{"$schema":"https://json.schemastore.org/sarif-2.1.0.json","version":"2.1.0","runs":[{"tool":{"driver":{"name":"codehealth","informationUri":"https://codehealth.canine.dev","rules":[{"id":"D1","name":"Cyclomatic Complexity","shortDescription":{"text":"Cyclomatic Complexity"},"helpUri":"https://codehealth.canine.dev/dimensions/D1"},{"id":"D2","name":"Cognitive Complexity","shortDescription":{"text":"Cognitive Complexity"},"helpUri":"https://codehealth.canine.dev/dimensions/D2"},{"id":"D3","name":"God Classes","shortDescription":{"text":"God Classes"},"helpUri":"https://codehealth.canine.dev/dimensions/D3"},{"id":"D4","name":"Code Duplication","shortDescription":{"text":"Code Duplication"},"helpUri":"https://codehealth.canine.dev/dimensions/D4"},{"id":"D5","name":"Coupling","shortDescription":{"text":"Coupling"},"helpUri":"https://codehealth.canine.dev/dimensions/D5"},{"id":"D6","name":"Cohesion (LCOM4)","shortDescription":{"text":"Cohesion (LCOM4)"},"helpUri":"https://codehealth.canine.dev/dimensions/D6"},{"id":"D10","name":"Test Quality","shortDescription":{"text":"Test Quality"},"helpUri":"https://codehealth.canine.dev/dimensions/D10"},{"id":"D12","name":"Dependency Hygiene","shortDescription":{"text":"Dependency Hygiene"},"helpUri":"https://codehealth.canine.dev/dimensions/D12"},{"id":"D13","name":"Secret Scanning","shortDescription":{"text":"Secret Scanning"},"helpUri":"https://codehealth.canine.dev/dimensions/D13","relationships":[{"target":{"id":"CWE-798","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]},{"target":{"id":"CWE-259","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]},{"target":{"id":"A07:2025","toolComponent":{"name":"OWASP Top 10","guid":"7d1f0c2e-4b6a-4e39-9a51-0b2e8c3d5f61"}},"kinds":["relevant"]}],"properties":{"cwe":["CWE-798","CWE-259"],"owasp":"A07:2025"}},{"id":"D14","name":"License Compliance","shortDescription":{"text":"License Compliance"},"helpUri":"https://codehealth.canine.dev/dimensions/D14"},{"id":"D15","name":"Churn \u00D7 Complexity Hotspots","shortDescription":{"text":"Churn \u00D7 Complexity Hotspots"},"helpUri":"https://codehealth.canine.dev/dimensions/D15"},{"id":"D16","name":"Bus Factor","shortDescription":{"text":"Bus Factor"},"helpUri":"https://codehealth.canine.dev/dimensions/D16"},{"id":"D17","name":"Explicit Debt","shortDescription":{"text":"Explicit Debt"},"helpUri":"https://codehealth.canine.dev/dimensions/D17"},{"id":"D19","name":"Documentation Quality","shortDescription":{"text":"Documentation Quality"},"helpUri":"https://codehealth.canine.dev/dimensions/D19"},{"id":"D20","name":"ADR Quality","shortDescription":{"text":"ADR Quality"},"helpUri":"https://codehealth.canine.dev/dimensions/D20"},{"id":"D24","name":"Comment Value","shortDescription":{"text":"Comment Value"},"helpUri":"https://codehealth.canine.dev/dimensions/D24"},{"id":"D26","name":"Project Cohesion","shortDescription":{"text":"Project Cohesion"},"helpUri":"https://codehealth.canine.dev/dimensions/D26"},{"id":"D27","name":"Navigability","shortDescription":{"text":"Navigability"},"helpUri":"https://codehealth.canine.dev/dimensions/D27"},{"id":"D28","name":"Secrets (history)","shortDescription":{"text":"Secrets (history)"},"helpUri":"https://codehealth.canine.dev/dimensions/D28","relationships":[{"target":{"id":"CWE-798","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]},{"target":{"id":"CWE-259","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]},{"target":{"id":"A07:2025","toolComponent":{"name":"OWASP Top 10","guid":"7d1f0c2e-4b6a-4e39-9a51-0b2e8c3d5f61"}},"kinds":["relevant"]}],"properties":{"cwe":["CWE-798","CWE-259"],"owasp":"A07:2025"}},{"id":"D29","name":"Static Analysis (SAST)","shortDescription":{"text":"Static Analysis (SAST)"},"helpUri":"https://codehealth.canine.dev/dimensions/D29","relationships":[{"target":{"id":"CWE-79","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]},{"target":{"id":"CWE-89","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]},{"target":{"id":"CWE-78","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]},{"target":{"id":"CWE-94","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]},{"target":{"id":"CWE-77","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]},{"target":{"id":"A05:2025","toolComponent":{"name":"OWASP Top 10","guid":"7d1f0c2e-4b6a-4e39-9a51-0b2e8c3d5f61"}},"kinds":["relevant"]}],"properties":{"cwe":["CWE-79","CWE-89","CWE-78","CWE-94","CWE-77"],"owasp":"A05:2025"}},{"id":"D30","name":"Dependency Vulnerabilities","shortDescription":{"text":"Dependency Vulnerabilities"},"helpUri":"https://codehealth.canine.dev/dimensions/D30","relationships":[{"target":{"id":"CWE-1395","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]},{"target":{"id":"CWE-937","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]},{"target":{"id":"A03:2025","toolComponent":{"name":"OWASP Top 10","guid":"7d1f0c2e-4b6a-4e39-9a51-0b2e8c3d5f61"}},"kinds":["relevant"]}],"properties":{"cwe":["CWE-1395","CWE-937"],"owasp":"A03:2025"}},{"id":"D31","name":"IaC \u0026 Container Security","shortDescription":{"text":"IaC \u0026 Container Security"},"helpUri":"https://codehealth.canine.dev/dimensions/D31","relationships":[{"target":{"id":"CWE-1032","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]},{"target":{"id":"CWE-732","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]},{"target":{"id":"CWE-16","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]},{"target":{"id":"A02:2025","toolComponent":{"name":"OWASP Top 10","guid":"7d1f0c2e-4b6a-4e39-9a51-0b2e8c3d5f61"}},"kinds":["relevant"]}],"properties":{"cwe":["CWE-1032","CWE-732","CWE-16"],"owasp":"A02:2025"}},{"id":"D32","name":"Data Compliance (PII/GDPR)","shortDescription":{"text":"Data Compliance (PII/GDPR)"},"helpUri":"https://codehealth.canine.dev/dimensions/D32","relationships":[{"target":{"id":"CWE-359","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]},{"target":{"id":"CWE-312","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]},{"target":{"id":"CWE-200","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]},{"target":{"id":"A01:2025","toolComponent":{"name":"OWASP Top 10","guid":"7d1f0c2e-4b6a-4e39-9a51-0b2e8c3d5f61"}},"kinds":["relevant"]}],"properties":{"cwe":["CWE-359","CWE-312","CWE-200"],"owasp":"A01:2025"}},{"id":"D34","name":"Knowledge Freshness","shortDescription":{"text":"Knowledge Freshness"},"helpUri":"https://codehealth.canine.dev/dimensions/D34"},{"id":"D35","name":"Change Coupling","shortDescription":{"text":"Change Coupling"},"helpUri":"https://codehealth.canine.dev/dimensions/D35"},{"id":"D36","name":"Supply-chain Provenance \u0026 Signing","shortDescription":{"text":"Supply-chain Provenance \u0026 Signing"},"helpUri":"https://codehealth.canine.dev/dimensions/D36","relationships":[{"target":{"id":"CWE-1357","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]},{"target":{"id":"CWE-494","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]},{"target":{"id":"A03:2025","toolComponent":{"name":"OWASP Top 10","guid":"7d1f0c2e-4b6a-4e39-9a51-0b2e8c3d5f61"}},"kinds":["relevant"]}],"properties":{"cwe":["CWE-1357","CWE-494"],"owasp":"A03:2025"}},{"id":"D37","name":"Vulnerability-disclosure Policy","shortDescription":{"text":"Vulnerability-disclosure Policy"},"helpUri":"https://codehealth.canine.dev/dimensions/D37","relationships":[{"target":{"id":"CWE-1059","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]},{"target":{"id":"A02:2025","toolComponent":{"name":"OWASP Top 10","guid":"7d1f0c2e-4b6a-4e39-9a51-0b2e8c3d5f61"}},"kinds":["relevant"]}],"properties":{"cwe":["CWE-1059"],"owasp":"A02:2025"}},{"id":"D43","name":"Malicious Dependencies","shortDescription":{"text":"Malicious Dependencies"},"helpUri":"https://codehealth.canine.dev/dimensions/D43","relationships":[{"target":{"id":"CWE-506","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]},{"target":{"id":"A08:2025","toolComponent":{"name":"OWASP Top 10","guid":"7d1f0c2e-4b6a-4e39-9a51-0b2e8c3d5f61"}},"kinds":["relevant"]}],"properties":{"cwe":["CWE-506"],"owasp":"A08:2025"}},{"id":"D44","name":"Platform End-of-Life","shortDescription":{"text":"Platform End-of-Life"},"helpUri":"https://codehealth.canine.dev/dimensions/D44"},{"id":"AC1","name":"Text alternatives","shortDescription":{"text":"Text alternatives"},"helpUri":"https://codehealth.canine.dev/dimensions/AC1"},{"id":"AC2","name":"Forms \u0026 labels","shortDescription":{"text":"Forms \u0026 labels"},"helpUri":"https://codehealth.canine.dev/dimensions/AC2"},{"id":"AC3","name":"Page structure","shortDescription":{"text":"Page structure"},"helpUri":"https://codehealth.canine.dev/dimensions/AC3"},{"id":"AC4","name":"Keyboard semantics","shortDescription":{"text":"Keyboard semantics"},"helpUri":"https://codehealth.canine.dev/dimensions/AC4"},{"id":"AC5","name":"ARIA correctness","shortDescription":{"text":"ARIA correctness"},"helpUri":"https://codehealth.canine.dev/dimensions/AC5"},{"id":"AC6","name":"Visual \u0026 motion safety","shortDescription":{"text":"Visual \u0026 motion safety"},"helpUri":"https://codehealth.canine.dev/dimensions/AC6"},{"id":"AX10","name":"Code composition","shortDescription":{"text":"Code composition"},"helpUri":"https://codehealth.canine.dev/dimensions/AX10"},{"id":"AX3","name":"Project dependency cycles","shortDescription":{"text":"Project dependency cycles"},"helpUri":"https://codehealth.canine.dev/dimensions/AX3"},{"id":"AX4","name":"Dependency direction","shortDescription":{"text":"Dependency direction"},"helpUri":"https://codehealth.canine.dev/dimensions/AX4"},{"id":"AX6","name":"Interface segregation","shortDescription":{"text":"Interface segregation"},"helpUri":"https://codehealth.canine.dev/dimensions/AX6"},{"id":"AXB2","name":"Runtime readiness","shortDescription":{"text":"Runtime readiness"},"helpUri":"https://codehealth.canine.dev/dimensions/AXB2"},{"id":"C2","name":"Access Controls","shortDescription":{"text":"Access Controls"},"helpUri":"https://codehealth.canine.dev/dimensions/C2"},{"id":"ED5","name":"Idempotency","shortDescription":{"text":"Idempotency"},"helpUri":"https://codehealth.canine.dev/dimensions/ED5"},{"id":"M1","name":"Documentation (README)","shortDescription":{"text":"Documentation (README)"},"helpUri":"https://codehealth.canine.dev/dimensions/M1"},{"id":"M2","name":"Architecture documentation","shortDescription":{"text":"Architecture documentation"},"helpUri":"https://codehealth.canine.dev/dimensions/M2"},{"id":"M3","name":"Folder \u0026 project structure","shortDescription":{"text":"Folder \u0026 project structure"},"helpUri":"https://codehealth.canine.dev/dimensions/M3"},{"id":"M4","name":"Documentation accuracy","shortDescription":{"text":"Documentation accuracy"},"helpUri":"https://codehealth.canine.dev/dimensions/M4"},{"id":"P1","name":"CI/CD gates","shortDescription":{"text":"CI/CD gates"},"helpUri":"https://codehealth.canine.dev/dimensions/P1"},{"id":"P10","name":"Library API \u0026 versioning","shortDescription":{"text":"Library API \u0026 versioning"},"helpUri":"https://codehealth.canine.dev/dimensions/P10"},{"id":"P12","name":"CI test-gate honesty","shortDescription":{"text":"CI test-gate honesty"},"helpUri":"https://codehealth.canine.dev/dimensions/P12"},{"id":"P2","name":"Observability","shortDescription":{"text":"Observability"},"helpUri":"https://codehealth.canine.dev/dimensions/P2"},{"id":"P3","name":"Security \u0026 performance tooling","shortDescription":{"text":"Security \u0026 performance tooling"},"helpUri":"https://codehealth.canine.dev/dimensions/P3"},{"id":"P4","name":"Deployment \u0026 Rollback","shortDescription":{"text":"Deployment \u0026 Rollback"},"helpUri":"https://codehealth.canine.dev/dimensions/P4"},{"id":"P5","name":"DR \u0026 Backup","shortDescription":{"text":"DR \u0026 Backup"},"helpUri":"https://codehealth.canine.dev/dimensions/P5"},{"id":"P6","name":"Release Hygiene","shortDescription":{"text":"Release Hygiene"},"helpUri":"https://codehealth.canine.dev/dimensions/P6"},{"id":"P7","name":"Outbound HTTP resilience","shortDescription":{"text":"Outbound HTTP resilience"},"helpUri":"https://codehealth.canine.dev/dimensions/P7"},{"id":"PF3","name":"Async \u0026 latency hygiene","shortDescription":{"text":"Async \u0026 latency hygiene"},"helpUri":"https://codehealth.canine.dev/dimensions/PF3"},{"id":"R1","name":"Type Safety","shortDescription":{"text":"Type Safety"},"helpUri":"https://codehealth.canine.dev/dimensions/R1"},{"id":"R10","name":"Code Duplication","shortDescription":{"text":"Code Duplication"},"helpUri":"https://codehealth.canine.dev/dimensions/R10"},{"id":"R2","name":"Cyclomatic Complexity","shortDescription":{"text":"Cyclomatic Complexity"},"helpUri":"https://codehealth.canine.dev/dimensions/R2"},{"id":"R3","name":"Large Files","shortDescription":{"text":"Large Files"},"helpUri":"https://codehealth.canine.dev/dimensions/R3"},{"id":"R4","name":"Test Coverage","shortDescription":{"text":"Test Coverage"},"helpUri":"https://codehealth.canine.dev/dimensions/R4"},{"id":"R5","name":"Dependency Freshness","shortDescription":{"text":"Dependency Freshness"},"helpUri":"https://codehealth.canine.dev/dimensions/R5"},{"id":"R6","name":"Tooling","shortDescription":{"text":"Tooling"},"helpUri":"https://codehealth.canine.dev/dimensions/R6"},{"id":"R7","name":"Dead Code","shortDescription":{"text":"Dead Code"},"helpUri":"https://codehealth.canine.dev/dimensions/R7"},{"id":"R8","name":"Dependency Hygiene","shortDescription":{"text":"Dependency Hygiene"},"helpUri":"https://codehealth.canine.dev/dimensions/R8"},{"id":"R9","name":"Circular Imports","shortDescription":{"text":"Circular Imports"},"helpUri":"https://codehealth.canine.dev/dimensions/R9"},{"id":"S1","name":"Web-Security Posture","shortDescription":{"text":"Web-Security Posture"},"helpUri":"https://codehealth.canine.dev/dimensions/S1"},{"id":"SC1","name":"Supply-chain hygiene","shortDescription":{"text":"Supply-chain hygiene"},"helpUri":"https://codehealth.canine.dev/dimensions/SC1"},{"id":"X1","name":"Async correctness","shortDescription":{"text":"Async correctness"},"helpUri":"https://codehealth.canine.dev/dimensions/X1"},{"id":"X10","name":"Duplicated predicate","shortDescription":{"text":"Duplicated predicate"},"helpUri":"https://codehealth.canine.dev/dimensions/X10"},{"id":"X12","name":"Unreachable branch","shortDescription":{"text":"Unreachable branch"},"helpUri":"https://codehealth.canine.dev/dimensions/X12"},{"id":"X13","name":"Undrained process stream","shortDescription":{"text":"Undrained process stream"},"helpUri":"https://codehealth.canine.dev/dimensions/X13"},{"id":"X14","name":"Bypassable address classification","shortDescription":{"text":"Bypassable address classification"},"helpUri":"https://codehealth.canine.dev/dimensions/X14"},{"id":"X15","name":"Unvalidated length from an untrusted reader","shortDescription":{"text":"Unvalidated length from an untrusted reader"},"helpUri":"https://codehealth.canine.dev/dimensions/X15"},{"id":"X17","name":"Uncapped recursion over a caller-supplied document","shortDescription":{"text":"Uncapped recursion over a caller-supplied document"},"helpUri":"https://codehealth.canine.dev/dimensions/X17"},{"id":"X18","name":"Disposal-pattern correctness","shortDescription":{"text":"Disposal-pattern correctness"},"helpUri":"https://codehealth.canine.dev/dimensions/X18"},{"id":"X19","name":"Unrestored process-global state","shortDescription":{"text":"Unrestored process-global state"},"helpUri":"https://codehealth.canine.dev/dimensions/X19"},{"id":"X2","name":"Cancellation propagation","shortDescription":{"text":"Cancellation propagation"},"helpUri":"https://codehealth.canine.dev/dimensions/X2"},{"id":"X20","name":"Mistyped argument guard","shortDescription":{"text":"Mistyped argument guard"},"helpUri":"https://codehealth.canine.dev/dimensions/X20"},{"id":"X21","name":"Side-effecting pattern guard","shortDescription":{"text":"Side-effecting pattern guard"},"helpUri":"https://codehealth.canine.dev/dimensions/X21"},{"id":"X22","name":"Contradicted release guard","shortDescription":{"text":"Contradicted release guard"},"helpUri":"https://codehealth.canine.dev/dimensions/X22"},{"id":"X23","name":"Unguarded diagnostic materialisation","shortDescription":{"text":"Unguarded diagnostic materialisation"},"helpUri":"https://codehealth.canine.dev/dimensions/X23"},{"id":"X24","name":"Document value interpolated into markup unescaped","shortDescription":{"text":"Document value interpolated into markup unescaped"},"helpUri":"https://codehealth.canine.dev/dimensions/X24"},{"id":"X25","name":"Inert configuration knob","shortDescription":{"text":"Inert configuration knob"},"helpUri":"https://codehealth.canine.dev/dimensions/X25"},{"id":"X26","name":"Unsynchronised callback handoff","shortDescription":{"text":"Unsynchronised callback handoff"},"helpUri":"https://codehealth.canine.dev/dimensions/X26"},{"id":"X27","name":"Collection changed while being enumerated","shortDescription":{"text":"Collection changed while being enumerated"},"helpUri":"https://codehealth.canine.dev/dimensions/X27"},{"id":"X28","name":"Index access outside its own emptiness guard","shortDescription":{"text":"Index access outside its own emptiness guard"},"helpUri":"https://codehealth.canine.dev/dimensions/X28"},{"id":"X3","name":"Exception handling","shortDescription":{"text":"Exception handling"},"helpUri":"https://codehealth.canine.dev/dimensions/X3"},{"id":"X30","name":"Support guard that admits what it rejects","shortDescription":{"text":"Support guard that admits what it rejects"},"helpUri":"https://codehealth.canine.dev/dimensions/X30"},{"id":"X32","name":"Type resolved by simple name across every loaded assembly","shortDescription":{"text":"Type resolved by simple name across every loaded assembly"},"helpUri":"https://codehealth.canine.dev/dimensions/X32"},{"id":"X4","name":"Structured logging","shortDescription":{"text":"Structured logging"},"helpUri":"https://codehealth.canine.dev/dimensions/X4"},{"id":"X5","name":"Nullable reference types","shortDescription":{"text":"Nullable reference types"},"helpUri":"https://codehealth.canine.dev/dimensions/X5"},{"id":"X6","name":"Hand-rolled structured-format parsing","shortDescription":{"text":"Hand-rolled structured-format parsing"},"helpUri":"https://codehealth.canine.dev/dimensions/X6"},{"id":"X7","name":"Silent fallback defaults","shortDescription":{"text":"Silent fallback defaults"},"helpUri":"https://codehealth.canine.dev/dimensions/X7"},{"id":"X9","name":"Subsumed condition operand","shortDescription":{"text":"Subsumed condition operand"},"helpUri":"https://codehealth.canine.dev/dimensions/X9"}]}},"results":[{"ruleId":"D1","level":"warning","message":{"text":"Agent.Agent (cyclomatic 364): Agent.Agent has cyclomatic complexity 364 (threshold 15). Of this number, 22 points are the body\u0027s own statements and 342 belong to 74 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Agent.tsx"},"region":{"startLine":227}}}],"partialFingerprints":{"codehealthFindingId/v1":"56911833fec46b2d5f0abec76e3f72f76b63d1d28844aef71f449dee63ca3a86"}},{"ruleId":"D1","level":"warning","message":{"text":"Scheduled.Scheduled (cyclomatic 116): Scheduled.Scheduled has cyclomatic complexity 116 (threshold 15). Of this number, 40 points are the body\u0027s own statements and 76 belong to 19 function items inside it that branch. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Scheduled.tsx"},"region":{"startLine":92}}}],"partialFingerprints":{"codehealthFindingId/v1":"ad3eef0dad377fed161c2be159957469e44bf91cdf68ad7b267c90e5c29fb7ef"}},{"ruleId":"D1","level":"warning","message":{"text":"AgentLoop._run_bound (cyclomatic 92): AgentLoop._run_bound has cyclomatic complexity 92 (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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/agent/loop.py"},"region":{"startLine":386}}}],"partialFingerprints":{"codehealthFindingId/v1":"f65ec0599221120923dd1ad72f92cf30eee6081655ad94c587cd7d4ef4c9bc19"}},{"ruleId":"D1","level":"warning","message":{"text":"Portfolio.Portfolio (cyclomatic 78): Portfolio.Portfolio has cyclomatic complexity 78 (threshold 15). Of this number, 27 points are the body\u0027s own statements and 51 belong to 16 function items inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Portfolio.tsx"},"region":{"startLine":135}}}],"partialFingerprints":{"codehealthFindingId/v1":"ee23c9bd819159a172597ce32d7a9151a5263f7eec398f2235b00d15047bd4c4"}},{"ruleId":"D1","level":"warning","message":{"text":"RunDetail.RunDetail (cyclomatic 75): RunDetail.RunDetail has cyclomatic complexity 75 (threshold 15). Of this number, 38 points are the body\u0027s own statements and 37 belong to 13 function items inside it that branch. To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/RunDetail.tsx"},"region":{"startLine":124}}}],"partialFingerprints":{"codehealthFindingId/v1":"04d3febb2f6d5817552b678f9778bec875344d546a4c907f11621167209fa744"}},{"ruleId":"D1","level":"warning","message":{"text":"ResearchLab.ResearchLab (cyclomatic 69): ResearchLab.ResearchLab has cyclomatic complexity 69 (threshold 15). Of this number, 22 points are the body\u0027s own statements and 47 belong to 16 function items inside it that branch. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/ResearchLab.tsx"},"region":{"startLine":20}}}],"partialFingerprints":{"codehealthFindingId/v1":"7e132592890e2958c7dce79bdac7b6f2a6fd8020e1a9f0aef0b2c2663f2486c2"}},{"ruleId":"D1","level":"warning","message":{"text":"WeixinChannel._process_message (cyclomatic 66): WeixinChannel._process_message has cyclomatic complexity 66 (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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/weixin.py"},"region":{"startLine":600}}}],"partialFingerprints":{"codehealthFindingId/v1":"0d4d02f9b2c1e145ac78a7035816a569135002d3567f2860169502f5b1a12ec0"}},{"ruleId":"D1","level":"warning","message":{"text":"ShannonPortfolio.ShannonPortfolio (cyclomatic 66): ShannonPortfolio.ShannonPortfolio has cyclomatic complexity 66 (threshold 15). Of this number, 30 points are the body\u0027s own statements and 36 belong to 11 function items inside it that branch. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/charts/ShannonPortfolio.tsx"},"region":{"startLine":31}}}],"partialFingerprints":{"codehealthFindingId/v1":"e2950e3a5ec3573f612b95dee74bf656f15525bffa08753e78641f83873ece0d"}},{"ruleId":"D1","level":"warning","message":{"text":"_legacy.main (cyclomatic 63): _legacy.main has cyclomatic complexity 63 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":6402}}}],"partialFingerprints":{"codehealthFindingId/v1":"dc9d6cd8cd525abe42c33e6865463e663c0249c042ce7c075170b9e925555831"}},{"ruleId":"D1","level":"warning","message":{"text":"ResearchArtifacts.ResearchArtifacts (cyclomatic 63): ResearchArtifacts.ResearchArtifacts has cyclomatic complexity 63 (threshold 15). Of this number, 26 points are the body\u0027s own statements and 37 belong to 8 function items inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/ResearchArtifacts.tsx"},"region":{"startLine":80}}}],"partialFingerprints":{"codehealthFindingId/v1":"f81fb35b55a50d7174130ed56e539c44463dd6bd102ebcda431512a7298978ea"}},{"ruleId":"D1","level":"warning","message":{"text":"options_portfolio._calc_options_metrics (cyclomatic 58): options_portfolio._calc_options_metrics has cyclomatic complexity 58 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/engines/options_portfolio.py"},"region":{"startLine":705}}}],"partialFingerprints":{"codehealthFindingId/v1":"99e3dbb7da06e1e615fca4fc5cd4f64914306fbe66129da63b121817149e213e"}},{"ruleId":"D1","level":"warning","message":{"text":"Layout.Layout (cyclomatic 58): Layout.Layout has cyclomatic complexity 58 (threshold 15). Of this number, 30 points are the body\u0027s own statements and 28 belong to 13 function items inside it that branch. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/layout/Layout.tsx"},"region":{"startLine":21}}}],"partialFingerprints":{"codehealthFindingId/v1":"fcd358affae1482404beee4e244dedf850070d84c9db7e0ffdd060d28c7198ca"}},{"ruleId":"D1","level":"warning","message":{"text":"ToolCallLifecycle._process_tool_calls (cyclomatic 57): ToolCallLifecycle._process_tool_calls has cyclomatic complexity 57 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/agent/tool_lifecycle.py"},"region":{"startLine":95}}}],"partialFingerprints":{"codehealthFindingId/v1":"b4b27c1cd15eed14ac06c4c788cd44d222b75098a2a860f657dc441869111f0a"}},{"ruleId":"D1","level":"warning","message":{"text":"historical._walk_bars (cyclomatic 55): historical._walk_bars has cyclomatic complexity 55 (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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/data_gateway/historical.py"},"region":{"startLine":121}}}],"partialFingerprints":{"codehealthFindingId/v1":"4dabb95fb5008d2143eacd43439619d1ed92a2acc609bd21e685c80c2b64a3a4"}},{"ruleId":"D1","level":"warning","message":{"text":"PortfolioService._collect_source (cyclomatic 53): PortfolioService._collect_source has cyclomatic complexity 53 (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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/portfolio/service.py"},"region":{"startLine":962}}}],"partialFingerprints":{"codehealthFindingId/v1":"8cecb769757fc27fd98b0e31341d9942659877ebe555c2fb0118e3f4888299f8"}},{"ruleId":"D1","level":"warning","message":{"text":"options_portfolio.run_options_backtest (cyclomatic 52): options_portfolio.run_options_backtest has cyclomatic complexity 52 (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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/engines/options_portfolio.py"},"region":{"startLine":199}}}],"partialFingerprints":{"codehealthFindingId/v1":"853a4688731dcf0bde7275da605e5a8e6159fc559606aa667012c2c98a11b0ae"}},{"ruleId":"D1","level":"warning","message":{"text":"worker._run_worker_impl (cyclomatic 52): worker._run_worker_impl has cyclomatic complexity 52 (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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/swarm/worker.py"},"region":{"startLine":557}}}],"partialFingerprints":{"codehealthFindingId/v1":"73c93bcb08ff1392e629c92b4257cd288565c238678408da9da7e03a305eb774"}},{"ruleId":"D1","level":"warning","message":{"text":"OptionsLab.OptionsLab (cyclomatic 50): OptionsLab.OptionsLab has cyclomatic complexity 50 (threshold 15). Of this number, 37 points are the body\u0027s own statements and 13 belong to 5 function items inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/OptionsLab.tsx"},"region":{"startLine":61}}}],"partialFingerprints":{"codehealthFindingId/v1":"9d625e978a458c08fc949eb89213fd675fad335a611d519f9ebfcdbfb579d234"}},{"ruleId":"D1","level":"warning","message":{"text":"_PolicyMixin._derivation (cyclomatic 49): _PolicyMixin._derivation has cyclomatic complexity 49 (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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/grounding/policies.py"},"region":{"startLine":1957}}}],"partialFingerprints":{"codehealthFindingId/v1":"77170a1d2c4526bfb1ad268b84ad9174aea95f1612d5a65f03344d616fd325b5"}},{"ruleId":"D1","level":"warning","message":{"text":"ChatLLM.stream_chat (cyclomatic 49): ChatLLM.stream_chat has cyclomatic complexity 49 (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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/providers/chat.py"},"region":{"startLine":495}}}],"partialFingerprints":{"codehealthFindingId/v1":"aea20a233f7f815ce4a79abae3d2bfe1f1c619b14f43cb3259b4a5d23a0d563f"}},{"ruleId":"D1","level":"warning","message":{"text":"Compare.Compare (cyclomatic 49): Compare.Compare has cyclomatic complexity 49 (threshold 15). Of this number, 24 points are the body\u0027s own statements and 25 belong to 14 function literals inside it that branch. To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Compare.tsx"},"region":{"startLine":235}}}],"partialFingerprints":{"codehealthFindingId/v1":"0d5ee20d5c9cc82f6de5bf5c4c4cb80011f3a3bf1eefdc0fd5972933b28641fc"}},{"ruleId":"D1","level":"warning","message":{"text":"feishu._extract_element_content (cyclomatic 48): feishu._extract_element_content has cyclomatic complexity 48 (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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/feishu.py"},"region":{"startLine":204}}}],"partialFingerprints":{"codehealthFindingId/v1":"7c5f434b701fc6359b9bca307f20f1fddaf389cf426ebfe5bc262f8e503536b0"}},{"ruleId":"D1","level":"warning","message":{"text":"BaseEngine._execute_bars (cyclomatic 47): BaseEngine._execute_bars has cyclomatic complexity 47 (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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/engines/base.py"},"region":{"startLine":1290}}}],"partialFingerprints":{"codehealthFindingId/v1":"9432da01b280e8ef01018edc16f17d6451b239a3281e2f2be2bdf931a6ccdcb4"}},{"ruleId":"D1","level":"warning","message":{"text":"schema._validate_expectations (cyclomatic 47): schema._validate_expectations has cyclomatic complexity 47 (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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/harness/schema.py"},"region":{"startLine":79}}}],"partialFingerprints":{"codehealthFindingId/v1":"5eff6c65abeba602334128e003e6fbf0a4e567e43ba7ed5ed01f3fe39a859c95"}},{"ruleId":"D1","level":"warning","message":{"text":"HistoryStore.run (cyclomatic 47): HistoryStore.run has cyclomatic complexity 47 (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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/data_gateway/history_store.py"},"region":{"startLine":526}}}],"partialFingerprints":{"codehealthFindingId/v1":"d192309b0e6b9090e0f447da956e0556ff291de47eecbb0b0a19b71e12649922"}},{"ruleId":"D1","level":"warning","message":{"text":"bench_runner.run_bench (cyclomatic 47): bench_runner.run_bench has cyclomatic complexity 47 (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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/bench_runner.py"},"region":{"startLine":144}}}],"partialFingerprints":{"codehealthFindingId/v1":"54d16a10f1a9d6b08b49d84071320cec079f103994de2044d446b23f5813c7e6"}},{"ruleId":"D1","level":"warning","message":{"text":"bench_runner_strict.run_bench_strict (cyclomatic 46): bench_runner_strict.run_bench_strict has cyclomatic complexity 46 (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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/bench_runner_strict.py"},"region":{"startLine":326}}}],"partialFingerprints":{"codehealthFindingId/v1":"f0cb3705e7f712eac58d623336ec59cb89e43814d37fa9bf62825561ba1f1a4f"}},{"ruleId":"D1","level":"warning","message":{"text":"swarmStatus.applySwarmEvent (cyclomatic 46): swarmStatus.applySwarmEvent has cyclomatic complexity 46 (threshold 15). Of this number, 27 points are the body\u0027s own statements and 19 belong to 9 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/lib/swarmStatus.ts"},"region":{"startLine":209}}}],"partialFingerprints":{"codehealthFindingId/v1":"92b760e7c17d96dafbf303f608d4b5dff49fa541a2cb7b8ca85da57b5e6520e2"}},{"ruleId":"D1","level":"warning","message":{"text":"_PolicyMixin._referenced (cyclomatic 45): _PolicyMixin._referenced has cyclomatic complexity 45 (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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/grounding/policies.py"},"region":{"startLine":817}}}],"partialFingerprints":{"codehealthFindingId/v1":"a3f3a24da5992ec96847ce8dc4bbe0b1f16ad50ed58531aa4d6e617d67c98405"}},{"ruleId":"D1","level":"warning","message":{"text":"service.build_job_from_draft (cyclomatic 45): service.build_job_from_draft has cyclomatic complexity 45 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/scheduled_research/service.py"},"region":{"startLine":136}}}],"partialFingerprints":{"codehealthFindingId/v1":"0d3cf145f565924b92d8ac5c75d94a3989d4f94259eae152faf3470eabfb04d1"}},{"ruleId":"D1","level":"warning","message":{"text":"runner.fetch_data_map (cyclomatic 44): runner.fetch_data_map has cyclomatic complexity 44 (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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/runner.py"},"region":{"startLine":2060}}}],"partialFingerprints":{"codehealthFindingId/v1":"a0f5b104128f7fdc223e40913bbda8477fbeeac5a9d15b0c16bef39a33909038"}},{"ruleId":"D1","level":"warning","message":{"text":"figures.scan_figures (cyclomatic 44): figures.scan_figures has cyclomatic complexity 44 (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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/grounding/figures.py"},"region":{"startLine":1254}}}],"partialFingerprints":{"codehealthFindingId/v1":"49d2f86f4dc4436c49641074d9e9e5dd151564a4a34ae2779a70689dde04e79d"}},{"ruleId":"D1","level":"warning","message":{"text":"ConnectionCenter.ConnectionCard (cyclomatic 44): ConnectionCenter.ConnectionCard has cyclomatic complexity 44 (threshold 15). Of this number, 31 points are the body\u0027s own statements and 13 belong to 4 function items inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/portfolio/ConnectionCenter.tsx"},"region":{"startLine":183}}}],"partialFingerprints":{"codehealthFindingId/v1":"8734f72fd6f4320ad10a9db205683f9bf621aa21e0c12d8bf9605518895ccab3"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelSettings.ChannelSettings (cyclomatic 44): ChannelSettings.ChannelSettings has cyclomatic complexity 44 (threshold 15). Most of this is not in the body itself: 13 of the 44 points are its own statements and the rest belongs to 7 function items inside it that branch (a function literal at line 235, setChannelsRunning, a function literal at line 38, \u2026). The named helpers are already separate functions; the literals\u0027 work cannot be called, reviewed or tested from outside this body. To reduce it, move the named helpers out of the body to the enclosing scope and lift each literal\u0027s work into a named function there, so each is measured, reviewed and tested on its own, and reduce whichever one then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/settings/ChannelSettings.tsx"},"region":{"startLine":24}}}],"partialFingerprints":{"codehealthFindingId/v1":"9753977a23e715ab57bd99477bb73ccce72e1897bb1c8c9490eaae5ce2140e4d"}},{"ruleId":"D1","level":"warning","message":{"text":"_PolicyMixin._validate_figures (cyclomatic 43): _PolicyMixin._validate_figures has cyclomatic complexity 43 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/grounding/policies.py"},"region":{"startLine":467}}}],"partialFingerprints":{"codehealthFindingId/v1":"538b45928cdfd440a81b8a1da744053fd9ef6e23113f80f9ccfa4a415f67da6f"}},{"ruleId":"D1","level":"warning","message":{"text":"_PolicyMixin._check_observed (cyclomatic 43): _PolicyMixin._check_observed has cyclomatic complexity 43 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/grounding/policies.py"},"region":{"startLine":1695}}}],"partialFingerprints":{"codehealthFindingId/v1":"22fb47885dc7d521aa854d9d1b75cff3265e81c622abcc55ff632782f86a5f04"}},{"ruleId":"D1","level":"warning","message":{"text":"openai_codex._message_chunks_from_events (cyclomatic 43): openai_codex._message_chunks_from_events has cyclomatic complexity 43 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/providers/openai_codex.py"},"region":{"startLine":632}}}],"partialFingerprints":{"codehealthFindingId/v1":"c24cf1ae5b056d58d83b0fdc8e75acb0281f0e9f54460ab155737a7cb9b7cd93"}},{"ruleId":"D1","level":"warning","message":{"text":"EmailChannel.send (cyclomatic 42): EmailChannel.send has cyclomatic complexity 42 (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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/email.py"},"region":{"startLine":265}}}],"partialFingerprints":{"codehealthFindingId/v1":"0255519c3674ccb3cfe8524d3e0ad2391eb48a840a937565ce40f1cb33455e83"}},{"ruleId":"D1","level":"warning","message":{"text":"cli_handlers.cmd_alpha_bench (cyclomatic 42): cli_handlers.cmd_alpha_bench has cyclomatic complexity 42 (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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/cli_handlers.py"},"region":{"startLine":566}}}],"partialFingerprints":{"codehealthFindingId/v1":"eb731c216be3e58c332884466a24cfaac6a47ef16de730c75b151ffdb3697dc7"}},{"ruleId":"D1","level":"warning","message":{"text":"RunnerStatus.BrokerRow (cyclomatic 42): RunnerStatus.BrokerRow has cyclomatic complexity 42 (threshold 15). Of this number, 34 points are the body\u0027s own statements and 8 belong to 4 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/chat/RunnerStatus.tsx"},"region":{"startLine":121}}}],"partialFingerprints":{"codehealthFindingId/v1":"7ac8f77f378eb1822379015888cda8acb6f98852eb7afe1daa5fb865e4877486"}},{"ruleId":"D1","level":"warning","message":{"text":"IdentityLedger._ingest_resolution (cyclomatic 41): IdentityLedger._ingest_resolution has cyclomatic complexity 41 (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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/agent/instrument_identity.py"},"region":{"startLine":739}}}],"partialFingerprints":{"codehealthFindingId/v1":"38971c169c2503fe6438f109cf0fc581640660eba75fce01eb16d73f19e28539"}},{"ruleId":"D1","level":"warning","message":{"text":"eventstudy.event_study (cyclomatic 41): eventstudy.event_study has cyclomatic complexity 41 (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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/eventstudy.py"},"region":{"startLine":325}}}],"partialFingerprints":{"codehealthFindingId/v1":"1ea99c1bfcf2a408a1d023c13c4b785cefe2f9fd2d2eb6e385ea924b192f34c6"}},{"ruleId":"D1","level":"warning","message":{"text":"financial_facts.validate_financial_facts (cyclomatic 41): financial_facts.validate_financial_facts has cyclomatic complexity 41 (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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/research_artifacts/financial_facts.py"},"region":{"startLine":69}}}],"partialFingerprints":{"codehealthFindingId/v1":"2732ac071bcf7b29532f3fb40a85871aaf76bacc8538254eb9b1f14db3153646"}},{"ruleId":"D1","level":"warning","message":{"text":"CandlestickChart.CandlestickChart (cyclomatic 41): CandlestickChart.CandlestickChart has cyclomatic complexity 41 (threshold 15). Most of this is not in the body itself: 3 of the 41 points are its own statements and the rest belongs to 13 function literals inside it that branch (lines 114, 222, 156, \u2026). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/charts/CandlestickChart.tsx"},"region":{"startLine":37}}}],"partialFingerprints":{"codehealthFindingId/v1":"b38d59759ffff696fcfeac693ae77dbd3e2852d8cad22295b19d6f7caf94665b"}},{"ruleId":"D1","level":"warning","message":{"text":"Settings.Settings (cyclomatic 41): Settings.Settings has cyclomatic complexity 41 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages. This shape REPEATS in the file: 2 other methods here (Settings.Settings::submit, Settings.Settings::submitDataSources) have the same decision points, in the same order, at the same nesting depths \u2014 so this is one pattern written 3 times rather than 3 independent problems. Splitting this body alone leaves the other 2 exactly as they are. Where these are variations on one operation, the change that clears all 3 is the shared one: lift the common shape into a single routine the variants call, parameterised by whatever genuinely differs between them, and keep in each method only the part that is not shared."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Settings.tsx"},"region":{"startLine":42}}}],"partialFingerprints":{"codehealthFindingId/v1":"a4639d4b644947d2eef6a7b3dc38356fa08868a9f33704676d16535d166be69f"}},{"ruleId":"D1","level":"warning","message":{"text":"llm.build_llm (cyclomatic 40): llm.build_llm has cyclomatic complexity 40 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/providers/llm.py"},"region":{"startLine":1454}}}],"partialFingerprints":{"codehealthFindingId/v1":"d521d05f0d2f16cbff8bc0c32c9a2719e1a0537e968861bc4320e6c13eb2f547"}},{"ruleId":"D1","level":"warning","message":{"text":"mcp.quote_summary (cyclomatic 40): mcp.quote_summary has cyclomatic complexity 40 (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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/robinhood/mcp.py"},"region":{"startLine":352}}}],"partialFingerprints":{"codehealthFindingId/v1":"529b1e3bb836c55f3fe1b55f5cd2cca7358ee6ee928a3286e788a9a3369f51de"}},{"ruleId":"D1","level":"warning","message":{"text":"MandateProposalCard.MandateProposalCard (cyclomatic 40): MandateProposalCard.MandateProposalCard has cyclomatic complexity 40 (threshold 15). Of this number, 23 points are the body\u0027s own statements and 17 belong to 7 function literals inside it that branch. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/chat/MandateProposalCard.tsx"},"region":{"startLine":203}}}],"partialFingerprints":{"codehealthFindingId/v1":"c67249d236734b3d462c19520518393be90926ff77ebb628905408a42995a0b9"}},{"ruleId":"D1","level":"warning","message":{"text":"VibeTradingDingTalkHandler.process (cyclomatic 39): VibeTradingDingTalkHandler.process has cyclomatic complexity 39 (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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/dingtalk.py"},"region":{"startLine":57}}}],"partialFingerprints":{"codehealthFindingId/v1":"5b8598f7b6128fcbe88e6af5d02f6c8694ceef095586929a07b33178849e6600"}},{"ruleId":"D1","level":"warning","message":{"text":"SlackChannel._on_socket_request (cyclomatic 39): SlackChannel._on_socket_request has cyclomatic complexity 39 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/slack.py"},"region":{"startLine":335}}}],"partialFingerprints":{"codehealthFindingId/v1":"4d078fd0ab71e315c2cc7e1a6b34afee4acde7459ad88a439321a3a1899a4bc0"}},{"ruleId":"D1","level":"warning","message":{"text":"normalization.normalize_position (cyclomatic 39): normalization.normalize_position has cyclomatic complexity 39 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/portfolio/normalization.py"},"region":{"startLine":56}}}],"partialFingerprints":{"codehealthFindingId/v1":"65279faa003f16358df6f807d83509c67ba1b589ee47b505e4c974302e6e979e"}},{"ruleId":"D1","level":"warning","message":{"text":"ScheduledResearchJob.from_dict (cyclomatic 39): ScheduledResearchJob.from_dict has cyclomatic complexity 39 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/scheduled_research/models.py"},"region":{"startLine":313}}}],"partialFingerprints":{"codehealthFindingId/v1":"c637001b75b523468d8b00c41fafe19239408848558d18791b71daf46fe520ea"}},{"ruleId":"D1","level":"warning","message":{"text":"gildata_fin_query_tool._normalize_table (cyclomatic 39): gildata_fin_query_tool._normalize_table has cyclomatic complexity 39 (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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/gildata_fin_query_tool.py"},"region":{"startLine":35}}}],"partialFingerprints":{"codehealthFindingId/v1":"6f1046091802fa4b41f7c1a644e0d8d972ea4aab5ed1f935d7f67141f069d9e9"}},{"ruleId":"D1","level":"warning","message":{"text":"MarketDataTool.execute (cyclomatic 39): MarketDataTool.execute has cyclomatic complexity 39 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/market_data_tool.py"},"region":{"startLine":172}}}],"partialFingerprints":{"codehealthFindingId/v1":"cf5e02166568fd494184e835a23774deaf48191d61f8950ee380f9acad483cb6"}},{"ruleId":"D1","level":"warning","message":{"text":"WebSearchTool.execute (cyclomatic 39): WebSearchTool.execute has cyclomatic complexity 39 (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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/web_search_tool.py"},"region":{"startLine":175}}}],"partialFingerprints":{"codehealthFindingId/v1":"f63da6ace8578cfa2a4ba9405af7617476325fedcaba96676722a9bc541e05b6"}},{"ruleId":"D1","level":"warning","message":{"text":"CustomProviderManager.CustomProviderManager (cyclomatic 39): CustomProviderManager.CustomProviderManager has cyclomatic complexity 39 (threshold 15). Of this number, 23 points are the body\u0027s own statements and 16 belong to 6 function items inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/settings/CustomProviderManager.tsx"},"region":{"startLine":20}}}],"partialFingerprints":{"codehealthFindingId/v1":"2bfd70d5caab4fbf8cb582dd72c93a15622684b1cc85e9cf085791bdf5089c5c"}},{"ruleId":"D1","level":"warning","message":{"text":"ingest._load_panel_long (cyclomatic 38): ingest._load_panel_long has cyclomatic complexity 38 (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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/entities/ingest.py"},"region":{"startLine":928}}}],"partialFingerprints":{"codehealthFindingId/v1":"7b2f5e96cbd2b24f8438dfe917eddaf3b8d6a32203286f33065f1d1cc97d4014"}},{"ruleId":"D1","level":"warning","message":{"text":"options.barrier_option_price (cyclomatic 38): options.barrier_option_price has cyclomatic complexity 38 (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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/options.py"},"region":{"startLine":517}}}],"partialFingerprints":{"codehealthFindingId/v1":"549dfdaecb24e674b1b88774c8d03fb02e6934c1a109ab678d60f88dec3376c9"}},{"ruleId":"D1","level":"warning","message":{"text":"AlphaZoo.BrowseView (cyclomatic 38): AlphaZoo.BrowseView has cyclomatic complexity 38 (threshold 15). Most of this is not in the body itself: 12 of the 38 points are its own statements and the rest belongs to 10 function literals inside it that branch (lines 197, 386, 189, \u2026). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/AlphaZoo.tsx"},"region":{"startLine":143}}}],"partialFingerprints":{"codehealthFindingId/v1":"c3827b693c4eb3eb2c279ddd2e841f19b53858cfc8e137087e6f9f64cdb2c192"}},{"ruleId":"D1","level":"warning","message":{"text":"runs_routes._build_response_from_run_dir (cyclomatic 37): runs_routes._build_response_from_run_dir has cyclomatic complexity 37 (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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/api/runs_routes.py"},"region":{"startLine":680}}}],"partialFingerprints":{"codehealthFindingId/v1":"3197c930a53e193feed03d828efbfd1336299a5d5d03b2fedd46eb9693777442"}},{"ruleId":"D1","level":"warning","message":{"text":"TelegramChannel.send_delta (cyclomatic 37): TelegramChannel.send_delta has cyclomatic complexity 37 (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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/telegram.py"},"region":{"startLine":937}}}],"partialFingerprints":{"codehealthFindingId/v1":"7b781040c0452952b4a404bfbdcc40214929882716aa80809e1e5b9565bf4e13"}},{"ruleId":"D1","level":"warning","message":{"text":"WecomChannel._process_message (cyclomatic 37): WecomChannel._process_message has cyclomatic complexity 37 (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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/wecom.py"},"region":{"startLine":223}}}],"partialFingerprints":{"codehealthFindingId/v1":"576b884a1538d1d60868e03258192415a26ff04083b942865fb6c71476367335"}},{"ruleId":"D1","level":"warning","message":{"text":"sources.normalize (cyclomatic 37): sources.normalize has cyclomatic complexity 37 (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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/data_gateway/sources.py"},"region":{"startLine":25}}}],"partialFingerprints":{"codehealthFindingId/v1":"ccae7c1e7da4053e1e3994c6354536d1358f786c9dbfc91aa82c19765a45b568"}},{"ruleId":"D1","level":"warning","message":{"text":"RailRunDashboard.handle_event (cyclomatic 36): RailRunDashboard.handle_event has cyclomatic complexity 36 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/ui/rail.py"},"region":{"startLine":320}}}],"partialFingerprints":{"codehealthFindingId/v1":"966c71efbe0c6d09e0dd8c442d3aab150462e1246c7cb156c83f8e4e96800999"}},{"ruleId":"D1","level":"warning","message":{"text":"historical.fetch_bars (cyclomatic 36): historical.fetch_bars has cyclomatic complexity 36 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/data_gateway/historical.py"},"region":{"startLine":21}}}],"partialFingerprints":{"codehealthFindingId/v1":"7f5896acf1c8f4947cf1177b33488708a44e7e7452e5ba235f8cb667052deaee"}},{"ruleId":"D1","level":"warning","message":{"text":"cli_handlers.cmd_alpha_show (cyclomatic 36): cli_handlers.cmd_alpha_show has cyclomatic complexity 36 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/cli_handlers.py"},"region":{"startLine":302}}}],"partialFingerprints":{"codehealthFindingId/v1":"acce6118595c0537849f4e0f59203f971928e5fa9a339e7df63e97d281bc42dc"}},{"ruleId":"D1","level":"warning","message":{"text":"session_5m.match_orders_5m (cyclomatic 36): session_5m.match_orders_5m has cyclomatic complexity 36 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/paper_trade/session_5m.py"},"region":{"startLine":141}}}],"partialFingerprints":{"codehealthFindingId/v1":"9dd7c31703b30888450089d071f85c56ffd458d253613a6e515d09faa0ad095e"}},{"ruleId":"D1","level":"warning","message":{"text":"tool._execute_step (cyclomatic 36): tool._execute_step has cyclomatic complexity 36 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/paper_trade/tool.py"},"region":{"startLine":229}}}],"partialFingerprints":{"codehealthFindingId/v1":"1dce7c4f9a1e925b67009c13c5ef45d328a685d3f4ea5bf05d909eced63a63b0"}},{"ruleId":"D1","level":"warning","message":{"text":"symbol_search_tool._search_selected_connector (cyclomatic 36): symbol_search_tool._search_selected_connector has cyclomatic complexity 36 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/symbol_search_tool.py"},"region":{"startLine":573}}}],"partialFingerprints":{"codehealthFindingId/v1":"e2d6b48f01f4eb88b393fe0a5d1afa14ed42ba5290e7196e789bae82045d6513"}},{"ruleId":"D1","level":"warning","message":{"text":"FeishuChannel._on_message (cyclomatic 35): FeishuChannel._on_message 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/feishu.py"},"region":{"startLine":2261}}}],"partialFingerprints":{"codehealthFindingId/v1":"d6305f9f8095800c202e42b15a84089daae61cd64e557f933b620d49fae6df99"}},{"ruleId":"D1","level":"warning","message":{"text":"WhatsAppChannel._handle_neonize_message (cyclomatic 35): WhatsAppChannel._handle_neonize_message has cyclomatic complexity 35 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/whatsapp.py"},"region":{"startLine":503}}}],"partialFingerprints":{"codehealthFindingId/v1":"377e35e053a39dc7c58ce1d5b3b7fd64e7fdf958077e3119ead78dbe61d38267"}},{"ruleId":"D1","level":"warning","message":{"text":"BaseEngine.run_backtest (cyclomatic 34): BaseEngine.run_backtest has cyclomatic complexity 34 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/engines/base.py"},"region":{"startLine":981}}}],"partialFingerprints":{"codehealthFindingId/v1":"d2aec755228e6c1d06b43419d76f7422ea4bc4f9dc87fa5fb64e6033eba579ef"}},{"ruleId":"D1","level":"warning","message":{"text":"ChatLLM._parse_response (cyclomatic 34): ChatLLM._parse_response has cyclomatic complexity 34 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/providers/chat.py"},"region":{"startLine":677}}}],"partialFingerprints":{"codehealthFindingId/v1":"ab2ec1c3a59778126f7312646deecdbd6a3c12e75cf95382f764298b03894724"}},{"ruleId":"D1","level":"warning","message":{"text":"alpha_bench_tool.run_alpha_bench (cyclomatic 34): alpha_bench_tool.run_alpha_bench has cyclomatic complexity 34 (threshold 15). To reduce it, separate the branches: extract each independent case into its own named function so the top-level body reads as a short sequence of named decisions."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/alpha_bench_tool.py"},"region":{"startLine":1270}}}],"partialFingerprints":{"codehealthFindingId/v1":"f3cfb1a6d1d74b4e0246b89474e851904e9aa4ad74f2b45ab07c7f3df97b9100"}},{"ruleId":"D1","level":"warning","message":{"text":"trade_journal_parsers._futu_datetime (cyclomatic 34): trade_journal_parsers._futu_datetime has cyclomatic complexity 34 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/trade_journal_parsers.py"},"region":{"startLine":473}}}],"partialFingerprints":{"codehealthFindingId/v1":"00c9939cb2e13ffc772b114c0dc0e0cc0124a62dd62205a889c5eed07ee1b7f0"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelConfigPanel.ChannelConfigPanel (cyclomatic 34): ChannelConfigPanel.ChannelConfigPanel has cyclomatic complexity 34 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top. This shape REPEATS in the file: one other method here (ChannelConfigPanel.ChannelConfigPanel::renderField) has the same decision points, in the same order, at the same nesting depths \u2014 so this is one pattern written twice rather than two separate problems. Splitting this body alone leaves the other exactly as it is. Where these are variations on one operation, the change that clears both is the shared one: lift the common shape into a single routine the variants call, parameterised by whatever genuinely differs between them, and keep in each method only the part that is not shared."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/settings/ChannelConfigPanel.tsx"},"region":{"startLine":193}}}],"partialFingerprints":{"codehealthFindingId/v1":"47f9be8a6188e16e6faa07f159ddda93c8cd0651e46b79e410fed013a21d8cf5"}},{"ruleId":"D1","level":"warning","message":{"text":"agent.useAgentStore (cyclomatic 34): agent.useAgentStore has cyclomatic complexity 34 (threshold 15). Most of this is not in the body itself: 1 of the 34 points is its own statement and the rest belongs to 19 function literals inside it that branch (lines 208, 141, 156, \u2026). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/stores/agent.ts"},"region":{"startLine":120}}}],"partialFingerprints":{"codehealthFindingId/v1":"96fd6ff72124aae1c25cb55c4eb93b99490b426add09aaf6c5a61d99fbac7032"}},{"ruleId":"D1","level":"warning","message":{"text":"EmailChannel._fetch_messages_once (cyclomatic 33): EmailChannel._fetch_messages_once has cyclomatic complexity 33 (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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/email.py"},"region":{"startLine":537}}}],"partialFingerprints":{"codehealthFindingId/v1":"ab65d5dcb35f104a44c76bd0c702b3a7e93811960f5894b9886b60e24dcce202"}},{"ruleId":"D1","level":"warning","message":{"text":"WebSocketChannel.send (cyclomatic 33): WebSocketChannel.send has cyclomatic complexity 33 (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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/websocket.py"},"region":{"startLine":884}}}],"partialFingerprints":{"codehealthFindingId/v1":"1529936d88642ef380f95737e5ba1a1ab018a8488a65d9b442cee8ab59b40b99"}},{"ruleId":"D1","level":"warning","message":{"text":"StrategyDiscoveryFacade.query_strategies (cyclomatic 33): StrategyDiscoveryFacade.query_strategies has cyclomatic complexity 33 (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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/strategy_discovery/facade.py"},"region":{"startLine":417}}}],"partialFingerprints":{"codehealthFindingId/v1":"5713300bbfd05d1cfd22c975a8389d60487c24799b2ac51cad5beee4f2d44044"}},{"ruleId":"D1","level":"warning","message":{"text":"data_refs.resolve_data_refs (cyclomatic 33): data_refs.resolve_data_refs has cyclomatic complexity 33 (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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/data_refs.py"},"region":{"startLine":12}}}],"partialFingerprints":{"codehealthFindingId/v1":"74e37ba3cbcdc445afb65d6debce8c21b902060fb20f4ad426e90784898669c4"}},{"ruleId":"D1","level":"warning","message":{"text":"SymbolSearchTool.execute (cyclomatic 33): SymbolSearchTool.execute has cyclomatic complexity 33 (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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/symbol_search_tool.py"},"region":{"startLine":263}}}],"partialFingerprints":{"codehealthFindingId/v1":"0ec5a9aa55836b3fe6f2fe6b27f41062918d801a129dd38ff5ba370a4d267a89"}},{"ruleId":"D1","level":"warning","message":{"text":"TechnicalIndicatorTool.execute (cyclomatic 33): TechnicalIndicatorTool.execute has cyclomatic complexity 33 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/technical_indicator_tool.py"},"region":{"startLine":322}}}],"partialFingerprints":{"codehealthFindingId/v1":"fd0816252144c532f7c8afa1e901b714457a9355c71ffd233329003818514830"}},{"ruleId":"D1","level":"warning","message":{"text":"FactorResearchPanel.FactorResearchPanel (cyclomatic 33): FactorResearchPanel.FactorResearchPanel has cyclomatic complexity 33 (threshold 15). Most of this is not in the body itself: 12 of the 33 points are its own statements and the rest belongs to 9 function literals inside it that branch (lines 113, 175, 93, \u2026). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/charts/FactorResearchPanel.tsx"},"region":{"startLine":84}}}],"partialFingerprints":{"codehealthFindingId/v1":"c951efbb36b2ad2866015767b68678060ccacdd35dd2290174e7739616338476"}},{"ruleId":"D1","level":"warning","message":{"text":"HistoryStorageSettings.HistoryStorageSettings (cyclomatic 33): HistoryStorageSettings.HistoryStorageSettings has cyclomatic complexity 33 (threshold 15). Most of this is not in the body itself: 9 of the 33 points are its own statements and the rest belongs to 6 function items inside it that branch (a function literal at line 53, a function literal at line 130, act, \u2026). The named helpers are already separate functions; the literals\u0027 work cannot be called, reviewed or tested from outside this body. To reduce it, move the named helpers out of the body to the enclosing scope and lift each literal\u0027s work into a named function there, so each is measured, reviewed and tested on its own, and reduce whichever one then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/settings/HistoryStorageSettings.tsx"},"region":{"startLine":9}}}],"partialFingerprints":{"codehealthFindingId/v1":"8c509047fd744bfae04d51311511e8c67666d6cc0f81cbe8f043ac1b2cdfbbe5"}},{"ruleId":"D1","level":"warning","message":{"text":"PaperTrading.PaperTrading (cyclomatic 33): PaperTrading.PaperTrading has cyclomatic complexity 33 (threshold 15). Most of this is not in the body itself: 13 of the 33 points are its own statements and the rest belongs to 15 function items inside it that branch (advance, a function literal at line 44, a function literal at line 47, \u2026). The named helpers are already separate functions; the literals\u0027 work cannot be called, reviewed or tested from outside this body. To reduce it, move the named helpers out of the body to the enclosing scope and lift each literal\u0027s work into a named function there, so each is measured, reviewed and tested on its own, and reduce whichever one then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/PaperTrading.tsx"},"region":{"startLine":18}}}],"partialFingerprints":{"codehealthFindingId/v1":"f35aaf34dc595c42d6f427b23698cbbe6fce2e078ce8fb8b484aa2ae5f71abd6"}},{"ruleId":"D1","level":"warning","message":{"text":"AgentLoop._auto_compact (cyclomatic 32): AgentLoop._auto_compact has cyclomatic complexity 32 (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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/agent/loop.py"},"region":{"startLine":1428}}}],"partialFingerprints":{"codehealthFindingId/v1":"88d1a7ced689818336a674a89176c9ae596cdf7cb3c41ffae633ccaf3c4f9ba2"}},{"ruleId":"D1","level":"warning","message":{"text":"WeixinChannel.send (cyclomatic 32): WeixinChannel.send has cyclomatic complexity 32 (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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/weixin.py"},"region":{"startLine":1090}}}],"partialFingerprints":{"codehealthFindingId/v1":"1b8840f94f86f434d5505755320204f697297d3b48e7b3d2f5fc63a8d05641d2"}},{"ruleId":"D1","level":"warning","message":{"text":"tools.build_registry (cyclomatic 32): tools.build_registry has cyclomatic complexity 32 (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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/__init__.py"},"region":{"startLine":77}}}],"partialFingerprints":{"codehealthFindingId/v1":"e0114c0a8eecc14ffe15b77f38bd543bedef213e4f75ead560d1c61f5db903b2"}},{"ruleId":"D1","level":"warning","message":{"text":"AddGoalEvidenceTool.execute (cyclomatic 32): AddGoalEvidenceTool.execute has cyclomatic complexity 32 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/goal_tool.py"},"region":{"startLine":491}}}],"partialFingerprints":{"codehealthFindingId/v1":"c023444cf8ac2fe9a7b63a720ad160ffe1529eeee34279eb3d21c869e71aa631"}},{"ruleId":"D1","level":"warning","message":{"text":"PositionsTab.PositionsTab (cyclomatic 32): PositionsTab.PositionsTab has cyclomatic complexity 32 (threshold 15). Most of this is not in the body itself: 8 of the 32 points are its own statements and the rest belongs to 11 function items inside it that branch (a function literal at line 175, handleResolve, a function literal at line 161, \u2026). The named helpers are already separate functions; the literals\u0027 work cannot be called, reviewed or tested from outside this body. To reduce it, move the named helpers out of the body to the enclosing scope and lift each literal\u0027s work into a named function there, so each is measured, reviewed and tested on its own, and reduce whichever one then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/run/PositionsTab.tsx"},"region":{"startLine":98}}}],"partialFingerprints":{"codehealthFindingId/v1":"7ddb7fe3a7250332c14cee5a832d2e0bdbc2eb37bc9c0bbc09c22b1be3fb22b3"}},{"ruleId":"D1","level":"warning","message":{"text":"options.buildPayoffRequest (cyclomatic 32): options.buildPayoffRequest has cyclomatic complexity 32 (threshold 15). Of this number, 31 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/lib/options.ts"},"region":{"startLine":373}}}],"partialFingerprints":{"codehealthFindingId/v1":"de7471799a419c8cd3dfaf8fd343aab80db5a44fa2400784b5f036d05f37e7bd"}},{"ruleId":"D1","level":"warning","message":{"text":"metrics.calc_metrics (cyclomatic 31): metrics.calc_metrics has cyclomatic complexity 31 (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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/metrics.py"},"region":{"startLine":606}}}],"partialFingerprints":{"codehealthFindingId/v1":"8cec82f8700c0661ed331bd911ce4ef72493533fc48887c7b0f0dcf6eb48c78a"}},{"ruleId":"D1","level":"warning","message":{"text":"main._interactive_loop (cyclomatic 31): main._interactive_loop has cyclomatic complexity 31 (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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/main.py"},"region":{"startLine":1303}}}],"partialFingerprints":{"codehealthFindingId/v1":"da81941039dfe28d4e5da805f69e6784f4fe0adc75177dcd8ec446805c9bb723"}},{"ruleId":"D1","level":"warning","message":{"text":"WebSocketChannel._dispatch_envelope (cyclomatic 31): WebSocketChannel._dispatch_envelope has cyclomatic complexity 31 (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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/websocket.py"},"region":{"startLine":672}}}],"partialFingerprints":{"codehealthFindingId/v1":"c351b75c13c24bf886c89b8a33b287618c8bf19d4a209e79c94c9d81d1297406"}},{"ruleId":"D1","level":"warning","message":{"text":"combination.combine_factors (cyclomatic 31): combination.combine_factors has cyclomatic complexity 31 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/combination.py"},"region":{"startLine":323}}}],"partialFingerprints":{"codehealthFindingId/v1":"f2f56d3c54d52a35ef92d02ed8b532baca6199aa77b44d5a51e45908c9befa77"}},{"ruleId":"D1","level":"warning","message":{"text":"OptionsChainTable.OptionsChainTable (cyclomatic 31): OptionsChainTable.OptionsChainTable has cyclomatic complexity 31 (threshold 15). Of this number, 17 points are the body\u0027s own statements and 14 belong to 5 function items inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/options/OptionsChainTable.tsx"},"region":{"startLine":139}}}],"partialFingerprints":{"codehealthFindingId/v1":"84034c1382f164258d48c7d33f3a3f7ea197daccf435f882ac65d49663c48ff7"}},{"ruleId":"D1","level":"warning","message":{"text":"argentina_equity._field_problems (cyclomatic 30): argentina_equity._field_problems has cyclomatic complexity 30 (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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/engines/argentina_equity.py"},"region":{"startLine":872}}}],"partialFingerprints":{"codehealthFindingId/v1":"6a8863857e379ef0cfe232eac136baf1e9b89b7d5e480017e05727edeba26032"}},{"ruleId":"D1","level":"warning","message":{"text":"BaseEngine._execute_target_rebalance (cyclomatic 30): BaseEngine._execute_target_rebalance has cyclomatic complexity 30 (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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/engines/base.py"},"region":{"startLine":1799}}}],"partialFingerprints":{"codehealthFindingId/v1":"a793489f70ea26d0e52e09f7ffcd9a68c5e7faa3f78f721054262a250edb88ea"}},{"ruleId":"D1","level":"warning","message":{"text":"_RunDashboard.handle_event (cyclomatic 30): _RunDashboard.handle_event has cyclomatic complexity 30 (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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":604}}}],"partialFingerprints":{"codehealthFindingId/v1":"9784b5160829110e2889e0e0ca69a9d61e35c331a49e76a32bb197d647eb8406"}},{"ruleId":"D1","level":"warning","message":{"text":"feishu._extract_interactive_content (cyclomatic 30): feishu._extract_interactive_content has cyclomatic complexity 30 (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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/feishu.py"},"region":{"startLine":133}}}],"partialFingerprints":{"codehealthFindingId/v1":"ab1aaf3688fba5c12cc7385f0fcaf7295be6aa4cdffd5075dc216e66018a4e81"}},{"ruleId":"D1","level":"warning","message":{"text":"PersistentMemory.find_relevant (cyclomatic 30): PersistentMemory.find_relevant has cyclomatic complexity 30 (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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/memory/persistent.py"},"region":{"startLine":366}}}],"partialFingerprints":{"codehealthFindingId/v1":"758527e7a68deb33d2e0f47653377574a01899d258de586f9e536e6fbf49dd22"}},{"ruleId":"D1","level":"warning","message":{"text":"ResearchPapersTool.execute (cyclomatic 30): ResearchPapersTool.execute has cyclomatic complexity 30 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/research_papers_tool.py"},"region":{"startLine":1559}}}],"partialFingerprints":{"codehealthFindingId/v1":"bb7cdad48d6fa81c518ca62efb1c8f03a2cc0fc085738f87f0a829090a9df594"}},{"ruleId":"D1","level":"warning","message":{"text":"sdk.place_order (cyclomatic 30): sdk.place_order has cyclomatic complexity 30 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/alpaca/sdk.py"},"region":{"startLine":460}}}],"partialFingerprints":{"codehealthFindingId/v1":"d1d0ed90fb2920c9af50beb7c0ec4898e29f48df404aeee6fb9da9f556ee458e"}},{"ruleId":"D1","level":"warning","message":{"text":"sdk.place_order (cyclomatic 30): sdk.place_order has cyclomatic complexity 30 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/tiger/sdk.py"},"region":{"startLine":335}}}],"partialFingerprints":{"codehealthFindingId/v1":"67d7a9063a8fdad7ab9ed12e87a0bc2924ed4c6f10be1ebd1fbe4bdde715b332"}},{"ruleId":"D1","level":"warning","message":{"text":"local_plugins.parse_manifest (cyclomatic 30): local_plugins.parse_manifest has cyclomatic complexity 30 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/local_plugins.py"},"region":{"startLine":108}}}],"partialFingerprints":{"codehealthFindingId/v1":"c43754a4b3d0b22a7173785e80a673c1785497aa5ec270d50facb3fba9f719c3"}},{"ruleId":"D1","level":"warning","message":{"text":"StrategyResearchDashboard.StrategyResearchDashboard (cyclomatic 30): StrategyResearchDashboard.StrategyResearchDashboard has cyclomatic complexity 30 (threshold 15). Most of this is not in the body itself: 14 of the 30 points are its own statements and the rest belongs to 9 function literals inside it that branch (lines 140, 129, 195, \u2026). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/charts/StrategyResearchDashboard.tsx"},"region":{"startLine":122}}}],"partialFingerprints":{"codehealthFindingId/v1":"21f108c220e20f534943db587f901be4ae7c35e4a1f1c823de473cc0295413c5"}},{"ruleId":"D1","level":"warning","message":{"text":"Reports.Reports (cyclomatic 30): Reports.Reports has cyclomatic complexity 30 (threshold 15). Most of this is not in the body itself: 14 of the 30 points are its own statements and the rest belongs to 5 function items inside it that branch (a function literal at line 66, loadReports, a function literal at line 60, \u2026). The named helpers are already separate functions; the literals\u0027 work cannot be called, reviewed or tested from outside this body. To reduce it, move the named helpers out of the body to the enclosing scope and lift each literal\u0027s work into a named function there, so each is measured, reviewed and tested on its own, and reduce whichever one then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Reports.tsx"},"region":{"startLine":23}}}],"partialFingerprints":{"codehealthFindingId/v1":"ce2f5b4fd1decb4dd893310720568a7a99a2e0ed806359285c394f3238fa161d"}},{"ruleId":"D1","level":"warning","message":{"text":"binance_shadow_evidence._validate_evidence (cyclomatic 29): binance_shadow_evidence._validate_evidence has cyclomatic complexity 29 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/binance_shadow_evidence.py"},"region":{"startLine":262}}}],"partialFingerprints":{"codehealthFindingId/v1":"377da188740269e544d2eb43cdec6e73f5ff6c8fa6a7a3b3ecc9d0b200a19951"}},{"ruleId":"D1","level":"warning","message":{"text":"run_card._model_provenance (cyclomatic 29): run_card._model_provenance has cyclomatic complexity 29 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/run_card.py"},"region":{"startLine":47}}}],"partialFingerprints":{"codehealthFindingId/v1":"988be4619dddbe20da8cfc4efd2d5695108a70e9bc53a8bee4e03d367cf19549"}},{"ruleId":"D1","level":"warning","message":{"text":"_legacy._print_connector_account (cyclomatic 29): _legacy._print_connector_account has cyclomatic complexity 29 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":4847}}}],"partialFingerprints":{"codehealthFindingId/v1":"951fb4506f7986ae6759a1172f8793bb88fc9e6e16c86760bd06f34f05f7253b"}},{"ruleId":"D1","level":"warning","message":{"text":"rail._result_summary (cyclomatic 29): rail._result_summary has cyclomatic complexity 29 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/ui/rail.py"},"region":{"startLine":125}}}],"partialFingerprints":{"codehealthFindingId/v1":"ce625136ee2a5b6e841262af5ddddcc231e8ce44e395e07f01467410b045996c"}},{"ruleId":"D1","level":"warning","message":{"text":"_EvidenceMixin._ingest_engine_table (cyclomatic 29): _EvidenceMixin._ingest_engine_table has cyclomatic complexity 29 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/grounding/evidence.py"},"region":{"startLine":1199}}}],"partialFingerprints":{"codehealthFindingId/v1":"4e816e93d035cebc3e24b3dc4537465b9b305eddffa6424501a5c7b033acfa51"}},{"ruleId":"D1","level":"warning","message":{"text":"measurements.measurement_verdicts (cyclomatic 29): measurements.measurement_verdicts has cyclomatic complexity 29 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/harness/measurements.py"},"region":{"startLine":55}}}],"partialFingerprints":{"codehealthFindingId/v1":"e3354699b9dcbe8f835e3789c00384bcfc3b55549b1329aa5f0224a7751a6a0f"}},{"ruleId":"D1","level":"warning","message":{"text":"MSTeamsChannel._handle_activity (cyclomatic 29): MSTeamsChannel._handle_activity has cyclomatic complexity 29 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/msteams.py"},"region":{"startLine":331}}}],"partialFingerprints":{"codehealthFindingId/v1":"10e47098f9b27626a99397289fa37d07d5c90bc37a086fdc1f2c17842a6764a0"}},{"ruleId":"D1","level":"warning","message":{"text":"ingest.load_cashflows (cyclomatic 29): ingest.load_cashflows has cyclomatic complexity 29 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/entities/ingest.py"},"region":{"startLine":365}}}],"partialFingerprints":{"codehealthFindingId/v1":"38351b0d813f0dff9a02219d20d8bf39f14b7addd5ca6a7d89820c0384308181"}},{"ruleId":"D1","level":"warning","message":{"text":"config.parse_settings (cyclomatic 29): config.parse_settings has cyclomatic complexity 29 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/portfolio/config.py"},"region":{"startLine":144}}}],"partialFingerprints":{"codehealthFindingId/v1":"b5ea5c99fbf52455d946655229c7c61657e21716355dab06d507357ddc75402f"}},{"ruleId":"D1","level":"warning","message":{"text":"FinancialRigorTool.execute (cyclomatic 29): FinancialRigorTool.execute has cyclomatic complexity 29 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/financial_rigor_tool.py"},"region":{"startLine":549}}}],"partialFingerprints":{"codehealthFindingId/v1":"d68aeba78f0273b19be38ca2e5f03b8f79e79758f45dae043cb12d23d21529b1"}},{"ruleId":"D1","level":"warning","message":{"text":"SourcePrioritySettings.SourcePrioritySettings (cyclomatic 29): SourcePrioritySettings.SourcePrioritySettings has cyclomatic complexity 29 (threshold 15). Most of this is not in the body itself: 13 of the 29 points are its own statements and the rest belongs to 10 function items inside it that branch (submit, a function literal at line 66, a function literal at line 72, \u2026). The named helpers are already separate functions; the literals\u0027 work cannot be called, reviewed or tested from outside this body. To reduce it, move the named helpers out of the body to the enclosing scope and lift each literal\u0027s work into a named function there, so each is measured, reviewed and tested on its own, and reduce whichever one then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/settings/SourcePrioritySettings.tsx"},"region":{"startLine":24}}}],"partialFingerprints":{"codehealthFindingId/v1":"0e7ec8ca7ab2ec7adb618c7ac2cd24547d66ec75c078a7a735f3c6478a380bd1"}},{"ruleId":"D1","level":"warning","message":{"text":"_legacy._print_portfolio_snapshot (cyclomatic 28): _legacy._print_portfolio_snapshot has cyclomatic complexity 28 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":4108}}}],"partialFingerprints":{"codehealthFindingId/v1":"c2ec5c47de9882a2ba2a8671526cabdf901c072749e188e9be1d64929dcbb05f"}},{"ruleId":"D1","level":"warning","message":{"text":"_legacy.cmd_connector_positions (cyclomatic 28): _legacy.cmd_connector_positions has cyclomatic complexity 28 (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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":4941}}}],"partialFingerprints":{"codehealthFindingId/v1":"e51ecd8f0949b06e58695e4f08fbb2c1e173cebfe3629164ae0a3b3bd6579a5d"}},{"ruleId":"D1","level":"warning","message":{"text":"assertions._budget_verdicts (cyclomatic 28): assertions._budget_verdicts has cyclomatic complexity 28 (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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/harness/assertions.py"},"region":{"startLine":535}}}],"partialFingerprints":{"codehealthFindingId/v1":"a627e9a175aa3b137f168c74af8c5bcbe9d807acbe6ff33836452b67aff00329"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelRuntime._handle_inbound (cyclomatic 28): ChannelRuntime._handle_inbound has cyclomatic complexity 28 (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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/runtime.py"},"region":{"startLine":122}}}],"partialFingerprints":{"codehealthFindingId/v1":"941c8dad66a085f3c7fb037901fc63a4ce0025bd3acfa76500ee581f4016b42b"}},{"ruleId":"D1","level":"warning","message":{"text":"history_router.fetch_chunk (cyclomatic 28): history_router.fetch_chunk has cyclomatic complexity 28 (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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/data_gateway/history_router.py"},"region":{"startLine":296}}}],"partialFingerprints":{"codehealthFindingId/v1":"3b07b9469584d8a059538e2e66edb99b36be3be4e49fc55d695776ff79cd4145"}},{"ruleId":"D1","level":"warning","message":{"text":"cli_handlers.cmd_alpha_list (cyclomatic 28): cli_handlers.cmd_alpha_list has cyclomatic complexity 28 (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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/cli_handlers.py"},"region":{"startLine":188}}}],"partialFingerprints":{"codehealthFindingId/v1":"ebeba63cd29314e37b39a8a63ea31dbb7b9cc5d2bea7ddcbe698bb7ad16d6cc9"}},{"ruleId":"D1","level":"warning","message":{"text":"neutralization.neutralize_factor (cyclomatic 28): neutralization.neutralize_factor has cyclomatic complexity 28 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/neutralization.py"},"region":{"startLine":204}}}],"partialFingerprints":{"codehealthFindingId/v1":"42def09044c11f138fddd47fab00f3115debefe46c24d440c9593b4eb5d01970"}},{"ruleId":"D1","level":"warning","message":{"text":"etf_holdings_tool._parse_cn_period (cyclomatic 28): etf_holdings_tool._parse_cn_period has cyclomatic complexity 28 (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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/etf_holdings_tool.py"},"region":{"startLine":892}}}],"partialFingerprints":{"codehealthFindingId/v1":"54f98618c1ff8eeb5412fa048f479285c4f780680b36f0840793de9a42688d3c"}},{"ruleId":"D1","level":"warning","message":{"text":"etf_holdings_tool._holdings_cn (cyclomatic 28): etf_holdings_tool._holdings_cn has cyclomatic complexity 28 (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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/etf_holdings_tool.py"},"region":{"startLine":1491}}}],"partialFingerprints":{"codehealthFindingId/v1":"1e0b1516384db815b2332242f031c7dd7631e4d070e4752c1df346b827c67adf"}},{"ruleId":"D1","level":"warning","message":{"text":"ReadFileTool.execute (cyclomatic 28): ReadFileTool.execute has cyclomatic complexity 28 (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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/read_file_tool.py"},"region":{"startLine":107}}}],"partialFingerprints":{"codehealthFindingId/v1":"6aa0163b4d0a62bc5859e772f0157b956f6665b098e0c7bdd0c6a068c00f4f18"}},{"ruleId":"D1","level":"warning","message":{"text":"ConnectionStore._parse (cyclomatic 28): ConnectionStore._parse has cyclomatic complexity 28 (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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connections.py"},"region":{"startLine":356}}}],"partialFingerprints":{"codehealthFindingId/v1":"0d265cddbc0b8ec4f8ad76f7651f67c1c3affd2d2eb031fbe2b7c60594c38921"}},{"ruleId":"D1","level":"warning","message":{"text":"sdk.place_order (cyclomatic 28): sdk.place_order has cyclomatic complexity 28 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/binance/sdk.py"},"region":{"startLine":527}}}],"partialFingerprints":{"codehealthFindingId/v1":"7affe9bdd6884af13b832bba128d3a29213aaedb603687224bc24f4bf9b49ef8"}},{"ruleId":"D1","level":"warning","message":{"text":"ConnectionCenter.ConnectionCenter (cyclomatic 28): ConnectionCenter.ConnectionCenter has cyclomatic complexity 28 (threshold 15). Most of this is not in the body itself: 8 of the 28 points are its own statements and the rest belongs to 8 function items inside it that branch (create, test, remove, \u2026). The named helpers are already separate functions; the literals\u0027 work cannot be called, reviewed or tested from outside this body. To reduce it, move the named helpers out of the body to the enclosing scope and lift each literal\u0027s work into a named function there, so each is measured, reviewed and tested on its own, and reduce whichever one then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/portfolio/ConnectionCenter.tsx"},"region":{"startLine":21}}}],"partialFingerprints":{"codehealthFindingId/v1":"ef1a5946c8d282b7331fb839fcfda250040d679899e43229ff587ac844d976f3"}},{"ruleId":"D1","level":"warning","message":{"text":"RunDetail.TradesTab (cyclomatic 28): RunDetail.TradesTab has cyclomatic complexity 28 (threshold 15). Most of this is not in the body itself: 11 of the 28 points are its own statements and the rest belongs to 4 function literals inside it that branch (lines 1112, 1020, 1053, \u2026). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/RunDetail.tsx"},"region":{"startLine":1001}}}],"partialFingerprints":{"codehealthFindingId/v1":"310964819c99e232dd65ce79aaac18d68b445e8be55832ec6a545fc6655cbf0f"}},{"ruleId":"D1","level":"warning","message":{"text":"Runtime.Runtime (cyclomatic 28): Runtime.Runtime has cyclomatic complexity 28 (threshold 15). Of this number, 17 points are the body\u0027s own statements and 11 belong to 2 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Runtime.tsx"},"region":{"startLine":25}}}],"partialFingerprints":{"codehealthFindingId/v1":"07b62fc8d232d8753e24cb0bef619772884c20b63aa4b3c0a45362c99a1f3ec3"}},{"ruleId":"D1","level":"warning","message":{"text":"_legacy._print_result (cyclomatic 27): _legacy._print_result has cyclomatic complexity 27 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":1411}}}],"partialFingerprints":{"codehealthFindingId/v1":"6abf43f1beb3c95eec6a50e05abd1fb409c0524aa5ee4842cc462a78b616f590"}},{"ruleId":"D1","level":"warning","message":{"text":"GroundingLedger.ingest_tool_result (cyclomatic 27): GroundingLedger.ingest_tool_result has cyclomatic complexity 27 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/grounding/ledger.py"},"region":{"startLine":121}}}],"partialFingerprints":{"codehealthFindingId/v1":"0c5bc3819d247a72289a37d754021aa63f05ca571e312a84beb2081a4f32be47"}},{"ruleId":"D1","level":"warning","message":{"text":"_PolicyMixin._artifact_scope (cyclomatic 27): _PolicyMixin._artifact_scope has cyclomatic complexity 27 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/grounding/policies.py"},"region":{"startLine":1059}}}],"partialFingerprints":{"codehealthFindingId/v1":"fdeb33712dcd6f6457950d30071016a2d6c49d29a8a2399ed36dfabac48e1af1"}},{"ruleId":"D1","level":"warning","message":{"text":"ToolCallLifecycle._finalize_tool_result (cyclomatic 27): ToolCallLifecycle._finalize_tool_result has cyclomatic complexity 27 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/agent/tool_lifecycle.py"},"region":{"startLine":938}}}],"partialFingerprints":{"codehealthFindingId/v1":"3959a05c27e319c620205568f043c963cfa4969ac3d9d805ed226bfb964f945c"}},{"ruleId":"D1","level":"warning","message":{"text":"attribution_core._build_attribution_payload (cyclomatic 27): attribution_core._build_attribution_payload has cyclomatic complexity 27 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/api/attribution_core.py"},"region":{"startLine":776}}}],"partialFingerprints":{"codehealthFindingId/v1":"9375f3fd5aad56f133b852c1c7c211147ccc89b1e324689d3ff7153ce3bcc182"}},{"ruleId":"D1","level":"warning","message":{"text":"TelegramChannel.send (cyclomatic 27): TelegramChannel.send has cyclomatic complexity 27 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/telegram.py"},"region":{"startLine":750}}}],"partialFingerprints":{"codehealthFindingId/v1":"25c539ba36884b47720ca1af7fb49149f12d3290044e798c1f28ef78e163d220"}},{"ruleId":"D1","level":"warning","message":{"text":"ResearchArtifactStore.save (cyclomatic 27): ResearchArtifactStore.save has cyclomatic complexity 27 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/research_artifacts/store.py"},"region":{"startLine":195}}}],"partialFingerprints":{"codehealthFindingId/v1":"60e1004ac7300414c6189598db1cb9e059c6a7bc1394ed5ab47a62967191eeb4"}},{"ruleId":"D1","level":"warning","message":{"text":"sdk.place_order (cyclomatic 27): sdk.place_order has cyclomatic complexity 27 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/futu/sdk.py"},"region":{"startLine":769}}}],"partialFingerprints":{"codehealthFindingId/v1":"4dd8e44f2fd6003df285e03ffed18a9d2d1b8531a27c05a5758a8821c657b745"}},{"ruleId":"D1","level":"warning","message":{"text":"_legacy.cmd_connector_setup (cyclomatic 26): _legacy.cmd_connector_setup has cyclomatic complexity 26 (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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":4463}}}],"partialFingerprints":{"codehealthFindingId/v1":"b7cae733e25b8f2cb5386499dc417d2fd0cf665e899e23c2c03fc740c8bd6563"}},{"ruleId":"D1","level":"warning","message":{"text":"_legacy._dispatch_connector (cyclomatic 26): _legacy._dispatch_connector has cyclomatic complexity 26 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":5327}}}],"partialFingerprints":{"codehealthFindingId/v1":"03fa8ad9a2bc337c0e0c25c7103705c15373857e5d7c880168fade3cbf588114"}},{"ruleId":"D1","level":"warning","message":{"text":"WeixinChannel._download_media_item (cyclomatic 26): WeixinChannel._download_media_item has cyclomatic complexity 26 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/weixin.py"},"region":{"startLine":831}}}],"partialFingerprints":{"codehealthFindingId/v1":"38322a367abf95cfa645423f789c7047db80ec909be35560ae6663bd49e6307d"}},{"ruleId":"D1","level":"warning","message":{"text":"history_router._normalize (cyclomatic 26): history_router._normalize has cyclomatic complexity 26 (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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/data_gateway/history_router.py"},"region":{"startLine":222}}}],"partialFingerprints":{"codehealthFindingId/v1":"3f09ede135dce687f5a2a8abb288dc22140eb1b0438d02ff0908eb5b84283e9a"}},{"ruleId":"D1","level":"warning","message":{"text":"PortfolioService.refresh (cyclomatic 26): PortfolioService.refresh has cyclomatic complexity 26 (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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/portfolio/service.py"},"region":{"startLine":303}}}],"partialFingerprints":{"codehealthFindingId/v1":"389dbb00bbde9f456a91a787378fc03b9069a407d6ef0e7025a70c5039125ea5"}},{"ruleId":"D1","level":"warning","message":{"text":"evidence_harness.compute_evidence_for_run (cyclomatic 26): evidence_harness.compute_evidence_for_run has cyclomatic complexity 26 (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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/strategy_discovery/evidence_harness.py"},"region":{"startLine":411}}}],"partialFingerprints":{"codehealthFindingId/v1":"32e60ecb6ec46d415c4cfe140855b3cc0e3f77557b90135cd0e823d96b510380"}},{"ruleId":"D1","level":"warning","message":{"text":"InstitutionalHoldingsTool._ticker_holders (cyclomatic 26): InstitutionalHoldingsTool._ticker_holders has cyclomatic complexity 26 (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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/institutional_holdings_tool.py"},"region":{"startLine":2000}}}],"partialFingerprints":{"codehealthFindingId/v1":"7f04bb92bf686105717a49bc21c33c64125a81f7e410da9e2d41c22d356cb417"}},{"ruleId":"D1","level":"warning","message":{"text":"RunCompleteCard.RunCompleteCard (cyclomatic 26): RunCompleteCard.RunCompleteCard has cyclomatic complexity 26 (threshold 15). Of this number, 13 points are the body\u0027s own statements and 13 belong to 6 function literals inside it that branch. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/chat/RunCompleteCard.tsx"},"region":{"startLine":25}}}],"partialFingerprints":{"codehealthFindingId/v1":"bc0ea6bd5cc8ab5b33156e895abdafef305d2b7dc9de4e5a638dd36533b478f9"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelConfigPanel.ChannelConfigPanel::renderField (cyclomatic 26): ChannelConfigPanel.ChannelConfigPanel::renderField has cyclomatic complexity 26 (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. This shape REPEATS in the file: one other method here (ChannelConfigPanel.ChannelConfigPanel) has the same decision points, in the same order, at the same nesting depths \u2014 so this is one pattern written twice rather than two separate problems. Splitting this body alone leaves the other exactly as it is. Where these are variations on one operation, the change that clears both is the shared one: lift the common shape into a single routine the variants call, parameterised by whatever genuinely differs between them, and keep in each method only the part that is not shared."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/settings/ChannelConfigPanel.tsx"},"region":{"startLine":534}}}],"partialFingerprints":{"codehealthFindingId/v1":"df425a718b1f04f2478209f82f515432f6459252c495ac119e6aa6f64f9a091d"}},{"ruleId":"D1","level":"warning","message":{"text":"useAlphaJob.useAlphaJob.connect (cyclomatic 26): useAlphaJob.useAlphaJob.connect has cyclomatic complexity 26 (threshold 15). Most of this is not in the body itself: 10 of the 26 points are its own statements and the rest belongs to 7 function literals inside it that branch (lines 50, 60, 37, \u2026). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/hooks/useAlphaJob.ts"},"region":{"startLine":19}}}],"partialFingerprints":{"codehealthFindingId/v1":"36aa0837c466e2b97acfe45d3df90f8372424a6366e77f50ead4c31eecf0579d"}},{"ruleId":"D1","level":"warning","message":{"text":"AlphaZoo.BenchView (cyclomatic 26): AlphaZoo.BenchView has cyclomatic complexity 26 (threshold 15). Of this number, 16 points are the body\u0027s own statements and 10 belong to 3 function items inside it that branch. To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/AlphaZoo.tsx"},"region":{"startLine":641}}}],"partialFingerprints":{"codehealthFindingId/v1":"10e2774f1bf7f37cf7d50a230885ff9a2ab41596cea982a3d660825319de3ffa"}},{"ruleId":"D1","level":"warning","message":{"text":"base._read_loader_cache_frame (cyclomatic 25): base._read_loader_cache_frame has cyclomatic complexity 25 (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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/base.py"},"region":{"startLine":741}}}],"partialFingerprints":{"codehealthFindingId/v1":"e5beda1795e2d0fec97201e74353ed19f8e269eeac54d82d813d48f2e02ed458"}},{"ruleId":"D1","level":"warning","message":{"text":"tushare_fundamentals.enrich_price_frames_with_fundamentals (cyclomatic 25): tushare_fundamentals.enrich_price_frames_with_fundamentals has cyclomatic complexity 25 (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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/tushare_fundamentals.py"},"region":{"startLine":313}}}],"partialFingerprints":{"codehealthFindingId/v1":"1ccd923b5d58eaded6a99a248056a9acffb67cb85d4af0f22c6808b14944a957"}},{"ruleId":"D1","level":"warning","message":{"text":"_legacy.cmd_connector_check (cyclomatic 25): _legacy.cmd_connector_check has cyclomatic complexity 25 (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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":4376}}}],"partialFingerprints":{"codehealthFindingId/v1":"8984051d9cbb7d1a2d88ed0fa402f145e1c32ac706e7c739a48957875468a481"}},{"ruleId":"D1","level":"warning","message":{"text":"figures._numbers (cyclomatic 25): figures._numbers has cyclomatic complexity 25 (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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/grounding/figures.py"},"region":{"startLine":483}}}],"partialFingerprints":{"codehealthFindingId/v1":"9c94deafbb8c1bf5500c1679ed67abeff381e3db399a490ca7af946e00143840"}},{"ruleId":"D1","level":"warning","message":{"text":"FeishuChannel.send (cyclomatic 25): FeishuChannel.send has cyclomatic complexity 25 (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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/feishu.py"},"region":{"startLine":2037}}}],"partialFingerprints":{"codehealthFindingId/v1":"e3aa2a0f6e8a4423ba2612fac9ad8849cd33b05129f7d561bc7c8c162040fa7a"}},{"ruleId":"D1","level":"warning","message":{"text":"history_router.plan (cyclomatic 25): history_router.plan has cyclomatic complexity 25 (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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/data_gateway/history_router.py"},"region":{"startLine":113}}}],"partialFingerprints":{"codehealthFindingId/v1":"aa14c3b9022c9c036ba51d8e01094535e345c3d5409c20d605e39a403b2369c8"}},{"ruleId":"D1","level":"warning","message":{"text":"PendingAction.validate_evidence (cyclomatic 25): PendingAction.validate_evidence has cyclomatic complexity 25 (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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/live/pending_action.py"},"region":{"startLine":161}}}],"partialFingerprints":{"codehealthFindingId/v1":"845d77db76fe35f0ab5b1fc5891be6e8ea2ff67165ba4ad89172e31df40a6f13"}},{"ruleId":"D1","level":"warning","message":{"text":"SignalEngine._evaluate_signals (cyclomatic 25): SignalEngine._evaluate_signals has cyclomatic complexity 25 (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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/skills/chanlun/example_signal_engine.py"},"region":{"startLine":134}}}],"partialFingerprints":{"codehealthFindingId/v1":"d54f9b158daa269d1efef96fb1d904f47a5494ed996f84b357e3d5e33b5df95b"}},{"ruleId":"D1","level":"warning","message":{"text":"sdk.place_order (cyclomatic 25): sdk.place_order has cyclomatic complexity 25 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/kis/sdk.py"},"region":{"startLine":470}}}],"partialFingerprints":{"codehealthFindingId/v1":"2538b438010215f472b937f975ca2376f8bfe893d3f21575ba8bfe96a08330a2"}},{"ruleId":"D1","level":"warning","message":{"text":"tap_forward.forward (cyclomatic 25): tap_forward.forward has cyclomatic complexity 25 (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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/tap_forward.py"},"region":{"startLine":105}}}],"partialFingerprints":{"codehealthFindingId/v1":"2d33de7fb0846c0ee4cb085be63f3deafc8b58730fc79d20d07c0a234f89868a"}},{"ruleId":"D1","level":"warning","message":{"text":"api.errorFromResponse (cyclomatic 25): api.errorFromResponse has cyclomatic complexity 25 (threshold 15). Of this number, 18 points are the body\u0027s own statements and 7 belong to 2 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/lib/api.ts"},"region":{"startLine":403}}}],"partialFingerprints":{"codehealthFindingId/v1":"226742f6d4425cb5d27843a91ef1d7bfaa99c63589e510912e2b1c359286323c"}},{"ruleId":"D1","level":"warning","message":{"text":"Correlation.CorrelationAnalysis (cyclomatic 25): Correlation.CorrelationAnalysis has cyclomatic complexity 25 (threshold 15). Of this number, 15 points are the body\u0027s own statements and 10 belong to 4 function items inside it that branch. To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Correlation.tsx"},"region":{"startLine":44}}}],"partialFingerprints":{"codehealthFindingId/v1":"52925cdbc243f92c4fcc0068a49ee9de58f0be7631fe3cb4068be1e9b45e36c7"}},{"ruleId":"D1","level":"warning","message":{"text":"run_card._render_markdown (cyclomatic 24): run_card._render_markdown has cyclomatic complexity 24 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/run_card.py"},"region":{"startLine":521}}}],"partialFingerprints":{"codehealthFindingId/v1":"eeeb5e3ae19874edebf1aa73c6ab54a8f2276b44d5dd63a9745aee22669eac4c"}},{"ruleId":"D1","level":"warning","message":{"text":"runner._fetch_auto (cyclomatic 24): runner._fetch_auto has cyclomatic complexity 24 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/runner.py"},"region":{"startLine":1944}}}],"partialFingerprints":{"codehealthFindingId/v1":"11d8061456a5ec293ea86db00159305f35a9a089f67f338d9be478ed11f77ac0"}},{"ruleId":"D1","level":"warning","message":{"text":"validation.walk_forward_analysis (cyclomatic 24): validation.walk_forward_analysis has cyclomatic complexity 24 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/validation.py"},"region":{"startLine":246}}}],"partialFingerprints":{"codehealthFindingId/v1":"87bd19bf31dcb4325acfc1144978edd0c7156c92a9d87d8c83699750eebf1af4"}},{"ruleId":"D1","level":"warning","message":{"text":"_RunDashboard.render (cyclomatic 24): _RunDashboard.render has cyclomatic complexity 24 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":795}}}],"partialFingerprints":{"codehealthFindingId/v1":"509501d74018f338a0ed44bf9fd64fa4f2951f33192a78fc65225b953e30b2b4"}},{"ruleId":"D1","level":"warning","message":{"text":"assertions._identity_verdicts (cyclomatic 24): assertions._identity_verdicts has cyclomatic complexity 24 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/harness/assertions.py"},"region":{"startLine":349}}}],"partialFingerprints":{"codehealthFindingId/v1":"bf15b1688f2094c1a7683928fdaad6ee72acd8f574e5a26fa2fb69c3bcfd80a1"}},{"ruleId":"D1","level":"warning","message":{"text":"SlackChannel.send (cyclomatic 24): SlackChannel.send has cyclomatic complexity 24 (threshold 15). To reduce it, separate the branches: extract each independent case into its own named function so the top-level body reads as a short sequence of named decisions."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/slack.py"},"region":{"startLine":174}}}],"partialFingerprints":{"codehealthFindingId/v1":"e7ecf8415b80f56476179f95d3bf03687cf401b2749047b6aaac62421c63784d"}},{"ruleId":"D1","level":"warning","message":{"text":"MarketDataGateway._fetch (cyclomatic 24): MarketDataGateway._fetch has cyclomatic complexity 24 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/data_gateway/service.py"},"region":{"startLine":185}}}],"partialFingerprints":{"codehealthFindingId/v1":"7202b13db8768c1a0c3f601ef6a244108666e2d1361be9d61d8550aaa885e227"}},{"ruleId":"D1","level":"warning","message":{"text":"discovery._list_openai_codex_models (cyclomatic 24): discovery._list_openai_codex_models has cyclomatic complexity 24 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/providers/discovery.py"},"region":{"startLine":119}}}],"partialFingerprints":{"codehealthFindingId/v1":"f93b9f1ee0ce0643b86ffde2f6776c0f3a53a474de0e88c6cf8cecac2c99a915"}},{"ruleId":"D1","level":"warning","message":{"text":"portfolio.hierarchical_risk_parity (cyclomatic 24): portfolio.hierarchical_risk_parity has cyclomatic complexity 24 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/portfolio.py"},"region":{"startLine":102}}}],"partialFingerprints":{"codehealthFindingId/v1":"1a1252e24628fce3dc99a41d00a2b232e57830ffc03406232580d771563d94fb"}},{"ruleId":"D1","level":"warning","message":{"text":"evidence_handoff._observations (cyclomatic 24): evidence_handoff._observations has cyclomatic complexity 24 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/swarm/evidence_handoff.py"},"region":{"startLine":14}}}],"partialFingerprints":{"codehealthFindingId/v1":"94ba98257b28359194cb701e1f1d5ee4e3c482b430bd97d632d1d3d2a7791fbd"}},{"ruleId":"D1","level":"warning","message":{"text":"SwarmRuntime._apply_resume_overlay (cyclomatic 24): SwarmRuntime._apply_resume_overlay has cyclomatic complexity 24 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/swarm/runtime.py"},"region":{"startLine":783}}}],"partialFingerprints":{"codehealthFindingId/v1":"571fdb98bff58a4122b57f5cb3e1658aba51258ade8099e37e935a7e24a34098"}},{"ruleId":"D1","level":"warning","message":{"text":"OrderBookDepthTool.execute (cyclomatic 24): OrderBookDepthTool.execute has cyclomatic complexity 24 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/orderbook_depth_tool.py"},"region":{"startLine":348}}}],"partialFingerprints":{"codehealthFindingId/v1":"06a1b3df922e3a80ceb618c2b2d884b42088fa5439f9f935d0ae3c0c16e3bf1b"}},{"ruleId":"D1","level":"warning","message":{"text":"trade_journal_tool.pair_trades_fifo (cyclomatic 24): trade_journal_tool.pair_trades_fifo has cyclomatic complexity 24 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/trade_journal_tool.py"},"region":{"startLine":76}}}],"partialFingerprints":{"codehealthFindingId/v1":"57b2239836149afed7edc38a8c8dfb25862d8a1e27f0fbfe185ba94cfb8df1c0"}},{"ruleId":"D1","level":"warning","message":{"text":"SwarmStatusCard.SwarmStatusCard (cyclomatic 24): SwarmStatusCard.SwarmStatusCard has cyclomatic complexity 24 (threshold 15). Of this number, 14 points are the body\u0027s own statements and 10 belong to 4 function items inside it that branch. To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/chat/SwarmStatusCard.tsx"},"region":{"startLine":182}}}],"partialFingerprints":{"codehealthFindingId/v1":"10ee144aec18e6c71aff9ef69e25e35f541da4645251a9d9347f540ee8707933"}},{"ruleId":"D1","level":"warning","message":{"text":"ToolProgressIndicator.ToolRow (cyclomatic 24): ToolProgressIndicator.ToolRow has cyclomatic complexity 24 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/chat/ToolProgressIndicator.tsx"},"region":{"startLine":128}}}],"partialFingerprints":{"codehealthFindingId/v1":"36c944989ba88a78a4dde181f250d6062ed4b4badacf2d27a2177b9e791b4efb"}},{"ruleId":"D1","level":"warning","message":{"text":"VolatilitySurfaceGrid.VolatilitySurfaceGrid (cyclomatic 24): VolatilitySurfaceGrid.VolatilitySurfaceGrid has cyclomatic complexity 24 (threshold 15). Most of this is not in the body itself: 10 of the 24 points are its own statements and the rest belongs to 4 function items inside it that branch (compute, cellStyle, a function literal at line 46, \u2026). The named helpers are already separate functions; the literals\u0027 work cannot be called, reviewed or tested from outside this body. To reduce it, move the named helpers out of the body to the enclosing scope and lift each literal\u0027s work into a named function there, so each is measured, reviewed and tested on its own, and reduce whichever one then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/options/VolatilitySurfaceGrid.tsx"},"region":{"startLine":25}}}],"partialFingerprints":{"codehealthFindingId/v1":"ddbcb5165f6a729b789cf3d01ff1f85415778398a691902296f43b3d32f9b5c1"}},{"ruleId":"D1","level":"warning","message":{"text":"AlphaZoo.DetailView (cyclomatic 24): AlphaZoo.DetailView has cyclomatic complexity 24 (threshold 15). Of this number, 20 points are the body\u0027s own statements and 4 belong to 3 function literals inside it that branch. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/AlphaZoo.tsx"},"region":{"startLine":457}}}],"partialFingerprints":{"codehealthFindingId/v1":"596886ca7e3a6b9de9f87f21438b10f7ede8465b6e7755684a8d9b6f6b2db7e5"}},{"ruleId":"D1","level":"warning","message":{"text":"RunDetail.RunCardTab (cyclomatic 24): RunDetail.RunCardTab has cyclomatic complexity 24 (threshold 15). Of this number, 17 points are the body\u0027s own statements and 7 belong to 2 function literals inside it that branch. To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/RunDetail.tsx"},"region":{"startLine":477}}}],"partialFingerprints":{"codehealthFindingId/v1":"563e41e17b5580fef1f75d31ca03a183060c092b77baab510b28e976a1a77fa9"}},{"ruleId":"D1","level":"warning","message":{"text":"runner._reject_forbidden_node (cyclomatic 23): runner._reject_forbidden_node has cyclomatic complexity 23 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/runner.py"},"region":{"startLine":687}}}],"partialFingerprints":{"codehealthFindingId/v1":"75336f3e64dd0554e017606a5c89f9855859a657f209f89fdab8b37ce4747c50"}},{"ruleId":"D1","level":"warning","message":{"text":"runner._select_market_engine (cyclomatic 23): runner._select_market_engine has cyclomatic complexity 23 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/runner.py"},"region":{"startLine":1786}}}],"partialFingerprints":{"codehealthFindingId/v1":"73d6a57735261811562ba7285e98ebf13333dfa6c25be4d88fb1570b3063e5d1"}},{"ruleId":"D1","level":"warning","message":{"text":"_RunDashboard._render_progress_row (cyclomatic 23): _RunDashboard._render_progress_row has cyclomatic complexity 23 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":719}}}],"partialFingerprints":{"codehealthFindingId/v1":"c943e45f5981d57c55c6324843132bac2eb52fc46b0728d5d56329801abc8e7f"}},{"ruleId":"D1","level":"warning","message":{"text":"_SwarmDashboard.handle_event (cyclomatic 23): _SwarmDashboard.handle_event has cyclomatic complexity 23 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":2166}}}],"partialFingerprints":{"codehealthFindingId/v1":"81e31ebb2afea11a19ab15bffdcbc47c315ca64ab27be9b39b6ad52ffc3c5321"}},{"ruleId":"D1","level":"warning","message":{"text":"_legacy.cmd_trace (cyclomatic 23): _legacy.cmd_trace has cyclomatic complexity 23 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":2609}}}],"partialFingerprints":{"codehealthFindingId/v1":"4af729d089f0af2b74501ef9d11a16d32f6c5688ba90e4837f9e43c88e370219"}},{"ruleId":"D1","level":"warning","message":{"text":"figures.parse_figures_block (cyclomatic 23): figures.parse_figures_block has cyclomatic complexity 23 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/grounding/figures.py"},"region":{"startLine":821}}}],"partialFingerprints":{"codehealthFindingId/v1":"2cccd3b635a14291dab94cb2162ed0d8df9a97f20435af1d0710676362ea77ec"}},{"ruleId":"D1","level":"warning","message":{"text":"instrument_identity._infer_instrument_type (cyclomatic 23): instrument_identity._infer_instrument_type has cyclomatic complexity 23 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/agent/instrument_identity.py"},"region":{"startLine":345}}}],"partialFingerprints":{"codehealthFindingId/v1":"dfafb43257c9852818bf36e9e31be3fb04b97f6e34fcaee72c690bfd203c2730"}},{"ruleId":"D1","level":"warning","message":{"text":"result_artifacts.deliver_tool_result (cyclomatic 23): result_artifacts.deliver_tool_result has cyclomatic complexity 23 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/agent/result_artifacts.py"},"region":{"startLine":136}}}],"partialFingerprints":{"codehealthFindingId/v1":"35b37bf2b42323d27ec81666005078143c9cf6757fcc27d96b5722ca3376c992"}},{"ruleId":"D1","level":"warning","message":{"text":"write_targets.record_written_target (cyclomatic 23): write_targets.record_written_target has cyclomatic complexity 23 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/agent/write_targets.py"},"region":{"startLine":29}}}],"partialFingerprints":{"codehealthFindingId/v1":"f7c2a39a61a05870292e5146d74e63a434df2a0c3d57b930e407593d3fb39624"}},{"ruleId":"D1","level":"warning","message":{"text":"runs_routes._scan_factor_results (cyclomatic 23): runs_routes._scan_factor_results has cyclomatic complexity 23 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/api/runs_routes.py"},"region":{"startLine":288}}}],"partialFingerprints":{"codehealthFindingId/v1":"13989994b5de0cbce31b48f30f8991d4c147dc6f3ef4ae832e1ba54d7c7b98ba"}},{"ruleId":"D1","level":"warning","message":{"text":"FeishuChannel.send_delta (cyclomatic 23): FeishuChannel.send_delta has cyclomatic complexity 23 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/feishu.py"},"region":{"startLine":1881}}}],"partialFingerprints":{"codehealthFindingId/v1":"5335d466315d6933da89c288417cc59fcaa8d37bdae859133e69ba4a17e5eb05"}},{"ruleId":"D1","level":"warning","message":{"text":"QQChannel._download_to_media_dir_chunked (cyclomatic 23): QQChannel._download_to_media_dir_chunked has cyclomatic complexity 23 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/qq.py"},"region":{"startLine":660}}}],"partialFingerprints":{"codehealthFindingId/v1":"0e63406c29f95c847bb9f482e814b60250e114ddb6431605b9c273e9e3763e8a"}},{"ruleId":"D1","level":"warning","message":{"text":"sdk_order_gate._allow (cyclomatic 23): sdk_order_gate._allow has cyclomatic complexity 23 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/live/sdk_order_gate.py"},"region":{"startLine":434}}}],"partialFingerprints":{"codehealthFindingId/v1":"1f75c354703ea25ffc3640acfe988ec00e6bf0d0463f6f266041ed73f578f4f1"}},{"ruleId":"D1","level":"warning","message":{"text":"market_data._fetch_market_data_direct (cyclomatic 23): market_data._fetch_market_data_direct has cyclomatic complexity 23 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/market_data.py"},"region":{"startLine":220}}}],"partialFingerprints":{"codehealthFindingId/v1":"d97350321e3f085fac81dd7567b852d4a215e9ab37afb85c571e817f19bf58d3"}},{"ruleId":"D1","level":"warning","message":{"text":"adaptation_workflow.prepare_adaptation (cyclomatic 23): adaptation_workflow.prepare_adaptation has cyclomatic complexity 23 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/strategy_discovery/adaptation_workflow.py"},"region":{"startLine":18}}}],"partialFingerprints":{"codehealthFindingId/v1":"49e28cb33530ac2d7ebd01a82529eac64ff2615abd791b4fb6164b8575e07c12"}},{"ruleId":"D1","level":"warning","message":{"text":"run_artifacts.read_trade_activity (cyclomatic 23): run_artifacts.read_trade_activity has cyclomatic complexity 23 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/strategy_discovery/run_artifacts.py"},"region":{"startLine":128}}}],"partialFingerprints":{"codehealthFindingId/v1":"172f6d61cb0d563846cdd47d28ff4a3424588f62a3652417c823bc6b71be40a0"}},{"ruleId":"D1","level":"warning","message":{"text":"PredictionMarketTool.execute (cyclomatic 23): PredictionMarketTool.execute has cyclomatic complexity 23 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/prediction_market_tool.py"},"region":{"startLine":1120}}}],"partialFingerprints":{"codehealthFindingId/v1":"724b3921eaaa7b2ba97c570a93da24683f0d991d8ba679fb134417b9c1511c9e"}},{"ruleId":"D1","level":"warning","message":{"text":"SwarmTool.execute (cyclomatic 23): SwarmTool.execute has cyclomatic complexity 23 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/swarm_tool.py"},"region":{"startLine":540}}}],"partialFingerprints":{"codehealthFindingId/v1":"2fd682dd8bd45524548901eef7a879fb38d939ba75718c76b36829221534a87c"}},{"ruleId":"D1","level":"warning","message":{"text":"trading.edit_position_stops (cyclomatic 23): trading.edit_position_stops has cyclomatic complexity 23 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/etoro/trading.py"},"region":{"startLine":218}}}],"partialFingerprints":{"codehealthFindingId/v1":"1936e350725e40215b80d15d4a815787f24eb3d4bed55c0d93a56689c179acd1"}},{"ruleId":"D1","level":"warning","message":{"text":"sdk.place_order (cyclomatic 23): sdk.place_order has cyclomatic complexity 23 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/upbit/sdk.py"},"region":{"startLine":376}}}],"partialFingerprints":{"codehealthFindingId/v1":"302d516203d559afd20f02c06b3d3b8dbac1d6fef3d8c60bfeb8baa8997787f7"}},{"ruleId":"D1","level":"warning","message":{"text":"ui_services.load_run_context (cyclomatic 23): ui_services.load_run_context has cyclomatic complexity 23 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/ui_services.py"},"region":{"startLine":102}}}],"partialFingerprints":{"codehealthFindingId/v1":"91b9788871bbcc829e134936d9227f5095ef857023db78dad2db62921cda24be"}},{"ruleId":"D1","level":"warning","message":{"text":"ModelPicker.ModelPicker (cyclomatic 23): ModelPicker.ModelPicker has cyclomatic complexity 23 (threshold 15). Most of this is not in the body itself: 6 of the 23 points are its own statements and the rest belongs to 5 function items inside it that branch (onKeyDown, a function literal at line 111, a function literal at line 58, \u2026). The named helpers are already separate functions; the literals\u0027 work cannot be called, reviewed or tested from outside this body. To reduce it, move the named helpers out of the body to the enclosing scope and lift each literal\u0027s work into a named function there, so each is measured, reviewed and tested on its own, and reduce whichever one then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/settings/ModelPicker.tsx"},"region":{"startLine":13}}}],"partialFingerprints":{"codehealthFindingId/v1":"bb6d002ae332a79f24b84b94cf2c32887c3f95cd8d9beeb2abc5cad616f6c96c"}},{"ruleId":"D1","level":"warning","message":{"text":"SoftwareUpdateSettings.SoftwareUpdateSettings (cyclomatic 23): SoftwareUpdateSettings.SoftwareUpdateSettings has cyclomatic complexity 23 (threshold 15). Of this number, 20 points are the body\u0027s own statements and 3 belong to 2 function items inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/settings/SoftwareUpdateSettings.tsx"},"region":{"startLine":5}}}],"partialFingerprints":{"codehealthFindingId/v1":"80a62a15b8e23a8c14595eda5e3e52e98e71e94303c7ddcbfb57e787ac2e850a"}},{"ruleId":"D1","level":"warning","message":{"text":"yahoo_client._parse_chart (cyclomatic 22): yahoo_client._parse_chart has cyclomatic complexity 22 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/yahoo_client.py"},"region":{"startLine":221}}}],"partialFingerprints":{"codehealthFindingId/v1":"9330a70227b1c073a8f4536522a512767a63145ee78cfe923a84dd492493e478"}},{"ruleId":"D1","level":"warning","message":{"text":"TurnoverAwareOptimizer._calc_weights (cyclomatic 22): TurnoverAwareOptimizer._calc_weights has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/optimizers/turnover_aware.py"},"region":{"startLine":160}}}],"partialFingerprints":{"codehealthFindingId/v1":"b82ca0554248223da75579e316cfcc891e87d8727452ce93e2adb87eb0f7f868"}},{"ruleId":"D1","level":"warning","message":{"text":"_EvidenceMixin._record_backtest_metrics (cyclomatic 22): _EvidenceMixin._record_backtest_metrics has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/grounding/evidence.py"},"region":{"startLine":999}}}],"partialFingerprints":{"codehealthFindingId/v1":"17cc1c17be2efb7cb7044ef51e3c29ddd65fbfc0b5ad577cc08c133f0e16cca4"}},{"ruleId":"D1","level":"warning","message":{"text":"_EvidenceMixin._ingest_market_data (cyclomatic 22): _EvidenceMixin._ingest_market_data has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/grounding/evidence.py"},"region":{"startLine":1360}}}],"partialFingerprints":{"codehealthFindingId/v1":"6da27e1c60dd2d52e74e2f5a2bfa4fd62697473fec4326355b9a115c7422a910"}},{"ruleId":"D1","level":"warning","message":{"text":"evidence._wrapped_percent_headers (cyclomatic 22): evidence._wrapped_percent_headers has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/grounding/evidence.py"},"region":{"startLine":752}}}],"partialFingerprints":{"codehealthFindingId/v1":"f7d24e2f1afef89b658b24b046379762f630524adc7a46e6846e2b397841f4db"}},{"ruleId":"D1","level":"warning","message":{"text":"_PolicyMixin._indexed_field_ref_candidates (cyclomatic 22): _PolicyMixin._indexed_field_ref_candidates has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/grounding/policies.py"},"region":{"startLine":1225}}}],"partialFingerprints":{"codehealthFindingId/v1":"b362cff534922b1527c39f36e99d0b0c1bb148679794bd0d8bab81527ec875f2"}},{"ruleId":"D1","level":"warning","message":{"text":"context_compact._verification_ledger (cyclomatic 22): context_compact._verification_ledger has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/agent/context_compact.py"},"region":{"startLine":114}}}],"partialFingerprints":{"codehealthFindingId/v1":"52ec5370456e1e2791242b320646e9342d6e01f251898a01f1c3845d57c20186"}},{"ruleId":"D1","level":"warning","message":{"text":"instrument_identity._normalize_symbol (cyclomatic 22): instrument_identity._normalize_symbol has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/agent/instrument_identity.py"},"region":{"startLine":165}}}],"partialFingerprints":{"codehealthFindingId/v1":"ac430d563f23b299a7baf06903ea3855f57d17fb75b6e41fd5861ab36a13ac85"}},{"ruleId":"D1","level":"warning","message":{"text":"EmailChannel.start (cyclomatic 22): EmailChannel.start has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/email.py"},"region":{"startLine":171}}}],"partialFingerprints":{"codehealthFindingId/v1":"59ca4447d7b7a944aa2205126a35e4a8182729be2c2324f245555baf51d4c7c2"}},{"ruleId":"D1","level":"warning","message":{"text":"telegram._split_telegram_markdown (cyclomatic 22): telegram._split_telegram_markdown has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/telegram.py"},"region":{"startLine":46}}}],"partialFingerprints":{"codehealthFindingId/v1":"85702b8ca65640e669c5420ff39ab80b70e9e42eba8ef68d3031b7e22053f10d"}},{"ruleId":"D1","level":"warning","message":{"text":"ScanQueue._run (cyclomatic 22): ScanQueue._run has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/data_gateway/scans.py"},"region":{"startLine":110}}}],"partialFingerprints":{"codehealthFindingId/v1":"f91b27e4c09cd63bb8ad2124747e13ec504dce985ba5f4ad8105bf7dde31965f"}},{"ruleId":"D1","level":"warning","message":{"text":"ingest._load_panel_wide (cyclomatic 22): ingest._load_panel_wide has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/entities/ingest.py"},"region":{"startLine":1099}}}],"partialFingerprints":{"codehealthFindingId/v1":"228b188c83f370fa96a544c2138b826e961b899e3126ed28f56321dfb8aac3b3"}},{"ruleId":"D1","level":"warning","message":{"text":"context.format_goal_continuation_prompt (cyclomatic 22): context.format_goal_continuation_prompt has cyclomatic complexity 22 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/goal/context.py"},"region":{"startLine":94}}}],"partialFingerprints":{"codehealthFindingId/v1":"a147228eb4ede095eb666420ab992ebc380aef39b9beb1ee19100caf4c802ee9"}},{"ruleId":"D1","level":"warning","message":{"text":"enforcement.check_mandate (cyclomatic 22): enforcement.check_mandate has cyclomatic complexity 22 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/live/enforcement.py"},"region":{"startLine":476}}}],"partialFingerprints":{"codehealthFindingId/v1":"aa1758fc90f6f62e76e356d5228334c4ca3cfe334c8c5f734ee446bab444322c"}},{"ruleId":"D1","level":"warning","message":{"text":"openai_codex._convert_messages (cyclomatic 22): openai_codex._convert_messages has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/providers/openai_codex.py"},"region":{"startLine":466}}}],"partialFingerprints":{"codehealthFindingId/v1":"2faaf6d8491a59cd5f3e4592b16bf29949991a5fce265f935992cd6d3404d6b0"}},{"ruleId":"D1","level":"warning","message":{"text":"neutralization.pca_factors (cyclomatic 22): neutralization.pca_factors has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/neutralization.py"},"region":{"startLine":385}}}],"partialFingerprints":{"codehealthFindingId/v1":"b350a4f7d8ee3c444ab2efe80d707880d473e077c8deaaa9dfab40d807f621c0"}},{"ruleId":"D1","level":"warning","message":{"text":"ScheduledResearchExecutor.sweep_deliveries (cyclomatic 22): ScheduledResearchExecutor.sweep_deliveries has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/scheduled_research/executor.py"},"region":{"startLine":567}}}],"partialFingerprints":{"codehealthFindingId/v1":"b703808d062d5860ece62ae02912cfc3061e9225728b291b4c186da7e5f530b3"}},{"ruleId":"D1","level":"warning","message":{"text":"SessionService._record_tool_trail_event (cyclomatic 22): SessionService._record_tool_trail_event has cyclomatic complexity 22 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/session/service.py"},"region":{"startLine":732}}}],"partialFingerprints":{"codehealthFindingId/v1":"ce6750d0bc93dc5c76d87ae58f23dddb6883fe8c883a9d8781fdec82815d3bb1"}},{"ruleId":"D1","level":"warning","message":{"text":"doc_reader_tool._read_pdf (cyclomatic 22): doc_reader_tool._read_pdf has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/doc_reader_tool.py"},"region":{"startLine":133}}}],"partialFingerprints":{"codehealthFindingId/v1":"e089c9db4ec0b58b397e8a94742fffe8c2751982577b6763e183624faf5c0156"}},{"ruleId":"D1","level":"warning","message":{"text":"etf_holdings_tool._cn_etf_list (cyclomatic 22): etf_holdings_tool._cn_etf_list has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/etf_holdings_tool.py"},"region":{"startLine":1202}}}],"partialFingerprints":{"codehealthFindingId/v1":"f937a9317342df1240f736fb6c97c530593353b8e6a06c5d2880604e164435e3"}},{"ruleId":"D1","level":"warning","message":{"text":"financial_statements_tool._fetch_sec_statement (cyclomatic 22): financial_statements_tool._fetch_sec_statement has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/financial_statements_tool.py"},"region":{"startLine":684}}}],"partialFingerprints":{"codehealthFindingId/v1":"21afce751456a97b983399d684f0a29380e914e5e199131108465eb9a2034a6d"}},{"ruleId":"D1","level":"warning","message":{"text":"GildataFundNavTool.execute (cyclomatic 22): GildataFundNavTool.execute has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/fund_nav_tool.py"},"region":{"startLine":140}}}],"partialFingerprints":{"codehealthFindingId/v1":"8e4db7e13bbc8721aa9dcfd51b1d46d513782735fe1037464fb271dab813a820"}},{"ruleId":"D1","level":"warning","message":{"text":"GetFundamentalsTool.execute (cyclomatic 22): GetFundamentalsTool.execute has cyclomatic complexity 22 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/get_fundamentals_tool.py"},"region":{"startLine":128}}}],"partialFingerprints":{"codehealthFindingId/v1":"562611bc6b106f2dd2b5bf7e2f8d7cde069c878b97c08925ac3388d7276c4ef6"}},{"ruleId":"D1","level":"warning","message":{"text":"institutional_holdings_tool._walk_chain (cyclomatic 22): institutional_holdings_tool._walk_chain has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/institutional_holdings_tool.py"},"region":{"startLine":1208}}}],"partialFingerprints":{"codehealthFindingId/v1":"7303ae17a31dfb677562173afd414b6479c6440fc74407a3113083accaa2ecfc"}},{"ruleId":"D1","level":"warning","message":{"text":"OptionsChainTool.execute (cyclomatic 22): OptionsChainTool.execute has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/options_chain_tool.py"},"region":{"startLine":71}}}],"partialFingerprints":{"codehealthFindingId/v1":"7ce7411d6b127293471be1e601f0a60033cc02b8512e8134146bb8af4e0d3cf6"}},{"ruleId":"D1","level":"warning","message":{"text":"data._fetch_cn_a (cyclomatic 22): data._fetch_cn_a has cyclomatic complexity 22 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/paper_trade/data.py"},"region":{"startLine":647}}}],"partialFingerprints":{"codehealthFindingId/v1":"3959d0b9802ffbd0035d63fe65d7727987477871a065c8b8e75e004b07013912"}},{"ruleId":"D1","level":"warning","message":{"text":"reconcile.reconcile_document (cyclomatic 22): reconcile.reconcile_document has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/paper_trade/reconcile.py"},"region":{"startLine":149}}}],"partialFingerprints":{"codehealthFindingId/v1":"42fd5df5fcd01dd002d3676dc3d209a28f47522f00e0df273aceddceeaca68b1"}},{"ruleId":"D1","level":"warning","message":{"text":"research_papers_tool._arxiv_paper (cyclomatic 22): research_papers_tool._arxiv_paper has cyclomatic complexity 22 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/research_papers_tool.py"},"region":{"startLine":1017}}}],"partialFingerprints":{"codehealthFindingId/v1":"1900aaf2fffbe76456c5e6e296baa839dd8add2a704cb87b6b9d1df85645bfa2"}},{"ruleId":"D1","level":"warning","message":{"text":"trade_journal_tool._compute_profile (cyclomatic 22): trade_journal_tool._compute_profile has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/trade_journal_tool.py"},"region":{"startLine":237}}}],"partialFingerprints":{"codehealthFindingId/v1":"9f09beef6092d275f2b4d8197c87737f936aaf295b8c634f4929f4494a2ca0ae"}},{"ruleId":"D1","level":"warning","message":{"text":"service._close_etoro_position (cyclomatic 22): service._close_etoro_position has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/service.py"},"region":{"startLine":883}}}],"partialFingerprints":{"codehealthFindingId/v1":"8e6e9cc4e9e59dc4646972c03cc969ec25465c205a35f3401afaadab8df307e3"}},{"ruleId":"D1","level":"warning","message":{"text":"Settings.Settings::submitDataSources (cyclomatic 22): Settings.Settings::submitDataSources has cyclomatic complexity 22 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages. This shape REPEATS in the file: 2 other methods here (Settings.Settings, Settings.Settings::submit) have the same decision points, in the same order, at the same nesting depths \u2014 so this is one pattern written 3 times rather than 3 independent problems. Splitting this body alone leaves the other 2 exactly as they are. Where these are variations on one operation, the change that clears all 3 is the shared one: lift the common shape into a single routine the variants call, parameterised by whatever genuinely differs between them, and keep in each method only the part that is not shared."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Settings.tsx"},"region":{"startLine":270}}}],"partialFingerprints":{"codehealthFindingId/v1":"84081d4e075a2cb6b8c5195f08c80cd3041a33f1f6e87edcd95124392b52794c"}},{"ruleId":"D1","level":"warning","message":{"text":"additive_conversion.convert_additive_to_multiplicative (cyclomatic 21): additive_conversion.convert_additive_to_multiplicative has cyclomatic complexity 21 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/additive_conversion.py"},"region":{"startLine":103}}}],"partialFingerprints":{"codehealthFindingId/v1":"959182c30b7ce51325c75216df7083fd4fdb0bf3762e8ac1d28cf681c674cdba"}},{"ruleId":"D1","level":"warning","message":{"text":"LongbridgeLoader.fetch (cyclomatic 21): LongbridgeLoader.fetch has cyclomatic complexity 21 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/longbridge.py"},"region":{"startLine":256}}}],"partialFingerprints":{"codehealthFindingId/v1":"0c261bf307cad34d2a1a3bf36a07f6992dadd47d5d916102c89de49ce2cc7730"}},{"ruleId":"D1","level":"warning","message":{"text":"runner.main (cyclomatic 21): runner.main has cyclomatic complexity 21 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/runner.py"},"region":{"startLine":1461}}}],"partialFingerprints":{"codehealthFindingId/v1":"afd3c80f84eec91c37e6048243910407f7049f3f60906110cdd8cf8b3c7d1379"}},{"ruleId":"D1","level":"warning","message":{"text":"_legacy._build_welcome_panel (cyclomatic 21): _legacy._build_welcome_panel has cyclomatic complexity 21 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":1704}}}],"partialFingerprints":{"codehealthFindingId/v1":"a56d12b7f793f0d4cdb061004422e37966ee0faf8f0e1642b9cc843490b86e2b"}},{"ruleId":"D1","level":"warning","message":{"text":"_legacy._handle_slash_command (cyclomatic 21): _legacy._handle_slash_command has cyclomatic complexity 21 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":1953}}}],"partialFingerprints":{"codehealthFindingId/v1":"1bee5c902a8dbcccfbe04eb18ee949e361bcb5881739b34fc2569b3d7a5279f8"}},{"ruleId":"D1","level":"warning","message":{"text":"_legacy.cmd_dev (cyclomatic 21): _legacy.cmd_dev has cyclomatic complexity 21 (threshold 15). To reduce it, separate the branches: extract each independent case into its own named function so the top-level body reads as a short sequence of named decisions."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":6253}}}],"partialFingerprints":{"codehealthFindingId/v1":"84fbf7b1745673f31f5537d356a9ef25dceadf392239322a3eae076feb1ccba8"}},{"ruleId":"D1","level":"warning","message":{"text":"evidence._document_percent_cells (cyclomatic 21): evidence._document_percent_cells has cyclomatic complexity 21 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/grounding/evidence.py"},"region":{"startLine":814}}}],"partialFingerprints":{"codehealthFindingId/v1":"f49cd60481da1581c43eb2f4424328d065b191e4ab4e63df5926f8b94f94d726"}},{"ruleId":"D1","level":"warning","message":{"text":"DingTalkChannel._fetch_remote_media_bytes (cyclomatic 21): DingTalkChannel._fetch_remote_media_bytes has cyclomatic complexity 21 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/dingtalk.py"},"region":{"startLine":384}}}],"partialFingerprints":{"codehealthFindingId/v1":"a0dacb58613f97ea3c353b54904f3aab1fd7ec0f4119e30f175d8b7a1940ea4d"}},{"ruleId":"D1","level":"warning","message":{"text":"MSTeamsChannel._normalize_teams_reply_quote (cyclomatic 21): MSTeamsChannel._normalize_teams_reply_quote has cyclomatic complexity 21 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/msteams.py"},"region":{"startLine":441}}}],"partialFingerprints":{"codehealthFindingId/v1":"07252baa3bc68904f6a3bb0c41b81e5681b5dd74e6caa854ff8d5284b73577d9"}},{"ruleId":"D1","level":"warning","message":{"text":"history_source.fetch_chunk (cyclomatic 21): history_source.fetch_chunk has cyclomatic complexity 21 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/data_gateway/history_source.py"},"region":{"startLine":69}}}],"partialFingerprints":{"codehealthFindingId/v1":"d34aedf1beec6655c4eb1f2ddcbe356a92851844f43e684afb6ff625c23ce2cc"}},{"ruleId":"D1","level":"warning","message":{"text":"HypothesisRegistry.update (cyclomatic 21): HypothesisRegistry.update has cyclomatic complexity 21 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/hypotheses/registry.py"},"region":{"startLine":214}}}],"partialFingerprints":{"codehealthFindingId/v1":"776c6b71eeba4cbfa14b9c1d9068821db016c3f44c89b1b897dafda9629ea1ab"}},{"ruleId":"D1","level":"warning","message":{"text":"commit._resolve_profile (cyclomatic 21): commit._resolve_profile has cyclomatic complexity 21 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/live/mandate/commit.py"},"region":{"startLine":265}}}],"partialFingerprints":{"codehealthFindingId/v1":"582367fa2cbbf31fea9e8ffaf168dc4854a5b9015b86d60ce65e131a0c560c5d"}},{"ruleId":"D1","level":"warning","message":{"text":"stream_guard.supervised_pulls (cyclomatic 21): stream_guard.supervised_pulls has cyclomatic complexity 21 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/providers/stream_guard.py"},"region":{"startLine":131}}}],"partialFingerprints":{"codehealthFindingId/v1":"5740cf26d22709628081b54ce24a90d2dc37bd0db0de5738a0267b593f722d6e"}},{"ruleId":"D1","level":"warning","message":{"text":"ResearchPlaybook.to_job (cyclomatic 21): ResearchPlaybook.to_job has cyclomatic complexity 21 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/scheduled_research/playbooks.py"},"region":{"startLine":142}}}],"partialFingerprints":{"codehealthFindingId/v1":"3912092d88edb17ca7c9fb559e073c50dcc3d65016f78217f310e9e21f7f0649"}},{"ruleId":"D1","level":"warning","message":{"text":"StrategyDiscoveryFacade.get_strategy_evidence (cyclomatic 21): StrategyDiscoveryFacade.get_strategy_evidence has cyclomatic complexity 21 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/strategy_discovery/facade.py"},"region":{"startLine":606}}}],"partialFingerprints":{"codehealthFindingId/v1":"5695a522a3a51f1d130dd986232b3689698a3ae1665a8095306adff7fcde7997"}},{"ruleId":"D1","level":"warning","message":{"text":"checkpoint.restore (cyclomatic 21): checkpoint.restore has cyclomatic complexity 21 (threshold 15). To reduce it, separate the branches: extract each independent case into its own named function so the top-level body reads as a short sequence of named decisions."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/swarm/checkpoint.py"},"region":{"startLine":40}}}],"partialFingerprints":{"codehealthFindingId/v1":"f16f2555636923044cae057e6a411cccbeecd1b7a9b4bc72262ea659508426ad"}},{"ruleId":"D1","level":"warning","message":{"text":"EtfHoldingsTool.execute (cyclomatic 21): EtfHoldingsTool.execute has cyclomatic complexity 21 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/etf_holdings_tool.py"},"region":{"startLine":1808}}}],"partialFingerprints":{"codehealthFindingId/v1":"460c7a3010a9dd3a02d2a7caf748739a19aec14bae9c15b6f5f7cb2a898da838"}},{"ruleId":"D1","level":"warning","message":{"text":"institutional_holdings_tool._resolve_chain_value (cyclomatic 21): institutional_holdings_tool._resolve_chain_value has cyclomatic complexity 21 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/institutional_holdings_tool.py"},"region":{"startLine":1432}}}],"partialFingerprints":{"codehealthFindingId/v1":"f91330928b287e4df679f9216d17d97d5dfb0712f82a755e0ccc65a8abb05506"}},{"ruleId":"D1","level":"warning","message":{"text":"OptionsPayoffTool._execute_single (cyclomatic 21): OptionsPayoffTool._execute_single has cyclomatic complexity 21 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/options_payoff_tool.py"},"region":{"startLine":203}}}],"partialFingerprints":{"codehealthFindingId/v1":"f93d3655ad8150a230e7414eb098481b5d1f702b4c074961204be31e23202d1d"}},{"ruleId":"D1","level":"warning","message":{"text":"data.fetch_market_data (cyclomatic 21): data.fetch_market_data has cyclomatic complexity 21 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/paper_trade/data.py"},"region":{"startLine":429}}}],"partialFingerprints":{"codehealthFindingId/v1":"d396e73f9409fb07baf63bce058ceca3d41d40b5db3fb5cacb855f42f2bdac90"}},{"ruleId":"D1","level":"warning","message":{"text":"report_audit_tool._report_value (cyclomatic 21): report_audit_tool._report_value has cyclomatic complexity 21 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/report_audit_tool.py"},"region":{"startLine":64}}}],"partialFingerprints":{"codehealthFindingId/v1":"241047e6cdf4817112a999abb34dd89682cd34566ea30adefa706f38bd3ebc11"}},{"ruleId":"D1","level":"warning","message":{"text":"sdk.place_order (cyclomatic 21): sdk.place_order has cyclomatic complexity 21 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/longbridge/sdk.py"},"region":{"startLine":482}}}],"partialFingerprints":{"codehealthFindingId/v1":"2a004c811252d756d0c73b7ff2cb5a8a721a1067cce7023acd8101bc744a3d8d"}},{"ruleId":"D1","level":"warning","message":{"text":"update-verification.compareSemanticVersions (cyclomatic 21): update-verification.compareSemanticVersions has cyclomatic complexity 21 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"desktop/electron/src/update-verification.ts"},"region":{"startLine":237}}}],"partialFingerprints":{"codehealthFindingId/v1":"b798ee681c7331fa012992d64418b6d97e4333cf2ec13acf535dd2b0b2fcb48e"}},{"ruleId":"D1","level":"warning","message":{"text":"formatters.metricSentiment (cyclomatic 21): formatters.metricSentiment has cyclomatic complexity 21 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/lib/formatters.ts"},"region":{"startLine":69}}}],"partialFingerprints":{"codehealthFindingId/v1":"80a8d33a8ac9d139cabd324c564b3a053529cc3cae7c570d3a6fbaa2a23b8f20"}},{"ruleId":"D1","level":"warning","message":{"text":"Compare.EquityChartOverlay (cyclomatic 21): Compare.EquityChartOverlay has cyclomatic complexity 21 (threshold 15). Most of this is not in the body itself: 3 of the 21 points are its own statements and the rest belongs to 5 function literals inside it that branch (lines 124, 162, 142, \u2026). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Compare.tsx"},"region":{"startLine":120}}}],"partialFingerprints":{"codehealthFindingId/v1":"844f7faef6050df3a256b5c38b2b98568373d997d8bb3310446e48dedc0b2115"}},{"ruleId":"D1","level":"warning","message":{"text":"RunDetail.StudioTab (cyclomatic 21): RunDetail.StudioTab has cyclomatic complexity 21 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/RunDetail.tsx"},"region":{"startLine":622}}}],"partialFingerprints":{"codehealthFindingId/v1":"51a1b369c7dcfd12f9a7f930bef6877ac405376c4626f61bca579687f607ce2c"}},{"ruleId":"D1","level":"warning","message":{"text":"composite._build_rule_engines (cyclomatic 20): composite._build_rule_engines has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/engines/composite.py"},"region":{"startLine":29}}}],"partialFingerprints":{"codehealthFindingId/v1":"438f1dc354231995238c8cf09b5055a54767aaae8d7972dab45f9b6d7f39a9f6"}},{"ruleId":"D1","level":"warning","message":{"text":"DataLoader._fetch_one (cyclomatic 20): DataLoader._fetch_one has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/tencent_loader.py"},"region":{"startLine":241}}}],"partialFingerprints":{"codehealthFindingId/v1":"697d3421be1180b339a6754ee1682ba920895a523ec23ddd3256a0205f4a00cd"}},{"ruleId":"D1","level":"warning","message":{"text":"_SwarmDashboard.build_table (cyclomatic 20): _SwarmDashboard.build_table has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":2237}}}],"partialFingerprints":{"codehealthFindingId/v1":"da7045dde931ac7dbdc7eae45039efac33c8b323d70ebb824dbe8a60b1058961"}},{"ruleId":"D1","level":"warning","message":{"text":"_EvidenceMixin._ingest_analysis_result (cyclomatic 20): _EvidenceMixin._ingest_analysis_result has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/grounding/evidence.py"},"region":{"startLine":873}}}],"partialFingerprints":{"codehealthFindingId/v1":"8d775640713a687d4fae6b09e1e466b8a91db6e8412d8423de43649ffdad6f1c"}},{"ruleId":"D1","level":"warning","message":{"text":"mcp_server.alpha_bench (cyclomatic 20): mcp_server.alpha_bench has cyclomatic complexity 20 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/mcp_server.py"},"region":{"startLine":1059}}}],"partialFingerprints":{"codehealthFindingId/v1":"29b70361691cd632be5a916b249939ae09f4317d783f8d71077c90d4e96655fb"}},{"ruleId":"D1","level":"warning","message":{"text":"DiscordChannel.send_delta (cyclomatic 20): DiscordChannel.send_delta has cyclomatic complexity 20 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/discord.py"},"region":{"startLine":513}}}],"partialFingerprints":{"codehealthFindingId/v1":"b2fb8f0ec9be2757f6e45bf2fc3fb5ace9cb16b49d9ae74f18afff4d6a25d753"}},{"ruleId":"D1","level":"warning","message":{"text":"EmailChannel._authentication_results_segments (cyclomatic 20): EmailChannel._authentication_results_segments has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/email.py"},"region":{"startLine":959}}}],"partialFingerprints":{"codehealthFindingId/v1":"48efe54aa3be42ebf08a9fe382ef26d77ff418b206514ca023fabd23d126c7e1"}},{"ruleId":"D1","level":"warning","message":{"text":"MatrixChannel._upload_and_send_attachment (cyclomatic 20): MatrixChannel._upload_and_send_attachment has cyclomatic complexity 20 (threshold 15). To reduce it, separate the branches: extract each independent case into its own named function so the top-level body reads as a short sequence of named decisions."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/matrix.py"},"region":{"startLine":458}}}],"partialFingerprints":{"codehealthFindingId/v1":"cb7162f9ff40635dec92951736d23a50bf15b94aafb40577a3c3f65c9acdc5ce"}},{"ruleId":"D1","level":"warning","message":{"text":"store.handle_pairing_command (cyclomatic 20): store.handle_pairing_command has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/pairing/store.py"},"region":{"startLine":233}}}],"partialFingerprints":{"codehealthFindingId/v1":"cfc9b022d0d1bcb5be0c392cdf53cff0deb38f93b83b95344b9f0b13145b88c4"}},{"ruleId":"D1","level":"warning","message":{"text":"SignalChannel._should_respond_in_group (cyclomatic 20): SignalChannel._should_respond_in_group has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/signal.py"},"region":{"startLine":1230}}}],"partialFingerprints":{"codehealthFindingId/v1":"d10c02f47b727cee9c2dded190f388d90bcee37dad46d59da960bfddfd131ee5"}},{"ruleId":"D1","level":"warning","message":{"text":"historical.describe_coverage (cyclomatic 20): historical.describe_coverage has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/data_gateway/historical.py"},"region":{"startLine":374}}}],"partialFingerprints":{"codehealthFindingId/v1":"042cc4ef99099ad3c028f54bd02e34fbabaa9ffeb4505b26473da239574a80ed"}},{"ruleId":"D1","level":"warning","message":{"text":"SSEEventMapper.map (cyclomatic 20): SSEEventMapper.map has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/openbb_bridge/event_mapper.py"},"region":{"startLine":50}}}],"partialFingerprints":{"codehealthFindingId/v1":"b0aa20f42e03e524e9968570f1861dc4d91da09ed7143c24becb26427900505b"}},{"ruleId":"D1","level":"warning","message":{"text":"PortfolioService._warnings (cyclomatic 20): PortfolioService._warnings has cyclomatic complexity 20 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/portfolio/service.py"},"region":{"startLine":1203}}}],"partialFingerprints":{"codehealthFindingId/v1":"c6bdf9bfee4ea099d6eb695b5b7e23137495726bdb84be93a1ffacf992f4e117"}},{"ruleId":"D1","level":"warning","message":{"text":"claude_cli._decide (cyclomatic 20): claude_cli._decide has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/providers/claude_cli.py"},"region":{"startLine":377}}}],"partialFingerprints":{"codehealthFindingId/v1":"f286a1af4cb7fea833f0a5bd7482f49163dc000970739a0f4c47219da5d6cb04"}},{"ruleId":"D1","level":"warning","message":{"text":"claude_cli._query_claude_cli_models (cyclomatic 20): claude_cli._query_claude_cli_models has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/providers/claude_cli.py"},"region":{"startLine":733}}}],"partialFingerprints":{"codehealthFindingId/v1":"c6c61e42466a3722ed446b3b2a4cab0f41a71886bdc6a9a8cde75c81ffe80dd1"}},{"ruleId":"D1","level":"warning","message":{"text":"crossvalidation.group_purged_kfold_splits (cyclomatic 20): crossvalidation.group_purged_kfold_splits has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/crossvalidation.py"},"region":{"startLine":292}}}],"partialFingerprints":{"codehealthFindingId/v1":"996066215b2660c42f01b43447e0f6f9863764cf6bb0466be2f3971f667a8956"}},{"ruleId":"D1","level":"warning","message":{"text":"factormodel.factor_risk_decomposition (cyclomatic 20): factormodel.factor_risk_decomposition has cyclomatic complexity 20 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/factormodel.py"},"region":{"startLine":601}}}],"partialFingerprints":{"codehealthFindingId/v1":"aaf2537121badc211eb6e9659451285e75f8e7a28f2ac907fb4d66a990ec0667"}},{"ruleId":"D1","level":"warning","message":{"text":"factormodel.factor_ic_analysis (cyclomatic 20): factormodel.factor_ic_analysis has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/factormodel.py"},"region":{"startLine":761}}}],"partialFingerprints":{"codehealthFindingId/v1":"369cacc61fcdddabf793e2c3fc2587232ad304e6be4379f4d72a5134c8f0f927"}},{"ruleId":"D1","level":"warning","message":{"text":"volatility.implied_volatility_surface (cyclomatic 20): volatility.implied_volatility_surface has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/volatility.py"},"region":{"startLine":279}}}],"partialFingerprints":{"codehealthFindingId/v1":"4436af9057503b7c7956a221e67b51976a8ad5751e82783524b0917f46576580"}},{"ruleId":"D1","level":"warning","message":{"text":"SignalEngine._find_impulse (cyclomatic 20): SignalEngine._find_impulse has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/skills/elliott-wave/example_signal_engine.py"},"region":{"startLine":188}}}],"partialFingerprints":{"codehealthFindingId/v1":"37da573359812f3f74a33b88510d3fc4bac4daaa067315117827c2fcbaa583ba"}},{"ruleId":"D1","level":"warning","message":{"text":"presets.inspect_preset (cyclomatic 20): presets.inspect_preset has cyclomatic complexity 20 (threshold 15). To reduce it, separate the branches: extract each independent case into its own named function so the top-level body reads as a short sequence of named decisions."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/swarm/presets.py"},"region":{"startLine":171}}}],"partialFingerprints":{"codehealthFindingId/v1":"f6b907653fd78d55109c4d61a55f00120dc03050417c7e895e7b292c36c04eee"}},{"ruleId":"D1","level":"warning","message":{"text":"SwarmRuntime._execute_layer (cyclomatic 20): SwarmRuntime._execute_layer has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/swarm/runtime.py"},"region":{"startLine":992}}}],"partialFingerprints":{"codehealthFindingId/v1":"1b6077e1f5db06ebeb2a8cb1bcce491c7e628660192aaf1d2cf6f23fd4905355"}},{"ruleId":"D1","level":"warning","message":{"text":"alpha_bench_tool._load_csi300_panel (cyclomatic 20): alpha_bench_tool._load_csi300_panel has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/alpha_bench_tool.py"},"region":{"startLine":316}}}],"partialFingerprints":{"codehealthFindingId/v1":"b159ad304faba808f48d6adf49a5dc80468cf18819b930aa536e919463ba3596"}},{"ruleId":"D1","level":"warning","message":{"text":"GildataFundNavTool._fetch_one (cyclomatic 20): GildataFundNavTool._fetch_one has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/fund_nav_tool.py"},"region":{"startLine":223}}}],"partialFingerprints":{"codehealthFindingId/v1":"33e5c235b9d43af03946531592706edbef82a0fdcc23c9edc2c83b2a9f26dd99"}},{"ruleId":"D1","level":"warning","message":{"text":"southbound_tool._parse_hkex_report (cyclomatic 20): southbound_tool._parse_hkex_report has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/southbound_tool.py"},"region":{"startLine":175}}}],"partialFingerprints":{"codehealthFindingId/v1":"7736e8579d63e66f533eb806db5d500800872b1fa82df8692fac0612cdf9ad95"}},{"ruleId":"D1","level":"warning","message":{"text":"trade_journal_parsers.parse_generic (cyclomatic 20): trade_journal_parsers.parse_generic has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/trade_journal_parsers.py"},"region":{"startLine":571}}}],"partialFingerprints":{"codehealthFindingId/v1":"d6efa461a6e676c546846871573cb1b24950a03e2c32a16f225e4566e4990046"}},{"ruleId":"D1","level":"warning","message":{"text":"orders.place_order (cyclomatic 20): orders.place_order has cyclomatic complexity 20 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/mt5/orders.py"},"region":{"startLine":59}}}],"partialFingerprints":{"codehealthFindingId/v1":"c12710752d72269bf5ee4676b99e716c85b6723de4aedc230f59340aefeefb49"}},{"ruleId":"D1","level":"warning","message":{"text":"update-verification.verifyWindowsUpdateCandidate (cyclomatic 20): update-verification.verifyWindowsUpdateCandidate has cyclomatic complexity 20 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"desktop/electron/src/update-verification.ts"},"region":{"startLine":53}}}],"partialFingerprints":{"codehealthFindingId/v1":"2924a396cf5f8008a7b0e1a22e37fea8894e7a8b0955a262ca62dac11f4c9297"}},{"ruleId":"D1","level":"warning","message":{"text":"GoalPanel.GoalPanel (cyclomatic 20): GoalPanel.GoalPanel has cyclomatic complexity 20 (threshold 15). Of this number, 11 points are the body\u0027s own statements and 9 belong to 4 function literals inside it that branch. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/chat/GoalPanel.tsx"},"region":{"startLine":61}}}],"partialFingerprints":{"codehealthFindingId/v1":"36a12c9777e783b2e07fb4a58494c4387ec2d150f5e2592ce35e774f9b585587"}},{"ruleId":"D1","level":"warning","message":{"text":"RunnerBudgetControls.RunnerBudgetControls (cyclomatic 20): RunnerBudgetControls.RunnerBudgetControls has cyclomatic complexity 20 (threshold 15). Of this number, 11 points are the body\u0027s own statements and 9 belong to 5 function literals inside it that branch. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/chat/RunnerBudgetControls.tsx"},"region":{"startLine":6}}}],"partialFingerprints":{"codehealthFindingId/v1":"7985321f1d97161167ea557cd69014a9d139ab35accbd4c5a391f4eed8e528d9"}},{"ruleId":"D1","level":"warning","message":{"text":"PortfolioSourceEditor.PortfolioSourceEditor (cyclomatic 20): PortfolioSourceEditor.PortfolioSourceEditor has cyclomatic complexity 20 (threshold 15). Most of this is not in the body itself: 6 of the 20 points are its own statements and the rest belongs to 10 function items inside it that branch (a function literal at line 108, a function literal at line 35, move, \u2026). The named helpers are already separate functions; the literals\u0027 work cannot be called, reviewed or tested from outside this body. To reduce it, move the named helpers out of the body to the enclosing scope and lift each literal\u0027s work into a named function there, so each is measured, reviewed and tested on its own, and reduce whichever one then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/portfolio/PortfolioSourceEditor.tsx"},"region":{"startLine":29}}}],"partialFingerprints":{"codehealthFindingId/v1":"ed9f0731bf7122e9645982acd6064f1232385e355caf59f2754ea7fa13ae5150"}},{"ruleId":"D1","level":"warning","message":{"text":"options.buildVolatilitySurfaceRequest (cyclomatic 20): options.buildVolatilitySurfaceRequest has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/lib/options.ts"},"region":{"startLine":258}}}],"partialFingerprints":{"codehealthFindingId/v1":"4844a16a6140f5a2514133a179d9166a8dd76e87b45c9d6301904c2617c668a6"}},{"ruleId":"D1","level":"warning","message":{"text":"RunDetail.ChartTab (cyclomatic 20): RunDetail.ChartTab has cyclomatic complexity 20 (threshold 15). Of this number, 19 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/RunDetail.tsx"},"region":{"startLine":825}}}],"partialFingerprints":{"codehealthFindingId/v1":"2efa0c4ddea5a52dbce588ceef2bc17750c968019d26bd1c3a72947c625b6a29"}},{"ruleId":"D1","level":"warning","message":{"text":"DataLoader._request_page (cyclomatic 19): DataLoader._request_page has cyclomatic complexity 19 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/tencent_loader.py"},"region":{"startLine":158}}}],"partialFingerprints":{"codehealthFindingId/v1":"b850a6324c0d4b7c032c8e36b22070f105baed926f68aae8459fb5319e982c2d"}},{"ruleId":"D1","level":"warning","message":{"text":"_legacy.cmd_run (cyclomatic 19): _legacy.cmd_run has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":1519}}}],"partialFingerprints":{"codehealthFindingId/v1":"e7353524433af3a7df3cd9978191e18f2582ccf0a0f5a39fc4a5c2f597b31bed"}},{"ruleId":"D1","level":"warning","message":{"text":"_legacy.cmd_swarm_inspect (cyclomatic 19): _legacy.cmd_swarm_inspect has cyclomatic complexity 19 (threshold 15). To reduce it, separate the branches: extract each independent case into its own named function so the top-level body reads as a short sequence of named decisions."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":2719}}}],"partialFingerprints":{"codehealthFindingId/v1":"e8b89974526a01ca938025928563a2f0f4b2f05929b6cc2d9bc67faf79ef158a"}},{"ruleId":"D1","level":"warning","message":{"text":"research_playbook.run (cyclomatic 19): research_playbook.run has cyclomatic complexity 19 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/commands/research_playbook.py"},"region":{"startLine":398}}}],"partialFingerprints":{"codehealthFindingId/v1":"3cb8b8d8afdf3b4d1829660a9145aa24db7f528b7913cea85e2c7bd6a866c43a"}},{"ruleId":"D1","level":"warning","message":{"text":"_EvidenceMixin._record_backtest_outputs (cyclomatic 19): _EvidenceMixin._record_backtest_outputs has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/grounding/evidence.py"},"region":{"startLine":1069}}}],"partialFingerprints":{"codehealthFindingId/v1":"cec384dc1332d2fe69544240e29b210d52ba485f889fb8f17294bae57c9df9ff"}},{"ruleId":"D1","level":"warning","message":{"text":"_EvidenceMixin._ingest_document_text (cyclomatic 19): _EvidenceMixin._ingest_document_text has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/grounding/evidence.py"},"region":{"startLine":1660}}}],"partialFingerprints":{"codehealthFindingId/v1":"ce39309cbc3881623eb0d35bf61ff7ac4868e77e135103dcff0a88ddaa9bb1ef"}},{"ruleId":"D1","level":"warning","message":{"text":"_PolicyMixin._operands_read_as_points (cyclomatic 19): _PolicyMixin._operands_read_as_points has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/grounding/policies.py"},"region":{"startLine":2132}}}],"partialFingerprints":{"codehealthFindingId/v1":"71556645f0b2b0b4f68167a3a0013ea6967bb9dceb20db21505dab3ef367904a"}},{"ruleId":"D1","level":"warning","message":{"text":"assertions._tool_result_join_verdict (cyclomatic 19): assertions._tool_result_join_verdict has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/harness/assertions.py"},"region":{"startLine":735}}}],"partialFingerprints":{"codehealthFindingId/v1":"1d1e5cd166c0dd9895320961bf312e47f583915fadae63bb9ea3a92974f5129b"}},{"ruleId":"D1","level":"warning","message":{"text":"measurements.validate_measurements (cyclomatic 19): measurements.validate_measurements has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/harness/measurements.py"},"region":{"startLine":16}}}],"partialFingerprints":{"codehealthFindingId/v1":"1ceac2da60f1b592656bb595434fc37917afa27e0bbe4e8910f1d4fb6cf41408"}},{"ruleId":"D1","level":"warning","message":{"text":"MatrixChannel._handle_key_verification_event (cyclomatic 19): MatrixChannel._handle_key_verification_event has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/matrix.py"},"region":{"startLine":624}}}],"partialFingerprints":{"codehealthFindingId/v1":"80200f8b1fb7fcce19106c09327c631552fcd1bcf5ea30df33bdf38b23456e70"}},{"ruleId":"D1","level":"warning","message":{"text":"WeixinChannel._send_media_file (cyclomatic 19): WeixinChannel._send_media_file has cyclomatic complexity 19 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/weixin.py"},"region":{"startLine":1328}}}],"partialFingerprints":{"codehealthFindingId/v1":"0a400efc904166afe2d48a2b35f3cbb989a8293dc12bd6e1532739def91f9520"}},{"ruleId":"D1","level":"warning","message":{"text":"Runner.execute (cyclomatic 19): Runner.execute has cyclomatic complexity 19 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/core/runner.py"},"region":{"startLine":594}}}],"partialFingerprints":{"codehealthFindingId/v1":"5484f5bc7cb26323607535c01f73931b1488af8982f80e6ee2a5139278c4ef98"}},{"ruleId":"D1","level":"warning","message":{"text":"bar_summary.summarize_bars (cyclomatic 19): bar_summary.summarize_bars has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/data_gateway/bar_summary.py"},"region":{"startLine":7}}}],"partialFingerprints":{"codehealthFindingId/v1":"91821570684b9137f94040981b84c83d5e9d72f083e4934ada4b82f2a5215ce5"}},{"ruleId":"D1","level":"warning","message":{"text":"fanout.acquire_groups (cyclomatic 19): fanout.acquire_groups has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/data_gateway/fanout.py"},"region":{"startLine":20}}}],"partialFingerprints":{"codehealthFindingId/v1":"ab27672b94f5facda9f4918d491b93a3afe4f45d576e56e4be196d3ae34a0673"}},{"ruleId":"D1","level":"warning","message":{"text":"reads.read (cyclomatic 19): reads.read has cyclomatic complexity 19 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/data_gateway/reads.py"},"region":{"startLine":50}}}],"partialFingerprints":{"codehealthFindingId/v1":"345142efcf458f7b91d18bc093f8b26d60d96b97c515e6deb1bd994199efe904"}},{"ruleId":"D1","level":"warning","message":{"text":"sdk_order_gate._recover_pending_order (cyclomatic 19): sdk_order_gate._recover_pending_order has cyclomatic complexity 19 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/live/sdk_order_gate.py"},"region":{"startLine":542}}}],"partialFingerprints":{"codehealthFindingId/v1":"b8cf9a8ceac9ed53e5fb56f9f343df2e2a3049b7f364a31755005b79b83e58e1"}},{"ruleId":"D1","level":"warning","message":{"text":"PersistentMemory.add (cyclomatic 19): PersistentMemory.add has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/memory/persistent.py"},"region":{"startLine":515}}}],"partialFingerprints":{"codehealthFindingId/v1":"7d3dce306b1236aa9d8b48542d4bdd18fa2a3f81c7570b4f2effe3445e6754c2"}},{"ruleId":"D1","level":"warning","message":{"text":"rebalance.propose_rebalance (cyclomatic 19): rebalance.propose_rebalance has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/portfolio/rebalance.py"},"region":{"startLine":13}}}],"partialFingerprints":{"codehealthFindingId/v1":"ee48535be44b709dfef034d508a77e07a2164971db3ffcb3a54d8fe32dea4d55"}},{"ruleId":"D1","level":"warning","message":{"text":"PortfolioService._combine_holdings (cyclomatic 19): PortfolioService._combine_holdings has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/portfolio/service.py"},"region":{"startLine":899}}}],"partialFingerprints":{"codehealthFindingId/v1":"169975c09bce3b8a07afe16e951630877368ca625ecc16f003153b10e3f58ea9"}},{"ruleId":"D1","level":"warning","message":{"text":"openai_codex._get_codex_token (cyclomatic 19): openai_codex._get_codex_token has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/providers/openai_codex.py"},"region":{"startLine":330}}}],"partialFingerprints":{"codehealthFindingId/v1":"6d79dcfb502c22529c2c158946df4fe9f91cfc29bcfd817a4a9981bf4965f2db"}},{"ruleId":"D1","level":"warning","message":{"text":"scanner._compare (cyclomatic 19): scanner._compare has cyclomatic complexity 19 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/shadow_account/scanner.py"},"region":{"startLine":236}}}],"partialFingerprints":{"codehealthFindingId/v1":"2658721a4d1034c2eaf3d9e6e5ad8187b324942853f27f7f0bf0eae1dfc78080"}},{"ruleId":"D1","level":"warning","message":{"text":"SwarmRuntime._execute_run (cyclomatic 19): SwarmRuntime._execute_run has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/swarm/runtime.py"},"region":{"startLine":520}}}],"partialFingerprints":{"codehealthFindingId/v1":"df6d397048a3885162c546418a6892abb85ba026f1f4df789c09f7935516284f"}},{"ruleId":"D1","level":"warning","message":{"text":"FredMacroTool.execute (cyclomatic 19): FredMacroTool.execute has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/fred_macro_tool.py"},"region":{"startLine":116}}}],"partialFingerprints":{"codehealthFindingId/v1":"a0c9346a7493e63ab1b2b981c30e45eadf9ae153b8b53d322e1730f045f00eec"}},{"ruleId":"D1","level":"warning","message":{"text":"goal_tool._trace_fields_from_runtime (cyclomatic 19): goal_tool._trace_fields_from_runtime has cyclomatic complexity 19 (threshold 15). To reduce it, separate the branches: extract each independent case into its own named function so the top-level body reads as a short sequence of named decisions."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/goal_tool.py"},"region":{"startLine":72}}}],"partialFingerprints":{"codehealthFindingId/v1":"3b22136e53da8b8324fa6956fcd0ec105f0cd87b44c299d61aed54f86b561323"}},{"ruleId":"D1","level":"warning","message":{"text":"OptionsPricingTool.execute (cyclomatic 19): OptionsPricingTool.execute has cyclomatic complexity 19 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/options_pricing_tool.py"},"region":{"startLine":95}}}],"partialFingerprints":{"codehealthFindingId/v1":"0ca5a0f67e5f0be670d620ffe1b46bea46922cafabbb5d13e4c4ec670c240349"}},{"ruleId":"D1","level":"warning","message":{"text":"schema._validate_node (cyclomatic 19): schema._validate_node has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/paper_trade/schema.py"},"region":{"startLine":727}}}],"partialFingerprints":{"codehealthFindingId/v1":"f663a87b8f7a4a26ab8668e4a64f132f77f215d8a13cc43a8083e32dbf0c691c"}},{"ruleId":"D1","level":"warning","message":{"text":"check_i18n.main (cyclomatic 19): check_i18n.main has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"wiki/scripts/check_i18n.py"},"region":{"startLine":68}}}],"partialFingerprints":{"codehealthFindingId/v1":"882ab159dcfa8972e609621f8db5a7e1e93cbef141ccfd2020b384c971821ccf"}},{"ruleId":"D1","level":"warning","message":{"text":"main.installUpdate (cyclomatic 19): main.installUpdate has cyclomatic complexity 19 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"desktop/electron/src/main.ts"},"region":{"startLine":305}}}],"partialFingerprints":{"codehealthFindingId/v1":"78bd484c760d3e9e800de5a1259b547bec282a5265d7752a6bb35ff3e60b57fd"}},{"ruleId":"D1","level":"warning","message":{"text":"ScheduledResearchProposalCard.ScheduledResearchProposalCard (cyclomatic 19): ScheduledResearchProposalCard.ScheduledResearchProposalCard has cyclomatic complexity 19 (threshold 15). Of this number, 16 points are the body\u0027s own statements and 3 belong to one function item inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/chat/ScheduledResearchProposalCard.tsx"},"region":{"startLine":19}}}],"partialFingerprints":{"codehealthFindingId/v1":"00a5bbe686d2ab3f62573696a78c08b4437b49681f881fb14f9317aaffa34b49"}},{"ruleId":"D1","level":"warning","message":{"text":"ConnectionCenter.AccountSelector (cyclomatic 19): ConnectionCenter.AccountSelector has cyclomatic complexity 19 (threshold 15). Of this number, 12 points are the body\u0027s own statements and 7 belong to 3 function items inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/portfolio/ConnectionCenter.tsx"},"region":{"startLine":261}}}],"partialFingerprints":{"codehealthFindingId/v1":"bc0702492b1b29bfd86f1b586d8dbef1667484ad6e23b952d816601f0d43e403"}},{"ruleId":"D1","level":"warning","message":{"text":"useAnalysisState.useAnalysisState (cyclomatic 19): useAnalysisState.useAnalysisState has cyclomatic complexity 19 (threshold 15). Of this number, 14 points are the body\u0027s own statements and 5 belong to 2 function literals inside it that branch. To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/hooks/useAnalysisState.ts"},"region":{"startLine":14}}}],"partialFingerprints":{"codehealthFindingId/v1":"8f828dc4cd4577ccd9ccfc73ab50bcb6375d69137738a9269ca4df07f17e2de6"}},{"ruleId":"D1","level":"warning","message":{"text":"shannon.parseHoldings (cyclomatic 19): shannon.parseHoldings has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/lib/shannon.ts"},"region":{"startLine":37}}}],"partialFingerprints":{"codehealthFindingId/v1":"7667c2773878e00e9bf59eb6f0f87b8ec60020fd56ec81c3b83aa4366f24cd77"}},{"ruleId":"D1","level":"warning","message":{"text":"binance_account_reconciliation.snapshot_from_binance_usdm_observation (cyclomatic 18): binance_account_reconciliation.snapshot_from_binance_usdm_observation has cyclomatic complexity 18 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/binance_account_reconciliation.py"},"region":{"startLine":133}}}],"partialFingerprints":{"codehealthFindingId/v1":"1fcf71230e575da840cb13d43c3de99f4bfd574eced67bf8e7249d9bb8adc1c5"}},{"ruleId":"D1","level":"warning","message":{"text":"valuation_loader.load_valuation_panel (cyclomatic 18): valuation_loader.load_valuation_panel has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/valuation_loader.py"},"region":{"startLine":237}}}],"partialFingerprints":{"codehealthFindingId/v1":"fc93cc55bf421ded4e1e44f7a8907e93de586a3ad47a425a216b60203f692224"}},{"ruleId":"D1","level":"warning","message":{"text":"run_card._metric_citations (cyclomatic 18): run_card._metric_citations has cyclomatic complexity 18 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/run_card.py"},"region":{"startLine":469}}}],"partialFingerprints":{"codehealthFindingId/v1":"60e67f985c6ac515c8282603bb7fdda8b8e6c73a33f8d5028432ee859d82b0d0"}},{"ruleId":"D1","level":"warning","message":{"text":"runner._reject_forbidden_open (cyclomatic 18): runner._reject_forbidden_open has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/runner.py"},"region":{"startLine":585}}}],"partialFingerprints":{"codehealthFindingId/v1":"cbef011894ec600fb1edf8a740f99f2b55ab32417aad9f160240cd562ece0ee4"}},{"ruleId":"D1","level":"warning","message":{"text":"_EvidenceMixin._ingest_run_dir_ohlc_csvs (cyclomatic 18): _EvidenceMixin._ingest_run_dir_ohlc_csvs has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/grounding/evidence.py"},"region":{"startLine":1552}}}],"partialFingerprints":{"codehealthFindingId/v1":"f4b198b23ecc317fafa590b5345eaba20e00342fdec68e2d7850510269f8a962"}},{"ruleId":"D1","level":"warning","message":{"text":"figures.table_rows (cyclomatic 18): figures.table_rows has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/grounding/figures.py"},"region":{"startLine":939}}}],"partialFingerprints":{"codehealthFindingId/v1":"fb2bbee5da3629bee4be96cd757b9a6960f4e347904e26808d621b1e37bcc017"}},{"ruleId":"D1","level":"warning","message":{"text":"figures._currency_code_for_figure (cyclomatic 18): figures._currency_code_for_figure has cyclomatic complexity 18 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/grounding/figures.py"},"region":{"startLine":1051}}}],"partialFingerprints":{"codehealthFindingId/v1":"106b7b34d1d9af12e9767f3879b2a31f78e446c86bac8af59265aac43ebfe468"}},{"ruleId":"D1","level":"warning","message":{"text":"context_compact._context_collapse (cyclomatic 18): context_compact._context_collapse has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/agent/context_compact.py"},"region":{"startLine":292}}}],"partialFingerprints":{"codehealthFindingId/v1":"9f3add0e07f8a8a27b2b9563db0a78d39ba102cc03b679d06715600b8675bfd9"}},{"ruleId":"D1","level":"warning","message":{"text":"write_targets.pending_write_directive (cyclomatic 18): write_targets.pending_write_directive has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/agent/write_targets.py"},"region":{"startLine":114}}}],"partialFingerprints":{"codehealthFindingId/v1":"91d8e66ccad46bf318cc010fd05ba163c78d961ffa16e7e7bd914ce785ed206f"}},{"ruleId":"D1","level":"warning","message":{"text":"attribution_core._attribution_equal_weight_returns (cyclomatic 18): attribution_core._attribution_equal_weight_returns has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/api/attribution_core.py"},"region":{"startLine":279}}}],"partialFingerprints":{"codehealthFindingId/v1":"4bd84e4fe1a867ec96653e6dc826f6cde9f05304741ba15466391286b8cf05c4"}},{"ruleId":"D1","level":"warning","message":{"text":"channels_config_routes._apply_update (cyclomatic 18): channels_config_routes._apply_update has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/api/channels_config_routes.py"},"region":{"startLine":454}}}],"partialFingerprints":{"codehealthFindingId/v1":"4b0d8b7b6a52ee3c05841b26e9f1d992be1c47b5fd88306c8a43c579337d66c9"}},{"ruleId":"D1","level":"warning","message":{"text":"runs_routes._build_positions_sector_map (cyclomatic 18): runs_routes._build_positions_sector_map has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/api/runs_routes.py"},"region":{"startLine":530}}}],"partialFingerprints":{"codehealthFindingId/v1":"556687dcf0cd657abb9a5c1673b45148fd5b48175a8485f6baf1d6763b47493d"}},{"ruleId":"D1","level":"warning","message":{"text":"feishu._extract_post_content (cyclomatic 18): feishu._extract_post_content has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/feishu.py"},"region":{"startLine":305}}}],"partialFingerprints":{"codehealthFindingId/v1":"39fbfbe1c39a806492286ca1e516df54079b47e4b44f5adcc1e2599400997b8e"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelManager._dispatch_outbound (cyclomatic 18): ChannelManager._dispatch_outbound has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/manager.py"},"region":{"startLine":458}}}],"partialFingerprints":{"codehealthFindingId/v1":"4a782ae42a04ddae52d9a7106e975afbb8376b4a3c37369279a7fcfdda5ceb5c"}},{"ruleId":"D1","level":"warning","message":{"text":"SignalChannel._sse_receive_loop (cyclomatic 18): SignalChannel._sse_receive_loop has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/signal.py"},"region":{"startLine":609}}}],"partialFingerprints":{"codehealthFindingId/v1":"d408445e72a3eebf65f7061d3b3b78c7314d140a1430e831d7b48a586610f52f"}},{"ruleId":"D1","level":"warning","message":{"text":"TelegramChannel._process_message_update (cyclomatic 18): TelegramChannel._process_message_update has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/telegram.py"},"region":{"startLine":1462}}}],"partialFingerprints":{"codehealthFindingId/v1":"9393bf7ee4576bfe3c1657a42e883f8816f19da8832be7afdbcbdfdd3cab16f5"}},{"ruleId":"D1","level":"warning","message":{"text":"calendars.validate (cyclomatic 18): calendars.validate has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/data_gateway/calendars.py"},"region":{"startLine":40}}}],"partialFingerprints":{"codehealthFindingId/v1":"95a50f0acfbcdef7f7d7ec7c15ec187fd514a35c1256bfe28cc58635a8acbfe7"}},{"ruleId":"D1","level":"warning","message":{"text":"MemoryLifecycle.run_gc (cyclomatic 18): MemoryLifecycle.run_gc has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/memory/lifecycle.py"},"region":{"startLine":183}}}],"partialFingerprints":{"codehealthFindingId/v1":"0e3c8bca9a1cfa231c8048f85a983eb0813a3fbd81745942c8a4c3033a26d67d"}},{"ruleId":"D1","level":"warning","message":{"text":"tool_policy.check_bash_command (cyclomatic 18): tool_policy.check_bash_command has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/providers/tool_policy.py"},"region":{"startLine":84}}}],"partialFingerprints":{"codehealthFindingId/v1":"0db0597b2c930ebbc5698d0d3dc325562bdb8c0bb96e03105c045da729934f12"}},{"ruleId":"D1","level":"warning","message":{"text":"attribution.brinson_fachler (cyclomatic 18): attribution.brinson_fachler has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/attribution.py"},"region":{"startLine":209}}}],"partialFingerprints":{"codehealthFindingId/v1":"aa0b95474cc4c19ed07d77329fb4954e94907834e0c8a912cb987d3041bfc5e7"}},{"ruleId":"D1","level":"warning","message":{"text":"artifact._flatten (cyclomatic 18): artifact._flatten has cyclomatic complexity 18 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/valuation/artifact.py"},"region":{"startLine":399}}}],"partialFingerprints":{"codehealthFindingId/v1":"783acb4a51377ee656b8e0b190c148ad142dee9f3ca84b58f33e3a452fcf3657"}},{"ruleId":"D1","level":"warning","message":{"text":"playbooks.load_playbook_file (cyclomatic 18): playbooks.load_playbook_file has cyclomatic complexity 18 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/scheduled_research/playbooks.py"},"region":{"startLine":275}}}],"partialFingerprints":{"codehealthFindingId/v1":"29a14dc42389e96bbd5a4ec9b44b20f8747781ca3a74d281174d04b7017807e8"}},{"ruleId":"D1","level":"warning","message":{"text":"SessionService._run_attempt (cyclomatic 18): SessionService._run_attempt has cyclomatic complexity 18 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/session/service.py"},"region":{"startLine":446}}}],"partialFingerprints":{"codehealthFindingId/v1":"e9760c39bda9735ece84b37bce0a0b6105b67eae0d88f4f432f58d3f51c8d33d"}},{"ruleId":"D1","level":"warning","message":{"text":"adaptation_workflow.validate_adapted_run (cyclomatic 18): adaptation_workflow.validate_adapted_run has cyclomatic complexity 18 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/strategy_discovery/adaptation_workflow.py"},"region":{"startLine":111}}}],"partialFingerprints":{"codehealthFindingId/v1":"dd81dd94c001a3c68f88c483d31207061422d054614a3b0b5a66857b45dfa6ef"}},{"ruleId":"D1","level":"warning","message":{"text":"backtest_tool.run_backtest (cyclomatic 18): backtest_tool.run_backtest has cyclomatic complexity 18 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/backtest_tool.py"},"region":{"startLine":193}}}],"partialFingerprints":{"codehealthFindingId/v1":"fef4199a53a19aa8c14b8f0016bdda2794bd345621793e923c2e4a349c54cd6f"}},{"ruleId":"D1","level":"warning","message":{"text":"fund_flow_tool._fetch_symbol_flow (cyclomatic 18): fund_flow_tool._fetch_symbol_flow has cyclomatic complexity 18 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/fund_flow_tool.py"},"region":{"startLine":118}}}],"partialFingerprints":{"codehealthFindingId/v1":"f1f00fe0c57b6c597de31296ef2e2fb67bf189ad1e017f693b6b19457670b14e"}},{"ruleId":"D1","level":"warning","message":{"text":"InstitutionalHoldingsTool._top_managers (cyclomatic 18): InstitutionalHoldingsTool._top_managers has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/institutional_holdings_tool.py"},"region":{"startLine":2160}}}],"partialFingerprints":{"codehealthFindingId/v1":"9e16180ee02a6a526b54547f1e0c94baaa916bb085d5c4ff93d355c89dbffaaf"}},{"ruleId":"D1","level":"warning","message":{"text":"LoadSkillTool.execute (cyclomatic 18): LoadSkillTool.execute has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/load_skill_tool.py"},"region":{"startLine":207}}}],"partialFingerprints":{"codehealthFindingId/v1":"c7c63ab4231ac1b798fd71cecbe5da2676ee0d74063f3d24b96a52b1a20f2dbf"}},{"ruleId":"D1","level":"warning","message":{"text":"instruments.search_instruments (cyclomatic 18): instruments.search_instruments has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/etoro/instruments.py"},"region":{"startLine":157}}}],"partialFingerprints":{"codehealthFindingId/v1":"c50c10ef6987cdbfee70e0623a72bbcdb8d36a753069a59bbad6f3ee9db24f67"}},{"ruleId":"D1","level":"warning","message":{"text":"sdk.cancel_order (cyclomatic 18): sdk.cancel_order has cyclomatic complexity 18 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/kis/sdk.py"},"region":{"startLine":562}}}],"partialFingerprints":{"codehealthFindingId/v1":"25b2488a3b40c22d301e6d53b79b249c5c2d589a8ca5cd5811a71a83344b31b6"}},{"ruleId":"D1","level":"warning","message":{"text":"_client._usd_contract_value (cyclomatic 18): _client._usd_contract_value has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/mt5/_client.py"},"region":{"startLine":385}}}],"partialFingerprints":{"codehealthFindingId/v1":"80cd9b5ac1e118e878f3f47354b6eb14db41246954dc32e8f6e8d42aab218cbd"}},{"ruleId":"D1","level":"warning","message":{"text":"sdk.place_order (cyclomatic 18): sdk.place_order has cyclomatic complexity 18 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/okx/sdk.py"},"region":{"startLine":373}}}],"partialFingerprints":{"codehealthFindingId/v1":"72748dcdebb98cf1511ff9458fd3e461eafc1eed3580cbc94f13fe82490a17e3"}},{"ruleId":"D1","level":"warning","message":{"text":"ui_services.infer_indicator_periods (cyclomatic 18): ui_services.infer_indicator_periods has cyclomatic complexity 18 (threshold 15). To reduce it, separate the branches: extract each independent case into its own named function so the top-level body reads as a short sequence of named decisions."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/ui_services.py"},"region":{"startLine":151}}}],"partialFingerprints":{"codehealthFindingId/v1":"d71c0e5e5aad5ccebb1ecd9f2794df18cc3eb9df04766279663231749ce0c6a4"}},{"ruleId":"D1","level":"warning","message":{"text":"build_alpha_library.main (cyclomatic 18): build_alpha_library.main has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"wiki/scripts/build_alpha_library.py"},"region":{"startLine":483}}}],"partialFingerprints":{"codehealthFindingId/v1":"bae8bcab5befe8007f20a5e0dd37db955697321c7b764c061c0b61575df7aeb2"}},{"ruleId":"D1","level":"warning","message":{"text":"MonthlyReturnsHeatmap.MonthlyReturnsHeatmap (cyclomatic 18): MonthlyReturnsHeatmap.MonthlyReturnsHeatmap has cyclomatic complexity 18 (threshold 15). Most of this is not in the body itself: 2 of the 18 points are its own statements and the rest belongs to 3 function literals inside it that branch (lines 20, 58, 95). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/charts/MonthlyReturnsHeatmap.tsx"},"region":{"startLine":17}}}],"partialFingerprints":{"codehealthFindingId/v1":"cd6ca14955925986a21775fa7d2f62ca537f85fcc786549ca5086f0b35207d0a"}},{"ruleId":"D1","level":"warning","message":{"text":"ActivityLine.ActivityLine (cyclomatic 18): ActivityLine.ActivityLine has cyclomatic complexity 18 (threshold 15). Of this number, 10 points are the body\u0027s own statements and 8 belong to 4 function literals inside it that branch. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/chat/ActivityLine.tsx"},"region":{"startLine":62}}}],"partialFingerprints":{"codehealthFindingId/v1":"2ea02dee33a335cf1d9512092a8eb12e2a4aa6925694976c84060eb840cba2db"}},{"ruleId":"D1","level":"warning","message":{"text":"ToolProgressIndicator.calculateEta (cyclomatic 18): ToolProgressIndicator.calculateEta has cyclomatic complexity 18 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/chat/ToolProgressIndicator.tsx"},"region":{"startLine":15}}}],"partialFingerprints":{"codehealthFindingId/v1":"067899b2fc0ff325140a3b2b79fa1a6753c112161fcccf0c43f51ffa4243f3b9"}},{"ruleId":"D1","level":"warning","message":{"text":"ConfirmDialog.ConfirmDialog (cyclomatic 18): ConfirmDialog.ConfirmDialog has cyclomatic complexity 18 (threshold 15). Most of this is not in the body itself: 5 of the 18 points are its own statements and the rest belongs to 3 function literals inside it that branch (lines 48, 42, 78). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/common/ConfirmDialog.tsx"},"region":{"startLine":25}}}],"partialFingerprints":{"codehealthFindingId/v1":"5e5211956bd273b6b4cac242e0798a17cda867dd7a0fdd7cc291c1a3c8ab7652"}},{"ruleId":"D1","level":"warning","message":{"text":"SidebarNavigation.SidebarNavigation (cyclomatic 18): SidebarNavigation.SidebarNavigation has cyclomatic complexity 18 (threshold 15). Most of this is not in the body itself: 4 of the 18 points are its own statements and the rest belongs to 5 function literals inside it that branch (lines 44, 40, 20, \u2026). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/layout/SidebarNavigation.tsx"},"region":{"startLine":8}}}],"partialFingerprints":{"codehealthFindingId/v1":"f938870d5487fcc4007bc22e1f9340cdf0efd7f74e6c2387a503ca8078d0e3ec"}},{"ruleId":"D1","level":"warning","message":{"text":"options.volatilitySurfaceIssue (cyclomatic 18): options.volatilitySurfaceIssue has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/lib/options.ts"},"region":{"startLine":292}}}],"partialFingerprints":{"codehealthFindingId/v1":"e0afd913f82e4d02fd3aad56ec8efebb993419c5ca1cd6f7abfc1f2e90eef764"}},{"ruleId":"D1","level":"warning","message":{"text":"tearsheet.computeMonthlyReturns (cyclomatic 18): tearsheet.computeMonthlyReturns has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/lib/tearsheet.ts"},"region":{"startLine":106}}}],"partialFingerprints":{"codehealthFindingId/v1":"d4253fe8251982c52ca315098119413a1a84cf39193086be3da08241ecc3c740"}},{"ruleId":"D1","level":"warning","message":{"text":"AlphaZoo.CompareView (cyclomatic 18): AlphaZoo.CompareView has cyclomatic complexity 18 (threshold 15). Of this number, 12 points are the body\u0027s own statements and 6 belong to 3 function items inside it that branch. To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/AlphaZoo.tsx"},"region":{"startLine":1027}}}],"partialFingerprints":{"codehealthFindingId/v1":"e1ba6fa1da53f1d9f3b4310b015ccc52c493ec73d36701fe3f7ad9eee342ab00"}},{"ruleId":"D1","level":"warning","message":{"text":"Portfolio.AccountCard (cyclomatic 18): Portfolio.AccountCard has cyclomatic complexity 18 (threshold 15). Of this number, 16 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Portfolio.tsx"},"region":{"startLine":547}}}],"partialFingerprints":{"codehealthFindingId/v1":"c1e4233c01d0488428e2d6c0ae3497aa79c2a94a1cae212511ec15edfdec6757"}},{"ruleId":"D1","level":"warning","message":{"text":"loader_health.check_frame (cyclomatic 17): loader_health.check_frame has cyclomatic complexity 17 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loader_health.py"},"region":{"startLine":147}}}],"partialFingerprints":{"codehealthFindingId/v1":"c5da77e47b0fcc97f93d84a062dc4f42233352a28669932323c676e092aa2919"}},{"ruleId":"D1","level":"warning","message":{"text":"fundamentals_loader._extract_concept_series (cyclomatic 17): fundamentals_loader._extract_concept_series 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/fundamentals_loader.py"},"region":{"startLine":48}}}],"partialFingerprints":{"codehealthFindingId/v1":"8365e4076adc939cd0ae30ea117d0835eeb21f604193fe38f9845a1173d4716f"}},{"ruleId":"D1","level":"warning","message":{"text":"FutuLoader.fetch (cyclomatic 17): FutuLoader.fetch 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/futu.py"},"region":{"startLine":150}}}],"partialFingerprints":{"codehealthFindingId/v1":"20ae58b810213672d44a3dfefa8c7b7f9aee53cafc8c2dc557439f81898acfc9"}},{"ruleId":"D1","level":"warning","message":{"text":"mt5_loader._ensure_initialized (cyclomatic 17): mt5_loader._ensure_initialized has cyclomatic complexity 17 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/mt5_loader.py"},"region":{"startLine":77}}}],"partialFingerprints":{"codehealthFindingId/v1":"ceb80fbe0a9dd875c5fd1231e34f58db878977b41b16613234f9144ce88df188"}},{"ruleId":"D1","level":"warning","message":{"text":"runner._ast_config_keys (cyclomatic 17): runner._ast_config_keys 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/runner.py"},"region":{"startLine":1340}}}],"partialFingerprints":{"codehealthFindingId/v1":"ac21e7759018e35382f6034b8cbca4f8a1ab192b593a7ee3beb86a4d5f157062"}},{"ruleId":"D1","level":"warning","message":{"text":"_legacy._handle_swarm_command (cyclomatic 17): _legacy._handle_swarm_command has cyclomatic complexity 17 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":2012}}}],"partialFingerprints":{"codehealthFindingId/v1":"a4dd4de2812e4ea401776484456fbe5e211d3ed3c5edde1ef762881c55e8f859"}},{"ruleId":"D1","level":"warning","message":{"text":"FiguresBlock.match (cyclomatic 17): FiguresBlock.match 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/grounding/figures.py"},"region":{"startLine":180}}}],"partialFingerprints":{"codehealthFindingId/v1":"605b8cbdd7b877c52995ce55047d26a6598f6ada6b2e0f1139e54d1c1a4a2253"}},{"ruleId":"D1","level":"warning","message":{"text":"policies._records_at (cyclomatic 17): policies._records_at has cyclomatic complexity 17 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/grounding/policies.py"},"region":{"startLine":2664}}}],"partialFingerprints":{"codehealthFindingId/v1":"8ed5574c853c2a8e3ad76e8f47a3a2e1350d7bb4d1f2401cd29e4ea786a9bf33"}},{"ruleId":"D1","level":"warning","message":{"text":"assertions._evidence_verdicts (cyclomatic 17): assertions._evidence_verdicts has cyclomatic complexity 17 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/harness/assertions.py"},"region":{"startLine":456}}}],"partialFingerprints":{"codehealthFindingId/v1":"1d3476f7b92ae7495355cde5e6561c8408df6bc9c5798bf752f59ab836b6750c"}},{"ruleId":"D1","level":"warning","message":{"text":"context_compact._fix_tool_pairs (cyclomatic 17): context_compact._fix_tool_pairs 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/agent/context_compact.py"},"region":{"startLine":394}}}],"partialFingerprints":{"codehealthFindingId/v1":"2c31e5a66fe5bff7572f30b34de5665c385aa238bc2a68655cdc56f6e43fb7dc"}},{"ruleId":"D1","level":"warning","message":{"text":"settings_routes._build_llm_settings_response (cyclomatic 17): settings_routes._build_llm_settings_response 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/api/settings_routes.py"},"region":{"startLine":203}}}],"partialFingerprints":{"codehealthFindingId/v1":"93b93768093212bb75868a8d6ac398ed5c3f8b71312174d2b54c6900134946bf"}},{"ruleId":"D1","level":"warning","message":{"text":"EmailChannel._extract_text_body (cyclomatic 17): EmailChannel._extract_text_body 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/email.py"},"region":{"startLine":919}}}],"partialFingerprints":{"codehealthFindingId/v1":"c79a9794302dd445b064cfc04915a48ba4f10fa4e6d617d58eba108090113ee0"}},{"ruleId":"D1","level":"warning","message":{"text":"EmailChannel._check_authentication_results (cyclomatic 17): EmailChannel._check_authentication_results 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/email.py"},"region":{"startLine":1095}}}],"partialFingerprints":{"codehealthFindingId/v1":"5bd5b00b9ab2f2a29515dacf2b9bcf25f864b022fb7f1fcaa2d36c949e61cf49"}},{"ruleId":"D1","level":"warning","message":{"text":"NapcatChannel._parse_segments (cyclomatic 17): NapcatChannel._parse_segments 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/napcat.py"},"region":{"startLine":309}}}],"partialFingerprints":{"codehealthFindingId/v1":"013b85cfea9c7d2c97b99efe80ff067524f7c8f0860907560e3f0416cbdcf7f8"}},{"ruleId":"D1","level":"warning","message":{"text":"QQChannel._on_message (cyclomatic 17): QQChannel._on_message has cyclomatic complexity 17 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/qq.py"},"region":{"startLine":531}}}],"partialFingerprints":{"codehealthFindingId/v1":"acc98700b15ef562194fe35276dc89b17c44d834a479ebf5155d3912760079d3"}},{"ruleId":"D1","level":"warning","message":{"text":"WebSocketChannel._save_envelope_media (cyclomatic 17): WebSocketChannel._save_envelope_media 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/websocket.py"},"region":{"startLine":604}}}],"partialFingerprints":{"codehealthFindingId/v1":"309bb2a01bfdfc2e895e04f4b9379a13a18a86a8e281e7168210459a9ce74467"}},{"ruleId":"D1","level":"warning","message":{"text":"WeixinChannel._qr_login (cyclomatic 17): WeixinChannel._qr_login 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/weixin.py"},"region":{"startLine":342}}}],"partialFingerprints":{"codehealthFindingId/v1":"63cc3b39469bd5b5bbd2c4f586c5fcc0b25194235dd529bac944a7a19fc3235e"}},{"ruleId":"D1","level":"warning","message":{"text":"whatsapp._media_message (cyclomatic 17): whatsapp._media_message has cyclomatic complexity 17 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/whatsapp.py"},"region":{"startLine":215}}}],"partialFingerprints":{"codehealthFindingId/v1":"642eaa4c570de453d070181b06c476c320d632af430fe86777de33243db2f1d1"}},{"ruleId":"D1","level":"warning","message":{"text":"data_availability.build_availability_contract (cyclomatic 17): data_availability.build_availability_contract 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/data_availability.py"},"region":{"startLine":229}}}],"partialFingerprints":{"codehealthFindingId/v1":"406f5576d47c78ec1af87eb629d5450b71dc85273a7eb68ed7d590ab187ad45b"}},{"ruleId":"D1","level":"warning","message":{"text":"Registry.compute (cyclomatic 17): Registry.compute has cyclomatic complexity 17 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/registry.py"},"region":{"startLine":325}}}],"partialFingerprints":{"codehealthFindingId/v1":"14ff1e05550e8c75d79977eb09ef23f9fd3467c39b569a8d0f2ee5c09975b88e"}},{"ruleId":"D1","level":"warning","message":{"text":"PersistentMemory.remove (cyclomatic 17): PersistentMemory.remove has cyclomatic complexity 17 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/memory/persistent.py"},"region":{"startLine":649}}}],"partialFingerprints":{"codehealthFindingId/v1":"7232e11a264b4e74f43a61483bdea42b05d5793587494f4e2399dda5ca4baebb"}},{"ruleId":"D1","level":"warning","message":{"text":"compatibility.adapt_and_validate_payloads (cyclomatic 17): compatibility.adapt_and_validate_payloads 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/portfolio/compatibility.py"},"region":{"startLine":131}}}],"partialFingerprints":{"codehealthFindingId/v1":"348091f9ae097dd7fc2790224bbef3188685cdbc6849607cad7827d36ab47aae"}},{"ruleId":"D1","level":"warning","message":{"text":"PortfolioImportStore.create (cyclomatic 17): PortfolioImportStore.create has cyclomatic complexity 17 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/portfolio/imports.py"},"region":{"startLine":46}}}],"partialFingerprints":{"codehealthFindingId/v1":"5187a0ac4f63d2aeea03572a590b8c04d869f1059d9d7fdf8d2f9d8a8c1c3c71"}},{"ruleId":"D1","level":"warning","message":{"text":"normalization.account_total_usd (cyclomatic 17): normalization.account_total_usd 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/portfolio/normalization.py"},"region":{"startLine":248}}}],"partialFingerprints":{"codehealthFindingId/v1":"f1f71a633469f26917b5d7d68c8b9c769e8350ce4880d429e192c3b8358b8dc7"}},{"ruleId":"D1","level":"warning","message":{"text":"PortfolioStore.history (cyclomatic 17): PortfolioStore.history 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/portfolio/store.py"},"region":{"startLine":143}}}],"partialFingerprints":{"codehealthFindingId/v1":"bbfec4afa6bb4e76a594dbdc456ce1e9cd9e108a64687f36f31b7f33f06fd79c"}},{"ruleId":"D1","level":"warning","message":{"text":"settings.get_llm_credentials (cyclomatic 17): settings.get_llm_credentials 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/providers/settings.py"},"region":{"startLine":173}}}],"partialFingerprints":{"codehealthFindingId/v1":"e43a1219d8d59739ffe9a15c4fb83edb8c804bb9cfa90f103cc6c302ddd03e67"}},{"ruleId":"D1","level":"warning","message":{"text":"fixedincome.fit_yield_curve (cyclomatic 17): fixedincome.fit_yield_curve has cyclomatic complexity 17 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/fixedincome.py"},"region":{"startLine":733}}}],"partialFingerprints":{"codehealthFindingId/v1":"7508b08da8084116b2c354b538ac86e6425fa9cde1cfa528a64df3af8e3f5e57"}},{"ruleId":"D1","level":"warning","message":{"text":"execution.freeze_run (cyclomatic 17): execution.freeze_run 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/research_lab/execution.py"},"region":{"startLine":62}}}],"partialFingerprints":{"codehealthFindingId/v1":"bd4647b7818501b47f7696aa8800873dbe6c7781c587ccc5e58e9361daee682b"}},{"ruleId":"D1","level":"warning","message":{"text":"SignalEngine.generate (cyclomatic 17): SignalEngine.generate 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/skills/multi-factor/example_signal_engine.py"},"region":{"startLine":94}}}],"partialFingerprints":{"codehealthFindingId/v1":"137b22eb49499cbf0c6914c71cbdd418ccb1bacdbd822c0a194cc63b010b5b9e"}},{"ruleId":"D1","level":"warning","message":{"text":"_ShortPremium._run (cyclomatic 17): _ShortPremium._run 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/skills/options-strategy/example_signal_engine.py"},"region":{"startLine":123}}}],"partialFingerprints":{"codehealthFindingId/v1":"4f62e75c49e5804764374afd33d8336ca1ab6152f5eb1b167e08a5d8bd46593a"}},{"ruleId":"D1","level":"warning","message":{"text":"sec_filings_example.recent_filings (cyclomatic 17): sec_filings_example.recent_filings 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/skills/sec-edgar/scripts/sec_filings_example.py"},"region":{"startLine":47}}}],"partialFingerprints":{"codehealthFindingId/v1":"4470b13e07db14af9e58c9851ee568c6654905ea70e56016c829dfa5fc99fe7a"}},{"ruleId":"D1","level":"warning","message":{"text":"BackgroundManager._execute (cyclomatic 17): BackgroundManager._execute 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/background_tools.py"},"region":{"startLine":296}}}],"partialFingerprints":{"codehealthFindingId/v1":"e55597d28224979b96e7a54369212bc74dea78a1d9f92224a2e80dfddeb49c86"}},{"ruleId":"D1","level":"warning","message":{"text":"backtest_runs_tool.list_backtest_runs (cyclomatic 17): backtest_runs_tool.list_backtest_runs 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/backtest_runs_tool.py"},"region":{"startLine":133}}}],"partialFingerprints":{"codehealthFindingId/v1":"91ac8aa99ec694deb18fc463d710c55a7ff027bc9f684a029c4f61896adea694"}},{"ruleId":"D1","level":"warning","message":{"text":"backtest_tool._record_bench_if_declared (cyclomatic 17): backtest_tool._record_bench_if_declared has cyclomatic complexity 17 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/backtest_tool.py"},"region":{"startLine":106}}}],"partialFingerprints":{"codehealthFindingId/v1":"f7f20a5413ea2ba488681ae82917a28753deb118ef066cae58099977fb344df7"}},{"ruleId":"D1","level":"warning","message":{"text":"financial_statements_tool._fetch_yahoo_statement (cyclomatic 17): financial_statements_tool._fetch_yahoo_statement 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/financial_statements_tool.py"},"region":{"startLine":333}}}],"partialFingerprints":{"codehealthFindingId/v1":"752d055343747dc8e4cc3d3b55d742af439eaf5f566ae120cec825109d37e2a1"}},{"ruleId":"D1","level":"warning","message":{"text":"institutional_holdings_tool._parse_information_table (cyclomatic 17): institutional_holdings_tool._parse_information_table has cyclomatic complexity 17 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/institutional_holdings_tool.py"},"region":{"startLine":722}}}],"partialFingerprints":{"codehealthFindingId/v1":"d602f65fa53ce9e3815424e88e5f5cf82ed3fac58f41cdfc232292ad71e9851f"}},{"ruleId":"D1","level":"warning","message":{"text":"quantlib_tool._encode (cyclomatic 17): quantlib_tool._encode has cyclomatic complexity 17 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/quantlib_tool.py"},"region":{"startLine":184}}}],"partialFingerprints":{"codehealthFindingId/v1":"cbb0246b3ac0e2d66958fb12fb8434a25181a1395d3e943e30a2202e57c1ce53"}},{"ruleId":"D1","level":"warning","message":{"text":"SdmDecayScanTool.execute (cyclomatic 17): SdmDecayScanTool.execute 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/sdm_decay_scan_tool.py"},"region":{"startLine":64}}}],"partialFingerprints":{"codehealthFindingId/v1":"f59ee6d600eadce7b24e77865b19ce583b3e8b84d23a10637767234d006e4bf6"}},{"ruleId":"D1","level":"warning","message":{"text":"sec_filings_tool._parse_filings (cyclomatic 17): sec_filings_tool._parse_filings has cyclomatic complexity 17 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/sec_filings_tool.py"},"region":{"startLine":187}}}],"partialFingerprints":{"codehealthFindingId/v1":"7a7df60eb295b0a746893d51db2cc7b52be19648307b3092289cf511d0bcb17d"}},{"ruleId":"D1","level":"warning","message":{"text":"technical_indicator_tool._extract_series (cyclomatic 17): technical_indicator_tool._extract_series has cyclomatic complexity 17 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/technical_indicator_tool.py"},"region":{"startLine":47}}}],"partialFingerprints":{"codehealthFindingId/v1":"abf85f966f8b400efdfdb2e5f902e35e3879a6647ff75333f648b58856185327"}},{"ruleId":"D1","level":"warning","message":{"text":"trade_journal_parsers._infer_market_from_symbol (cyclomatic 17): trade_journal_parsers._infer_market_from_symbol 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/trade_journal_parsers.py"},"region":{"startLine":694}}}],"partialFingerprints":{"codehealthFindingId/v1":"3a37fd1e2c2cadc984bdea66b6dfc685e5d2fd3cff2e0c6e65aadc4852b09da2"}},{"ruleId":"D1","level":"warning","message":{"text":"usdm._join_positions (cyclomatic 17): usdm._join_positions 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/binance/usdm.py"},"region":{"startLine":144}}}],"partialFingerprints":{"codehealthFindingId/v1":"bdafe7455a1f765af0c8c3a93ae35057041ec883e4a434bad79b70aa0b0fc54c"}},{"ruleId":"D1","level":"warning","message":{"text":"sdk.place_order (cyclomatic 17): sdk.place_order has cyclomatic complexity 17 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/dhan/sdk.py"},"region":{"startLine":439}}}],"partialFingerprints":{"codehealthFindingId/v1":"d5a0d966ac6d9907a199c8d2066582260ad78f7168141552a173f36c3c6b5d4c"}},{"ruleId":"D1","level":"warning","message":{"text":"EtoroClient.request (cyclomatic 17): EtoroClient.request 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/etoro/client.py"},"region":{"startLine":280}}}],"partialFingerprints":{"codehealthFindingId/v1":"ab6e62fb8cbc9d83b31def352eb7302f780573a900ba3ccfb941b3e335d96d69"}},{"ruleId":"D1","level":"warning","message":{"text":"service._sdk_config (cyclomatic 17): service._sdk_config has cyclomatic complexity 17 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/service.py"},"region":{"startLine":82}}}],"partialFingerprints":{"codehealthFindingId/v1":"3ba2a5005925ece067adfa09f6f831275218712fcd075233ea0b50a1980b34c7"}},{"ruleId":"D1","level":"warning","message":{"text":"Layout.LanguageSwitcher (cyclomatic 17): Layout.LanguageSwitcher has cyclomatic complexity 17 (threshold 15). Of this number, 9 points are the body\u0027s own statements and 8 belong to 5 function literals inside it that branch. To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/layout/Layout.tsx"},"region":{"startLine":393}}}],"partialFingerprints":{"codehealthFindingId/v1":"e692c2da1c81f35c20a4c74014e344fa4538c87943507ab61092f1f36355057f"}},{"ruleId":"D1","level":"warning","message":{"text":"StrategyBuilder.StrategyBuilder (cyclomatic 17): StrategyBuilder.StrategyBuilder has cyclomatic complexity 17 (threshold 15). Of this number, 9 points are the body\u0027s own statements and 8 belong to 5 function items inside it that branch. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/options/StrategyBuilder.tsx"},"region":{"startLine":25}}}],"partialFingerprints":{"codehealthFindingId/v1":"62bdc5783b23aa5fbc7c71c41ba477ef61a4218a4b23aa86353c5ddf662a286a"}},{"ruleId":"D1","level":"warning","message":{"text":"Settings.Settings::submit (cyclomatic 17): Settings.Settings::submit has cyclomatic complexity 17 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages. This shape REPEATS in the file: 2 other methods here (Settings.Settings, Settings.Settings::submitDataSources) have the same decision points, in the same order, at the same nesting depths \u2014 so this is one pattern written 3 times rather than 3 independent problems. Splitting this body alone leaves the other 2 exactly as they are. Where these are variations on one operation, the change that clears all 3 is the shared one: lift the common shape into a single routine the variants call, parameterised by whatever genuinely differs between them, and keep in each method only the part that is not shared."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Settings.tsx"},"region":{"startLine":232}}}],"partialFingerprints":{"codehealthFindingId/v1":"ef1678b8d4bd757ce34c6de4c5e1c8fca20b0e02abe64c34759fccc18bcea7aa"}},{"ruleId":"D1","level":"warning","message":{"text":"correlation.infer_market (cyclomatic 16): correlation.infer_market has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/correlation.py"},"region":{"startLine":20}}}],"partialFingerprints":{"codehealthFindingId/v1":"51b6b69a3ef67e48f54f1ebf95f3df2fca5adb9ff0bb9d1fb1a50549ddabad55"}},{"ruleId":"D1","level":"warning","message":{"text":"ArgentinaEquityEngine.prepare_market_data (cyclomatic 16): ArgentinaEquityEngine.prepare_market_data has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/engines/argentina_equity.py"},"region":{"startLine":469}}}],"partialFingerprints":{"codehealthFindingId/v1":"389fd715baac99d7e1ff8c9098bc0465225ee1ceb1886d24c562f32d6e5e4964"}},{"ruleId":"D1","level":"warning","message":{"text":"fmp_loader._parse_historical (cyclomatic 16): fmp_loader._parse_historical has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/fmp_loader.py"},"region":{"startLine":220}}}],"partialFingerprints":{"codehealthFindingId/v1":"30860312f94218e1f2b017f5d4bf992cbb9717e70ceb7cbefde07897d6090124"}},{"ruleId":"D1","level":"warning","message":{"text":"metrics.win_rate_and_stats (cyclomatic 16): metrics.win_rate_and_stats has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/metrics.py"},"region":{"startLine":386}}}],"partialFingerprints":{"codehealthFindingId/v1":"68111aebeb3b3de9718c1056491c11de02f6a176c8f5ebd39896b369db668303"}},{"ruleId":"D1","level":"warning","message":{"text":"TurnoverAwareOptimizer.__init__ (cyclomatic 16): TurnoverAwareOptimizer.__init__ has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/optimizers/turnover_aware.py"},"region":{"startLine":52}}}],"partialFingerprints":{"codehealthFindingId/v1":"f0c210a484e0076dffee4d1e2b027a65a29128615db9785cdb4cfb8573ad30f3"}},{"ruleId":"D1","level":"warning","message":{"text":"options_payoff._analytic_breakevens (cyclomatic 16): options_payoff._analytic_breakevens has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/options_payoff.py"},"region":{"startLine":205}}}],"partialFingerprints":{"codehealthFindingId/v1":"27da1d1d6d2bb0c2d8439eff61a61435be7578002f612af5928d9770b35ffd7a"}},{"ruleId":"D1","level":"warning","message":{"text":"validation.bootstrap_sharpe_ci (cyclomatic 16): validation.bootstrap_sharpe_ci has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/validation.py"},"region":{"startLine":152}}}],"partialFingerprints":{"codehealthFindingId/v1":"854800b59797bc6fbc79c9b4ce1f10465a31a3d9964c3933097b1b1fc46aac24"}},{"ruleId":"D1","level":"warning","message":{"text":"_legacy._show_settings (cyclomatic 16): _legacy._show_settings has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":1894}}}],"partialFingerprints":{"codehealthFindingId/v1":"754c3a519a345eddb82894a7d5d3161c5eb070fc403328a87ce9d696b07fae09"}},{"ruleId":"D1","level":"warning","message":{"text":"main._render_mandate_proposal (cyclomatic 16): main._render_mandate_proposal has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/main.py"},"region":{"startLine":1008}}}],"partialFingerprints":{"codehealthFindingId/v1":"757f637c5394de58b66776c82ed72c1dae7dd9d39d91027980f90ad5153d613a"}},{"ruleId":"D1","level":"warning","message":{"text":"evidence._metric_kind_for_path (cyclomatic 16): evidence._metric_kind_for_path has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/grounding/evidence.py"},"region":{"startLine":618}}}],"partialFingerprints":{"codehealthFindingId/v1":"e04cd891a7d4b41963d6ca1ef03ea38f6e12c7b0c4ca8f1b4bf34df4b58f04f2"}},{"ruleId":"D1","level":"warning","message":{"text":"figures._writes_decimal_commas (cyclomatic 16): figures._writes_decimal_commas has cyclomatic complexity 16 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/grounding/figures.py"},"region":{"startLine":610}}}],"partialFingerprints":{"codehealthFindingId/v1":"7c80490b7bd1a9d51fa498297b099601fb0d98778796b42db6af72b04d1b54b5"}},{"ruleId":"D1","level":"warning","message":{"text":"_PolicyMixin._unknown_call_field_ref_candidates (cyclomatic 16): _PolicyMixin._unknown_call_field_ref_candidates has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/grounding/policies.py"},"region":{"startLine":1362}}}],"partialFingerprints":{"codehealthFindingId/v1":"b62e9111ba0e82ae35cb617541e7ace106891f196239854bce5d0b214165e1df"}},{"ruleId":"D1","level":"warning","message":{"text":"assertions._tool_verdicts (cyclomatic 16): assertions._tool_verdicts has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/harness/assertions.py"},"region":{"startLine":261}}}],"partialFingerprints":{"codehealthFindingId/v1":"8a0363ec8fc991b2307b809add26b7ec4865454a13e45f1d1839a7c3a6087274"}},{"ruleId":"D1","level":"warning","message":{"text":"HarnessCase.from_dict (cyclomatic 16): HarnessCase.from_dict has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/harness/schema.py"},"region":{"startLine":33}}}],"partialFingerprints":{"codehealthFindingId/v1":"32a130f5e1fd0fd161470e56a689831cbf7b163c706bc0fc3dcd248ad3fc89c7"}},{"ruleId":"D1","level":"warning","message":{"text":"llm_usage._normalize_llm_usage (cyclomatic 16): llm_usage._normalize_llm_usage has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/agent/llm_usage.py"},"region":{"startLine":35}}}],"partialFingerprints":{"codehealthFindingId/v1":"04b8ace93d81a61187905269af56340461e93f84a6639d47b5c7a9a5f4a42ba6"}},{"ruleId":"D1","level":"warning","message":{"text":"runs_routes._iter_factor_series_files (cyclomatic 16): runs_routes._iter_factor_series_files has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/api/runs_routes.py"},"region":{"startLine":222}}}],"partialFingerprints":{"codehealthFindingId/v1":"f0657a96b1633da201bb82ce9dfa5bed1d373c36e0fe051c821238f8a12ee8f9"}},{"ruleId":"D1","level":"warning","message":{"text":"FeishuChannel._format_tool_hint_lines (cyclomatic 16): FeishuChannel._format_tool_hint_lines has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/feishu.py"},"region":{"startLine":2442}}}],"partialFingerprints":{"codehealthFindingId/v1":"d5807b9da40d9160f9c4a97cb826a4ad56e0326d5516818b4a2407c521e7b805"}},{"ruleId":"D1","level":"warning","message":{"text":"MatrixChannel._download_media_bytes (cyclomatic 16): MatrixChannel._download_media_bytes has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/matrix.py"},"region":{"startLine":873}}}],"partialFingerprints":{"codehealthFindingId/v1":"eac90236605ccd3827b33ad3a8363d773c2d3c1ee19316a5af225eb73efba9ad"}},{"ruleId":"D1","level":"warning","message":{"text":"MSTeamsChannel._prune_conversation_refs (cyclomatic 16): MSTeamsChannel._prune_conversation_refs has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/msteams.py"},"region":{"startLine":727}}}],"partialFingerprints":{"codehealthFindingId/v1":"0f445e0fd370bad0a549517e637db0d0ebfd40034783c633a4fd728e7ef770a9"}},{"ruleId":"D1","level":"warning","message":{"text":"NapcatChannel._on_message (cyclomatic 16): NapcatChannel._on_message has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/napcat.py"},"region":{"startLine":233}}}],"partialFingerprints":{"codehealthFindingId/v1":"4aa2426042cb55d9682f2ae964626765491d98270f59053da6b27d3285d5ecc7"}},{"ruleId":"D1","level":"warning","message":{"text":"QQChannel._read_media_bytes (cyclomatic 16): QQChannel._read_media_bytes has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/qq.py"},"region":{"startLine":408}}}],"partialFingerprints":{"codehealthFindingId/v1":"0e279851fd0cb5d8cb8a1694d6a4091bfa11525e0f8635b4c030a71ff0c12498"}},{"ruleId":"D1","level":"warning","message":{"text":"SignalChannel._check_inbound_policy (cyclomatic 16): SignalChannel._check_inbound_policy has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/signal.py"},"region":{"startLine":839}}}],"partialFingerprints":{"codehealthFindingId/v1":"40fb813661c5c934107b846d815d22ab687a36f56a08f250bd01b185f8ecdc69"}},{"ruleId":"D1","level":"warning","message":{"text":"SlackChannel._on_block_action (cyclomatic 16): SlackChannel._on_block_action has cyclomatic complexity 16 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/slack.py"},"region":{"startLine":535}}}],"partialFingerprints":{"codehealthFindingId/v1":"6d198d1d360df895acbe4af24de0335b790475c4ac3cb493f59a8a086203f0e2"}},{"ruleId":"D1","level":"warning","message":{"text":"__main__.run_history (cyclomatic 16): __main__.run_history has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/data_gateway/__main__.py"},"region":{"startLine":28}}}],"partialFingerprints":{"codehealthFindingId/v1":"ab5478e957ad2f82ab5c96a43ea4ad060006afd860d1fb951c636d6be59ffd15"}},{"ruleId":"D1","level":"warning","message":{"text":"HistoryStore.start (cyclomatic 16): HistoryStore.start has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/data_gateway/history_store.py"},"region":{"startLine":439}}}],"partialFingerprints":{"codehealthFindingId/v1":"1401b2c51ac227aa014de973bb131f11a1ac6518b2011bb4bac57a43f4a6a239"}},{"ruleId":"D1","level":"warning","message":{"text":"sources.cboe_options (cyclomatic 16): sources.cboe_options has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/data_gateway/sources.py"},"region":{"startLine":131}}}],"partialFingerprints":{"codehealthFindingId/v1":"f8b013ada5b0678c3fd90e21f238076b34c21ba7314f9e3d58b0b5dba78bf1a5"}},{"ruleId":"D1","level":"warning","message":{"text":"Topic.parse (cyclomatic 16): Topic.parse has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/data_gateway/streams.py"},"region":{"startLine":34}}}],"partialFingerprints":{"codehealthFindingId/v1":"0856d97d94214059d717c11e80fe0751a3855d172009e72cea12f56078672b1f"}},{"ruleId":"D1","level":"warning","message":{"text":"compare_runner.compare_alphas (cyclomatic 16): compare_runner.compare_alphas has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/compare_runner.py"},"region":{"startLine":88}}}],"partialFingerprints":{"codehealthFindingId/v1":"c780b6834b3d1e654b52bbdae4438e174243c288bb4e67b3f1b0b2e570c4801d"}},{"ruleId":"D1","level":"warning","message":{"text":"data_availability._source_for (cyclomatic 16): data_availability._source_for has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/data_availability.py"},"region":{"startLine":170}}}],"partialFingerprints":{"codehealthFindingId/v1":"305687a47f7bedf57476391e8e06530de1c461c649dad450c64d71cdabb79fb8"}},{"ruleId":"D1","level":"warning","message":{"text":"GoalStore._validate_completion_audit (cyclomatic 16): GoalStore._validate_completion_audit has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/goal/store.py"},"region":{"startLine":899}}}],"partialFingerprints":{"codehealthFindingId/v1":"eb3364f7af0b24c4dcbe5dbff8808a1e68defa2d9b31ce53b0c5933e406119e0"}},{"ruleId":"D1","level":"warning","message":{"text":"cli_handlers._emit_detail (cyclomatic 16): cli_handlers._emit_detail has cyclomatic complexity 16 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/hypotheses/cli_handlers.py"},"region":{"startLine":105}}}],"partialFingerprints":{"codehealthFindingId/v1":"83e42709595f665fb0b334669da64f7e990a2ab481c70577256b94b43b7b11da"}},{"ruleId":"D1","level":"warning","message":{"text":"LiveRunner._run_preemptive_sweep (cyclomatic 16): LiveRunner._run_preemptive_sweep has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/live/runtime/runner.py"},"region":{"startLine":624}}}],"partialFingerprints":{"codehealthFindingId/v1":"b59058b7745fe23fd89a0390c920975c750eb8cb982812d608dcf5ada5774071"}},{"ruleId":"D1","level":"warning","message":{"text":"sdk_order_gate._recover_correlated_fill (cyclomatic 16): sdk_order_gate._recover_correlated_fill has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/live/sdk_order_gate.py"},"region":{"startLine":620}}}],"partialFingerprints":{"codehealthFindingId/v1":"76c881d88132684d3a767b540bf4b44b8548a9715783daa7ddffc4921d1cbe5c"}},{"ruleId":"D1","level":"warning","message":{"text":"extraetf._parse_decimal (cyclomatic 16): extraetf._parse_decimal has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/portfolio/extraetf.py"},"region":{"startLine":787}}}],"partialFingerprints":{"codehealthFindingId/v1":"e434ab61eb576629f6ddedf7d9300c500ad087f35909358acb49e136fe5e4bee"}},{"ruleId":"D1","level":"warning","message":{"text":"PortfolioService.latest (cyclomatic 16): PortfolioService.latest has cyclomatic complexity 16 (threshold 15). To reduce it, separate the branches: extract each independent case into its own named function so the top-level body reads as a short sequence of named decisions."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/portfolio/service.py"},"region":{"startLine":566}}}],"partialFingerprints":{"codehealthFindingId/v1":"c04b344fa2df50a845f36d5123ca5bfecc5f8a931bd582859e493b670df1a866"}},{"ruleId":"D1","level":"warning","message":{"text":"discovery._list_provider_models (cyclomatic 16): discovery._list_provider_models has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/providers/discovery.py"},"region":{"startLine":201}}}],"partialFingerprints":{"codehealthFindingId/v1":"13048065847a4b299c995da1877f455820d664a55e5a88d3be95c736313fd1c8"}},{"ruleId":"D1","level":"warning","message":{"text":"llm._build_anthropic (cyclomatic 16): llm._build_anthropic has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/providers/llm.py"},"region":{"startLine":1232}}}],"partialFingerprints":{"codehealthFindingId/v1":"95e99d3ccf1b28a8fd55db5d3e1b279631a14dbb4108dd7606bc6bb1b5813d80"}},{"ruleId":"D1","level":"warning","message":{"text":"microstructure.vpin (cyclomatic 16): microstructure.vpin has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/microstructure.py"},"region":{"startLine":132}}}],"partialFingerprints":{"codehealthFindingId/v1":"e538e7e08a170b81ce3663bbfbae25ba9c35c50961108ba980fa20ffac4581fb"}},{"ruleId":"D1","level":"warning","message":{"text":"SignalEngine._find_abc (cyclomatic 16): SignalEngine._find_abc has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/skills/elliott-wave/example_signal_engine.py"},"region":{"startLine":285}}}],"partialFingerprints":{"codehealthFindingId/v1":"b306b6037edee8e896b75bb8f9df56b18277bce9516dd532c04be8d29f0b19c0"}},{"ruleId":"D1","level":"warning","message":{"text":"_StockPlusOption._run (cyclomatic 16): _StockPlusOption._run has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/skills/options-strategy/example_signal_engine.py"},"region":{"startLine":268}}}],"partialFingerprints":{"codehealthFindingId/v1":"9756a3bfdaa47e07512c02886dd269ac03f065765056ad0123cc75b99e84614e"}},{"ruleId":"D1","level":"warning","message":{"text":"financial_statements_tool._synthesize_fiscal_q4 (cyclomatic 16): financial_statements_tool._synthesize_fiscal_q4 has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/financial_statements_tool.py"},"region":{"startLine":576}}}],"partialFingerprints":{"codehealthFindingId/v1":"f49cc3a22fe5335de53c05795d118b9cc53ecff74b93b1c4ee67aab45910fc00"}},{"ruleId":"D1","level":"warning","message":{"text":"HistoryDataTool.execute (cyclomatic 16): HistoryDataTool.execute has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/history_data_tool.py"},"region":{"startLine":100}}}],"partialFingerprints":{"codehealthFindingId/v1":"38f8f7f566dd0160f77f5c7ac55c1b8e0300b53c91dd3921b7ad726db0e2ae2a"}},{"ruleId":"D1","level":"warning","message":{"text":"data_5m._split_session_days (cyclomatic 16): data_5m._split_session_days has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/paper_trade/data_5m.py"},"region":{"startLine":326}}}],"partialFingerprints":{"codehealthFindingId/v1":"6532489794164d08fe35c40b032eef594b2151c2b105f2dc19c3a61220c715be"}},{"ruleId":"D1","level":"warning","message":{"text":"redaction.is_sensitive_arg (cyclomatic 16): redaction.is_sensitive_arg has cyclomatic complexity 16 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/redaction.py"},"region":{"startLine":284}}}],"partialFingerprints":{"codehealthFindingId/v1":"34753a98285c162ff6ced1f05cffda4f49dc7b8ee38f39479e7c47cfe1e2cb31"}},{"ruleId":"D1","level":"warning","message":{"text":"ReportAuditTool.execute (cyclomatic 16): ReportAuditTool.execute has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/report_audit_tool.py"},"region":{"startLine":561}}}],"partialFingerprints":{"codehealthFindingId/v1":"40292265aa08614ff1f776b2c2f405809ae81fd0590ec46df3b0ba83e83303b2"}},{"ruleId":"D1","level":"warning","message":{"text":"report_audit_tool._parse_md_tables (cyclomatic 16): report_audit_tool._parse_md_tables has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/report_audit_tool.py"},"region":{"startLine":147}}}],"partialFingerprints":{"codehealthFindingId/v1":"2318b3b30f6c93944b7bee0f76aff626a0777ff85c394ce54bd09e4bf92817ed"}},{"ruleId":"D1","level":"warning","message":{"text":"ResearchLabTool.execute (cyclomatic 16): ResearchLabTool.execute has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/research_lab_tool.py"},"region":{"startLine":36}}}],"partialFingerprints":{"codehealthFindingId/v1":"38bd0e34babef6cc00a33aad96573309a599f614966d8ad58603b548f069e354"}},{"ruleId":"D1","level":"warning","message":{"text":"research_papers_tool._arxiv_search (cyclomatic 16): research_papers_tool._arxiv_search has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/research_papers_tool.py"},"region":{"startLine":1110}}}],"partialFingerprints":{"codehealthFindingId/v1":"51a51868d70aac72c35b03ed126b2625f7090dd9587852285229908f61034ddf"}},{"ruleId":"D1","level":"warning","message":{"text":"research_papers_tool._openalex_search (cyclomatic 16): research_papers_tool._openalex_search has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/research_papers_tool.py"},"region":{"startLine":1316}}}],"partialFingerprints":{"codehealthFindingId/v1":"7949856c6f46f4cc0fbf4878460daa44cd7e90ebfec86f52510efc2fdf02f164"}},{"ruleId":"D1","level":"warning","message":{"text":"run_artifact_tool.read_run_artifact (cyclomatic 16): run_artifact_tool.read_run_artifact has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/run_artifact_tool.py"},"region":{"startLine":450}}}],"partialFingerprints":{"codehealthFindingId/v1":"c2de3d90b3c8ea6f1db03651dd9a2bc82eb807cf06586b7b7ae0c8129e4e6b8c"}},{"ruleId":"D1","level":"warning","message":{"text":"trade_journal_tool.analyze_trade_journal (cyclomatic 16): trade_journal_tool.analyze_trade_journal has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/trade_journal_tool.py"},"region":{"startLine":675}}}],"partialFingerprints":{"codehealthFindingId/v1":"878167da7b87ca9ae170fc70bcdf6eda0e8d05e7dfb37dd2bd0d4495733be2e7"}},{"ruleId":"D1","level":"warning","message":{"text":"BinanceConfig.from_mapping (cyclomatic 16): BinanceConfig.from_mapping has cyclomatic complexity 16 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/binance/sdk.py"},"region":{"startLine":75}}}],"partialFingerprints":{"codehealthFindingId/v1":"291b27ea2695d5f1b580d142818b370a0dc474d6662e9f5fc6e13215baae0888"}},{"ruleId":"D1","level":"warning","message":{"text":"sdk._enrich_positions_with_metadata (cyclomatic 16): sdk._enrich_positions_with_metadata has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/etoro/sdk.py"},"region":{"startLine":422}}}],"partialFingerprints":{"codehealthFindingId/v1":"3f5526819fbc35b19a8ad1c11a6a36b98e0987f80c9d926389ec17efb3707868"}},{"ruleId":"D1","level":"warning","message":{"text":"trading.place_order (cyclomatic 16): trading.place_order has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/etoro/trading.py"},"region":{"startLine":32}}}],"partialFingerprints":{"codehealthFindingId/v1":"3a34f18d89abc86570ad189d1b8af6e10f333b1b47fde73c15e73724ef9defa7"}},{"ruleId":"D1","level":"warning","message":{"text":"sdk._request (cyclomatic 16): sdk._request has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/kis/sdk.py"},"region":{"startLine":814}}}],"partialFingerprints":{"codehealthFindingId/v1":"5770fe4e78a66948c1f46015c1f38d7c83050cec64d09edcf1d087ab2a1ccbbc"}},{"ruleId":"D1","level":"warning","message":{"text":"sdk.place_order (cyclomatic 16): sdk.place_order has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/shoonya/sdk.py"},"region":{"startLine":421}}}],"partialFingerprints":{"codehealthFindingId/v1":"d9341dcc16414f94c68a6bf28709f018d60f29141a9b2a32c7016c5b3fd44c74"}},{"ruleId":"D1","level":"warning","message":{"text":"service._call_remote (cyclomatic 16): service._call_remote has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/service.py"},"region":{"startLine":1525}}}],"partialFingerprints":{"codehealthFindingId/v1":"567bf11c2aee34c73d4aa0b08585caff171d198004c716c6c8d7f287b9da7233"}},{"ruleId":"D1","level":"warning","message":{"text":"sync_site_chrome.wiring_problems (cyclomatic 16): sync_site_chrome.wiring_problems has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"wiki/scripts/sync_site_chrome.py"},"region":{"startLine":124}}}],"partialFingerprints":{"codehealthFindingId/v1":"22c8a05ab7db903641b22a30b51955e8c858a587419b1e93e6ebf3bd229e26e9"}},{"ruleId":"D1","level":"warning","message":{"text":"StrategyResearchDashboard.getStrategyReportIdentity (cyclomatic 16): StrategyResearchDashboard.getStrategyReportIdentity has cyclomatic complexity 16 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/charts/StrategyResearchDashboard.tsx"},"region":{"startLine":69}}}],"partialFingerprints":{"codehealthFindingId/v1":"7d59225d1cdb30f22e6ad0c24b9cf340dbbd726f9c3e6513e82716a75668522f"}},{"ruleId":"D1","level":"warning","message":{"text":"MessageBubble.MessageBubble (cyclomatic 16): MessageBubble.MessageBubble has cyclomatic complexity 16 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/chat/MessageBubble.tsx"},"region":{"startLine":204}}}],"partialFingerprints":{"codehealthFindingId/v1":"dc763a6f713d45c78da9079e543e926db11885ca2c14a2e5bbdfa141645512bf"}},{"ruleId":"D1","level":"warning","message":{"text":"PixelOffice.PixelOffice (cyclomatic 16): PixelOffice.PixelOffice has cyclomatic complexity 16 (threshold 15). Most of this is not in the body itself: 6 of the 16 points are its own statements and the rest belongs to 6 function items inside it that branch (a function literal at line 21, a function literal at line 16, mutate, \u2026). The named helpers are already separate functions; the literals\u0027 work cannot be called, reviewed or tested from outside this body. To reduce it, move the named helpers out of the body to the enclosing scope and lift each literal\u0027s work into a named function there, so each is measured, reviewed and tested on its own, and reduce whichever one then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/PixelOffice.tsx"},"region":{"startLine":6}}}],"partialFingerprints":{"codehealthFindingId/v1":"7cc85017b7290c28fbb8bfb4b5fbee86c43cdc2642ccb489fbaf1cd70f88fac7"}},{"ruleId":"D1","level":"warning","message":{"text":"Runtime.BrokerRuntimeCard (cyclomatic 16): Runtime.BrokerRuntimeCard has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Runtime.tsx"},"region":{"startLine":227}}}],"partialFingerprints":{"codehealthFindingId/v1":"cbf2269853d2c420929aa30cf872eb5f6724b6fecd87f670fe2692e729701af9"}},{"ruleId":"D1","level":"warning","message":{"text":"translateElement (cyclomatic 16): translateElement has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"wiki/site.js"},"region":{"startLine":62}}}],"partialFingerprints":{"codehealthFindingId/v1":"b39379bab488a22084cb6c00169cdef038a00f271444cfc70fb4b73f484f26eb"}},{"ruleId":"D2","level":"warning","message":{"text":"Agent.Agent (cognitive 418): Agent.Agent has cognitive complexity 418 (threshold 15). Drivers by points: if/else 156 (191 pts), boolean chains 120, ternaries 49 (90 pts), error handling 7 (9 pts), loops 8 (nesting depth added 78). Of this number, 18 points are the body\u0027s own statements and 400 belong to 74 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Agent.tsx"},"region":{"startLine":227}}}],"partialFingerprints":{"codehealthFindingId/v1":"aaa9e79bd75fe60cdde1d257081ac4181b56c5ee32840624bc9c047ebdd26e61"}},{"ruleId":"D2","level":"warning","message":{"text":"AgentLoop._run_bound (cognitive 169): AgentLoop._run_bound has cognitive complexity 169 (threshold 15). Drivers by points: if/else 49 (109 pts), boolean chains 31, ternaries 10 (21 pts), error handling 3 (7 pts), loops 1 (nesting depth added 75). 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/agent/loop.py"},"region":{"startLine":386}}}],"partialFingerprints":{"codehealthFindingId/v1":"d36af3b5baad102268301e232f8e6a0765d5929d109d1ca97ea54d7f7c7887eb"}},{"ruleId":"D2","level":"warning","message":{"text":"options_portfolio.run_options_backtest (cognitive 151): options_portfolio.run_options_backtest has cognitive complexity 151 (threshold 15). Drivers by points: if/else 29 (87 pts), ternaries 11 (41 pts), loops 11 (19 pts), boolean chains 4 (nesting depth added 96). 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/engines/options_portfolio.py"},"region":{"startLine":199}}}],"partialFingerprints":{"codehealthFindingId/v1":"99a2f7880d15a0f1dc38f92acc8e4c74f393152449f7430409029d07d50550bb"}},{"ruleId":"D2","level":"warning","message":{"text":"WeixinChannel._process_message (cognitive 143): WeixinChannel._process_message has cognitive complexity 143 (threshold 15). Drivers by points: if/else 47 (121 pts), boolean chains 18, loops 3 (4 pts) (nesting depth added 75). To reduce it, flatten the nesting: this score is depth rather than breadth \u2014 most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language\u0027s equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/weixin.py"},"region":{"startLine":600}}}],"partialFingerprints":{"codehealthFindingId/v1":"f6415233412580e0c94e3e95987ebf106eee3e64d810e58fa7b48ac86222cfca"}},{"ruleId":"D2","level":"warning","message":{"text":"Scheduled.Scheduled (cognitive 116): Scheduled.Scheduled has cognitive complexity 116 (threshold 15). Drivers by points: ternaries 26 (44 pts), boolean chains 40, if/else 26 (27 pts), error handling 3, match/switch 2 (nesting depth added 19). Of this number, 38 points are the body\u0027s own statements and 78 belong to 19 function items inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Scheduled.tsx"},"region":{"startLine":92}}}],"partialFingerprints":{"codehealthFindingId/v1":"4909aeb5c706c53930193898d66ad707c2aea01ffc03c73c7787a4992a7027d1"}},{"ruleId":"D2","level":"warning","message":{"text":"historical._walk_bars (cognitive 114): historical._walk_bars has cognitive complexity 114 (threshold 15). Drivers by points: if/else 17 (42 pts), ternaries 11 (27 pts), boolean chains 16, loops 7 (16 pts), error handling 5 (13 pts) (nesting depth added 58). 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/data_gateway/historical.py"},"region":{"startLine":121}}}],"partialFingerprints":{"codehealthFindingId/v1":"6314b08252cb508b3f22ccd6cc3ee3d09e591be361db3e602f0906fcbace765f"}},{"ruleId":"D2","level":"warning","message":{"text":"Portfolio.Portfolio (cognitive 114): Portfolio.Portfolio has cognitive complexity 114 (threshold 15). Drivers by points: ternaries 39 (73 pts), if/else 14 (18 pts), boolean chains 16, error handling 6, loops 1 (nesting depth added 38). Of this number, 41 points are the body\u0027s own statements and 73 belong to 16 function items inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Portfolio.tsx"},"region":{"startLine":135}}}],"partialFingerprints":{"codehealthFindingId/v1":"f3c80a77d3cbd7ab42e5113e74b0c218d630db32f7a62cc4e26a7f5394b340a5"}},{"ruleId":"D2","level":"warning","message":{"text":"ToolCallLifecycle._process_tool_calls (cognitive 109): ToolCallLifecycle._process_tool_calls has cognitive complexity 109 (threshold 15). Drivers by points: if/else 28 (64 pts), ternaries 7 (16 pts), boolean chains 15, loops 8 (14 pts) (nesting depth added 51). 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/agent/tool_lifecycle.py"},"region":{"startLine":95}}}],"partialFingerprints":{"codehealthFindingId/v1":"d77da841c7110ad4c2c8f4ff8eb91529a87b02fa21cc817b0aa91f094c77d3e8"}},{"ruleId":"D2","level":"warning","message":{"text":"BaseEngine._execute_bars (cognitive 106): BaseEngine._execute_bars has cognitive complexity 106 (threshold 15). Drivers by points: if/else 22 (51 pts), loops 9 (20 pts), ternaries 6 (18 pts), boolean chains 10, error handling 2 (7 pts) (nesting depth added 57). 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/engines/base.py"},"region":{"startLine":1290}}}],"partialFingerprints":{"codehealthFindingId/v1":"b46c909311a3b5ffeae3050b864463dbb6fb4b7ae9ac92ca3062e12cd9c6dd89"}},{"ruleId":"D2","level":"warning","message":{"text":"session_5m.match_orders_5m (cognitive 98): session_5m.match_orders_5m has cognitive complexity 98 (threshold 15). Drivers by points: if/else 25 (71 pts), loops 8 (15 pts), ternaries 2 (8 pts), boolean chains 4 (nesting depth added 59). 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/paper_trade/session_5m.py"},"region":{"startLine":141}}}],"partialFingerprints":{"codehealthFindingId/v1":"724309dc43ebb436c2cdf3ffa53b4d8e91e517ac80b9e3aba1984e56aa98566e"}},{"ruleId":"D2","level":"warning","message":{"text":"runner.fetch_data_map (cognitive 95): runner.fetch_data_map has cognitive complexity 95 (threshold 15). Drivers by points: if/else 25 (62 pts), loops 5 (18 pts), boolean chains 13, ternaries 1 (2 pts) (nesting depth added 51). To reduce it, flatten the nesting: this score is depth rather than breadth \u2014 most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language\u0027s equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/runner.py"},"region":{"startLine":2060}}}],"partialFingerprints":{"codehealthFindingId/v1":"dfdbe9b1e8b06bef61999fb088bd94aa97556c675f1dcb33655867c1a4360907"}},{"ruleId":"D2","level":"warning","message":{"text":"feishu._extract_element_content (cognitive 93): feishu._extract_element_content has cognitive complexity 93 (threshold 15). Drivers by points: if/else 23 (62 pts), loops 7 (18 pts), ternaries 2 (7 pts), boolean chains 6 (nesting depth added 55). To reduce it, flatten the nesting: this score is depth rather than breadth \u2014 most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language\u0027s equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/feishu.py"},"region":{"startLine":204}}}],"partialFingerprints":{"codehealthFindingId/v1":"333f38014812ee6112da9639fd54bed293499dcb901612593e36102827904ded"}},{"ruleId":"D2","level":"warning","message":{"text":"worker._run_worker_impl (cognitive 90): worker._run_worker_impl has cognitive complexity 90 (threshold 15). Drivers by points: if/else 24 (49 pts), boolean chains 19, ternaries 5 (13 pts), error handling 4 (6 pts), loops 2 (3 pts) (nesting depth added 36). 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/swarm/worker.py"},"region":{"startLine":557}}}],"partialFingerprints":{"codehealthFindingId/v1":"647dcd7cdea61edeac1a6b0a57c4f3eb4847aa6955ac05c39acef13cef464f33"}},{"ruleId":"D2","level":"warning","message":{"text":"schema._validate_expectations (cognitive 84): schema._validate_expectations has cognitive complexity 84 (threshold 15). Drivers by points: if/else 28 (59 pts), loops 6 (12 pts), boolean chains 11, ternaries 1 (2 pts) (nesting depth added 38). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/harness/schema.py"},"region":{"startLine":79}}}],"partialFingerprints":{"codehealthFindingId/v1":"67a2824f1263e9322fbc504bac86567ed8c345e3ac84d2966f5424c848e46422"}},{"ruleId":"D2","level":"warning","message":{"text":"bench_runner.run_bench (cognitive 84): bench_runner.run_bench has cognitive complexity 84 (threshold 15). Drivers by points: if/else 24 (39 pts), error handling 10 (24 pts), loops 5 (8 pts), ternaries 4 (7 pts), boolean chains 6 (nesting depth added 35). 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/bench_runner.py"},"region":{"startLine":144}}}],"partialFingerprints":{"codehealthFindingId/v1":"2fbaff4cfc6da2ac250b82b44c771c2cecf71d7b18b3ff5e68b15d740a778a18"}},{"ruleId":"D2","level":"warning","message":{"text":"PortfolioService._collect_source (cognitive 83): PortfolioService._collect_source has cognitive complexity 83 (threshold 15). Drivers by points: if/else 20 (44 pts), boolean chains 20, ternaries 4 (12 pts), error handling 2 (4 pts), loops 3 (nesting depth added 34). To reduce it, flatten the nesting: this score is depth rather than breadth \u2014 most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language\u0027s equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/portfolio/service.py"},"region":{"startLine":962}}}],"partialFingerprints":{"codehealthFindingId/v1":"544afca7dab8554045eb161db5d9588fbba273e1a72e9e57006075beca0a99f6"}},{"ruleId":"D2","level":"warning","message":{"text":"HistoryStore.run (cognitive 82): HistoryStore.run has cognitive complexity 82 (threshold 15). Drivers by points: if/else 21 (46 pts), boolean chains 14, ternaries 7 (13 pts), loops 3 (5 pts), error handling 2 (4 pts) (nesting depth added 35). 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/data_gateway/history_store.py"},"region":{"startLine":526}}}],"partialFingerprints":{"codehealthFindingId/v1":"a60fc0f4beaebd65c4dfc890bb2d43926471adf05b56f343d9d1537a2ebd48de"}},{"ruleId":"D2","level":"warning","message":{"text":"_legacy.main (cognitive 80): _legacy.main has cognitive complexity 80 (threshold 15). Drivers by points: if/else 56 (68 pts), ternaries 3 (7 pts), error handling 2 (4 pts), boolean chains 1 (nesting depth added 18). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":6402}}}],"partialFingerprints":{"codehealthFindingId/v1":"7a397fdb543c78a6dc0ab72d73acc56b6cf8ad3295171e8ef6babc18d21156c6"}},{"ruleId":"D2","level":"warning","message":{"text":"_PolicyMixin._validate_figures (cognitive 77): _PolicyMixin._validate_figures has cognitive complexity 77 (threshold 15). Drivers by points: if/else 22 (46 pts), ternaries 5 (14 pts), boolean chains 12, loops 3 (5 pts) (nesting depth added 35). 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/grounding/policies.py"},"region":{"startLine":467}}}],"partialFingerprints":{"codehealthFindingId/v1":"d214b6e8cbc143f236b61817e37d67822d0af6d84e3a99d9d04e00c3b1237e64"}},{"ruleId":"D2","level":"warning","message":{"text":"ChatLLM.stream_chat (cognitive 77): ChatLLM.stream_chat has cognitive complexity 77 (threshold 15). Drivers by points: if/else 21 (41 pts), boolean chains 18, ternaries 7 (14 pts), error handling 3, loops 1 (nesting depth added 27). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/providers/chat.py"},"region":{"startLine":495}}}],"partialFingerprints":{"codehealthFindingId/v1":"21b9963835ddfc6826c2ca391c658ef6e507f79e272899620f1e4b58cac81859"}},{"ruleId":"D2","level":"warning","message":{"text":"options_portfolio._calc_options_metrics (cognitive 76): options_portfolio._calc_options_metrics has cognitive complexity 76 (threshold 15). Drivers by points: if/else 37 (49 pts), ternaries 11 (12 pts), boolean chains 10, error handling 2 (4 pts), loops 1 (nesting depth added 15). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/engines/options_portfolio.py"},"region":{"startLine":705}}}],"partialFingerprints":{"codehealthFindingId/v1":"df13fdf66be7fe76ba9efddaab268fbaf03957d4849fa9e11d8c02fc688130be"}},{"ruleId":"D2","level":"warning","message":{"text":"gildata_fin_query_tool._normalize_table (cognitive 76): gildata_fin_query_tool._normalize_table has cognitive complexity 76 (threshold 15). Drivers by points: if/else 15 (37 pts), ternaries 6 (22 pts), boolean chains 13, loops 3 (4 pts) (nesting depth added 39). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/gildata_fin_query_tool.py"},"region":{"startLine":35}}}],"partialFingerprints":{"codehealthFindingId/v1":"e98d3f84c96034585d04402e23468fe97c53f1f87763f41b9fa3bc3a8cb19eae"}},{"ruleId":"D2","level":"warning","message":{"text":"historical.fetch_bars (cognitive 75): historical.fetch_bars has cognitive complexity 75 (threshold 15). Drivers by points: if/else 13 (38 pts), loops 9 (24 pts), boolean chains 8, ternaries 3, error handling 1 (2 pts) (nesting depth added 41). 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/data_gateway/historical.py"},"region":{"startLine":21}}}],"partialFingerprints":{"codehealthFindingId/v1":"f9df84e31866530ac1c3df00c5f003f586142310e97a26efb5007673698fb378"}},{"ruleId":"D2","level":"warning","message":{"text":"RunnerStatus.BrokerRow (cognitive 75): RunnerStatus.BrokerRow has cognitive complexity 75 (threshold 15). Drivers by points: ternaries 17 (56 pts), boolean chains 12, if/else 6, error handling 1 (nesting depth added 39). Of this number, 65 points are the body\u0027s own statements and 10 belong to 4 function literals inside it that branch. To reduce it, flatten the nesting: this score is depth rather than breadth \u2014 most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language\u0027s equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/chat/RunnerStatus.tsx"},"region":{"startLine":121}}}],"partialFingerprints":{"codehealthFindingId/v1":"862116e296fc892f3fea926de87076846b5dbae3678ce7f4762feef90b453969"}},{"ruleId":"D2","level":"warning","message":{"text":"TelegramChannel.send_delta (cognitive 72): TelegramChannel.send_delta has cognitive complexity 72 (threshold 15). Drivers by points: if/else 21 (44 pts), error handling 6 (17 pts), boolean chains 6, ternaries 1 (3 pts), loops 1 (2 pts) (nesting depth added 37). To reduce it, flatten the nesting: this score is depth rather than breadth \u2014 most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language\u0027s equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/telegram.py"},"region":{"startLine":937}}}],"partialFingerprints":{"codehealthFindingId/v1":"759b271e3b3daae4209979da52e723ed7c6cca241e9646205b5c6d2671a6c811"}},{"ruleId":"D2","level":"warning","message":{"text":"main._interactive_loop (cognitive 70): main._interactive_loop has cognitive complexity 70 (threshold 15). Drivers by points: if/else 23 (52 pts), error handling 5 (11 pts), boolean chains 3, ternaries 1 (3 pts), loops 1 (nesting depth added 37). 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/main.py"},"region":{"startLine":1303}}}],"partialFingerprints":{"codehealthFindingId/v1":"5a0c82914e0a2f107393f976da13bc50b4787a88662518496071e9b59fa65261"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelSettings.ChannelSettings (cognitive 69): ChannelSettings.ChannelSettings has cognitive complexity 69 (threshold 15). Drivers by points: ternaries 23 (49 pts), if/else 11, boolean chains 6, error handling 3 (nesting depth added 26). Most of this is not in the body itself: 15 of the 69 points are its own statements and the rest belongs to 7 function items inside it that branch (a function literal at line 235, a function literal at line 38, setChannelsRunning, \u2026). The named helpers are already separate functions; the literals\u0027 work cannot be called, reviewed or tested from outside this body. To reduce it, move the named helpers out of the body to the enclosing scope and lift each literal\u0027s work into a named function there, so each is measured, reviewed and tested on its own, and reduce whichever one then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/settings/ChannelSettings.tsx"},"region":{"startLine":24}}}],"partialFingerprints":{"codehealthFindingId/v1":"4761a3589becd4e8d1bb8bb7c32655b0e075d5a54b045fea5a03bbb3ff1cbc1b"}},{"ruleId":"D2","level":"warning","message":{"text":"openai_codex._message_chunks_from_events (cognitive 67): openai_codex._message_chunks_from_events has cognitive complexity 67 (threshold 15). Drivers by points: if/else 12 (41 pts), boolean chains 21, ternaries 1 (4 pts), loops 1 (nesting depth added 32). To reduce it, flatten the nesting: this score is depth rather than breadth \u2014 most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language\u0027s equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/providers/openai_codex.py"},"region":{"startLine":632}}}],"partialFingerprints":{"codehealthFindingId/v1":"febbf4e3d624bd05c3f17fd87d568c0a99b51d3e934a5960cb8f84635b2cf06f"}},{"ruleId":"D2","level":"warning","message":{"text":"RunDetail.RunDetail (cognitive 67): RunDetail.RunDetail has cognitive complexity 67 (threshold 15). Drivers by points: boolean chains 30, if/else 18 (20 pts), ternaries 11 (16 pts), loops 1 (nesting depth added 7). Of this number, 27 points are the body\u0027s own statements and 40 belong to 13 function items inside it that branch. To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/RunDetail.tsx"},"region":{"startLine":124}}}],"partialFingerprints":{"codehealthFindingId/v1":"6e2bceab036a12dfbfa1c62ceeaff7d7563c261f1537c5b333464a7d26bfb294"}},{"ruleId":"D2","level":"warning","message":{"text":"bench_runner_strict.run_bench_strict (cognitive 66): bench_runner_strict.run_bench_strict has cognitive complexity 66 (threshold 15). Drivers by points: if/else 19 (29 pts), ternaries 9 (14 pts), error handling 6 (10 pts), boolean chains 9, loops 4 (nesting depth added 19). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/bench_runner_strict.py"},"region":{"startLine":326}}}],"partialFingerprints":{"codehealthFindingId/v1":"574e56369b26051756e7dcf304ea7e6d2c6fdae00f58803188db5b8251eba6b8"}},{"ruleId":"D2","level":"warning","message":{"text":"PersistentMemory.find_relevant (cognitive 66): PersistentMemory.find_relevant has cognitive complexity 66 (threshold 15). Drivers by points: if/else 18 (46 pts), loops 5 (11 pts), boolean chains 5, error handling 2 (4 pts) (nesting depth added 36). To reduce it, flatten the nesting: this score is depth rather than breadth \u2014 most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language\u0027s equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/memory/persistent.py"},"region":{"startLine":366}}}],"partialFingerprints":{"codehealthFindingId/v1":"412169811d2df9e45b71c5973d742d4a2fbad6b4e14bdafb85a884f2f1ebdbb1"}},{"ruleId":"D2","level":"warning","message":{"text":"_PolicyMixin._check_observed (cognitive 65): _PolicyMixin._check_observed has cognitive complexity 65 (threshold 15). Drivers by points: if/else 28 (49 pts), boolean chains 8, ternaries 5 (8 pts) (nesting depth added 24). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/grounding/policies.py"},"region":{"startLine":1695}}}],"partialFingerprints":{"codehealthFindingId/v1":"125f4cd9125bf681ea157ef14ee2498467a9aca45476c320c4349e2ae3bccb8c"}},{"ruleId":"D2","level":"warning","message":{"text":"measurements.measurement_verdicts (cognitive 65): measurements.measurement_verdicts has cognitive complexity 65 (threshold 15). Drivers by points: if/else 20 (46 pts), ternaries 3 (11 pts), boolean chains 5, error handling 1 (2 pts), loops 1 (nesting depth added 35). To reduce it, flatten the nesting: this score is depth rather than breadth \u2014 most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language\u0027s equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/harness/measurements.py"},"region":{"startLine":55}}}],"partialFingerprints":{"codehealthFindingId/v1":"54e4f25dbdab7cae645cb69a6cbb49681a18fa79a6ba2f331a81654922f5afc8"}},{"ruleId":"D2","level":"warning","message":{"text":"financial_facts.validate_financial_facts (cognitive 65): financial_facts.validate_financial_facts has cognitive complexity 65 (threshold 15). Drivers by points: if/else 24 (46 pts), boolean chains 13, loops 4 (6 pts) (nesting depth added 24). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/research_artifacts/financial_facts.py"},"region":{"startLine":69}}}],"partialFingerprints":{"codehealthFindingId/v1":"76f3286a59d51439888333a37c140f0b5a8ff2c2d9ba99c2de9618d44490140d"}},{"ruleId":"D2","level":"warning","message":{"text":"tools.build_registry (cognitive 65): tools.build_registry has cognitive complexity 65 (threshold 15). Drivers by points: if/else 15 (37 pts), ternaries 3 (10 pts), loops 4 (7 pts), boolean chains 6, error handling 2 (5 pts) (nesting depth added 35). To reduce it, flatten the nesting: this score is depth rather than breadth \u2014 most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language\u0027s equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/__init__.py"},"region":{"startLine":77}}}],"partialFingerprints":{"codehealthFindingId/v1":"8b76f03743fb2058496b5b9cfe50702c9ff2cb4b80f4f992b2dcbaaa0ba04597"}},{"ruleId":"D2","level":"warning","message":{"text":"trade_journal_parsers._futu_datetime (cognitive 65): trade_journal_parsers._futu_datetime has cognitive complexity 65 (threshold 15). Drivers by points: if/else 13 (39 pts), boolean chains 15, error handling 2 (6 pts), ternaries 3 (5 pts) (nesting depth added 32). To reduce it, flatten the nesting: this score is depth rather than breadth \u2014 most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language\u0027s equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/trade_journal_parsers.py"},"region":{"startLine":473}}}],"partialFingerprints":{"codehealthFindingId/v1":"1251358d75d3e62e32d1240b629081cd14be47859cbc93fb7cdca9a8a13dd951"}},{"ruleId":"D2","level":"warning","message":{"text":"WebSearchTool.execute (cognitive 65): WebSearchTool.execute has cognitive complexity 65 (threshold 15). Drivers by points: if/else 18 (32 pts), error handling 8 (16 pts), boolean chains 8, ternaries 4 (6 pts), loops 2 (3 pts) (nesting depth added 25). 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/web_search_tool.py"},"region":{"startLine":175}}}],"partialFingerprints":{"codehealthFindingId/v1":"cf1c1090567676e8fedf72aef992357745e1088e1f464684817814ffca00aa49"}},{"ruleId":"D2","level":"warning","message":{"text":"eventstudy.event_study (cognitive 64): eventstudy.event_study has cognitive complexity 64 (threshold 15). Drivers by points: if/else 28 (37 pts), ternaries 10 (17 pts), loops 4 (5 pts), boolean chains 3, error handling 1 (2 pts) (nesting depth added 18). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/eventstudy.py"},"region":{"startLine":325}}}],"partialFingerprints":{"codehealthFindingId/v1":"6f096f59ce1bba353cd07c5751cc1e3f1dd2b093f10379a8264145887e3d00c0"}},{"ruleId":"D2","level":"warning","message":{"text":"BaseEngine._execute_target_rebalance (cognitive 63): BaseEngine._execute_target_rebalance has cognitive complexity 63 (threshold 15). Drivers by points: if/else 21 (49 pts), loops 4 (6 pts), ternaries 3 (6 pts), boolean chains 2 (nesting depth added 33). 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/engines/base.py"},"region":{"startLine":1799}}}],"partialFingerprints":{"codehealthFindingId/v1":"a91bfd42b95c8506bcbdc7833fadaba7ca249c697812a1bef3565b3f1a5bec18"}},{"ruleId":"D2","level":"warning","message":{"text":"figures.scan_figures (cognitive 63): figures.scan_figures has cognitive complexity 63 (threshold 15). Drivers by points: if/else 13 (27 pts), boolean chains 20, ternaries 6 (13 pts), loops 3 (nesting depth added 21). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/grounding/figures.py"},"region":{"startLine":1254}}}],"partialFingerprints":{"codehealthFindingId/v1":"684a7f4defebf7fddecf4517783c3187361b977088df1918e08d1ab3eb0d49c7"}},{"ruleId":"D2","level":"warning","message":{"text":"_PolicyMixin._referenced (cognitive 63): _PolicyMixin._referenced has cognitive complexity 63 (threshold 15). Drivers by points: if/else 21 (38 pts), boolean chains 21, ternaries 2 (4 pts) (nesting depth added 19). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/grounding/policies.py"},"region":{"startLine":817}}}],"partialFingerprints":{"codehealthFindingId/v1":"e95726713428445bf9543885f90eff8b549a567ec31d423f4fdcb4139b29eaf5"}},{"ruleId":"D2","level":"warning","message":{"text":"ingest._load_panel_long (cognitive 62): ingest._load_panel_long has cognitive complexity 62 (threshold 15). Drivers by points: if/else 24 (46 pts), boolean chains 10, error handling 2 (4 pts), loops 2 (nesting depth added 24). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/entities/ingest.py"},"region":{"startLine":928}}}],"partialFingerprints":{"codehealthFindingId/v1":"0efb003ef1c85688bbd068ea0488a92d5e1deb0d92b0e5729289fc2c361d7365"}},{"ruleId":"D2","level":"warning","message":{"text":"_PolicyMixin._derivation (cognitive 61): _PolicyMixin._derivation has cognitive complexity 61 (threshold 15). Drivers by points: if/else 23 (32 pts), boolean chains 22, ternaries 4 (7 pts) (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/grounding/policies.py"},"region":{"startLine":1957}}}],"partialFingerprints":{"codehealthFindingId/v1":"f2984ff0124f071d298300a93c02a46858e1ed475d799311c6b6500827add9a4"}},{"ruleId":"D2","level":"warning","message":{"text":"options.barrier_option_price (cognitive 61): options.barrier_option_price has cognitive complexity 61 (threshold 15). Drivers by points: ternaries 14 (34 pts), if/else 17 (22 pts), boolean chains 5 (nesting depth added 25). 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/options.py"},"region":{"startLine":517}}}],"partialFingerprints":{"codehealthFindingId/v1":"b378b7f5778481f82c8d299b0a36b19efc8651264740965a6142d1a98c61ebd9"}},{"ruleId":"D2","level":"warning","message":{"text":"OptionsLab.OptionsLab (cognitive 61): OptionsLab.OptionsLab has cognitive complexity 61 (threshold 15). Drivers by points: ternaries 21 (37 pts), boolean chains 17, if/else 5 (6 pts), error handling 1 (nesting depth added 17). Of this number, 46 points are the body\u0027s own statements and 15 belong to 5 function items inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/OptionsLab.tsx"},"region":{"startLine":61}}}],"partialFingerprints":{"codehealthFindingId/v1":"d6785ec2b720360e4b3a0a2fa6a7133fc4686a9bcade41e2f7066f3c613f8ff7"}},{"ruleId":"D2","level":"warning","message":{"text":"ResearchArtifacts.ResearchArtifacts (cognitive 61): ResearchArtifacts.ResearchArtifacts has cognitive complexity 61 (threshold 15). Drivers by points: boolean chains 24, ternaries 12 (20 pts), if/else 9 (11 pts), error handling 6 (nesting depth added 10). Of this number, 16 points are the body\u0027s own statements and 45 belong to 8 function items inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/ResearchArtifacts.tsx"},"region":{"startLine":80}}}],"partialFingerprints":{"codehealthFindingId/v1":"c6707c5ec299e146a0c5d3f7b5e430ce1e90772f4c671c9dd2815ac311062902"}},{"ruleId":"D2","level":"warning","message":{"text":"telegram._split_telegram_markdown (cognitive 60): telegram._split_telegram_markdown has cognitive complexity 60 (threshold 15). Drivers by points: if/else 19 (52 pts), ternaries 1 (6 pts), boolean chains 1, loops 1 (nesting depth added 38). To reduce it, flatten the nesting: this score is depth rather than breadth \u2014 most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language\u0027s equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/telegram.py"},"region":{"startLine":46}}}],"partialFingerprints":{"codehealthFindingId/v1":"3499f8b1f32c6336822495fcd9e72cc2c5b438bc973cf4cca0ec58913a700bd7"}},{"ruleId":"D2","level":"warning","message":{"text":"cli_handlers.cmd_alpha_bench (cognitive 60): cli_handlers.cmd_alpha_bench has cognitive complexity 60 (threshold 15). Drivers by points: if/else 26 (35 pts), ternaries 8 (12 pts), boolean chains 7, error handling 3, loops 2 (3 pts) (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/cli_handlers.py"},"region":{"startLine":566}}}],"partialFingerprints":{"codehealthFindingId/v1":"88a8a319503cfeade29af9c69c2c7fd0bde2007ece73cfea09a1b66bedd889de"}},{"ruleId":"D2","level":"warning","message":{"text":"WecomChannel._process_message (cognitive 59): WecomChannel._process_message has cognitive complexity 59 (threshold 15). Drivers by points: if/else 25 (45 pts), boolean chains 8, loops 2 (3 pts), ternaries 2, error handling 1 (nesting depth added 21). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/wecom.py"},"region":{"startLine":223}}}],"partialFingerprints":{"codehealthFindingId/v1":"d3a5d568a28d98dffcd4f602da33de28805aa1be0147143e5df977c88876a133"}},{"ruleId":"D2","level":"warning","message":{"text":"EmailChannel._fetch_messages_once (cognitive 58): EmailChannel._fetch_messages_once has cognitive complexity 58 (threshold 15). Drivers by points: if/else 21 (45 pts), boolean chains 9, loops 2 (4 pts) (nesting depth added 26). 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/email.py"},"region":{"startLine":537}}}],"partialFingerprints":{"codehealthFindingId/v1":"4446ffa0d5e76d1a3b784bcc20dd2e83e40acbba00a28edaa48f4123045c3a01"}},{"ruleId":"D2","level":"warning","message":{"text":"feishu._extract_interactive_content (cognitive 57): feishu._extract_interactive_content has cognitive complexity 57 (threshold 15). Drivers by points: if/else 18 (32 pts), loops 4 (14 pts), boolean chains 4, error handling 2 (4 pts), ternaries 1 (3 pts) (nesting depth added 28). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/feishu.py"},"region":{"startLine":133}}}],"partialFingerprints":{"codehealthFindingId/v1":"67be5d23e2d36a1132f6db07f2c7066545bb3a02e0fc59e2f5e7f0b5ee1cd5c8"}},{"ruleId":"D2","level":"warning","message":{"text":"mcp.quote_summary (cognitive 57): mcp.quote_summary has cognitive complexity 57 (threshold 15). Drivers by points: if/else 28 (42 pts), boolean chains 7, loops 2 (4 pts), error handling 1 (3 pts), ternaries 1 (nesting depth added 18). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/robinhood/mcp.py"},"region":{"startLine":352}}}],"partialFingerprints":{"codehealthFindingId/v1":"a50ab13b299e1c0780bb6cb5a51cea85a9056b6d5e00cb54e75742f1ff8dcaa2"}},{"ruleId":"D2","level":"warning","message":{"text":"_legacy.cmd_connector_check (cognitive 56): _legacy.cmd_connector_check has cognitive complexity 56 (threshold 15). Drivers by points: if/else 13 (26 pts), ternaries 7 (23 pts), boolean chains 4, loops 1 (2 pts), error handling 1 (nesting depth added 30). To reduce it, flatten the nesting: this score is depth rather than breadth \u2014 most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language\u0027s equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":4376}}}],"partialFingerprints":{"codehealthFindingId/v1":"cb2dc150093bf938e365b14944f1635e018162c355d3cbe59e90b381e8172288"}},{"ruleId":"D2","level":"warning","message":{"text":"trade_journal_tool.pair_trades_fifo (cognitive 56): trade_journal_tool.pair_trades_fifo has cognitive complexity 56 (threshold 15). Drivers by points: ternaries 8 (28 pts), if/else 6 (16 pts), boolean chains 6, loops 3 (6 pts) (nesting depth added 33). 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/trade_journal_tool.py"},"region":{"startLine":76}}}],"partialFingerprints":{"codehealthFindingId/v1":"b3ce37483ba5d66f6db67851ff296d55eed2c526960fe989ca48f4c5ecdbfd1a"}},{"ruleId":"D2","level":"warning","message":{"text":"VibeTradingDingTalkHandler.process (cognitive 55): VibeTradingDingTalkHandler.process has cognitive complexity 55 (threshold 15). Drivers by points: if/else 15 (33 pts), boolean chains 15, ternaries 1 (4 pts), loops 1 (2 pts), error handling 1 (nesting depth added 22). 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/dingtalk.py"},"region":{"startLine":57}}}],"partialFingerprints":{"codehealthFindingId/v1":"004942c496760157ba81472654c48be514f1a5c9a04779ee2a9be054d12caf0d"}},{"ruleId":"D2","level":"warning","message":{"text":"ScanQueue._run (cognitive 55): ScanQueue._run has cognitive complexity 55 (threshold 15). Drivers by points: if/else 13 (34 pts), loops 5 (12 pts), ternaries 2 (6 pts), error handling 1 (2 pts), boolean chains 1 (nesting depth added 33). 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/data_gateway/scans.py"},"region":{"startLine":110}}}],"partialFingerprints":{"codehealthFindingId/v1":"7ac55bebd1a562a108f33f0604b68d94ccdad087be4245d25267ff8213854518"}},{"ruleId":"D2","level":"warning","message":{"text":"sources.normalize (cognitive 55): sources.normalize has cognitive complexity 55 (threshold 15). Drivers by points: if/else 12 (21 pts), boolean chains 14, ternaries 6 (11 pts), loops 3 (6 pts), error handling 1 (3 pts) (nesting depth added 19). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/data_gateway/sources.py"},"region":{"startLine":25}}}],"partialFingerprints":{"codehealthFindingId/v1":"04175dce447a93baad38ef0d65c6a31de540f6f884cd81ba1556915d0d440188"}},{"ruleId":"D2","level":"warning","message":{"text":"EmailChannel.send (cognitive 54): EmailChannel.send has cognitive complexity 54 (threshold 15). Drivers by points: if/else 23 (32 pts), boolean chains 13, error handling 3 (5 pts), loops 2, ternaries 1 (2 pts) (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/email.py"},"region":{"startLine":265}}}],"partialFingerprints":{"codehealthFindingId/v1":"a059acadfacf663481db1337278ffa21b5cc88417b57df76c96b0bde71f5f245"}},{"ruleId":"D2","level":"warning","message":{"text":"report_audit_tool._parse_md_tables (cognitive 54): report_audit_tool._parse_md_tables has cognitive complexity 54 (threshold 15). Drivers by points: if/else 7 (34 pts), loops 3 (10 pts), ternaries 1 (6 pts), boolean chains 4 (nesting depth added 39). To reduce it, flatten the nesting: this score is depth rather than breadth \u2014 most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language\u0027s equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/report_audit_tool.py"},"region":{"startLine":147}}}],"partialFingerprints":{"codehealthFindingId/v1":"0aefd2111778d6e8fc313c515d9becf32039dc2330a77be0995eb552f1f93fb2"}},{"ruleId":"D2","level":"warning","message":{"text":"rail._result_summary (cognitive 53): rail._result_summary has cognitive complexity 53 (threshold 15). Drivers by points: if/else 17 (34 pts), boolean chains 6, ternaries 2 (6 pts), error handling 2 (5 pts), loops 1 (2 pts) (nesting depth added 25). 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/ui/rail.py"},"region":{"startLine":125}}}],"partialFingerprints":{"codehealthFindingId/v1":"63ffa69e551aa2abd2b950eea127f950dca49163c2c25c4d0be8853b274201f8"}},{"ruleId":"D2","level":"warning","message":{"text":"Layout.Layout (cognitive 53): Layout.Layout has cognitive complexity 53 (threshold 15). Drivers by points: ternaries 17 (25 pts), boolean chains 16, if/else 10, error handling 2 (nesting depth added 8). Of this number, 30 points are the body\u0027s own statements and 23 belong to 13 function items inside it that branch. To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/layout/Layout.tsx"},"region":{"startLine":21}}}],"partialFingerprints":{"codehealthFindingId/v1":"cd99cd52f02b0efb297e1534c99fcce7560f5cb0b4efcc7810cf685bbbe78b12"}},{"ruleId":"D2","level":"warning","message":{"text":"swarmStatus.applySwarmEvent (cognitive 53): swarmStatus.applySwarmEvent has cognitive complexity 53 (threshold 15). Drivers by points: boolean chains 18, ternaries 9 (18 pts), if/else 16 (17 pts) (nesting depth added 10). Of this number, 28 points are the body\u0027s own statements and 25 belong to 9 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/lib/swarmStatus.ts"},"region":{"startLine":209}}}],"partialFingerprints":{"codehealthFindingId/v1":"6d2227d61f4e403756d9d90821c70c1e0ea06689d5bcba8371ba7839fdf18ec6"}},{"ruleId":"D2","level":"warning","message":{"text":"RailRunDashboard.handle_event (cognitive 52): RailRunDashboard.handle_event has cognitive complexity 52 (threshold 15). Drivers by points: if/else 20 (33 pts), boolean chains 15, loops 1 (2 pts), ternaries 1 (2 pts) (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/ui/rail.py"},"region":{"startLine":320}}}],"partialFingerprints":{"codehealthFindingId/v1":"8ebc900a0d88b1a803f77a6ad7546e251e433ecc6a2043b3356b4f7d3ac3032c"}},{"ruleId":"D2","level":"warning","message":{"text":"IdentityLedger._ingest_resolution (cognitive 52): IdentityLedger._ingest_resolution has cognitive complexity 52 (threshold 15). Drivers by points: if/else 19 (28 pts), boolean chains 14, ternaries 6 (7 pts), loops 2 (3 pts) (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/agent/instrument_identity.py"},"region":{"startLine":739}}}],"partialFingerprints":{"codehealthFindingId/v1":"bd529d37f86d015c22d68c301e64850584258d748fa2391bbbeea65402b009df"}},{"ruleId":"D2","level":"warning","message":{"text":"WebSocketChannel.send (cognitive 52): WebSocketChannel.send has cognitive complexity 52 (threshold 15). Drivers by points: if/else 22 (31 pts), ternaries 7 (17 pts), loops 2 (3 pts), boolean chains 1 (nesting depth added 20). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/websocket.py"},"region":{"startLine":884}}}],"partialFingerprints":{"codehealthFindingId/v1":"e73097c851dfd6e233d35d85ff4f60a854b6ee0c0b3ef89021c22b2accc8584f"}},{"ruleId":"D2","level":"warning","message":{"text":"symbol_search_tool._search_selected_connector (cognitive 52): symbol_search_tool._search_selected_connector has cognitive complexity 52 (threshold 15). Drivers by points: if/else 10 (19 pts), boolean chains 15, ternaries 6 (13 pts), loops 2 (3 pts), error handling 2 (nesting depth added 17). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/symbol_search_tool.py"},"region":{"startLine":573}}}],"partialFingerprints":{"codehealthFindingId/v1":"af7d70b4afa11eab8ae5c5cdce25fdf4de5c8040486bcdba2026d3eaf7b61f50"}},{"ruleId":"D2","level":"warning","message":{"text":"WebSocketChannel._dispatch_envelope (cognitive 50): WebSocketChannel._dispatch_envelope has cognitive complexity 50 (threshold 15). Drivers by points: if/else 22 (40 pts), boolean chains 7, ternaries 1 (3 pts) (nesting depth added 20). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/websocket.py"},"region":{"startLine":672}}}],"partialFingerprints":{"codehealthFindingId/v1":"5e02a1534f97abaf05b6b7633c7486ac2e34dc02f9c81f5980d9122bb56bd248"}},{"ruleId":"D2","level":"warning","message":{"text":"ShannonPortfolio.ShannonPortfolio (cognitive 50): ShannonPortfolio.ShannonPortfolio has cognitive complexity 50 (threshold 15). Drivers by points: boolean chains 26, if/else 8 (11 pts), ternaries 8 (11 pts), error handling 2 (nesting depth added 6). Of this number, 28 points are the body\u0027s own statements and 22 belong to 11 function items inside it that branch. To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/charts/ShannonPortfolio.tsx"},"region":{"startLine":31}}}],"partialFingerprints":{"codehealthFindingId/v1":"e191e5b58af376ae3f04fb88308b3a3a201e937a062ff4c6fd1b93c4d3a2cb4d"}},{"ruleId":"D2","level":"warning","message":{"text":"_EvidenceMixin._ingest_engine_table (cognitive 49): _EvidenceMixin._ingest_engine_table has cognitive complexity 49 (threshold 15). Drivers by points: if/else 13 (23 pts), ternaries 5 (13 pts), boolean chains 7, error handling 2 (3 pts), loops 2 (3 pts) (nesting depth added 20). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/grounding/evidence.py"},"region":{"startLine":1199}}}],"partialFingerprints":{"codehealthFindingId/v1":"dd88d5b6c2d53e9ec7e122426497e92370255b2abd4ed45945929258413af268"}},{"ruleId":"D2","level":"warning","message":{"text":"runs_routes._build_response_from_run_dir (cognitive 49): runs_routes._build_response_from_run_dir has cognitive complexity 49 (threshold 15). Drivers by points: if/else 21 (25 pts), boolean chains 10, error handling 3 (6 pts), ternaries 2 (6 pts), loops 1 (2 pts) (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/api/runs_routes.py"},"region":{"startLine":680}}}],"partialFingerprints":{"codehealthFindingId/v1":"a37c7191ae4198c17c538b94f5082d6f5739be9b1ac52c51a1d95da3482e9375"}},{"ruleId":"D2","level":"warning","message":{"text":"service.build_job_from_draft (cognitive 49): service.build_job_from_draft has cognitive complexity 49 (threshold 15). Drivers by points: if/else 23 (29 pts), boolean chains 19, ternaries 1 (nesting depth added 6). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/scheduled_research/service.py"},"region":{"startLine":136}}}],"partialFingerprints":{"codehealthFindingId/v1":"8d634471a42a0b86c1e26db8e6c208002af1dac4e43db0206b5de6983f4cdbbc"}},{"ruleId":"D2","level":"warning","message":{"text":"ConnectionCenter.ConnectionCard (cognitive 49): ConnectionCenter.ConnectionCard has cognitive complexity 49 (threshold 15). Drivers by points: ternaries 21 (31 pts), boolean chains 13, if/else 3, error handling 2 (nesting depth added 10). Of this number, 30 points are the body\u0027s own statements and 19 belong to 4 function items inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/portfolio/ConnectionCenter.tsx"},"region":{"startLine":183}}}],"partialFingerprints":{"codehealthFindingId/v1":"1314d3fa71234f73c143ce47c48bacbaa7a09216c1d1333e6ad9a069a2211afe"}},{"ruleId":"D2","level":"warning","message":{"text":"runner._fetch_auto (cognitive 48): runner._fetch_auto has cognitive complexity 48 (threshold 15). Drivers by points: if/else 13 (29 pts), loops 5 (12 pts), boolean chains 3, error handling 1 (2 pts), ternaries 1 (2 pts) (nesting depth added 25). 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/runner.py"},"region":{"startLine":1944}}}],"partialFingerprints":{"codehealthFindingId/v1":"76ea4faabe0627b5c74b45e056b230155ae3df4b257f0643f55bed604d19ddb8"}},{"ruleId":"D2","level":"warning","message":{"text":"history_router.fetch_chunk (cognitive 48): history_router.fetch_chunk has cognitive complexity 48 (threshold 15). Drivers by points: if/else 14 (28 pts), boolean chains 10, ternaries 2 (7 pts), error handling 1 (2 pts), loops 1 (nesting depth added 20). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/data_gateway/history_router.py"},"region":{"startLine":296}}}],"partialFingerprints":{"codehealthFindingId/v1":"707a6ee0341eeae49f9be73c2d24b433cb82bc669bf58b13337400432abbce42"}},{"ruleId":"D2","level":"warning","message":{"text":"cli_handlers.cmd_alpha_show (cognitive 48): cli_handlers.cmd_alpha_show has cognitive complexity 48 (threshold 15). Drivers by points: ternaries 11 (18 pts), boolean chains 11, if/else 10 (11 pts), error handling 4 (8 pts) (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/cli_handlers.py"},"region":{"startLine":302}}}],"partialFingerprints":{"codehealthFindingId/v1":"8bcc40324fea321241a43ea9c7a7bcaac8dc264f8ef56f25b4327f3ddc44c086"}},{"ruleId":"D2","level":"warning","message":{"text":"figures.parse_figures_block (cognitive 47): figures.parse_figures_block has cognitive complexity 47 (threshold 15). Drivers by points: ternaries 9 (23 pts), if/else 9 (18 pts), loops 2 (4 pts), boolean chains 2 (nesting depth added 25). 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/grounding/figures.py"},"region":{"startLine":821}}}],"partialFingerprints":{"codehealthFindingId/v1":"e12b3e2da197064a16222e0cdce42c4139e1674701c0ef0c2698d51c064da576"}},{"ruleId":"D2","level":"warning","message":{"text":"AgentLoop._auto_compact (cognitive 47): AgentLoop._auto_compact has cognitive complexity 47 (threshold 15). Drivers by points: if/else 20 (31 pts), boolean chains 10, error handling 1 (3 pts), loops 2, ternaries 1 (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/agent/loop.py"},"region":{"startLine":1428}}}],"partialFingerprints":{"codehealthFindingId/v1":"8091d39b20848ea548a30a6521c7af5af525ca09ba1c5951907b95b638634d16"}},{"ruleId":"D2","level":"warning","message":{"text":"evidence_handoff._observations (cognitive 47): evidence_handoff._observations has cognitive complexity 47 (threshold 15). Drivers by points: if/else 14 (29 pts), error handling 4 (11 pts), loops 3 (5 pts), boolean chains 2 (nesting depth added 24). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/swarm/evidence_handoff.py"},"region":{"startLine":14}}}],"partialFingerprints":{"codehealthFindingId/v1":"ceb7f5fd50ec955d7a7b7f064351b4e74d5704d3699245c8a5f54f084fbd925a"}},{"ruleId":"D2","level":"warning","message":{"text":"ingest.load_cashflows (cognitive 46): ingest.load_cashflows has cognitive complexity 46 (threshold 15). Drivers by points: if/else 18 (33 pts), boolean chains 7, error handling 2 (4 pts), loops 2 (nesting depth added 17). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/entities/ingest.py"},"region":{"startLine":365}}}],"partialFingerprints":{"codehealthFindingId/v1":"d08277dc7b91c97824f56ef3e41ec479136c4ef13f239ec20799ba2a32689cb6"}},{"ruleId":"D2","level":"warning","message":{"text":"config.parse_settings (cognitive 46): config.parse_settings has cognitive complexity 46 (threshold 15). Drivers by points: if/else 17 (34 pts), boolean chains 11, loops 1 (nesting depth added 17). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/portfolio/config.py"},"region":{"startLine":144}}}],"partialFingerprints":{"codehealthFindingId/v1":"cad1e93faa49ec5ae86f762d6dc4db8a72a1b5d00fe540c0507297f6586be8bf"}},{"ruleId":"D2","level":"warning","message":{"text":"PaperTrading.PaperTrading (cognitive 46): PaperTrading.PaperTrading has cognitive complexity 46 (threshold 15). Drivers by points: ternaries 13 (25 pts), if/else 7 (9 pts), boolean chains 8, error handling 3 (4 pts) (nesting depth added 15). Most of this is not in the body itself: 15 of the 46 points are its own statements and the rest belongs to 15 function items inside it that branch (advance, a function literal at line 44, a function literal at line 47, \u2026). The named helpers are already separate functions; the literals\u0027 work cannot be called, reviewed or tested from outside this body. To reduce it, move the named helpers out of the body to the enclosing scope and lift each literal\u0027s work into a named function there, so each is measured, reviewed and tested on its own, and reduce whichever one then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/PaperTrading.tsx"},"region":{"startLine":18}}}],"partialFingerprints":{"codehealthFindingId/v1":"93feab423e8dcfe302a8cb0643e50aabe350ee5349134bb0a809a64a8325e11b"}},{"ruleId":"D2","level":"warning","message":{"text":"metrics.calc_metrics (cognitive 45): metrics.calc_metrics has cognitive complexity 45 (threshold 15). Drivers by points: if/else 16 (22 pts), ternaries 12 (17 pts), boolean chains 4, error handling 1 (2 pts) (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/metrics.py"},"region":{"startLine":606}}}],"partialFingerprints":{"codehealthFindingId/v1":"38a76b641fe9d0b9d720f4dbd9c19cf805c8c946111f4df540d7c6000f9a2873"}},{"ruleId":"D2","level":"warning","message":{"text":"assertions._budget_verdicts (cognitive 45): assertions._budget_verdicts has cognitive complexity 45 (threshold 15). Drivers by points: if/else 13 (20 pts), ternaries 7 (16 pts), boolean chains 7, loops 2 (nesting depth added 16). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/harness/assertions.py"},"region":{"startLine":535}}}],"partialFingerprints":{"codehealthFindingId/v1":"9ce9b5ff4439fedd71a2aeee33a183b0f798c9c41425aeba002e10f4aa1d494a"}},{"ruleId":"D2","level":"warning","message":{"text":"PortfolioService.refresh (cognitive 45): PortfolioService.refresh has cognitive complexity 45 (threshold 15). Drivers by points: if/else 13 (24 pts), ternaries 4 (8 pts), error handling 3 (7 pts), boolean chains 4, loops 2 (nesting depth added 19). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/portfolio/service.py"},"region":{"startLine":303}}}],"partialFingerprints":{"codehealthFindingId/v1":"db5f0f04fe808feed255675058d5d5f05289b072c5343ae02abf9391e4e24932"}},{"ruleId":"D2","level":"warning","message":{"text":"ChatLLM._parse_response (cognitive 45): ChatLLM._parse_response has cognitive complexity 45 (threshold 15). Drivers by points: if/else 9 (15 pts), boolean chains 14, error handling 2 (6 pts), ternaries 6, loops 2 (4 pts) (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/providers/chat.py"},"region":{"startLine":677}}}],"partialFingerprints":{"codehealthFindingId/v1":"6a15d316906da9049b858ca302631933f562f0ab867f21968d33c26f57273c57"}},{"ruleId":"D2","level":"warning","message":{"text":"llm.build_llm (cognitive 45): llm.build_llm has cognitive complexity 45 (threshold 15). Drivers by points: if/else 19 (27 pts), boolean chains 14, ternaries 4 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/providers/llm.py"},"region":{"startLine":1454}}}],"partialFingerprints":{"codehealthFindingId/v1":"2770f7ba58e92e5c1e01f38ce326d621211e5a97cf150c6643db8d924221388e"}},{"ruleId":"D2","level":"warning","message":{"text":"MarketDataTool.execute (cognitive 45): MarketDataTool.execute has cognitive complexity 45 (threshold 15). Drivers by points: if/else 25 (31 pts), boolean chains 12, error handling 1 (2 pts) (nesting depth added 7). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/market_data_tool.py"},"region":{"startLine":172}}}],"partialFingerprints":{"codehealthFindingId/v1":"d9412a650f202b4da8e6902c60ef919f453b15384d1ef3331e1c2a10977fea17"}},{"ruleId":"D2","level":"warning","message":{"text":"tool._execute_step (cognitive 45): tool._execute_step has cognitive complexity 45 (threshold 15). Drivers by points: if/else 18 (23 pts), boolean chains 10, ternaries 4 (7 pts), error handling 4 (5 pts) (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/paper_trade/tool.py"},"region":{"startLine":229}}}],"partialFingerprints":{"codehealthFindingId/v1":"948b87596240d325786b2c42ba54b0ee9227762db6bb6296ac1e6c81fb63496a"}},{"ruleId":"D2","level":"warning","message":{"text":"argentina_equity._field_problems (cognitive 44): argentina_equity._field_problems has cognitive complexity 44 (threshold 15). Drivers by points: if/else 12 (21 pts), boolean chains 10, ternaries 2 (6 pts), error handling 2 (5 pts), loops 1 (2 pts) (nesting depth added 17). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/engines/argentina_equity.py"},"region":{"startLine":872}}}],"partialFingerprints":{"codehealthFindingId/v1":"40491a55b5ba4ec00e198c23742d93595a537891995846d943d7fea2d4c46db6"}},{"ruleId":"D2","level":"warning","message":{"text":"tushare_fundamentals.enrich_price_frames_with_fundamentals (cognitive 44): tushare_fundamentals.enrich_price_frames_with_fundamentals has cognitive complexity 44 (threshold 15). Drivers by points: if/else 13 (30 pts), boolean chains 8, loops 3 (6 pts) (nesting depth added 20). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/tushare_fundamentals.py"},"region":{"startLine":313}}}],"partialFingerprints":{"codehealthFindingId/v1":"1f4a40473fce31ff06acd5caedcc87696550c8b547fcf68b8a77d1216a6a116e"}},{"ruleId":"D2","level":"warning","message":{"text":"FeishuChannel._on_message (cognitive 44): FeishuChannel._on_message has cognitive complexity 44 (threshold 15). Drivers by points: if/else 19 (28 pts), boolean chains 7, ternaries 4, loops 2 (3 pts), error handling 2 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/feishu.py"},"region":{"startLine":2261}}}],"partialFingerprints":{"codehealthFindingId/v1":"ba6c44138ba1ba501dfbee0f5fed26a6824968a21116da2398e60acfca0e5c87"}},{"ruleId":"D2","level":"warning","message":{"text":"CandlestickChart.CandlestickChart (cognitive 44): CandlestickChart.CandlestickChart has cognitive complexity 44 (threshold 15). Drivers by points: if/else 18 (20 pts), ternaries 10 (14 pts), boolean chains 8, loops 2 (nesting depth added 6). Most of this is not in the body itself: 2 of the 44 points are its own statements and the rest belongs to 13 function literals inside it that branch (lines 222, 114, 156, \u2026). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/charts/CandlestickChart.tsx"},"region":{"startLine":37}}}],"partialFingerprints":{"codehealthFindingId/v1":"fabffdfcde7830a0f5cccaab7c30e40ca891d9a3aef27f2c2622fb15312147a4"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelConfigPanel.ChannelConfigPanel (cognitive 44): ChannelConfigPanel.ChannelConfigPanel has cognitive complexity 44 (threshold 15). Drivers by points: ternaries 51 (77 pts), if/else 29 (38 pts), boolean chains 25, loops 4, error handling 3 (nesting depth added 35). 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. This shape REPEATS in the file: one other method here (ChannelConfigPanel.ChannelConfigPanel::renderField) has the same decision points, in the same order, at the same nesting depths \u2014 so this is one pattern written twice rather than two separate problems. Splitting this body alone leaves the other exactly as it is. Where these are variations on one operation, the change that clears both is the shared one: lift the common shape into a single routine the variants call, parameterised by whatever genuinely differs between them, and keep in each method only the part that is not shared."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/settings/ChannelConfigPanel.tsx"},"region":{"startLine":193}}}],"partialFingerprints":{"codehealthFindingId/v1":"5bbfea697c8a500fd7142121ea3eb9308defd4fb3f6a50083be9f9b6e00d4620"}},{"ruleId":"D2","level":"warning","message":{"text":"FeishuChannel.send_delta (cognitive 43): FeishuChannel.send_delta has cognitive complexity 43 (threshold 15). Drivers by points: if/else 19 (37 pts), boolean chains 3, loops 1 (2 pts), ternaries 1 (nesting depth added 19). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/feishu.py"},"region":{"startLine":1881}}}],"partialFingerprints":{"codehealthFindingId/v1":"f36a43563372ac4b4bdbf49fb3fe8a54125499c43a8388fe0a1223bf7f47f4aa"}},{"ruleId":"D2","level":"warning","message":{"text":"SlackChannel._on_socket_request (cognitive 43): SlackChannel._on_socket_request has cognitive complexity 43 (threshold 15). Drivers by points: if/else 18 (23 pts), boolean chains 15, error handling 2, ternaries 2, loops 1 (nesting depth added 5). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/slack.py"},"region":{"startLine":335}}}],"partialFingerprints":{"codehealthFindingId/v1":"ca5b3e1f98eaa99601d966a55706d2716d1ca229fcbecd08eccf90d5965a7768"}},{"ruleId":"D2","level":"warning","message":{"text":"SignalEngine._find_impulse (cognitive 43): SignalEngine._find_impulse has cognitive complexity 43 (threshold 15). Drivers by points: if/else 13 (38 pts), boolean chains 4, loops 1 (nesting depth added 25). 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/skills/elliott-wave/example_signal_engine.py"},"region":{"startLine":188}}}],"partialFingerprints":{"codehealthFindingId/v1":"b52dcd62f26b21b0c0440e79f5b75961cda483067dfdee7499e81d0355a72fbd"}},{"ruleId":"D2","level":"warning","message":{"text":"_RunDashboard.handle_event (cognitive 42): _RunDashboard.handle_event has cognitive complexity 42 (threshold 15). Drivers by points: if/else 16 (27 pts), boolean chains 11, loops 1 (2 pts), ternaries 1 (2 pts) (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":604}}}],"partialFingerprints":{"codehealthFindingId/v1":"182af6053890945c0dba4725536f3b50597903b62d7b65efb222a4bad9d8cfb4"}},{"ruleId":"D2","level":"warning","message":{"text":"WeixinChannel.send (cognitive 42): WeixinChannel.send has cognitive complexity 42 (threshold 15). Drivers by points: if/else 13 (16 pts), boolean chains 10, error handling 4 (7 pts), ternaries 2 (7 pts), loops 2 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/weixin.py"},"region":{"startLine":1090}}}],"partialFingerprints":{"codehealthFindingId/v1":"03fdf6843b481dd62600e5490a0b912e6dfc74f5f9c7c9c81fe139322623e51e"}},{"ruleId":"D2","level":"warning","message":{"text":"history_router.plan (cognitive 42): history_router.plan has cognitive complexity 42 (threshold 15). Drivers by points: if/else 14 (29 pts), boolean chains 6, ternaries 1 (4 pts), loops 2 (3 pts) (nesting depth added 19). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/data_gateway/history_router.py"},"region":{"startLine":113}}}],"partialFingerprints":{"codehealthFindingId/v1":"a0d991321beb0fbde581aa2f2511b0f2e21ef8a61b80a45e749feda78d9513ea"}},{"ruleId":"D2","level":"warning","message":{"text":"market_data._fetch_market_data_direct (cognitive 42): market_data._fetch_market_data_direct has cognitive complexity 42 (threshold 15). Drivers by points: if/else 11 (25 pts), loops 4 (6 pts), ternaries 3 (6 pts), boolean chains 3, error handling 1 (2 pts) (nesting depth added 20). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/market_data.py"},"region":{"startLine":220}}}],"partialFingerprints":{"codehealthFindingId/v1":"8b4d81844320f14d6860339c2afb0ed81053b83aeec3431bb738845cb58a1103"}},{"ruleId":"D2","level":"warning","message":{"text":"normalization.normalize_position (cognitive 42): normalization.normalize_position has cognitive complexity 42 (threshold 15). Drivers by points: boolean chains 21, ternaries 12 (16 pts), if/else 5 (nesting depth added 4). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/portfolio/normalization.py"},"region":{"startLine":56}}}],"partialFingerprints":{"codehealthFindingId/v1":"e2f16c56ac293e5037d7674144ca5640f36c4d94dc5685874899ba291e8df5da"}},{"ruleId":"D2","level":"warning","message":{"text":"SourcePrioritySettings.SourcePrioritySettings (cognitive 42): SourcePrioritySettings.SourcePrioritySettings has cognitive complexity 42 (threshold 15). Drivers by points: ternaries 14 (28 pts), boolean chains 7, if/else 6, error handling 1 (nesting depth added 14). Of this number, 23 points are the body\u0027s own statements and 19 belong to 10 function items inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/settings/SourcePrioritySettings.tsx"},"region":{"startLine":24}}}],"partialFingerprints":{"codehealthFindingId/v1":"3cfa3f24b92f1e464b6ae29d5699e9088424aad04db64ac5bb679c2acc357564"}},{"ruleId":"D2","level":"warning","message":{"text":"runs_routes._scan_factor_results (cognitive 41): runs_routes._scan_factor_results has cognitive complexity 41 (threshold 15). Drivers by points: if/else 13 (33 pts), boolean chains 3, error handling 1 (2 pts), ternaries 1 (2 pts), loops 1 (nesting depth added 22). 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/api/runs_routes.py"},"region":{"startLine":288}}}],"partialFingerprints":{"codehealthFindingId/v1":"ab18be56e9271b496138f2c517c1cc7a6cb7a0c7b6738063249c7e68b823059c"}},{"ruleId":"D2","level":"warning","message":{"text":"DingTalkChannel._fetch_remote_media_bytes (cognitive 41): DingTalkChannel._fetch_remote_media_bytes has cognitive complexity 41 (threshold 15). Drivers by points: if/else 13 (31 pts), loops 3 (6 pts), boolean chains 2, error handling 2 (nesting depth added 21). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/dingtalk.py"},"region":{"startLine":384}}}],"partialFingerprints":{"codehealthFindingId/v1":"3cc729f11f8c072d07e17df130088a3cd3122123d552b2b3519ba26529b84d76"}},{"ruleId":"D2","level":"warning","message":{"text":"TelegramChannel.send (cognitive 41): TelegramChannel.send has cognitive complexity 41 (threshold 15). Drivers by points: if/else 14 (24 pts), boolean chains 6, ternaries 2 (5 pts), error handling 2 (3 pts), loops 2 (3 pts) (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/telegram.py"},"region":{"startLine":750}}}],"partialFingerprints":{"codehealthFindingId/v1":"0757b7104350c6c4e9416a7a2d18974dbd4d75490e2ec7d7ac92e17cb8a855e7"}},{"ruleId":"D2","level":"warning","message":{"text":"MarketDataGateway._fetch (cognitive 41): MarketDataGateway._fetch has cognitive complexity 41 (threshold 15). Drivers by points: if/else 12 (23 pts), ternaries 3 (7 pts), boolean chains 5, error handling 2 (5 pts), loops 1 (nesting depth added 18). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/data_gateway/service.py"},"region":{"startLine":185}}}],"partialFingerprints":{"codehealthFindingId/v1":"cf79ca9d91ed79f36311811d8ac6c077a0a73373348cab525a85f7f545755899"}},{"ruleId":"D2","level":"warning","message":{"text":"SwarmRuntime._apply_resume_overlay (cognitive 41): SwarmRuntime._apply_resume_overlay has cognitive complexity 41 (threshold 15). Drivers by points: if/else 12 (26 pts), loops 7 (11 pts), boolean chains 3, error handling 1 (nesting depth added 18). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/swarm/runtime.py"},"region":{"startLine":783}}}],"partialFingerprints":{"codehealthFindingId/v1":"dc3c7f28bce786b815e8579c147deb373fbcb4e8aba8f875a71d90e2d17e9a15"}},{"ruleId":"D2","level":"warning","message":{"text":"data_refs.resolve_data_refs (cognitive 41): data_refs.resolve_data_refs has cognitive complexity 41 (threshold 15). Drivers by points: if/else 21 (29 pts), boolean chains 8, ternaries 2 (3 pts), loops 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/data_refs.py"},"region":{"startLine":12}}}],"partialFingerprints":{"codehealthFindingId/v1":"37ea1e0635bf3f1f43692954a9a452e899ee3dbe8fe42843b6af6d8c25ea26cf"}},{"ruleId":"D2","level":"warning","message":{"text":"etf_holdings_tool._holdings_cn (cognitive 41): etf_holdings_tool._holdings_cn has cognitive complexity 41 (threshold 15). Drivers by points: if/else 19 (27 pts), boolean chains 5, loops 2 (4 pts), ternaries 2 (4 pts), error handling 1 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/etf_holdings_tool.py"},"region":{"startLine":1491}}}],"partialFingerprints":{"codehealthFindingId/v1":"46348f2c135fc9c98d2a8033d9e604003324009e2bbbf66f6bede76527752556"}},{"ruleId":"D2","level":"warning","message":{"text":"financial_statements_tool._fetch_sec_statement (cognitive 41): financial_statements_tool._fetch_sec_statement has cognitive complexity 41 (threshold 15). Drivers by points: if/else 11 (26 pts), ternaries 3 (7 pts), loops 3 (4 pts), boolean chains 2, error handling 2 (nesting depth added 20). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/financial_statements_tool.py"},"region":{"startLine":684}}}],"partialFingerprints":{"codehealthFindingId/v1":"ecef1e08453c41b171e9865c1415788b386c35ff9cb5e3c1acc99cfc35dbee72"}},{"ruleId":"D2","level":"warning","message":{"text":"Compare.Compare (cognitive 41): Compare.Compare has cognitive complexity 41 (threshold 15). Drivers by points: boolean chains 23, if/else 12, ternaries 4 (6 pts) (nesting depth added 2). Of this number, 19 points are the body\u0027s own statements and 22 belong to 14 function literals inside it that branch. To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Compare.tsx"},"region":{"startLine":235}}}],"partialFingerprints":{"codehealthFindingId/v1":"72d762b873f2d38a5ed1c74ca2e40faf63fa55da7033aa5fb5e1738a23f7b572"}},{"ruleId":"D2","level":"warning","message":{"text":"_legacy._print_result (cognitive 40): _legacy._print_result has cognitive complexity 40 (threshold 15). Drivers by points: if/else 19 (27 pts), ternaries 4 (8 pts), loops 2 (3 pts), boolean chains 2 (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":1411}}}],"partialFingerprints":{"codehealthFindingId/v1":"7a6be83bda05e7bee109ea6bc79e58927f04311d0f1715e11c4be2016dc333ff"}},{"ruleId":"D2","level":"warning","message":{"text":"_legacy.cmd_connector_positions (cognitive 40): _legacy.cmd_connector_positions has cognitive complexity 40 (threshold 15). Drivers by points: if/else 8 (14 pts), boolean chains 12, ternaries 4 (9 pts), loops 2 (4 pts), error handling 1 (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":4941}}}],"partialFingerprints":{"codehealthFindingId/v1":"79025da7ff589ca088aab622e04875a83cfadefcbeb6654eef8698c36dc47688"}},{"ruleId":"D2","level":"warning","message":{"text":"FeishuChannel.send (cognitive 40): FeishuChannel.send has cognitive complexity 40 (threshold 15). Drivers by points: if/else 17 (30 pts), boolean chains 4, loops 2 (4 pts), error handling 1, ternaries 1 (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/feishu.py"},"region":{"startLine":2037}}}],"partialFingerprints":{"codehealthFindingId/v1":"b62d9b67e02747f9147fcfbb73d81c66d263b272e8e9631642bcb5da89800761"}},{"ruleId":"D2","level":"warning","message":{"text":"bar_summary.summarize_bars (cognitive 40): bar_summary.summarize_bars has cognitive complexity 40 (threshold 15). Drivers by points: ternaries 6 (16 pts), if/else 5 (12 pts), boolean chains 4, error handling 1 (4 pts), loops 2 (4 pts) (nesting depth added 22). 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/data_gateway/bar_summary.py"},"region":{"startLine":7}}}],"partialFingerprints":{"codehealthFindingId/v1":"cb4c8f9e73be347cfc5fda7328ecd11f11c6e568c3fd060dbcaacb046088f9ea"}},{"ruleId":"D2","level":"warning","message":{"text":"commit._resolve_profile (cognitive 40): commit._resolve_profile has cognitive complexity 40 (threshold 15). Drivers by points: if/else 11 (33 pts), boolean chains 5, loops 1 (2 pts) (nesting depth added 23). 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/live/mandate/commit.py"},"region":{"startLine":265}}}],"partialFingerprints":{"codehealthFindingId/v1":"683f92677b797fb982b586ce1492c9ca33f52566929444faf4c10f088110fb00"}},{"ruleId":"D2","level":"warning","message":{"text":"StrategyDiscoveryFacade.query_strategies (cognitive 40): StrategyDiscoveryFacade.query_strategies has cognitive complexity 40 (threshold 15). Drivers by points: if/else 14 (21 pts), boolean chains 8, error handling 4 (6 pts), loops 4, ternaries 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/strategy_discovery/facade.py"},"region":{"startLine":417}}}],"partialFingerprints":{"codehealthFindingId/v1":"60dff982788ad9922caef484f06602b1462028d847fc6baca6a8283021871063"}},{"ruleId":"D2","level":"warning","message":{"text":"InstitutionalHoldingsTool._ticker_holders (cognitive 40): InstitutionalHoldingsTool._ticker_holders has cognitive complexity 40 (threshold 15). Drivers by points: if/else 8 (19 pts), boolean chains 11, loops 4 (7 pts), error handling 1 (2 pts), ternaries 1 (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/institutional_holdings_tool.py"},"region":{"startLine":2000}}}],"partialFingerprints":{"codehealthFindingId/v1":"354b8ee394d8cbdbb595ede62095f83f265745042a3aed850c2deabc47f4a718"}},{"ruleId":"D2","level":"warning","message":{"text":"ReadFileTool.execute (cognitive 40): ReadFileTool.execute has cognitive complexity 40 (threshold 15). Drivers by points: if/else 16 (23 pts), error handling 4 (8 pts), boolean chains 4, loops 2 (3 pts), ternaries 1 (2 pts) (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/read_file_tool.py"},"region":{"startLine":107}}}],"partialFingerprints":{"codehealthFindingId/v1":"8438f4ead27dee2c2444b248b157e2b050635aa98b2b082f7a29b73b1af1ac09"}},{"ruleId":"D2","level":"warning","message":{"text":"PositionsTab.PositionsTab (cognitive 40): PositionsTab.PositionsTab has cognitive complexity 40 (threshold 15). Drivers by points: if/else 9 (15 pts), ternaries 8 (10 pts), boolean chains 7, loops 4 (7 pts), error handling 1 (nesting depth added 11). Most of this is not in the body itself: 5 of the 40 points are its own statements and the rest belongs to 11 function items inside it that branch (a function literal at line 175, handleResolve, a function literal at line 161, \u2026). The named helpers are already separate functions; the literals\u0027 work cannot be called, reviewed or tested from outside this body. To reduce it, move the named helpers out of the body to the enclosing scope and lift each literal\u0027s work into a named function there, so each is measured, reviewed and tested on its own, and reduce whichever one then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/run/PositionsTab.tsx"},"region":{"startLine":98}}}],"partialFingerprints":{"codehealthFindingId/v1":"0b6a7a689022bf7d38b247b1f767eabf280a1349bc95b108de4d53c6532dc3e1"}},{"ruleId":"D2","level":"warning","message":{"text":"CustomProviderManager.CustomProviderManager (cognitive 40): CustomProviderManager.CustomProviderManager has cognitive complexity 40 (threshold 15). Drivers by points: ternaries 17 (25 pts), boolean chains 9, error handling 3, if/else 3 (nesting depth added 8). Of this number, 16 points are the body\u0027s own statements and 24 belong to 6 function items inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/settings/CustomProviderManager.tsx"},"region":{"startLine":20}}}],"partialFingerprints":{"codehealthFindingId/v1":"89c1b586014a02170b7044a0f018492d0a386c0dc868323f4e28281fab4aca20"}},{"ruleId":"D2","level":"warning","message":{"text":"BaseEngine.run_backtest (cognitive 39): BaseEngine.run_backtest has cognitive complexity 39 (threshold 15). Drivers by points: if/else 19 (21 pts), ternaries 8 (11 pts), boolean chains 5, error handling 1, loops 1 (nesting depth added 5). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/engines/base.py"},"region":{"startLine":981}}}],"partialFingerprints":{"codehealthFindingId/v1":"f44da6a1b6aae185ccff742c74c35c078ab55dc17ca76fbefb06dd52ea5b7d73"}},{"ruleId":"D2","level":"warning","message":{"text":"DataLoader._fetch_one (cognitive 39): DataLoader._fetch_one has cognitive complexity 39 (threshold 15). Drivers by points: if/else 10 (25 pts), error handling 2 (6 pts), boolean chains 5, loops 2 (3 pts) (nesting depth added 20). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/tencent_loader.py"},"region":{"startLine":241}}}],"partialFingerprints":{"codehealthFindingId/v1":"3578e0a0fe8f5ea3714144f78acdec0f354e402e4e0bf29cf397479f6412475e"}},{"ruleId":"D2","level":"warning","message":{"text":"run_card._model_provenance (cognitive 39): run_card._model_provenance has cognitive complexity 39 (threshold 15). Drivers by points: if/else 12 (18 pts), ternaries 5 (8 pts), boolean chains 6, error handling 4 (6 pts), loops 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/run_card.py"},"region":{"startLine":47}}}],"partialFingerprints":{"codehealthFindingId/v1":"9932d4694f92aef6951f1404907e95276713da4fa37bfb24eb1d71185f9e9fb2"}},{"ruleId":"D2","level":"warning","message":{"text":"run_card._render_markdown (cognitive 39): run_card._render_markdown has cognitive complexity 39 (threshold 15). Drivers by points: if/else 20 (27 pts), loops 5 (8 pts), boolean chains 2, ternaries 2 (nesting depth added 10). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/run_card.py"},"region":{"startLine":521}}}],"partialFingerprints":{"codehealthFindingId/v1":"f3a9251e992850501e894ce09c8f98cc9f533a9b79541ddfa8f5adf64d508266"}},{"ruleId":"D2","level":"warning","message":{"text":"evidence._document_percent_cells (cognitive 39): evidence._document_percent_cells has cognitive complexity 39 (threshold 15). Drivers by points: if/else 9 (22 pts), boolean chains 6, ternaries 3 (6 pts), loops 2 (5 pts) (nesting depth added 19). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/grounding/evidence.py"},"region":{"startLine":814}}}],"partialFingerprints":{"codehealthFindingId/v1":"6cb403a542f4d1bcd2997dcc83f77e332d1cefff6f83307202c72f75585e3bdf"}},{"ruleId":"D2","level":"warning","message":{"text":"_PolicyMixin._indexed_field_ref_candidates (cognitive 39): _PolicyMixin._indexed_field_ref_candidates has cognitive complexity 39 (threshold 15). Drivers by points: if/else 10 (28 pts), boolean chains 7, loops 2 (3 pts), ternaries 1 (nesting depth added 19). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/grounding/policies.py"},"region":{"startLine":1225}}}],"partialFingerprints":{"codehealthFindingId/v1":"34cc165aca79fb85d1db2d9be961cc7f83f2d1a0464d4e5f8a2d3e205cbea473"}},{"ruleId":"D2","level":"warning","message":{"text":"ToolCallLifecycle._finalize_tool_result (cognitive 39): ToolCallLifecycle._finalize_tool_result has cognitive complexity 39 (threshold 15). Drivers by points: if/else 14 (23 pts), error handling 3 (7 pts), boolean chains 5, ternaries 3 (4 pts) (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/agent/tool_lifecycle.py"},"region":{"startLine":938}}}],"partialFingerprints":{"codehealthFindingId/v1":"56d6fdcfd96697676e6bfaff734f7e92b11d250c0818b2055dc3a968f7101380"}},{"ruleId":"D2","level":"warning","message":{"text":"WhatsAppChannel._handle_neonize_message (cognitive 39): WhatsAppChannel._handle_neonize_message has cognitive complexity 39 (threshold 15). Drivers by points: if/else 17 (20 pts), boolean chains 16, loops 1 (2 pts), ternaries 1 (nesting depth added 4). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/whatsapp.py"},"region":{"startLine":503}}}],"partialFingerprints":{"codehealthFindingId/v1":"c41aefc0f63d7cfb59cfa271d38a645b5a48d8c679111b2ab2535153d815206e"}},{"ruleId":"D2","level":"warning","message":{"text":"fanout.acquire_groups (cognitive 39): fanout.acquire_groups has cognitive complexity 39 (threshold 15). Drivers by points: if/else 6 (19 pts), error handling 3 (10 pts), loops 6 (8 pts), boolean chains 2 (nesting depth added 22). 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/data_gateway/fanout.py"},"region":{"startLine":20}}}],"partialFingerprints":{"codehealthFindingId/v1":"7c6e9758367faa9e32d1bf5e0dc1621e74eabf85b41aee88aac627200e402a70"}},{"ruleId":"D2","level":"warning","message":{"text":"ingest._load_panel_wide (cognitive 39): ingest._load_panel_wide has cognitive complexity 39 (threshold 15). Drivers by points: if/else 8 (12 pts), ternaries 4 (10 pts), error handling 3 (9 pts), loops 3 (5 pts), boolean chains 3 (nesting depth added 18). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/entities/ingest.py"},"region":{"startLine":1099}}}],"partialFingerprints":{"codehealthFindingId/v1":"2c8243d7ba2695d5a2ac11520cf7a497a2f5535f80b878c4c827b71be5086090"}},{"ruleId":"D2","level":"warning","message":{"text":"discovery._list_openai_codex_models (cognitive 39): discovery._list_openai_codex_models has cognitive complexity 39 (threshold 15). Drivers by points: if/else 11 (22 pts), boolean chains 7, loops 3 (5 pts), ternaries 1 (4 pts), error handling 1 (nesting depth added 16). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/providers/discovery.py"},"region":{"startLine":119}}}],"partialFingerprints":{"codehealthFindingId/v1":"27e15385a649c567162398ddb03398f460a0074c09ff59e038bd871f2e0373f3"}},{"ruleId":"D2","level":"warning","message":{"text":"portfolio.hierarchical_risk_parity (cognitive 39): portfolio.hierarchical_risk_parity has cognitive complexity 39 (threshold 15). Drivers by points: if/else 15 (26 pts), ternaries 3 (6 pts), boolean chains 4, loops 2 (3 pts) (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/portfolio.py"},"region":{"startLine":102}}}],"partialFingerprints":{"codehealthFindingId/v1":"ddc2ea7fc7092ef7d6925a761ae9ae5ed60d2a6489678f0c7f967ed6f2703f3d"}},{"ruleId":"D2","level":"warning","message":{"text":"ScheduledResearchJob.from_dict (cognitive 39): ScheduledResearchJob.from_dict has cognitive complexity 39 (threshold 15). Drivers by points: if/else 19 (20 pts), boolean chains 16, ternaries 2, loops 1 (nesting depth added 1). To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/scheduled_research/models.py"},"region":{"startLine":313}}}],"partialFingerprints":{"codehealthFindingId/v1":"bd82b1441084dddbd1a89efb0ea0b06a53b3dcf1ff66a7c0fd3c06da0aab6881"}},{"ruleId":"D2","level":"warning","message":{"text":"alpha_bench_tool.run_alpha_bench (cognitive 39): alpha_bench_tool.run_alpha_bench has cognitive complexity 39 (threshold 15). Drivers by points: error handling 12 (15 pts), if/else 12 (14 pts), boolean chains 6, ternaries 3, loops 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/alpha_bench_tool.py"},"region":{"startLine":1270}}}],"partialFingerprints":{"codehealthFindingId/v1":"418a30dafc6ce7f332d6f0095dd05f5e07114b4c79d99ffb44567f2e6b463b57"}},{"ruleId":"D2","level":"warning","message":{"text":"etf_holdings_tool._parse_cn_period (cognitive 39): etf_holdings_tool._parse_cn_period has cognitive complexity 39 (threshold 15). Drivers by points: if/else 12 (19 pts), ternaries 8 (13 pts), boolean chains 6, loops 1 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/etf_holdings_tool.py"},"region":{"startLine":892}}}],"partialFingerprints":{"codehealthFindingId/v1":"67faae071e9b978219f1343cbe1efc5558bcc1a87a503db1f07a991eaedb3050"}},{"ruleId":"D2","level":"warning","message":{"text":"ui_services.load_run_context (cognitive 39): ui_services.load_run_context has cognitive complexity 39 (threshold 15). Drivers by points: if/else 7 (21 pts), boolean chains 14, loops 1 (4 pts) (nesting depth added 17). To reduce it, flatten the nesting: this score is depth rather than breadth \u2014 most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language\u0027s equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/ui_services.py"},"region":{"startLine":102}}}],"partialFingerprints":{"codehealthFindingId/v1":"602626f21a6e30bc4454e6e113c75ea49a44588d650ee65c85a2ae8286a7f919"}},{"ruleId":"D2","level":"warning","message":{"text":"Settings.Settings (cognitive 39): Settings.Settings has cognitive complexity 39 (threshold 15). Drivers by points: ternaries 39 (51 pts), boolean chains 30, if/else 26 (30 pts), error handling 3 (nesting depth added 16). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level. This shape REPEATS in the file: 2 other methods here (Settings.Settings::submit, Settings.Settings::submitDataSources) have the same decision points, in the same order, at the same nesting depths \u2014 so this is one pattern written 3 times rather than 3 independent problems. Splitting this body alone leaves the other 2 exactly as they are. Where these are variations on one operation, the change that clears all 3 is the shared one: lift the common shape into a single routine the variants call, parameterised by whatever genuinely differs between them, and keep in each method only the part that is not shared."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Settings.tsx"},"region":{"startLine":42}}}],"partialFingerprints":{"codehealthFindingId/v1":"73792d3ba1c32fd092f969f16e21c6e17039639be7c250b382f29f731fb45980"}},{"ruleId":"D2","level":"warning","message":{"text":"runner._reject_forbidden_node (cognitive 38): runner._reject_forbidden_node has cognitive complexity 38 (threshold 15). Drivers by points: if/else 11 (25 pts), loops 3 (7 pts), boolean chains 3, ternaries 1 (3 pts) (nesting depth added 20). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/runner.py"},"region":{"startLine":687}}}],"partialFingerprints":{"codehealthFindingId/v1":"c4361c895bb7d7dffdbd1741b00cf755a13ac0f23975a9b096e89abe3472738c"}},{"ruleId":"D2","level":"warning","message":{"text":"_legacy._print_connector_account (cognitive 38): _legacy._print_connector_account has cognitive complexity 38 (threshold 15). Drivers by points: boolean chains 14, if/else 10 (14 pts), ternaries 2 (6 pts), loops 2 (4 pts) (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":4847}}}],"partialFingerprints":{"codehealthFindingId/v1":"0282ae23fad8f66bec4693f29e859cde793d018aa1bff57a6cab2c4c3e471bab"}},{"ruleId":"D2","level":"warning","message":{"text":"_EvidenceMixin._ingest_market_data (cognitive 38): _EvidenceMixin._ingest_market_data has cognitive complexity 38 (threshold 15). Drivers by points: if/else 7 (16 pts), ternaries 5 (9 pts), loops 4 (8 pts), boolean chains 5 (nesting depth added 17). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/grounding/evidence.py"},"region":{"startLine":1360}}}],"partialFingerprints":{"codehealthFindingId/v1":"c80197a9be2393c8695465770715efef9a27bcbf2f892f28f5150a6dfb44bbfb"}},{"ruleId":"D2","level":"warning","message":{"text":"claude_cli._decide (cognitive 38): claude_cli._decide has cognitive complexity 38 (threshold 15). Drivers by points: if/else 7 (17 pts), loops 4 (9 pts), ternaries 3 (6 pts), boolean chains 4, error handling 1 (2 pts) (nesting depth added 19). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/providers/claude_cli.py"},"region":{"startLine":377}}}],"partialFingerprints":{"codehealthFindingId/v1":"37ae7277781c3ad34960689d6fcfdebc8d9af0af0b9448e431292195b6243526"}},{"ruleId":"D2","level":"warning","message":{"text":"FinancialRigorTool.execute (cognitive 38): FinancialRigorTool.execute has cognitive complexity 38 (threshold 15). Drivers by points: if/else 10 (20 pts), boolean chains 8, loops 2 (4 pts), ternaries 2 (4 pts), error handling 2 (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/financial_rigor_tool.py"},"region":{"startLine":549}}}],"partialFingerprints":{"codehealthFindingId/v1":"64926a397d5e714b804f1041282775697f7726cf96acfb26a8c454c1a3729f9d"}},{"ruleId":"D2","level":"warning","message":{"text":"Runtime.Runtime (cognitive 38): Runtime.Runtime has cognitive complexity 38 (threshold 15). Drivers by points: ternaries 13 (22 pts), if/else 6 (8 pts), boolean chains 7, error handling 1 (nesting depth added 11). Of this number, 23 points are the body\u0027s own statements and 15 belong to 2 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Runtime.tsx"},"region":{"startLine":25}}}],"partialFingerprints":{"codehealthFindingId/v1":"2c9faa914bf6e76bd527cbbc748d2a9f35c7fcf720db18b100f19158a476f821"}},{"ruleId":"D2","level":"warning","message":{"text":"validation.walk_forward_analysis (cognitive 37): validation.walk_forward_analysis has cognitive complexity 37 (threshold 15). Drivers by points: if/else 11 (19 pts), ternaries 6 (12 pts), boolean chains 5, loops 1 (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/validation.py"},"region":{"startLine":246}}}],"partialFingerprints":{"codehealthFindingId/v1":"2d5695d6cde474b311cc07294d65f15a3a1f83ea1b48f26bb4e3e6a70892845e"}},{"ruleId":"D2","level":"warning","message":{"text":"_EvidenceMixin._ingest_run_dir_ohlc_csvs (cognitive 37): _EvidenceMixin._ingest_run_dir_ohlc_csvs has cognitive complexity 37 (threshold 15). Drivers by points: if/else 10 (25 pts), loops 3 (6 pts), error handling 2 (4 pts), boolean chains 2 (nesting depth added 20). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/grounding/evidence.py"},"region":{"startLine":1552}}}],"partialFingerprints":{"codehealthFindingId/v1":"ad859a541e758ea190cb10348ee10b2bc86ab8ca83d39843426d767348ac4c9a"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelRuntime._handle_inbound (cognitive 37): ChannelRuntime._handle_inbound has cognitive complexity 37 (threshold 15). Drivers by points: if/else 11 (16 pts), ternaries 5 (9 pts), boolean chains 8, error handling 4 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/runtime.py"},"region":{"startLine":122}}}],"partialFingerprints":{"codehealthFindingId/v1":"ecb76d2c5b793fe91a37dc829ff31b951f6f2e8722b5d9c4d4c542c3adf856e5"}},{"ruleId":"D2","level":"warning","message":{"text":"sdk_order_gate._allow (cognitive 37): sdk_order_gate._allow has cognitive complexity 37 (threshold 15). Drivers by points: if/else 10 (14 pts), ternaries 5 (10 pts), error handling 4 (8 pts), boolean chains 5 (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/live/sdk_order_gate.py"},"region":{"startLine":434}}}],"partialFingerprints":{"codehealthFindingId/v1":"e3da825362bb4bd46d760116fc53750c6b72a0d65ff5a7ffd154d1f0edf19af4"}},{"ruleId":"D2","level":"warning","message":{"text":"SignalEngine.generate (cognitive 37): SignalEngine.generate has cognitive complexity 37 (threshold 15). Drivers by points: loops 8 (17 pts), if/else 7 (16 pts), ternaries 1 (3 pts), boolean chains 1 (nesting depth added 20). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/skills/multi-factor/example_signal_engine.py"},"region":{"startLine":94}}}],"partialFingerprints":{"codehealthFindingId/v1":"f0211a22630e180b98358f1288473aa7d04e19493234a628e78b39fc3890935e"}},{"ruleId":"D2","level":"warning","message":{"text":"evidence_harness.compute_evidence_for_run (cognitive 37): evidence_harness.compute_evidence_for_run has cognitive complexity 37 (threshold 15). Drivers by points: if/else 17 (27 pts), boolean chains 5, ternaries 2 (3 pts), loops 2 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/strategy_discovery/evidence_harness.py"},"region":{"startLine":411}}}],"partialFingerprints":{"codehealthFindingId/v1":"f0584da366c4936bd3c5f09d0bb4fdf553d03b1eed0f7b48bb22dc3b31354a45"}},{"ruleId":"D2","level":"warning","message":{"text":"etf_holdings_tool._cn_etf_list (cognitive 37): etf_holdings_tool._cn_etf_list has cognitive complexity 37 (threshold 15). Drivers by points: if/else 9 (18 pts), ternaries 4 (9 pts), boolean chains 5, loops 2 (3 pts), error handling 1 (2 pts) (nesting depth added 16). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/etf_holdings_tool.py"},"region":{"startLine":1202}}}],"partialFingerprints":{"codehealthFindingId/v1":"58b6e4a87557b216a8cb7caeea06a5d1e4956970e25e90e84bbb7db2d65981ce"}},{"ruleId":"D2","level":"warning","message":{"text":"reconcile.reconcile_document (cognitive 37): reconcile.reconcile_document has cognitive complexity 37 (threshold 15). Drivers by points: if/else 14 (26 pts), ternaries 2 (5 pts), boolean chains 3, loops 3 (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/paper_trade/reconcile.py"},"region":{"startLine":149}}}],"partialFingerprints":{"codehealthFindingId/v1":"7665e3c49b5287c13b4b9ff0e385e573c334fe028417b8395da41aaee67224e6"}},{"ruleId":"D2","level":"warning","message":{"text":"SymbolSearchTool.execute (cognitive 37): SymbolSearchTool.execute has cognitive complexity 37 (threshold 15). Drivers by points: if/else 17 (24 pts), boolean chains 11, ternaries 2 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/symbol_search_tool.py"},"region":{"startLine":263}}}],"partialFingerprints":{"codehealthFindingId/v1":"3cac444a023240e78acfda6ceea73e8d1160b89e74dbdb4e0596feda81d1046d"}},{"ruleId":"D2","level":"warning","message":{"text":"TechnicalIndicatorTool.execute (cognitive 37): TechnicalIndicatorTool.execute has cognitive complexity 37 (threshold 15). Drivers by points: if/else 14 (16 pts), boolean chains 10, ternaries 6, error handling 3 (4 pts), loops 1 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/technical_indicator_tool.py"},"region":{"startLine":322}}}],"partialFingerprints":{"codehealthFindingId/v1":"094dbd38e982c72ccb2dda0da56b7ed88651c0f55ceea727fe062fe8ccd9248f"}},{"ruleId":"D2","level":"warning","message":{"text":"MandateProposalCard.MandateProposalCard (cognitive 37): MandateProposalCard.MandateProposalCard has cognitive complexity 37 (threshold 15). Drivers by points: boolean chains 18, ternaries 9 (12 pts), if/else 6, error handling 1 (nesting depth added 3). Of this number, 23 points are the body\u0027s own statements and 14 belong to 7 function literals inside it that branch. To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/chat/MandateProposalCard.tsx"},"region":{"startLine":203}}}],"partialFingerprints":{"codehealthFindingId/v1":"285691a9464f37a6c293832b237f055ff0025c1067e360f1abdc32edb78e493b"}},{"ruleId":"D2","level":"warning","message":{"text":"AlphaZoo.BrowseView (cognitive 37): AlphaZoo.BrowseView has cognitive complexity 37 (threshold 15). Drivers by points: ternaries 13 (16 pts), boolean chains 15, if/else 3, loops 2 (3 pts) (nesting depth added 4). Most of this is not in the body itself: 13 of the 37 points are its own statements and the rest belongs to 10 function literals inside it that branch (lines 197, 386, 189, \u2026). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/AlphaZoo.tsx"},"region":{"startLine":143}}}],"partialFingerprints":{"codehealthFindingId/v1":"2ec17a3eec194becdf15215caab0683fbb4a5a2dab33ee9f8e72e7cf2e2ead8a"}},{"ruleId":"D2","level":"warning","message":{"text":"instrument_identity._normalize_symbol (cognitive 36): instrument_identity._normalize_symbol has cognitive complexity 36 (threshold 15). Drivers by points: if/else 12 (23 pts), boolean chains 5, ternaries 2 (5 pts), loops 1 (3 pts) (nesting depth added 16). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/agent/instrument_identity.py"},"region":{"startLine":165}}}],"partialFingerprints":{"codehealthFindingId/v1":"9e68037e19228628220bba012aa36716d9b7ff6d3ea755e13e2e27d6975da43e"}},{"ruleId":"D2","level":"warning","message":{"text":"WeixinChannel._qr_login (cognitive 36): WeixinChannel._qr_login has cognitive complexity 36 (threshold 15). Drivers by points: if/else 11 (30 pts), error handling 2 (3 pts), boolean chains 2, loops 1 (nesting depth added 20). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/weixin.py"},"region":{"startLine":342}}}],"partialFingerprints":{"codehealthFindingId/v1":"7ef12c5732872f56018e02717d7bb41b166d4740334cf34998083c46331d1157"}},{"ruleId":"D2","level":"warning","message":{"text":"openai_codex._convert_messages (cognitive 36): openai_codex._convert_messages has cognitive complexity 36 (threshold 15). Drivers by points: if/else 6 (19 pts), boolean chains 7, ternaries 2 (6 pts), loops 2 (4 pts) (nesting depth added 19). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/providers/openai_codex.py"},"region":{"startLine":466}}}],"partialFingerprints":{"codehealthFindingId/v1":"5a751959a93622e9349e389d51fbe89d9dc142bd329781896eeaa6ad0924f0bd"}},{"ruleId":"D2","level":"warning","message":{"text":"volatility.implied_volatility_surface (cognitive 36): volatility.implied_volatility_surface has cognitive complexity 36 (threshold 15). Drivers by points: if/else 10 (23 pts), boolean chains 5, loops 4 (5 pts), ternaries 1 (3 pts) (nesting depth added 16). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/volatility.py"},"region":{"startLine":279}}}],"partialFingerprints":{"codehealthFindingId/v1":"5cd84e12c94028ae408da5cceaacaac718c8cfb51e29f1133717b515dae251c2"}},{"ruleId":"D2","level":"warning","message":{"text":"ScheduledResearchExecutor.sweep_deliveries (cognitive 36): ScheduledResearchExecutor.sweep_deliveries has cognitive complexity 36 (threshold 15). Drivers by points: if/else 15 (27 pts), error handling 3 (6 pts), boolean chains 2, loops 1 (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/scheduled_research/executor.py"},"region":{"startLine":567}}}],"partialFingerprints":{"codehealthFindingId/v1":"7fd950287af4c564a20529326e070deb9117077e75a0562555d871279185f643"}},{"ruleId":"D2","level":"warning","message":{"text":"ResearchPapersTool.execute (cognitive 36): ResearchPapersTool.execute has cognitive complexity 36 (threshold 15). Drivers by points: if/else 14 (17 pts), boolean chains 10, error handling 2 (3 pts), loops 2 (3 pts), ternaries 2 (3 pts) (nesting depth added 6). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/research_papers_tool.py"},"region":{"startLine":1559}}}],"partialFingerprints":{"codehealthFindingId/v1":"7d0786dc07662aace112beb9cf47e98dc61f9c0ce9f83cbcacf4e841f2b7db78"}},{"ruleId":"D2","level":"warning","message":{"text":"southbound_tool._parse_hkex_report (cognitive 36): southbound_tool._parse_hkex_report has cognitive complexity 36 (threshold 15). Drivers by points: if/else 6 (13 pts), loops 4 (10 pts), ternaries 3 (7 pts), boolean chains 5, error handling 1 (nesting depth added 17). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/southbound_tool.py"},"region":{"startLine":175}}}],"partialFingerprints":{"codehealthFindingId/v1":"474705f9ddb6b47e8269b573e659791563ee670fda2374b505eb33690a1b2272"}},{"ruleId":"D2","level":"warning","message":{"text":"sdk.place_order (cognitive 36): sdk.place_order has cognitive complexity 36 (threshold 15). Drivers by points: if/else 16 (20 pts), boolean chains 6, error handling 4 (5 pts), ternaries 5 (nesting depth added 5). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/alpaca/sdk.py"},"region":{"startLine":460}}}],"partialFingerprints":{"codehealthFindingId/v1":"0404fe60d0c438435f9cbfb51bfb754986c4923d8de73959ecc9cb6f978dba5b"}},{"ruleId":"D2","level":"warning","message":{"text":"update-verification.compareSemanticVersions (cognitive 36): update-verification.compareSemanticVersions has cognitive complexity 36 (threshold 15). Drivers by points: if/else 11 (19 pts), ternaries 4 (12 pts), boolean chains 3, loops 2 (nesting depth added 16). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"desktop/electron/src/update-verification.ts"},"region":{"startLine":237}}}],"partialFingerprints":{"codehealthFindingId/v1":"d50289660be40a8981fcf13f48d4d5e5090e24c432edf1980eb8dd471b1c276d"}},{"ruleId":"D2","level":"warning","message":{"text":"useAlphaJob.useAlphaJob.connect (cognitive 36): useAlphaJob.useAlphaJob.connect has cognitive complexity 36 (threshold 15). Drivers by points: ternaries 8 (18 pts), if/else 9 (10 pts), boolean chains 4, error handling 4 (nesting depth added 11). Most of this is not in the body itself: 10 of the 36 points are its own statements and the rest belongs to 7 function literals inside it that branch (lines 60, 50, 37, \u2026). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/hooks/useAlphaJob.ts"},"region":{"startLine":19}}}],"partialFingerprints":{"codehealthFindingId/v1":"45d4f1139e572de27c7153acd8e2298f782c5921e64f012309d44e6531d7c844"}},{"ruleId":"D2","level":"warning","message":{"text":"_EvidenceMixin._record_backtest_metrics (cognitive 35): _EvidenceMixin._record_backtest_metrics has cognitive complexity 35 (threshold 15). Drivers by points: if/else 10 (18 pts), loops 4 (7 pts), boolean chains 6, error handling 1 (2 pts), ternaries 1 (2 pts) (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/grounding/evidence.py"},"region":{"startLine":999}}}],"partialFingerprints":{"codehealthFindingId/v1":"15641477029d0b1abb5d15ec04e989ba281b2c1973164819c2d0c5906e975268"}},{"ruleId":"D2","level":"warning","message":{"text":"evidence._wrapped_percent_headers (cognitive 35): evidence._wrapped_percent_headers has cognitive complexity 35 (threshold 15). Drivers by points: if/else 8 (20 pts), boolean chains 10, loops 3 (5 pts) (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/grounding/evidence.py"},"region":{"startLine":752}}}],"partialFingerprints":{"codehealthFindingId/v1":"42a53beca5d316a02e642b09438b4e608e909a8a87215acb3685ea6501e13f78"}},{"ruleId":"D2","level":"warning","message":{"text":"GroundingLedger.ingest_tool_result (cognitive 35): GroundingLedger.ingest_tool_result has cognitive complexity 35 (threshold 15). Drivers by points: if/else 9 (18 pts), boolean chains 7, ternaries 2 (7 pts), loops 1 (3 pts) (nesting depth added 16). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/grounding/ledger.py"},"region":{"startLine":121}}}],"partialFingerprints":{"codehealthFindingId/v1":"4a3754d786d9114a17fe444d4f15149e5b1ed32354019eecae567067cf2d0e7b"}},{"ruleId":"D2","level":"warning","message":{"text":"assertions._identity_verdicts (cognitive 35): assertions._identity_verdicts has cognitive complexity 35 (threshold 15). Drivers by points: if/else 11 (16 pts), ternaries 9 (15 pts), boolean chains 4 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/harness/assertions.py"},"region":{"startLine":349}}}],"partialFingerprints":{"codehealthFindingId/v1":"7a2d78a03c9424deb0b4f47072de5d9f3917dbe79e22fe1b358a1de0683eac4b"}},{"ruleId":"D2","level":"warning","message":{"text":"runner._prepare_sandbox_home (cognitive 35): runner._prepare_sandbox_home has cognitive complexity 35 (threshold 15). Drivers by points: error handling 6 (15 pts), if/else 7 (15 pts), loops 1 (3 pts), boolean chains 1, ternaries 1 (nesting depth added 19). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/core/runner.py"},"region":{"startLine":181}}}],"partialFingerprints":{"codehealthFindingId/v1":"9b94e759cc5324a436a42e0b902851287dc25add1b4d21fc1dfeea3a1d7da030"}},{"ruleId":"D2","level":"warning","message":{"text":"cli_handlers.cmd_alpha_list (cognitive 35): cli_handlers.cmd_alpha_list has cognitive complexity 35 (threshold 15). Drivers by points: if/else 10 (13 pts), boolean chains 11, loops 3 (6 pts), ternaries 2 (4 pts), error handling 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/cli_handlers.py"},"region":{"startLine":188}}}],"partialFingerprints":{"codehealthFindingId/v1":"7a76a1266384befec406a761b9c3532c7e8812c567b862293d68ba45e3c3dbd1"}},{"ruleId":"D2","level":"warning","message":{"text":"SignalEngine._find_abc (cognitive 35): SignalEngine._find_abc has cognitive complexity 35 (threshold 15). Drivers by points: if/else 11 (32 pts), boolean chains 2, loops 1 (nesting depth added 21). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/skills/elliott-wave/example_signal_engine.py"},"region":{"startLine":285}}}],"partialFingerprints":{"codehealthFindingId/v1":"893bb5aafc27d926070dd90ab9bc07de2e01347d0f60286b0b86655511fad974"}},{"ruleId":"D2","level":"warning","message":{"text":"example_signal_engine._detect_patterns_pyharmonics (cognitive 35): example_signal_engine._detect_patterns_pyharmonics has cognitive complexity 35 (threshold 15). Drivers by points: if/else 5 (15 pts), ternaries 2 (8 pts), loops 3 (6 pts), error handling 1 (4 pts), boolean chains 2 (nesting depth added 22). 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/skills/harmonic/example_signal_engine.py"},"region":{"startLine":249}}}],"partialFingerprints":{"codehealthFindingId/v1":"98eee2cf0f8ce18e33fdc86be5a62bf99753e2dcd61786044e83362403b6dd2d"}},{"ruleId":"D2","level":"warning","message":{"text":"SwarmRuntime._execute_layer (cognitive 35): SwarmRuntime._execute_layer has cognitive complexity 35 (threshold 15). Drivers by points: if/else 7 (16 pts), loops 5 (8 pts), error handling 4 (7 pts), boolean chains 3, ternaries 1 (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/swarm/runtime.py"},"region":{"startLine":992}}}],"partialFingerprints":{"codehealthFindingId/v1":"bcfb6ff9a9fef778bbfa76718d732468af1a7982481fe2b8e109d70f2a36660b"}},{"ruleId":"D2","level":"warning","message":{"text":"formatters.metricSentiment (cognitive 35): formatters.metricSentiment has cognitive complexity 35 (threshold 15). Drivers by points: ternaries 12 (28 pts), if/else 6, boolean chains 1 (nesting depth added 16). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/lib/formatters.ts"},"region":{"startLine":69}}}],"partialFingerprints":{"codehealthFindingId/v1":"31ae21139e1d5c191dafb8224f5ab4a93ca5a876f5e97b4d7e113de4f0f00d4d"}},{"ruleId":"D2","level":"warning","message":{"text":"_PolicyMixin._artifact_scope (cognitive 34): _PolicyMixin._artifact_scope has cognitive complexity 34 (threshold 15). Drivers by points: if/else 10 (16 pts), boolean chains 11, ternaries 2 (5 pts), loops 2 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/grounding/policies.py"},"region":{"startLine":1059}}}],"partialFingerprints":{"codehealthFindingId/v1":"551d350fcb6a4e1dd4ebab4f6eb7fc46441ca15bab22d2e339e1039af0388cb9"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelManager._dispatch_outbound (cognitive 34): ChannelManager._dispatch_outbound has cognitive complexity 34 (threshold 15). Drivers by points: if/else 11 (24 pts), boolean chains 5, error handling 2 (4 pts), loops 1 (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/manager.py"},"region":{"startLine":458}}}],"partialFingerprints":{"codehealthFindingId/v1":"af6b6cfc09ac35587d81afc44d3080953e13e98affda8c24c50d7c62bc4c9fbe"}},{"ruleId":"D2","level":"warning","message":{"text":"history_router._normalize (cognitive 34): history_router._normalize has cognitive complexity 34 (threshold 15). Drivers by points: if/else 13 (20 pts), boolean chains 9, ternaries 3 (4 pts), loops 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/data_gateway/history_router.py"},"region":{"startLine":222}}}],"partialFingerprints":{"codehealthFindingId/v1":"c3248d663069ff1cc21f06a85ec377287d8c3b0b6cbc02ae9d67ad2ceedff52e"}},{"ruleId":"D2","level":"warning","message":{"text":"combination.combine_factors (cognitive 34): combination.combine_factors has cognitive complexity 34 (threshold 15). Drivers by points: if/else 17 (21 pts), ternaries 6, boolean chains 5, loops 2 (nesting depth added 4). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/combination.py"},"region":{"startLine":323}}}],"partialFingerprints":{"codehealthFindingId/v1":"2fbee8033994f6adccf26b94df4648c4dba675fd123ac53670746ebdc22043e1"}},{"ruleId":"D2","level":"warning","message":{"text":"neutralization.pca_factors (cognitive 34): neutralization.pca_factors has cognitive complexity 34 (threshold 15). Drivers by points: if/else 10 (19 pts), ternaries 4 (8 pts), boolean chains 4, loops 2 (3 pts) (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/neutralization.py"},"region":{"startLine":385}}}],"partialFingerprints":{"codehealthFindingId/v1":"4ee362222c77f001c36af702912df5de6a69a7646b84a24784e8b8695e5779a1"}},{"ruleId":"D2","level":"warning","message":{"text":"_StockPlusOption._run (cognitive 34): _StockPlusOption._run has cognitive complexity 34 (threshold 15). Drivers by points: if/else 9 (22 pts), loops 2 (5 pts), ternaries 1 (4 pts), boolean chains 3 (nesting depth added 19). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/skills/options-strategy/example_signal_engine.py"},"region":{"startLine":268}}}],"partialFingerprints":{"codehealthFindingId/v1":"f9c6b639c97e1de7fc17f41c0030389d96749c7740818d482ea7bf1ca05b2ab5"}},{"ruleId":"D2","level":"warning","message":{"text":"OptionsChainTool.execute (cognitive 34): OptionsChainTool.execute has cognitive complexity 34 (threshold 15). Drivers by points: if/else 10 (16 pts), boolean chains 7, loops 2 (5 pts), ternaries 2 (4 pts), error handling 1 (2 pts) (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/options_chain_tool.py"},"region":{"startLine":71}}}],"partialFingerprints":{"codehealthFindingId/v1":"b61d55065c0f36cc34dfa3f96dac7b23c9b2fd1724f6a097aecfc69c8069a8a5"}},{"ruleId":"D2","level":"warning","message":{"text":"SwarmTool.execute (cognitive 34): SwarmTool.execute has cognitive complexity 34 (threshold 15). Drivers by points: if/else 15 (24 pts), error handling 4 (5 pts), loops 2, ternaries 2, boolean chains 1 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/swarm_tool.py"},"region":{"startLine":540}}}],"partialFingerprints":{"codehealthFindingId/v1":"f9dff24ce26220f7aa50e6c48a05eb9170d6c5c4dc42b4f6094035e8210cf3c3"}},{"ruleId":"D2","level":"warning","message":{"text":"ConnectionStore._parse (cognitive 34): ConnectionStore._parse has cognitive complexity 34 (threshold 15). Drivers by points: if/else 13 (19 pts), boolean chains 13, error handling 1 (2 pts) (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connections.py"},"region":{"startLine":356}}}],"partialFingerprints":{"codehealthFindingId/v1":"7e4c08c9007f64cd0cbbb3a0e27ccce92b9aedd07507ce16f04143ed82a3c07a"}},{"ruleId":"D2","level":"warning","message":{"text":"OptionsChainTable.OptionsChainTable (cognitive 34): OptionsChainTable.OptionsChainTable has cognitive complexity 34 (threshold 15). Drivers by points: ternaries 8 (14 pts), boolean chains 11, if/else 7 (8 pts), error handling 1 (nesting depth added 7). Of this number, 18 points are the body\u0027s own statements and 16 belong to 5 function items inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/options/OptionsChainTable.tsx"},"region":{"startLine":139}}}],"partialFingerprints":{"codehealthFindingId/v1":"491009a80d07dc2b5a09c34cbf1b12ef0c0d25fd27311d57d0eb7e6b05a9fc78"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelConfigPanel.ChannelConfigPanel::renderField (cognitive 34): ChannelConfigPanel.ChannelConfigPanel::renderField has cognitive complexity 34 (threshold 15). Drivers by points: ternaries 18 (27 pts), boolean chains 4, if/else 3 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body. This shape REPEATS in the file: one other method here (ChannelConfigPanel.ChannelConfigPanel) has the same decision points, in the same order, at the same nesting depths \u2014 so this is one pattern written twice rather than two separate problems. Splitting this body alone leaves the other exactly as it is. Where these are variations on one operation, the change that clears both is the shared one: lift the common shape into a single routine the variants call, parameterised by whatever genuinely differs between them, and keep in each method only the part that is not shared."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/settings/ChannelConfigPanel.tsx"},"region":{"startLine":534}}}],"partialFingerprints":{"codehealthFindingId/v1":"d09a7c22d70dc5571ac4330a9de3dbb66ebe02f4c984235c9337f99594905e2c"}},{"ruleId":"D2","level":"warning","message":{"text":"binance_shadow_evidence._validate_evidence (cognitive 33): binance_shadow_evidence._validate_evidence has cognitive complexity 33 (threshold 15). Drivers by points: if/else 16 (20 pts), boolean chains 7, loops 4, ternaries 1 (2 pts) (nesting depth added 5). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/binance_shadow_evidence.py"},"region":{"startLine":262}}}],"partialFingerprints":{"codehealthFindingId/v1":"b6ee6c55e9a00e931a5a5c4476f4c1a314bf2af3330a12c3e81aaaeaf1fc36d5"}},{"ruleId":"D2","level":"warning","message":{"text":"valuation_loader.load_valuation_panel (cognitive 33): valuation_loader.load_valuation_panel has cognitive complexity 33 (threshold 15). Drivers by points: if/else 11 (21 pts), loops 3 (7 pts), error handling 1 (3 pts), boolean chains 2 (nesting depth added 16). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/valuation_loader.py"},"region":{"startLine":237}}}],"partialFingerprints":{"codehealthFindingId/v1":"6e5d8858a8603b3c9d67cc46621f62a571e988ffbc03023c9cd2ecda146f3e13"}},{"ruleId":"D2","level":"warning","message":{"text":"TurnoverAwareOptimizer._calc_weights (cognitive 33): TurnoverAwareOptimizer._calc_weights has cognitive complexity 33 (threshold 15). Drivers by points: if/else 12 (19 pts), loops 4 (8 pts), boolean chains 4, ternaries 1 (2 pts) (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/optimizers/turnover_aware.py"},"region":{"startLine":160}}}],"partialFingerprints":{"codehealthFindingId/v1":"f62d7acdaccf8d48bd4dbb0a5025d4fc1a8df52e1b0be84bc037303a1f401555"}},{"ruleId":"D2","level":"warning","message":{"text":"_legacy._print_portfolio_snapshot (cognitive 33): _legacy._print_portfolio_snapshot has cognitive complexity 33 (threshold 15). Drivers by points: boolean chains 16, ternaries 5 (9 pts), if/else 2 (4 pts), loops 4 (nesting depth added 6). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":4108}}}],"partialFingerprints":{"codehealthFindingId/v1":"265200eb709a1f6349130bbda7b4957858e372a50d7675e70f1f04c7975bc388"}},{"ruleId":"D2","level":"warning","message":{"text":"_legacy.cmd_connector_setup (cognitive 33): _legacy.cmd_connector_setup has cognitive complexity 33 (threshold 15). Drivers by points: if/else 10 (15 pts), boolean chains 9, ternaries 2 (4 pts), loops 2 (3 pts), error handling 2 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":4463}}}],"partialFingerprints":{"codehealthFindingId/v1":"887de617622e51bd5688cd7fba7884dfe3a43049f11d3344711f9369dc7846c0"}},{"ruleId":"D2","level":"warning","message":{"text":"result_artifacts.deliver_tool_result (cognitive 33): result_artifacts.deliver_tool_result has cognitive complexity 33 (threshold 15). Drivers by points: if/else 10 (18 pts), loops 4 (7 pts), error handling 3, ternaries 3, boolean chains 2 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/agent/result_artifacts.py"},"region":{"startLine":136}}}],"partialFingerprints":{"codehealthFindingId/v1":"c6e82009dd60ab9ba5f50dde5a2fa7538aed8e643c3936e522f19ef77ae3dbd7"}},{"ruleId":"D2","level":"warning","message":{"text":"write_targets.pending_write_directive (cognitive 33): write_targets.pending_write_directive has cognitive complexity 33 (threshold 15). Drivers by points: if/else 10 (19 pts), error handling 2 (7 pts), boolean chains 4, loops 2 (3 pts) (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/agent/write_targets.py"},"region":{"startLine":114}}}],"partialFingerprints":{"codehealthFindingId/v1":"f12d545ee3d708c10b11eeb9748d305f7632f56d9b739d9031db4d14af2c13f6"}},{"ruleId":"D2","level":"warning","message":{"text":"attribution_core._build_attribution_payload (cognitive 33): attribution_core._build_attribution_payload has cognitive complexity 33 (threshold 15). Drivers by points: if/else 14 (17 pts), boolean chains 10, ternaries 3 (5 pts), error handling 1 (nesting depth added 5). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/api/attribution_core.py"},"region":{"startLine":776}}}],"partialFingerprints":{"codehealthFindingId/v1":"3f14358a43ff83458ce84d825b9b30af59fd261dabbce501174c9483ad6cee58"}},{"ruleId":"D2","level":"warning","message":{"text":"EmailChannel.start (cognitive 33): EmailChannel.start has cognitive complexity 33 (threshold 15). Drivers by points: if/else 9 (18 pts), boolean chains 7, error handling 2 (5 pts), loops 2 (3 pts) (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/email.py"},"region":{"startLine":171}}}],"partialFingerprints":{"codehealthFindingId/v1":"8fa33b5b064c6b0d0db5de955795e241eedfb314b25e814de419666625b09e9b"}},{"ruleId":"D2","level":"warning","message":{"text":"MSTeamsChannel._normalize_teams_reply_quote (cognitive 33): MSTeamsChannel._normalize_teams_reply_quote has cognitive complexity 33 (threshold 15). Drivers by points: if/else 11 (22 pts), boolean chains 6, loops 2 (3 pts), ternaries 1 (2 pts) (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/msteams.py"},"region":{"startLine":441}}}],"partialFingerprints":{"codehealthFindingId/v1":"0d4e3e07486b3f2a7e8a14a8a547d420a8fe408811ed79f50d78d761e81140d3"}},{"ruleId":"D2","level":"warning","message":{"text":"calendars.validate (cognitive 33): calendars.validate has cognitive complexity 33 (threshold 15). Drivers by points: if/else 9 (15 pts), loops 3 (7 pts), ternaries 3 (7 pts), boolean chains 4 (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/data_gateway/calendars.py"},"region":{"startLine":40}}}],"partialFingerprints":{"codehealthFindingId/v1":"f3899a81babc602f2eea7af08b439e4b9ae7a8e0741e7cbb382fb8a836ac3fe2"}},{"ruleId":"D2","level":"warning","message":{"text":"MemoryLifecycle.run_gc (cognitive 33): MemoryLifecycle.run_gc has cognitive complexity 33 (threshold 15). Drivers by points: if/else 10 (22 pts), ternaries 1 (4 pts), loops 2 (3 pts), boolean chains 2, error handling 1 (2 pts) (nesting depth added 17). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/memory/lifecycle.py"},"region":{"startLine":183}}}],"partialFingerprints":{"codehealthFindingId/v1":"bad0dc2401a5aefa169d8b67c53fdde201511d014e44a1c8f9be865a556c7f2d"}},{"ruleId":"D2","level":"warning","message":{"text":"stream_guard.supervised_pulls (cognitive 33): stream_guard.supervised_pulls has cognitive complexity 33 (threshold 15). Drivers by points: if/else 8 (15 pts), ternaries 3 (8 pts), boolean chains 7, error handling 1 (2 pts), loops 1 (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/providers/stream_guard.py"},"region":{"startLine":131}}}],"partialFingerprints":{"codehealthFindingId/v1":"f4a2c92ab83158ef73f7485b2f7ebc2387e35e438b644001aeb7065716afebcb"}},{"ruleId":"D2","level":"warning","message":{"text":"ResearchArtifactStore.save (cognitive 33): ResearchArtifactStore.save has cognitive complexity 33 (threshold 15). Drivers by points: boolean chains 15, if/else 8 (9 pts), ternaries 5 (9 pts) (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/research_artifacts/store.py"},"region":{"startLine":195}}}],"partialFingerprints":{"codehealthFindingId/v1":"d0362750f39ff5bfd8f58434baff92f3a68e1253023b76bd96cae907e3260d4a"}},{"ruleId":"D2","level":"warning","message":{"text":"SignalEngine._evaluate_signals (cognitive 33): SignalEngine._evaluate_signals has cognitive complexity 33 (threshold 15). Drivers by points: if/else 18 (27 pts), boolean chains 6 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/skills/chanlun/example_signal_engine.py"},"region":{"startLine":134}}}],"partialFingerprints":{"codehealthFindingId/v1":"073ced783674fa6a74f3eac394fea11cc9c0fe7ae5132bdf46c52ab2f69d6f4a"}},{"ruleId":"D2","level":"warning","message":{"text":"run_artifacts.read_trade_activity (cognitive 33): run_artifacts.read_trade_activity has cognitive complexity 33 (threshold 15). Drivers by points: if/else 9 (15 pts), ternaries 5 (9 pts), boolean chains 6, loops 2, error handling 1 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/strategy_discovery/run_artifacts.py"},"region":{"startLine":128}}}],"partialFingerprints":{"codehealthFindingId/v1":"3a0f1a0d2f8c28cadf05a7cdfad432d18f8c6f55999f6be8c23acaba8b09f0f7"}},{"ruleId":"D2","level":"warning","message":{"text":"GildataFundNavTool._fetch_one (cognitive 33): GildataFundNavTool._fetch_one has cognitive complexity 33 (threshold 15). Drivers by points: if/else 12 (25 pts), boolean chains 4, loops 2 (3 pts), ternaries 1 (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/fund_nav_tool.py"},"region":{"startLine":223}}}],"partialFingerprints":{"codehealthFindingId/v1":"270a174a32ad5c4a53a407848b9211ae575c59c1e60ebeb25d74e46608eeaf7e"}},{"ruleId":"D2","level":"warning","message":{"text":"institutional_holdings_tool._walk_chain (cognitive 33): institutional_holdings_tool._walk_chain has cognitive complexity 33 (threshold 15). Drivers by points: if/else 13 (21 pts), boolean chains 7, ternaries 2 (4 pts), loops 1 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/institutional_holdings_tool.py"},"region":{"startLine":1208}}}],"partialFingerprints":{"codehealthFindingId/v1":"754bef774b436f0e8f14a665d886af7e226ef754ed999e96273601edfce7deb6"}},{"ruleId":"D2","level":"warning","message":{"text":"sdk.place_order (cognitive 33): sdk.place_order has cognitive complexity 33 (threshold 15). Drivers by points: if/else 16 (18 pts), boolean chains 9, error handling 5 (6 pts) (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/tiger/sdk.py"},"region":{"startLine":335}}}],"partialFingerprints":{"codehealthFindingId/v1":"b94ee565f9eb44ab65848bfa6729da92e8fb3c62c64e72fcfa2d06e07eb8fdbf"}},{"ruleId":"D2","level":"warning","message":{"text":"HistoryStorageSettings.HistoryStorageSettings (cognitive 33): HistoryStorageSettings.HistoryStorageSettings has cognitive complexity 33 (threshold 15). Drivers by points: boolean chains 13, if/else 7 (9 pts), ternaries 8 (9 pts), error handling 2 (nesting depth added 3). Most of this is not in the body itself: 6 of the 33 points are its own statements and the rest belongs to 6 function items inside it that branch (a function literal at line 53, a function literal at line 130, act, \u2026). The named helpers are already separate functions; the literals\u0027 work cannot be called, reviewed or tested from outside this body. To reduce it, move the named helpers out of the body to the enclosing scope and lift each literal\u0027s work into a named function there, so each is measured, reviewed and tested on its own, and reduce whichever one then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/settings/HistoryStorageSettings.tsx"},"region":{"startLine":9}}}],"partialFingerprints":{"codehealthFindingId/v1":"647ed87342e913aaaf33fb355ec13cd1f42f1149aa69a1938f0fecbcc4d31e6b"}},{"ruleId":"D2","level":"warning","message":{"text":"api.errorFromResponse (cognitive 33): api.errorFromResponse has cognitive complexity 33 (threshold 15). Drivers by points: if/else 12 (19 pts), boolean chains 9, ternaries 2 (4 pts), error handling 1 (nesting depth added 9). Of this number, 22 points are the body\u0027s own statements and 11 belong to 2 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/lib/api.ts"},"region":{"startLine":403}}}],"partialFingerprints":{"codehealthFindingId/v1":"ebb0f6372953eeb2d9c30b973a4c9e099925a2aa581d9ca577759623fd885367"}},{"ruleId":"D2","level":"warning","message":{"text":"options.buildPayoffRequest (cognitive 33): options.buildPayoffRequest has cognitive complexity 33 (threshold 15). Drivers by points: if/else 13 (17 pts), boolean chains 13, ternaries 2, loops 1 (nesting depth added 4). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/lib/options.ts"},"region":{"startLine":373}}}],"partialFingerprints":{"codehealthFindingId/v1":"81675d6316d89532e130efb9f9e8fe4b0ad3da4d5b6ccebe94dba7b4ab811d3a"}},{"ruleId":"D2","level":"warning","message":{"text":"agent.useAgentStore (cognitive 33): agent.useAgentStore has cognitive complexity 33 (threshold 15). Drivers by points: if/else 10 (12 pts), ternaries 11, boolean chains 9, loops 1 (nesting depth added 2). None of this is in the body itself: all 33 points belong to 19 function literals inside it that branch (lines 208, 141, 191, \u2026). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/stores/agent.ts"},"region":{"startLine":120}}}],"partialFingerprints":{"codehealthFindingId/v1":"ebdeca13a25eb661d094b87b1cdfd14447cde084a837ede38d6edb7cbdd4a607"}},{"ruleId":"D2","level":"warning","message":{"text":"fundamentals_loader._extract_concept_series (cognitive 32): fundamentals_loader._extract_concept_series has cognitive complexity 32 (threshold 15). Drivers by points: if/else 12 (22 pts), loops 3 (6 pts), ternaries 2 (3 pts), boolean chains 1 (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/fundamentals_loader.py"},"region":{"startLine":48}}}],"partialFingerprints":{"codehealthFindingId/v1":"c84e9d36d2c0d63d44a5f3ff42cd38960b8dcd9895d5e6a8aa34cb362d63540b"}},{"ruleId":"D2","level":"warning","message":{"text":"figures._numbers (cognitive 32): figures._numbers has cognitive complexity 32 (threshold 15). Drivers by points: if/else 7 (15 pts), boolean chains 9, ternaries 5 (6 pts), loops 2 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/grounding/figures.py"},"region":{"startLine":483}}}],"partialFingerprints":{"codehealthFindingId/v1":"d7641ef8b00cc84eec21e5ea92adba3ffa4285ce189a76e330879b6410ffdaaf"}},{"ruleId":"D2","level":"warning","message":{"text":"figures.table_rows (cognitive 32): figures.table_rows has cognitive complexity 32 (threshold 15). Drivers by points: if/else 9 (22 pts), boolean chains 5, loops 3 (5 pts) (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/grounding/figures.py"},"region":{"startLine":939}}}],"partialFingerprints":{"codehealthFindingId/v1":"b7c6cbe65658966f77c04ddff23bfde259c1d31c9d2fc1af282ad1aadf2c73bc"}},{"ruleId":"D2","level":"warning","message":{"text":"doc_reader_tool._read_pdf (cognitive 32): doc_reader_tool._read_pdf has cognitive complexity 32 (threshold 15). Drivers by points: if/else 13 (20 pts), ternaries 4 (7 pts), boolean chains 3, error handling 1, loops 1 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/doc_reader_tool.py"},"region":{"startLine":133}}}],"partialFingerprints":{"codehealthFindingId/v1":"6e9793b0d42756a1417aa1bd46724a5d88cf975ae9ef25d36b250d92b178f2dc"}},{"ruleId":"D2","level":"warning","message":{"text":"AddGoalEvidenceTool.execute (cognitive 32): AddGoalEvidenceTool.execute has cognitive complexity 32 (threshold 15). Drivers by points: boolean chains 25, if/else 4 (5 pts), error handling 2 (nesting depth added 1). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/goal_tool.py"},"region":{"startLine":491}}}],"partialFingerprints":{"codehealthFindingId/v1":"2ec49da0e98c39959885b532c23a4268e1adbf28a316dd2f96471dedd1aa2770"}},{"ruleId":"D2","level":"warning","message":{"text":"tap_forward.forward (cognitive 32): tap_forward.forward has cognitive complexity 32 (threshold 15). Drivers by points: ternaries 8 (14 pts), boolean chains 9, if/else 6 (8 pts), loops 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/tap_forward.py"},"region":{"startLine":105}}}],"partialFingerprints":{"codehealthFindingId/v1":"d46efdbede15b775b15c40374c43c8bb71e052aa34461cc2732eff567446584c"}},{"ruleId":"D2","level":"warning","message":{"text":"FactorResearchPanel.FactorResearchPanel (cognitive 32): FactorResearchPanel.FactorResearchPanel has cognitive complexity 32 (threshold 15). Drivers by points: boolean chains 13, ternaries 6 (11 pts), if/else 8 (nesting depth added 5). Most of this is not in the body itself: 9 of the 32 points are its own statements and the rest belongs to 9 function literals inside it that branch (lines 175, 113, 97, \u2026). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/charts/FactorResearchPanel.tsx"},"region":{"startLine":84}}}],"partialFingerprints":{"codehealthFindingId/v1":"f4f5dc2f363bbc1c13c9fab2d673e53d02a9d150caecf895c86fa0951e46025a"}},{"ruleId":"D2","level":"warning","message":{"text":"additive_conversion._plateau_spans (cognitive 31): additive_conversion._plateau_spans has cognitive complexity 31 (threshold 15). Drivers by points: if/else 7 (17 pts), loops 4 (6 pts), ternaries 2 (6 pts), boolean chains 2 (nesting depth added 16). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/additive_conversion.py"},"region":{"startLine":47}}}],"partialFingerprints":{"codehealthFindingId/v1":"4179c8c1fcac0bcf434845cd6a635c7974b9cee0aa3998ac3297f8668151ecd1"}},{"ruleId":"D2","level":"warning","message":{"text":"_legacy.cmd_run (cognitive 31): _legacy.cmd_run has cognitive complexity 31 (threshold 15). Drivers by points: if/else 17 (25 pts), boolean chains 3, ternaries 1 (2 pts), error handling 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":1519}}}],"partialFingerprints":{"codehealthFindingId/v1":"e4376a4a76dca8673e252ec9880a783a3a4514f287a045a1fb7c529a36263575"}},{"ruleId":"D2","level":"warning","message":{"text":"_legacy.cmd_dev (cognitive 31): _legacy.cmd_dev has cognitive complexity 31 (threshold 15). Drivers by points: error handling 7 (14 pts), if/else 7 (11 pts), boolean chains 2, loops 2, ternaries 2 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":6253}}}],"partialFingerprints":{"codehealthFindingId/v1":"efe8aac21600c0f14599bd09bf0a239c91158ac36a5921ca291e65a01748fa33"}},{"ruleId":"D2","level":"warning","message":{"text":"_EvidenceMixin._record_backtest_outputs (cognitive 31): _EvidenceMixin._record_backtest_outputs has cognitive complexity 31 (threshold 15). Drivers by points: if/else 8 (19 pts), boolean chains 7, loops 3 (5 pts) (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/grounding/evidence.py"},"region":{"startLine":1069}}}],"partialFingerprints":{"codehealthFindingId/v1":"eacfec28bbd12c969dab374a7eb2c0056acea94737ebbae8ba75b8751971d527"}},{"ruleId":"D2","level":"warning","message":{"text":"context_compact._fix_tool_pairs (cognitive 31): context_compact._fix_tool_pairs has cognitive complexity 31 (threshold 15). Drivers by points: if/else 8 (19 pts), loops 7 (10 pts), boolean chains 2 (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/agent/context_compact.py"},"region":{"startLine":394}}}],"partialFingerprints":{"codehealthFindingId/v1":"2eb885e4a766fc2b4cd29159477f1ca1b23a41047092d7041767bd08cfa4bd5c"}},{"ruleId":"D2","level":"warning","message":{"text":"PendingAction.validate_evidence (cognitive 31): PendingAction.validate_evidence has cognitive complexity 31 (threshold 15). Drivers by points: if/else 12 (17 pts), boolean chains 10, error handling 1 (2 pts), ternaries 1 (2 pts) (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/live/pending_action.py"},"region":{"startLine":161}}}],"partialFingerprints":{"codehealthFindingId/v1":"672111678cfa65a9f87df6757f685df60a2e8e895c078118cf8960af4cdd7593"}},{"ruleId":"D2","level":"warning","message":{"text":"claude_cli._query_claude_cli_models (cognitive 31): claude_cli._query_claude_cli_models has cognitive complexity 31 (threshold 15). Drivers by points: ternaries 4 (11 pts), if/else 5 (9 pts), boolean chains 6, error handling 2 (3 pts), loops 2 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/providers/claude_cli.py"},"region":{"startLine":733}}}],"partialFingerprints":{"codehealthFindingId/v1":"f9ccf200995f577f621c15bd1b099f3d2ec79b2d4505d4a6db63bad0ff896171"}},{"ruleId":"D2","level":"warning","message":{"text":"attribution.brinson_fachler (cognitive 31): attribution.brinson_fachler has cognitive complexity 31 (threshold 15). Drivers by points: if/else 11 (23 pts), loops 5 (7 pts), boolean chains 1 (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/attribution.py"},"region":{"startLine":209}}}],"partialFingerprints":{"codehealthFindingId/v1":"fa4bd2e5680a6ac808ac16a0387936fa19b58b0483307f042d6fbe8d86259496"}},{"ruleId":"D2","level":"warning","message":{"text":"neutralization.neutralize_factor (cognitive 31): neutralization.neutralize_factor has cognitive complexity 31 (threshold 15). Drivers by points: if/else 14 (20 pts), boolean chains 6, ternaries 3, loops 2 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/neutralization.py"},"region":{"startLine":204}}}],"partialFingerprints":{"codehealthFindingId/v1":"10ce5fd877698f6a5c5f0e48dc075d79d1703cada120f5761fe387f70235c2eb"}},{"ruleId":"D2","level":"warning","message":{"text":"sdk.place_order (cognitive 31): sdk.place_order has cognitive complexity 31 (threshold 15). Drivers by points: if/else 14 (17 pts), boolean chains 10, error handling 2, ternaries 2 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/binance/sdk.py"},"region":{"startLine":527}}}],"partialFingerprints":{"codehealthFindingId/v1":"b34513ca6fadd6bee8529e673fe527d391d860bffa505297c7b8049676a03696"}},{"ruleId":"D2","level":"warning","message":{"text":"local_plugins.parse_manifest (cognitive 31): local_plugins.parse_manifest has cognitive complexity 31 (threshold 15). Drivers by points: boolean chains 15, if/else 11 (13 pts), error handling 1, loops 1, ternaries 1 (nesting depth added 2). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/local_plugins.py"},"region":{"startLine":108}}}],"partialFingerprints":{"codehealthFindingId/v1":"a57a6ae9a27647a0559f5f72743fcef81c618c3a34b42c2e5172fc6bfb3bb437"}},{"ruleId":"D2","level":"warning","message":{"text":"check_i18n.main (cognitive 31): check_i18n.main has cognitive complexity 31 (threshold 15). Drivers by points: if/else 6 (14 pts), loops 8 (13 pts), boolean chains 4 (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"wiki/scripts/check_i18n.py"},"region":{"startLine":68}}}],"partialFingerprints":{"codehealthFindingId/v1":"cc04df2a92aa00d5ebc462759f1fc3a423b42a3d60ba981789b5ee3ebd74fa48"}},{"ruleId":"D2","level":"warning","message":{"text":"ConnectionCenter.ConnectionCenter (cognitive 31): ConnectionCenter.ConnectionCenter has cognitive complexity 31 (threshold 15). Drivers by points: ternaries 13 (18 pts), boolean chains 4, error handling 4, if/else 4, loops 1 (nesting depth added 5). Most of this is not in the body itself: 7 of the 31 points are its own statements and the rest belongs to 8 function items inside it that branch (remove, create, test, \u2026). The named helpers are already separate functions; the literals\u0027 work cannot be called, reviewed or tested from outside this body. To reduce it, move the named helpers out of the body to the enclosing scope and lift each literal\u0027s work into a named function there, so each is measured, reviewed and tested on its own, and reduce whichever one then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/portfolio/ConnectionCenter.tsx"},"region":{"startLine":21}}}],"partialFingerprints":{"codehealthFindingId/v1":"6ce24ed9e79c1f776b35a3262601769b5c6c49afb57d0a20f2cd0f4c3435adc0"}},{"ruleId":"D2","level":"warning","message":{"text":"Reports.Reports (cognitive 31): Reports.Reports has cognitive complexity 31 (threshold 15). Drivers by points: ternaries 12 (15 pts), boolean chains 10, if/else 5, error handling 1 (nesting depth added 3). Most of this is not in the body itself: 13 of the 31 points are its own statements and the rest belongs to 5 function items inside it that branch (a function literal at line 66, loadReports, a function literal at line 60, \u2026). The named helpers are already separate functions; the literals\u0027 work cannot be called, reviewed or tested from outside this body. To reduce it, move the named helpers out of the body to the enclosing scope and lift each literal\u0027s work into a named function there, so each is measured, reviewed and tested on its own, and reduce whichever one then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Reports.tsx"},"region":{"startLine":23}}}],"partialFingerprints":{"codehealthFindingId/v1":"6341c701fe7cb371681210a6bd84fdc10e29688a1facb995d359ce435a4343ae"}},{"ruleId":"D2","level":"warning","message":{"text":"_RunDashboard.render (cognitive 30): _RunDashboard.render has cognitive complexity 30 (threshold 15). Drivers by points: ternaries 14 (19 pts), if/else 6 (7 pts), boolean chains 2, loops 2 (nesting depth added 6). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":795}}}],"partialFingerprints":{"codehealthFindingId/v1":"f2580c386bdb1a6caeb9f6b1730a41357de8d9501a21b1f579dba51381386f18"}},{"ruleId":"D2","level":"warning","message":{"text":"_legacy.cmd_trace (cognitive 30): _legacy.cmd_trace has cognitive complexity 30 (threshold 15). Drivers by points: ternaries 7 (19 pts), if/else 4 (7 pts), boolean chains 3, loops 1 (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":2609}}}],"partialFingerprints":{"codehealthFindingId/v1":"41eb223c368f2fabb3c26c05992cfbe60ec145569965298a6eeccfe61259ef0a"}},{"ruleId":"D2","level":"warning","message":{"text":"store.handle_pairing_command (cognitive 30): store.handle_pairing_command has cognitive complexity 30 (threshold 15). Drivers by points: if/else 9 (18 pts), ternaries 5 (9 pts), loops 1 (2 pts), boolean chains 1 (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/pairing/store.py"},"region":{"startLine":233}}}],"partialFingerprints":{"codehealthFindingId/v1":"e922126504551c0aa6f943b959114ee0325e339cee402409cccbca11cbb00000"}},{"ruleId":"D2","level":"warning","message":{"text":"SignalChannel._sse_receive_loop (cognitive 30): SignalChannel._sse_receive_loop has cognitive complexity 30 (threshold 15). Drivers by points: if/else 8 (16 pts), error handling 3 (7 pts), ternaries 1 (4 pts), boolean chains 2, loops 1 (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/signal.py"},"region":{"startLine":609}}}],"partialFingerprints":{"codehealthFindingId/v1":"0bf9bbf4fc5c4e2bac834d4e8251e23685fe37e879001eca4f35d755eda1c5f3"}},{"ruleId":"D2","level":"warning","message":{"text":"SignalChannel._assemble_inbound_content (cognitive 30): SignalChannel._assemble_inbound_content has cognitive complexity 30 (threshold 15). Drivers by points: if/else 9 (18 pts), ternaries 2 (5 pts), error handling 1 (3 pts), boolean chains 2, loops 1 (2 pts) (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/signal.py"},"region":{"startLine":921}}}],"partialFingerprints":{"codehealthFindingId/v1":"3a6e9286a7440a9134fe0c51fe02d09aa440b4b6cd07ac39a2958ad7cd080541"}},{"ruleId":"D2","level":"warning","message":{"text":"SignalChannel._should_respond_in_group (cognitive 30): SignalChannel._should_respond_in_group has cognitive complexity 30 (threshold 15). Drivers by points: if/else 10 (19 pts), loops 4 (6 pts), boolean chains 5 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/signal.py"},"region":{"startLine":1230}}}],"partialFingerprints":{"codehealthFindingId/v1":"1988b58c848c9e34170d863a81b555e36a496a02cc724063f951f2a42aca02ea"}},{"ruleId":"D2","level":"warning","message":{"text":"historical.describe_coverage (cognitive 30): historical.describe_coverage has cognitive complexity 30 (threshold 15). Drivers by points: if/else 8 (16 pts), boolean chains 5, ternaries 4 (5 pts), error handling 2 (4 pts) (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/data_gateway/historical.py"},"region":{"startLine":374}}}],"partialFingerprints":{"codehealthFindingId/v1":"e1ad266b31de292a37791fe6809a2b4845a2e58f8fe53dc48b7b0c2a9701edb6"}},{"ruleId":"D2","level":"warning","message":{"text":"crossvalidation.group_purged_kfold_splits (cognitive 30): crossvalidation.group_purged_kfold_splits has cognitive complexity 30 (threshold 15). Drivers by points: if/else 12 (19 pts), loops 4 (5 pts), ternaries 2 (4 pts), boolean chains 2 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/crossvalidation.py"},"region":{"startLine":292}}}],"partialFingerprints":{"codehealthFindingId/v1":"9e133a5384ca878a5676fb4c7d3babaa4e04d8cd2ad33435c555fae1e6ff3d4a"}},{"ruleId":"D2","level":"warning","message":{"text":"factormodel.factor_ic_analysis (cognitive 30): factormodel.factor_ic_analysis has cognitive complexity 30 (threshold 15). Drivers by points: if/else 10 (15 pts), ternaries 6 (11 pts), boolean chains 3, loops 1 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/factormodel.py"},"region":{"startLine":761}}}],"partialFingerprints":{"codehealthFindingId/v1":"00db8ed942a697e1d056ed8a47cb00d9c05336009f1fefea51ceec5d39726661"}},{"ruleId":"D2","level":"warning","message":{"text":"InstitutionalHoldingsTool._top_managers (cognitive 30): InstitutionalHoldingsTool._top_managers has cognitive complexity 30 (threshold 15). Drivers by points: if/else 5 (15 pts), boolean chains 8, loops 4 (7 pts) (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/institutional_holdings_tool.py"},"region":{"startLine":2160}}}],"partialFingerprints":{"codehealthFindingId/v1":"be92821ca9c6eab1e6711546d6f182380590e7a1811228bfd0ceff5351b3dfbf"}},{"ruleId":"D2","level":"warning","message":{"text":"schema._validate_node (cognitive 30): schema._validate_node has cognitive complexity 30 (threshold 15). Drivers by points: if/else 10 (16 pts), loops 4 (10 pts), boolean chains 4 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/paper_trade/schema.py"},"region":{"startLine":727}}}],"partialFingerprints":{"codehealthFindingId/v1":"5cb6206c5d7908ffdd98db98de5bbf1e8666eb6ae4f2f267610d117108c79703"}},{"ruleId":"D2","level":"warning","message":{"text":"report_audit_tool._report_value (cognitive 30): report_audit_tool._report_value has cognitive complexity 30 (threshold 15). Drivers by points: if/else 13 (22 pts), boolean chains 7, ternaries 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/report_audit_tool.py"},"region":{"startLine":64}}}],"partialFingerprints":{"codehealthFindingId/v1":"f525ffc930a08edab1230e21b49fafbe2ff94498832194d5be628b27dc4a5548"}},{"ruleId":"D2","level":"warning","message":{"text":"sdk.place_order (cognitive 30): sdk.place_order has cognitive complexity 30 (threshold 15). Drivers by points: if/else 12 (15 pts), error handling 6 (7 pts), boolean chains 5, ternaries 3 (nesting depth added 4). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/futu/sdk.py"},"region":{"startLine":769}}}],"partialFingerprints":{"codehealthFindingId/v1":"fbfbf9f066874aff23029c5f514a91d2233f41bb2f9f41016327328c9db6cbf2"}},{"ruleId":"D2","level":"warning","message":{"text":"correlation._fetch_price_series (cognitive 29): correlation._fetch_price_series has cognitive complexity 29 (threshold 15). Drivers by points: if/else 6 (15 pts), error handling 2 (6 pts), loops 2 (3 pts), ternaries 1 (3 pts), boolean chains 2 (nesting depth added 16). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/correlation.py"},"region":{"startLine":268}}}],"partialFingerprints":{"codehealthFindingId/v1":"afacefee79871fec1ed3ec22f251139f894d187ef680dcf5f0f476d0610fb3b6"}},{"ruleId":"D2","level":"warning","message":{"text":"ArgentinaEquityEngine.prepare_market_data (cognitive 29): ArgentinaEquityEngine.prepare_market_data has cognitive complexity 29 (threshold 15). Drivers by points: if/else 7 (15 pts), ternaries 4 (10 pts), loops 3, boolean chains 1 (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/engines/argentina_equity.py"},"region":{"startLine":469}}}],"partialFingerprints":{"codehealthFindingId/v1":"f165629aedd62d653e68b98d420c32310321410c2d254d47cdf273811b6a2d33"}},{"ruleId":"D2","level":"warning","message":{"text":"base._read_loader_cache_frame (cognitive 29): base._read_loader_cache_frame has cognitive complexity 29 (threshold 15). Drivers by points: if/else 12 (16 pts), boolean chains 8, error handling 3, loops 1 (2 pts) (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/base.py"},"region":{"startLine":741}}}],"partialFingerprints":{"codehealthFindingId/v1":"ac63ca8b332b9e0a66f1bb58a3c4b9ad48f9326367dc95c057069a2c7461df23"}},{"ruleId":"D2","level":"warning","message":{"text":"LongbridgeLoader.fetch (cognitive 29): LongbridgeLoader.fetch has cognitive complexity 29 (threshold 15). Drivers by points: if/else 12 (18 pts), error handling 4 (6 pts), loops 3 (4 pts), boolean chains 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/longbridge.py"},"region":{"startLine":256}}}],"partialFingerprints":{"codehealthFindingId/v1":"0d0dcf17837d71f50ea712837fcade775b185143bb272daef911e2e5de8204eb"}},{"ruleId":"D2","level":"warning","message":{"text":"_legacy._build_welcome_panel (cognitive 29): _legacy._build_welcome_panel has cognitive complexity 29 (threshold 15). Drivers by points: if/else 8, loops 4 (8 pts), ternaries 6 (8 pts), boolean chains 5 (nesting depth added 6). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":1704}}}],"partialFingerprints":{"codehealthFindingId/v1":"cae67e705114f8ebe9e3dbe6ca5eb46238c7785c80eeb42cdca7dcddb66199a1"}},{"ruleId":"D2","level":"warning","message":{"text":"runs_routes._iter_factor_series_files (cognitive 29): runs_routes._iter_factor_series_files has cognitive complexity 29 (threshold 15). Drivers by points: if/else 5 (14 pts), error handling 3 (8 pts), boolean chains 4, loops 2 (3 pts) (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/api/runs_routes.py"},"region":{"startLine":222}}}],"partialFingerprints":{"codehealthFindingId/v1":"e75035194b973aab5b0e77d28e8a371d3e7bc15e7207df5ef6d27511ceaa7e3d"}},{"ruleId":"D2","level":"warning","message":{"text":"MSTeamsChannel._handle_activity (cognitive 29): MSTeamsChannel._handle_activity has cognitive complexity 29 (threshold 15). Drivers by points: boolean chains 20, if/else 8 (9 pts) (nesting depth added 1). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/msteams.py"},"region":{"startLine":331}}}],"partialFingerprints":{"codehealthFindingId/v1":"0f18fd457713f9c4fd76a95e0ca6844993d313a01847b3d1436fde0b164b713e"}},{"ruleId":"D2","level":"warning","message":{"text":"SignalChannel._start_http_mode (cognitive 29): SignalChannel._start_http_mode has cognitive complexity 29 (threshold 15). Drivers by points: error handling 6 (14 pts), if/else 7 (14 pts), loops 1 (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/signal.py"},"region":{"startLine":474}}}],"partialFingerprints":{"codehealthFindingId/v1":"ff1fe0ec635ea1936bd3fb1ea9b34088620ddbf16ee1f5f02d4630a50b8dade7"}},{"ruleId":"D2","level":"warning","message":{"text":"SessionSearchIndex.reindex_from_store (cognitive 29): SessionSearchIndex.reindex_from_store has cognitive complexity 29 (threshold 15). Drivers by points: if/else 6 (15 pts), error handling 4 (9 pts), loops 2 (4 pts), boolean chains 1 (nesting depth added 16). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/session/search.py"},"region":{"startLine":393}}}],"partialFingerprints":{"codehealthFindingId/v1":"272fe789e153bdebe5f7b21d05d9d6b9dbd618eb444f2d751165f8f406e3c948"}},{"ruleId":"D2","level":"warning","message":{"text":"SignalEngine.generate (cognitive 29): SignalEngine.generate has cognitive complexity 29 (threshold 15). Drivers by points: if/else 5 (18 pts), loops 4 (10 pts), boolean chains 1 (nesting depth added 19). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/skills/elliott-wave/example_signal_engine.py"},"region":{"startLine":370}}}],"partialFingerprints":{"codehealthFindingId/v1":"70c923dae2aa1e5e20ce587d04dd18521ccbb520b59ce9378d1c69abeb7d8974"}},{"ruleId":"D2","level":"warning","message":{"text":"financial_statements_tool._fetch_yahoo_statement (cognitive 29): financial_statements_tool._fetch_yahoo_statement has cognitive complexity 29 (threshold 15). Drivers by points: if/else 8 (15 pts), loops 4 (8 pts), boolean chains 3, ternaries 1 (2 pts), error handling 1 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/financial_statements_tool.py"},"region":{"startLine":333}}}],"partialFingerprints":{"codehealthFindingId/v1":"c6a632980579676041b3240fa7decc2260117f02c42fb25c76b14e62dae9d8f6"}},{"ruleId":"D2","level":"warning","message":{"text":"OrderBookDepthTool.execute (cognitive 29): OrderBookDepthTool.execute has cognitive complexity 29 (threshold 15). Drivers by points: if/else 12 (13 pts), ternaries 6 (10 pts), boolean chains 4, error handling 1, loops 1 (nesting depth added 5). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/orderbook_depth_tool.py"},"region":{"startLine":348}}}],"partialFingerprints":{"codehealthFindingId/v1":"7502a887e305303c4bb445a133c01494d81c8b53706e81c2fce9b29fb770a754"}},{"ruleId":"D2","level":"warning","message":{"text":"trade_journal_tool._compute_profile (cognitive 29): trade_journal_tool._compute_profile has cognitive complexity 29 (threshold 15). Drivers by points: ternaries 13 (18 pts), if/else 5 (6 pts), loops 3 (4 pts), boolean chains 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/trade_journal_tool.py"},"region":{"startLine":237}}}],"partialFingerprints":{"codehealthFindingId/v1":"ba1222d0cc35875a299016fbccc3d5f6b1b39b7fb86df9a8bad5993b3083e5d3"}},{"ruleId":"D2","level":"warning","message":{"text":"sdk.place_order (cognitive 29): sdk.place_order has cognitive complexity 29 (threshold 15). Drivers by points: if/else 15 (20 pts), boolean chains 6, ternaries 3 (nesting depth added 5). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/upbit/sdk.py"},"region":{"startLine":376}}}],"partialFingerprints":{"codehealthFindingId/v1":"3ffd6f59067d5853f159df85828d79e766d054414cf41dc5f1972fe61883fbf3"}},{"ruleId":"D2","level":"warning","message":{"text":"StrategyResearchDashboard.StrategyResearchDashboard (cognitive 29): StrategyResearchDashboard.StrategyResearchDashboard has cognitive complexity 29 (threshold 15). Drivers by points: boolean chains 19, if/else 5, ternaries 4 (5 pts) (nesting depth added 1). Most of this is not in the body itself: 12 of the 29 points are its own statements and the rest belongs to 9 function literals inside it that branch (lines 140, 129, 195, \u2026). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/charts/StrategyResearchDashboard.tsx"},"region":{"startLine":122}}}],"partialFingerprints":{"codehealthFindingId/v1":"b81c96566b51f17ce7986c192e538ed072065d382efad9b88bcb4e28478a280d"}},{"ruleId":"D2","level":"warning","message":{"text":"_RunDashboard._render_progress_row (cognitive 28): _RunDashboard._render_progress_row has cognitive complexity 28 (threshold 15). Drivers by points: if/else 10 (13 pts), boolean chains 12, error handling 1 (3 pts) (nesting depth added 5). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":719}}}],"partialFingerprints":{"codehealthFindingId/v1":"848f05483d5792c0f82a114c711582eac3d89bb3823d4e6de6b21810a764cf69"}},{"ruleId":"D2","level":"warning","message":{"text":"_legacy._dispatch_connector (cognitive 28): _legacy._dispatch_connector has cognitive complexity 28 (threshold 15). Drivers by points: if/else 23 (24 pts), ternaries 2 (4 pts) (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":5327}}}],"partialFingerprints":{"codehealthFindingId/v1":"ed31dcd101e6062c3056751bfb741af8d4cc8e420f2e905e26a696b5692be938"}},{"ruleId":"D2","level":"warning","message":{"text":"_EvidenceMixin._ingest_document_text (cognitive 28): _EvidenceMixin._ingest_document_text has cognitive complexity 28 (threshold 15). Drivers by points: if/else 11 (18 pts), error handling 2 (5 pts), boolean chains 3, loops 1, ternaries 1 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/grounding/evidence.py"},"region":{"startLine":1660}}}],"partialFingerprints":{"codehealthFindingId/v1":"df5f5f7a57c71b3f6f75e64a62567247ebf7ae7b15138b1f6b461806b13e625e"}},{"ruleId":"D2","level":"warning","message":{"text":"measurements.validate_measurements (cognitive 28): measurements.validate_measurements has cognitive complexity 28 (threshold 15). Drivers by points: if/else 10 (20 pts), boolean chains 7, loops 1 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/harness/measurements.py"},"region":{"startLine":16}}}],"partialFingerprints":{"codehealthFindingId/v1":"5d7ea7655ebd4ef4fb8b075bc701c684dc43d8ed266e01ece4a5d2a82f6d5dfa"}},{"ruleId":"D2","level":"warning","message":{"text":"attribution_core._attribution_equal_weight_returns (cognitive 28): attribution_core._attribution_equal_weight_returns has cognitive complexity 28 (threshold 15). Drivers by points: if/else 9 (18 pts), loops 4 (6 pts), boolean chains 4 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/api/attribution_core.py"},"region":{"startLine":279}}}],"partialFingerprints":{"codehealthFindingId/v1":"61108d8873a03ce719ee7e96048fd957bc42777cd99c82b0ae22d4169322e4ec"}},{"ruleId":"D2","level":"warning","message":{"text":"WeixinChannel._download_media_item (cognitive 28): WeixinChannel._download_media_item has cognitive complexity 28 (threshold 15). Drivers by points: if/else 11 (13 pts), boolean chains 10, error handling 3 (4 pts), loops 1 (nesting depth added 3). To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/weixin.py"},"region":{"startLine":831}}}],"partialFingerprints":{"codehealthFindingId/v1":"bf7e6b09f7220bc178e07b3c1b2a723265b19d2762eaec9b441d84eac0d27cfe"}},{"ruleId":"D2","level":"warning","message":{"text":"GoalStore._validate_completion_audit (cognitive 28): GoalStore._validate_completion_audit has cognitive complexity 28 (threshold 15). Drivers by points: if/else 9 (21 pts), boolean chains 4, loops 2 (3 pts) (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/goal/store.py"},"region":{"startLine":899}}}],"partialFingerprints":{"codehealthFindingId/v1":"6e7f9f7904cd6d5c6139c48a013b8b555a8b088d4260fd5ce6f305ada9302476"}},{"ruleId":"D2","level":"warning","message":{"text":"PersistentMemory.add (cognitive 28): PersistentMemory.add has cognitive complexity 28 (threshold 15). Drivers by points: if/else 13 (19 pts), error handling 2 (4 pts), boolean chains 3, ternaries 1 (2 pts) (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/memory/persistent.py"},"region":{"startLine":515}}}],"partialFingerprints":{"codehealthFindingId/v1":"f74a82e303dcca26f6b725389ef16135496650475d0e528b4d0289c9f38454a4"}},{"ruleId":"D2","level":"warning","message":{"text":"combination._walk_forward_weights (cognitive 28): combination._walk_forward_weights has cognitive complexity 28 (threshold 15). Drivers by points: if/else 9 (24 pts), loops 2 (3 pts), boolean chains 1 (nesting depth added 16). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/combination.py"},"region":{"startLine":207}}}],"partialFingerprints":{"codehealthFindingId/v1":"de24689eb5f2540a00e8c8dfb24a74a46f6a623f6944676dc080f425e7fb2c22"}},{"ruleId":"D2","level":"warning","message":{"text":"options.bs_greeks (cognitive 28): options.bs_greeks has cognitive complexity 28 (threshold 15). Drivers by points: ternaries 5 (15 pts), if/else 10 (13 pts) (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/options.py"},"region":{"startLine":268}}}],"partialFingerprints":{"codehealthFindingId/v1":"c4bd562131a0b5853ca4d916b169e0a0d602bcbdb8f9cccf1e6d71f8a376482a"}},{"ruleId":"D2","level":"warning","message":{"text":"SignalEngine.generate (cognitive 28): SignalEngine.generate has cognitive complexity 28 (threshold 15). Drivers by points: if/else 7 (19 pts), loops 4 (7 pts), boolean chains 2 (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/skills/fundamental-filter/example_signal_engine.py"},"region":{"startLine":75}}}],"partialFingerprints":{"codehealthFindingId/v1":"2f6607b29d5d46b27b43dee75e758e200399810025431786d7f4a7066665ee8a"}},{"ruleId":"D2","level":"warning","message":{"text":"StrategyDiscoveryFacade.get_strategy_evidence (cognitive 28): StrategyDiscoveryFacade.get_strategy_evidence has cognitive complexity 28 (threshold 15). Drivers by points: if/else 11 (15 pts), error handling 4 (6 pts), ternaries 2 (4 pts), boolean chains 2, loops 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/strategy_discovery/facade.py"},"region":{"startLine":606}}}],"partialFingerprints":{"codehealthFindingId/v1":"96ba209d185eb25a8c9214041246f334ce55b60364e55acdf41664241fa2efed"}},{"ruleId":"D2","level":"warning","message":{"text":"presets.inspect_preset (cognitive 28): presets.inspect_preset has cognitive complexity 28 (threshold 15). Drivers by points: if/else 7 (12 pts), loops 9 (12 pts), error handling 2 (3 pts), boolean chains 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/swarm/presets.py"},"region":{"startLine":171}}}],"partialFingerprints":{"codehealthFindingId/v1":"e6e6d981c439475d15f0fc0f60c585aacf57e42929b139078a27055cc86c0316"}},{"ruleId":"D2","level":"warning","message":{"text":"SwarmRuntime._execute_run (cognitive 28): SwarmRuntime._execute_run has cognitive complexity 28 (threshold 15). Drivers by points: if/else 8 (15 pts), loops 4 (6 pts), boolean chains 3, ternaries 3, error handling 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/swarm/runtime.py"},"region":{"startLine":520}}}],"partialFingerprints":{"codehealthFindingId/v1":"8577af84ee87f9244af43c93cb098153af1ffcefedb6601f3faeeb734c9a3a09"}},{"ruleId":"D2","level":"warning","message":{"text":"BackgroundManager.check (cognitive 28): BackgroundManager.check has cognitive complexity 28 (threshold 15). Drivers by points: if/else 11 (23 pts), ternaries 2 (3 pts), boolean chains 2 (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/background_tools.py"},"region":{"startLine":461}}}],"partialFingerprints":{"codehealthFindingId/v1":"5f53ad54880dd5c3b6ece010992f62a7f80851f41c9d875f39b2d21329481234"}},{"ruleId":"D2","level":"warning","message":{"text":"GildataFundNavTool.execute (cognitive 28): GildataFundNavTool.execute has cognitive complexity 28 (threshold 15). Drivers by points: if/else 10 (14 pts), error handling 3 (6 pts), boolean chains 4, loops 3, ternaries 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/fund_nav_tool.py"},"region":{"startLine":140}}}],"partialFingerprints":{"codehealthFindingId/v1":"2fa11d85883c5fe26994178412862a940bd0cd78256581068c756ce5a7386ffb"}},{"ruleId":"D2","level":"warning","message":{"text":"PredictionMarketTool.execute (cognitive 28): PredictionMarketTool.execute has cognitive complexity 28 (threshold 15). Drivers by points: if/else 13 (17 pts), boolean chains 5, ternaries 3 (4 pts), error handling 1 (2 pts) (nesting depth added 6). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/prediction_market_tool.py"},"region":{"startLine":1120}}}],"partialFingerprints":{"codehealthFindingId/v1":"eca9ae78189077fc9ca466a46ed438cf5a7abb86846ea8786b2c7cb215b8fdf3"}},{"ruleId":"D2","level":"warning","message":{"text":"SdmDecayScanTool.execute (cognitive 28): SdmDecayScanTool.execute has cognitive complexity 28 (threshold 15). Drivers by points: if/else 11 (22 pts), loops 2 (3 pts), boolean chains 2, error handling 1 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/sdm_decay_scan_tool.py"},"region":{"startLine":64}}}],"partialFingerprints":{"codehealthFindingId/v1":"69eb8c5496db033a98803e06b1912c04b39da6d19c066b3f058407cd15c461ae"}},{"ruleId":"D2","level":"warning","message":{"text":"service._close_etoro_position (cognitive 28): service._close_etoro_position has cognitive complexity 28 (threshold 15). Drivers by points: if/else 11 (15 pts), error handling 4 (6 pts), boolean chains 5, ternaries 1 (2 pts) (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/service.py"},"region":{"startLine":883}}}],"partialFingerprints":{"codehealthFindingId/v1":"8a02efe54eee73c48374f41ce4841258b8e7a6dbab568cb7544c6376241a24f8"}},{"ruleId":"D2","level":"warning","message":{"text":"FutuLoader.fetch (cognitive 27): FutuLoader.fetch has cognitive complexity 27 (threshold 15). Drivers by points: if/else 10 (19 pts), loops 3 (4 pts), boolean chains 3, error handling 1 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/futu.py"},"region":{"startLine":150}}}],"partialFingerprints":{"codehealthFindingId/v1":"d5f0010d8d89241fa6e56c68569a75091afa448d1d9c5dc41035de2ce4b6a39f"}},{"ruleId":"D2","level":"warning","message":{"text":"_PolicyMixin._operands_read_as_points (cognitive 27): _PolicyMixin._operands_read_as_points has cognitive complexity 27 (threshold 15). Drivers by points: if/else 10 (17 pts), boolean chains 7, loops 2 (3 pts) (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/grounding/policies.py"},"region":{"startLine":2132}}}],"partialFingerprints":{"codehealthFindingId/v1":"4f3edf0649721e68381856b1497a1fda16f562e7f46e9f83cb040af37687775b"}},{"ruleId":"D2","level":"warning","message":{"text":"write_targets.record_written_target (cognitive 27): write_targets.record_written_target has cognitive complexity 27 (threshold 15). Drivers by points: if/else 9 (12 pts), error handling 6 (7 pts), boolean chains 6, ternaries 1 (2 pts) (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/agent/write_targets.py"},"region":{"startLine":29}}}],"partialFingerprints":{"codehealthFindingId/v1":"6198ea1003684474ae65a40b5d65c70a04461bbf121720ac63c3dc82db023dd6"}},{"ruleId":"D2","level":"warning","message":{"text":"SlackChannel.send (cognitive 27): SlackChannel.send has cognitive complexity 27 (threshold 15). Drivers by points: boolean chains 11, if/else 4 (6 pts), ternaries 3 (4 pts), error handling 2 (3 pts), loops 2 (3 pts) (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/slack.py"},"region":{"startLine":174}}}],"partialFingerprints":{"codehealthFindingId/v1":"ec31cbff9060c3f4d3c7c50ab78923b305bd01d84c2b273a690f86f5818b3179"}},{"ruleId":"D2","level":"warning","message":{"text":"history_source.fetch_chunk (cognitive 27): history_source.fetch_chunk has cognitive complexity 27 (threshold 15). Drivers by points: if/else 13 (18 pts), loops 3 (5 pts), boolean chains 4 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/data_gateway/history_source.py"},"region":{"startLine":69}}}],"partialFingerprints":{"codehealthFindingId/v1":"0aa1f068c3325e08932eb407323e271fd8f86fb1cbe517f694dd1d6c9b5d4b23"}},{"ruleId":"D2","level":"warning","message":{"text":"commit._profile_fits_ceilings (cognitive 27): commit._profile_fits_ceilings has cognitive complexity 27 (threshold 15). Drivers by points: if/else 9 (23 pts), boolean chains 3, loops 1 (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/live/mandate/commit.py"},"region":{"startLine":348}}}],"partialFingerprints":{"codehealthFindingId/v1":"3a0b64b9d34954ca0f92814fe99097e6462c7cf58b8d2d27e862a46fa1927ca2"}},{"ruleId":"D2","level":"warning","message":{"text":"PortfolioService._combine_holdings (cognitive 27): PortfolioService._combine_holdings has cognitive complexity 27 (threshold 15). Drivers by points: if/else 6 (11 pts), boolean chains 6, ternaries 3 (6 pts), loops 3 (4 pts) (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/portfolio/service.py"},"region":{"startLine":899}}}],"partialFingerprints":{"codehealthFindingId/v1":"4ca2d887fa444f6434e72b19ed3c66d4acd1f679203eeb4acc47f4f859450841"}},{"ruleId":"D2","level":"warning","message":{"text":"service.catalog (cognitive 27): service.catalog has cognitive complexity 27 (threshold 15). Drivers by points: if/else 5 (13 pts), ternaries 2 (6 pts), boolean chains 3, error handling 1 (3 pts), loops 1 (2 pts) (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/research_lab/service.py"},"region":{"startLine":32}}}],"partialFingerprints":{"codehealthFindingId/v1":"568abfb1cc3a0cdc07f6ccb9aeab630ce4abccf6dcf0dca65d3b51e466966385"}},{"ruleId":"D2","level":"warning","message":{"text":"data.fetch_market_data (cognitive 27): data.fetch_market_data has cognitive complexity 27 (threshold 15). Drivers by points: if/else 14 (19 pts), boolean chains 5, ternaries 2, loops 1 (nesting depth added 5). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/paper_trade/data.py"},"region":{"startLine":429}}}],"partialFingerprints":{"codehealthFindingId/v1":"6171a0c1452df3eae92652373384acae1d69c4dc61cd50f7a7ed8925047b3b04"}},{"ruleId":"D2","level":"warning","message":{"text":"data_5m._split_session_days (cognitive 27): data_5m._split_session_days has cognitive complexity 27 (threshold 15). Drivers by points: if/else 12 (24 pts), boolean chains 2, loops 1 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/paper_trade/data_5m.py"},"region":{"startLine":326}}}],"partialFingerprints":{"codehealthFindingId/v1":"5450f37609b54dcdd1b6679173745daea0ee5368767acf177233fcba21a0753c"}},{"ruleId":"D2","level":"warning","message":{"text":"pdf_report._rtl_lines (cognitive 27): pdf_report._rtl_lines has cognitive complexity 27 (threshold 15). Drivers by points: if/else 8 (17 pts), loops 3 (5 pts), ternaries 2 (3 pts), boolean chains 2 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/pdf_report.py"},"region":{"startLine":62}}}],"partialFingerprints":{"codehealthFindingId/v1":"613bcc1902d9006f5cffe33bd2cfaedc3f21d31fd4607fbfcf7543e88b5e1230"}},{"ruleId":"D2","level":"warning","message":{"text":"trade_journal_parsers.parse_generic (cognitive 27): trade_journal_parsers.parse_generic has cognitive complexity 27 (threshold 15). Drivers by points: ternaries 6 (12 pts), if/else 6 (10 pts), boolean chains 3, loops 2 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/trade_journal_parsers.py"},"region":{"startLine":571}}}],"partialFingerprints":{"codehealthFindingId/v1":"3e906154fdd88ee9ca4de558d812e372f402da7c0fb238d404fa755e10d4b204"}},{"ruleId":"D2","level":"warning","message":{"text":"usdm._join_positions (cognitive 27): usdm._join_positions has cognitive complexity 27 (threshold 15). Drivers by points: if/else 8 (16 pts), boolean chains 4, ternaries 2 (4 pts), loops 2 (3 pts) (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/binance/usdm.py"},"region":{"startLine":144}}}],"partialFingerprints":{"codehealthFindingId/v1":"22396288d3fba16f1c34e0a8984b7bd074ecf9ca63f486fe5c590cba58cf7faa"}},{"ruleId":"D2","level":"warning","message":{"text":"trading.edit_position_stops (cognitive 27): trading.edit_position_stops has cognitive complexity 27 (threshold 15). Drivers by points: if/else 11 (13 pts), boolean chains 7, error handling 3 (5 pts), ternaries 1 (2 pts) (nesting depth added 5). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/etoro/trading.py"},"region":{"startLine":218}}}],"partialFingerprints":{"codehealthFindingId/v1":"8d834f7eefa1fd4fba9938f9acc7d9c0e5cd07a83213b9cffade7f79322214f7"}},{"ruleId":"D2","level":"warning","message":{"text":"sdk._request (cognitive 27): sdk._request has cognitive complexity 27 (threshold 15). Drivers by points: if/else 7 (16 pts), boolean chains 4, error handling 2 (4 pts), ternaries 1 (2 pts), loops 1 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/kis/sdk.py"},"region":{"startLine":814}}}],"partialFingerprints":{"codehealthFindingId/v1":"3db80e6b11eaa54063c2294c482395c65de78a90876a7a390b56b6b4abb44a95"}},{"ruleId":"D2","level":"warning","message":{"text":"ui_services.infer_indicator_periods (cognitive 27): ui_services.infer_indicator_periods has cognitive complexity 27 (threshold 15). Drivers by points: if/else 5 (11 pts), boolean chains 8, error handling 2 (6 pts), loops 2 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/ui_services.py"},"region":{"startLine":151}}}],"partialFingerprints":{"codehealthFindingId/v1":"d6dd9287f574de729cd5e79c9abf0a3d096b07058cc5f9d8c86e7cc4bce20484"}},{"ruleId":"D2","level":"warning","message":{"text":"build_alpha_library.main (cognitive 27): build_alpha_library.main has cognitive complexity 27 (threshold 15). Drivers by points: if/else 9 (17 pts), boolean chains 7, loops 2 (3 pts) (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"wiki/scripts/build_alpha_library.py"},"region":{"startLine":483}}}],"partialFingerprints":{"codehealthFindingId/v1":"84f01a38f82ef5712d056897cfae776f655051076161cf7f22b588b4b5c2c017"}},{"ruleId":"D2","level":"warning","message":{"text":"options.volatilitySurfaceIssue (cognitive 27): options.volatilitySurfaceIssue has cognitive complexity 27 (threshold 15). Drivers by points: if/else 12 (19 pts), loops 4 (5 pts), boolean chains 3 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/lib/options.ts"},"region":{"startLine":292}}}],"partialFingerprints":{"codehealthFindingId/v1":"fe4ffac2298b10e7a89bdce0cfaa86cc42bad53b65e4e7638ba13733d6f4d7ab"}},{"ruleId":"D2","level":"warning","message":{"text":"RunDetail.RunCardTab (cognitive 27): RunDetail.RunCardTab has cognitive complexity 27 (threshold 15). Drivers by points: boolean chains 14, ternaries 9 (13 pts) (nesting depth added 4). Of this number, 17 points are the body\u0027s own statements and 10 belong to 2 function literals inside it that branch. To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/RunDetail.tsx"},"region":{"startLine":477}}}],"partialFingerprints":{"codehealthFindingId/v1":"085308524813c8f7ecb8ba2cb3e0b86f063e26e32bd5d95ece11dc9f9808e7e1"}},{"ruleId":"D2","level":"warning","message":{"text":"argentina_equity.byma_cash_ledger (cognitive 26): argentina_equity.byma_cash_ledger has cognitive complexity 26 (threshold 15). Drivers by points: ternaries 8 (16 pts), if/else 3 (7 pts), boolean chains 2, loops 1 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/engines/argentina_equity.py"},"region":{"startLine":691}}}],"partialFingerprints":{"codehealthFindingId/v1":"1b86a078f5a648c7257ca154aaefac3481ccbfbc1b7268d40164b6c6ec50f9e7"}},{"ruleId":"D2","level":"warning","message":{"text":"DataLoader._fetch_minutes (cognitive 26): DataLoader._fetch_minutes has cognitive complexity 26 (threshold 15). Drivers by points: if/else 5 (10 pts), ternaries 3 (9 pts), loops 2 (3 pts), boolean chains 2, error handling 1 (2 pts) (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/tushare.py"},"region":{"startLine":333}}}],"partialFingerprints":{"codehealthFindingId/v1":"01428b2d7986e55ce7be86a9c9a393294f68ff9a3ab333059a0a1383215e60c2"}},{"ruleId":"D2","level":"warning","message":{"text":"yahoo_client._parse_chart (cognitive 26): yahoo_client._parse_chart has cognitive complexity 26 (threshold 15). Drivers by points: boolean chains 14, if/else 4 (7 pts), loops 2 (3 pts), ternaries 1 (2 pts) (nesting depth added 5). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/yahoo_client.py"},"region":{"startLine":221}}}],"partialFingerprints":{"codehealthFindingId/v1":"c026cfcaa0f1320f60f34e0a6c027940b2dcbaa4b1ba77d6b5f0414398a80a92"}},{"ruleId":"D2","level":"warning","message":{"text":"runner._module_level_forbidden_aliases (cognitive 26): runner._module_level_forbidden_aliases has cognitive complexity 26 (threshold 15). Drivers by points: if/else 3 (10 pts), loops 3 (7 pts), boolean chains 5, ternaries 1 (4 pts) (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/runner.py"},"region":{"startLine":727}}}],"partialFingerprints":{"codehealthFindingId/v1":"38e20802978591f5b2c6d83a34de41338be36be582d01751192fbc568e4e93e5"}},{"ruleId":"D2","level":"warning","message":{"text":"runner._select_market_engine (cognitive 26): runner._select_market_engine has cognitive complexity 26 (threshold 15). Drivers by points: if/else 19 (24 pts), boolean chains 1, ternaries 1 (nesting depth added 5). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/runner.py"},"region":{"startLine":1786}}}],"partialFingerprints":{"codehealthFindingId/v1":"474f2b8e3ce507f57067e27bca2741064c4543cc0eb7315a0efb8a073f340b54"}},{"ruleId":"D2","level":"warning","message":{"text":"_SwarmDashboard.build_table (cognitive 26): _SwarmDashboard.build_table has cognitive complexity 26 (threshold 15). Drivers by points: ternaries 8 (16 pts), if/else 7 (8 pts), boolean chains 1, loops 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":2237}}}],"partialFingerprints":{"codehealthFindingId/v1":"af99c1a4ba3fd5615482bd1fe789b23cd10044a5566021145edfff3fc4c978cf"}},{"ruleId":"D2","level":"warning","message":{"text":"context_compact._verification_ledger (cognitive 26): context_compact._verification_ledger has cognitive complexity 26 (threshold 15). Drivers by points: if/else 7 (15 pts), boolean chains 7, error handling 1 (2 pts), loops 2 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/agent/context_compact.py"},"region":{"startLine":114}}}],"partialFingerprints":{"codehealthFindingId/v1":"d6543a292f64c0d4ecd0e676570069853a8439e198398b2b94c52c6fb85de19d"}},{"ruleId":"D2","level":"warning","message":{"text":"context_compact._context_collapse (cognitive 26): context_compact._context_collapse has cognitive complexity 26 (threshold 15). Drivers by points: if/else 8 (16 pts), boolean chains 6, loops 3 (4 pts) (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/agent/context_compact.py"},"region":{"startLine":292}}}],"partialFingerprints":{"codehealthFindingId/v1":"62f7ff3bbe0675c7dbb9d17e6b3195226a6a561398671483b8a7bb76989f7b39"}},{"ruleId":"D2","level":"warning","message":{"text":"EmailChannel._extract_text_body (cognitive 26): EmailChannel._extract_text_body has cognitive complexity 26 (threshold 15). Drivers by points: if/else 8 (16 pts), boolean chains 4, error handling 2 (4 pts), loops 1 (2 pts) (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/email.py"},"region":{"startLine":919}}}],"partialFingerprints":{"codehealthFindingId/v1":"7ebace4e93999f5a2b97b4b92bfc978f2ea3c5840f2f6b3de00ca7a6238bc761"}},{"ruleId":"D2","level":"warning","message":{"text":"EmailChannel._parse_authentication_results_clauses (cognitive 26): EmailChannel._parse_authentication_results_clauses has cognitive complexity 26 (threshold 15). Drivers by points: if/else 8 (20 pts), loops 2 (3 pts), error handling 1 (2 pts), boolean chains 1 (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/email.py"},"region":{"startLine":1037}}}],"partialFingerprints":{"codehealthFindingId/v1":"64faa87f9ee62899197e0e0bb83c6c990d027a06d34742c38f122a9ecb938963"}},{"ruleId":"D2","level":"warning","message":{"text":"SSEEventMapper.map (cognitive 26): SSEEventMapper.map has cognitive complexity 26 (threshold 15). Drivers by points: ternaries 7 (14 pts), if/else 9, boolean chains 2, error handling 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/openbb_bridge/event_mapper.py"},"region":{"startLine":50}}}],"partialFingerprints":{"codehealthFindingId/v1":"d2b90f03b3256bca0f2f1bc7e8ad786aef2622bc4595b2262e22a3213a7b2409"}},{"ruleId":"D2","level":"warning","message":{"text":"_ShortPremium._run (cognitive 26): _ShortPremium._run has cognitive complexity 26 (threshold 15). Drivers by points: if/else 7 (15 pts), boolean chains 6, ternaries 1 (4 pts), loops 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/skills/options-strategy/example_signal_engine.py"},"region":{"startLine":123}}}],"partialFingerprints":{"codehealthFindingId/v1":"21f5a339be6398d329d1350a5223f4bf4d27deb33737f13c69d8a37a3347d052"}},{"ruleId":"D2","level":"warning","message":{"text":"goal_tool._trace_fields_from_runtime (cognitive 26): goal_tool._trace_fields_from_runtime has cognitive complexity 26 (threshold 15). Drivers by points: if/else 6 (10 pts), boolean chains 9, error handling 2 (7 pts) (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/goal_tool.py"},"region":{"startLine":72}}}],"partialFingerprints":{"codehealthFindingId/v1":"655197c16870ba1bb61ab44ba1e480947ab9575d349e5e03920350adc20f630f"}},{"ruleId":"D2","level":"warning","message":{"text":"institutional_holdings_tool._resolve_chain_value (cognitive 26): institutional_holdings_tool._resolve_chain_value has cognitive complexity 26 (threshold 15). Drivers by points: if/else 9 (14 pts), boolean chains 9, ternaries 2, loops 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/institutional_holdings_tool.py"},"region":{"startLine":1432}}}],"partialFingerprints":{"codehealthFindingId/v1":"d3eb8fb24a53e1c655d957c9f92f313ed5e90dae8d6a4b0c3a69cd23c69c9ae8"}},{"ruleId":"D2","level":"warning","message":{"text":"data._fetch_cn_a (cognitive 26): data._fetch_cn_a has cognitive complexity 26 (threshold 15). Drivers by points: if/else 7 (10 pts), ternaries 5 (6 pts), boolean chains 4, error handling 1 (3 pts), loops 2 (3 pts) (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/paper_trade/data.py"},"region":{"startLine":647}}}],"partialFingerprints":{"codehealthFindingId/v1":"ec5dbf406c38d31b4b9265020e8448744dd07a9fe757cca37daaafc3a7104a31"}},{"ruleId":"D2","level":"warning","message":{"text":"research_papers_tool._extract_performance (cognitive 26): research_papers_tool._extract_performance has cognitive complexity 26 (threshold 15). Drivers by points: if/else 6 (20 pts), loops 3 (6 pts) (nesting depth added 17). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/research_papers_tool.py"},"region":{"startLine":741}}}],"partialFingerprints":{"codehealthFindingId/v1":"dc4b478f7cb3d4b12606a199beab046766b2c6fa7509c9776fc61b68b4a28a6d"}},{"ruleId":"D2","level":"warning","message":{"text":"RunDetail.TradesTab (cognitive 26): RunDetail.TradesTab has cognitive complexity 26 (threshold 15). Drivers by points: boolean chains 17, ternaries 7 (8 pts), if/else 1 (nesting depth added 1). Most of this is not in the body itself: 10 of the 26 points are its own statements and the rest belongs to 4 function literals inside it that branch (lines 1112, 1020, 1053, \u2026). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/RunDetail.tsx"},"region":{"startLine":1001}}}],"partialFingerprints":{"codehealthFindingId/v1":"43abe953700ef532c46977d34537aaab58fe555c636df8ca81e52f1c4a474257"}},{"ruleId":"D2","level":"warning","message":{"text":"rebalance_mask.resolve_rebalance_dates (cognitive 25): rebalance_mask.resolve_rebalance_dates has cognitive complexity 25 (threshold 15). Drivers by points: if/else 10 (18 pts), loops 2 (4 pts), error handling 1 (3 pts) (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/rebalance_mask.py"},"region":{"startLine":47}}}],"partialFingerprints":{"codehealthFindingId/v1":"1a1ddc396cafb796a1b2471ca62327f8507cb6eeece23bd89c66c5f0cd7f95a5"}},{"ruleId":"D2","level":"warning","message":{"text":"validation._load_trades (cognitive 25): validation._load_trades has cognitive complexity 25 (threshold 15). Drivers by points: if/else 5 (12 pts), ternaries 3 (5 pts), error handling 1 (4 pts), boolean chains 3, loops 1 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/validation.py"},"region":{"startLine":444}}}],"partialFingerprints":{"codehealthFindingId/v1":"94635ba64f208fe72d7a0b546881f63a4aaf6b7c493755fa930e058b7e380728"}},{"ruleId":"D2","level":"warning","message":{"text":"context_compact._summary_chunks (cognitive 25): context_compact._summary_chunks has cognitive complexity 25 (threshold 15). Drivers by points: if/else 5 (12 pts), ternaries 2 (6 pts), loops 3 (5 pts), boolean chains 2 (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/agent/context_compact.py"},"region":{"startLine":37}}}],"partialFingerprints":{"codehealthFindingId/v1":"aa2dbfc58d4a8a35cb6487d041991908d4dc8d3a674f57173147f489003b7951"}},{"ruleId":"D2","level":"warning","message":{"text":"instrument_identity._infer_instrument_type (cognitive 25): instrument_identity._infer_instrument_type has cognitive complexity 25 (threshold 15). Drivers by points: if/else 16 (18 pts), boolean chains 5, ternaries 1 (2 pts) (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/agent/instrument_identity.py"},"region":{"startLine":345}}}],"partialFingerprints":{"codehealthFindingId/v1":"4a2de124da5a74df47c4926ceed6da1e42e296d9937abcddff7981980525728a"}},{"ruleId":"D2","level":"warning","message":{"text":"NapcatChannel._parse_segments (cognitive 25): NapcatChannel._parse_segments has cognitive complexity 25 (threshold 15). Drivers by points: if/else 7 (14 pts), ternaries 2 (4 pts), boolean chains 3, error handling 1 (3 pts), loops 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/napcat.py"},"region":{"startLine":309}}}],"partialFingerprints":{"codehealthFindingId/v1":"61ae87429124975a937426331cb918324665a2dece0e538fe41c6e5b4bf39c86"}},{"ruleId":"D2","level":"warning","message":{"text":"WebSocketChannel._save_envelope_media (cognitive 25): WebSocketChannel._save_envelope_media has cognitive complexity 25 (threshold 15). Drivers by points: if/else 8 (14 pts), error handling 2 (4 pts), ternaries 2 (4 pts), loops 2, boolean chains 1 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/websocket.py"},"region":{"startLine":604}}}],"partialFingerprints":{"codehealthFindingId/v1":"8a91ac5b0083ea71cb9dc1c917feb388499cd80dae0ada4b6ed9a282d1ebc0cd"}},{"ruleId":"D2","level":"warning","message":{"text":"PortfolioStore.history (cognitive 25): PortfolioStore.history has cognitive complexity 25 (threshold 15). Drivers by points: if/else 5 (12 pts), boolean chains 6, ternaries 3 (4 pts), error handling 1 (2 pts), loops 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/portfolio/store.py"},"region":{"startLine":143}}}],"partialFingerprints":{"codehealthFindingId/v1":"473a2e2d29404bf78bc02a5dc7e982c39b366c066a7be82b68b43e1235e418f3"}},{"ruleId":"D2","level":"warning","message":{"text":"neutralization._select (cognitive 25): neutralization._select has cognitive complexity 25 (threshold 15). Drivers by points: if/else 10 (21 pts), loops 2 (3 pts), boolean chains 1 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/neutralization.py"},"region":{"startLine":143}}}],"partialFingerprints":{"codehealthFindingId/v1":"4a21a840b89586801088f95de4034cf56d795618aa29c799dad409c68493f6b8"}},{"ruleId":"D2","level":"warning","message":{"text":"execution.constructor_defaults (cognitive 25): execution.constructor_defaults has cognitive complexity 25 (threshold 15). Drivers by points: if/else 3 (10 pts), loops 3 (7 pts), error handling 1 (5 pts), boolean chains 3 (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/research_lab/execution.py"},"region":{"startLine":39}}}],"partialFingerprints":{"codehealthFindingId/v1":"8b89bfe670170aa9b233a1a46899a2f62a6d444a77a3b8af3fd75e86b7786900"}},{"ruleId":"D2","level":"warning","message":{"text":"SessionService._record_tool_trail_event (cognitive 25): SessionService._record_tool_trail_event has cognitive complexity 25 (threshold 15). Drivers by points: if/else 11 (14 pts), boolean chains 7, ternaries 3 (4 pts) (nesting depth added 4). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/session/service.py"},"region":{"startLine":732}}}],"partialFingerprints":{"codehealthFindingId/v1":"1cdf72f93c03e07d8d5cfe6ff954e50698d25c9c32f9b37b03b465d77be0973a"}},{"ruleId":"D2","level":"warning","message":{"text":"checkpoint.restore (cognitive 25): checkpoint.restore has cognitive complexity 25 (threshold 15). Drivers by points: if/else 6 (10 pts), boolean chains 9, loops 3 (5 pts), error handling 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/swarm/checkpoint.py"},"region":{"startLine":40}}}],"partialFingerprints":{"codehealthFindingId/v1":"50bae1ce8a312f6b4741053c666b694024841ad271073486abfb2a9b5b1d5e90"}},{"ruleId":"D2","level":"warning","message":{"text":"alpha_bench_tool._load_csi300_panel (cognitive 25): alpha_bench_tool._load_csi300_panel has cognitive complexity 25 (threshold 15). Drivers by points: if/else 9 (12 pts), boolean chains 4, error handling 3 (4 pts), loops 2 (3 pts), ternaries 1 (2 pts) (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/alpha_bench_tool.py"},"region":{"startLine":316}}}],"partialFingerprints":{"codehealthFindingId/v1":"64a0af1d0e8af1723f9c6cfd0fdcc3338f452717905c0a696a26aeae7aacf008"}},{"ruleId":"D2","level":"warning","message":{"text":"EtfHoldingsTool.execute (cognitive 25): EtfHoldingsTool.execute has cognitive complexity 25 (threshold 15). Drivers by points: if/else 8 (11 pts), boolean chains 7, ternaries 4 (6 pts), error handling 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/etf_holdings_tool.py"},"region":{"startLine":1808}}}],"partialFingerprints":{"codehealthFindingId/v1":"22392ec8d4ed3d952e2fbff21765ade7d4d104a7374d80fddbeb2f958e05ab85"}},{"ruleId":"D2","level":"warning","message":{"text":"financial_rigor_tool.verify_valuation (cognitive 25): financial_rigor_tool.verify_valuation has cognitive complexity 25 (threshold 15). Drivers by points: if/else 13 (24 pts), boolean chains 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/financial_rigor_tool.py"},"region":{"startLine":192}}}],"partialFingerprints":{"codehealthFindingId/v1":"b8018581a1cc7ac6cf74e0e14c6b24cceb7e0be7d433fb3b1987726fab37ee6b"}},{"ruleId":"D2","level":"warning","message":{"text":"FredMacroTool.execute (cognitive 25): FredMacroTool.execute has cognitive complexity 25 (threshold 15). Drivers by points: if/else 10 (15 pts), boolean chains 4, ternaries 2 (4 pts), error handling 1, loops 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/fred_macro_tool.py"},"region":{"startLine":116}}}],"partialFingerprints":{"codehealthFindingId/v1":"4e393068ff65958926b5d28c7281c872417d1bf39e39e76c6efbf8b2ae4c0eac"}},{"ruleId":"D2","level":"warning","message":{"text":"report_audit_tool.render_verdict (cognitive 25): report_audit_tool.render_verdict has cognitive complexity 25 (threshold 15). Drivers by points: if/else 10 (18 pts), ternaries 2 (4 pts), boolean chains 2, loops 1 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/report_audit_tool.py"},"region":{"startLine":348}}}],"partialFingerprints":{"codehealthFindingId/v1":"d3d7eb56c302d415335248db1a0e6c99360a0c57e14287ddeeeba4faf65ec326"}},{"ruleId":"D2","level":"warning","message":{"text":"symbol_search_tool._canonical_crypto_pair (cognitive 25): symbol_search_tool._canonical_crypto_pair has cognitive complexity 25 (threshold 15). Drivers by points: if/else 7 (17 pts), boolean chains 6, loops 1 (2 pts) (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/symbol_search_tool.py"},"region":{"startLine":453}}}],"partialFingerprints":{"codehealthFindingId/v1":"c91318ef4e8b525b0bd948c1a3b58eaa260f2b3b3393476bc6e5ba605892036f"}},{"ruleId":"D2","level":"warning","message":{"text":"EtoroClient.request (cognitive 25): EtoroClient.request has cognitive complexity 25 (threshold 15). Drivers by points: if/else 7 (12 pts), boolean chains 4, error handling 2 (4 pts), ternaries 2 (4 pts), loops 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/etoro/client.py"},"region":{"startLine":280}}}],"partialFingerprints":{"codehealthFindingId/v1":"e1758ed081714d1e945773782ae8c0c5b0059293568f3a7c886b2673e3f32864"}},{"ruleId":"D2","level":"warning","message":{"text":"instruments.resolve_instrument_id (cognitive 25): instruments.resolve_instrument_id has cognitive complexity 25 (threshold 15). Drivers by points: if/else 9 (18 pts), loops 3 (5 pts), boolean chains 2 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/etoro/instruments.py"},"region":{"startLine":295}}}],"partialFingerprints":{"codehealthFindingId/v1":"bdb8542f78b17c6aa31f6c063422132e1324c5ac31ad7cc91455599d9f2743d3"}},{"ruleId":"D2","level":"warning","message":{"text":"sdk._extract_positions (cognitive 25): sdk._extract_positions has cognitive complexity 25 (threshold 15). Drivers by points: if/else 8 (23 pts), loops 1 (2 pts) (nesting depth added 16). To reduce it, flatten the nesting: this score is depth rather than breadth \u2014 most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language\u0027s equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/etoro/sdk.py"},"region":{"startLine":318}}}],"partialFingerprints":{"codehealthFindingId/v1":"210551ed8f051ca018f5a5ef21c28eaa34163fc2a3275060fe18f9e6b8a8b34d"}},{"ruleId":"D2","level":"warning","message":{"text":"VolatilitySurfaceGrid.VolatilitySurfaceGrid (cognitive 25): VolatilitySurfaceGrid.VolatilitySurfaceGrid has cognitive complexity 25 (threshold 15). Drivers by points: ternaries 9 (12 pts), boolean chains 7, if/else 4 (5 pts), error handling 1 (nesting depth added 4). Most of this is not in the body itself: 8 of the 25 points are its own statements and the rest belongs to 4 function items inside it that branch (compute, cellStyle, a function literal at line 46, \u2026). The named helpers are already separate functions; the literals\u0027 work cannot be called, reviewed or tested from outside this body. To reduce it, move the named helpers out of the body to the enclosing scope and lift each literal\u0027s work into a named function there, so each is measured, reviewed and tested on its own, and reduce whichever one then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/options/VolatilitySurfaceGrid.tsx"},"region":{"startLine":25}}}],"partialFingerprints":{"codehealthFindingId/v1":"f46bf0584acf03a4655ac3aa2c840e82a52c49c3153d766fb5de352bdcac0c97"}},{"ruleId":"D2","level":"warning","message":{"text":"AlphaZoo.DetailView (cognitive 25): AlphaZoo.DetailView has cognitive complexity 25 (threshold 15). Drivers by points: boolean chains 12, ternaries 6 (8 pts), if/else 5 (nesting depth added 2). Of this number, 21 points are the body\u0027s own statements and 4 belong to 3 function literals inside it that branch. To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/AlphaZoo.tsx"},"region":{"startLine":457}}}],"partialFingerprints":{"codehealthFindingId/v1":"9833960459a08486f8bbb439fa8b5de94f268803dd0440813f3c555821527898"}},{"ruleId":"D2","level":"warning","message":{"text":"evidence._metric_kind_for_path (cognitive 24): evidence._metric_kind_for_path has cognitive complexity 24 (threshold 15). Drivers by points: if/else 7 (13 pts), loops 4 (5 pts), boolean chains 3, ternaries 1 (3 pts) (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/grounding/evidence.py"},"region":{"startLine":618}}}],"partialFingerprints":{"codehealthFindingId/v1":"2bdd84fa98243bfbac381e7d933d195fa39092979e176392ba4de08e4ef18532"}},{"ruleId":"D2","level":"warning","message":{"text":"assertions._tool_result_join_verdict (cognitive 24): assertions._tool_result_join_verdict has cognitive complexity 24 (threshold 15). Drivers by points: if/else 12 (17 pts), ternaries 2 (3 pts), boolean chains 2, loops 2 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/harness/assertions.py"},"region":{"startLine":735}}}],"partialFingerprints":{"codehealthFindingId/v1":"6015e42158e2ff288d70fd95b1b7f562a21b03855da619f608d6e648fe64ab2f"}},{"ruleId":"D2","level":"warning","message":{"text":"AttemptProgress.poll (cognitive 24): AttemptProgress.poll has cognitive complexity 24 (threshold 15). Drivers by points: if/else 8 (18 pts), boolean chains 5, loops 1 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/attempt_progress.py"},"region":{"startLine":36}}}],"partialFingerprints":{"codehealthFindingId/v1":"a88f9660bdcfdada25421b8a2bf545398169f7d2ecc80f16dcc708a01afe7aaa"}},{"ruleId":"D2","level":"warning","message":{"text":"FeishuChannel._format_tool_hint_lines (cognitive 24): FeishuChannel._format_tool_hint_lines has cognitive complexity 24 (threshold 15). Drivers by points: if/else 9 (18 pts), ternaries 1 (3 pts), boolean chains 2, loops 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/feishu.py"},"region":{"startLine":2442}}}],"partialFingerprints":{"codehealthFindingId/v1":"5de69289548bc439c67fba5e26c2636141928924aad149006351b6f38114f0af"}},{"ruleId":"D2","level":"warning","message":{"text":"feishu._extract_post_content (cognitive 24): feishu._extract_post_content has cognitive complexity 24 (threshold 15). Drivers by points: if/else 8 (15 pts), boolean chains 7, loops 2 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/feishu.py"},"region":{"startLine":305}}}],"partialFingerprints":{"codehealthFindingId/v1":"de931a6bbce502718e99b17d0279ce482f7c28488ea4ce5607bfe33e578e7e2e"}},{"ruleId":"D2","level":"warning","message":{"text":"QQChannel._download_to_media_dir_chunked (cognitive 24): QQChannel._download_to_media_dir_chunked has cognitive complexity 24 (threshold 15). Drivers by points: if/else 14 (18 pts), boolean chains 4, error handling 1, loops 1 (nesting depth added 4). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/qq.py"},"region":{"startLine":660}}}],"partialFingerprints":{"codehealthFindingId/v1":"0e9f9532fbfd3328aca0b44ed52ed7e1bffa7c63602c9f8d55657654a8cd9757"}},{"ruleId":"D2","level":"warning","message":{"text":"reads.read (cognitive 24): reads.read has cognitive complexity 24 (threshold 15). Drivers by points: if/else 10 (13 pts), error handling 3 (5 pts), ternaries 3 (4 pts), boolean chains 2 (nesting depth added 6). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/data_gateway/reads.py"},"region":{"startLine":50}}}],"partialFingerprints":{"codehealthFindingId/v1":"9b44bd7566e6459993cc3b7612142f12b25220542b7d987e6444ea2abde2ffd3"}},{"ruleId":"D2","level":"warning","message":{"text":"enforcement._check_universe_floors (cognitive 24): enforcement._check_universe_floors has cognitive complexity 24 (threshold 15). Drivers by points: ternaries 4 (12 pts), if/else 4 (6 pts), error handling 2 (4 pts), boolean chains 2 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/live/enforcement.py"},"region":{"startLine":651}}}],"partialFingerprints":{"codehealthFindingId/v1":"bfce819df0524cf525d9884545f801eb1bebe5b393b8f903f02b5aa7c3b8be11"}},{"ruleId":"D2","level":"warning","message":{"text":"MemoryHierarchy.recover_extensionless_entries (cognitive 24): MemoryHierarchy.recover_extensionless_entries has cognitive complexity 24 (threshold 15). Drivers by points: if/else 5 (14 pts), error handling 2 (6 pts), loops 2 (3 pts), boolean chains 1 (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/memory/hierarchy.py"},"region":{"startLine":92}}}],"partialFingerprints":{"codehealthFindingId/v1":"95b038b58de8d459bec1578fb13d7cc1b14d0f30f6c3fd11420f9ca8b882a962"}},{"ruleId":"D2","level":"warning","message":{"text":"backtester._load_metrics (cognitive 24): backtester._load_metrics has cognitive complexity 24 (threshold 15). Drivers by points: if/else 8 (18 pts), error handling 2 (4 pts), loops 2 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/shadow_account/backtester.py"},"region":{"startLine":447}}}],"partialFingerprints":{"codehealthFindingId/v1":"aede2dd7f53de659d15244359d3046180f14bac78979256045d8247a3bb68c47"}},{"ruleId":"D2","level":"warning","message":{"text":"BackgroundManager._execute (cognitive 24): BackgroundManager._execute has cognitive complexity 24 (threshold 15). Drivers by points: if/else 7 (9 pts), ternaries 3 (7 pts), error handling 3 (5 pts), boolean chains 3 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/background_tools.py"},"region":{"startLine":296}}}],"partialFingerprints":{"codehealthFindingId/v1":"1c4080a8f47d8f33423bb459378113f160d42f2dcfb2a846c2db8a4a373a9afc"}},{"ruleId":"D2","level":"warning","message":{"text":"reconcile._issue_end_state (cognitive 24): reconcile._issue_end_state has cognitive complexity 24 (threshold 15). Drivers by points: if/else 10 (19 pts), loops 3, boolean chains 2 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/paper_trade/reconcile.py"},"region":{"startLine":286}}}],"partialFingerprints":{"codehealthFindingId/v1":"16b179d9c57876894756e50625fca40dd1b2ec1b8d7a571617d55c9907dd8bbc"}},{"ruleId":"D2","level":"warning","message":{"text":"ResearchLabTool.execute (cognitive 24): ResearchLabTool.execute has cognitive complexity 24 (threshold 15). Drivers by points: if/else 10 (18 pts), ternaries 3 (4 pts), boolean chains 1, error handling 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/research_lab_tool.py"},"region":{"startLine":36}}}],"partialFingerprints":{"codehealthFindingId/v1":"ec675ac3e8fc9afc4f68e33d3ec0eb0901b9bbb5a6c7f552a939eb7d5f4b0ad3"}},{"ruleId":"D2","level":"warning","message":{"text":"research_papers_tool._read_openalex (cognitive 24): research_papers_tool._read_openalex has cognitive complexity 24 (threshold 15). Drivers by points: if/else 8 (16 pts), loops 4 (6 pts), boolean chains 2 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/research_papers_tool.py"},"region":{"startLine":1404}}}],"partialFingerprints":{"codehealthFindingId/v1":"dce80ef990d19a51e4d531659f93016123a5b0c15ffac2fe477ecf65ab4b32cd"}},{"ruleId":"D2","level":"warning","message":{"text":"instruments.search_instruments (cognitive 24): instruments.search_instruments has cognitive complexity 24 (threshold 15). Drivers by points: if/else 12 (17 pts), boolean chains 5, ternaries 1 (2 pts) (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/etoro/instruments.py"},"region":{"startLine":157}}}],"partialFingerprints":{"codehealthFindingId/v1":"21c6e53e3359e32e91dea454a47eb83f42363b611614d109382481bd79161978"}},{"ruleId":"D2","level":"warning","message":{"text":"sdk.place_order (cognitive 24): sdk.place_order has cognitive complexity 24 (threshold 15). Drivers by points: boolean chains 9, if/else 9, ternaries 6. To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/kis/sdk.py"},"region":{"startLine":470}}}],"partialFingerprints":{"codehealthFindingId/v1":"8668c4d63c679b59b19c6283e602a23c39c2f3a6a8004fcf745f228dc05ce8ef"}},{"ruleId":"D2","level":"warning","message":{"text":"_client._usd_contract_value (cognitive 24): _client._usd_contract_value has cognitive complexity 24 (threshold 15). Drivers by points: ternaries 5 (10 pts), if/else 6 (8 pts), boolean chains 4, loops 2 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/mt5/_client.py"},"region":{"startLine":385}}}],"partialFingerprints":{"codehealthFindingId/v1":"bdb42af864d511e810def9c7fe24e002be52ef7cf03d205877f011767bbbde0e"}},{"ruleId":"D2","level":"warning","message":{"text":"backend-manager.resolveBackend (cognitive 24): backend-manager.resolveBackend has cognitive complexity 24 (threshold 15). Drivers by points: if/else 8 (17 pts), loops 4 (6 pts), boolean chains 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"desktop/electron/src/backend-manager.ts"},"region":{"startLine":310}}}],"partialFingerprints":{"codehealthFindingId/v1":"caee639a75cde6254b2e71a99f4d66174dfe08e18a7a466bee0af5ab0aa4742b"}},{"ruleId":"D2","level":"warning","message":{"text":"RunCompleteCard.RunCompleteCard (cognitive 24): RunCompleteCard.RunCompleteCard has cognitive complexity 24 (threshold 15). Drivers by points: boolean chains 10, if/else 9 (10 pts), ternaries 2 (3 pts), error handling 1 (nesting depth added 2). Most of this is not in the body itself: 10 of the 24 points are its own statements and the rest belongs to 6 function literals inside it that branch (lines 70, 35, 54, \u2026). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/chat/RunCompleteCard.tsx"},"region":{"startLine":25}}}],"partialFingerprints":{"codehealthFindingId/v1":"4a0ab326fc33532d2266f16e82942b9787a53e2c7793c9b9e102f30ff49c0086"}},{"ruleId":"D2","level":"warning","message":{"text":"ToolProgressIndicator.ToolRow (cognitive 24): ToolProgressIndicator.ToolRow has cognitive complexity 24 (threshold 15). Drivers by points: boolean chains 14, ternaries 4 (7 pts), if/else 1 (2 pts), loops 1 (nesting depth added 4). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/chat/ToolProgressIndicator.tsx"},"region":{"startLine":128}}}],"partialFingerprints":{"codehealthFindingId/v1":"0934cac37784efa7a129915b45c6764062727809bcd3f5d07078f9d1df885499"}},{"ruleId":"D2","level":"warning","message":{"text":"ModelPicker.ModelPicker (cognitive 24): ModelPicker.ModelPicker has cognitive complexity 24 (threshold 15). Drivers by points: if/else 8 (12 pts), ternaries 5 (8 pts), boolean chains 4 (nesting depth added 7). Most of this is not in the body itself: 4 of the 24 points are its own statements and the rest belongs to 5 function items inside it that branch (onKeyDown, a function literal at line 58, a function literal at line 28, \u2026). The named helpers are already separate functions; the literals\u0027 work cannot be called, reviewed or tested from outside this body. To reduce it, move the named helpers out of the body to the enclosing scope and lift each literal\u0027s work into a named function there, so each is measured, reviewed and tested on its own, and reduce whichever one then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/settings/ModelPicker.tsx"},"region":{"startLine":13}}}],"partialFingerprints":{"codehealthFindingId/v1":"1984467a6595ffa649e07a6065804d1dd0bb134ec61263bb1a242b4183652d32"}},{"ruleId":"D2","level":"warning","message":{"text":"SoftwareUpdateSettings.SoftwareUpdateSettings (cognitive 24): SoftwareUpdateSettings.SoftwareUpdateSettings has cognitive complexity 24 (threshold 15). Drivers by points: ternaries 7 (13 pts), boolean chains 9, error handling 2 (nesting depth added 6). Of this number, 21 points are the body\u0027s own statements and 3 belong to 2 function items inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/settings/SoftwareUpdateSettings.tsx"},"region":{"startLine":5}}}],"partialFingerprints":{"codehealthFindingId/v1":"64766984892ac8d26d3883f04ecd470b9085667807318725d1d546729d1d02b4"}},{"ruleId":"D2","level":"warning","message":{"text":"attachments.extractUploadedAttachments (cognitive 24): attachments.extractUploadedAttachments has cognitive complexity 24 (threshold 15). Drivers by points: if/else 6 (15 pts), ternaries 1 (4 pts), error handling 1 (3 pts), boolean chains 2 (nesting depth added 14). Of this number, 14 points are the body\u0027s own statements and 10 belong to one function literal inside it that branches. To reduce it, flatten the nesting: this score is depth rather than breadth \u2014 most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language\u0027s equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/lib/attachments.ts"},"region":{"startLine":24}}}],"partialFingerprints":{"codehealthFindingId/v1":"473c1ac61b0008aea0217a33b9a3923a503b5c53ab56d887c9c8809983066bc5"}},{"ruleId":"D2","level":"warning","message":{"text":"Correlation.CorrelationAnalysis (cognitive 24): Correlation.CorrelationAnalysis has cognitive complexity 24 (threshold 15). Drivers by points: boolean chains 12, ternaries 4 (6 pts), if/else 4 (5 pts), error handling 1 (nesting depth added 3). Of this number, 12 points are the body\u0027s own statements and 12 belong to 4 function items inside it that branch. To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Correlation.tsx"},"region":{"startLine":44}}}],"partialFingerprints":{"codehealthFindingId/v1":"017aad02b09babb5a1c73b69ed048c3383fbbb91354681844dce52b3055d6a8c"}},{"ruleId":"D2","level":"warning","message":{"text":"additive_conversion.convert_additive_to_multiplicative (cognitive 23): additive_conversion.convert_additive_to_multiplicative has cognitive complexity 23 (threshold 15). Drivers by points: if/else 12 (15 pts), boolean chains 5, loops 3 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/additive_conversion.py"},"region":{"startLine":103}}}],"partialFingerprints":{"codehealthFindingId/v1":"bdc04dade49459fb769e0d60aa67dfe2fad4f39c890e641ad99c6727a257656e"}},{"ruleId":"D2","level":"warning","message":{"text":"DataLoader.fetch (cognitive 23): DataLoader.fetch has cognitive complexity 23 (threshold 15). Drivers by points: if/else 7 (11 pts), loops 5 (8 pts), error handling 2 (3 pts), boolean chains 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/yfinance_loader.py"},"region":{"startLine":285}}}],"partialFingerprints":{"codehealthFindingId/v1":"bac5cb108af781800e93a6089643f6a35cf4682c0342a6e3eb5244af72f88773"}},{"ruleId":"D2","level":"warning","message":{"text":"rebalance_notes.compute_rebalance_notes (cognitive 23): rebalance_notes.compute_rebalance_notes has cognitive complexity 23 (threshold 15). Drivers by points: if/else 5 (12 pts), ternaries 5 (7 pts), boolean chains 3, loops 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/rebalance_notes.py"},"region":{"startLine":34}}}],"partialFingerprints":{"codehealthFindingId/v1":"0a63c6c93f2faeb770dd06fe7d5968b393cf8587760187874d6c7385a5ba9172"}},{"ruleId":"D2","level":"warning","message":{"text":"runner.main (cognitive 23): runner.main has cognitive complexity 23 (threshold 15). Drivers by points: if/else 15 (16 pts), error handling 6, boolean chains 1 (nesting depth added 1). To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/runner.py"},"region":{"startLine":1461}}}],"partialFingerprints":{"codehealthFindingId/v1":"11ebdb2fffa832f418529d937cf317b0827d84d14a43e98f8838204b4ffc441b"}},{"ruleId":"D2","level":"warning","message":{"text":"research_playbook.run (cognitive 23): research_playbook.run has cognitive complexity 23 (threshold 15). Drivers by points: if/else 15 (17 pts), boolean chains 2, error handling 1 (2 pts), ternaries 1 (2 pts) (nesting depth added 4). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/commands/research_playbook.py"},"region":{"startLine":398}}}],"partialFingerprints":{"codehealthFindingId/v1":"841efa9e8c977b470a081fce16bd430033a99798cb1fe3096477b6fbf1d4da03"}},{"ruleId":"D2","level":"warning","message":{"text":"figures._fenced_blocks (cognitive 23): figures._fenced_blocks has cognitive complexity 23 (threshold 15). Drivers by points: if/else 5 (11 pts), ternaries 2 (5 pts), loops 3 (4 pts), boolean chains 3 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/grounding/figures.py"},"region":{"startLine":681}}}],"partialFingerprints":{"codehealthFindingId/v1":"ef2ebbc643eecc7dbff8e8b3103bd6d8dc8ea3f22f7773057e2a4a9460440e90"}},{"ruleId":"D2","level":"warning","message":{"text":"mcp_server.run_swarm (cognitive 23): mcp_server.run_swarm has cognitive complexity 23 (threshold 15). Drivers by points: if/else 7 (13 pts), error handling 4 (7 pts), boolean chains 2, loops 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/mcp_server.py"},"region":{"startLine":1965}}}],"partialFingerprints":{"codehealthFindingId/v1":"387c1ab2368a8679477ba61eb7c2772f7c6e4ab8bf59c2410865af1bbe313315"}},{"ruleId":"D2","level":"warning","message":{"text":"runs_routes._build_positions_sector_map (cognitive 23): runs_routes._build_positions_sector_map has cognitive complexity 23 (threshold 15). Drivers by points: if/else 8 (12 pts), boolean chains 4, error handling 3 (4 pts), loops 2 (3 pts) (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/api/runs_routes.py"},"region":{"startLine":530}}}],"partialFingerprints":{"codehealthFindingId/v1":"f17f368af47e5cf4bb5f9916acf73e839a956a6363c51960b7e35d36a5071d81"}},{"ruleId":"D2","level":"warning","message":{"text":"MatrixChannel._handle_key_verification_event (cognitive 23): MatrixChannel._handle_key_verification_event has cognitive complexity 23 (threshold 15). Drivers by points: if/else 12 (17 pts), boolean chains 6 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/matrix.py"},"region":{"startLine":624}}}],"partialFingerprints":{"codehealthFindingId/v1":"3fe06ef85e47c9964e35b1286ff60f3f61bd3dd7eeb08fa1433b01e3c33b3a36"}},{"ruleId":"D2","level":"warning","message":{"text":"TelegramChannel._process_message_update (cognitive 23): TelegramChannel._process_message_update has cognitive complexity 23 (threshold 15). Drivers by points: if/else 13 (18 pts), ternaries 2 (3 pts), boolean chains 2 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/telegram.py"},"region":{"startLine":1462}}}],"partialFingerprints":{"codehealthFindingId/v1":"75d3e8663940a353b82611a8aa6ec990e40cade685a2eaba52f5b8eb413c26ca"}},{"ruleId":"D2","level":"warning","message":{"text":"WecomChannel.send (cognitive 23): WecomChannel.send has cognitive complexity 23 (threshold 15). Drivers by points: if/else 10 (15 pts), boolean chains 4, ternaries 1 (2 pts), error handling 1, loops 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/wecom.py"},"region":{"startLine":498}}}],"partialFingerprints":{"codehealthFindingId/v1":"138cdefc56f49ab4d2e995e3c01cdef706e2b0253ebb9da9261352d4d9082191"}},{"ruleId":"D2","level":"warning","message":{"text":"bar_artifact.export_bars_csv (cognitive 23): bar_artifact.export_bars_csv has cognitive complexity 23 (threshold 15). Drivers by points: if/else 8 (15 pts), loops 2 (3 pts), boolean chains 2, ternaries 1 (2 pts), error handling 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/data_gateway/bar_artifact.py"},"region":{"startLine":21}}}],"partialFingerprints":{"codehealthFindingId/v1":"ab93d025d14f0f831477b9e37bc5a37289deb6220c8b4c9a2739aa8d18c6a6f1"}},{"ruleId":"D2","level":"warning","message":{"text":"context.format_goal_continuation_prompt (cognitive 23): context.format_goal_continuation_prompt has cognitive complexity 23 (threshold 15). Drivers by points: boolean chains 14, if/else 3 (4 pts), ternaries 2 (3 pts), loops 2 (nesting depth added 2). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/goal/context.py"},"region":{"startLine":94}}}],"partialFingerprints":{"codehealthFindingId/v1":"490e520a34cf27e9be1a0def27b6722be195be86aabb57b75acd0fd7c491c1d5"}},{"ruleId":"D2","level":"warning","message":{"text":"MemoryHierarchy._parse_index_keywords (cognitive 23): MemoryHierarchy._parse_index_keywords has cognitive complexity 23 (threshold 15). Drivers by points: if/else 7 (18 pts), boolean chains 3, error handling 1, loops 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/memory/hierarchy.py"},"region":{"startLine":263}}}],"partialFingerprints":{"codehealthFindingId/v1":"0259cac35b081e69021d07bdfe6f4c355dff60330b7cfc1f123719053149cb9e"}},{"ruleId":"D2","level":"warning","message":{"text":"factormodel.factor_risk_decomposition (cognitive 23): factormodel.factor_risk_decomposition has cognitive complexity 23 (threshold 15). Drivers by points: if/else 16 (18 pts), ternaries 3, boolean chains 2 (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/factormodel.py"},"region":{"startLine":601}}}],"partialFingerprints":{"codehealthFindingId/v1":"4549372f8927419610c5a66434bb54140d0a617104e6af32152a1db81487e99b"}},{"ruleId":"D2","level":"warning","message":{"text":"risk.drawdown_distribution_analysis (cognitive 23): risk.drawdown_distribution_analysis has cognitive complexity 23 (threshold 15). Drivers by points: if/else 13 (20 pts), ternaries 1 (2 pts), loops 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/risk.py"},"region":{"startLine":327}}}],"partialFingerprints":{"codehealthFindingId/v1":"bcaf8105ed8236aa81075a2f47940d56b7471e07afc06d066c41ae642f31fef8"}},{"ruleId":"D2","level":"warning","message":{"text":"scanner._compare (cognitive 23): scanner._compare has cognitive complexity 23 (threshold 15). Drivers by points: if/else 15 (19 pts), boolean chains 4 (nesting depth added 4). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/shadow_account/scanner.py"},"region":{"startLine":236}}}],"partialFingerprints":{"codehealthFindingId/v1":"a1f437c6e7a788a47032eec29b8657ed70781a7f6acd4bfec881d5b3c1d8c689"}},{"ruleId":"D2","level":"warning","message":{"text":"adaptation_workflow.prepare_adaptation (cognitive 23): adaptation_workflow.prepare_adaptation has cognitive complexity 23 (threshold 15). Drivers by points: if/else 9 (10 pts), boolean chains 9, ternaries 2, error handling 1, loops 1 (nesting depth added 1). To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/strategy_discovery/adaptation_workflow.py"},"region":{"startLine":18}}}],"partialFingerprints":{"codehealthFindingId/v1":"0114e880c49a6de9c03f2b367307195325d0de2d2d57a96861535f4e5c3dafb0"}},{"ruleId":"D2","level":"warning","message":{"text":"path_utils.resolve_safe_path (cognitive 23): path_utils.resolve_safe_path has cognitive complexity 23 (threshold 15). Drivers by points: if/else 4 (11 pts), loops 3 (7 pts), error handling 2 (4 pts), ternaries 1 (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/path_utils.py"},"region":{"startLine":214}}}],"partialFingerprints":{"codehealthFindingId/v1":"9332d269a9e070dc90501a846171ded4583949b16b6b04080500d0e025953f3c"}},{"ruleId":"D2","level":"warning","message":{"text":"sdk.place_order (cognitive 23): sdk.place_order has cognitive complexity 23 (threshold 15). Drivers by points: if/else 13 (15 pts), boolean chains 4, error handling 3 (4 pts) (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/longbridge/sdk.py"},"region":{"startLine":482}}}],"partialFingerprints":{"codehealthFindingId/v1":"45dd21e96f02947b662399860eca87637d9a3b4dd6fcc5d6f9f42adc4f329bae"}},{"ruleId":"D2","level":"warning","message":{"text":"ConnectionCenter.AccountSelector (cognitive 23): ConnectionCenter.AccountSelector has cognitive complexity 23 (threshold 15). Drivers by points: ternaries 12 (17 pts), boolean chains 3, error handling 2, if/else 1 (nesting depth added 5). Of this number, 12 points are the body\u0027s own statements and 11 belong to 3 function items inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/portfolio/ConnectionCenter.tsx"},"region":{"startLine":261}}}],"partialFingerprints":{"codehealthFindingId/v1":"6526c685bde6913f83b917743526000f68d7eb28d4d7025a3ae7fffa0c173414"}},{"ruleId":"D2","level":"warning","message":{"text":"shannon.parseHoldings (cognitive 23): shannon.parseHoldings has cognitive complexity 23 (threshold 15). Drivers by points: if/else 7 (11 pts), boolean chains 7, ternaries 2 (4 pts), loops 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/lib/shannon.ts"},"region":{"startLine":37}}}],"partialFingerprints":{"codehealthFindingId/v1":"c5aac1f523ca5d1f1ab459727d7b74eb5c75b4ce193034662e6b1f2891ed79eb"}},{"ruleId":"D2","level":"warning","message":{"text":"tearsheet.computeMonthlyReturns (cognitive 23): tearsheet.computeMonthlyReturns has cognitive complexity 23 (threshold 15). Drivers by points: if/else 9 (15 pts), boolean chains 4, loops 2, ternaries 1 (2 pts) (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/lib/tearsheet.ts"},"region":{"startLine":106}}}],"partialFingerprints":{"codehealthFindingId/v1":"1c682467b6d9155f67e1eae91ad9c209695261bef5b0dd459ab866d50d13cfc8"}},{"ruleId":"D2","level":"warning","message":{"text":"AlphaZoo.BenchView (cognitive 23): AlphaZoo.BenchView has cognitive complexity 23 (threshold 15). Drivers by points: boolean chains 14, ternaries 8, if/else 1. Of this number, 13 points are the body\u0027s own statements and 10 belong to 3 function items inside it that branch. To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/AlphaZoo.tsx"},"region":{"startLine":641}}}],"partialFingerprints":{"codehealthFindingId/v1":"36da844b3368f54f68c12e3a3037b577ba1a55deaae0f8d3a891139db419d508"}},{"ruleId":"D2","level":"warning","message":{"text":"argentina_equity.reconcile_ratio_changes (cognitive 22): argentina_equity.reconcile_ratio_changes has cognitive complexity 22 (threshold 15). Drivers by points: if/else 7 (12 pts), boolean chains 4, loops 2 (4 pts), ternaries 1 (2 pts) (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/engines/argentina_equity.py"},"region":{"startLine":259}}}],"partialFingerprints":{"codehealthFindingId/v1":"0bcfc96c4a786194747f40dc9252b0f811639fe3285b2f6ce95eabfb44dfdd49"}},{"ruleId":"D2","level":"warning","message":{"text":"loader_health.probe (cognitive 22): loader_health.probe has cognitive complexity 22 (threshold 15). Drivers by points: if/else 7 (9 pts), error handling 3 (6 pts), boolean chains 3, ternaries 1 (3 pts), loops 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loader_health.py"},"region":{"startLine":192}}}],"partialFingerprints":{"codehealthFindingId/v1":"96df02b5a4694f962821ac589128bf1a02a2ae8d1aa28fa1d3f2e12c17a66e64"}},{"ruleId":"D2","level":"warning","message":{"text":"sec_edgar_client.get_company_facts (cognitive 22): sec_edgar_client.get_company_facts has cognitive complexity 22 (threshold 15). Drivers by points: if/else 3 (11 pts), loops 4 (10 pts), boolean chains 1 (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/sec_edgar_client.py"},"region":{"startLine":217}}}],"partialFingerprints":{"codehealthFindingId/v1":"0d994d1b92974f967cf070f6b33e71012941a7688f4c94c7a2f59b3e5c096e79"}},{"ruleId":"D2","level":"warning","message":{"text":"run_card._metric_citations (cognitive 22): run_card._metric_citations has cognitive complexity 22 (threshold 15). Drivers by points: if/else 9 (12 pts), boolean chains 5, error handling 2 (4 pts), loops 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/run_card.py"},"region":{"startLine":469}}}],"partialFingerprints":{"codehealthFindingId/v1":"1dd9015e01afccc719712d790c6f0e385cab63893fb6261a841e3b95d9a18db1"}},{"ruleId":"D2","level":"warning","message":{"text":"runner._scan_runtime_reachable (cognitive 22): runner._scan_runtime_reachable has cognitive complexity 22 (threshold 15). Drivers by points: if/else 8 (16 pts), boolean chains 3, loops 2 (3 pts) (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/runner.py"},"region":{"startLine":774}}}],"partialFingerprints":{"codehealthFindingId/v1":"420a4bed53ffd4338efafedc5e4f88591b84acf915c8b8f42656fec6c9446ea7"}},{"ruleId":"D2","level":"warning","message":{"text":"runner._ast_config_keys (cognitive 22): runner._ast_config_keys has cognitive complexity 22 (threshold 15). Drivers by points: if/else 4 (11 pts), boolean chains 10, loops 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/runner.py"},"region":{"startLine":1340}}}],"partialFingerprints":{"codehealthFindingId/v1":"46b4cd2876ce2da1df0cd4e516d111dfe7cfaf73194177078a4a92d806036a6d"}},{"ruleId":"D2","level":"warning","message":{"text":"_SwarmDashboard.handle_event (cognitive 22): _SwarmDashboard.handle_event has cognitive complexity 22 (threshold 15). Drivers by points: if/else 7 (11 pts), ternaries 5 (10 pts), boolean chains 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":2166}}}],"partialFingerprints":{"codehealthFindingId/v1":"c1989e120a0b6e2c175ab15c26ffd99e64848e58cce16de328b5ed561ee15ef9"}},{"ruleId":"D2","level":"warning","message":{"text":"_legacy.cmd_interactive (cognitive 22): _legacy.cmd_interactive has cognitive complexity 22 (threshold 15). Drivers by points: if/else 7 (13 pts), error handling 3 (7 pts), boolean chains 1, loops 1 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":2059}}}],"partialFingerprints":{"codehealthFindingId/v1":"53f0e3aa316126808c89c9492de4c1c50bebf3ac5cf5ad0248ba360fadb12333"}},{"ruleId":"D2","level":"warning","message":{"text":"_EvidenceMixin._ingest_analysis_result (cognitive 22): _EvidenceMixin._ingest_analysis_result has cognitive complexity 22 (threshold 15). Drivers by points: if/else 9 (14 pts), boolean chains 8 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/grounding/evidence.py"},"region":{"startLine":873}}}],"partialFingerprints":{"codehealthFindingId/v1":"089f8016a85aa0587b5247fa46c309bca545212b5d11b9c32899f8e89b70aecc"}},{"ruleId":"D2","level":"warning","message":{"text":"FiguresBlock.match (cognitive 22): FiguresBlock.match has cognitive complexity 22 (threshold 15). Drivers by points: if/else 7 (12 pts), boolean chains 5, loops 2 (3 pts), ternaries 2 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/grounding/figures.py"},"region":{"startLine":180}}}],"partialFingerprints":{"codehealthFindingId/v1":"c2554ee7641b312c0562c0d12a26d3ac39c6d2776c9fa5a9e59fa9306eef63c8"}},{"ruleId":"D2","level":"warning","message":{"text":"assertions._tool_verdicts (cognitive 22): assertions._tool_verdicts has cognitive complexity 22 (threshold 15). Drivers by points: if/else 9 (14 pts), ternaries 2 (4 pts), boolean chains 2, loops 2 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/harness/assertions.py"},"region":{"startLine":261}}}],"partialFingerprints":{"codehealthFindingId/v1":"bf90df87940eb9832cddfce14292b2ab1900250203c8719463092d66814aa2f7"}},{"ruleId":"D2","level":"warning","message":{"text":"channels_config_routes._apply_update (cognitive 22): channels_config_routes._apply_update has cognitive complexity 22 (threshold 15). Drivers by points: if/else 7 (8 pts), boolean chains 5, error handling 3 (5 pts), ternaries 1 (3 pts), loops 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/api/channels_config_routes.py"},"region":{"startLine":454}}}],"partialFingerprints":{"codehealthFindingId/v1":"21a21a210acdb66f56a855f0c15d3ba5fd1be94e6cdb552e718b1ca34e5169d6"}},{"ruleId":"D2","level":"warning","message":{"text":"settings_routes._build_llm_settings_response (cognitive 22): settings_routes._build_llm_settings_response has cognitive complexity 22 (threshold 15). Drivers by points: ternaries 6 (10 pts), error handling 3 (6 pts), if/else 3 (4 pts), boolean chains 2 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/api/settings_routes.py"},"region":{"startLine":203}}}],"partialFingerprints":{"codehealthFindingId/v1":"8356962f7dcf8def926cc92d5cc63f67a0438e9742d17a4268ab861eb43b8bff"}},{"ruleId":"D2","level":"warning","message":{"text":"cvm_companies.sync (cognitive 22): cvm_companies.sync has cognitive complexity 22 (threshold 15). Drivers by points: if/else 6 (15 pts), loops 4 (6 pts), boolean chains 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/br_data/cvm_companies.py"},"region":{"startLine":128}}}],"partialFingerprints":{"codehealthFindingId/v1":"b38fb1d8d38a4f316c5b6648c40aa205d9318ffc45ef3799675b613e6992108e"}},{"ruleId":"D2","level":"warning","message":{"text":"DiscordChannel.send_delta (cognitive 22): DiscordChannel.send_delta has cognitive complexity 22 (threshold 15). Drivers by points: if/else 10 (13 pts), boolean chains 6, error handling 2 (3 pts) (nesting depth added 4). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/discord.py"},"region":{"startLine":513}}}],"partialFingerprints":{"codehealthFindingId/v1":"b0edc2bf73524e1804f914bb138e5c62a2ceb3f473d995be124ca4c719245217"}},{"ruleId":"D2","level":"warning","message":{"text":"EmailChannel._check_authentication_results (cognitive 22): EmailChannel._check_authentication_results has cognitive complexity 22 (threshold 15). Drivers by points: if/else 6 (11 pts), boolean chains 7, ternaries 1 (3 pts), loops 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/email.py"},"region":{"startLine":1095}}}],"partialFingerprints":{"codehealthFindingId/v1":"28988aef519849fd81384737459bdfa5d4cb377f6bc5cc0c0d6bffefeca6b9c1"}},{"ruleId":"D2","level":"warning","message":{"text":"FeishuChannel._download_and_save_media (cognitive 22): FeishuChannel._download_and_save_media has cognitive complexity 22 (threshold 15). Drivers by points: if/else 10 (20 pts), boolean chains 2 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/feishu.py"},"region":{"startLine":1529}}}],"partialFingerprints":{"codehealthFindingId/v1":"ca6fe5d22b60b727621f54825da3c4d4c43bd7e896b7be879fc1054e1444d570"}},{"ruleId":"D2","level":"warning","message":{"text":"SignalChannel._check_inbound_policy (cognitive 22): SignalChannel._check_inbound_policy has cognitive complexity 22 (threshold 15). Drivers by points: if/else 9 (16 pts), boolean chains 6 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/signal.py"},"region":{"startLine":839}}}],"partialFingerprints":{"codehealthFindingId/v1":"bee89913caf1198fd6c52b9b677a500e6db60f111c9176f10d1c52e379cb6cbb"}},{"ruleId":"D2","level":"warning","message":{"text":"_EnvBase._load_from_env (cognitive 22): _EnvBase._load_from_env has cognitive complexity 22 (threshold 15). Drivers by points: error handling 2 (8 pts), if/else 4 (8 pts), boolean chains 5, loops 1 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/config/env_schema.py"},"region":{"startLine":116}}}],"partialFingerprints":{"codehealthFindingId/v1":"d9c7208b74280fbb2aeb114316f8bcf6c85d6b47f7fff9a713ca93fac7282629"}},{"ruleId":"D2","level":"warning","message":{"text":"history_router.inventory (cognitive 22): history_router.inventory has cognitive complexity 22 (threshold 15). Drivers by points: if/else 8 (17 pts), boolean chains 2, ternaries 1 (2 pts), loops 1 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/data_gateway/history_router.py"},"region":{"startLine":33}}}],"partialFingerprints":{"codehealthFindingId/v1":"04d51270e0293a31231e186b7e4e0385d4c292c4f249cc01f85db405e1bb7380"}},{"ruleId":"D2","level":"warning","message":{"text":"HistoryStore.read (cognitive 22): HistoryStore.read has cognitive complexity 22 (threshold 15). Drivers by points: if/else 7 (14 pts), boolean chains 3, loops 2 (3 pts), ternaries 2 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/data_gateway/history_store.py"},"region":{"startLine":720}}}],"partialFingerprints":{"codehealthFindingId/v1":"c931601a0aecda1e731d0cc827016d2e0b332c1a168bd2be689f096fc25106df"}},{"ruleId":"D2","level":"warning","message":{"text":"enforcement.check_mandate (cognitive 22): enforcement.check_mandate has cognitive complexity 22 (threshold 15). Drivers by points: if/else 15 (16 pts), boolean chains 5, ternaries 1 (nesting depth added 1). To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/live/enforcement.py"},"region":{"startLine":476}}}],"partialFingerprints":{"codehealthFindingId/v1":"b96107cf04b8a39a585de43b1bb27d69ac0aaf941b52b3dbc0b3dbf35ae79aa0"}},{"ruleId":"D2","level":"warning","message":{"text":"normalization.account_total_usd (cognitive 22): normalization.account_total_usd has cognitive complexity 22 (threshold 15). Drivers by points: if/else 5 (9 pts), loops 4 (6 pts), boolean chains 5, ternaries 2 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/portfolio/normalization.py"},"region":{"startLine":248}}}],"partialFingerprints":{"codehealthFindingId/v1":"b87a93524d2107e3c96a42543ca954d7e639077d3261b75c643a0a61feb21f6c"}},{"ruleId":"D2","level":"warning","message":{"text":"rebalance.propose_rebalance (cognitive 22): rebalance.propose_rebalance has cognitive complexity 22 (threshold 15). Drivers by points: if/else 9 (12 pts), boolean chains 5, loops 3, error handling 1 (2 pts) (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/portfolio/rebalance.py"},"region":{"startLine":13}}}],"partialFingerprints":{"codehealthFindingId/v1":"ff42c7f686bda69ea4f05ec8bf0d384ffe0dc2e854016c1148f84a4fe5446874"}},{"ruleId":"D2","level":"warning","message":{"text":"llm._build_anthropic (cognitive 22): llm._build_anthropic has cognitive complexity 22 (threshold 15). Drivers by points: ternaries 6 (10 pts), if/else 3 (5 pts), boolean chains 4, loops 1 (2 pts), error handling 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/providers/llm.py"},"region":{"startLine":1232}}}],"partialFingerprints":{"codehealthFindingId/v1":"9d57c5edd88e3db0416e933fee0dcf0b21cc5dcc7513b5e95a2914c515f10fef"}},{"ruleId":"D2","level":"warning","message":{"text":"execution.freeze_run (cognitive 22): execution.freeze_run has cognitive complexity 22 (threshold 15). Drivers by points: if/else 10 (15 pts), boolean chains 5, loops 2 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/research_lab/execution.py"},"region":{"startLine":62}}}],"partialFingerprints":{"codehealthFindingId/v1":"9956bc3dfac3cb9d7dc7fd5867f1d2a68393210789f995ff659c5b385987c459"}},{"ruleId":"D2","level":"warning","message":{"text":"sec_filings_example.recent_filings (cognitive 22): sec_filings_example.recent_filings has cognitive complexity 22 (threshold 15). Drivers by points: boolean chains 8, if/else 3 (6 pts), ternaries 3 (6 pts), error handling 1, loops 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/skills/sec-edgar/scripts/sec_filings_example.py"},"region":{"startLine":47}}}],"partialFingerprints":{"codehealthFindingId/v1":"59630a50e10a0c6cc9a2195525c2a020eb4f90f78ff4219b7242ae83e483a31a"}},{"ruleId":"D2","level":"warning","message":{"text":"backtest_tool.run_backtest (cognitive 22): backtest_tool.run_backtest has cognitive complexity 22 (threshold 15). Drivers by points: if/else 11 (14 pts), ternaries 4 (5 pts), error handling 3 (nesting depth added 4). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/backtest_tool.py"},"region":{"startLine":193}}}],"partialFingerprints":{"codehealthFindingId/v1":"fbbfefa81de3217d198bf618779d320ca853be041b824b7162ecb6e9383baaf3"}},{"ruleId":"D2","level":"warning","message":{"text":"GetFundamentalsTool.execute (cognitive 22): GetFundamentalsTool.execute has cognitive complexity 22 (threshold 15). Drivers by points: if/else 12 (13 pts), boolean chains 7, error handling 1, loops 1 (nesting depth added 1). To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/get_fundamentals_tool.py"},"region":{"startLine":128}}}],"partialFingerprints":{"codehealthFindingId/v1":"ffddb5bb0d1f153e8ff3c181024ea3f371a04c57a37840e218a4f6d3129a8a6c"}},{"ruleId":"D2","level":"warning","message":{"text":"OptionsPayoffTool._execute_single (cognitive 22): OptionsPayoffTool._execute_single has cognitive complexity 22 (threshold 15). Drivers by points: ternaries 10, boolean chains 5, if/else 3 (5 pts), error handling 2 (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/options_payoff_tool.py"},"region":{"startLine":203}}}],"partialFingerprints":{"codehealthFindingId/v1":"470410d847a19fd6a50c7cbf97dd1e253f07af6d2d0d982994a41b70ee1cd411"}},{"ruleId":"D2","level":"warning","message":{"text":"engine.run_day_loop (cognitive 22): engine.run_day_loop has cognitive complexity 22 (threshold 15). Drivers by points: if/else 9 (14 pts), loops 3 (5 pts), ternaries 1 (2 pts), boolean chains 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/paper_trade/engine.py"},"region":{"startLine":636}}}],"partialFingerprints":{"codehealthFindingId/v1":"e07d1fd20772d4f5bc39d24f9090beae37e62372fcbe22eb7295e07a69e08d3e"}},{"ruleId":"D2","level":"warning","message":{"text":"trade_journal_parsers._infer_market_from_symbol (cognitive 22): trade_journal_parsers._infer_market_from_symbol has cognitive complexity 22 (threshold 15). Drivers by points: if/else 11 (17 pts), boolean chains 4, loops 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/trade_journal_parsers.py"},"region":{"startLine":694}}}],"partialFingerprints":{"codehealthFindingId/v1":"235ebb64fd838cf1f0fea0dc28ea9e443ad62ce1f40a6f4a466d19ae807fc49d"}},{"ruleId":"D2","level":"warning","message":{"text":"SwarmStatusCard.SwarmStatusCard (cognitive 22): SwarmStatusCard.SwarmStatusCard has cognitive complexity 22 (threshold 15). Drivers by points: boolean chains 11, if/else 4 (5 pts), error handling 4, ternaries 2 (nesting depth added 1). Of this number, 11 points are the body\u0027s own statements and 11 belong to 4 function items inside it that branch. To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/chat/SwarmStatusCard.tsx"},"region":{"startLine":182}}}],"partialFingerprints":{"codehealthFindingId/v1":"3266f3d1faaf26069af31a6ba02f0415d4c273d891deb55b415600d30066db5d"}},{"ruleId":"D2","level":"warning","message":{"text":"Compare.EquityChartOverlay (cognitive 22): Compare.EquityChartOverlay has cognitive complexity 22 (threshold 15). Drivers by points: boolean chains 8, if/else 7 (8 pts), loops 3, ternaries 2 (3 pts) (nesting depth added 2). Most of this is not in the body itself: 2 of the 22 points are its own statements and the rest belongs to 5 function literals inside it that branch (lines 124, 162, 142, \u2026). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Compare.tsx"},"region":{"startLine":120}}}],"partialFingerprints":{"codehealthFindingId/v1":"417bef272adb8e4247e6f4714ad0a4dae98bf21cffcf497fa2141cbb11d4b0c6"}},{"ruleId":"D2","level":"warning","message":{"text":"Portfolio.AccountCard (cognitive 22): Portfolio.AccountCard has cognitive complexity 22 (threshold 15). Drivers by points: ternaries 12 (17 pts), boolean chains 4, if/else 1 (nesting depth added 5). Of this number, 20 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Portfolio.tsx"},"region":{"startLine":547}}}],"partialFingerprints":{"codehealthFindingId/v1":"4a7d59264699da41d98190f1a6f1fb8a1b04bb4d697b4661996f3d41e7bc8bfa"}},{"ruleId":"D2","level":"warning","message":{"text":"Settings.Settings::submitDataSources (cognitive 22): Settings.Settings::submitDataSources has cognitive complexity 22 (threshold 15). Drivers by points: ternaries 7 (10 pts), boolean chains 8, if/else 3, error handling 1 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition. This shape REPEATS in the file: 2 other methods here (Settings.Settings, Settings.Settings::submit) have the same decision points, in the same order, at the same nesting depths \u2014 so this is one pattern written 3 times rather than 3 independent problems. Splitting this body alone leaves the other 2 exactly as they are. Where these are variations on one operation, the change that clears all 3 is the shared one: lift the common shape into a single routine the variants call, parameterised by whatever genuinely differs between them, and keep in each method only the part that is not shared."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Settings.tsx"},"region":{"startLine":270}}}],"partialFingerprints":{"codehealthFindingId/v1":"eb983776975ef8c0b384d9696b0b34bfd096d8a99958661d4f544e79249591ff"}},{"ruleId":"D2","level":"warning","message":{"text":"correlation._rolling_correlation_matrix (cognitive 21): correlation._rolling_correlation_matrix has cognitive complexity 21 (threshold 15). Drivers by points: if/else 8 (13 pts), loops 4 (5 pts), ternaries 1 (3 pts) (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/correlation.py"},"region":{"startLine":176}}}],"partialFingerprints":{"codehealthFindingId/v1":"2e7799817c2e63dbd7574673650c9379b93b6fbd117219671a3fb86c83b2dac1"}},{"ruleId":"D2","level":"warning","message":{"text":"_legacy.cmd_continue (cognitive 21): _legacy.cmd_continue has cognitive complexity 21 (threshold 15). Drivers by points: if/else 8 (12 pts), boolean chains 3, error handling 2 (3 pts), ternaries 2 (3 pts) (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":1608}}}],"partialFingerprints":{"codehealthFindingId/v1":"7aac47dcd825be7ec4dea365485e15ad4c815c1ddcdc4f31a96781adf3dbbfda"}},{"ruleId":"D2","level":"warning","message":{"text":"_legacy._handle_swarm_command (cognitive 21): _legacy._handle_swarm_command has cognitive complexity 21 (threshold 15). Drivers by points: if/else 12 (17 pts), ternaries 2 (3 pts), boolean chains 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":2012}}}],"partialFingerprints":{"codehealthFindingId/v1":"a36da60f7df183bf2263f8ec3fe33ae5db7028af722112cdf89e8bab6de1a585"}},{"ruleId":"D2","level":"warning","message":{"text":"_legacy.cmd_swarm_inspect (cognitive 21): _legacy.cmd_swarm_inspect has cognitive complexity 21 (threshold 15). Drivers by points: loops 5 (8 pts), boolean chains 4, if/else 4, ternaries 3, error handling 2 (nesting depth added 3). 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":2719}}}],"partialFingerprints":{"codehealthFindingId/v1":"11e36516d51a0e25801265bc760f7d271f40d15bc1ac95310197a0c0a8ef1481"}},{"ruleId":"D2","level":"warning","message":{"text":"main._render_mandate_proposal (cognitive 21): main._render_mandate_proposal has cognitive complexity 21 (threshold 15). Drivers by points: if/else 8 (14 pts), boolean chains 5, loops 1, ternaries 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/main.py"},"region":{"startLine":1008}}}],"partialFingerprints":{"codehealthFindingId/v1":"919abd53ba0f07b6d7eb339d1785bafde597cd08fc8b9656a748ed1e06aa504f"}},{"ruleId":"D2","level":"warning","message":{"text":"result_artifacts.persist_calculation_result (cognitive 21): result_artifacts.persist_calculation_result has cognitive complexity 21 (threshold 15). Drivers by points: if/else 9 (14 pts), loops 3 (4 pts), error handling 2 (3 pts) (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/agent/result_artifacts.py"},"region":{"startLine":16}}}],"partialFingerprints":{"codehealthFindingId/v1":"b6c7ab808369ff7501635744b0d2ff1d324a1de0aff69d87aecc7bb4b709bbb6"}},{"ruleId":"D2","level":"warning","message":{"text":"MatrixChannel.start (cognitive 21): MatrixChannel.start has cognitive complexity 21 (threshold 15). Drivers by points: if/else 8 (13 pts), error handling 2 (5 pts), boolean chains 2, ternaries 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/matrix.py"},"region":{"startLine":255}}}],"partialFingerprints":{"codehealthFindingId/v1":"65f21adf6f13d9084e7143af2bb3268a3fdba9144cdb9de57e02212930ef4706"}},{"ruleId":"D2","level":"warning","message":{"text":"MSTeamsChannel._prune_conversation_refs (cognitive 21): MSTeamsChannel._prune_conversation_refs has cognitive complexity 21 (threshold 15). Drivers by points: if/else 6 (10 pts), boolean chains 4, ternaries 2 (3 pts), error handling 1 (2 pts), loops 2 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/msteams.py"},"region":{"startLine":727}}}],"partialFingerprints":{"codehealthFindingId/v1":"05b4f3d2dc90235f61c942144b458cd3389f436492a51f48c8e8f3a686d1a148"}},{"ruleId":"D2","level":"warning","message":{"text":"QQChannel._on_message (cognitive 21): QQChannel._on_message has cognitive complexity 21 (threshold 15). Drivers by points: if/else 8 (9 pts), ternaries 3 (5 pts), boolean chains 4, error handling 2 (3 pts) (nesting depth added 4). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/qq.py"},"region":{"startLine":531}}}],"partialFingerprints":{"codehealthFindingId/v1":"6e57fa40f8196540143c6b75c72bdd5ef7c26247b6e6c5c6db8ad0f3af24776a"}},{"ruleId":"D2","level":"warning","message":{"text":"Runner.execute (cognitive 21): Runner.execute has cognitive complexity 21 (threshold 15). Drivers by points: if/else 9 (12 pts), boolean chains 4, error handling 2 (3 pts), loops 1, ternaries 1 (nesting depth added 4). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/core/runner.py"},"region":{"startLine":594}}}],"partialFingerprints":{"codehealthFindingId/v1":"f603f98892838051397cf23c01603400fc6cd7259aa9f460c512d36117a5d9f7"}},{"ruleId":"D2","level":"warning","message":{"text":"compare_runner.compare_alphas (cognitive 21): compare_runner.compare_alphas has cognitive complexity 21 (threshold 15). Drivers by points: if/else 8 (10 pts), boolean chains 5, loops 3 (5 pts), ternaries 1 (nesting depth added 4). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/compare_runner.py"},"region":{"startLine":88}}}],"partialFingerprints":{"codehealthFindingId/v1":"5f43a38be5e88f476f407ad5752cf1a74e66d3742db461ff251d41bf159da6c4"}},{"ruleId":"D2","level":"warning","message":{"text":"data_availability.build_availability_contract (cognitive 21): data_availability.build_availability_contract has cognitive complexity 21 (threshold 15). Drivers by points: if/else 9 (13 pts), boolean chains 5, ternaries 1 (2 pts), loops 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/data_availability.py"},"region":{"startLine":229}}}],"partialFingerprints":{"codehealthFindingId/v1":"1cc37717d54fe95df840a78bc010d1fc16023539d43ae87e905831e70b92c0e6"}},{"ruleId":"D2","level":"warning","message":{"text":"sdk_order_gate._recover_pending_order (cognitive 21): sdk_order_gate._recover_pending_order has cognitive complexity 21 (threshold 15). Drivers by points: if/else 8, error handling 4 (7 pts), boolean chains 3, ternaries 3 (nesting depth added 3). To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/live/sdk_order_gate.py"},"region":{"startLine":542}}}],"partialFingerprints":{"codehealthFindingId/v1":"593ce291a09310ad673ac12238fbdf7e27079d0525b276efa06619b68f0035ca"}},{"ruleId":"D2","level":"warning","message":{"text":"MemoryHierarchy.scan_all (cognitive 21): MemoryHierarchy.scan_all has cognitive complexity 21 (threshold 15). Drivers by points: if/else 5 (13 pts), loops 3 (6 pts), boolean chains 2 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/memory/hierarchy.py"},"region":{"startLine":145}}}],"partialFingerprints":{"codehealthFindingId/v1":"17461b11b5a931ddd06bcf042b6a8a98264fad30b1a55ffad2ae7c4dbaa8dde5"}},{"ruleId":"D2","level":"warning","message":{"text":"MemoryHierarchy.prune_search_scope (cognitive 21): MemoryHierarchy.prune_search_scope has cognitive complexity 21 (threshold 15). Drivers by points: if/else 7 (14 pts), loops 4 (6 pts), boolean chains 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/memory/hierarchy.py"},"region":{"startLine":313}}}],"partialFingerprints":{"codehealthFindingId/v1":"a58ed7662a12d7fe679a898f88a1d149adeb628cf30e5d7ece52f03e5455fd32"}},{"ruleId":"D2","level":"warning","message":{"text":"PersistentMemory._scan_entries (cognitive 21): PersistentMemory._scan_entries has cognitive complexity 21 (threshold 15). Drivers by points: if/else 5 (8 pts), error handling 3 (6 pts), ternaries 2 (4 pts), boolean chains 2, loops 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/memory/persistent.py"},"region":{"startLine":230}}}],"partialFingerprints":{"codehealthFindingId/v1":"616482caed661f3478b4ff31afb852b560a4ab1eb31fc05020949fe4c22210c2"}},{"ruleId":"D2","level":"warning","message":{"text":"WorkspaceContextInjector._format_tool_results (cognitive 21): WorkspaceContextInjector._format_tool_results has cognitive complexity 21 (threshold 15). Drivers by points: if/else 8 (17 pts), loops 2 (3 pts), boolean chains 1 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/openbb_bridge/context_injector.py"},"region":{"startLine":167}}}],"partialFingerprints":{"codehealthFindingId/v1":"bc28370b83c9154d5b1cc69db33919d6ba5eeafbb8b46101182c86bd930a5ba4"}},{"ruleId":"D2","level":"warning","message":{"text":"compatibility.adapt_and_validate_payloads (cognitive 21): compatibility.adapt_and_validate_payloads has cognitive complexity 21 (threshold 15). Drivers by points: if/else 10 (15 pts), boolean chains 3, loops 2, ternaries 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/portfolio/compatibility.py"},"region":{"startLine":131}}}],"partialFingerprints":{"codehealthFindingId/v1":"d5ef33c55d372f9e86470c22496ac67018fe027b78233d3c10425d1f7800b0a6"}},{"ruleId":"D2","level":"warning","message":{"text":"openai_codex._get_codex_token (cognitive 21): openai_codex._get_codex_token has cognitive complexity 21 (threshold 15). Drivers by points: if/else 9 (12 pts), boolean chains 8, error handling 1 (nesting depth added 3). 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/providers/openai_codex.py"},"region":{"startLine":330}}}],"partialFingerprints":{"codehealthFindingId/v1":"125e26c775a277a2699576b75ff548407ebe0c0f0ec5b5ab0db4dea289b0675e"}},{"ruleId":"D2","level":"warning","message":{"text":"tool_policy.check_bash_command (cognitive 21): tool_policy.check_bash_command has cognitive complexity 21 (threshold 15). Drivers by points: if/else 9 (13 pts), boolean chains 6, error handling 1, ternaries 1 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/providers/tool_policy.py"},"region":{"startLine":84}}}],"partialFingerprints":{"codehealthFindingId/v1":"c23c8da004f5548f98f0b1ff499ef68f5af5723c8d9e38751adc08a6af1481b0"}},{"ruleId":"D2","level":"warning","message":{"text":"microstructure.vpin (cognitive 21): microstructure.vpin has cognitive complexity 21 (threshold 15). Drivers by points: if/else 9 (13 pts), boolean chains 5, loops 2 (3 pts) (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/microstructure.py"},"region":{"startLine":132}}}],"partialFingerprints":{"codehealthFindingId/v1":"2b29d84cd8bebfc48937a13d01ca303f588eb51f9c6c54e2589e8eaa5aad9c71"}},{"ruleId":"D2","level":"warning","message":{"text":"artifact._flatten (cognitive 21): artifact._flatten has cognitive complexity 21 (threshold 15). Drivers by points: if/else 11 (12 pts), loops 3 (6 pts), ternaries 1 (2 pts), boolean chains 1 (nesting depth added 5). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/valuation/artifact.py"},"region":{"startLine":399}}}],"partialFingerprints":{"codehealthFindingId/v1":"6ae5f68f41103dc12ca64869fd5101db74a4baafabce967b862e32ee7350a9ca"}},{"ruleId":"D2","level":"warning","message":{"text":"ResearchPlaybook.to_job (cognitive 21): ResearchPlaybook.to_job has cognitive complexity 21 (threshold 15). Drivers by points: ternaries 8, boolean chains 7, if/else 5 (6 pts) (nesting depth added 1). To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/scheduled_research/playbooks.py"},"region":{"startLine":142}}}],"partialFingerprints":{"codehealthFindingId/v1":"68380991a85e20d0c2eb66c411f70d01ee45766537f871b269e864a4fbc514f1"}},{"ruleId":"D2","level":"warning","message":{"text":"SessionService._run_attempt (cognitive 21): SessionService._run_attempt has cognitive complexity 21 (threshold 15). Drivers by points: if/else 13 (16 pts), boolean chains 2, error handling 2, loops 1 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/session/service.py"},"region":{"startLine":446}}}],"partialFingerprints":{"codehealthFindingId/v1":"098a862b8e0aeb040ce0a2b68b837fc3edfe12cfe936d2554f33b3f3ab902abc"}},{"ruleId":"D2","level":"warning","message":{"text":"SessionService._convert_messages_to_history (cognitive 21): SessionService._convert_messages_to_history has cognitive complexity 21 (threshold 15). Drivers by points: if/else 5 (10 pts), ternaries 3 (6 pts), boolean chains 3, loops 2 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/session/service.py"},"region":{"startLine":807}}}],"partialFingerprints":{"codehealthFindingId/v1":"8cf7e4401faf022809b8dcbb63b0f1eb454679b377ccab1734cc4b5974c3fce5"}},{"ruleId":"D2","level":"warning","message":{"text":"etf_holdings_tool._lookup_cn (cognitive 21): etf_holdings_tool._lookup_cn has cognitive complexity 21 (threshold 15). Drivers by points: if/else 8 (15 pts), error handling 2 (4 pts), boolean chains 2 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/etf_holdings_tool.py"},"region":{"startLine":1309}}}],"partialFingerprints":{"codehealthFindingId/v1":"4f89b2dbdc2171cee9f4b63472cb0791e33e18fd9b9218907d6051784be67875"}},{"ruleId":"D2","level":"warning","message":{"text":"MCPServerAdapter._build_client (cognitive 21): MCPServerAdapter._build_client has cognitive complexity 21 (threshold 15). Drivers by points: ternaries 5 (13 pts), boolean chains 4, if/else 3 (4 pts) (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/mcp.py"},"region":{"startLine":662}}}],"partialFingerprints":{"codehealthFindingId/v1":"2acb8e2b2b6a01748a1cd8dbde3066e2edd94402c4835fb5d1d77410e208f632"}},{"ruleId":"D2","level":"warning","message":{"text":"mcp._normalize_schema_node (cognitive 21): mcp._normalize_schema_node has cognitive complexity 21 (threshold 15). Drivers by points: if/else 8 (18 pts), loops 1 (2 pts), boolean chains 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/mcp.py"},"region":{"startLine":1021}}}],"partialFingerprints":{"codehealthFindingId/v1":"d33d0adf3ae71d4b1aa6e98d51d1a60c583614dcf5247698e62a2881871bd1d2"}},{"ruleId":"D2","level":"warning","message":{"text":"_MatchSession._day_gate (cognitive 21): _MatchSession._day_gate has cognitive complexity 21 (threshold 15). Drivers by points: if/else 11 (16 pts), boolean chains 3, ternaries 1 (2 pts) (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/paper_trade/engine.py"},"region":{"startLine":276}}}],"partialFingerprints":{"codehealthFindingId/v1":"f3586bafc2652e26cf6944802a95a3c1aa249f243840207578e68c5c5850c947"}},{"ruleId":"D2","level":"warning","message":{"text":"PortfolioRiskXrayTool._closes_frame (cognitive 21): PortfolioRiskXrayTool._closes_frame has cognitive complexity 21 (threshold 15). Drivers by points: if/else 7 (14 pts), error handling 1 (3 pts), loops 2 (3 pts), boolean chains 1 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/portfolio_risk_tool.py"},"region":{"startLine":187}}}],"partialFingerprints":{"codehealthFindingId/v1":"dacaaa0bb2704a3002cc2652ff3412a66126d0e146474e363fcaf0c215b08ae9"}},{"ruleId":"D2","level":"warning","message":{"text":"ReportAuditTool.execute (cognitive 21): ReportAuditTool.execute has cognitive complexity 21 (threshold 15). Drivers by points: boolean chains 6, if/else 4 (6 pts), error handling 3 (5 pts), ternaries 2 (4 pts) (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/report_audit_tool.py"},"region":{"startLine":561}}}],"partialFingerprints":{"codehealthFindingId/v1":"93cff76dfc949ae384e622b61c798c963f679ea95aa913e1aea03da0d0c117b4"}},{"ruleId":"D2","level":"warning","message":{"text":"research_papers_tool._arxiv_paper (cognitive 21): research_papers_tool._arxiv_paper has cognitive complexity 21 (threshold 15). Drivers by points: boolean chains 16, ternaries 4, if/else 1. To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/research_papers_tool.py"},"region":{"startLine":1017}}}],"partialFingerprints":{"codehealthFindingId/v1":"2a124492bfbe011052063f7bb4b8b948158dad71c1bad36cf1d66f9154d40989"}},{"ruleId":"D2","level":"warning","message":{"text":"ShareholderCountTool.execute (cognitive 21): ShareholderCountTool.execute has cognitive complexity 21 (threshold 15). Drivers by points: if/else 11 (15 pts), loops 1 (3 pts), boolean chains 2, error handling 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/shareholder_count_tool.py"},"region":{"startLine":85}}}],"partialFingerprints":{"codehealthFindingId/v1":"80bc3c2fc5901fc19f99835f0dc1089330b5f5269558df6417f8450202535562"}},{"ruleId":"D2","level":"warning","message":{"text":"sdk._enrich_positions_with_metadata (cognitive 21): sdk._enrich_positions_with_metadata has cognitive complexity 21 (threshold 15). Drivers by points: if/else 6 (10 pts), error handling 3 (5 pts), boolean chains 4, loops 2 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/etoro/sdk.py"},"region":{"startLine":422}}}],"partialFingerprints":{"codehealthFindingId/v1":"aefda0dc21df79985babbf9e50b92164b535ce75155e2d3fff3788ae9de38951"}},{"ruleId":"D2","level":"warning","message":{"text":"MonthlyReturnsHeatmap.MonthlyReturnsHeatmap (cognitive 21): MonthlyReturnsHeatmap.MonthlyReturnsHeatmap has cognitive complexity 21 (threshold 15). Drivers by points: if/else 7 (11 pts), boolean chains 4, loops 3, ternaries 3 (nesting depth added 4). Most of this is not in the body itself: 1 of the 21 points is its own statement and the rest belongs to 3 function literals inside it that branch (lines 20, 58, 95). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/charts/MonthlyReturnsHeatmap.tsx"},"region":{"startLine":17}}}],"partialFingerprints":{"codehealthFindingId/v1":"561b0d1e12ea79d6f8c7e5653ab4cb9d50ea240238ba8c16635609f7679977c2"}},{"ruleId":"D2","level":"warning","message":{"text":"useAlphaJob.useAlphaJob (cognitive 21): useAlphaJob.useAlphaJob has cognitive complexity 21 (threshold 15). Drivers by points: ternaries 6 (15 pts), boolean chains 4, if/else 2 (nesting depth added 9). None of this is in the body itself: all 21 points belong to 4 function literals inside it that branch (lines 64, 74, 71, \u2026). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/hooks/useAlphaJob.ts"},"region":{"startLine":9}}}],"partialFingerprints":{"codehealthFindingId/v1":"14f14a761ce6ba93b1ac8a5397f4a9555a631ec4556d670ddea8aefedfb6e034"}},{"ruleId":"D2","level":"warning","message":{"text":"options.buildVolatilitySurfaceRequest (cognitive 21): options.buildVolatilitySurfaceRequest has cognitive complexity 21 (threshold 15). Drivers by points: if/else 6 (10 pts), boolean chains 6, ternaries 4, loops 1 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/lib/options.ts"},"region":{"startLine":258}}}],"partialFingerprints":{"codehealthFindingId/v1":"d06f6f5a76e334012dc9345644b9ff78ee90d1d54730c556a1f72db18da3177a"}},{"ruleId":"D2","level":"warning","message":{"text":"BaseEngine.historical_base_price (cognitive 20): BaseEngine.historical_base_price has cognitive complexity 20 (threshold 15). Drivers by points: if/else 7 (14 pts), boolean chains 5, loops 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/engines/base.py"},"region":{"startLine":725}}}],"partialFingerprints":{"codehealthFindingId/v1":"c7f1502b82fd3ea4299d46ef3d03e30891769c4a4f6414adac50f28bc02d7813"}},{"ruleId":"D2","level":"warning","message":{"text":"DataLoader._fetch_one (cognitive 20): DataLoader._fetch_one has cognitive complexity 20 (threshold 15). Drivers by points: if/else 12 (16 pts), boolean chains 2, loops 1 (2 pts) (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/local_loader.py"},"region":{"startLine":355}}}],"partialFingerprints":{"codehealthFindingId/v1":"bbb6f1219df5da4e3babd8cb7decff130b1faf9b4170d4f6d4e3a627c0bf74b8"}},{"ruleId":"D2","level":"warning","message":{"text":"runner._reject_forbidden_open (cognitive 20): runner._reject_forbidden_open has cognitive complexity 20 (threshold 15). Drivers by points: if/else 7 (10 pts), boolean chains 7, ternaries 2, loops 1 (nesting depth added 3). 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/runner.py"},"region":{"startLine":585}}}],"partialFingerprints":{"codehealthFindingId/v1":"b6fde6f5a00a51f318d32028647d416142fae61dbaf884101b666f1b81aec77e"}},{"ruleId":"D2","level":"warning","message":{"text":"_legacy.cmd_init (cognitive 20): _legacy.cmd_init has cognitive complexity 20 (threshold 15). Drivers by points: if/else 7 (10 pts), ternaries 3 (7 pts), loops 2 (3 pts) (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":5997}}}],"partialFingerprints":{"codehealthFindingId/v1":"fd1fc5d6e539e5c997a7394bc6ee0af4e235303234b59e910748bc994593cafb"}},{"ruleId":"D2","level":"warning","message":{"text":"mcp_server.alpha_bench (cognitive 20): mcp_server.alpha_bench has cognitive complexity 20 (threshold 15). Drivers by points: if/else 11, boolean chains 5, error handling 3 (4 pts) (nesting depth added 1). To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/mcp_server.py"},"region":{"startLine":1059}}}],"partialFingerprints":{"codehealthFindingId/v1":"a410ca74766fd9fad8b5d10a53a01f1e367e6c492474a63f34d9967f3b95e366"}},{"ruleId":"D2","level":"warning","message":{"text":"context_compact._attach_tool_call_thought_signatures (cognitive 20): context_compact._attach_tool_call_thought_signatures has cognitive complexity 20 (threshold 15). Drivers by points: if/else 7 (12 pts), boolean chains 4, loops 3 (4 pts) (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/agent/context_compact.py"},"region":{"startLine":451}}}],"partialFingerprints":{"codehealthFindingId/v1":"7677cf8dec8bb4717ab782cd000873207eb98f201e1077a93f9ebdc884b3ff3f"}},{"ruleId":"D2","level":"warning","message":{"text":"EmailChannel._authentication_results_segments (cognitive 20): EmailChannel._authentication_results_segments has cognitive complexity 20 (threshold 15). Drivers by points: if/else 6 (13 pts), boolean chains 6, loops 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/email.py"},"region":{"startLine":959}}}],"partialFingerprints":{"codehealthFindingId/v1":"202fd4e1df46944791d5499b7f40db49df6631a751cc19ff525a9254cde3ff89"}},{"ruleId":"D2","level":"warning","message":{"text":"NapcatChannel._on_message (cognitive 20): NapcatChannel._on_message has cognitive complexity 20 (threshold 15). Drivers by points: if/else 9 (13 pts), boolean chains 6, loops 1 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/napcat.py"},"region":{"startLine":233}}}],"partialFingerprints":{"codehealthFindingId/v1":"e4d0f6235ac23e603992ab322aadc707059b08c324ca2e0cfdd2f1e6e63216cf"}},{"ruleId":"D2","level":"warning","message":{"text":"signal._partition_styles (cognitive 20): signal._partition_styles has cognitive complexity 20 (threshold 15). Drivers by points: if/else 6 (13 pts), loops 3 (4 pts), boolean chains 3 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/signal.py"},"region":{"startLine":262}}}],"partialFingerprints":{"codehealthFindingId/v1":"a2d07cbd6554423ac4d68f604a80d90e6c6fe60d9e67d6658ccf623f0c31c256"}},{"ruleId":"D2","level":"warning","message":{"text":"sources.cboe_options (cognitive 20): sources.cboe_options has cognitive complexity 20 (threshold 15). Drivers by points: if/else 9 (13 pts), ternaries 2 (3 pts), boolean chains 2, loops 2 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/data_gateway/sources.py"},"region":{"startLine":131}}}],"partialFingerprints":{"codehealthFindingId/v1":"222e98509b37541fd662356ec11fd809a6560460685d3d5a2d938b9718f9be6e"}},{"ruleId":"D2","level":"warning","message":{"text":"Topic.parse (cognitive 20): Topic.parse has cognitive complexity 20 (threshold 15). Drivers by points: if/else 6 (9 pts), boolean chains 7, ternaries 2 (4 pts) (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/data_gateway/streams.py"},"region":{"startLine":34}}}],"partialFingerprints":{"codehealthFindingId/v1":"54d6b65121d40f907624b9ef2ed3553bb8c1142f7f9d099ed1c86ab84234ac19"}},{"ruleId":"D2","level":"warning","message":{"text":"base.downside_beta (cognitive 20): base.downside_beta has cognitive complexity 20 (threshold 15). Drivers by points: if/else 4 (13 pts), loops 2 (3 pts), ternaries 1 (3 pts), boolean chains 1 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/base.py"},"region":{"startLine":517}}}],"partialFingerprints":{"codehealthFindingId/v1":"226c279f03fb9a621f392664c4b76a8768d8488937f7c397f735bbdd7cdd0091"}},{"ruleId":"D2","level":"warning","message":{"text":"data_availability._source_for (cognitive 20): data_availability._source_for has cognitive complexity 20 (threshold 15). Drivers by points: ternaries 5 (10 pts), if/else 8, boolean chains 2 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/data_availability.py"},"region":{"startLine":170}}}],"partialFingerprints":{"codehealthFindingId/v1":"f8a1612e9ffb1339e60fd2f05cb549ba2e640e3a327c797e73b5d245d884a1dc"}},{"ruleId":"D2","level":"warning","message":{"text":"Registry.compute (cognitive 20): Registry.compute has cognitive complexity 20 (threshold 15). Drivers by points: if/else 11 (13 pts), loops 2 (4 pts), error handling 2, boolean chains 1 (nesting depth added 4). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/registry.py"},"region":{"startLine":325}}}],"partialFingerprints":{"codehealthFindingId/v1":"d47e2295b9a08032b9ec7ce74c64264cad7c7a28d92368844a4db6eb65cd1f2d"}},{"ruleId":"D2","level":"warning","message":{"text":"HypothesisRegistry.update (cognitive 20): HypothesisRegistry.update has cognitive complexity 20 (threshold 15). Drivers by points: if/else 10, ternaries 8, boolean chains 2. To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/hypotheses/registry.py"},"region":{"startLine":214}}}],"partialFingerprints":{"codehealthFindingId/v1":"d49d73dc0b63690f680c3bb5d764d8a9818627c701214e627251255606f94067"}},{"ruleId":"D2","level":"warning","message":{"text":"PortfolioService._warnings (cognitive 20): PortfolioService._warnings has cognitive complexity 20 (threshold 15). Drivers by points: if/else 13 (14 pts), boolean chains 5, loops 1 (nesting depth added 1). To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/portfolio/service.py"},"region":{"startLine":1203}}}],"partialFingerprints":{"codehealthFindingId/v1":"f10c3b9cefad22462d334841ed53420a05791f1556f508e025808916508b1bc5"}},{"ruleId":"D2","level":"warning","message":{"text":"fixedincome.fit_yield_curve (cognitive 20): fixedincome.fit_yield_curve has cognitive complexity 20 (threshold 15). Drivers by points: if/else 13 (15 pts), boolean chains 3, loops 1, ternaries 1 (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/fixedincome.py"},"region":{"startLine":733}}}],"partialFingerprints":{"codehealthFindingId/v1":"2b818f31dec3cb51ce3cbb63c7bfeb097e48a37c5e216db68b758cabeb1bbe5e"}},{"ruleId":"D2","level":"warning","message":{"text":"performance._normalize_valuations (cognitive 20): performance._normalize_valuations has cognitive complexity 20 (threshold 15). Drivers by points: if/else 7 (13 pts), loops 3 (4 pts), error handling 1 (2 pts), boolean chains 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/performance.py"},"region":{"startLine":281}}}],"partialFingerprints":{"codehealthFindingId/v1":"253fc6242555c5f3abaaa0de9fb4030c0a6eec58b9e716dc67c608aca4cbf8a9"}},{"ruleId":"D2","level":"warning","message":{"text":"execution.trial (cognitive 20): execution.trial has cognitive complexity 20 (threshold 15). Drivers by points: if/else 9 (12 pts), error handling 1 (3 pts), loops 3, boolean chains 2 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/research_lab/execution.py"},"region":{"startLine":138}}}],"partialFingerprints":{"codehealthFindingId/v1":"ca1b16c1884560476fec52ce04a460431d35ea18262d10019a5a5cb369e39255"}},{"ruleId":"D2","level":"warning","message":{"text":"backtest_runs_tool.list_backtest_runs (cognitive 20): backtest_runs_tool.list_backtest_runs has cognitive complexity 20 (threshold 15). Drivers by points: if/else 5 (9 pts), boolean chains 5, ternaries 4, error handling 1, loops 1 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/backtest_runs_tool.py"},"region":{"startLine":133}}}],"partialFingerprints":{"codehealthFindingId/v1":"e4413eb10ab5d1851efbe9d9b7437e5bc6eca5feb8e08b5af02b31634d51627a"}},{"ruleId":"D2","level":"warning","message":{"text":"financial_statements_tool._synthesize_fiscal_q4 (cognitive 20): financial_statements_tool._synthesize_fiscal_q4 has cognitive complexity 20 (threshold 15). Drivers by points: if/else 6 (11 pts), boolean chains 8, loops 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/financial_statements_tool.py"},"region":{"startLine":576}}}],"partialFingerprints":{"codehealthFindingId/v1":"c9b767b800c41fdf78e5d09da11fdcf2826351f8f8db883da6d34ed3b35c11e1"}},{"ruleId":"D2","level":"warning","message":{"text":"LoadSkillTool.execute (cognitive 20): LoadSkillTool.execute has cognitive complexity 20 (threshold 15). Drivers by points: if/else 9 (12 pts), boolean chains 7, error handling 1 (nesting depth added 3). 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/load_skill_tool.py"},"region":{"startLine":207}}}],"partialFingerprints":{"codehealthFindingId/v1":"f61c6d2a95f307433b0ed73ff0bf38272ce5cde1c333a0cec3bb586a4bdfb3cb"}},{"ruleId":"D2","level":"warning","message":{"text":"OptionsPricingTool.execute (cognitive 20): OptionsPricingTool.execute has cognitive complexity 20 (threshold 15). Drivers by points: boolean chains 8, if/else 7, ternaries 2 (3 pts), error handling 2 (nesting depth added 1). To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/options_pricing_tool.py"},"region":{"startLine":95}}}],"partialFingerprints":{"codehealthFindingId/v1":"dca3b138ddc75adb3122edd01b6262dde19382b616ea66e30474a515066a776b"}},{"ruleId":"D2","level":"warning","message":{"text":"quantlib_tool._encode (cognitive 20): quantlib_tool._encode has cognitive complexity 20 (threshold 15). Drivers by points: if/else 13 (15 pts), ternaries 1 (3 pts), boolean chains 2 (nesting depth added 4). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/quantlib_tool.py"},"region":{"startLine":184}}}],"partialFingerprints":{"codehealthFindingId/v1":"ef8b71f90073426a2fbe45e3b63c22ee3b262e27f44d0374645dd652c49570eb"}},{"ruleId":"D2","level":"warning","message":{"text":"stock_news_tool._fetch_eastmoney_news (cognitive 20): stock_news_tool._fetch_eastmoney_news has cognitive complexity 20 (threshold 15). Drivers by points: if/else 7 (13 pts), ternaries 2 (6 pts), boolean chains 1 (nesting depth added 10). To reduce it, flatten the nesting: this score is depth rather than breadth \u2014 most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language\u0027s equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/stock_news_tool.py"},"region":{"startLine":152}}}],"partialFingerprints":{"codehealthFindingId/v1":"c1332e24b69908105929c74e3d0636f686dd7bc3aa10b711ac4fda24f77f2e3b"}},{"ruleId":"D2","level":"warning","message":{"text":"trade_journal_parsers.parse_eastmoney (cognitive 20): trade_journal_parsers.parse_eastmoney has cognitive complexity 20 (threshold 15). Drivers by points: if/else 7 (14 pts), boolean chains 3, error handling 1 (2 pts), loops 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/trade_journal_parsers.py"},"region":{"startLine":408}}}],"partialFingerprints":{"codehealthFindingId/v1":"66539845943e8ef0ce1cfa9e12d4a462cd020bd23e094b80d537e5f521773e6e"}},{"ruleId":"D2","level":"warning","message":{"text":"trade_journal_parsers._generic_datetime_cell (cognitive 20): trade_journal_parsers._generic_datetime_cell has cognitive complexity 20 (threshold 15). Drivers by points: if/else 8 (14 pts), boolean chains 4, error handling 1 (2 pts) (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/trade_journal_parsers.py"},"region":{"startLine":667}}}],"partialFingerprints":{"codehealthFindingId/v1":"096b47672b18af68f25190edf69ef6bb0247b05e424cbd1c8313cdfab1535db9"}},{"ruleId":"D2","level":"warning","message":{"text":"orders.place_order (cognitive 20): orders.place_order has cognitive complexity 20 (threshold 15). Drivers by points: if/else 11, boolean chains 6, ternaries 1 (2 pts), error handling 1 (nesting depth added 1). To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/mt5/orders.py"},"region":{"startLine":59}}}],"partialFingerprints":{"codehealthFindingId/v1":"14e77e27c6c9091bba5a62ac42537259b0fcf6281e6e65bbe777225c8f73791f"}},{"ruleId":"D2","level":"warning","message":{"text":"sdk.place_order (cognitive 20): sdk.place_order has cognitive complexity 20 (threshold 15). Drivers by points: if/else 11 (13 pts), boolean chains 5, error handling 2 (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/okx/sdk.py"},"region":{"startLine":373}}}],"partialFingerprints":{"codehealthFindingId/v1":"dd2cdaaecd1f4f5a530172f69f3b03640c07fb0ae68577eb4cb8a64d8722fa58"}},{"ruleId":"D2","level":"warning","message":{"text":"RunnerBudgetControls.RunnerBudgetControls (cognitive 20): RunnerBudgetControls.RunnerBudgetControls has cognitive complexity 20 (threshold 15). Drivers by points: boolean chains 8, ternaries 6 (8 pts), if/else 3, error handling 1 (nesting depth added 2). Most of this is not in the body itself: 9 of the 20 points are its own statements and the rest belongs to 5 function literals inside it that branch (lines 49, 39, 54, \u2026). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/chat/RunnerBudgetControls.tsx"},"region":{"startLine":6}}}],"partialFingerprints":{"codehealthFindingId/v1":"e5505dc7ca5a8f2aa14449797b9bf25e711b5441bca24e0771ac61ccdd06f03d"}},{"ruleId":"D2","level":"warning","message":{"text":"ResearchLab.ResearchLab::submit (cognitive 20): ResearchLab.ResearchLab::submit has cognitive complexity 20 (threshold 15). Drivers by points: if/else 9 (13 pts), ternaries 1 (3 pts), loops 1 (2 pts), boolean chains 1, error handling 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body. This shape REPEATS in the file: one other method here (ResearchLab.ResearchLab) has the same decision points, in the same order, at the same nesting depths \u2014 so this is one pattern written twice rather than two separate problems. Splitting this body alone leaves the other exactly as it is. Where these are variations on one operation, the change that clears both is the shared one: lift the common shape into a single routine the variants call, parameterised by whatever genuinely differs between them, and keep in each method only the part that is not shared."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/ResearchLab.tsx"},"region":{"startLine":96}}}],"partialFingerprints":{"codehealthFindingId/v1":"4ce6130fe4c01342dcf73443c960bcc3ff008dcd4739eddb20374184db1241a6"}},{"ruleId":"D2","level":"warning","message":{"text":"translateElement (cognitive 20): translateElement has cognitive complexity 20 (threshold 15). Drivers by points: if/else 6 (8 pts), other 5, ternaries 2 (4 pts), loops 1 (2 pts), boolean chains 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"wiki/site.js"},"region":{"startLine":62}}}],"partialFingerprints":{"codehealthFindingId/v1":"cb98df713fae94657c03dfc6f473180f02911fdb02a9734afbaade5a1ed65d58"}},{"ruleId":"D2","level":"warning","message":{"text":"constraints._build_constraint (cognitive 19): constraints._build_constraint has cognitive complexity 19 (threshold 15). Drivers by points: if/else 10 (16 pts), boolean chains 3 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/constraints.py"},"region":{"startLine":138}}}],"partialFingerprints":{"codehealthFindingId/v1":"d8e430c8be017bd7de930ab0c8730b2a49c45ff3914f61c6af2a843813854e03"}},{"ruleId":"D2","level":"warning","message":{"text":"BaseEngine._rebalance (cognitive 19): BaseEngine._rebalance has cognitive complexity 19 (threshold 15). Drivers by points: if/else 8 (12 pts), boolean chains 5, ternaries 2 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/engines/base.py"},"region":{"startLine":1634}}}],"partialFingerprints":{"codehealthFindingId/v1":"1f0863b83d1746a619843034c4cd6570389c0a4a96fef928c17faec46ca53f63"}},{"ruleId":"D2","level":"warning","message":{"text":"BaseEngine._write_artifacts (cognitive 19): BaseEngine._write_artifacts has cognitive complexity 19 (threshold 15). Drivers by points: ternaries 6 (12 pts), loops 3, error handling 1 (2 pts), boolean chains 1, if/else 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/engines/base.py"},"region":{"startLine":2388}}}],"partialFingerprints":{"codehealthFindingId/v1":"16f2a74b9dd5f8e5c079db4c49592a7f6385c9db082c4d88246263e3f0e207af"}},{"ruleId":"D2","level":"warning","message":{"text":"baostock_loader._session_admission (cognitive 19): baostock_loader._session_admission has cognitive complexity 19 (threshold 15). Drivers by points: if/else 6 (10 pts), ternaries 3 (6 pts), boolean chains 2, loops 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/baostock_loader.py"},"region":{"startLine":43}}}],"partialFingerprints":{"codehealthFindingId/v1":"02040b3ab20a273b598d55888fdf4a718c61d824ec48b53fcf8c098950b37550"}},{"ruleId":"D2","level":"warning","message":{"text":"DataLoader.fetch (cognitive 19): DataLoader.fetch has cognitive complexity 19 (threshold 15). Drivers by points: if/else 5 (10 pts), error handling 2 (5 pts), boolean chains 3, loops 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/tencent_loader.py"},"region":{"startLine":82}}}],"partialFingerprints":{"codehealthFindingId/v1":"e46e214aefa338c17979f0c26abf7854722e5f69cf90772f9d1f6637b0622cef"}},{"ruleId":"D2","level":"warning","message":{"text":"DataLoader._request_page (cognitive 19): DataLoader._request_page has cognitive complexity 19 (threshold 15). Drivers by points: if/else 11 (12 pts), boolean chains 3, ternaries 3, loops 1 (nesting depth added 1). To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/tencent_loader.py"},"region":{"startLine":158}}}],"partialFingerprints":{"codehealthFindingId/v1":"3ffa9a6ffde69a510f0d27a45a16eb462f6a64773eb284d2f5f8647b0cc01a61"}},{"ruleId":"D2","level":"warning","message":{"text":"input._has_unbalanced_brackets (cognitive 19): input._has_unbalanced_brackets has cognitive complexity 19 (threshold 15). Drivers by points: if/else 7 (16 pts), boolean chains 2, loops 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/input.py"},"region":{"startLine":121}}}],"partialFingerprints":{"codehealthFindingId/v1":"933c1e457877c94e53a1a5d086b5645658b694165251d28a8572654ecf0228cc"}},{"ruleId":"D2","level":"warning","message":{"text":"main._render_scheduled_proposal (cognitive 19): main._render_scheduled_proposal has cognitive complexity 19 (threshold 15). Drivers by points: boolean chains 7, if/else 3 (6 pts), ternaries 3 (6 pts) (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/main.py"},"region":{"startLine":1074}}}],"partialFingerprints":{"codehealthFindingId/v1":"ff3a79c83ef5efe753852260587c5d41a2aa7d31207bbaa66530fcc6b3b5f1b5"}},{"ruleId":"D2","level":"warning","message":{"text":"RailRunDashboard._action_label (cognitive 19): RailRunDashboard._action_label has cognitive complexity 19 (threshold 15). Drivers by points: ternaries 6 (12 pts), if/else 7 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/ui/rail.py"},"region":{"startLine":556}}}],"partialFingerprints":{"codehealthFindingId/v1":"5bfb0c1755fd9b5c05055d2d4aab8ad2e3b27bb98a72e252691b34863f4ff2ed"}},{"ruleId":"D2","level":"warning","message":{"text":"ToolCallLifecycle._batch_execute (cognitive 19): ToolCallLifecycle._batch_execute has cognitive complexity 19 (threshold 15). Drivers by points: if/else 7 (12 pts), loops 3 (5 pts), boolean chains 2 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/agent/tool_lifecycle.py"},"region":{"startLine":535}}}],"partialFingerprints":{"codehealthFindingId/v1":"23c1a79930c99c794b7f760062d653849fc785d5204935a581e61844621d778d"}},{"ruleId":"D2","level":"warning","message":{"text":"live_routes._fetch_broker_ceilings (cognitive 19): live_routes._fetch_broker_ceilings has cognitive complexity 19 (threshold 15). Drivers by points: if/else 5 (6 pts), error handling 4 (5 pts), ternaries 2 (4 pts), boolean chains 3, loops 1 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/api/live_routes.py"},"region":{"startLine":418}}}],"partialFingerprints":{"codehealthFindingId/v1":"0b90099f96caf07fe93cafaa5a6de7b29cb079f114c0ad090424d4fdbde9e800"}},{"ruleId":"D2","level":"warning","message":{"text":"MatrixChannel._upload_and_send_attachment (cognitive 19): MatrixChannel._upload_and_send_attachment has cognitive complexity 19 (threshold 15). Drivers by points: boolean chains 8, if/else 6, error handling 3, ternaries 2. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/matrix.py"},"region":{"startLine":458}}}],"partialFingerprints":{"codehealthFindingId/v1":"0f9d41a0a9a41aa488476f9d2b036ab678b2057673aa1a0304b1d8f3f862dd40"}},{"ruleId":"D2","level":"warning","message":{"text":"QQChannel._read_media_bytes (cognitive 19): QQChannel._read_media_bytes has cognitive complexity 19 (threshold 15). Drivers by points: if/else 10 (12 pts), boolean chains 4, error handling 2 (3 pts) (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/qq.py"},"region":{"startLine":408}}}],"partialFingerprints":{"codehealthFindingId/v1":"4d88407a3042446c5c28ae4a5bc4f60b94399daf034c419855227f3c54fce538"}},{"ruleId":"D2","level":"warning","message":{"text":"SignalChannel._strip_bot_mention (cognitive 19): SignalChannel._strip_bot_mention has cognitive complexity 19 (threshold 15). Drivers by points: if/else 9 (17 pts), loops 2 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/signal.py"},"region":{"startLine":1283}}}],"partialFingerprints":{"codehealthFindingId/v1":"10d2f67b66aba5c1f3fbfa0d7115aabe7a2179ecd2224d9b8111753288410783"}},{"ruleId":"D2","level":"warning","message":{"text":"StreamHub._run (cognitive 19): StreamHub._run has cognitive complexity 19 (threshold 15). Drivers by points: if/else 4 (7 pts), ternaries 3 (7 pts), error handling 2 (4 pts), loops 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/data_gateway/streams.py"},"region":{"startLine":311}}}],"partialFingerprints":{"codehealthFindingId/v1":"3b58f3d249414aed8eb072c0a55fed4ef97ddfcc68cede540a3801abec4ea83e"}},{"ruleId":"D2","level":"warning","message":{"text":"audit.audit_factors (cognitive 19): audit.audit_factors has cognitive complexity 19 (threshold 15). Drivers by points: if/else 6 (12 pts), error handling 1 (2 pts), loops 2, ternaries 1 (2 pts), boolean chains 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/audit.py"},"region":{"startLine":58}}}],"partialFingerprints":{"codehealthFindingId/v1":"b61ea1a540490c233216342fb6d22cfa6982881494f3b1bff7322e2e5561935e"}},{"ruleId":"D2","level":"warning","message":{"text":"LiveRunner._run_preemptive_sweep (cognitive 19): LiveRunner._run_preemptive_sweep has cognitive complexity 19 (threshold 15). Drivers by points: if/else 9 (11 pts), boolean chains 4, error handling 3 (4 pts) (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/live/runtime/runner.py"},"region":{"startLine":624}}}],"partialFingerprints":{"codehealthFindingId/v1":"0796ff0e411f1695ed706890b0c6d928507e02f93644285edf295673d387a616"}},{"ruleId":"D2","level":"warning","message":{"text":"sdk_order_gate._recover_correlated_fill (cognitive 19): sdk_order_gate._recover_correlated_fill has cognitive complexity 19 (threshold 15). Drivers by points: if/else 7, boolean chains 5, error handling 3 (5 pts), ternaries 1 (2 pts) (nesting depth added 3). To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/live/sdk_order_gate.py"},"region":{"startLine":620}}}],"partialFingerprints":{"codehealthFindingId/v1":"c56d9cd722661be41c9dd35918443981a5cfa3155a6f5832b56302937e004ab6"}},{"ruleId":"D2","level":"warning","message":{"text":"PersistentMemory.remove (cognitive 19): PersistentMemory.remove has cognitive complexity 19 (threshold 15). Drivers by points: if/else 9 (10 pts), boolean chains 5, error handling 2 (4 pts) (nesting depth added 3). To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/memory/persistent.py"},"region":{"startLine":649}}}],"partialFingerprints":{"codehealthFindingId/v1":"5741203a60b2c37297de991feb5880c83def617d2cf2abb9e54aaed99133719e"}},{"ruleId":"D2","level":"warning","message":{"text":"OpenBBQueryAdapter._consume_events (cognitive 19): OpenBBQueryAdapter._consume_events has cognitive complexity 19 (threshold 15). Drivers by points: if/else 4 (8 pts), loops 3 (6 pts), boolean chains 5 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/openbb_bridge/adapter.py"},"region":{"startLine":130}}}],"partialFingerprints":{"codehealthFindingId/v1":"a485bc5a9d2327cb7827c5d2b8052b32548417e7a7a4be97f8a91974abf70583"}},{"ruleId":"D2","level":"warning","message":{"text":"WorkspaceContextInjector._format_widgets (cognitive 19): WorkspaceContextInjector._format_widgets has cognitive complexity 19 (threshold 15). Drivers by points: if/else 8 (15 pts), loops 2 (3 pts), boolean chains 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/openbb_bridge/context_injector.py"},"region":{"startLine":269}}}],"partialFingerprints":{"codehealthFindingId/v1":"7880cc74f9f161204fd62492301482b5b90cca596ea721913db1ad4ae6bb823f"}},{"ruleId":"D2","level":"warning","message":{"text":"PortfolioService.latest (cognitive 19): PortfolioService.latest has cognitive complexity 19 (threshold 15). Drivers by points: boolean chains 6, if/else 5 (6 pts), error handling 2 (5 pts), loops 2 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/portfolio/service.py"},"region":{"startLine":566}}}],"partialFingerprints":{"codehealthFindingId/v1":"d3be320c6b2387073d08323a3c04345d9f20757e25381147b6c687edcb973563"}},{"ruleId":"D2","level":"warning","message":{"text":"settings.get_llm_credentials (cognitive 19): settings.get_llm_credentials has cognitive complexity 19 (threshold 15). Drivers by points: if/else 6 (8 pts), boolean chains 7, ternaries 3 (4 pts) (nesting depth added 3). 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/providers/settings.py"},"region":{"startLine":173}}}],"partialFingerprints":{"codehealthFindingId/v1":"b2136722c9db007cb19dc71e01b5d0b38707c169e4070406a090d0eaf0abfe0e"}},{"ruleId":"D2","level":"warning","message":{"text":"crossvalidation._as_label_spans (cognitive 19): crossvalidation._as_label_spans has cognitive complexity 19 (threshold 15). Drivers by points: if/else 10 (17 pts), boolean chains 2 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/crossvalidation.py"},"region":{"startLine":110}}}],"partialFingerprints":{"codehealthFindingId/v1":"000afb6e4a9928c2c45be6ab0bdcbf3191d5c4c70232cc916402e27dcfd086eb"}},{"ruleId":"D2","level":"warning","message":{"text":"performance._assign_flows_to_periods (cognitive 19): performance._assign_flows_to_periods has cognitive complexity 19 (threshold 15). Drivers by points: if/else 7 (17 pts), boolean chains 1, loops 1 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/performance.py"},"region":{"startLine":452}}}],"partialFingerprints":{"codehealthFindingId/v1":"a987dba8d80e6e6d2ff5eec6c41bb6c605950a04d1d7899302a1959a3f104074"}},{"ruleId":"D2","level":"warning","message":{"text":"triggers.next_cron_due (cognitive 19): triggers.next_cron_due has cognitive complexity 19 (threshold 15). Drivers by points: if/else 2 (6 pts), loops 3 (6 pts), ternaries 3 (6 pts), boolean chains 1 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/scheduling/triggers.py"},"region":{"startLine":225}}}],"partialFingerprints":{"codehealthFindingId/v1":"8511810afaa1d4d76e91b8f8e8062c2067193f6c536c625919a2b56ac1751ee4"}},{"ruleId":"D2","level":"warning","message":{"text":"search._search_snippet (cognitive 19): search._search_snippet has cognitive complexity 19 (threshold 15). Drivers by points: if/else 5 (10 pts), loops 4, ternaries 4, boolean chains 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/session/search.py"},"region":{"startLine":44}}}],"partialFingerprints":{"codehealthFindingId/v1":"bbd0b09f1c61559f87e92209817d12181722fc2e9e6f2b8992d0ccb781038e4e"}},{"ruleId":"D2","level":"warning","message":{"text":"backtester._compute_attribution (cognitive 19): backtester._compute_attribution has cognitive complexity 19 (threshold 15). Drivers by points: if/else 7 (13 pts), boolean chains 3, loops 2 (3 pts) (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/shadow_account/backtester.py"},"region":{"startLine":648}}}],"partialFingerprints":{"codehealthFindingId/v1":"bd4196911ea3c5af785f12deed2aa1487e19b76d25de89d7c7edea4a0ff97267"}},{"ruleId":"D2","level":"warning","message":{"text":"codegen._rule_to_context (cognitive 19): codegen._rule_to_context has cognitive complexity 19 (threshold 15). Drivers by points: if/else 5 (13 pts), loops 2 (4 pts), boolean chains 2 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/shadow_account/codegen.py"},"region":{"startLine":127}}}],"partialFingerprints":{"codehealthFindingId/v1":"67084084b04e739f57583cec54d54f28c330eb2747a00a11f427e42f18460185"}},{"ruleId":"D2","level":"warning","message":{"text":"adaptation_workflow.validate_adapted_run (cognitive 19): adaptation_workflow.validate_adapted_run has cognitive complexity 19 (threshold 15). Drivers by points: if/else 10 (12 pts), boolean chains 3, loops 2, error handling 1, ternaries 1 (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/strategy_discovery/adaptation_workflow.py"},"region":{"startLine":111}}}],"partialFingerprints":{"codehealthFindingId/v1":"7c63924475eb7529f75e7a49980a9e0a61786b6948b712402e80ca259bb93d2d"}},{"ruleId":"D2","level":"warning","message":{"text":"grounding.format_grounding_block (cognitive 19): grounding.format_grounding_block has cognitive complexity 19 (threshold 15). Drivers by points: if/else 6 (10 pts), ternaries 2 (6 pts), loops 2 (3 pts) (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/swarm/grounding.py"},"region":{"startLine":231}}}],"partialFingerprints":{"codehealthFindingId/v1":"806b4cfe9617f93c45fd95d82ac45b67f748866f35530ce50d788ea9f7a73304"}},{"ruleId":"D2","level":"warning","message":{"text":"runtime._rehome_artifact_paths (cognitive 19): runtime._rehome_artifact_paths has cognitive complexity 19 (threshold 15). Drivers by points: if/else 5 (10 pts), boolean chains 4, error handling 2 (4 pts), loops 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/swarm/runtime.py"},"region":{"startLine":191}}}],"partialFingerprints":{"codehealthFindingId/v1":"8e7097eb4e21be6ad3a739902101be9529144f8b62a075d19d341b4147d0876e"}},{"ruleId":"D2","level":"warning","message":{"text":"cashflow_analytics_tool._resolve_flows (cognitive 19): cashflow_analytics_tool._resolve_flows has cognitive complexity 19 (threshold 15). Drivers by points: if/else 8 (11 pts), error handling 2 (4 pts), boolean chains 3, loops 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/cashflow_analytics_tool.py"},"region":{"startLine":339}}}],"partialFingerprints":{"codehealthFindingId/v1":"8ab20f702146d8033ba966d6f76c3cf1b0a0137f870091b73f4e3636c8893d56"}},{"ruleId":"D2","level":"warning","message":{"text":"fund_flow_tool._fetch_symbol_flow (cognitive 19): fund_flow_tool._fetch_symbol_flow has cognitive complexity 19 (threshold 15). Drivers by points: if/else 7 (9 pts), ternaries 6, boolean chains 2, error handling 1, loops 1 (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/fund_flow_tool.py"},"region":{"startLine":118}}}],"partialFingerprints":{"codehealthFindingId/v1":"7e42d71e32fa234452a39a07c8503bd1ee80db330e5b5545177e5224b29aeb71"}},{"ruleId":"D2","level":"warning","message":{"text":"institutional_holdings_tool._list_13f_filings (cognitive 19): institutional_holdings_tool._list_13f_filings has cognitive complexity 19 (threshold 15). Drivers by points: if/else 4 (8 pts), boolean chains 6, loops 3 (4 pts), error handling 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/institutional_holdings_tool.py"},"region":{"startLine":570}}}],"partialFingerprints":{"codehealthFindingId/v1":"acb2ad0b7431e4164a445415806dafd5e2263249beeab1ec3719551a6bdc72fb"}},{"ruleId":"D2","level":"warning","message":{"text":"institutional_holdings_tool._parse_information_table (cognitive 19): institutional_holdings_tool._parse_information_table has cognitive complexity 19 (threshold 15). Drivers by points: boolean chains 10, if/else 4 (7 pts), loops 1, ternaries 1 (nesting depth added 3). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/institutional_holdings_tool.py"},"region":{"startLine":722}}}],"partialFingerprints":{"codehealthFindingId/v1":"7e832bcd71b66586fb371821953141d389e548276f537e9bbb1e91fec2dee19a"}},{"ruleId":"D2","level":"warning","message":{"text":"_MatchSession._fill_gate (cognitive 19): _MatchSession._fill_gate has cognitive complexity 19 (threshold 15). Drivers by points: if/else 9 (12 pts), ternaries 4 (6 pts), boolean chains 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/paper_trade/engine.py"},"region":{"startLine":323}}}],"partialFingerprints":{"codehealthFindingId/v1":"87e8d3b81cc368d1e7c7623bae081906e5c054471cd5d4568d6453b354077824"}},{"ruleId":"D2","level":"warning","message":{"text":"pattern_tool.find_peaks_valleys (cognitive 19): pattern_tool.find_peaks_valleys has cognitive complexity 19 (threshold 15). Drivers by points: if/else 8 (16 pts), boolean chains 2, loops 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/pattern_tool.py"},"region":{"startLine":24}}}],"partialFingerprints":{"codehealthFindingId/v1":"10f1d59567d5f2167a1d6f68aff71099f712abb41dfa3c1f048f7985172025df"}},{"ruleId":"D2","level":"warning","message":{"text":"report_audit_tool.extract_data_points (cognitive 19): report_audit_tool.extract_data_points has cognitive complexity 19 (threshold 15). Drivers by points: if/else 5 (11 pts), loops 3 (4 pts), boolean chains 2, ternaries 1 (2 pts) (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/report_audit_tool.py"},"region":{"startLine":213}}}],"partialFingerprints":{"codehealthFindingId/v1":"6ce17ac05bc3fb02eac067c1665711988fcc366d0110c68aaf6504a7a0bec0ad"}},{"ruleId":"D2","level":"warning","message":{"text":"sec_filings_tool._parse_filings (cognitive 19): sec_filings_tool._parse_filings has cognitive complexity 19 (threshold 15). Drivers by points: boolean chains 11, if/else 3 (5 pts), ternaries 1 (2 pts), loops 1 (nesting depth added 3). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/sec_filings_tool.py"},"region":{"startLine":187}}}],"partialFingerprints":{"codehealthFindingId/v1":"cf2929ec8c2a5a73ea1126e8036ae59b57e6f188a64fce6740765e19141d9a3a"}},{"ruleId":"D2","level":"warning","message":{"text":"strategy_discovery_tool.validate_refresh_entries (cognitive 19): strategy_discovery_tool.validate_refresh_entries has cognitive complexity 19 (threshold 15). Drivers by points: if/else 6 (12 pts), boolean chains 2, error handling 1 (2 pts), ternaries 1 (2 pts), loops 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/strategy_discovery_tool.py"},"region":{"startLine":495}}}],"partialFingerprints":{"codehealthFindingId/v1":"cc2f067aa81b3e983f72bac2319f0dbcf1f1e094e41a0f61d68606bb3fc3a287"}},{"ruleId":"D2","level":"warning","message":{"text":"sdk._extract_portfolio_orders (cognitive 19): sdk._extract_portfolio_orders has cognitive complexity 19 (threshold 15). Drivers by points: if/else 5 (12 pts), boolean chains 4, loops 2 (3 pts) (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/etoro/sdk.py"},"region":{"startLine":382}}}],"partialFingerprints":{"codehealthFindingId/v1":"b7f655089e0a79effbdae69709e8f8c1ad997b10854af4c3b55c42a6b1b647a5"}},{"ruleId":"D2","level":"warning","message":{"text":"orders._build_request (cognitive 19): orders._build_request has cognitive complexity 19 (threshold 15). Drivers by points: ternaries 5 (11 pts), if/else 4 (6 pts), boolean chains 2 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/mt5/orders.py"},"region":{"startLine":281}}}],"partialFingerprints":{"codehealthFindingId/v1":"cccc0c3630f71e48afa0eee3e7810cb466876cdde1ae1e66280ba9822c7f793f"}},{"ruleId":"D2","level":"warning","message":{"text":"update-verification.verifyWindowsUpdateCandidate (cognitive 19): update-verification.verifyWindowsUpdateCandidate has cognitive complexity 19 (threshold 15). Drivers by points: if/else 11, boolean chains 5, error handling 3. To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"desktop/electron/src/update-verification.ts"},"region":{"startLine":53}}}],"partialFingerprints":{"codehealthFindingId/v1":"95f1746704f87576f10119aebecdc0bd5d9bee8cf0c77196c0de46e1b5e79d63"}},{"ruleId":"D2","level":"warning","message":{"text":"GoalPanel.GoalPanel (cognitive 19): GoalPanel.GoalPanel has cognitive complexity 19 (threshold 15). Drivers by points: boolean chains 9, ternaries 3 (5 pts), if/else 3, error handling 2 (nesting depth added 2). Most of this is not in the body itself: 9 of the 19 points are its own statements and the rest belongs to 4 function literals inside it that branch (lines 101, 79, 75, \u2026). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/chat/GoalPanel.tsx"},"region":{"startLine":61}}}],"partialFingerprints":{"codehealthFindingId/v1":"6877e7e6e9cc3d09fb8eb5a6137e508f0ff8022085cc69c29064416d5ffa6a8b"}},{"ruleId":"D2","level":"warning","message":{"text":"PortfolioSourceEditor.PortfolioSourceEditor (cognitive 19): PortfolioSourceEditor.PortfolioSourceEditor has cognitive complexity 19 (threshold 15). Drivers by points: if/else 7, ternaries 6 (7 pts), boolean chains 5 (nesting depth added 1). Most of this is not in the body itself: 5 of the 19 points are its own statements and the rest belongs to 10 function items inside it that branch (a function literal at line 108, a function literal at line 35, move, \u2026). The named helpers are already separate functions; the literals\u0027 work cannot be called, reviewed or tested from outside this body. To reduce it, move the named helpers out of the body to the enclosing scope and lift each literal\u0027s work into a named function there, so each is measured, reviewed and tested on its own, and reduce whichever one then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/portfolio/PortfolioSourceEditor.tsx"},"region":{"startLine":29}}}],"partialFingerprints":{"codehealthFindingId/v1":"f3d20407d00e0521e3da596f4e38b2a4282cf153124c3f052c2bc174bbd680fb"}},{"ruleId":"D2","level":"warning","message":{"text":"ResearchLab.ResearchLab (cognitive 19): ResearchLab.ResearchLab has cognitive complexity 19 (threshold 15). Drivers by points: if/else 28 (35 pts), boolean chains 27, loops 3 (5 pts), ternaries 3 (5 pts), error handling 1 (nesting depth added 11). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level. This shape REPEATS in the file: one other method here (ResearchLab.ResearchLab::submit) has the same decision points, in the same order, at the same nesting depths \u2014 so this is one pattern written twice rather than two separate problems. Splitting this body alone leaves the other exactly as it is. Where these are variations on one operation, the change that clears both is the shared one: lift the common shape into a single routine the variants call, parameterised by whatever genuinely differs between them, and keep in each method only the part that is not shared."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/ResearchLab.tsx"},"region":{"startLine":20}}}],"partialFingerprints":{"codehealthFindingId/v1":"45602202be19c236023a1c1dddb1daab2f629da42433c87a519614dcdf4f6c2d"}},{"ruleId":"D2","level":"warning","message":{"text":"Runtime.SdkBrokerRuntimeCard (cognitive 19): Runtime.SdkBrokerRuntimeCard has cognitive complexity 19 (threshold 15). Drivers by points: ternaries 9 (14 pts), boolean chains 3, error handling 1, if/else 1 (nesting depth added 5). Of this number, 17 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Runtime.tsx"},"region":{"startLine":302}}}],"partialFingerprints":{"codehealthFindingId/v1":"e0ef6577629114b0f354d45144b3a61294b7d70ff9a88b19c800368a09280cc8"}},{"ruleId":"D2","level":"warning","message":{"text":"argentina_equity.argentina_sell_allowed (cognitive 18): argentina_equity.argentina_sell_allowed has cognitive complexity 18 (threshold 15). Drivers by points: if/else 7 (12 pts), boolean chains 4, loops 2 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/engines/argentina_equity.py"},"region":{"startLine":623}}}],"partialFingerprints":{"codehealthFindingId/v1":"9466881951c31e667784ba43efd7daa637c3a50f85a544c6cabf90e2854065ad"}},{"ruleId":"D2","level":"warning","message":{"text":"base._normalise_fundamental_fields (cognitive 18): base._normalise_fundamental_fields has cognitive complexity 18 (threshold 15). Drivers by points: if/else 8 (14 pts), boolean chains 3, loops 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/engines/base.py"},"region":{"startLine":430}}}],"partialFingerprints":{"codehealthFindingId/v1":"1a4872724a0ffcdf7c1704c007d4969b01fff81dcc7ed5493ec939affcf50797"}},{"ruleId":"D2","level":"warning","message":{"text":"DataLoader.fetch (cognitive 18): DataLoader.fetch has cognitive complexity 18 (threshold 15). Drivers by points: if/else 4 (9 pts), error handling 2 (5 pts), boolean chains 3, loops 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/akshare_loader.py"},"region":{"startLine":126}}}],"partialFingerprints":{"codehealthFindingId/v1":"6ee72a40424b0fdec2bfe451465fe8b9889f0a31a77840992e4b2ad7dee1283b"}},{"ruleId":"D2","level":"warning","message":{"text":"DataLoader.fetch (cognitive 18): DataLoader.fetch has cognitive complexity 18 (threshold 15). Drivers by points: if/else 4 (9 pts), error handling 2 (5 pts), boolean chains 3, loops 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/eastmoney_loader.py"},"region":{"startLine":71}}}],"partialFingerprints":{"codehealthFindingId/v1":"1d1a9a933e1eee1d560ef71d6cac3b87bd5e0aa36216e03206efc0fb5ce23266"}},{"ruleId":"D2","level":"warning","message":{"text":"mt5_loader._ensure_initialized (cognitive 18): mt5_loader._ensure_initialized has cognitive complexity 18 (threshold 15). Drivers by points: if/else 8 (9 pts), boolean chains 4, error handling 3 (4 pts), ternaries 1 (nesting depth added 2). To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/mt5_loader.py"},"region":{"startLine":77}}}],"partialFingerprints":{"codehealthFindingId/v1":"272db1ff6d165d4ce14f1496e07e779617d7241d76a88dfbca60146c554ea4ca"}},{"ruleId":"D2","level":"warning","message":{"text":"DataLoader._fetch_one (cognitive 18): DataLoader._fetch_one has cognitive complexity 18 (threshold 15). Drivers by points: if/else 7 (11 pts), boolean chains 4, ternaries 2, loops 1 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/nobitex.py"},"region":{"startLine":190}}}],"partialFingerprints":{"codehealthFindingId/v1":"55433d7a3e43d3d7cb5082568ecff022bf0377690dd444fd1531ae4188b2ff70"}},{"ruleId":"D2","level":"warning","message":{"text":"DataLoader._fetch_candles (cognitive 18): DataLoader._fetch_candles has cognitive complexity 18 (threshold 15). Drivers by points: if/else 8 (13 pts), boolean chains 2, error handling 1 (2 pts), loops 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/okx.py"},"region":{"startLine":227}}}],"partialFingerprints":{"codehealthFindingId/v1":"0637ad27d0757013b2a4eff6ac36129b860f6ed59cbf29ac346fdc11d8f1eeec"}},{"ruleId":"D2","level":"warning","message":{"text":"DataLoader._merge_basic_fields (cognitive 18): DataLoader._merge_basic_fields has cognitive complexity 18 (threshold 15). Drivers by points: if/else 5 (10 pts), loops 2 (4 pts), boolean chains 2, error handling 1 (2 pts) (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/tushare.py"},"region":{"startLine":278}}}],"partialFingerprints":{"codehealthFindingId/v1":"fe214338b1aa10f07ec227a48179e076f4164e75f96ce51c16cd9d9b2bfd878c"}},{"ruleId":"D2","level":"warning","message":{"text":"TurnoverAwareOptimizer.__init__ (cognitive 18): TurnoverAwareOptimizer.__init__ has cognitive complexity 18 (threshold 15). Drivers by points: if/else 6 (8 pts), boolean chains 4, ternaries 3, error handling 1 (2 pts), loops 1 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/optimizers/turnover_aware.py"},"region":{"startLine":52}}}],"partialFingerprints":{"codehealthFindingId/v1":"b1398943b6c43f679ca413496bf4bee81cc4ae3c62d596db15de9f62da8dd646"}},{"ruleId":"D2","level":"warning","message":{"text":"options_payoff._analytic_breakevens (cognitive 18): options_payoff._analytic_breakevens has cognitive complexity 18 (threshold 15). Drivers by points: if/else 6 (11 pts), boolean chains 4, loops 3 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/options_payoff.py"},"region":{"startLine":205}}}],"partialFingerprints":{"codehealthFindingId/v1":"a20df5eb5efd81a5b397f190fcf59cd27ef691c6c2cde57187142ee022c526a0"}},{"ruleId":"D2","level":"warning","message":{"text":"_legacy._format_tool_result_preview (cognitive 18): _legacy._format_tool_result_preview has cognitive complexity 18 (threshold 15). Drivers by points: if/else 10 (14 pts), ternaries 2 (4 pts) (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":913}}}],"partialFingerprints":{"codehealthFindingId/v1":"5a156515aaa7de41c37b627bc3beb31105c4384bfddbf0c5650ef63d67446567"}},{"ruleId":"D2","level":"warning","message":{"text":"_legacy._show_settings (cognitive 18): _legacy._show_settings has cognitive complexity 18 (threshold 15). Drivers by points: boolean chains 6, ternaries 5 (6 pts), if/else 4, loops 1 (2 pts) (nesting depth added 2). To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":1894}}}],"partialFingerprints":{"codehealthFindingId/v1":"a20faf368d4b645599fbfae45df34d0087a914d3d440c135cdeb65f688034d66"}},{"ruleId":"D2","level":"warning","message":{"text":"_legacy._handle_slash_command (cognitive 18): _legacy._handle_slash_command has cognitive complexity 18 (threshold 15). Drivers by points: if/else 12 (17 pts), ternaries 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":1953}}}],"partialFingerprints":{"codehealthFindingId/v1":"88364cafa38751f081d639a9b9164a1a14a068bf2f2cd98646c630f376762fd4"}},{"ruleId":"D2","level":"warning","message":{"text":"_legacy.cmd_session_chat (cognitive 18): _legacy.cmd_session_chat has cognitive complexity 18 (threshold 15). Drivers by points: if/else 5 (9 pts), error handling 2 (4 pts), boolean chains 3, loops 2 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":2928}}}],"partialFingerprints":{"codehealthFindingId/v1":"6e4e57984930f3325d8a0aea2c0e00731e3d36f199feaab229fb46bf4b2a6c8e"}},{"ruleId":"D2","level":"warning","message":{"text":"_legacy.cmd_connector_select_account (cognitive 18): _legacy.cmd_connector_select_account has cognitive complexity 18 (threshold 15). Drivers by points: if/else 4 (6 pts), ternaries 2 (6 pts), boolean chains 2, error handling 2, loops 1 (2 pts) (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":4568}}}],"partialFingerprints":{"codehealthFindingId/v1":"3b5c5d68d844592c95a06b095883126980b9bb69b1024d3b18f5b6e3e98331db"}},{"ruleId":"D2","level":"warning","message":{"text":"figures._entity (cognitive 18): figures._entity has cognitive complexity 18 (threshold 15). Drivers by points: if/else 8 (12 pts), boolean chains 4, ternaries 1 (2 pts) (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/grounding/figures.py"},"region":{"startLine":380}}}],"partialFingerprints":{"codehealthFindingId/v1":"388c97b12a0267e4d5d66d9ff7fd0875b90c6bb8990f27ae1a1468abb621c621"}},{"ruleId":"D2","level":"warning","message":{"text":"figures._currency_code_for_figure (cognitive 18): figures._currency_code_for_figure has cognitive complexity 18 (threshold 15). Drivers by points: if/else 9 (10 pts), boolean chains 7, loops 1 (nesting depth added 1). To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/grounding/figures.py"},"region":{"startLine":1051}}}],"partialFingerprints":{"codehealthFindingId/v1":"a0546825cba7d76502744cbeda34a4d88fea6a44ac0f367cd4dd1b3bcd56d840"}},{"ruleId":"D2","level":"warning","message":{"text":"figures._index_cells (cognitive 18): figures._index_cells has cognitive complexity 18 (threshold 15). Drivers by points: if/else 4 (12 pts), loops 3 (4 pts), boolean chains 2 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/grounding/figures.py"},"region":{"startLine":1219}}}],"partialFingerprints":{"codehealthFindingId/v1":"e5821b4e141aa35f836e83697b9e91f872d5f43a04fce34b995d49c12ed17cfe"}},{"ruleId":"D2","level":"warning","message":{"text":"_PolicyMixin._other_call_field_ref_candidates (cognitive 18): _PolicyMixin._other_call_field_ref_candidates has cognitive complexity 18 (threshold 15). Drivers by points: if/else 5 (11 pts), boolean chains 4, loops 2 (3 pts) (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/grounding/policies.py"},"region":{"startLine":1296}}}],"partialFingerprints":{"codehealthFindingId/v1":"46fc721ac4ca2bfe72fbc323dc1c132d9f0e9c72251221aa47ae901c0b010eaf"}},{"ruleId":"D2","level":"warning","message":{"text":"llm_usage._normalize_llm_usage (cognitive 18): llm_usage._normalize_llm_usage has cognitive complexity 18 (threshold 15). Drivers by points: if/else 10 (12 pts), boolean chains 4, error handling 1 (2 pts) (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/agent/llm_usage.py"},"region":{"startLine":35}}}],"partialFingerprints":{"codehealthFindingId/v1":"b5b5a41553bf56ef7d244de095b32904729efed5177d99931303780713e971ad"}},{"ruleId":"D2","level":"warning","message":{"text":"MatrixChannel._download_media_bytes (cognitive 18): MatrixChannel._download_media_bytes has cognitive complexity 18 (threshold 15). Drivers by points: if/else 6 (8 pts), boolean chains 4, error handling 3 (4 pts), loops 1, ternaries 1 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/matrix.py"},"region":{"startLine":873}}}],"partialFingerprints":{"codehealthFindingId/v1":"8324bb3ed146257bbbffd23ceb369da628f20c5b57a50eb73d13f6bf8eba91af"}},{"ruleId":"D2","level":"warning","message":{"text":"MochatChannel._refresh_sessions_directory (cognitive 18): MochatChannel._refresh_sessions_directory has cognitive complexity 18 (threshold 15). Drivers by points: if/else 9 (15 pts), boolean chains 1, error handling 1, loops 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/mochat.py"},"region":{"startLine":550}}}],"partialFingerprints":{"codehealthFindingId/v1":"6837d51e7b89bbd56dbb406666d208a622e00dba926508bcee0adc2207f59f8e"}},{"ruleId":"D2","level":"warning","message":{"text":"MochatChannel._panel_poll_worker (cognitive 18): MochatChannel._panel_poll_worker has cognitive complexity 18 (threshold 15). Drivers by points: if/else 2 (6 pts), boolean chains 4, error handling 2 (4 pts), loops 2 (4 pts) (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/mochat.py"},"region":{"startLine":653}}}],"partialFingerprints":{"codehealthFindingId/v1":"63a0d23622656a356b70547ca1fd1a75494e7410fe48d3f1f6836c3c04f3b216"}},{"ruleId":"D2","level":"warning","message":{"text":"signal._markdown_to_signal (cognitive 18): signal._markdown_to_signal has cognitive complexity 18 (threshold 15). Drivers by points: if/else 6 (10 pts), loops 4 (7 pts), boolean chains 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/signal.py"},"region":{"startLine":137}}}],"partialFingerprints":{"codehealthFindingId/v1":"40d8c0ab71bfe8bffd594830cd3c4be4ac63182c185361a151ac948d3e45a02d"}},{"ruleId":"D2","level":"warning","message":{"text":"SlackChannel._resolve_channel_name (cognitive 18): SlackChannel._resolve_channel_name has cognitive complexity 18 (threshold 15). Drivers by points: if/else 5 (11 pts), boolean chains 4, loops 2 (3 pts) (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/slack.py"},"region":{"startLine":252}}}],"partialFingerprints":{"codehealthFindingId/v1":"e89432e948d0ecfa6e036d56f06c139895b89b7b4a505c8308772ccbaca88224"}},{"ruleId":"D2","level":"warning","message":{"text":"history_router.candidates (cognitive 18): history_router.candidates has cognitive complexity 18 (threshold 15). Drivers by points: if/else 8 (12 pts), boolean chains 5, ternaries 1 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/data_gateway/history_router.py"},"region":{"startLine":79}}}],"partialFingerprints":{"codehealthFindingId/v1":"3a8183a4fcfeeeddbbb9ba0c417659c0d4dd8aea80ae76a1b4f420db4cddeb29"}},{"ruleId":"D2","level":"warning","message":{"text":"HistoryStore._recover_interrupted (cognitive 18): HistoryStore._recover_interrupted has cognitive complexity 18 (threshold 15). Drivers by points: error handling 3 (8 pts), if/else 2 (4 pts), loops 2 (4 pts), boolean chains 2 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/data_gateway/history_store.py"},"region":{"startLine":80}}}],"partialFingerprints":{"codehealthFindingId/v1":"686b08f8cb494c079f1a851ee774a1b2be01bc2a814e17ffbba7d82414c28fcc"}},{"ruleId":"D2","level":"warning","message":{"text":"MarketDataGateway.submit_source (cognitive 18): MarketDataGateway.submit_source has cognitive complexity 18 (threshold 15). Drivers by points: if/else 9 (14 pts), boolean chains 3, error handling 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/data_gateway/service.py"},"region":{"startLine":279}}}],"partialFingerprints":{"codehealthFindingId/v1":"4c38c4b03c1a249c7f241bb98b54bc77c6d1a117237b78df052c87ab49c64414"}},{"ruleId":"D2","level":"warning","message":{"text":"base.zscore_by_group (cognitive 18): base.zscore_by_group has cognitive complexity 18 (threshold 15). Drivers by points: if/else 5 (12 pts), boolean chains 3, loops 2 (3 pts) (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/base.py"},"region":{"startLine":99}}}],"partialFingerprints":{"codehealthFindingId/v1":"efbf46566d3a952e13e7836b29f960ebd72f4c06e6cf44a7f7acf523257b19c9"}},{"ruleId":"D2","level":"warning","message":{"text":"cli_handlers._emit_detail (cognitive 18): cli_handlers._emit_detail has cognitive complexity 18 (threshold 15). Drivers by points: boolean chains 9, if/else 5 (7 pts), loops 1 (2 pts) (nesting depth added 3). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/hypotheses/cli_handlers.py"},"region":{"startLine":105}}}],"partialFingerprints":{"codehealthFindingId/v1":"ba395ad9b61b758eef22e34c4f682ef195fc340bc54ec6274e3df735831c2cbf"}},{"ruleId":"D2","level":"warning","message":{"text":"enforcement._position_signed_market_value (cognitive 18): enforcement._position_signed_market_value has cognitive complexity 18 (threshold 15). Drivers by points: if/else 8 (12 pts), ternaries 2 (5 pts), loops 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/live/enforcement.py"},"region":{"startLine":420}}}],"partialFingerprints":{"codehealthFindingId/v1":"80e31d504e59b7323430876f90efe9e76f4ecc80bc50ebaf5215bccd291312c5"}},{"ruleId":"D2","level":"warning","message":{"text":"PortfolioImportStore.create (cognitive 18): PortfolioImportStore.create has cognitive complexity 18 (threshold 15). Drivers by points: if/else 9 (11 pts), boolean chains 6, loops 1 (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/portfolio/imports.py"},"region":{"startLine":46}}}],"partialFingerprints":{"codehealthFindingId/v1":"0dda528f8e1739c28f633dac06bb9d09510e80f308f967cd702eb938207d11e5"}},{"ruleId":"D2","level":"warning","message":{"text":"preflight._check_llm_provider (cognitive 18): preflight._check_llm_provider has cognitive complexity 18 (threshold 15). Drivers by points: if/else 10 (13 pts), error handling 2 (3 pts), boolean chains 2 (nesting depth added 4). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/preflight.py"},"region":{"startLine":31}}}],"partialFingerprints":{"codehealthFindingId/v1":"826df3c2162c52d816a7fadb9156760dcf93cf32abede40ef607f3ab4a29eb73"}},{"ruleId":"D2","level":"warning","message":{"text":"fixedincome.year_fraction (cognitive 18): fixedincome.year_fraction has cognitive complexity 18 (threshold 15). Drivers by points: if/else 9 (14 pts), ternaries 1 (2 pts), boolean chains 1, loops 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/fixedincome.py"},"region":{"startLine":63}}}],"partialFingerprints":{"codehealthFindingId/v1":"f88c18e1dd888fd2daaf0b3c197dc6621f362f77ffc48f1eb0064584241cd64a"}},{"ruleId":"D2","level":"warning","message":{"text":"volatility.heston_price (cognitive 18): volatility.heston_price has cognitive complexity 18 (threshold 15). Drivers by points: if/else 10 (11 pts), boolean chains 3, ternaries 2 (3 pts), loops 1 (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/volatility.py"},"region":{"startLine":114}}}],"partialFingerprints":{"codehealthFindingId/v1":"a8e255ac93cc7cfbb0b6f5b22d8c7f73546aa327c2d3cafd4899b783e1578cdd"}},{"ruleId":"D2","level":"warning","message":{"text":"proposals.commit_proposal (cognitive 18): proposals.commit_proposal has cognitive complexity 18 (threshold 15). Drivers by points: if/else 11 (17 pts), boolean chains 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/scheduled_research/proposals.py"},"region":{"startLine":172}}}],"partialFingerprints":{"codehealthFindingId/v1":"7bdb4c172ca7193b27a7141a41f1fe4ca66c1d7e3237df012c977eeb18a6adf3"}},{"ruleId":"D2","level":"warning","message":{"text":"scanner._iter_selected_targets (cognitive 18): scanner._iter_selected_targets has cognitive complexity 18 (threshold 15). Drivers by points: if/else 8 (11 pts), ternaries 2 (4 pts), loops 1 (2 pts), boolean chains 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/security/scanner.py"},"region":{"startLine":223}}}],"partialFingerprints":{"codehealthFindingId/v1":"da8376337b4cb5630e8791c9c8128c7006a82a77aa0820eac433e70e3d11ffc1"}},{"ruleId":"D2","level":"warning","message":{"text":"evidence_harness.rebuild_evidence (cognitive 18): evidence_harness.rebuild_evidence has cognitive complexity 18 (threshold 15). Drivers by points: if/else 7 (11 pts), ternaries 1 (3 pts), error handling 1 (2 pts), boolean chains 1, loops 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/strategy_discovery/evidence_harness.py"},"region":{"startLine":589}}}],"partialFingerprints":{"codehealthFindingId/v1":"e7436c2a0954e8edd7ac70dcd5be77a5df2160456f03cbc80fb95af075ec9a21"}},{"ruleId":"D2","level":"warning","message":{"text":"institutional_holdings_tool._information_table_urls (cognitive 18): institutional_holdings_tool._information_table_urls has cognitive complexity 18 (threshold 15). Drivers by points: boolean chains 7, if/else 4 (6 pts), error handling 1 (2 pts), ternaries 1 (2 pts), loops 1 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/institutional_holdings_tool.py"},"region":{"startLine":661}}}],"partialFingerprints":{"codehealthFindingId/v1":"a61cfd960a9137968bc7c2c9c029380f9ce7ae4ef14e7647cc18a9af5493f491"}},{"ruleId":"D2","level":"warning","message":{"text":"data_5m.fetch_five_minute (cognitive 18): data_5m.fetch_five_minute has cognitive complexity 18 (threshold 15). Drivers by points: if/else 8 (12 pts), error handling 2 (3 pts), boolean chains 2, loops 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/paper_trade/data_5m.py"},"region":{"startLine":460}}}],"partialFingerprints":{"codehealthFindingId/v1":"2e7dd649a259243468bf59fe134d0b9e77e1ff03d4b921d2b840736837603fe9"}},{"ruleId":"D2","level":"warning","message":{"text":"data_readiness._assess_five_minute_readiness (cognitive 18): data_readiness._assess_five_minute_readiness has cognitive complexity 18 (threshold 15). Drivers by points: if/else 11 (15 pts), boolean chains 3 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/paper_trade/data_readiness.py"},"region":{"startLine":83}}}],"partialFingerprints":{"codehealthFindingId/v1":"9ea32ebfe77c2406a1609c46cf50dbb70a5fd6f2803fc5dbc846a91ecee22705"}},{"ruleId":"D2","level":"warning","message":{"text":"tool._resolve_clients (cognitive 18): tool._resolve_clients has cognitive complexity 18 (threshold 15). Drivers by points: ternaries 6 (11 pts), if/else 6, boolean chains 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/paper_trade/tool.py"},"region":{"startLine":154}}}],"partialFingerprints":{"codehealthFindingId/v1":"9748ec2e4d4ee8c859dc90584099480c71be63834017cc620c675446af56b4c2"}},{"ruleId":"D2","level":"warning","message":{"text":"wire.received_state_hash_from_payload (cognitive 18): wire.received_state_hash_from_payload has cognitive complexity 18 (threshold 15). Drivers by points: if/else 9 (12 pts), error handling 3 (4 pts), boolean chains 1, loops 1 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/paper_trade/wire.py"},"region":{"startLine":152}}}],"partialFingerprints":{"codehealthFindingId/v1":"53a2dde2256d5b4deebae180703a2f175242213e7dfc23608bf3fc1bbeb8ec92"}},{"ruleId":"D2","level":"warning","message":{"text":"pdf_report.render_markdown_pdf (cognitive 18): pdf_report.render_markdown_pdf has cognitive complexity 18 (threshold 15). Drivers by points: if/else 7 (12 pts), loops 2 (4 pts), boolean chains 2 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/pdf_report.py"},"region":{"startLine":175}}}],"partialFingerprints":{"codehealthFindingId/v1":"6fc4f7674abcec32ec33b037f082efc9b3bdc5810cba6553498beff28eb28379"}},{"ruleId":"D2","level":"warning","message":{"text":"redaction.is_sensitive_arg (cognitive 18): redaction.is_sensitive_arg has cognitive complexity 18 (threshold 15). Drivers by points: boolean chains 9, if/else 6 (9 pts) (nesting depth added 3). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/redaction.py"},"region":{"startLine":284}}}],"partialFingerprints":{"codehealthFindingId/v1":"42111063c4c7c86bdeaeabdaa5232e28ad0001a58f90a9ebb7290116ed63f52f"}},{"ruleId":"D2","level":"warning","message":{"text":"technical_indicator_tool._extract_series (cognitive 18): technical_indicator_tool._extract_series has cognitive complexity 18 (threshold 15). Drivers by points: if/else 9 (11 pts), ternaries 2 (3 pts), boolean chains 2, error handling 1 (2 pts) (nesting depth added 4). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/technical_indicator_tool.py"},"region":{"startLine":47}}}],"partialFingerprints":{"codehealthFindingId/v1":"8d816d7ee3c2da4aee394180d0fd47e334133c16e17606c0e59b4beeb597c08e"}},{"ruleId":"D2","level":"warning","message":{"text":"sdk._first_rate (cognitive 18): sdk._first_rate has cognitive complexity 18 (threshold 15). Drivers by points: if/else 5 (9 pts), boolean chains 6, loops 2 (3 pts) (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/etoro/sdk.py"},"region":{"startLine":479}}}],"partialFingerprints":{"codehealthFindingId/v1":"2521b12e8a8c84fc9c112ec5d46150cd782a1f678a878ed60ea610fe8ea2145e"}},{"ruleId":"D2","level":"warning","message":{"text":"ui_services.load_chart_symbols (cognitive 18): ui_services.load_chart_symbols has cognitive complexity 18 (threshold 15). Drivers by points: if/else 6 (10 pts), boolean chains 4, error handling 1 (2 pts), loops 1 (2 pts) (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/ui_services.py"},"region":{"startLine":410}}}],"partialFingerprints":{"codehealthFindingId/v1":"47f86c49adc2eb05f7089261aa84d64648e1e1ca0bb6369073b772e0634858b9"}},{"ruleId":"D2","level":"warning","message":{"text":"sync_site_chrome.wiring_problems (cognitive 18): sync_site_chrome.wiring_problems has cognitive complexity 18 (threshold 15). Drivers by points: if/else 9 (13 pts), boolean chains 3, loops 1, ternaries 1 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"wiki/scripts/sync_site_chrome.py"},"region":{"startLine":124}}}],"partialFingerprints":{"codehealthFindingId/v1":"c8c3d0357ba2b4946dc87ebeec2679e3c5dbceab029e99211d2d7ac30109852a"}},{"ruleId":"D2","level":"warning","message":{"text":"ScheduledResearchProposalCard.ScheduledResearchProposalCard (cognitive 18): ScheduledResearchProposalCard.ScheduledResearchProposalCard has cognitive complexity 18 (threshold 15). Drivers by points: ternaries 6 (10 pts), boolean chains 6, error handling 1, if/else 1 (nesting depth added 4). Of this number, 14 points are the body\u0027s own statements and 4 belong to one function item inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/chat/ScheduledResearchProposalCard.tsx"},"region":{"startLine":19}}}],"partialFingerprints":{"codehealthFindingId/v1":"8c4165d57b349940f185bbe1b43e6c01b570256652f19cd5d9efaa26f72e4378"}},{"ruleId":"D2","level":"warning","message":{"text":"ThinkingTimeline.rebuildLegacyActivity (cognitive 18): ThinkingTimeline.rebuildLegacyActivity has cognitive complexity 18 (threshold 15). Drivers by points: ternaries 4 (7 pts), if/else 3 (6 pts), boolean chains 4, loops 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/chat/ThinkingTimeline.tsx"},"region":{"startLine":17}}}],"partialFingerprints":{"codehealthFindingId/v1":"68b2c12425c90e1342e734ff6ef8530221462eb561e5708c114e1ffa5ac2c822"}},{"ruleId":"D2","level":"warning","message":{"text":"positions.parsePositionsPanel (cognitive 18): positions.parsePositionsPanel has cognitive complexity 18 (threshold 15). Drivers by points: if/else 5 (13 pts), loops 3 (5 pts) (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/lib/positions.ts"},"region":{"startLine":75}}}],"partialFingerprints":{"codehealthFindingId/v1":"174e6124873c28911c159ba1a639fd35fe47aec5359eea09ba3d69bfa5623df2"}},{"ruleId":"D2","level":"warning","message":{"text":"main.initInstallTabs (cognitive 18): main.initInstallTabs has cognitive complexity 18 (threshold 15). Drivers by points: if/else 5 (11 pts), error handling 2 (4 pts), loops 2 (3 pts) (nesting depth added 9). Most of this is not in the body itself: 4 of the 18 points are its own statements and the rest belongs to one function literal inside it that branches (line 9). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"wiki/main.js"},"region":{"startLine":4}}}],"partialFingerprints":{"codehealthFindingId/v1":"4efb0a11e0d0890f706d8fe6faed0946e9fa54a961a043b02b2fb7c7742153ac"}},{"ruleId":"D2","level":"warning","message":{"text":"binance_account_reconciliation.snapshot_from_binance_usdm_observation (cognitive 17): binance_account_reconciliation.snapshot_from_binance_usdm_observation has cognitive complexity 17 (threshold 15). Drivers by points: if/else 13, boolean chains 2, error handling 1, ternaries 1. To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/binance_account_reconciliation.py"},"region":{"startLine":133}}}],"partialFingerprints":{"codehealthFindingId/v1":"248fbc740d5ebdaebb400b94a3887c4d67543424666f9a91e7a45f4887c94c1c"}},{"ruleId":"D2","level":"warning","message":{"text":"correlation.infer_market (cognitive 17): correlation.infer_market has cognitive complexity 17 (threshold 15). Drivers by points: if/else 14 (16 pts), boolean chains 1 (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/correlation.py"},"region":{"startLine":20}}}],"partialFingerprints":{"codehealthFindingId/v1":"f40bfebcd2edbea2c6a112632760e1b1f2517660d2facc2bee05e66cdff5424f"}},{"ruleId":"D2","level":"warning","message":{"text":"correlation._normalize_symbol (cognitive 17): correlation._normalize_symbol has cognitive complexity 17 (threshold 15). Drivers by points: if/else 12 (17 pts) (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/correlation.py"},"region":{"startLine":95}}}],"partialFingerprints":{"codehealthFindingId/v1":"72f3ee784d2f6c7de6039cc7dc7a3c2d68c24968c34b348a2d9d01dea3b74799"}},{"ruleId":"D2","level":"warning","message":{"text":"BaseEngine._record_dropped_target_adjustments (cognitive 17): BaseEngine._record_dropped_target_adjustments has cognitive complexity 17 (threshold 15). Drivers by points: if/else 5 (10 pts), ternaries 2 (4 pts), boolean chains 2, loops 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/engines/base.py"},"region":{"startLine":1749}}}],"partialFingerprints":{"codehealthFindingId/v1":"28cca6da745b1089c7b3c3c844517b16294b2ec06de3c9d778ca569eb74a089e"}},{"ruleId":"D2","level":"warning","message":{"text":"base.evaluation_start_index (cognitive 17): base.evaluation_start_index has cognitive complexity 17 (threshold 15). Drivers by points: if/else 8 (11 pts), boolean chains 4, error handling 1 (2 pts) (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/engines/base.py"},"region":{"startLine":176}}}],"partialFingerprints":{"codehealthFindingId/v1":"de36b5ac3ad24d55c5546e71473b86c8bb9735231d7762ce35e0fc2a025464e3"}},{"ruleId":"D2","level":"warning","message":{"text":"ccxt_loader._validate_bracket_artifact (cognitive 17): ccxt_loader._validate_bracket_artifact has cognitive complexity 17 (threshold 15). Drivers by points: if/else 8 (9 pts), error handling 3 (6 pts), boolean chains 1, loops 1 (nesting depth added 4). To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/ccxt_loader.py"},"region":{"startLine":114}}}],"partialFingerprints":{"codehealthFindingId/v1":"6a3e7acdb4e4a5f5a417572fe064644c287aa42105e94db0e06e7285a5ead99e"}},{"ruleId":"D2","level":"warning","message":{"text":"fmp_loader._parse_historical (cognitive 17): fmp_loader._parse_historical has cognitive complexity 17 (threshold 15). Drivers by points: if/else 10 (11 pts), ternaries 2 (3 pts), loops 2, boolean chains 1 (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/fmp_loader.py"},"region":{"startLine":220}}}],"partialFingerprints":{"codehealthFindingId/v1":"f2e85809e5049a7e14911b5dd3d36f17ceb252e4d64c0cf0c88e3234725db0d3"}},{"ruleId":"D2","level":"warning","message":{"text":"DataLoader.fetch (cognitive 17): DataLoader.fetch has cognitive complexity 17 (threshold 15). Drivers by points: error handling 3 (7 pts), if/else 5 (7 pts), boolean chains 2, loops 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/india_broker_loader.py"},"region":{"startLine":144}}}],"partialFingerprints":{"codehealthFindingId/v1":"5c1a65da638bb58a2231448098a5699bc9ef5fea9fec8fcab1f9281a3052c1db"}},{"ruleId":"D2","level":"warning","message":{"text":"local_loader._normalize_columns (cognitive 17): local_loader._normalize_columns has cognitive complexity 17 (threshold 15). Drivers by points: if/else 11 (14 pts), loops 3 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/local_loader.py"},"region":{"startLine":182}}}],"partialFingerprints":{"codehealthFindingId/v1":"4d6101f6c08a54b7f8bc04922f78252d20cc3ef7ef0b0d1b7a10cea9f5b9d715"}},{"ruleId":"D2","level":"warning","message":{"text":"DataLoader._paginate (cognitive 17): DataLoader._paginate has cognitive complexity 17 (threshold 15). Drivers by points: if/else 5 (8 pts), boolean chains 3, loops 3, ternaries 2 (3 pts) (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/okx.py"},"region":{"startLine":292}}}],"partialFingerprints":{"codehealthFindingId/v1":"a06cdd303739ae996f87876d0a80a0f70ce76502e45172dd9586044272b8be21"}},{"ruleId":"D2","level":"warning","message":{"text":"registry.refresh_source_order_overrides (cognitive 17): registry.refresh_source_order_overrides has cognitive complexity 17 (threshold 15). Drivers by points: if/else 6 (11 pts), boolean chains 3, ternaries 1 (2 pts), loops 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/registry.py"},"region":{"startLine":539}}}],"partialFingerprints":{"codehealthFindingId/v1":"281495475cbaca727158b8c48ed3b0d30e74e03bed4185033c39c0c5dd50ef3c"}},{"ruleId":"D2","level":"warning","message":{"text":"valuation_loader._load_baostock_valuation (cognitive 17): valuation_loader._load_baostock_valuation has cognitive complexity 17 (threshold 15). Drivers by points: if/else 6 (11 pts), loops 3 (4 pts), error handling 1 (2 pts) (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/valuation_loader.py"},"region":{"startLine":172}}}],"partialFingerprints":{"codehealthFindingId/v1":"a44403dcf38c22bf7edbd76cac44cacc8047851fc8ea4e4c35e81e8e94eb2f76"}},{"ruleId":"D2","level":"warning","message":{"text":"metrics.win_rate_and_stats (cognitive 17): metrics.win_rate_and_stats has cognitive complexity 17 (threshold 15). Drivers by points: ternaries 9, if/else 6 (7 pts), loops 1 (nesting depth added 1). To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/metrics.py"},"region":{"startLine":386}}}],"partialFingerprints":{"codehealthFindingId/v1":"5c1a4fc26ac49ac8fc7f943804ecd6acd3a4f625bbb50ddb8adc2006584ce6f9"}},{"ruleId":"D2","level":"warning","message":{"text":"BaseOptimizer.optimize (cognitive 17): BaseOptimizer.optimize has cognitive complexity 17 (threshold 15). Drivers by points: if/else 7 (13 pts), loops 2 (3 pts), boolean chains 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/optimizers/base.py"},"region":{"startLine":36}}}],"partialFingerprints":{"codehealthFindingId/v1":"2e00e82898fbc38a2f3f33e2ea07061803a9f0fea557726c368320bb2e9cad2c"}},{"ruleId":"D2","level":"warning","message":{"text":"risk_xray.compute_risk_xray (cognitive 17): risk_xray.compute_risk_xray has cognitive complexity 17 (threshold 15). Drivers by points: if/else 11 (15 pts), boolean chains 1, loops 1 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/risk_xray.py"},"region":{"startLine":94}}}],"partialFingerprints":{"codehealthFindingId/v1":"c2a83831e662b39b89c9dfca69d028f034b7cfca65a99c915bd2ee7d7f70f533"}},{"ruleId":"D2","level":"warning","message":{"text":"validation.monte_carlo_test (cognitive 17): validation.monte_carlo_test has cognitive complexity 17 (threshold 15). Drivers by points: if/else 9 (13 pts), boolean chains 2, loops 1, ternaries 1 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/validation.py"},"region":{"startLine":33}}}],"partialFingerprints":{"codehealthFindingId/v1":"fe7c6eeb87fb69dd55e9a70ce3e034d164ac6367a2017ad7a2c744969eb4d254"}},{"ruleId":"D2","level":"warning","message":{"text":"_legacy.cmd_swarm_show (cognitive 17): _legacy.cmd_swarm_show has cognitive complexity 17 (threshold 15). Drivers by points: if/else 7 (9 pts), ternaries 3 (6 pts), boolean chains 1, loops 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":2827}}}],"partialFingerprints":{"codehealthFindingId/v1":"4b729b331543831d4be2ab888b34359713a8a22e0da495071fdcf72584f1bf20"}},{"ruleId":"D2","level":"warning","message":{"text":"_legacy._print_channels_status (cognitive 17): _legacy._print_channels_status has cognitive complexity 17 (threshold 15). Drivers by points: ternaries 6 (11 pts), if/else 3 (4 pts), boolean chains 1, loops 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":3220}}}],"partialFingerprints":{"codehealthFindingId/v1":"3cfceb486b6c8aeb8debc83a9888e28dd8b9cdd93c42e62c8fc887c11fde5fb9"}},{"ruleId":"D2","level":"warning","message":{"text":"_legacy._handle_prompt_command (cognitive 17): _legacy._handle_prompt_command has cognitive complexity 17 (threshold 15). Drivers by points: ternaries 3 (9 pts), if/else 6 (8 pts) (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":5817}}}],"partialFingerprints":{"codehealthFindingId/v1":"2f0c03d7df14870200328785a31a1f3e1665f50c8b942839d96efe41e4b9873b"}},{"ruleId":"D2","level":"warning","message":{"text":"RailRunDashboard._active_step (cognitive 17): RailRunDashboard._active_step has cognitive complexity 17 (threshold 15). Drivers by points: if/else 4 (8 pts), boolean chains 5, loops 2 (4 pts) (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/ui/rail.py"},"region":{"startLine":463}}}],"partialFingerprints":{"codehealthFindingId/v1":"c4f77042601b5cfb622fb3b5606149e76ade1d2c15187123c8b81212b27e2b3f"}},{"ruleId":"D2","level":"warning","message":{"text":"_PolicyMixin._unknown_call_field_ref_candidates (cognitive 17): _PolicyMixin._unknown_call_field_ref_candidates has cognitive complexity 17 (threshold 15). Drivers by points: if/else 5 (7 pts), boolean chains 6, loops 2, ternaries 2 (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/grounding/policies.py"},"region":{"startLine":1362}}}],"partialFingerprints":{"codehealthFindingId/v1":"119d3146633fcab530c7e0cb98efffec606f019336685f73c01457fe3086202c"}},{"ruleId":"D2","level":"warning","message":{"text":"policies._records_at (cognitive 17): policies._records_at has cognitive complexity 17 (threshold 15). Drivers by points: if/else 7, boolean chains 6, error handling 2 (3 pts), ternaries 1 (nesting depth added 1). To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/grounding/policies.py"},"region":{"startLine":2664}}}],"partialFingerprints":{"codehealthFindingId/v1":"da6affcde725bb6533d22246824b362ed2b4dde3a736875a208cffca750452d1"}},{"ruleId":"D2","level":"warning","message":{"text":"HarnessCase.from_dict (cognitive 17): HarnessCase.from_dict has cognitive complexity 17 (threshold 15). Drivers by points: if/else 10 (12 pts), boolean chains 5 (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/harness/schema.py"},"region":{"startLine":33}}}],"partialFingerprints":{"codehealthFindingId/v1":"3d041ca9c1bc013336a20d590d922d0eff87ca069e4d979db8f3d4dd9f765b16"}},{"ruleId":"D2","level":"warning","message":{"text":"skills.split_sections (cognitive 17): skills.split_sections has cognitive complexity 17 (threshold 15). Drivers by points: if/else 4 (12 pts), loops 3 (4 pts), boolean chains 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/agent/skills.py"},"region":{"startLine":230}}}],"partialFingerprints":{"codehealthFindingId/v1":"970fd1a2efa69b8753ff6f4b55cc2f412eb0f7e661926085b643cc2d489c7c31"}},{"ruleId":"D2","level":"warning","message":{"text":"tool_results._archive_backtest_result (cognitive 17): tool_results._archive_backtest_result has cognitive complexity 17 (threshold 15). Drivers by points: if/else 7 (11 pts), loops 3, error handling 2, boolean chains 1 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/agent/tool_results.py"},"region":{"startLine":185}}}],"partialFingerprints":{"codehealthFindingId/v1":"e2d348f6de44632bfe784488b6346d17c7c3401e418483ff73b78e6e12fa30e3"}},{"ruleId":"D2","level":"warning","message":{"text":"attribution_core._attribution_factor_section (cognitive 17): attribution_core._attribution_factor_section has cognitive complexity 17 (threshold 15). Drivers by points: if/else 7 (10 pts), loops 3 (4 pts), boolean chains 2, ternaries 1 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/api/attribution_core.py"},"region":{"startLine":361}}}],"partialFingerprints":{"codehealthFindingId/v1":"32ab3a887d254b12a960d127d08f4d8508a2a20a0549e6485fa8d21f35972e1e"}},{"ruleId":"D2","level":"warning","message":{"text":"cvm_companies.parse_statement (cognitive 17): cvm_companies.parse_statement has cognitive complexity 17 (threshold 15). Drivers by points: if/else 4 (8 pts), boolean chains 6, ternaries 1 (2 pts), loops 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/br_data/cvm_companies.py"},"region":{"startLine":81}}}],"partialFingerprints":{"codehealthFindingId/v1":"aab3d3bf204e3aa3fccd3f9a5d60455f45a588ccf4d742d8c6813f5630cd29f7"}},{"ruleId":"D2","level":"warning","message":{"text":"SlackChannel._resolve_user_handle (cognitive 17): SlackChannel._resolve_user_handle has cognitive complexity 17 (threshold 15). Drivers by points: if/else 5 (11 pts), boolean chains 3, loops 2 (3 pts) (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/slack.py"},"region":{"startLine":284}}}],"partialFingerprints":{"codehealthFindingId/v1":"4cd70618c813859f3f911be22afd73901b4c484fa6e00a1137370026471db66f"}},{"ruleId":"D2","level":"warning","message":{"text":"TelegramChannel._try_send_rich (cognitive 17): TelegramChannel._try_send_rich has cognitive complexity 17 (threshold 15). Drivers by points: if/else 10 (14 pts), error handling 2, boolean chains 1 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/telegram.py"},"region":{"startLine":695}}}],"partialFingerprints":{"codehealthFindingId/v1":"ca6a4af3dbe71af67beb0a7ab1a3a8c1ae13b42930e102a2fa92c0b5d244f160"}},{"ruleId":"D2","level":"warning","message":{"text":"HistoryStore.status (cognitive 17): HistoryStore.status has cognitive complexity 17 (threshold 15). Drivers by points: if/else 5 (7 pts), boolean chains 5, loops 2 (3 pts), ternaries 1 (2 pts) (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/data_gateway/history_store.py"},"region":{"startLine":372}}}],"partialFingerprints":{"codehealthFindingId/v1":"810f6d742525ed49041a546af20244803272784d5174c32ebe6ea8afcd7cc1c4"}},{"ruleId":"D2","level":"warning","message":{"text":"ingest._resolve_columns (cognitive 17): ingest._resolve_columns has cognitive complexity 17 (threshold 15). Drivers by points: if/else 5 (12 pts), loops 3 (5 pts) (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body. This shape REPEATS in the file: one other method here (ingest._resolve_panel_long_columns) has the same decision points, in the same order, at the same nesting depths \u2014 so this is one pattern written twice rather than two separate problems. Splitting this body alone leaves the other exactly as it is. Where these are variations on one operation, the change that clears both is the shared one: lift the common shape into a single routine the variants call, parameterised by whatever genuinely differs between them, and keep in each method only the part that is not shared."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/entities/ingest.py"},"region":{"startLine":89}}}],"partialFingerprints":{"codehealthFindingId/v1":"8e6da010f71ecc775e112e5280736341bc8200f619026243aeed6f4cc3f9e1d0"}},{"ruleId":"D2","level":"warning","message":{"text":"ingest._resolve_panel_long_columns (cognitive 17): ingest._resolve_panel_long_columns has cognitive complexity 17 (threshold 15). Drivers by points: if/else 5 (12 pts), loops 3 (5 pts) (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body. This shape REPEATS in the file: one other method here (ingest._resolve_columns) has the same decision points, in the same order, at the same nesting depths \u2014 so this is one pattern written twice rather than two separate problems. Splitting this body alone leaves the other exactly as it is. Where these are variations on one operation, the change that clears both is the shared one: lift the common shape into a single routine the variants call, parameterised by whatever genuinely differs between them, and keep in each method only the part that is not shared."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/entities/ingest.py"},"region":{"startLine":743}}}],"partialFingerprints":{"codehealthFindingId/v1":"3222e34b30ede0827c2f517f7ed030f0c86922bef52a9e5089775052c6258c8c"}},{"ruleId":"D2","level":"warning","message":{"text":"flatten._flatten_open_positions (cognitive 17): flatten._flatten_open_positions has cognitive complexity 17 (threshold 15). Drivers by points: if/else 6 (11 pts), error handling 1 (2 pts), ternaries 1 (2 pts), boolean chains 1, loops 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/live/runtime/flatten.py"},"region":{"startLine":321}}}],"partialFingerprints":{"codehealthFindingId/v1":"02f77f6f4eaf3c53a59f23a6567820aecf42551045d5702441c54de5e4785515"}},{"ruleId":"D2","level":"warning","message":{"text":"normalization.account_cash_usd (cognitive 17): normalization.account_cash_usd has cognitive complexity 17 (threshold 15). Drivers by points: if/else 5 (8 pts), boolean chains 5, loops 1 (2 pts), ternaries 2 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/portfolio/normalization.py"},"region":{"startLine":337}}}],"partialFingerprints":{"codehealthFindingId/v1":"864a0d95dd4a1ce0ee5d1ce31e48f49fd3d5cbef801b36c04d65612a0592752c"}},{"ruleId":"D2","level":"warning","message":{"text":"discovery._list_provider_models (cognitive 17): discovery._list_provider_models has cognitive complexity 17 (threshold 15). Drivers by points: if/else 9 (11 pts), boolean chains 4, error handling 1, ternaries 1 (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/providers/discovery.py"},"region":{"startLine":201}}}],"partialFingerprints":{"codehealthFindingId/v1":"897d7fc0ca2f62fb2ef7c78301c95305a77f4eafb237a231855cb6c2e7099035"}},{"ruleId":"D2","level":"warning","message":{"text":"openai_codex._convert_user_message (cognitive 17): openai_codex._convert_user_message has cognitive complexity 17 (threshold 15). Drivers by points: if/else 6 (14 pts), loops 1 (2 pts), boolean chains 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/providers/openai_codex.py"},"region":{"startLine":438}}}],"partialFingerprints":{"codehealthFindingId/v1":"1de288863a02fd44cb0ce769d9a1f4e40d027c2669f62442890dfbb0d8b0dfb8"}},{"ruleId":"D2","level":"warning","message":{"text":"registry.get_provider_capabilities (cognitive 17): registry.get_provider_capabilities has cognitive complexity 17 (threshold 15). Drivers by points: if/else 7 (12 pts), boolean chains 4, loops 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/providers/registry.py"},"region":{"startLine":189}}}],"partialFingerprints":{"codehealthFindingId/v1":"e63d113154670beebd4372b32986057dff274f1bd93dc9f01ed4db31efe76951"}},{"ruleId":"D2","level":"warning","message":{"text":"playbooks.load_playbook_file (cognitive 17): playbooks.load_playbook_file has cognitive complexity 17 (threshold 15). Drivers by points: if/else 8, boolean chains 6, error handling 2, ternaries 1. To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/scheduled_research/playbooks.py"},"region":{"startLine":275}}}],"partialFingerprints":{"codehealthFindingId/v1":"4dce0730b7cdf334153c1370ecfe6bb24f1c9980a3e8623481d0f7fddac98760"}},{"ruleId":"D2","level":"warning","message":{"text":"backtester.run_shadow_backtest (cognitive 17): backtester.run_shadow_backtest has cognitive complexity 17 (threshold 15). Drivers by points: if/else 5 (6 pts), loops 4 (6 pts), boolean chains 3, ternaries 2 (nesting depth added 3). To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/shadow_account/backtester.py"},"region":{"startLine":164}}}],"partialFingerprints":{"codehealthFindingId/v1":"76203ba0e9a60af89e81fb76e6e7b53b35e6b8e14f5d25bb299f1f8b769d69be"}},{"ruleId":"D2","level":"warning","message":{"text":"pdf_fallback.render_pdf_reportlab (cognitive 17): pdf_fallback.render_pdf_reportlab has cognitive complexity 17 (threshold 15). Drivers by points: if/else 15, boolean chains 1, loops 1. To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/shadow_account/pdf_fallback.py"},"region":{"startLine":72}}}],"partialFingerprints":{"codehealthFindingId/v1":"651816d5e18dd5167132d9ba99e4f75aed7f6b3a383fb31d1fcb2070e80a283d"}},{"ruleId":"D2","level":"warning","message":{"text":"SignalEngine.generate (cognitive 17): SignalEngine.generate has cognitive complexity 17 (threshold 15). Drivers by points: if/else 5 (11 pts), loops 3 (5 pts), boolean chains 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/skills/event-driven/example_signal_engine.py"},"region":{"startLine":39}}}],"partialFingerprints":{"codehealthFindingId/v1":"1d478007ec7cb992b32a2cdb1b0cec76e484ca78188ade1ce5a4573d9f1440fe"}},{"ruleId":"D2","level":"warning","message":{"text":"run_artifacts.read_equity_series (cognitive 17): run_artifacts.read_equity_series has cognitive complexity 17 (threshold 15). Drivers by points: if/else 4 (6 pts), ternaries 3 (5 pts), boolean chains 4, error handling 1, loops 1 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/strategy_discovery/run_artifacts.py"},"region":{"startLine":235}}}],"partialFingerprints":{"codehealthFindingId/v1":"8506683a39f6f6d206526fd3f4ede8db6aef3f870f3f9afb159a8bb72ecd15aa"}},{"ruleId":"D2","level":"warning","message":{"text":"SwarmRuntime._run_worker_with_retries (cognitive 17): SwarmRuntime._run_worker_with_retries has cognitive complexity 17 (threshold 15). Drivers by points: if/else 6 (13 pts), ternaries 1 (3 pts), loops 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/swarm/runtime.py"},"region":{"startLine":1178}}}],"partialFingerprints":{"codehealthFindingId/v1":"59f06bca09d5592493fddc3750c7983668bf2ff323f5a91169e48dd63c2a62ae"}},{"ruleId":"D2","level":"warning","message":{"text":"mcp.compact_result_for_agent (cognitive 17): mcp.compact_result_for_agent has cognitive complexity 17 (threshold 15). Drivers by points: if/else 8 (14 pts), boolean chains 3 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/mcp.py"},"region":{"startLine":1255}}}],"partialFingerprints":{"codehealthFindingId/v1":"67ac86c9d00cc310dfd3b4ad0734b0f72097b6183341bec25c460074b71bce66"}},{"ruleId":"D2","level":"warning","message":{"text":"data._resolve_network_loader (cognitive 17): data._resolve_network_loader has cognitive complexity 17 (threshold 15). Drivers by points: if/else 5 (9 pts), boolean chains 4, error handling 2 (3 pts), loops 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/paper_trade/data.py"},"region":{"startLine":269}}}],"partialFingerprints":{"codehealthFindingId/v1":"b79d203388b64c6ed83428bd61a1918c3fcc5203d692f79640f927b53484a2ea"}},{"ruleId":"D2","level":"warning","message":{"text":"strategy_exec.run_strategy_path (cognitive 17): strategy_exec.run_strategy_path has cognitive complexity 17 (threshold 15). Drivers by points: if/else 6, error handling 3 (5 pts), ternaries 3 (5 pts), boolean chains 1 (nesting depth added 4). To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/paper_trade/strategy_exec.py"},"region":{"startLine":504}}}],"partialFingerprints":{"codehealthFindingId/v1":"98a13a742291b4003881a556c469681317b3b61c3bbfb2225b8b11e25f86158e"}},{"ruleId":"D2","level":"warning","message":{"text":"pattern_tool.double_top_bottom (cognitive 17): pattern_tool.double_top_bottom has cognitive complexity 17 (threshold 15). Drivers by points: if/else 5 (11 pts), boolean chains 4, loops 2 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/pattern_tool.py"},"region":{"startLine":201}}}],"partialFingerprints":{"codehealthFindingId/v1":"d704b739dcb851317de87a2e56337fc85d0834a1187ffb630c604277d78eb389"}},{"ruleId":"D2","level":"warning","message":{"text":"pattern_tool.run_pattern (cognitive 17): pattern_tool.run_pattern has cognitive complexity 17 (threshold 15). Drivers by points: if/else 8 (11 pts), loops 2 (3 pts), error handling 2, boolean chains 1 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/pattern_tool.py"},"region":{"startLine":331}}}],"partialFingerprints":{"codehealthFindingId/v1":"4820e5aede45f5ae5a7aae9cdd471d13bafa423e0f83e249ef955e08fe4f12a1"}},{"ruleId":"D2","level":"warning","message":{"text":"trade_journal_parsers._ths_datetime (cognitive 17): trade_journal_parsers._ths_datetime has cognitive complexity 17 (threshold 15). Drivers by points: if/else 7 (11 pts), boolean chains 4, error handling 1 (2 pts) (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/trade_journal_parsers.py"},"region":{"startLine":380}}}],"partialFingerprints":{"codehealthFindingId/v1":"11fa72900ffe13bd96d976d47999a8690d5732c58654dcd2bc441feb44cdcc72"}},{"ruleId":"D2","level":"warning","message":{"text":"trade_journal_tool._apply_filter (cognitive 17): trade_journal_tool._apply_filter has cognitive complexity 17 (threshold 15). Drivers by points: if/else 5 (7 pts), ternaries 3 (6 pts), error handling 2 (4 pts) (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/trade_journal_tool.py"},"region":{"startLine":597}}}],"partialFingerprints":{"codehealthFindingId/v1":"9c4760f50269f50becec46869576c038b4b44df56c72c40f5e629e1f589a6ceb"}},{"ruleId":"D2","level":"warning","message":{"text":"sdk.search_instruments (cognitive 17): sdk.search_instruments has cognitive complexity 17 (threshold 15). Drivers by points: if/else 6 (10 pts), boolean chains 5, error handling 1, loops 1 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/binance/sdk.py"},"region":{"startLine":421}}}],"partialFingerprints":{"codehealthFindingId/v1":"4134c8d4ba0bf57181a72c4d86e258a31010919e960c924d814715dd90e655f3"}},{"ruleId":"D2","level":"warning","message":{"text":"instruments._rates_by_instrument_id (cognitive 17): instruments._rates_by_instrument_id has cognitive complexity 17 (threshold 15). Drivers by points: if/else 4 (8 pts), boolean chains 4, loops 2 (3 pts), error handling 1 (2 pts) (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/etoro/instruments.py"},"region":{"startLine":458}}}],"partialFingerprints":{"codehealthFindingId/v1":"8289ec6ac2d8fe0c063bbc8374ad1489168a24ad13771c387ca1739fdeedc528"}},{"ruleId":"D2","level":"warning","message":{"text":"sdk._normalize_candles (cognitive 17): sdk._normalize_candles has cognitive complexity 17 (threshold 15). Drivers by points: if/else 5 (11 pts), loops 2 (4 pts), boolean chains 2 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/etoro/sdk.py"},"region":{"startLine":508}}}],"partialFingerprints":{"codehealthFindingId/v1":"2e32ba395d3e046d92bb53bb50a1ad08504812a7b070a57ccc664d65b5c35fbf"}},{"ruleId":"D2","level":"warning","message":{"text":"sdk.get_open_orders (cognitive 17): sdk.get_open_orders has cognitive complexity 17 (threshold 15). Drivers by points: if/else 4 (7 pts), boolean chains 4, loops 3 (4 pts), error handling 1 (2 pts) (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/kis/sdk.py"},"region":{"startLine":318}}}],"partialFingerprints":{"codehealthFindingId/v1":"c8a6cab054123c633c99f1d052e0b6d3804916234eb436ebe0a8f1441597b98f"}},{"ruleId":"D2","level":"warning","message":{"text":"sdk.cancel_order (cognitive 17): sdk.cancel_order has cognitive complexity 17 (threshold 15). Drivers by points: boolean chains 7, if/else 5, ternaries 5. To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/kis/sdk.py"},"region":{"startLine":562}}}],"partialFingerprints":{"codehealthFindingId/v1":"87a7ac39c5b93c2e48c5dd4afe1d347e3b86ed34d16b04f9f4ceaaf244e8d939"}},{"ruleId":"D2","level":"warning","message":{"text":"service._sdk_config (cognitive 17): service._sdk_config has cognitive complexity 17 (threshold 15). Drivers by points: if/else 10 (11 pts), boolean chains 4, error handling 1, ternaries 1 (nesting depth added 1). To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/service.py"},"region":{"startLine":82}}}],"partialFingerprints":{"codehealthFindingId/v1":"f6dbd4508fc0e30ff10d36026f9bbe364738a0db8e65af1a56e365252e249a6e"}},{"ruleId":"D2","level":"warning","message":{"text":"ConfirmDialog.ConfirmDialog (cognitive 17): ConfirmDialog.ConfirmDialog has cognitive complexity 17 (threshold 15). Drivers by points: if/else 9, boolean chains 6, ternaries 2. Most of this is not in the body itself: 4 of the 17 points are its own statements and the rest belongs to 3 function literals inside it that branch (lines 48, 42, 78). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/common/ConfirmDialog.tsx"},"region":{"startLine":25}}}],"partialFingerprints":{"codehealthFindingId/v1":"32bf6c4e6aa32ff2f19143c2c8a268c93490f1a76596dd1f76665f6ea5fd6ce7"}},{"ruleId":"D2","level":"warning","message":{"text":"RunDetail.StudioTab (cognitive 17): RunDetail.StudioTab has cognitive complexity 17 (threshold 15). Drivers by points: boolean chains 17. To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/RunDetail.tsx"},"region":{"startLine":622}}}],"partialFingerprints":{"codehealthFindingId/v1":"a2cce31f277dbffa4248b7ac38bfad3e58c515b74c92b0afc40b93c971768912"}},{"ruleId":"D2","level":"warning","message":{"text":"ArgentinaEquityEngine.__init__ (cognitive 16): ArgentinaEquityEngine.__init__ has cognitive complexity 16 (threshold 15). Drivers by points: if/else 9 (11 pts), boolean chains 3, loops 2 (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/engines/argentina_equity.py"},"region":{"startLine":389}}}],"partialFingerprints":{"codehealthFindingId/v1":"a74d2cba55a52697a8c12ced07ba90d91ae5bfd44ea7991c5df385fa78c5bf10"}},{"ruleId":"D2","level":"warning","message":{"text":"BaseEngine._weighted_holding_bars (cognitive 16): BaseEngine._weighted_holding_bars has cognitive complexity 16 (threshold 15). Drivers by points: if/else 6 (11 pts), loops 3 (4 pts), boolean chains 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/engines/base.py"},"region":{"startLine":2346}}}],"partialFingerprints":{"codehealthFindingId/v1":"b87dce16ff9e4c7eb2ec9449299adbe40ccf70efceb7ab85922872610e7b6d7b"}},{"ruleId":"D2","level":"warning","message":{"text":"factor_costs.rebalance_cost (cognitive 16): factor_costs.rebalance_cost has cognitive complexity 16 (threshold 15). Drivers by points: if/else 6 (7 pts), ternaries 4 (7 pts), boolean chains 2 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/factor_costs.py"},"region":{"startLine":297}}}],"partialFingerprints":{"codehealthFindingId/v1":"393d2ef01ebf377aa044996fbd763b86b52deb29d13b430b3d34c899b5e002e1"}},{"ruleId":"D2","level":"warning","message":{"text":"frozen.load_frozen_frames (cognitive 16): frozen.load_frozen_frames has cognitive complexity 16 (threshold 15). Drivers by points: if/else 8 (14 pts), boolean chains 1, loops 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/frozen.py"},"region":{"startLine":15}}}],"partialFingerprints":{"codehealthFindingId/v1":"45c693b3270b96213c6ba24de6ac0fbf412a32ff7e417b5cfa38a2370ad25a7a"}},{"ruleId":"D2","level":"warning","message":{"text":"loader_health.check_frame (cognitive 16): loader_health.check_frame has cognitive complexity 16 (threshold 15). Drivers by points: if/else 10, boolean chains 6. To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loader_health.py"},"region":{"startLine":147}}}],"partialFingerprints":{"codehealthFindingId/v1":"35bfb97e66bc8516b38a5df797d35997ab985651ad2fc9f577a491cc91cac2ae"}},{"ruleId":"D2","level":"warning","message":{"text":"gildata_codes.resolve_vendor_code (cognitive 16): gildata_codes.resolve_vendor_code has cognitive complexity 16 (threshold 15). Drivers by points: if/else 9 (10 pts), ternaries 1 (3 pts), boolean chains 2, error handling 1 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/gildata_codes.py"},"region":{"startLine":89}}}],"partialFingerprints":{"codehealthFindingId/v1":"5b38b7362485594793a02537aefcd518ec240fbb6e2038e9dcbc5cdeb2a2a96c"}},{"ruleId":"D2","level":"warning","message":{"text":"rsshub_events.enrich_price_frames_with_events (cognitive 16): rsshub_events.enrich_price_frames_with_events has cognitive complexity 16 (threshold 15). Drivers by points: if/else 5 (9 pts), loops 3 (6 pts), boolean chains 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/rsshub_events.py"},"region":{"startLine":528}}}],"partialFingerprints":{"codehealthFindingId/v1":"e369aeba30a3fa77ec5cd9102d8c53f1e312dcd5b0dcf3d8ffcb206f9641523a"}},{"ruleId":"D2","level":"warning","message":{"text":"options_payoff._validate_legs (cognitive 16): options_payoff._validate_legs has cognitive complexity 16 (threshold 15). Drivers by points: if/else 6 (11 pts), boolean chains 4, loops 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/options_payoff.py"},"region":{"startLine":77}}}],"partialFingerprints":{"codehealthFindingId/v1":"9251222f7b8fcd0adbfef7f01ed930c4293c2d35c4342a35efc3f8ae8e6c6eae"}},{"ruleId":"D2","level":"warning","message":{"text":"perpetual_risk._position_risks (cognitive 16): perpetual_risk._position_risks has cognitive complexity 16 (threshold 15). Drivers by points: if/else 7 (11 pts), boolean chains 2, ternaries 1 (2 pts), loops 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/perpetual_risk.py"},"region":{"startLine":284}}}],"partialFingerprints":{"codehealthFindingId/v1":"c385789cdebe99042d6c511f83f7382c5ef6b709c6e2bddcf511e9c5c39dc9bc"}},{"ruleId":"D2","level":"warning","message":{"text":"run_card.write_run_card (cognitive 16): run_card.write_run_card has cognitive complexity 16 (threshold 15). Drivers by points: if/else 10 (12 pts), boolean chains 3, ternaries 1 (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/run_card.py"},"region":{"startLine":168}}}],"partialFingerprints":{"codehealthFindingId/v1":"e134a13071adb2b7ae4124625816c585b2737777662e618ee215f4278ab89ae0"}},{"ruleId":"D2","level":"warning","message":{"text":"run_card._normalize_tool_traces (cognitive 16): run_card._normalize_tool_traces has cognitive complexity 16 (threshold 15). Drivers by points: if/else 5 (11 pts), loops 2 (3 pts), boolean chains 2 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/run_card.py"},"region":{"startLine":423}}}],"partialFingerprints":{"codehealthFindingId/v1":"a886498ab56008974d18db32989728159abe6d60ad29720508976bc747e934fb"}},{"ruleId":"D2","level":"warning","message":{"text":"runner._validate_signal_engine_source (cognitive 16): runner._validate_signal_engine_source has cognitive complexity 16 (threshold 15). Drivers by points: if/else 6 (12 pts), boolean chains 2, error handling 1, loops 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/runner.py"},"region":{"startLine":819}}}],"partialFingerprints":{"codehealthFindingId/v1":"1844c15edd3de7361dfd3d4931f69a40bc21a0f53c718469c39ec72e4b0d6a50"}},{"ruleId":"D2","level":"warning","message":{"text":"validation.bootstrap_sharpe_ci (cognitive 16): validation.bootstrap_sharpe_ci has cognitive complexity 16 (threshold 15). Drivers by points: if/else 9, boolean chains 6, loops 1. To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/validation.py"},"region":{"startLine":152}}}],"partialFingerprints":{"codehealthFindingId/v1":"c4261dde0609190ce4540b6420885b06d0b37fbb9616e5f22c0fc27160453b97"}},{"ruleId":"D2","level":"warning","message":{"text":"_legacy._build_benchmark_table (cognitive 16): _legacy._build_benchmark_table has cognitive complexity 16 (threshold 15). Drivers by points: if/else 7, ternaries 3 (5 pts), boolean chains 2, error handling 1 (2 pts) (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":1351}}}],"partialFingerprints":{"codehealthFindingId/v1":"78e2d1d58ed56c595716cbc9c9426f1b8745e916a2a563b848d5ddb0b5a198b1"}},{"ruleId":"D2","level":"warning","message":{"text":"main._print_interactive_result (cognitive 16): main._print_interactive_result has cognitive complexity 16 (threshold 15). Drivers by points: ternaries 3 (7 pts), if/else 3 (5 pts), boolean chains 2, loops 1 (2 pts) (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/main.py"},"region":{"startLine":784}}}],"partialFingerprints":{"codehealthFindingId/v1":"188682abcde09f0df5685931f74027c6dcb0247ab89f0a3a8050213ae0cea123"}},{"ruleId":"D2","level":"warning","message":{"text":"figures._writes_decimal_commas (cognitive 16): figures._writes_decimal_commas has cognitive complexity 16 (threshold 15). Drivers by points: boolean chains 10, if/else 2 (5 pts), loops 1 (nesting depth added 3). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/grounding/figures.py"},"region":{"startLine":610}}}],"partialFingerprints":{"codehealthFindingId/v1":"e4034b46afc5e9123c8546eec8fe7894708b765d8e17637cc1598a029c2086df"}},{"ruleId":"D2","level":"warning","message":{"text":"assertions._evidence_verdicts (cognitive 16): assertions._evidence_verdicts has cognitive complexity 16 (threshold 15). Drivers by points: if/else 6, boolean chains 5, ternaries 5. To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/harness/assertions.py"},"region":{"startLine":456}}}],"partialFingerprints":{"codehealthFindingId/v1":"f1dc40bc94e0a25e52c9691b9c2c881eed902830b3e1f42d88f916990acc0b0f"}},{"ruleId":"D2","level":"warning","message":{"text":"context_compact._microcompact (cognitive 16): context_compact._microcompact has cognitive complexity 16 (threshold 15). Drivers by points: if/else 7 (12 pts), boolean chains 3, loops 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/agent/context_compact.py"},"region":{"startLine":227}}}],"partialFingerprints":{"codehealthFindingId/v1":"80e3f29f9482256c618d047d56eaecaf81fd72e9fcd54920fd64d68abe2b09a8"}},{"ruleId":"D2","level":"warning","message":{"text":"run_outcome.resolve_final_status (cognitive 16): run_outcome.resolve_final_status has cognitive complexity 16 (threshold 15). Drivers by points: if/else 11 (14 pts), boolean chains 2 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/agent/run_outcome.py"},"region":{"startLine":119}}}],"partialFingerprints":{"codehealthFindingId/v1":"728e8494928503c70307631b8ae7cc15c8d44be25ec2cd96fd24ffc6b99c2b60"}},{"ruleId":"D2","level":"warning","message":{"text":"attribution_core._attribution_load_equity (cognitive 16): attribution_core._attribution_load_equity has cognitive complexity 16 (threshold 15). Drivers by points: if/else 7 (10 pts), boolean chains 3, ternaries 1 (2 pts), loops 1 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/api/attribution_core.py"},"region":{"startLine":173}}}],"partialFingerprints":{"codehealthFindingId/v1":"7b766c48854fc4d0b1f73bf72d242a4aeb317525ce5fcd31f1aafbb396f8b265"}},{"ruleId":"D2","level":"warning","message":{"text":"attribution_core._attribution_brinson_asset_class_mode (cognitive 16): attribution_core._attribution_brinson_asset_class_mode has cognitive complexity 16 (threshold 15). Drivers by points: if/else 9 (12 pts), boolean chains 2, loops 2 (nesting depth added 3). 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/api/attribution_core.py"},"region":{"startLine":656}}}],"partialFingerprints":{"codehealthFindingId/v1":"596516ff9d12493a1dc7f3a008e7e433c7c62013ffc9c756d7ac78fe2aa524bd"}},{"ruleId":"D2","level":"warning","message":{"text":"sessions_routes._strip_prompt_wrappers (cognitive 16): sessions_routes._strip_prompt_wrappers has cognitive complexity 16 (threshold 15). Drivers by points: if/else 7 (11 pts), error handling 1 (3 pts), boolean chains 2 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/api/sessions_routes.py"},"region":{"startLine":56}}}],"partialFingerprints":{"codehealthFindingId/v1":"312a3f7c3447b74d1efcf930e193fb6923f568a341db3853d2dfdf1692bb723e"}},{"ruleId":"D2","level":"warning","message":{"text":"cotahist.sync (cognitive 16): cotahist.sync has cognitive complexity 16 (threshold 15). Drivers by points: if/else 6 (11 pts), loops 2 (3 pts), boolean chains 2 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/br_data/cotahist.py"},"region":{"startLine":157}}}],"partialFingerprints":{"codehealthFindingId/v1":"7d33f6540f87497b3b9367cf4af173d9dc3a36d778baceafdc56fb77ca32e8c6"}},{"ruleId":"D2","level":"warning","message":{"text":"cvm_funds.sync_daily (cognitive 16): cvm_funds.sync_daily has cognitive complexity 16 (threshold 15). Drivers by points: if/else 5 (12 pts), boolean chains 2, loops 1, ternaries 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/br_data/cvm_funds.py"},"region":{"startLine":151}}}],"partialFingerprints":{"codehealthFindingId/v1":"7fc9b72875db789f1bfaf2ad9f04aa2547e8cd557fa6e261a48ef3acb7e03bb6"}},{"ruleId":"D2","level":"warning","message":{"text":"DingTalkChannel._send_media_ref (cognitive 16): DingTalkChannel._send_media_ref has cognitive complexity 16 (threshold 15). Drivers by points: if/else 9 (11 pts), boolean chains 5 (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/dingtalk.py"},"region":{"startLine":620}}}],"partialFingerprints":{"codehealthFindingId/v1":"160754c7c5792e989cbdd3f7c6e7d6b3d12bcb7bfe12aa555e0cf5360e9b7c4a"}},{"ruleId":"D2","level":"warning","message":{"text":"DiscordChannel._should_respond_in_group (cognitive 16): DiscordChannel._should_respond_in_group has cognitive complexity 16 (threshold 15). Drivers by points: if/else 8 (14 pts), boolean chains 2 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/discord.py"},"region":{"startLine":763}}}],"partialFingerprints":{"codehealthFindingId/v1":"a4dc1257a6b556e791fff090a23d4eb2b1f2f2ffc9855e055975f52c1b830a08"}},{"ruleId":"D2","level":"warning","message":{"text":"EmailChannel._select_trusted_authentication_results (cognitive 16): EmailChannel._select_trusted_authentication_results has cognitive complexity 16 (threshold 15). Drivers by points: if/else 4 (8 pts), boolean chains 4, error handling 1 (2 pts), loops 1, ternaries 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/email.py"},"region":{"startLine":1002}}}],"partialFingerprints":{"codehealthFindingId/v1":"7e361bd8131983e9c6474a93745c0511959d1aaa41f1cc9c07935e80e283881e"}},{"ruleId":"D2","level":"warning","message":{"text":"EmailChannel._extract_attachments (cognitive 16): EmailChannel._extract_attachments has cognitive complexity 16 (threshold 15). Drivers by points: if/else 6 (11 pts), boolean chains 2, error handling 1 (2 pts), loops 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/email.py"},"region":{"startLine":1156}}}],"partialFingerprints":{"codehealthFindingId/v1":"90e15264fe18e39270476ebb710c1652f42d855a964ebdf72e7c4410fce60f05"}},{"ruleId":"D2","level":"warning","message":{"text":"FeishuChannel._resolve_mentions (cognitive 16): FeishuChannel._resolve_mentions has cognitive complexity 16 (threshold 15). Drivers by points: if/else 6 (10 pts), boolean chains 5, loops 1 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/feishu.py"},"region":{"startLine":903}}}],"partialFingerprints":{"codehealthFindingId/v1":"ec4e35823144a5f30da5214f97686c957cddc77defa981569d6f5509e032b397"}},{"ruleId":"D2","level":"warning","message":{"text":"MatrixChannel.send (cognitive 16): MatrixChannel.send has cognitive complexity 16 (threshold 15). Drivers by points: if/else 7 (10 pts), boolean chains 2, loops 1 (2 pts), ternaries 1 (2 pts) (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/matrix.py"},"region":{"startLine":512}}}],"partialFingerprints":{"codehealthFindingId/v1":"4bc2a202f37733cbb7e44c01e9ed0f40e916826e0cebb91ef5043837c47b9a88"}},{"ruleId":"D2","level":"warning","message":{"text":"MochatChannel._handle_watch_payload (cognitive 16): MochatChannel._handle_watch_payload has cognitive complexity 16 (threshold 15). Drivers by points: if/else 8 (11 pts), boolean chains 3, loops 1, ternaries 1 (nesting depth added 3). 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/mochat.py"},"region":{"startLine":682}}}],"partialFingerprints":{"codehealthFindingId/v1":"82de98392987d76ad14a8f5829f0a9eb73182c649696ff0507015cdceed3acc8"}},{"ruleId":"D2","level":"warning","message":{"text":"MochatChannel._process_inbound_event (cognitive 16): MochatChannel._process_inbound_event has cognitive complexity 16 (threshold 15). Drivers by points: if/else 8 (9 pts), boolean chains 7 (nesting depth added 1). To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/mochat.py"},"region":{"startLine":712}}}],"partialFingerprints":{"codehealthFindingId/v1":"d2a7caf77202cbc75140a88d582a785864369603a5d1956561daac96980d9a3b"}},{"ruleId":"D2","level":"warning","message":{"text":"TelegramChannel._drain_ordered_updates (cognitive 16): TelegramChannel._drain_ordered_updates has cognitive complexity 16 (threshold 15). Drivers by points: if/else 5 (8 pts), error handling 3 (5 pts), loops 2 (3 pts) (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/telegram.py"},"region":{"startLine":1385}}}],"partialFingerprints":{"codehealthFindingId/v1":"a78bf6729f54de52aa7ec6b2a0f50cde2eb5c85b971ef3a1b06ef170a8d5df34"}},{"ruleId":"D2","level":"warning","message":{"text":"WeixinChannel._send_media_file (cognitive 16): WeixinChannel._send_media_file has cognitive complexity 16 (threshold 15). Drivers by points: if/else 10, boolean chains 6. To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/weixin.py"},"region":{"startLine":1328}}}],"partialFingerprints":{"codehealthFindingId/v1":"e637344f924739c552432a03a93d7ac5551c1078281b2b6e60887f10ebd8c9b3"}},{"ruleId":"D2","level":"warning","message":{"text":"whatsapp._media_message (cognitive 16): whatsapp._media_message has cognitive complexity 16 (threshold 15). Drivers by points: boolean chains 11, if/else 5. To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/whatsapp.py"},"region":{"startLine":215}}}],"partialFingerprints":{"codehealthFindingId/v1":"e61de26af7354a4b3db7160ff7e87a8f312ff2355870d49f371a3340abe93991"}},{"ruleId":"D2","level":"warning","message":{"text":"dotenv._write_env_values (cognitive 16): dotenv._write_env_values has cognitive complexity 16 (threshold 15). Drivers by points: if/else 5 (8 pts), loops 3 (4 pts), boolean chains 2, ternaries 1 (2 pts) (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/config/dotenv.py"},"region":{"startLine":132}}}],"partialFingerprints":{"codehealthFindingId/v1":"2547e06a830a12d0aa1e52bc999796e6ae70765ce03b19ce67394cbcf7f79f13"}},{"ruleId":"D2","level":"warning","message":{"text":"MCPServerConfig.validate_transport_config (cognitive 16): MCPServerConfig.validate_transport_config has cognitive complexity 16 (threshold 15). Drivers by points: if/else 9 (14 pts), boolean chains 2 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/config/schema.py"},"region":{"startLine":420}}}],"partialFingerprints":{"codehealthFindingId/v1":"fd4339702bce395eff109708c6e6fe72e9b610591925f11a12e26e0fca26d764"}},{"ruleId":"D2","level":"warning","message":{"text":"StreamHub._hybrid (cognitive 16): StreamHub._hybrid has cognitive complexity 16 (threshold 15). Drivers by points: if/else 3 (9 pts), error handling 2 (6 pts), loops 1 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/data_gateway/streams.py"},"region":{"startLine":351}}}],"partialFingerprints":{"codehealthFindingId/v1":"d3873735d15503c75d18e58fa7973f24206380f09be932ca45a2598e701d17c7"}},{"ruleId":"D2","level":"warning","message":{"text":"CashFlowSeries.__post_init__ (cognitive 16): CashFlowSeries.__post_init__ has cognitive complexity 16 (threshold 15). Drivers by points: if/else 6 (10 pts), ternaries 2 (4 pts), boolean chains 1, loops 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/entities/cashflow.py"},"region":{"startLine":223}}}],"partialFingerprints":{"codehealthFindingId/v1":"06f890f940d31b9b13e0ed6bcaaa8a747bdb11abf24e6f4ba32fb7bf51f57358"}},{"ruleId":"D2","level":"warning","message":{"text":"bench_runner_strict.categorise_strict (cognitive 16): bench_runner_strict.categorise_strict has cognitive complexity 16 (threshold 15). Drivers by points: if/else 9 (14 pts), boolean chains 2 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/bench_runner_strict.py"},"region":{"startLine":251}}}],"partialFingerprints":{"codehealthFindingId/v1":"4ece884e3518266bc731246929ffcf76c89c67721e139fcf012c028912c1c881"}},{"ruleId":"D2","level":"warning","message":{"text":"sdk_order_gate.execute_live_order (cognitive 16): sdk_order_gate.execute_live_order has cognitive complexity 16 (threshold 15). Drivers by points: if/else 9 (11 pts), error handling 2 (3 pts), boolean chains 2 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/live/sdk_order_gate.py"},"region":{"startLine":62}}}],"partialFingerprints":{"codehealthFindingId/v1":"aa3c44e43a65ea6a5403cadac5a8a0c0f28dc60006f662a93b18ab42443b48cb"}},{"ruleId":"D2","level":"warning","message":{"text":"MemoryLifecycle._write_compressed (cognitive 16): MemoryLifecycle._write_compressed has cognitive complexity 16 (threshold 15). Drivers by points: if/else 8 (10 pts), error handling 2 (3 pts), loops 2, boolean chains 1 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/memory/lifecycle.py"},"region":{"startLine":352}}}],"partialFingerprints":{"codehealthFindingId/v1":"f24a0329e7bdeb9ef6e68d85deed47f7e37f6e1f3187c48cef3cbb2ca83dba58"}},{"ruleId":"D2","level":"warning","message":{"text":"chat._parse_dsml_tool_calls (cognitive 16): chat._parse_dsml_tool_calls has cognitive complexity 16 (threshold 15). Drivers by points: if/else 5 (10 pts), loops 3 (6 pts) (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/providers/chat.py"},"region":{"startLine":292}}}],"partialFingerprints":{"codehealthFindingId/v1":"77b92865497027b048ce8a4ebfdc9ce23e4dfb827cd1fcf4a1d9ae6c67d36078"}},{"ruleId":"D2","level":"warning","message":{"text":"fundmath.preferred_return_amount (cognitive 16): fundmath.preferred_return_amount has cognitive complexity 16 (threshold 15). Drivers by points: if/else 10 (13 pts), boolean chains 2, loops 1 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/fundmath.py"},"region":{"startLine":922}}}],"partialFingerprints":{"codehealthFindingId/v1":"c16111bd0f057cea176f6149fc24001f91a25e61f1d1158a2887f4eb8d3a2ff1"}},{"ruleId":"D2","level":"warning","message":{"text":"var_backtest._align (cognitive 16): var_backtest._align has cognitive complexity 16 (threshold 15). Drivers by points: if/else 9 (11 pts), ternaries 4, boolean chains 1 (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/var_backtest.py"},"region":{"startLine":236}}}],"partialFingerprints":{"codehealthFindingId/v1":"4bfb89d78fc00f21172a199a903a58a68baf1846f42acf8d68459719b2fc20ea"}},{"ruleId":"D2","level":"warning","message":{"text":"system_jobs.ensure_system_jobs (cognitive 16): system_jobs.ensure_system_jobs has cognitive complexity 16 (threshold 15). Drivers by points: ternaries 5 (8 pts), if/else 3 (7 pts), loops 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/scheduling/system_jobs.py"},"region":{"startLine":420}}}],"partialFingerprints":{"codehealthFindingId/v1":"53ae07bb948ff308397a9f28e7976c54022e430361dbb975f4962b5b9ea28205"}},{"ruleId":"D2","level":"warning","message":{"text":"ZooSignalEngine.generate (cognitive 16): ZooSignalEngine.generate has cognitive complexity 16 (threshold 15). Drivers by points: if/else 7 (11 pts), loops 3 (4 pts), boolean chains 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/skills/multi-factor/zoo_signal_engine.py"},"region":{"startLine":251}}}],"partialFingerprints":{"codehealthFindingId/v1":"ad623924d836632bf80c0f619fddb1e99fef39e94bc1eeb20035c4f7586131d6"}},{"ruleId":"D2","level":"warning","message":{"text":"models.coverage_days_from_ranges (cognitive 16): models.coverage_days_from_ranges has cognitive complexity 16 (threshold 15). Drivers by points: if/else 6 (11 pts), boolean chains 4, loops 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/strategy_discovery/models.py"},"region":{"startLine":227}}}],"partialFingerprints":{"codehealthFindingId/v1":"46a0ba1dc5d1797d4f1b34705079f4a7e56890e94b1a02187e01dba0d92e59b4"}},{"ruleId":"D2","level":"warning","message":{"text":"metrics.compute_decay_metrics (cognitive 16): metrics.compute_decay_metrics has cognitive complexity 16 (threshold 15). Drivers by points: if/else 8 (13 pts), boolean chains 3 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/strategy_store/metrics.py"},"region":{"startLine":29}}}],"partialFingerprints":{"codehealthFindingId/v1":"52454175b605e36f9e603585795bbb6f712d483599f42a31e87515e62b577778"}},{"ruleId":"D2","level":"warning","message":{"text":"alpha_bench_tool._render_html_manual (cognitive 16): alpha_bench_tool._render_html_manual has cognitive complexity 16 (threshold 15). Drivers by points: loops 4 (6 pts), if/else 4 (5 pts), ternaries 1 (3 pts), boolean chains 2 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/alpha_bench_tool.py"},"region":{"startLine":1164}}}],"partialFingerprints":{"codehealthFindingId/v1":"ebe05fdb0f9d8e570bf69d080e165bf14bb2e5a9068886d30463c22eb564ba81"}},{"ruleId":"D2","level":"warning","message":{"text":"backtest_runs_tool._backtests_of (cognitive 16): backtest_runs_tool._backtests_of has cognitive complexity 16 (threshold 15). Drivers by points: if/else 6 (11 pts), ternaries 2 (3 pts), error handling 1, loops 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/backtest_runs_tool.py"},"region":{"startLine":62}}}],"partialFingerprints":{"codehealthFindingId/v1":"d1a6f19381064a695a2ddb61389551c7df7d1bb14f8526ac73fa94e52b3f94ee"}},{"ruleId":"D2","level":"warning","message":{"text":"backtest_tool._record_bench_if_declared (cognitive 16): backtest_tool._record_bench_if_declared has cognitive complexity 16 (threshold 15). Drivers by points: if/else 9, boolean chains 6, error handling 1. To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/backtest_tool.py"},"region":{"startLine":106}}}],"partialFingerprints":{"codehealthFindingId/v1":"a2ef0f7bc3ae92e8c8a667428354e4785ef8e95ffd6d432f65cc9312bc1e3e28"}},{"ruleId":"D2","level":"warning","message":{"text":"etf_holdings_tool._cn_periodic_reports (cognitive 16): etf_holdings_tool._cn_periodic_reports has cognitive complexity 16 (threshold 15). Drivers by points: if/else 5 (8 pts), boolean chains 5, error handling 1, loops 1, ternaries 1 (nesting depth added 3). 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/etf_holdings_tool.py"},"region":{"startLine":1045}}}],"partialFingerprints":{"codehealthFindingId/v1":"56a508f920cf5012f72b0b1921208a1168ab1b17274e4cb69a05a317bafaedc5"}},{"ruleId":"D2","level":"warning","message":{"text":"gildata_identity.search_candidates (cognitive 16): gildata_identity.search_candidates has cognitive complexity 16 (threshold 15). Drivers by points: if/else 4 (6 pts), boolean chains 5, loops 2 (3 pts), error handling 1, ternaries 1 (nesting depth added 3). 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/gildata_identity.py"},"region":{"startLine":8}}}],"partialFingerprints":{"codehealthFindingId/v1":"9b5ee2e3c0030265798143c336f32d08172f62df837c683967e1f2db642a58d8"}},{"ruleId":"D2","level":"warning","message":{"text":"options_payoff_tool._coerce_legs (cognitive 16): options_payoff_tool._coerce_legs has cognitive complexity 16 (threshold 15). Drivers by points: if/else 4 (6 pts), error handling 2 (4 pts), boolean chains 3, ternaries 1 (2 pts), loops 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/options_payoff_tool.py"},"region":{"startLine":383}}}],"partialFingerprints":{"codehealthFindingId/v1":"e93abdbf69c61a334e5d5dfb66d5dd35f3a221f2787a97da7581cad01118b2b0"}},{"ruleId":"D2","level":"warning","message":{"text":"prediction_market_tool._market_resolution (cognitive 16): prediction_market_tool._market_resolution has cognitive complexity 16 (threshold 15). Drivers by points: if/else 9 (11 pts), ternaries 2 (3 pts), boolean chains 2 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/prediction_market_tool.py"},"region":{"startLine":351}}}],"partialFingerprints":{"codehealthFindingId/v1":"a267a81af48217d6143f896864cf1153f2a4c2fa3e8ace3b3a2d1e27a055d9b8"}},{"ruleId":"D2","level":"warning","message":{"text":"prediction_market_tool._resolve_history_token (cognitive 16): prediction_market_tool._resolve_history_token has cognitive complexity 16 (threshold 15). Drivers by points: if/else 9 (12 pts), ternaries 3 (4 pts) (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/prediction_market_tool.py"},"region":{"startLine":778}}}],"partialFingerprints":{"codehealthFindingId/v1":"75f923820641f57419868ba5bdeced6418f89d4e948236f653c3dda357b36244"}},{"ruleId":"D2","level":"warning","message":{"text":"redaction.redact_internal_paths (cognitive 16): redaction.redact_internal_paths has cognitive complexity 16 (threshold 15). Drivers by points: if/else 5 (8 pts), boolean chains 4, loops 2 (3 pts), ternaries 1 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/redaction.py"},"region":{"startLine":232}}}],"partialFingerprints":{"codehealthFindingId/v1":"3d976c49b7378fb6fc2d23a3d784275c396ff564129845acdfd00f2d15db4a56"}},{"ruleId":"D2","level":"warning","message":{"text":"research_papers_tool._admits_metric (cognitive 16): research_papers_tool._admits_metric has cognitive complexity 16 (threshold 15). Drivers by points: if/else 6 (9 pts), boolean chains 6, loops 1 (nesting depth added 3). 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/research_papers_tool.py"},"region":{"startLine":531}}}],"partialFingerprints":{"codehealthFindingId/v1":"01e3259bb1519cc641ee3e14b79a58b1d095433250c2a7388fdc1a7104b661ea"}},{"ruleId":"D2","level":"warning","message":{"text":"run_artifact_tool.read_run_artifact (cognitive 16): run_artifact_tool.read_run_artifact has cognitive complexity 16 (threshold 15). Drivers by points: if/else 9, error handling 5 (6 pts), ternaries 1 (nesting depth added 1). To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/run_artifact_tool.py"},"region":{"startLine":450}}}],"partialFingerprints":{"codehealthFindingId/v1":"75bf9297d91d35b2ac1b3158405a3d043d218c79bf479e22bed8fcefe955c84e"}},{"ruleId":"D2","level":"warning","message":{"text":"symbol_search_tool._merge_candidates (cognitive 16): symbol_search_tool._merge_candidates has cognitive complexity 16 (threshold 15). Drivers by points: if/else 5 (12 pts), boolean chains 3, loops 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/symbol_search_tool.py"},"region":{"startLine":943}}}],"partialFingerprints":{"codehealthFindingId/v1":"5f4d9df8ff1a25a94f83013fc6fdda10979d2788dcf106fde48c8afb0eaae03d"}},{"ruleId":"D2","level":"warning","message":{"text":"sdk.place_order (cognitive 16): sdk.place_order has cognitive complexity 16 (threshold 15). Drivers by points: boolean chains 7, if/else 6, ternaries 2, error handling 1. To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/dhan/sdk.py"},"region":{"startLine":439}}}],"partialFingerprints":{"codehealthFindingId/v1":"5fd5a7ef7201ea3b4d30ce1d9958136ffaa10d35d41a60b8e8f8431db71c0e01"}},{"ruleId":"D2","level":"warning","message":{"text":"instruments._alias_tokens_for_type (cognitive 16): instruments._alias_tokens_for_type has cognitive complexity 16 (threshold 15). Drivers by points: if/else 7 (11 pts), boolean chains 3, loops 1 (2 pts) (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/etoro/instruments.py"},"region":{"startLine":125}}}],"partialFingerprints":{"codehealthFindingId/v1":"6b7592ef342aa1b327add1a8888e3c3e7498faf89873c175896ef22e2d6f8587"}},{"ruleId":"D2","level":"warning","message":{"text":"trading.place_order (cognitive 16): trading.place_order has cognitive complexity 16 (threshold 15). Drivers by points: if/else 7, boolean chains 6, error handling 2, ternaries 1. To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/etoro/trading.py"},"region":{"startLine":32}}}],"partialFingerprints":{"codehealthFindingId/v1":"92b16217a9a68631f2e2651f419b7f919c4078de78426afdf1545f7282c46784"}},{"ruleId":"D2","level":"warning","message":{"text":"service._call_remote (cognitive 16): service._call_remote has cognitive complexity 16 (threshold 15). Drivers by points: if/else 8, boolean chains 7, ternaries 1. To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/service.py"},"region":{"startLine":1525}}}],"partialFingerprints":{"codehealthFindingId/v1":"4ecda75ec04a0d73bd3bf3d5d96f5f151c65417ac566ccccc2796e8c78257c68"}},{"ruleId":"D2","level":"warning","message":{"text":"ui_services.build_indicator_series (cognitive 16): ui_services.build_indicator_series has cognitive complexity 16 (threshold 15). Drivers by points: if/else 3 (8 pts), loops 3 (6 pts), boolean chains 2 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/ui_services.py"},"region":{"startLine":309}}}],"partialFingerprints":{"codehealthFindingId/v1":"1b5708594083c5e66040ee919a86c23ecc76f43d4bad84ce6ff95aaefa5c32c0"}},{"ruleId":"D2","level":"warning","message":{"text":"ui_services.build_run_analysis (cognitive 16): ui_services.build_run_analysis has cognitive complexity 16 (threshold 15). Drivers by points: if/else 6 (8 pts), boolean chains 6, ternaries 2 (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/ui_services.py"},"region":{"startLine":491}}}],"partialFingerprints":{"codehealthFindingId/v1":"474702c7e8b5a87d20c22e0f3ff9009791c1af1311f7f28d81978a0adf4aa659"}},{"ruleId":"D2","level":"warning","message":{"text":"ActivityLine.ActivityLine (cognitive 16): ActivityLine.ActivityLine has cognitive complexity 16 (threshold 15). Drivers by points: boolean chains 7, if/else 7, ternaries 2. Of this number, 8 points are the body\u0027s own statements and 8 belong to 4 function literals inside it that branch. To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/chat/ActivityLine.tsx"},"region":{"startLine":62}}}],"partialFingerprints":{"codehealthFindingId/v1":"9b2661425c08ab1866cf12385286dfc36f1f01d8b35a6838db026ad3add6f8b9"}},{"ruleId":"D2","level":"warning","message":{"text":"ToolProgressIndicator.ToolProgressIndicator (cognitive 16): ToolProgressIndicator.ToolProgressIndicator has cognitive complexity 16 (threshold 15). Drivers by points: if/else 5 (8 pts), boolean chains 5, loops 3 (nesting depth added 3). Most of this is not in the body itself: 1 of the 16 points is its own statement and the rest belongs to 3 function literals inside it that branch (lines 235, 264, 256). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/chat/ToolProgressIndicator.tsx"},"region":{"startLine":230}}}],"partialFingerprints":{"codehealthFindingId/v1":"3571edded7094092295eb049fc805cbc99f3987e7a3f918212de32bc675de91c"}},{"ruleId":"D2","level":"warning","message":{"text":"SidebarNavigation.SidebarNavigation (cognitive 16): SidebarNavigation.SidebarNavigation has cognitive complexity 16 (threshold 15). Drivers by points: boolean chains 9, ternaries 4, if/else 3. Most of this is not in the body itself: 3 of the 16 points are its own statements and the rest belongs to 5 function literals inside it that branch (lines 44, 40, 20, \u2026). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/layout/SidebarNavigation.tsx"},"region":{"startLine":8}}}],"partialFingerprints":{"codehealthFindingId/v1":"a415efed3101c95bfbf41b2fcadedaa0b33dc52ca61f6a0a408c285564777e9e"}},{"ruleId":"D2","level":"warning","message":{"text":"StrategyBuilder.StrategyBuilder (cognitive 16): StrategyBuilder.StrategyBuilder has cognitive complexity 16 (threshold 15). Drivers by points: ternaries 13, boolean chains 2, if/else 1. Of this number, 8 points are the body\u0027s own statements and 8 belong to 5 function items inside it that branch. To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/options/StrategyBuilder.tsx"},"region":{"startLine":25}}}],"partialFingerprints":{"codehealthFindingId/v1":"8047af51adff4f572cc19a134d584e1a8662abb7c6f5016a1e31a219fd423995"}},{"ruleId":"D2","level":"warning","message":{"text":"tearsheet.computeTopDrawdowns (cognitive 16): tearsheet.computeTopDrawdowns has cognitive complexity 16 (threshold 15). Drivers by points: if/else 7 (11 pts), boolean chains 2, ternaries 2, loops 1 (nesting depth added 4). Of this number, 14 points are the body\u0027s own statements and 2 belong to one function item inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/lib/tearsheet.ts"},"region":{"startLine":189}}}],"partialFingerprints":{"codehealthFindingId/v1":"b45d1f95122843a4cbe96a8aace9df5384be94a43aaa3608207c30e6359c60c0"}},{"ruleId":"D2","level":"warning","message":{"text":"Portfolio.HistoryChart (cognitive 16): Portfolio.HistoryChart has cognitive complexity 16 (threshold 15). Drivers by points: ternaries 8 (14 pts), boolean chains 1, if/else 1 (nesting depth added 6). Most of this is not in the body itself: 1 of the 16 points is its own statement and the rest belongs to 3 function literals inside it that branch (lines 693, 676, 689). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Portfolio.tsx"},"region":{"startLine":672}}}],"partialFingerprints":{"codehealthFindingId/v1":"48c8b449b4aa035d0faf8b913e8c61c0479936a0e6706d700b3fa4940185cdec"}},{"ruleId":"D2","level":"warning","message":{"text":"Runtime.BrokerRuntimeCard (cognitive 16): Runtime.BrokerRuntimeCard has cognitive complexity 16 (threshold 15). Drivers by points: ternaries 12 (13 pts), boolean chains 2, if/else 1 (nesting depth added 1). To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Runtime.tsx"},"region":{"startLine":227}}}],"partialFingerprints":{"codehealthFindingId/v1":"b7ac1a745f65b83aeff6da94b7bf63ef5d1b39c890eae358e9e264a2973e5538"}},{"ruleId":"D2","level":"warning","message":{"text":"Settings.Settings::submit (cognitive 16): Settings.Settings::submit has cognitive complexity 16 (threshold 15). Drivers by points: ternaries 5 (7 pts), boolean chains 5, if/else 3, error handling 1 (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition. This shape REPEATS in the file: 2 other methods here (Settings.Settings, Settings.Settings::submitDataSources) have the same decision points, in the same order, at the same nesting depths \u2014 so this is one pattern written 3 times rather than 3 independent problems. Splitting this body alone leaves the other 2 exactly as they are. Where these are variations on one operation, the change that clears all 3 is the shared one: lift the common shape into a single routine the variants call, parameterised by whatever genuinely differs between them, and keep in each method only the part that is not shared."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Settings.tsx"},"region":{"startLine":232}}}],"partialFingerprints":{"codehealthFindingId/v1":"054674d0b1e4e001e9930b7f10913c302645aebaa9c23964a5de3b004798fc65"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: cli/_legacy.py: FileTooLong \u2014 4729 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 4229 over it, 9.46\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"979e421b0422abd1f6e3af1020b509fb41f84224f9c2e0e2860d0b1f34d3b897"}},{"ruleId":"D3","level":"warning","message":{"text":"FunctionTooLong: Scheduled.Scheduled: FunctionTooLong \u2014 Scheduled runs 643 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 543 over it, 6.43\u00D7 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 \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Scheduled.tsx"},"region":{"startLine":92}}}],"partialFingerprints":{"codehealthFindingId/v1":"214f1455bcf7e270021e11d4962506b8651842475cf11c4170d77b23efbb0de9"}},{"ruleId":"D3","level":"warning","message":{"text":"FunctionTooLong: Settings.Settings: FunctionTooLong \u2014 Settings runs 626 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 526 over it, 6.26\u00D7 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 \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Settings.tsx"},"region":{"startLine":42}}}],"partialFingerprints":{"codehealthFindingId/v1":"4c02307434452c34a0d3a9ffefa5bfe08105e1f0a1632b8885f7ea488c721aba"}},{"ruleId":"D3","level":"warning","message":{"text":"FunctionTooLong: PaperTrading.PaperTrading: FunctionTooLong \u2014 PaperTrading runs 488 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 388 over it, 4.88\u00D7 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 \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/PaperTrading.tsx"},"region":{"startLine":18}}}],"partialFingerprints":{"codehealthFindingId/v1":"ee6365f490e6940c921c87920a1a3b949c4f51c303b0e983355e4a1f92070146"}},{"ruleId":"D3","level":"warning","message":{"text":"FunctionTooLong: ChannelConfigPanel.ChannelConfigPanel: FunctionTooLong \u2014 ChannelConfigPanel runs 477 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 377 over it, 4.77\u00D7 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 \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/settings/ChannelConfigPanel.tsx"},"region":{"startLine":193}}}],"partialFingerprints":{"codehealthFindingId/v1":"e861737d4c7ff478810869da72e3df25f3dcaaabbd1924c5debae3c736635f3b"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: lib/api.ts: FileTooLong \u2014 1846 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 1346 over it, 3.69\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/lib/api.ts"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"2ad06a86313df339c30dd6635a272a9ad5bf1875377c4ed68f8b4c26a81105cc"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: grounding/policies.py: FileTooLong \u2014 1811 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 1311 over it, 3.62\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/grounding/policies.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"004abbc52c04d8b9644ec0380ab0b162af226a24a3e0d6512b579676b1702c9f"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: channels/feishu.py: FileTooLong \u2014 1705 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 1205 over it, 3.41\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/feishu.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"c4885a36584db6d3ce40646badfefd5c3b28356dbe7e441105a6b1c51070e861"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: engines/base.py: FileTooLong \u2014 1625 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 1125 over it, 3.25\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/engines/base.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"ce1b0d24eb2954d0dc1a48f61ce85bd689d108a9da2313221fbfcb7b29f8c601"}},{"ruleId":"D3","level":"warning","message":{"text":"FunctionTooLong: Layout.Layout: FunctionTooLong \u2014 Layout runs 304 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 204 over it, 3.04\u00D7 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 \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/layout/Layout.tsx"},"region":{"startLine":21}}}],"partialFingerprints":{"codehealthFindingId/v1":"10524806452537ecafef180fda860e5ffc7279b3cfe86800127830b05273fd8a"}},{"ruleId":"D3","level":"warning","message":{"text":"FunctionTooLong: ResearchArtifacts.ResearchArtifacts: FunctionTooLong \u2014 ResearchArtifacts runs 303 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 203 over it, 3.03\u00D7 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 \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/ResearchArtifacts.tsx"},"region":{"startLine":80}}}],"partialFingerprints":{"codehealthFindingId/v1":"0867d8830f9b3608301af427d4d55af69c2f85d91fd34307505b0e2588db7f97"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: pages/Agent.tsx: FileTooLong \u2014 1501 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 1001 over it, 3.00\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Agent.tsx"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"a884b6f2ef040fa2b02bd893ece96521b2b27fa33c5853e3ebe93db52438efc1"}},{"ruleId":"D3","level":"warning","message":{"text":"FunctionTooLong: Portfolio.Portfolio: FunctionTooLong \u2014 Portfolio runs 298 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 198 over it, 2.98\u00D7 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 \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Portfolio.tsx"},"region":{"startLine":135}}}],"partialFingerprints":{"codehealthFindingId/v1":"f303077a69e068bf15500473389f12dcd10e95ec8c92e0d52d2b7d927384a53d"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: agent/mcp_server.py: FileTooLong \u2014 1488 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 988 over it, 2.98\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/mcp_server.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"ab98ea5ac70d898a1473aaf951cb9ba13cc6850b0cfde00fbff3814fac9e9c41"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: backtest/runner.py: FileTooLong \u2014 1390 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 890 over it, 2.78\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/runner.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"d467a02f978c95311382ac262fe0d242af4939b4717d811325175f9ef0c42278"}},{"ruleId":"D3","level":"warning","message":{"text":"FunctionTooLong: AlphaZoo.BrowseView: FunctionTooLong \u2014 BrowseView runs 278 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 178 over it, 2.78\u00D7 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 \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/AlphaZoo.tsx"},"region":{"startLine":143}}}],"partialFingerprints":{"codehealthFindingId/v1":"122cafc770be60b3cc11cae8b90cfbcaaf591fe681f2053f7229eee1e9fe2e50"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: channels/telegram.py: FileTooLong \u2014 1319 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 819 over it, 2.64\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/telegram.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"984b53cc0a876a27f0407fc657c04f9ba820cb2023be3d2a30dc7f33694998ed"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: tools/institutional_holdings_tool.py: FileTooLong \u2014 1280 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 780 over it, 2.56\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/institutional_holdings_tool.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"8a23f2faae1dea8457651d9f203c415d04170f75ea651e165ed2d7c42da97db9"}},{"ruleId":"D3","level":"warning","message":{"text":"FunctionTooLong: ChannelSettings.ChannelSettings: FunctionTooLong \u2014 ChannelSettings runs 254 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 154 over it, 2.54\u00D7 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 \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/settings/ChannelSettings.tsx"},"region":{"startLine":24}}}],"partialFingerprints":{"codehealthFindingId/v1":"b8bd202b010cce6d9872fe6953ee6a7220cc1d981d02ceda5f1a3b155ce79807"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: trading/service.py: FileTooLong \u2014 1204 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 704 over it, 2.41\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/service.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"e8f98db6003ee245f023c56bec56044ae8283b237a41519044e5f27e1cfac249"}},{"ruleId":"D3","level":"warning","message":{"text":"FunctionTooLong: StrategyBuilder.StrategyBuilder: FunctionTooLong \u2014 StrategyBuilder runs 237 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 137 over it, 2.37\u00D7 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 \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/options/StrategyBuilder.tsx"},"region":{"startLine":25}}}],"partialFingerprints":{"codehealthFindingId/v1":"1fcfd477d764fd7daecbe2d2a2dd9beb3a2fff26f7675a1fb1e6eb0807e87ae7"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: grounding/evidence.py: FileTooLong \u2014 1178 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 678 over it, 2.36\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/grounding/evidence.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"38f1eeda43602293e5aa326240cbca8dac6033fb9f73626b51bd816a82dcb975"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: channels/weixin.py: FileTooLong \u2014 1155 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 655 over it, 2.31\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/weixin.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"bc088f4c38bc6ab28a910a375a4e289d84a726bcfcd78e411cd842c869bcefca"}},{"ruleId":"D3","level":"warning","message":{"text":"FunctionTooLong: SourcePrioritySettings.SourcePrioritySettings: FunctionTooLong \u2014 SourcePrioritySettings runs 228 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 128 over it, 2.28\u00D7 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 \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/settings/SourcePrioritySettings.tsx"},"region":{"startLine":24}}}],"partialFingerprints":{"codehealthFindingId/v1":"1c782576ddb657f0f00e5692842f71c9d45cf27bc1897f837946516c3d153cad"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: providers/llm.py: FileTooLong \u2014 1121 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 621 over it, 2.24\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/providers/llm.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"eef75af04b954c953a4f174cc193057a1d9a06e6db41a9d1d27f03332f4b5716"}},{"ruleId":"D3","level":"warning","message":{"text":"FunctionTooLong: CandlestickChart.CandlestickChart: FunctionTooLong \u2014 CandlestickChart runs 221 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 121 over it, 2.21\u00D7 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 \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/charts/CandlestickChart.tsx"},"region":{"startLine":37}}}],"partialFingerprints":{"codehealthFindingId/v1":"e27cf3919a6e45652358c019b739d1cf07a6aa545f97c2e069507c1e4a8f8291"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: agent/loop.py: FileTooLong \u2014 1068 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 568 over it, 2.14\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/agent/loop.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"987908ed85bf7a791f54b7b899334035df7aea5062fdd1fb4db5b5c2f9db9e4c"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: pages/AlphaZoo.tsx: FileTooLong \u2014 1051 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 551 over it, 2.10\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/AlphaZoo.tsx"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"52f1f6d429e92e71422125bc5217ba12407a766496f0adf60d0556d41e550419"}},{"ruleId":"D3","level":"warning","message":{"text":"FunctionTooLong: GoalPanel.GoalPanel: FunctionTooLong \u2014 GoalPanel runs 206 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 106 over it, 2.06\u00D7 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 \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/chat/GoalPanel.tsx"},"region":{"startLine":61}}}],"partialFingerprints":{"codehealthFindingId/v1":"aed5d0a2d9427a009ec2b2cfe9807ef4e059f7c4410eed1a3d06e1f876ba0616"}},{"ruleId":"D3","level":"warning","message":{"text":"FunctionTooLong: MandateProposalCard.MandateProposalCard: FunctionTooLong \u2014 MandateProposalCard runs 205 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 105 over it, 2.05\u00D7 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 \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/chat/MandateProposalCard.tsx"},"region":{"startLine":203}}}],"partialFingerprints":{"codehealthFindingId/v1":"37c0b489bf288626ef271930fae88325acace0b098abefd1726e098210318a3e"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: tools/etf_holdings_tool.py: FileTooLong \u2014 1018 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 518 over it, 2.04\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/etf_holdings_tool.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"7a12e0fff6d44f7673d52b93e00cb14ad1ac5d729386c77e76d5ed685d03624e"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: quantlib/fundmath.py: FileTooLong \u2014 1012 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 512 over it, 2.02\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/fundmath.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"bd703ac4608aa8bc699f6c9f67ab62587e29bd4c1c1966831df766793a52dae0"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: pages/RunDetail.tsx: FileTooLong \u2014 1008 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 508 over it, 2.02\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/RunDetail.tsx"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"787911657b64c7d4f6212bd8c8d0ac14807673718ad00dbe012acb4d579fc739"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: tools/alpha_bench_tool.py: FileTooLong \u2014 989 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 489 over it, 1.98\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/alpha_bench_tool.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"7c24e2126ce56977d3c03c7fea34342a77a8e2188eb54afb62b62aaa8ee56d3a"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: channels/signal.py: FileTooLong \u2014 964 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 464 over it, 1.93\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/signal.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"39a4026ac45bed729e223c116181d39e93a48eaad03990d80e6d2bf2c01f715b"}},{"ruleId":"D3","level":"warning","message":{"text":"FunctionTooLong: OptionsLab.OptionsLab: FunctionTooLong \u2014 OptionsLab runs 192 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 92 over it, 1.92\u00D7 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 \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/OptionsLab.tsx"},"region":{"startLine":61}}}],"partialFingerprints":{"codehealthFindingId/v1":"132334d8710c137920beb7ed1d72b7df805a444bf6d397f01ae2ecaaf6c2e259"}},{"ruleId":"D3","level":"warning","message":{"text":"FunctionTooLong: PositionsTab.PositionsTab: FunctionTooLong \u2014 PositionsTab runs 190 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 90 over it, 1.90\u00D7 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 \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/run/PositionsTab.tsx"},"region":{"startLine":98}}}],"partialFingerprints":{"codehealthFindingId/v1":"9a9a1c92e4808da228d344e804dc38dd461c2f165d45c4bccd720bfe92145f08"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: channels/websocket.py: FileTooLong \u2014 949 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 449 over it, 1.90\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/websocket.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"21f41b689eba508b404c4cbbc8669ad80dd30bd4996bdd593f52970906c859ec"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: channels/email.py: FileTooLong \u2014 933 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 433 over it, 1.87\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/email.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"12d4922ca2f14281096ab0ba8ab34286ca584615ee68aa9cfab0422e4a0c5045"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: api/live_routes.py: FileTooLong \u2014 919 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 419 over it, 1.84\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/api/live_routes.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"c1f0cd81161f39333a5b9456abcd62136b7adf92d898bce63ebf543c1403e95a"}},{"ruleId":"D3","level":"warning","message":{"text":"FunctionTooLong: RunnerStatus.BrokerRow: FunctionTooLong \u2014 BrokerRow runs 182 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 82 over it, 1.82\u00D7 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 \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/chat/RunnerStatus.tsx"},"region":{"startLine":121}}}],"partialFingerprints":{"codehealthFindingId/v1":"e9e58be33c865f8bbd248a0553195b6775d25848228f848959342e468372fc5b"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: cli/main.py: FileTooLong \u2014 902 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 402 over it, 1.80\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/main.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"0e7f78c9ff3e73d2e07e248c1d5b370a3b54d0e4720bd2df99de5f7cf79d3cb6"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: FeishuChannel: TooManyMethods \u2014 54 methods. The bar is 30 methods; this is 24 over it, 1.80\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/feishu.py"},"region":{"startLine":604}}}],"partialFingerprints":{"codehealthFindingId/v1":"4d2063e825b003d67f7b03b4f66be67d9fa4c0f0da895c99b81c3d16031d3614"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: factors/cli_handlers.py: FileTooLong \u2014 878 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 378 over it, 1.76\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/cli_handlers.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"b7131235b1bac6efd2db28f56b4d9eff1e1aecb471dcf0f488b408ff2ade2e98"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: live/sdk_order_gate.py: FileTooLong \u2014 875 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 375 over it, 1.75\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/live/sdk_order_gate.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"5686f9554118d2e0e4e8b979b131c513c1b7b9d981928f584e4c0c9a56f15f13"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: MatrixChannel: TooManyMethods \u2014 52 methods. The bar is 30 methods; this is 22 over it, 1.73\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/matrix.py"},"region":{"startLine":215}}}],"partialFingerprints":{"codehealthFindingId/v1":"9d76fe5bd8d69572c3ae37de1b943b8843203c6cc9d0198786b92bb8e51ce7cb"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: portfolio/service.py: FileTooLong \u2014 865 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 365 over it, 1.73\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/portfolio/service.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"f43a0539886fc77485cc4fe3bf2420fd5e14efd73c088ab984c0e77cb0506de5"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: TelegramChannel: TooManyMethods \u2014 51 methods. The bar is 30 methods; this is 21 over it, 1.70\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/telegram.py"},"region":{"startLine":423}}}],"partialFingerprints":{"codehealthFindingId/v1":"48257f49018fd111677324976d48a0d376f2a4f4fa88a3c1d6161256d76e304f"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: swarm/worker.py: FileTooLong \u2014 836 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 336 over it, 1.67\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/swarm/worker.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"327f959712330c85daa85628ffac2195f6bbfb65bd600ecad5b78f7404304060"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: grounding/figures.py: FileTooLong \u2014 827 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 327 over it, 1.65\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/grounding/figures.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"42a66c583d5b81a12f7e095611bafdea67ae5679126a24f73c28ea0438b27541"}},{"ruleId":"D3","level":"warning","message":{"text":"FunctionTooLong: agent.useAgentStore: FunctionTooLong \u2014 useAgentStore runs 164 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 64 over it, 1.64\u00D7 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 \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/stores/agent.ts"},"region":{"startLine":120}}}],"partialFingerprints":{"codehealthFindingId/v1":"c39d877e45fe37d2b4ec70a2f6a7477694b946ae9edcf43e773013aec1fcd13a"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: BaseEngine: TooManyMethods \u2014 49 methods. The bar is 30 methods; this is 19 over it, 1.63\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/engines/base.py"},"region":{"startLine":538}}}],"partialFingerprints":{"codehealthFindingId/v1":"b0fd5a22bd2721d2503e772b1f8520f9a6fce6d1980ed5f81ea0e231557bc3e3"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: _PolicyMixin: TooManyMethods \u2014 49 methods. The bar is 30 methods; this is 19 over it, 1.63\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/grounding/policies.py"},"region":{"startLine":460}}}],"partialFingerprints":{"codehealthFindingId/v1":"b63e938d357612a189b45f7a407168647c58b482b59f2095001337d22038eebb"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: channels/matrix.py: FileTooLong \u2014 807 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 307 over it, 1.61\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/matrix.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"07d496c4b5ed8932fce95f6e4059e8e7330ec644375ef579c5cf198063d2584d"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: swarm/runtime.py: FileTooLong \u2014 805 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 305 over it, 1.61\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/swarm/runtime.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"040551b60471ef5ace9fd485db28c661dd270de0eba9fdffa77c930fbb664863"}},{"ruleId":"D3","level":"warning","message":{"text":"ClassTooLong: Scheduled: ClassTooLong \u2014 643 significant lines (blank, comment-only and punctuation-only lines excluded), 8 methods. The bar is 400 significant lines; this is 243 over it, 1.61\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Scheduled.tsx"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"62245bed774b0e6464bfd109204a76bb664cb0d9485db60b6d83f9a24610a21f"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: tools/trading_connector_tool.py: FileTooLong \u2014 795 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 295 over it, 1.59\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/trading_connector_tool.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"ae4f032f90579bc931da46e6e27385d7eab5b2c6876402c3bb5caeb928341e2c"}},{"ruleId":"D3","level":"warning","message":{"text":"FunctionTooLong: Reports.Reports: FunctionTooLong \u2014 Reports runs 159 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 59 over it, 1.59\u00D7 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 \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Reports.tsx"},"region":{"startLine":23}}}],"partialFingerprints":{"codehealthFindingId/v1":"1686e31d058e110f35d95c982b48538b23289abcbda6929ce5f68a191027fc13"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: valuation/artifact.py: FileTooLong \u2014 792 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 292 over it, 1.58\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/valuation/artifact.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"8d341ebb82031fc19d46bd9de98d5e96bd5806b1338200a34f2d0af6c3fdf032"}},{"ruleId":"D3","level":"warning","message":{"text":"ClassTooLong: Settings: ClassTooLong \u2014 626 significant lines (blank, comment-only and punctuation-only lines excluded), 2 methods. The bar is 400 significant lines; this is 226 over it, 1.57\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Settings.tsx"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"a3928c83186ca0f071b214d46d2aed5d4f9e3838410a61c236fd4436e7179a2e"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: tools/mcp.py: FileTooLong \u2014 780 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 280 over it, 1.56\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/mcp.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"f890f8e2b01e035bfb22b0fdcf85b085a128c29e98bc1ad95af98c34f40175f6"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: futu/sdk.py: FileTooLong \u2014 778 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 278 over it, 1.56\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/futu/sdk.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"df00f3ad60c63ea0a84b1033f9c71803e54e3388808550c426c54bd8845c966d"}},{"ruleId":"D3","level":"warning","message":{"text":"FunctionTooLong: Correlation.CorrelationAnalysis: FunctionTooLong \u2014 CorrelationAnalysis runs 155 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 55 over it, 1.55\u00D7 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 \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Correlation.tsx"},"region":{"startLine":44}}}],"partialFingerprints":{"codehealthFindingId/v1":"183dc0ef14be9323b89fb52d9e0c796349fe810b4383c55883bf8bc925d76272"}},{"ruleId":"D3","level":"warning","message":{"text":"FunctionTooLong: CustomProviderManager.CustomProviderManager: FunctionTooLong \u2014 CustomProviderManager runs 154 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 54 over it, 1.54\u00D7 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 \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/settings/CustomProviderManager.tsx"},"region":{"startLine":20}}}],"partialFingerprints":{"codehealthFindingId/v1":"3ccaff56c2882974dbc433ac4488809a9033d6158cad533cbd282a69a0c640df"}},{"ruleId":"D3","level":"warning","message":{"text":"FunctionTooLong: FactorResearchPanel.FactorResearchPanel: FunctionTooLong \u2014 FactorResearchPanel runs 153 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 53 over it, 1.53\u00D7 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 \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/charts/FactorResearchPanel.tsx"},"region":{"startLine":84}}}],"partialFingerprints":{"codehealthFindingId/v1":"5262900117e9ae58eb7970b0571533a874bfb647e508a15fee8964e6fad7293a"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: channels/mochat.py: FileTooLong \u2014 739 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 239 over it, 1.48\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/mochat.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"294452e4a330bb99428652be9380cc0aab8c192d3d74a877ba8cc9ef40615bbc"}},{"ruleId":"D3","level":"warning","message":{"text":"FunctionTooLong: WelcomeScreen.WelcomeScreen: FunctionTooLong \u2014 WelcomeScreen runs 147 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 47 over it, 1.47\u00D7 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 \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/chat/WelcomeScreen.tsx"},"region":{"startLine":255}}}],"partialFingerprints":{"codehealthFindingId/v1":"cff551be80d7cfa67678bdedb83a096ba46c2ea3a6f3b8b7835c0ea2bd26c11d"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: agent/tool_lifecycle.py: FileTooLong \u2014 729 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 229 over it, 1.46\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/agent/tool_lifecycle.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"127df923586221db5abd498e814e7e53026ecb173c6c539497b858b94bb2aab2"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: api/runs_routes.py: FileTooLong \u2014 710 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 210 over it, 1.42\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/api/runs_routes.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"b930c3257fe0547220323f746976524024ce808858bd65722482b770d9ef7b33"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: pages/Scheduled.tsx: FileTooLong \u2014 707 significant lines (blank, comment-only and punctuation-only lines excluded), about 91% of them inside a single declaration: Scheduled (92-859). The bar is 500 significant lines; this is 207 over it, 1.41\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Scheduled.tsx"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"6ee61bf5d4901c5503b86685bec9791c8bb1c321e1ce45e2a6f6fa8cb91ca0ee"}},{"ruleId":"D3","level":"warning","message":{"text":"FunctionTooLong: Runtime.Runtime: FunctionTooLong \u2014 Runtime runs 141 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 41 over it, 1.41\u00D7 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 \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Runtime.tsx"},"region":{"startLine":25}}}],"partialFingerprints":{"codehealthFindingId/v1":"0dfaa29827ba86fc00c6def19266bc766539bb8c19c3ccc6912c329fe90d2666"}},{"ruleId":"D3","level":"warning","message":{"text":"FunctionTooLong: VolatilitySurfaceGrid.VolatilitySurfaceGrid: FunctionTooLong \u2014 VolatilitySurfaceGrid runs 138 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 38 over it, 1.38\u00D7 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 \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/options/VolatilitySurfaceGrid.tsx"},"region":{"startLine":25}}}],"partialFingerprints":{"codehealthFindingId/v1":"2ddebaa27e243e5fc5e3977c00a5d2067de0f9786741b0acb4fa379807d1c889"}},{"ruleId":"D3","level":"warning","message":{"text":"FunctionTooLong: AlphaZoo.BenchView: FunctionTooLong \u2014 BenchView runs 137 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 37 over it, 1.37\u00D7 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 \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/AlphaZoo.tsx"},"region":{"startLine":641}}}],"partialFingerprints":{"codehealthFindingId/v1":"3cf8b1e0489fc5631301621af1590e028e5d63ebe6e493f62cb597a4eeb2dd54"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: agent/instrument_identity.py: FileTooLong \u2014 684 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 184 over it, 1.37\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/agent/instrument_identity.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"eb6903e7445b2fc7942a30788cd2ce22de7dc5f11a441f11d692c0e13a1a5bb6"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: EmailChannel: TooManyMethods \u2014 41 methods. The bar is 30 methods; this is 11 over it, 1.37\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/email.py"},"region":{"startLine":106}}}],"partialFingerprints":{"codehealthFindingId/v1":"197ede9f1f1ba3442fe761f48453be45a488d9901a4e5b4882ea5ebb8d3632f9"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: entities/ingest.py: FileTooLong \u2014 681 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 181 over it, 1.36\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/entities/ingest.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"706f6727600621326ac7583b95192f51f4ee3da08ca9c1cdb2c90e3c89740b69"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: engines/argentina_equity.py: FileTooLong \u2014 679 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 179 over it, 1.36\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/engines/argentina_equity.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"d9793e168b0cb93bb738c935a3625cc3d71c028e6ce1c37730354ad62b1225c0"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: api/sessions_routes.py: FileTooLong \u2014 679 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 179 over it, 1.36\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/api/sessions_routes.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"2a1d6e2c976c1d9eaf06f497cdf509180a5731d90ceb5f42db8f3ba01e98424c"}},{"ruleId":"D3","level":"warning","message":{"text":"FunctionTooLong: useSSE.useSSE: FunctionTooLong \u2014 useSSE runs 134 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 34 over it, 1.34\u00D7 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 \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/hooks/useSSE.ts"},"region":{"startLine":27}}}],"partialFingerprints":{"codehealthFindingId/v1":"36741dae043f9fac26baee98d645772014f570ff034046587bb68557235d2e3c"}},{"ruleId":"D3","level":"warning","message":{"text":"FunctionTooLong: AlphaZoo.DetailView: FunctionTooLong \u2014 DetailView runs 134 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 34 over it, 1.34\u00D7 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 \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/AlphaZoo.tsx"},"region":{"startLine":457}}}],"partialFingerprints":{"codehealthFindingId/v1":"3926586987187622ed01d7b74a0666aea6cf069aa90d6465a6d997eedd60f28f"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: valuation/dcf.py: FileTooLong \u2014 669 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 169 over it, 1.34\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/valuation/dcf.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"206f534c5c2d66a14c12275a8e263087bcca1940519e8cc8d12a33e84c9bd740"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: api/scheduled_routes.py: FileTooLong \u2014 664 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 164 over it, 1.33\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/api/scheduled_routes.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"c3146e7b7792ede67dfca5cdc84cbfc9ba4f1535b0aa69c60ca4d59f35082f7b"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: channels/discord.py: FileTooLong \u2014 663 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 163 over it, 1.33\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/discord.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"a5b8f7f0edb9c018d3b8b40ae3129a0a43259d94d8275049c2f93d695a5744c5"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: pages/Settings.tsx: FileTooLong \u2014 660 significant lines (blank, comment-only and punctuation-only lines excluded), about 95% of them inside a single declaration: Settings (42-776). The bar is 500 significant lines; this is 160 over it, 1.32\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Settings.tsx"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"6a7463ea70fa9e7533a90cd647d318ec7e35e563d283aed2f81b66aeef201a95"}},{"ruleId":"D3","level":"warning","message":{"text":"FunctionTooLong: ConnectionCenter.ConnectionCenter: FunctionTooLong \u2014 ConnectionCenter runs 132 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 32 over it, 1.32\u00D7 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 \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/portfolio/ConnectionCenter.tsx"},"region":{"startLine":21}}}],"partialFingerprints":{"codehealthFindingId/v1":"05bccb41bf853062a522881d0861378dec0b3dd4c899a856cc6dea38f48a0f15"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: data_gateway/history_store.py: FileTooLong \u2014 657 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 157 over it, 1.31\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/data_gateway/history_store.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"f139ecefef13e5bf630d6e086a0dcf231bddb3b3d2494e6c15d19b99e8e9d3c4"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: channels/msteams.py: FileTooLong \u2014 651 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 151 over it, 1.30\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/msteams.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"917f0b3ec3b9e9fdf4132a521b3d19f296e0d4e186d55a8fc7937564a177facf"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: SignalChannel: TooManyMethods \u2014 39 methods. The bar is 30 methods; this is 9 over it, 1.30\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/signal.py"},"region":{"startLine":360}}}],"partialFingerprints":{"codehealthFindingId/v1":"bcd34ce40ef5d75555119a3636b886f91b94eacb40c6f1d90963e45f51f8b4f3"}},{"ruleId":"D3","level":"warning","message":{"text":"FunctionTooLong: AlphaZoo.CompareView: FunctionTooLong \u2014 CompareView runs 130 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 30 over it, 1.30\u00D7 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 \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/AlphaZoo.tsx"},"region":{"startLine":1027}}}],"partialFingerprints":{"codehealthFindingId/v1":"30a4f4a44a5a632a32379a74ad123e6922cf32f706a6457fbbaf384e9edbb78d"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: harness/assertions.py: FileTooLong \u2014 648 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 148 over it, 1.30\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/harness/assertions.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"058f0ba702a1a59d9e5e031de3cfc252f4734b04c40f221744cb6fe83478133b"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: tools/prediction_market_tool.py: FileTooLong \u2014 648 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 148 over it, 1.30\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/prediction_market_tool.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"e1d6d1514e52d44b4393810ab65306f84fbc15dc1b73f23c12e16837a3d0a0af"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: kis/sdk.py: FileTooLong \u2014 638 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 138 over it, 1.28\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/kis/sdk.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"a4d13967996ab4450bda382a27f9b2e7d8593a2ecd88e04f1b9f25daf11c196a"}},{"ruleId":"D3","level":"warning","message":{"text":"FunctionTooLong: MandateProposalCard.ProfileTile: FunctionTooLong \u2014 ProfileTile runs 127 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 27 over it, 1.27\u00D7 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 \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/chat/MandateProposalCard.tsx"},"region":{"startLine":49}}}],"partialFingerprints":{"codehealthFindingId/v1":"009c4ae1ab320b14bff5f9133e4b34df61c32e02976f0b53b2e0748e787783e8"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: MochatChannel: TooManyMethods \u2014 38 methods. The bar is 30 methods; this is 8 over it, 1.27\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/mochat.py"},"region":{"startLine":259}}}],"partialFingerprints":{"codehealthFindingId/v1":"596d7d3eb0267d186ba43d07d2273fb7f522ba56541a1e8b42a79b2618b223f1"}},{"ruleId":"D3","level":"warning","message":{"text":"FunctionTooLong: HistoryStorageSettings.HistoryStorageSettings: FunctionTooLong \u2014 HistoryStorageSettings runs 126 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 26 over it, 1.26\u00D7 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 \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/settings/HistoryStorageSettings.tsx"},"region":{"startLine":9}}}],"partialFingerprints":{"codehealthFindingId/v1":"9da247852defe9490e4d8b1ff1029d6b77235353a7f8caedc1dea9ab07321a75"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: alpaca/sdk.py: FileTooLong \u2014 623 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 123 over it, 1.25\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/alpaca/sdk.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"ac2dde0476c1d0d8c6dc6a340cca20add706665727eb7842a5dbfbd5376b38cd"}},{"ruleId":"D3","level":"warning","message":{"text":"FunctionTooLong: StrategyResearchDashboard.StrategyResearchDashboard: FunctionTooLong \u2014 StrategyResearchDashboard runs 124 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 24 over it, 1.24\u00D7 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 \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/charts/StrategyResearchDashboard.tsx"},"region":{"startLine":122}}}],"partialFingerprints":{"codehealthFindingId/v1":"40044bab43ce7d3e96bbac737a382c20c91c01559ced00862d30fa041f5f2ee2"}},{"ruleId":"D3","level":"warning","message":{"text":"FunctionTooLong: swarmStatus.applySwarmEvent: FunctionTooLong \u2014 applySwarmEvent runs 124 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 24 over it, 1.24\u00D7 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 \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/lib/swarmStatus.ts"},"region":{"startLine":209}}}],"partialFingerprints":{"codehealthFindingId/v1":"6024dd8a92ce824ace0e2dbc9e49fc77af944b3ad2537eb73ad1c42830a03bef"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: settings/ChannelConfigPanel.tsx: FileTooLong \u2014 616 significant lines (blank, comment-only and punctuation-only lines excluded), about 77% of them inside a single declaration: ChannelConfigPanel (193-861). The bar is 500 significant lines; this is 116 over it, 1.23\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/settings/ChannelConfigPanel.tsx"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"5c950e840009fe64bd6c1d41a768be16a548bddf1eaf0244c92caa908ee2e973"}},{"ruleId":"D3","level":"warning","message":{"text":"ClassTooLong: PaperTrading: ClassTooLong \u2014 488 significant lines (blank, comment-only and punctuation-only lines excluded), 1 methods. The bar is 400 significant lines; this is 88 over it, 1.22\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/PaperTrading.tsx"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"b1176a2016688f5aaf522ecdafb1fbee7c5aa86fdb004c675801665ebe87f578"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: longbridge/sdk.py: FileTooLong \u2014 610 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 110 over it, 1.22\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/longbridge/sdk.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"95e4950d1b417b75e9fe573164bcab074f7c152f129db2f8ca48e483936d8e22"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: channels/dingtalk.py: FileTooLong \u2014 607 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 107 over it, 1.21\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/dingtalk.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"cc645b9ba2215fa8d7586cc744da0aebddde0a9b450c6f22dc13f7a7decfc913"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: channels/slack.py: FileTooLong \u2014 599 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 99 over it, 1.20\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/slack.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"5c24a65c8da8f9ba331f63671dcdf322a5f24fcce45a1101bb7658f0bffe5efd"}},{"ruleId":"D3","level":"warning","message":{"text":"ClassTooLong: ChannelConfigPanel: ClassTooLong \u2014 477 significant lines (blank, comment-only and punctuation-only lines excluded), 4 methods. The bar is 400 significant lines; this is 77 over it, 1.19\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/settings/ChannelConfigPanel.tsx"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"61d187e385ec2a5183fa69c4fefc75e957f0e7521805746cb1b3cb75a20727f8"}},{"ruleId":"D3","level":"warning","message":{"text":"FunctionTooLong: ActivityLine.ActivityLine: FunctionTooLong \u2014 ActivityLine runs 119 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 19 over it, 1.19\u00D7 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 \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/chat/ActivityLine.tsx"},"region":{"startLine":62}}}],"partialFingerprints":{"codehealthFindingId/v1":"0f4cd92dd0b5f8a0928529be66a44420136463d46e33e4b3fab600bc7b5ed119"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: providers/openai_codex.py: FileTooLong \u2014 593 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 93 over it, 1.19\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/providers/openai_codex.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"341d004fc492823ba21a05fd1dc2c53641a560fac0d881d5a63697aaef77d288"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: tools/research_papers_tool.py: FileTooLong \u2014 586 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 86 over it, 1.17\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/research_papers_tool.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"c6744b2e79d15b1eabc57db4dd2da2512e7ce3256f8a02947abaf014d4588b6e"}},{"ruleId":"D3","level":"warning","message":{"text":"FunctionTooLong: ResearchLab.ResearchLab: FunctionTooLong \u2014 ResearchLab runs 117 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 17 over it, 1.17\u00D7 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 \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/ResearchLab.tsx"},"region":{"startLine":20}}}],"partialFingerprints":{"codehealthFindingId/v1":"8a958b04467a47268ec845fefc6316dac09dc868fc4a2063aaa1214048c35f6e"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: WeixinChannel: TooManyMethods \u2014 35 methods. The bar is 30 methods; this is 5 over it, 1.17\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/weixin.py"},"region":{"startLine":135}}}],"partialFingerprints":{"codehealthFindingId/v1":"8c62e2ba64b1d17e95cccf489182a0ec992a009d90db9b946713c5dde3920e06"}},{"ruleId":"D3","level":"warning","message":{"text":"FunctionTooLong: OptionsChainTable.OptionsChainTable: FunctionTooLong \u2014 OptionsChainTable runs 116 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 16 over it, 1.16\u00D7 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 \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/options/OptionsChainTable.tsx"},"region":{"startLine":139}}}],"partialFingerprints":{"codehealthFindingId/v1":"d70341085c94c4f20c8cdea53ac38ca3d273e3f54bf9be433b568f0523985042"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: binance/sdk.py: FileTooLong \u2014 578 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 78 over it, 1.16\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/binance/sdk.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"be2a0cccf710e19be2056c99eccb4cced882dbef112df8f2e23bd63b4cb39deb"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: goal/store.py: FileTooLong \u2014 574 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 74 over it, 1.15\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/goal/store.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"c5426e4ff5762d1e75fe44fdb2d58b998c175fbfd98a6568d84b714da455207e"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: pages/Portfolio.tsx: FileTooLong \u2014 570 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 70 over it, 1.14\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Portfolio.tsx"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"a8bf4cfc9330cfe02fd641347e0ee1f2e623df942dcce4ec3ad468f6dc9ff83c"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: tools/taiwan_stock_data_tool.py: FileTooLong \u2014 566 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 66 over it, 1.13\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/taiwan_stock_data_tool.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"92fc47a8a444ca573f306a6f9774d7689cdc86b8b1206bc6f8b1fe40324e78c9"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: api/alpha_routes.py: FileTooLong \u2014 563 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 63 over it, 1.13\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/api/alpha_routes.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"c2f8b008d065482fb9be198c63736e138b48ad4528c1cf39a498e133f8a4ceeb"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: loaders/base.py: FileTooLong \u2014 558 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 58 over it, 1.12\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/base.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"fc7f395d31f2e99bd39444506eb69d4b86310e44fffa0954d88a8c31e4989cb2"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: api/attribution_core.py: FileTooLong \u2014 556 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 56 over it, 1.11\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/api/attribution_core.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"46def852184e60d3225d5d767ac5532db580536e3ea57c5cfd9954456fc63e2a"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: live/order_guard.py: FileTooLong \u2014 554 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 54 over it, 1.11\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/live/order_guard.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"f556b75c04db863d5223229c42901d92fe5756fbd0a678add2e87b684545fd9d"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: engines/options_portfolio.py: FileTooLong \u2014 550 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 50 over it, 1.10\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/engines/options_portfolio.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"3b5e29816e80009db827a5dac1e79fbd0a6e757936f88f01ce0d652d7b6feef2"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: channels/whatsapp.py: FileTooLong \u2014 550 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 50 over it, 1.10\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/whatsapp.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"e69c1f534915e0d4b98b799a370fe9f247db40f263597824c925b71368fa292a"}},{"ruleId":"D3","level":"warning","message":{"text":"FunctionTooLong: PixelOffice.PixelOffice: FunctionTooLong \u2014 PixelOffice runs 110 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 10 over it, 1.10\u00D7 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 \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/PixelOffice.tsx"},"region":{"startLine":6}}}],"partialFingerprints":{"codehealthFindingId/v1":"f6d99051ecbe8e847df8a48f69eb79b739f3c4a12345dd2a2ad4727cef97f216"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: session/service.py: FileTooLong \u2014 546 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 46 over it, 1.09\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/session/service.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"78a40b9cd6224c05b3f87ae64378d80773aecf676f11286d4bef63da633eafd1"}},{"ruleId":"D3","level":"warning","message":{"text":"FunctionTooLong: OptionsPayoffChart.OptionsPayoffChart: FunctionTooLong \u2014 OptionsPayoffChart runs 109 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 9 over it, 1.09\u00D7 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 \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/charts/OptionsPayoffChart.tsx"},"region":{"startLine":16}}}],"partialFingerprints":{"codehealthFindingId/v1":"ec80322b8046cbf1f18c45ed5ba9011b4f7dbf205013d0fa991845bba3341278"}},{"ruleId":"D3","level":"warning","message":{"text":"FunctionTooLong: SwarmStatusCard.SwarmStatusCard: FunctionTooLong \u2014 SwarmStatusCard runs 109 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 9 over it, 1.09\u00D7 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 \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/chat/SwarmStatusCard.tsx"},"region":{"startLine":182}}}],"partialFingerprints":{"codehealthFindingId/v1":"a7cf344d7b84601b57742b8d70d2b97241e318ba17d64cddb3e4bda48ec03013"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: memory/persistent.py: FileTooLong \u2014 542 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 42 over it, 1.08\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/memory/persistent.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"24a13a16635702a72699434f0d8aebd5aa000f018d0ab6e2c79d0ea291268f35"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: valuation/comps.py: FileTooLong \u2014 541 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 41 over it, 1.08\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/valuation/comps.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"17cddeca1004903578754b6794646a8f0ecfc963bd7cb84e833db807a465a350"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: tools/swarm_tool.py: FileTooLong \u2014 539 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 39 over it, 1.08\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/swarm_tool.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"6585c6ff384de291d042c652874d29b9397e3ccfbe3780eac05939df96b3dd43"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: ibkr/local.py: FileTooLong \u2014 537 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 37 over it, 1.07\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/ibkr/local.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"670f22717b3c536af1ece2ec2f0d86c6e0fb0616ee7ff823633e7059001f7eef"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: paper_trade/engine.py: FileTooLong \u2014 534 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 34 over it, 1.07\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/paper_trade/engine.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"bd0ed9e01906ad9a56fd20f9a25122152bc74ea6b974493417b8365a7494234c"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: WebSocketChannel: TooManyMethods \u2014 32 methods. The bar is 30 methods; this is 2 over it, 1.07\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/websocket.py"},"region":{"startLine":265}}}],"partialFingerprints":{"codehealthFindingId/v1":"31eb3f3dae0c05250787c9633f49ec627c5086d578f83e8032a2572e4ff08a40"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: providers/claude_cli.py: FileTooLong \u2014 532 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 32 over it, 1.06\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/providers/claude_cli.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"4fb3374ae851d6e8f58c6415f0b729db93fcb92681d7ee55463e7312ef70a134"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: tools/trade_journal_parsers.py: FileTooLong \u2014 531 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 31 over it, 1.06\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/trade_journal_parsers.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"371719724394bea760ab3cebc0d31344ad43179f351a67dc3a2186842e80be9a"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: pages/Runtime.tsx: FileTooLong \u2014 530 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 30 over it, 1.06\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Runtime.tsx"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"6bbabae98637f94bd7ad0d98783df363cd556163d69071f931238af3a825de90"}},{"ruleId":"D3","level":"warning","message":{"text":"FunctionTooLong: ScheduledResearchProposalCard.ScheduledResearchProposalCard: FunctionTooLong \u2014 ScheduledResearchProposalCard 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\u00D7 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 \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/chat/ScheduledResearchProposalCard.tsx"},"region":{"startLine":19}}}],"partialFingerprints":{"codehealthFindingId/v1":"070ecee1ffc29fe3988e594bc6bfe8dc553c24ceec790c214b6d0778ba7ef614"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: tools/financial_statements_tool.py: FileTooLong \u2014 529 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 29 over it, 1.06\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/financial_statements_tool.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"1b8fc6f65c60338da44bdaa294a3f392bab4739c02bd96e0c29c5a6ff5d34447"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: engines/crypto.py: FileTooLong \u2014 528 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 28 over it, 1.06\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/engines/crypto.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"5acdf42793c7229c650705679037c43d9c9da7406649affcaff5ecb830c92a29"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: tools/trade_journal_tool.py: FileTooLong \u2014 527 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 27 over it, 1.05\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/trade_journal_tool.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"286888d26b3cdbd86a8781962d13f336caa0ea37414f5d543261d553ebd06d0f"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: providers/chat.py: FileTooLong \u2014 526 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 26 over it, 1.05\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/providers/chat.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"fb782bddef3fa8ab484e2c6ac8cf74ab8092ffbb788334d7ce89e8e6660feeeb"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: tools/symbol_search_tool.py: FileTooLong \u2014 525 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 25 over it, 1.05\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/symbol_search_tool.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"28906382a1f351dace16c4cc8869355b9ee3078f33be574e7c162250ad5e85b4"}},{"ruleId":"D3","level":"warning","message":{"text":"FunctionTooLong: ModelPicker.ModelPicker: FunctionTooLong \u2014 ModelPicker runs 105 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 5 over it, 1.05\u00D7 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 \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/settings/ModelPicker.tsx"},"region":{"startLine":13}}}],"partialFingerprints":{"codehealthFindingId/v1":"64fa5c94efc4b47992e032714db5171ccec2cdb80a185d9e42cfe4e38df8072d"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: channels/qq.py: FileTooLong \u2014 524 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 24 over it, 1.05\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/qq.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"f8c32574a83bcb72efea610e94e55873f7bfabcf9df93e2aa7576936df03cf1b"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: ui/rail.py: FileTooLong \u2014 518 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 18 over it, 1.04\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/ui/rail.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"1fb0ba68374080c8c76e12d56d2a8d73272d2919b2d5325b1080d479d1ff4a20"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: SlackChannel: TooManyMethods \u2014 31 methods. The bar is 30 methods; this is 1 over it, 1.03\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/slack.py"},"region":{"startLine":72}}}],"partialFingerprints":{"codehealthFindingId/v1":"427eaf3333d8b650d0c3e09a763bab2e751d143eb984926143d7147ff01bc763"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: okx/sdk.py: FileTooLong \u2014 511 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 11 over it, 1.02\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/okx/sdk.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"d840d58522f326c733b70a9ce22ccf23b56be045340fbd4b19a7643fad6d2d85"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: strategy_discovery/facade.py: FileTooLong \u2014 507 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 7 over it, 1.01\u00D7 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/strategy_discovery/facade.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"ca73a8625baf8b7d19c2d1dcd9488999f5bc2db765b2b8062d698aa940a5ca5c"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: pages/PaperTrading.tsx: FileTooLong \u2014 503 significant lines (blank, comment-only and punctuation-only lines excluded), about 97% of them inside a single declaration: PaperTrading (18-573). The bar is 500 significant lines; this is 3 over it, 1.01\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/PaperTrading.tsx"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"dcc1b29a7a1d557b6e7251587cefdda90f1646606a37b0ded56924ba6f03d7af"}},{"ruleId":"D4","level":"warning","message":{"text":"Near-duplicate member family (3 members, 49 shared lines): agent/backtest/loaders/akshare_loader.py:135-205 | agent/backtest/loaders/eastmoney_loader.py:80-160 | agent/backtest/loaders/tencent_loader.py:91-156 \u2014 These 3 members are variants of one another: a block of 49 lines reported below appears in every one of them, and the pairwise near-duplicate rows they would otherwise produce are collapsed into this row. Read them as one construct written 3 times. The repair is at the members\u0027 grain \u2014 factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 3 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/akshare_loader.py"},"region":{"startLine":135}}}],"partialFingerprints":{"codehealthFindingId/v1":"263fb00a09f00f3d158d9441abd93fc57f5201b1c6fdc48aae74cdb66fae3da6"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (32 corresponding lines): agent/src/strategy_store/sqlite_store.py:379-456 | agent/src/strategy_store/sqlite_store.py:554-619 \u2014 These two members are one piece of code written twice and then edited apart: 32 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/strategy_store/sqlite_store.py"},"region":{"startLine":379}}}],"partialFingerprints":{"codehealthFindingId/v1":"0e3a664c5f0a8cea72623fbe2ee98737ec5c5173c3e77d8fb0a1c4e75a17dff2"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (21 corresponding lines): agent/src/tools/pattern_tool.py:236-267 | agent/src/tools/pattern_tool.py:271-296 \u2014 These two members are one piece of code written twice and then edited apart: 21 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/pattern_tool.py"},"region":{"startLine":236}}}],"partialFingerprints":{"codehealthFindingId/v1":"3cbf397027022c404fe81868be2eaecd436c3ce62f29fd10e5b471e2c52515ce"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (25 corresponding lines): agent/src/tools/autopilot_tool.py:461-539 | agent/src/tools/autopilot_tool.py:580-675 \u2014 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 \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/autopilot_tool.py"},"region":{"startLine":461}}}],"partialFingerprints":{"codehealthFindingId/v1":"815ce1d540f8675a36652a11baf74fba73c0cf650dfc1799ee22d741708ab16e"}},{"ruleId":"D4","level":"warning","message":{"text":"Members sharing a duplicated core (18 members, 50\u002B identical tokens): agent/src/factors/zoo/alpha101/alpha_048.py:67-94 | agent/src/factors/zoo/alpha101/alpha_058.py:55-82 | agent/src/factors/zoo/alpha101/alpha_059.py:55-82 | agent/src/factors/zoo/alpha101/alpha_063.py:60-87 | agent/src/factors/zoo/alpha101/alpha_067.py:55-82 | agent/src/factors/zoo/alpha101/alpha_069.py:55-82 | agent/src/factors/zoo/alpha101/alpha_070.py:55-82 | agent/src/factors/zoo/alpha101/alpha_076.py:56-83 | agent/src/factors/zoo/alpha101/alpha_079.py:56-83 | agent/src/factors/zoo/alpha101/alpha_080.py:55-82 | agent/src/factors/zoo/alpha101/alpha_082.py:56-83 | agent/src/factors/zoo/alpha101/alpha_087.py:56-83 | agent/src/factors/zoo/alpha101/alpha_089.py:55-82 | agent/src/factors/zoo/alpha101/alpha_090.py:55-82 | agent/src/factors/zoo/alpha101/alpha_091.py:55-82 | agent/src/factors/zoo/alpha101/alpha_093.py:55-82 | agent/src/factors/zoo/alpha101/alpha_097.py:55-82 | agent/src/factors/zoo/alpha101/alpha_100.py:55-82 \u2014 These 18 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below \u2014 it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 18 times. The repair is at the members\u0027 grain \u2014 factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 18 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/alpha101/alpha_048.py"},"region":{"startLine":67}}}],"partialFingerprints":{"codehealthFindingId/v1":"55407b2af3f35f954071fd12f8760d2706787b0c9e02b8f525a262899e6c962c"}},{"ruleId":"D4","level":"warning","message":{"text":"Members sharing a duplicated core (12 members, 50\u002B identical tokens): agent/src/factors/zoo/academic/bab.py:53-58 | agent/src/factors/zoo/academic/carhart_mom.py:48-53 | agent/src/factors/zoo/academic/cma.py:48-53 | agent/src/factors/zoo/academic/corr_rewire.py:151-156 | agent/src/factors/zoo/academic/high52w.py:47-52 | agent/src/factors/zoo/academic/hml.py:48-53 | agent/src/factors/zoo/academic/illiq.py:47-52 | agent/src/factors/zoo/academic/mkt_rf.py:45-52 | agent/src/factors/zoo/academic/retskew.py:47-52 | agent/src/factors/zoo/academic/rmw.py:47-52 | agent/src/factors/zoo/academic/smb.py:46-51 | agent/src/factors/zoo/academic/strev.py:46-51 \u2014 These 12 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below \u2014 it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 12 times. The repair is at the members\u0027 grain \u2014 factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 12 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/academic/bab.py"},"region":{"startLine":53}}}],"partialFingerprints":{"codehealthFindingId/v1":"86df9ffa365cd21a1d0d138ef3cb98292725977c043bd0ba5cb923c85c2c520c"}},{"ruleId":"D4","level":"warning","message":{"text":"Members sharing a duplicated core (10 members, 50\u002B identical tokens): agent/src/factors/zoo/alpha101/alpha_007.py:60-77 | agent/src/factors/zoo/alpha101/alpha_009.py:55-72 | agent/src/factors/zoo/alpha101/alpha_010.py:55-72 | agent/src/factors/zoo/alpha101/alpha_021.py:65-82 | agent/src/factors/zoo/alpha101/alpha_023.py:60-77 | agent/src/factors/zoo/alpha101/alpha_024.py:67-84 | agent/src/factors/zoo/alpha101/alpha_027.py:65-82 | agent/src/factors/zoo/alpha101/alpha_046.py:67-84 | agent/src/factors/zoo/alpha101/alpha_049.py:67-84 | agent/src/factors/zoo/alpha101/alpha_051.py:67-84 \u2014 These 10 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below \u2014 it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 10 times. The repair is at the members\u0027 grain \u2014 factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 10 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/alpha101/alpha_007.py"},"region":{"startLine":60}}}],"partialFingerprints":{"codehealthFindingId/v1":"5ad2615165ca87baff35627ab9aafecfa2633454aeee6afaac065dc2d072a0c9"}},{"ruleId":"D4","level":"warning","message":{"text":"Members sharing a duplicated core (10 members, 50\u002B identical tokens): agent/src/factors/zoo/qlib158/sumd10.py:27-36 | agent/src/factors/zoo/qlib158/sumd20.py:27-36 | agent/src/factors/zoo/qlib158/sumd30.py:27-36 | agent/src/factors/zoo/qlib158/sumd5.py:27-36 | agent/src/factors/zoo/qlib158/sumd60.py:27-36 | agent/src/factors/zoo/qlib158/vsumd10.py:27-36 | agent/src/factors/zoo/qlib158/vsumd20.py:27-36 | agent/src/factors/zoo/qlib158/vsumd30.py:27-36 | agent/src/factors/zoo/qlib158/vsumd5.py:27-36 | agent/src/factors/zoo/qlib158/vsumd60.py:27-36 \u2014 These 10 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below \u2014 it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 10 times. The repair is at the members\u0027 grain \u2014 factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 10 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/qlib158/sumd10.py"},"region":{"startLine":27}}}],"partialFingerprints":{"codehealthFindingId/v1":"3a2668766517a164464d17c0823bea958cb6cd4ec645e32add193d4d5d3160ac"}},{"ruleId":"D4","level":"warning","message":{"text":"Members sharing a duplicated core (10 members, 50\u002B identical tokens): agent/src/factors/zoo/qlib158/sumn10.py:27-34 | agent/src/factors/zoo/qlib158/sumn20.py:27-34 | agent/src/factors/zoo/qlib158/sumn30.py:27-34 | agent/src/factors/zoo/qlib158/sumn5.py:27-34 | agent/src/factors/zoo/qlib158/sumn60.py:27-34 | agent/src/factors/zoo/qlib158/vsumn10.py:27-34 | agent/src/factors/zoo/qlib158/vsumn20.py:27-34 | agent/src/factors/zoo/qlib158/vsumn30.py:27-34 | agent/src/factors/zoo/qlib158/vsumn5.py:27-34 | agent/src/factors/zoo/qlib158/vsumn60.py:27-34 \u2014 These 10 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below \u2014 it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 10 times. The repair is at the members\u0027 grain \u2014 factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 10 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/qlib158/sumn10.py"},"region":{"startLine":27}}}],"partialFingerprints":{"codehealthFindingId/v1":"a5276c2dc1e7ef83bdbd0727cb19ed8a038a09b7452f9669c52967709fa72298"}},{"ruleId":"D4","level":"warning","message":{"text":"Members sharing a duplicated core (10 members, 50\u002B identical tokens): agent/src/factors/zoo/qlib158/sump10.py:27-34 | agent/src/factors/zoo/qlib158/sump20.py:27-34 | agent/src/factors/zoo/qlib158/sump30.py:27-34 | agent/src/factors/zoo/qlib158/sump5.py:27-34 | agent/src/factors/zoo/qlib158/sump60.py:27-34 | agent/src/factors/zoo/qlib158/vsump10.py:27-34 | agent/src/factors/zoo/qlib158/vsump20.py:27-34 | agent/src/factors/zoo/qlib158/vsump30.py:27-34 | agent/src/factors/zoo/qlib158/vsump5.py:27-34 | agent/src/factors/zoo/qlib158/vsump60.py:27-34 \u2014 These 10 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below \u2014 it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 10 times. The repair is at the members\u0027 grain \u2014 factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 10 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/qlib158/sump10.py"},"region":{"startLine":27}}}],"partialFingerprints":{"codehealthFindingId/v1":"c31279af756f7fc99c0c3dc69279307f5bedbba7e6540ee6b566df3a806a69bc"}},{"ruleId":"D4","level":"warning","message":{"text":"Members sharing a duplicated core (10 members, 50\u002B identical tokens): agent/src/trading/connectors/alpaca/sdk.py:175-183 | agent/src/trading/connectors/binance/sdk.py:198-206 | agent/src/trading/connectors/etoro/client.py:169-177 | agent/src/trading/connectors/futu/sdk.py:215-223 | agent/src/trading/connectors/ibkr/local.py:161-176 | agent/src/trading/connectors/mt5/_client.py:164-172 | agent/src/trading/connectors/okx/sdk.py:168-176 | agent/src/trading/connectors/tiger/sdk.py:168-176 | agent/src/trading/connectors/toss/sdk.py:168-176 | agent/src/trading/connectors/trading212/sdk.py:151-159 \u2014 These 10 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below \u2014 it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 10 times. The repair is at the members\u0027 grain \u2014 factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 10 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/alpaca/sdk.py"},"region":{"startLine":175}}}],"partialFingerprints":{"codehealthFindingId/v1":"445a24213e6ba9dc6bebfd1fb3dd3be4cdc00a0c5cefac3fdd70ce8a5e1c8117"}},{"ruleId":"D4","level":"warning","message":{"text":"Members sharing a duplicated core (7 members, 50\u002B identical tokens): agent/src/channels/config_meta.py:74-93 | agent/src/channels/config_meta.py:97-128 | agent/src/channels/config_meta.py:132-152 | agent/src/channels/config_meta.py:156-208 | agent/src/channels/config_meta.py:212-247 | agent/src/channels/config_meta.py:259-309 | agent/src/channels/config_meta.py:322-371 \u2014 These 7 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below \u2014 it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 7 times. The repair is at the members\u0027 grain \u2014 factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 7 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/config_meta.py"},"region":{"startLine":74}}}],"partialFingerprints":{"codehealthFindingId/v1":"0b8c87d2d5fdaa5ed5eee29f044d70b00b500281785a78eb95257c44c0dfad8b"}},{"ruleId":"D4","level":"warning","message":{"text":"Members sharing a duplicated core (7 members, 50\u002B identical tokens): agent/src/trading/connectors/binance/sdk.py:219-267 | agent/src/trading/connectors/dhan/sdk.py:198-230 | agent/src/trading/connectors/mt5/reads.py:67-103 | agent/src/trading/connectors/okx/sdk.py:189-247 | agent/src/trading/connectors/shoonya/sdk.py:198-223 | agent/src/trading/connectors/tiger/sdk.py:189-232 | agent/src/trading/connectors/upbit/sdk.py:192-221 \u2014 These 7 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below \u2014 it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 7 times. The repair is at the members\u0027 grain \u2014 factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 7 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/binance/sdk.py"},"region":{"startLine":219}}}],"partialFingerprints":{"codehealthFindingId/v1":"0b14ddb8eea3b2a327880fe5b13001ae5cf96c8bc69dd7664fea34a4208fd8e0"}},{"ruleId":"D4","level":"warning","message":{"text":"Members sharing a duplicated core (6 members, 50\u002B identical tokens): agent/mcp_server.py:904-969 | agent/src/trading/connectors/binance/sdk.py:124-138 | agent/src/trading/connectors/futu/sdk.py:144-158 | agent/src/trading/connectors/kis/sdk.py:163-175 | agent/src/trading/connectors/okx/sdk.py:105-119 | agent/src/trading/connectors/toss/sdk.py:114-126 \u2014 These 6 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below \u2014 it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 6 times. The repair is at the members\u0027 grain \u2014 factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 6 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/mcp_server.py"},"region":{"startLine":904}}}],"partialFingerprints":{"codehealthFindingId/v1":"8af0ed50a7e8ba67f2fb335a2bd975a9ad2ccb66623d26192edd35103f8e7aa6"}},{"ruleId":"D4","level":"warning","message":{"text":"Members sharing a duplicated core (6 members, 50\u002B identical tokens): agent/src/skills/candlestick/example_signal_engine.py:536-563 | agent/src/skills/elliott-wave/example_signal_engine.py:414-444 | agent/src/skills/harmonic/example_signal_engine.py:431-461 | agent/src/skills/ichimoku/example_signal_engine.py:135-165 | agent/src/skills/smc/example_signal_engine.py:26-53 | agent/src/skills/technical-basic/example_signal_engine.py:250-277 \u2014 These 6 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below \u2014 it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 6 times. The repair is at the members\u0027 grain \u2014 factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 6 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/skills/candlestick/example_signal_engine.py"},"region":{"startLine":536}}}],"partialFingerprints":{"codehealthFindingId/v1":"0d3a5e9e6da970deaf385ac4ced79128aee549befc02df02ac032080120071bb"}},{"ruleId":"D4","level":"warning","message":{"text":"Members sharing a duplicated core (5 members, 50\u002B identical tokens): agent/src/factors/zoo/alpha101/alpha_071.py:56-75 | agent/src/factors/zoo/alpha101/alpha_073.py:56-75 | agent/src/factors/zoo/alpha101/alpha_076.py:87-105 | agent/src/factors/zoo/alpha101/alpha_087.py:87-105 | agent/src/factors/zoo/alpha101/alpha_096.py:56-73 \u2014 These 5 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below \u2014 it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 5 times. The repair is at the members\u0027 grain \u2014 factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 5 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/alpha101/alpha_071.py"},"region":{"startLine":56}}}],"partialFingerprints":{"codehealthFindingId/v1":"1e30b8d36ac4227be6d6cefeea1acaa526f591605dd9bf93f5d01203c0c8a664"}},{"ruleId":"D4","level":"warning","message":{"text":"Members sharing a duplicated core (5 members, 50\u002B identical tokens): agent/src/factors/zoo/qlib158/cntd10.py:27-34 | agent/src/factors/zoo/qlib158/cntd20.py:27-34 | agent/src/factors/zoo/qlib158/cntd30.py:27-34 | agent/src/factors/zoo/qlib158/cntd5.py:27-34 | agent/src/factors/zoo/qlib158/cntd60.py:27-34 \u2014 These 5 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below \u2014 it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 5 times. The repair is at the members\u0027 grain \u2014 factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 5 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/qlib158/cntd10.py"},"region":{"startLine":27}}}],"partialFingerprints":{"codehealthFindingId/v1":"ef19463ca3660078b141a94ddfd3124063f8308cf87558f05e21b15b3eff9c47"}},{"ruleId":"D4","level":"warning","message":{"text":"Members sharing a duplicated core (5 members, 50\u002B identical tokens): agent/src/factors/zoo/qlib158/rsqr10.py:28-33 | agent/src/factors/zoo/qlib158/rsqr20.py:28-33 | agent/src/factors/zoo/qlib158/rsqr30.py:28-33 | agent/src/factors/zoo/qlib158/rsqr5.py:28-33 | agent/src/factors/zoo/qlib158/rsqr60.py:28-33 \u2014 These 5 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below \u2014 it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 5 times. The repair is at the members\u0027 grain \u2014 factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 5 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/qlib158/rsqr10.py"},"region":{"startLine":28}}}],"partialFingerprints":{"codehealthFindingId/v1":"2cfc8a0af8b81fcf6c3f133b5984d0d09ae35e37e1094f051315ba6d1cc82691"}},{"ruleId":"D4","level":"warning","message":{"text":"Members sharing a duplicated core (5 members, 50\u002B identical tokens): agent/src/trading/connectors/dhan/sdk.py:171-181 | agent/src/trading/connectors/kis/sdk.py:229-239 | agent/src/trading/connectors/shoonya/sdk.py:171-181 | agent/src/trading/connectors/upbit/sdk.py:165-175 | agent/src/trading/connectors/zerodha/sdk.py:165-175 \u2014 These 5 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below \u2014 it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 5 times. The repair is at the members\u0027 grain \u2014 factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 5 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/dhan/sdk.py"},"region":{"startLine":171}}}],"partialFingerprints":{"codehealthFindingId/v1":"93ef6b7741414f4d4a6637a7925a85224b52d64c23db4733a6209acda5d63ecf"}},{"ruleId":"D4","level":"warning","message":{"text":"Members sharing a duplicated core (4 members, 50\u002B identical tokens): agent/cli/_legacy.py:4645-4689 | agent/cli/_legacy.py:4720-4739 | agent/cli/_legacy.py:5100-5136 | agent/cli/_legacy.py:5157-5208 \u2014 These 4 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below \u2014 it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 4 times. The repair is at the members\u0027 grain \u2014 factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 4 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":4645}}}],"partialFingerprints":{"codehealthFindingId/v1":"2e4206151433d2336b57ff36ae750cda5e94f6148a2b763c9ec08def61513485"}},{"ruleId":"D4","level":"warning","message":{"text":"Members sharing a duplicated core (4 members, 50\u002B identical tokens): agent/cli/commands/goal.py:155-165 | agent/cli/commands/goal.py:220-262 | agent/cli/commands/goal.py:266-294 | agent/cli/commands/goal.py:298-354 \u2014 These 4 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below \u2014 it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 4 times. The repair is at the members\u0027 grain \u2014 factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 4 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/commands/goal.py"},"region":{"startLine":155}}}],"partialFingerprints":{"codehealthFindingId/v1":"4b913f0112601bd4f9ffe604a9b3a882dcea659ab4bcfa2cb6de432c06e2351b"}},{"ruleId":"D4","level":"warning","message":{"text":"Members sharing a duplicated core (4 members, 50\u002B identical tokens): agent/src/trading/connectors/alpaca/sdk.py:472-619 | agent/src/trading/connectors/binance/sdk.py:538-657 | agent/src/trading/connectors/kis/sdk.py:481-559 | agent/src/trading/connectors/upbit/sdk.py:387-494 \u2014 These 4 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below \u2014 it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 4 times. The repair is at the members\u0027 grain \u2014 factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 4 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/alpaca/sdk.py"},"region":{"startLine":472}}}],"partialFingerprints":{"codehealthFindingId/v1":"f1064a7b23c1647ec18a236d981ca2867439ea700963f79b1d2a304ade00c8ff"}},{"ruleId":"D4","level":"warning","message":{"text":"Members sharing a duplicated core (4 members, 50\u002B identical tokens): agent/src/trading/connectors/dhan/sdk.py:532-565 | agent/src/trading/connectors/shoonya/sdk.py:510-538 | agent/src/trading/connectors/upbit/sdk.py:503-536 | agent/src/trading/connectors/zerodha/sdk.py:627-659 \u2014 These 4 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below \u2014 it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 4 times. The repair is at the members\u0027 grain \u2014 factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 4 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/dhan/sdk.py"},"region":{"startLine":532}}}],"partialFingerprints":{"codehealthFindingId/v1":"575e4541aa2dc9f8b386d5667eeb3b837151d93dacb6604bfad5074c7780282f"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (155 corresponding lines): agent/src/entities/ingest.py:379-535 | agent/src/entities/ingest.py:942-1096 \u2014 These two members are one piece of code written twice and then edited apart: 155 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/entities/ingest.py"},"region":{"startLine":379}}}],"partialFingerprints":{"codehealthFindingId/v1":"cd670ef39488db9af2996e936f7a2da434b48a467146a025428635e849f6d9a3"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (74 corresponding lines): agent/backtest/loaders/nobitex.py:198-285 | agent/backtest/loaders/wallex.py:196-269 \u2014 These two members are one piece of code written twice and then edited apart: 74 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/nobitex.py"},"region":{"startLine":198}}}],"partialFingerprints":{"codehealthFindingId/v1":"1754e3e7b80e525f049a3044a3db99d393570d89d28ab7bcca1ae190feab4e0c"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (99 corresponding lines): agent/backtest/loaders/fmp_loader.py:221-324 | agent/backtest/loaders/tiingo_loader.py:165-263 \u2014 These two members are one piece of code written twice and then edited apart: 99 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/fmp_loader.py"},"region":{"startLine":221}}}],"partialFingerprints":{"codehealthFindingId/v1":"515ca82829930c24f27d92c49eb2aa4f626c91b72806d0912a0b3d4e86ebc7a6"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (83 corresponding lines): agent/src/skills/elliott-wave/example_signal_engine.py:189-283 | agent/src/skills/elliott-wave/example_signal_engine.py:286-368 \u2014 These two members are one piece of code written twice and then edited apart: 83 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/skills/elliott-wave/example_signal_engine.py"},"region":{"startLine":189}}}],"partialFingerprints":{"codehealthFindingId/v1":"e5350d640235dabbd70c1cd060a5e2d08a72761c7bdfdd18cb9d71cf3c0e139c"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (44 corresponding lines): agent/src/portfolio/normalization.py:254-297 | agent/src/portfolio/normalization.py:338-398 \u2014 These two members are one piece of code written twice and then edited apart: 44 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/portfolio/normalization.py"},"region":{"startLine":254}}}],"partialFingerprints":{"codehealthFindingId/v1":"74e90cfb14a018b6c2fa775819cf48c7ec7cf2fb38c56da557d64087e8a51552"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (52 corresponding lines): agent/src/trading/connectors/kis/sdk.py:686-739 | agent/src/trading/connectors/toss/sdk.py:450-501 \u2014 These two members are one piece of code written twice and then edited apart: 52 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/kis/sdk.py"},"region":{"startLine":686}}}],"partialFingerprints":{"codehealthFindingId/v1":"bc739794bf88c37ea5d54348b5fc8fc9d216477e06b02c71f6f01b852ac9ec25"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (21 corresponding lines): agent/src/tools/gildata_fin_query_tool.py:131-151 | agent/src/tools/gildata_stock_selection_tool.py:40-60 \u2014 These two members are one piece of code written twice and then edited apart: 21 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/gildata_fin_query_tool.py"},"region":{"startLine":131}}}],"partialFingerprints":{"codehealthFindingId/v1":"d948d6c3d4f29b741e59ab584b983abe7fe8dbfbc02b323a91caba6ab346f337"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (21 corresponding lines): agent/src/factors/zoo/gtja191/alpha_055.py:49-69 | agent/src/factors/zoo/gtja191/alpha_137.py:54-87 \u2014 These two members are one piece of code written twice and then edited apart: 21 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/gtja191/alpha_055.py"},"region":{"startLine":49}}}],"partialFingerprints":{"codehealthFindingId/v1":"61d01c9aaeae211e18bc5ec4ecb5f78bbf2c77c6e500204849f1086a2779bd1e"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (36 corresponding lines): agent/src/tools/goal_tool.py:279-314 | agent/src/tools/goal_tool.py:346-383 \u2014 These two members are one piece of code written twice and then edited apart: 36 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/goal_tool.py"},"region":{"startLine":279}}}],"partialFingerprints":{"codehealthFindingId/v1":"af212c0ec71c9ff2aca0bcaf448b2358de03b4d865e825499cf53d34fc695bda"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (51 corresponding lines): agent/backtest/loaders/nobitex.py:138-188 | agent/backtest/loaders/wallex.py:136-186 \u2014 These two members are one piece of code written twice and then edited apart: 51 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/nobitex.py"},"region":{"startLine":138}}}],"partialFingerprints":{"codehealthFindingId/v1":"484eba52731f65bff14ce29b00f5db71283ae751126ec367e4bd470c2d3d8a62"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (57 corresponding lines): agent/src/quantlib/crossvalidation.py:233-289 | agent/src/quantlib/crossvalidation.py:497-560 \u2014 These two members are one piece of code written twice and then edited apart: 57 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/crossvalidation.py"},"region":{"startLine":233}}}],"partialFingerprints":{"codehealthFindingId/v1":"e1a0a6fdd72c13e74755faf1e431c418f91498756593d6144ad2d5937da0c117"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (68 corresponding lines): agent/src/trading/connectors/dhan/sdk.py:453-523 | agent/src/trading/connectors/shoonya/sdk.py:434-501 \u2014 These two members are one piece of code written twice and then edited apart: 68 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/dhan/sdk.py"},"region":{"startLine":453}}}],"partialFingerprints":{"codehealthFindingId/v1":"63b7cb18b0b8dc024b5d73100425950096b685a14dc11b7f8f5240529d20f513"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (24 corresponding lines): agent/src/tools/trade_journal_parsers.py:381-405 | agent/src/tools/trade_journal_parsers.py:668-691 \u2014 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 \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/trade_journal_parsers.py"},"region":{"startLine":381}}}],"partialFingerprints":{"codehealthFindingId/v1":"33dd9d7ba29dd68c1e6a1c491f1d842348fa13a762a8a7ae9ad94397190aa17a"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (16 corresponding lines): agent/src/factors/zoo/gtja191/alpha_050.py:49-65 | agent/src/factors/zoo/gtja191/alpha_051.py:49-64 \u2014 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 \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/gtja191/alpha_050.py"},"region":{"startLine":49}}}],"partialFingerprints":{"codehealthFindingId/v1":"8b3bc72be8fb4bd60f7f92d48546b792a81c6daec36cb350cb99d6da6f4de40d"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (57 corresponding lines): agent/backtest/runner.py:1137-1193 | agent/backtest/runner.py:1205-1272 \u2014 These two members are one piece of code written twice and then edited apart: 57 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/runner.py"},"region":{"startLine":1137}}}],"partialFingerprints":{"codehealthFindingId/v1":"07b1bee5dea804799974f8a8827e19944a1fdefa482b67da965253ba715f69eb"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (29 corresponding lines): agent/src/tools/web_search_tool.py:70-101 | agent/src/tools/web_search_tool.py:105-133 \u2014 These two members are one piece of code written twice and then edited apart: 29 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/web_search_tool.py"},"region":{"startLine":70}}}],"partialFingerprints":{"codehealthFindingId/v1":"c15dc1192544c0ac5ddf1627cd10d39082db32174f7456b46cd29e7c4c38b512"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (44 corresponding lines): agent/src/api/alpha_routes.py:265-311 | agent/src/api/alpha_routes.py:317-360 \u2014 These two members are one piece of code written twice and then edited apart: 44 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/api/alpha_routes.py"},"region":{"startLine":265}}}],"partialFingerprints":{"codehealthFindingId/v1":"5e0a6307ec74ea9f22d7593cab694d64d020f67c3c18044f13ed3a720105f15b"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (26 corresponding lines): agent/src/config/writer.py:118-151 | agent/src/tools/background_store.py:167-192 \u2014 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 \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/config/writer.py"},"region":{"startLine":118}}}],"partialFingerprints":{"codehealthFindingId/v1":"14cd95c630ec2476792a894b8fd0d8095f6f054e746de8d414a8a17e7e028e36"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (39 corresponding lines): agent/src/tools/institutional_holdings_tool.py:823-861 | agent/src/tools/institutional_holdings_tool.py:1115-1161 \u2014 These two members are one piece of code written twice and then edited apart: 39 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/institutional_holdings_tool.py"},"region":{"startLine":823}}}],"partialFingerprints":{"codehealthFindingId/v1":"bfe9fdc2e52110d0d8765a1d4248575c5b791f2ca4b020dd3457a4cde30998e2"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (32 corresponding lines): agent/src/tools/skill_writer_tool.py:350-381 | agent/src/tools/skill_writer_tool.py:385-420 \u2014 These two members are one piece of code written twice and then edited apart: 32 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/skill_writer_tool.py"},"region":{"startLine":350}}}],"partialFingerprints":{"codehealthFindingId/v1":"d8585cca110fd2eb5bd268c5809320f16d2daa53a8ae7445050d3ddb5009027f"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 18\u002B corresponding lines): agent/src/factors/zoo/alpha101/alpha_077.py:56-73 | agent/src/factors/zoo/alpha101/alpha_088.py:56-73 | agent/src/factors/zoo/alpha101/alpha_092.py:56-80 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 18 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\u0027 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/alpha101/alpha_077.py"},"region":{"startLine":56}}}],"partialFingerprints":{"codehealthFindingId/v1":"d91f12222ba797f4ffa582261720daa5038fb6bd84e1497f3852bc807afacea6"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (16 corresponding lines): agent/src/tools/paper_trade/data.py:151-166 | agent/src/tools/paper_trade/data_5m.py:239-266 \u2014 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 \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/paper_trade/data.py"},"region":{"startLine":151}}}],"partialFingerprints":{"codehealthFindingId/v1":"770f150aaf17beeca2ff8ea89b5e84eca80765abbaff54a42620e52fbdb6707f"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (37 corresponding lines): agent/src/live/enforcement.py:247-289 | agent/src/live/enforcement.py:744-780 \u2014 These two members are one piece of code written twice and then edited apart: 37 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/live/enforcement.py"},"region":{"startLine":247}}}],"partialFingerprints":{"codehealthFindingId/v1":"779a2953727700dfeba84c11f53aff0861622395d2f914430f8d232253317ffb"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 59\u002B corresponding lines): agent/src/quantlib/valuation/artifact.py:701-769 | agent/src/quantlib/valuation/artifact.py:780-838 | agent/src/quantlib/valuation/artifact.py:851-921 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 59 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\u0027 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/valuation/artifact.py"},"region":{"startLine":701}}}],"partialFingerprints":{"codehealthFindingId/v1":"358d378414cdef72afb689ec516ec889bb65919d4366984fbbbc9af36b7093b3"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (32 corresponding lines): agent/cli/onboard.py:217-248 | agent/cli/onboard.py:253-287 \u2014 These two members are one piece of code written twice and then edited apart: 32 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/onboard.py"},"region":{"startLine":217}}}],"partialFingerprints":{"codehealthFindingId/v1":"89976c730488f65819795cebb3a52535b83b0f3504030deffde4f1c1007c7cb0"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (43 corresponding lines): agent/src/entities/ingest.py:94-136 | agent/src/entities/ingest.py:748-797 \u2014 These two members are one piece of code written twice and then edited apart: 43 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/entities/ingest.py"},"region":{"startLine":94}}}],"partialFingerprints":{"codehealthFindingId/v1":"64f00a380f831c763f238f73a406784e198f44b2eb0606c91fed6a4d9e172f4c"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (28 corresponding lines): agent/backtest/optimizers/max_diversification.py:19-48 | agent/backtest/optimizers/mean_variance.py:37-64 \u2014 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 \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/optimizers/max_diversification.py"},"region":{"startLine":19}}}],"partialFingerprints":{"codehealthFindingId/v1":"f8c8b439b736c9ba4c11e192010f319cea2c70210db68c4fc77ac6caece81e79"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (14 corresponding lines): agent/src/trading/connectors/okx/sdk.py:79-93 | agent/src/trading/connectors/shoonya/sdk.py:91-104 \u2014 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 \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/okx/sdk.py"},"region":{"startLine":79}}}],"partialFingerprints":{"codehealthFindingId/v1":"06b818e76a2303807acdf2cd569cdd1e86fde52c336380199900c8cee71a4041"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (22 corresponding lines): agent/src/trading/connectors/etoro/copy_trading.py:53-74 | agent/src/trading/connectors/etoro/copy_trading.py:85-125 \u2014 These two members are one piece of code written twice and then edited apart: 22 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/etoro/copy_trading.py"},"region":{"startLine":53}}}],"partialFingerprints":{"codehealthFindingId/v1":"8ecc2bbf052b82915defe9da4d5d93c66387e4044e4dd0d855e2cd9f48bdcd5f"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (33 corresponding lines): agent/backtest/loaders/mt5_loader.py:209-241 | agent/backtest/loaders/tickerall_loader.py:233-299 \u2014 These two members are one piece of code written twice and then edited apart: 33 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/mt5_loader.py"},"region":{"startLine":209}}}],"partialFingerprints":{"codehealthFindingId/v1":"cd68b769022c4f306a6bc82b19852a2962cacbb9ee974e82a4340ebe23680caf"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (53 corresponding lines): agent/backtest/engines/korea_equity.py:176-228 | agent/backtest/engines/vietnam_equity.py:269-326 \u2014 These two members are one piece of code written twice and then edited apart: 53 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/engines/korea_equity.py"},"region":{"startLine":176}}}],"partialFingerprints":{"codehealthFindingId/v1":"b8fea2010242755320c10d60833227081b88d9d2bdab6672f30474105f7fb49b"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (31 corresponding lines): agent/src/skills/candlestick/example_signal_engine.py:347-377 | agent/src/skills/candlestick/example_signal_engine.py:381-411 \u2014 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 \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/skills/candlestick/example_signal_engine.py"},"region":{"startLine":347}}}],"partialFingerprints":{"codehealthFindingId/v1":"21f2675ebed29465d5a3f475fb62e6c71a837ba3fb8d626bf4f9e7602787e07a"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (28 corresponding lines): agent/src/skills/okx-market/scripts/candle_data_example.py:18-45 | agent/src/skills/okx-market/scripts/candle_data_example.py:49-76 \u2014 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 \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/skills/okx-market/scripts/candle_data_example.py"},"region":{"startLine":18}}}],"partialFingerprints":{"codehealthFindingId/v1":"2bbac45b5b4fd193822dc6b0279c62760b6dc09954a4106dbbfb59527d74d411"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (34 corresponding lines): agent/src/trading/connectors/kis/sdk.py:430-467 | agent/src/trading/connectors/toss/sdk.py:350-383 \u2014 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 \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/kis/sdk.py"},"region":{"startLine":430}}}],"partialFingerprints":{"codehealthFindingId/v1":"48936b6c6cf0cded4b1d1fcba1aa12232a05afbbc78938d2d4daec0bb61ca2c8"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (4 members, 16\u002B corresponding lines): agent/src/trading/connectors/alpaca/sdk.py:91-106 | agent/src/trading/connectors/longbridge/sdk.py:88-106 | agent/src/trading/connectors/toss/sdk.py:87-103 | agent/src/trading/connectors/trading212/sdk.py:74-89 \u2014 These 4 members are one piece of code written 4 times and then edited apart: every two of them correspond over at least 16 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\u0027 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/alpaca/sdk.py"},"region":{"startLine":91}}}],"partialFingerprints":{"codehealthFindingId/v1":"db62fdf52e324c2acb053279aa19ee8950fca6be7fd10391a85afc8443853403"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (19 corresponding lines): agent/backtest/metrics.py:526-562 | agent/backtest/metrics.py:569-587 \u2014 These two members are one piece of code written twice and then edited apart: 19 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/metrics.py"},"region":{"startLine":526}}}],"partialFingerprints":{"codehealthFindingId/v1":"bf0e5658170efe3ada4cb4544781fc28ec9812aa695c90a6b8111b0ac54f4e7e"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (28 corresponding lines): agent/src/channels/mochat.py:551-582 | agent/src/channels/mochat.py:585-612 \u2014 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 \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/mochat.py"},"region":{"startLine":551}}}],"partialFingerprints":{"codehealthFindingId/v1":"7b2a68ec762ac628e024bb84ecf0431e0938a33b765e4c0a01f4e46efb8c7e1a"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (25 corresponding lines): agent/src/channels/feishu.py:1389-1413 | agent/src/channels/feishu.py:1416-1447 \u2014 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 \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/feishu.py"},"region":{"startLine":1389}}}],"partialFingerprints":{"codehealthFindingId/v1":"289f0ad801f367ebf583837ec46eb885b99de8e5665ca91477c771522083cdc6"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (30 corresponding lines): agent/src/portfolio/config.py:291-320 | agent/src/trading/connections.py:429-458 \u2014 These two members are one piece of code written twice and then edited apart: 30 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/portfolio/config.py"},"region":{"startLine":291}}}],"partialFingerprints":{"codehealthFindingId/v1":"29efb3dff2deea6e80ff300df16082bcf5ccf1502ac89d2fda9f76e16f8872ad"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (23 corresponding lines): agent/src/quantlib/copula.py:63-87 | agent/src/quantlib/copula.py:104-126 \u2014 These two members are one piece of code written twice and then edited apart: 23 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/copula.py"},"region":{"startLine":63}}}],"partialFingerprints":{"codehealthFindingId/v1":"a055eae49ca0472843b3e6e571fec3c5abf4226fdda599b8bd49948b31d99b6a"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (18 corresponding lines): agent/src/factors/zoo/gtja191/alpha_115.py:54-71 | agent/src/factors/zoo/gtja191/alpha_140.py:54-73 \u2014 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 \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/gtja191/alpha_115.py"},"region":{"startLine":54}}}],"partialFingerprints":{"codehealthFindingId/v1":"b99567678efb405ad08a0ed59bd879413f0c31f28d985c7887fa33a6e62bca93"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (32 corresponding lines): agent/src/channels/feishu.py:1641-1673 | agent/src/channels/feishu.py:1693-1724 \u2014 These two members are one piece of code written twice and then edited apart: 32 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/feishu.py"},"region":{"startLine":1641}}}],"partialFingerprints":{"codehealthFindingId/v1":"cbf768d94d1a8e9935c90093c6e1b11dbcc4d1a602e4f507e6c4b860035809e7"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (19 corresponding lines): agent/scripts/w4a_patch_blog.py:136-154 | agent/scripts/w4a_patch_blog.py:158-176 \u2014 These two members are one piece of code written twice and then edited apart: 19 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/scripts/w4a_patch_blog.py"},"region":{"startLine":136}}}],"partialFingerprints":{"codehealthFindingId/v1":"470d529165b0e9cffe87979ea80c872f8158af7afe0ffeb00f0fb2c1e6077260"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (7 members, 36\u002B corresponding lines): agent/backtest/loaders/alphavantage_loader.py:121-168 | agent/backtest/loaders/finnhub_loader.py:176-233 | agent/backtest/loaders/fmp_loader.py:102-148 | agent/backtest/loaders/pykrx_loader.py:101-144 | agent/backtest/loaders/sina_loader.py:146-181 | agent/backtest/loaders/stooq_loader.py:186-231 | agent/backtest/loaders/tiingo_loader.py:291-346 \u2014 These 7 members are one piece of code written 7 times and then edited apart: every two of them correspond over at least 36 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\u0027 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 7 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/alphavantage_loader.py"},"region":{"startLine":121}}}],"partialFingerprints":{"codehealthFindingId/v1":"a61ec5f16cb24c24c29b1ea187d5ba9f0190751de98693c2c03b48387cf42065"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (31 corresponding lines): agent/src/channels/feishu.py:1792-1823 | agent/src/channels/feishu.py:1826-1856 \u2014 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 \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/feishu.py"},"region":{"startLine":1792}}}],"partialFingerprints":{"codehealthFindingId/v1":"66d76a663ed7a7c44c6d1ad52db0461d4eef5427c37dc17b1a4120706448a118"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (26 corresponding lines): agent/src/channels/weixin.py:1508-1533 | agent/src/channels/weixin.py:1537-1566 \u2014 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 \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/weixin.py"},"region":{"startLine":1508}}}],"partialFingerprints":{"codehealthFindingId/v1":"1571ef53c5a610c4ff1792c14a284c0d16fb20df61ea201dbf41a324f3da31e0"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (17 corresponding lines): agent/src/factors/zoo/alpha101/alpha_079.py:87-103 | agent/src/factors/zoo/alpha101/alpha_095.py:61-77 \u2014 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 \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/alpha101/alpha_079.py"},"region":{"startLine":87}}}],"partialFingerprints":{"codehealthFindingId/v1":"026f9387f7bcb0c8dc5b66167ee844c5fbee48212656e7738ff0085f2318d7cb"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (4 members, 15\u002B corresponding lines): agent/src/trading/connectors/etoro/copy_trading.py:134-151 | agent/src/trading/connectors/etoro/copy_trading.py:161-187 | agent/src/trading/connectors/etoro/trading.py:115-136 | agent/src/trading/connectors/etoro/trading.py:201-215 \u2014 These 4 members are one piece of code written 4 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\u0027 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/etoro/copy_trading.py"},"region":{"startLine":134}}}],"partialFingerprints":{"codehealthFindingId/v1":"643852f178fa8bd8a3dc60be3664adade3fe6861a9a3cdf80d477608352e3a0b"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (23 corresponding lines): agent/src/trading/connectors/dhan/sdk.py:287-310 | agent/src/trading/connectors/shoonya/sdk.py:284-306 \u2014 These two members are one piece of code written twice and then edited apart: 23 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/dhan/sdk.py"},"region":{"startLine":287}}}],"partialFingerprints":{"codehealthFindingId/v1":"087791c18ac148c0c5e0ef109b89c5c6d0f9ce2034468bf58c2b2468e00b9af5"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (27 corresponding lines): agent/src/trading/connectors/futu/sdk.py:308-334 | agent/src/trading/connectors/futu/sdk.py:338-365 \u2014 These two members are one piece of code written twice and then edited apart: 27 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/futu/sdk.py"},"region":{"startLine":308}}}],"partialFingerprints":{"codehealthFindingId/v1":"be07b576bcf10f320782d03d7e584e100b3c6675a7079213441404ffcc2f04e0"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (23 corresponding lines): agent/src/quantlib/fundmath.py:1068-1090 | agent/src/quantlib/fundmath.py:1964-1990 \u2014 These two members are one piece of code written twice and then edited apart: 23 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/fundmath.py"},"region":{"startLine":1068}}}],"partialFingerprints":{"codehealthFindingId/v1":"eec8217010f6c57676e5ded4451c686023209ca4879c69be608d26f56459d6ec"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (35 corresponding lines): agent/src/trading/connectors/alpaca/sdk.py:266-300 | agent/src/trading/connectors/ibkr/local.py:193-241 \u2014 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 \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/alpaca/sdk.py"},"region":{"startLine":266}}}],"partialFingerprints":{"codehealthFindingId/v1":"483b9b9b03003055b8d60c34a652704e4af1a49790366e7add874fd7a80c0d0d"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (28 corresponding lines): agent/src/skills/candlestick/example_signal_engine.py:415-442 | agent/src/skills/candlestick/example_signal_engine.py:446-473 \u2014 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 \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/skills/candlestick/example_signal_engine.py"},"region":{"startLine":415}}}],"partialFingerprints":{"codehealthFindingId/v1":"f7d80f6fff4148116f50ca30b0c0c117ff1ddd24bb82338e58061cf7fd3e35ed"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (6 members, 12\u002B corresponding lines): agent/src/trading/connectors/dhan/sdk.py:96-107 | agent/src/trading/connectors/etoro/client.py:80-91 | agent/src/trading/connectors/kis/sdk.py:139-152 | agent/src/trading/connectors/tiger/sdk.py:85-97 | agent/src/trading/connectors/upbit/sdk.py:90-101 | agent/src/trading/connectors/zerodha/sdk.py:93-104 \u2014 These 6 members are one piece of code written 6 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\u0027 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/dhan/sdk.py"},"region":{"startLine":96}}}],"partialFingerprints":{"codehealthFindingId/v1":"697581eaa311447f420bbc9eb86ecd64097305d22162b7c5e8750af1f47ba4e9"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (22 corresponding lines): agent/src/quantlib/impact.py:128-149 | agent/src/quantlib/impact.py:256-292 \u2014 These two members are one piece of code written twice and then edited apart: 22 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/impact.py"},"region":{"startLine":128}}}],"partialFingerprints":{"codehealthFindingId/v1":"022c74858acd05b0469185bae6fd727f2f969109a30be9b417d86daeb941be68"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 21\u002B corresponding lines): agent/src/api/sessions_routes.py:280-300 | agent/src/api/sessions_routes.py:304-326 | agent/src/api/sessions_routes.py:355-376 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 21 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\u0027 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/api/sessions_routes.py"},"region":{"startLine":280}}}],"partialFingerprints":{"codehealthFindingId/v1":"22f36f52a451499a796cbc56ae115482ee58146627b252f1a9cd11e71370179c"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (21 corresponding lines): agent/src/channels/websocket.py:1006-1033 | agent/src/channels/websocket.py:1040-1060 \u2014 These two members are one piece of code written twice and then edited apart: 21 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/websocket.py"},"region":{"startLine":1006}}}],"partialFingerprints":{"codehealthFindingId/v1":"4ac550d5cb32d4c444f5d71eb64ecf0c83b430e60444540b6f2ed10260bf8cf7"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (16 corresponding lines): agent/src/goal/store.py:110-125 | agent/src/strategy_store/sqlite_store.py:135-153 \u2014 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 \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/goal/store.py"},"region":{"startLine":110}}}],"partialFingerprints":{"codehealthFindingId/v1":"f4c258489f129c78899068c769e408ab8a98b8f3c226e1960142123d931d4039"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (21 corresponding lines): agent/mcp_server.py:3057-3077 | agent/mcp_server.py:3082-3102 \u2014 These two members are one piece of code written twice and then edited apart: 21 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/mcp_server.py"},"region":{"startLine":3057}}}],"partialFingerprints":{"codehealthFindingId/v1":"99ce217868cc1254ecdd461e36aa275b059cc969e8b67780755ec89b39087085"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (60 corresponding lines): agent/src/quantlib/valuation/comps.py:431-521 | agent/src/quantlib/valuation/comps.py:533-592 \u2014 These two members are one piece of code written twice and then edited apart: 60 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/valuation/comps.py"},"region":{"startLine":431}}}],"partialFingerprints":{"codehealthFindingId/v1":"40ee07b82c2e3c94ff17d4381726261ed6c9d2c3453a5b1bb42f774339675824"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (4 members, 20\u002B corresponding lines): agent/src/trading/service.py:224-243 | agent/src/trading/service.py:272-291 | agent/src/trading/service.py:300-325 | agent/src/trading/service.py:338-376 \u2014 These 4 members are one piece of code written 4 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\u0027 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/service.py"},"region":{"startLine":224}}}],"partialFingerprints":{"codehealthFindingId/v1":"48112f33c25ef1df4a860737b1f4c7eecab48194ad5151f849f6ba1192cad4c3"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (4 members, 18\u002B corresponding lines): agent/src/factors/zoo/gtja191/alpha_108.py:55-75 | agent/src/factors/zoo/gtja191/alpha_121.py:55-72 | agent/src/factors/zoo/gtja191/alpha_131.py:55-72 | agent/src/factors/zoo/gtja191/alpha_156.py:55-74 \u2014 These 4 members are one piece of code written 4 times and then edited apart: every two of them correspond over at least 18 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\u0027 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/gtja191/alpha_108.py"},"region":{"startLine":55}}}],"partialFingerprints":{"codehealthFindingId/v1":"8482abb725c8f9f1cc609d58a558a1c660a210d48e35be8f45a33d74459841d3"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (26 corresponding lines): agent/src/trading/connectors/etoro/instruments.py:459-484 | agent/src/trading/connectors/etoro/sdk.py:480-505 \u2014 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 \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/etoro/instruments.py"},"region":{"startLine":459}}}],"partialFingerprints":{"codehealthFindingId/v1":"a025511e2151477f4ec6e2326c2bcc381d1dae725c48a97ad64fc04a57c7fdf8"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (23 corresponding lines): agent/src/skills/tushare/scripts/fund_data_example.py:64-86 | agent/src/skills/tushare/scripts/stock_data_example.py:64-87 \u2014 These two members are one piece of code written twice and then edited apart: 23 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/skills/tushare/scripts/fund_data_example.py"},"region":{"startLine":64}}}],"partialFingerprints":{"codehealthFindingId/v1":"590a436c94b32ff9a7be9226f93f59c5664ae95b463cc802c0d80973e8617b31"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (15 corresponding lines): agent/src/tools/remember_tool.py:102-122 | agent/src/tools/remember_tool.py:169-183 \u2014 These two members are one piece of code written twice and then edited apart: 15 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/remember_tool.py"},"region":{"startLine":102}}}],"partialFingerprints":{"codehealthFindingId/v1":"e4fbce47be2ec11c51752e339ceaa48dd235524a094837668d1d0dd279a8e0c7"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (23 corresponding lines): agent/src/live/order_guard.py:766-795 | agent/src/live/sdk_order_gate.py:1061-1083 \u2014 These two members are one piece of code written twice and then edited apart: 23 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/live/order_guard.py"},"region":{"startLine":766}}}],"partialFingerprints":{"codehealthFindingId/v1":"96b8e10d4c875577f7ec1df4515c9d7b90d0162fa54efa461adafc305308a6c8"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (14 corresponding lines): agent/src/factors/base.py:335-348 | agent/src/factors/base.py:352-365 \u2014 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 \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/base.py"},"region":{"startLine":335}}}],"partialFingerprints":{"codehealthFindingId/v1":"871604ab72448ea2df26f1b8cdc0036356537f76630dee67bd13abd9dc86bfe4"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (10 corresponding lines): agent/src/factors/base.py:234-249 | agent/src/factors/base.py:253-262 \u2014 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 \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/base.py"},"region":{"startLine":234}}}],"partialFingerprints":{"codehealthFindingId/v1":"3381173c542c95992f52f40726cf89801dad46500c461880a5d6123e8caee209"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (15 corresponding lines): agent/backtest/loaders/yahoo_client.py:332-346 | agent/backtest/loaders/yahoo_client.py:391-408 \u2014 These two members are one piece of code written twice and then edited apart: 15 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/yahoo_client.py"},"region":{"startLine":332}}}],"partialFingerprints":{"codehealthFindingId/v1":"8832338a282be62eb3d45c1f7073ee6bfa5ca3aa9f5cf41fa45937b75dc509b7"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (20 corresponding lines): agent/backtest/loaders/akshare_loader.py:246-265 | agent/backtest/loaders/akshare_loader.py:274-293 \u2014 These two members are one piece of code written twice and then edited apart: 20 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/akshare_loader.py"},"region":{"startLine":246}}}],"partialFingerprints":{"codehealthFindingId/v1":"78d1de76ccbe6f7e73c10942f3230e455de63f5a15d822cdcc1c153c115dd9e2"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (16 corresponding lines): agent/src/factors/zoo/gtja191/alpha_116.py:54-69 | agent/src/factors/zoo/gtja191/alpha_147.py:54-70 \u2014 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 \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/gtja191/alpha_116.py"},"region":{"startLine":54}}}],"partialFingerprints":{"codehealthFindingId/v1":"3ab0bf9ebed65e7b7aa9f22d661e41acd755ee3be38dbc5418f78c6bb89e4194"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 24\u002B corresponding lines): agent/src/trading/connectors/kis/sdk.py:248-271 | agent/src/trading/connectors/toss/sdk.py:180-204 | agent/src/trading/connectors/trading212/sdk.py:163-195 \u2014 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\u0027 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/kis/sdk.py"},"region":{"startLine":248}}}],"partialFingerprints":{"codehealthFindingId/v1":"e3d3504509e731340f37c1d129cf1fd75e28ed004147ccb7446cf20fc986da3d"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (27 corresponding lines): agent/backtest/loaders/eastmoney_client.py:145-174 | agent/src/tools/iwencai_tool.py:102-128 \u2014 These two members are one piece of code written twice and then edited apart: 27 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/eastmoney_client.py"},"region":{"startLine":145}}}],"partialFingerprints":{"codehealthFindingId/v1":"5b78e67724272f45e81f8adb015517feb6f6aa683c417fadcbc4b7eeb47ae08b"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (17 corresponding lines): agent/src/factors/zoo/alpha101/alpha_049.py:88-104 | agent/src/factors/zoo/alpha101/alpha_051.py:88-104 \u2014 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 \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/alpha101/alpha_049.py"},"region":{"startLine":88}}}],"partialFingerprints":{"codehealthFindingId/v1":"7e16541ff5a588dcc3f0ad41a958db4e778aa1221fb80d20d4a35c31142b4846"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (29 corresponding lines): agent/src/live/order_guard.py:545-575 | agent/src/live/sdk_order_gate.py:832-860 \u2014 These two members are one piece of code written twice and then edited apart: 29 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/live/order_guard.py"},"region":{"startLine":545}}}],"partialFingerprints":{"codehealthFindingId/v1":"4f77ac5597125651c11546cf4d07c9c8e8c803800dcd5769a9e60d26fa949cb0"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 24\u002B corresponding lines): agent/backtest/loaders/eastmoney_client.py:290-337 | agent/src/tools/market_screener_tool.py:122-168 | agent/src/tools/northbound_tool.py:131-154 \u2014 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\u0027 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/eastmoney_client.py"},"region":{"startLine":290}}}],"partialFingerprints":{"codehealthFindingId/v1":"157599413cd630f13bcd7dea290d886127fe0c196837a6eb627bf325b95d78ac"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (4 members, 14\u002B corresponding lines): agent/src/factors/zoo/alpha101/alpha_068.py:56-70 | agent/src/factors/zoo/alpha101/alpha_074.py:61-79 | agent/src/factors/zoo/alpha101/alpha_086.py:61-75 | agent/src/factors/zoo/alpha101/alpha_099.py:61-74 \u2014 These 4 members are one piece of code written 4 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\u0027 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/alpha101/alpha_068.py"},"region":{"startLine":56}}}],"partialFingerprints":{"codehealthFindingId/v1":"0375bd8e2b561355410a6e4db95fa165c9bd750aaeaa722e0ceff585ef00130b"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (38 corresponding lines): agent/src/live/runtime/sweep_latch.py:75-113 | agent/src/live/runtime/sweep_latch.py:227-264 \u2014 These two members are one piece of code written twice and then edited apart: 38 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/live/runtime/sweep_latch.py"},"region":{"startLine":75}}}],"partialFingerprints":{"codehealthFindingId/v1":"2c30231dcee826b40ac148536d430bbea46f5abdc30e114c42ca277edf9683c8"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (12 corresponding lines): agent/mcp_server.py:275-287 | agent/mcp_server.py:303-314 \u2014 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 \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/mcp_server.py"},"region":{"startLine":275}}}],"partialFingerprints":{"codehealthFindingId/v1":"b652b431562b28a4816bbb8deafcaecbdb1a16ec4add8ae64759a7491e0fbc27"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (23 corresponding lines): agent/src/live/runtime/jobstore.py:106-129 | agent/src/scheduled_research/store.py:105-127 \u2014 These two members are one piece of code written twice and then edited apart: 23 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/live/runtime/jobstore.py"},"region":{"startLine":106}}}],"partialFingerprints":{"codehealthFindingId/v1":"4ed4b5f19fcd8e038d603464fce17f2fb9d8b1465f39881a4cebaa5108040b83"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 35\u002B corresponding lines): agent/src/quantlib/valuation/artifact.py:1181-1219 | agent/src/quantlib/valuation/artifact.py:1305-1339 | agent/src/quantlib/valuation/artifact.py:1418-1456 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 35 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\u0027 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/valuation/artifact.py"},"region":{"startLine":1181}}}],"partialFingerprints":{"codehealthFindingId/v1":"7cdb0815eb9e27b4e003f449c2c2a3e5f04f2ab1b0cec0ea7debefe5229372d5"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (26 corresponding lines): agent/backtest/engines/china_a.py:204-229 | agent/backtest/engines/india_equity.py:129-166 \u2014 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 \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/engines/china_a.py"},"region":{"startLine":204}}}],"partialFingerprints":{"codehealthFindingId/v1":"88ef963476cec5f3c1e36022bbd964267240b98d05ee1aa23f7e1ea2856f9da0"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (19 corresponding lines): agent/src/live/runtime/jobstore.py:166-193 | agent/src/scheduled_research/store.py:242-260 \u2014 These two members are one piece of code written twice and then edited apart: 19 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/live/runtime/jobstore.py"},"region":{"startLine":166}}}],"partialFingerprints":{"codehealthFindingId/v1":"304183040ea3fd5fb635afe61fceb8e5ce4efb046f2783902ab0ba0978d6af6d"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (17 corresponding lines): agent/src/providers/settings.py:130-146 | agent/src/trading/tap_forward.py:50-76 \u2014 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 \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/providers/settings.py"},"region":{"startLine":130}}}],"partialFingerprints":{"codehealthFindingId/v1":"82116450c8940463514280dc0402d9b184615c146129d831ef315472d00cb99f"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (10 corresponding lines): agent/src/factors/zoo/alpha101/alpha_066.py:55-68 | agent/src/factors/zoo/gtja191/alpha_087.py:50-59 \u2014 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 \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/alpha101/alpha_066.py"},"region":{"startLine":55}}}],"partialFingerprints":{"codehealthFindingId/v1":"984f57d2b3b906db57f55d2287371948e6648152db9ef27d239653cf32f34a24"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 14\u002B corresponding lines): agent/src/factors/zoo/alpha101/alpha_075.py:56-69 | agent/src/factors/zoo/gtja191/alpha_101.py:56-73 | agent/src/factors/zoo/gtja191/alpha_123.py:55-71 \u2014 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\u0027 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/alpha101/alpha_075.py"},"region":{"startLine":56}}}],"partialFingerprints":{"codehealthFindingId/v1":"fbc1e68fd8ecb7dfc7894aa5318b3a705636bf2aa43356574d981255173a8951"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (13 corresponding lines): agent/src/factors/zoo/alpha101/alpha_089.py:86-98 | agent/src/factors/zoo/alpha101/alpha_097.py:86-98 \u2014 These two members are one piece of code written twice and then edited apart: 13 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/alpha101/alpha_089.py"},"region":{"startLine":86}}}],"partialFingerprints":{"codehealthFindingId/v1":"9d4143734a11592b8b5eb87ef7ba57fa2126f8c3fb76cf667adea62c88039660"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (16 corresponding lines): agent/src/factors/zoo/gtja191/alpha_102.py:54-70 | agent/src/factors/zoo/gtja191/alpha_162.py:54-69 \u2014 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 \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/gtja191/alpha_102.py"},"region":{"startLine":54}}}],"partialFingerprints":{"codehealthFindingId/v1":"70270ed29628879927ea2d852b3bee07f7df62fbd3443c8c63af17169895a41b"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 7\u002B corresponding lines): agent/src/factors/zoo/gtja191/alpha_061.py:50-56 | agent/src/factors/zoo/gtja191/alpha_077.py:50-58 | agent/src/factors/zoo/gtja191/alpha_092.py:50-57 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 7 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\u0027 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/gtja191/alpha_061.py"},"region":{"startLine":50}}}],"partialFingerprints":{"codehealthFindingId/v1":"311b7c46557abfeb71bf8f0ef0723f755c7c7236298fa0f7824f6fe78c5e3ae6"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (16 corresponding lines): agent/src/skills/technical-basic/example_signal_engine.py:14-29 | agent/src/tools/technical_indicator_tool.py:175-193 \u2014 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 \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/skills/technical-basic/example_signal_engine.py"},"region":{"startLine":14}}}],"partialFingerprints":{"codehealthFindingId/v1":"46cbdfa9992c243a3f74adb8a616f519cbcc4c90e573a0641f136a3dfd7880ba"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (10 corresponding lines): agent/backtest/loaders/yahoo_client.py:350-359 | agent/backtest/loaders/yahoo_client.py:412-421 \u2014 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 \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/yahoo_client.py"},"region":{"startLine":350}}}],"partialFingerprints":{"codehealthFindingId/v1":"0592195e895f7f57c952e0b281b4880c7b768660b650478d6a088d04061f9bb0"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (13 corresponding lines): agent/src/factors/zoo/alpha101/alpha_063.py:91-105 | agent/src/factors/zoo/alpha101/alpha_093.py:86-98 \u2014 These two members are one piece of code written twice and then edited apart: 13 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/alpha101/alpha_063.py"},"region":{"startLine":91}}}],"partialFingerprints":{"codehealthFindingId/v1":"c7e04c444f355802260dd88e44e3fe7ce1fc1804c0f3dc6157554b5e376b5a75"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (6 members, 15\u002B corresponding lines): agent/src/tools/trading_connector_tool.py:933-950 | agent/src/tools/trading_connector_tool.py:972-986 | agent/src/tools/trading_connector_tool.py:1061-1078 | agent/src/tools/trading_connector_tool.py:1108-1126 | agent/src/tools/trading_connector_tool.py:1148-1162 | agent/src/tools/trading_connector_tool.py:1189-1205 \u2014 These 6 members are one piece of code written 6 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\u0027 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/trading_connector_tool.py"},"region":{"startLine":933}}}],"partialFingerprints":{"codehealthFindingId/v1":"5f6bf079f9a5644b5c83a1c1386f939913c6b9d7200f4410df2a3ee4b07e085e"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (11 corresponding lines): agent/src/trading/connectors/etoro/sdk.py:182-196 | agent/src/trading/connectors/etoro/sdk.py:208-218 \u2014 These two members are one piece of code written twice and then edited apart: 11 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/etoro/sdk.py"},"region":{"startLine":182}}}],"partialFingerprints":{"codehealthFindingId/v1":"c10fbe2a0d50f575b797bb4f5d9dc8170d0e6e932ca30255d4e7269e4221f674"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (25 corresponding lines): agent/src/memory/compression.py:84-108 | agent/src/memory/semantic_links.py:74-101 \u2014 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 \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/memory/compression.py"},"region":{"startLine":84}}}],"partialFingerprints":{"codehealthFindingId/v1":"d111d3db23944a9a63d290c1172598fd97a960f4128fc7070203dafa6cacca4f"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (16 corresponding lines): agent/src/factors/zoo/alpha101/alpha_083.py:67-82 | agent/src/factors/zoo/gtja191/alpha_114.py:55-73 \u2014 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 \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/alpha101/alpha_083.py"},"region":{"startLine":67}}}],"partialFingerprints":{"codehealthFindingId/v1":"bc4cca9d953199a00a17f0ed8712077f40015752ac142afa29592e4a982d3053"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (17 corresponding lines): agent/src/factors/zoo/gtja191/alpha_119.py:55-71 | agent/src/factors/zoo/gtja191/alpha_138.py:55-71 \u2014 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 \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/gtja191/alpha_119.py"},"region":{"startLine":55}}}],"partialFingerprints":{"codehealthFindingId/v1":"99457385f9bd85f5d52d518b76c7abdd9fb3e5acccaec33a7611e1a10cac3bc3"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (14 corresponding lines): agent/cli/_legacy.py:968-995 | agent/src/api/sessions_routes.py:263-276 \u2014 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 \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":968}}}],"partialFingerprints":{"codehealthFindingId/v1":"e03c00233b428cd79572b4cf7a2f013777b885b6ec357dee65545ad0b794fbfc"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (16 corresponding lines): agent/src/api/security.py:470-504 | agent/src/api/security.py:644-659 \u2014 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 \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/api/security.py"},"region":{"startLine":470}}}],"partialFingerprints":{"codehealthFindingId/v1":"ccc03c3dbf2969418e4770aaad31d9510ec6a6ba6cdff943567195125de85734"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (18 corresponding lines): agent/src/factors/zoo/alpha101/alpha_009.py:76-93 | agent/src/factors/zoo/alpha101/alpha_010.py:76-95 \u2014 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 \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/alpha101/alpha_009.py"},"region":{"startLine":76}}}],"partialFingerprints":{"codehealthFindingId/v1":"49264ccf9429f42d63993955e7bbafd6cd117c5d8c8389097e6edd9e21c0a78a"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (10 corresponding lines): agent/src/tools/paper_trade/calendar.py:275-293 | agent/src/tools/paper_trade/engine.py:98-107 \u2014 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 \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/paper_trade/calendar.py"},"region":{"startLine":275}}}],"partialFingerprints":{"codehealthFindingId/v1":"5140bdc1694d48e7808d9f492a7a768b0ccade501fca2a99c26432a6be7601ae"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (13 corresponding lines): agent/src/factors/zoo/alpha101/alpha_065.py:60-73 | agent/src/factors/zoo/alpha101/alpha_078.py:60-72 \u2014 These two members are one piece of code written twice and then edited apart: 13 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/alpha101/alpha_065.py"},"region":{"startLine":60}}}],"partialFingerprints":{"codehealthFindingId/v1":"01498b19597736150b9fd60333837ff65adf4d931280d123ccae24997c125fb3"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (13 corresponding lines): agent/src/providers/chat.py:370-389 | agent/src/providers/chat.py:392-404 \u2014 These two members are one piece of code written twice and then edited apart: 13 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/providers/chat.py"},"region":{"startLine":370}}}],"partialFingerprints":{"codehealthFindingId/v1":"23a1717f7f8bab5e0b3734ff2e57d8f71609f1cb8fec1d940a0353333532c16f"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (9 corresponding lines): agent/src/tools/paper_trade/engine.py:210-218 | agent/src/tools/paper_trade/reconcile.py:123-135 \u2014 These two members are one piece of code written twice and then edited apart: 9 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/paper_trade/engine.py"},"region":{"startLine":210}}}],"partialFingerprints":{"codehealthFindingId/v1":"58b2befc6138da9fb1fd048929d04d0480fbd1a30fbfd0b4ffedae8acc25835e"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (41 corresponding lines): agent/src/tools/sector_tool.py:162-204 | agent/src/tools/sector_tool.py:259-299 \u2014 These two members are one piece of code written twice and then edited apart: 41 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/sector_tool.py"},"region":{"startLine":162}}}],"partialFingerprints":{"codehealthFindingId/v1":"561dc44ce9b59cf85668449b2fedf7fd7d5e1ccf2ef7509a00977b03057cfe0a"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (10 corresponding lines): agent/src/hypotheses/registry.py:371-380 | agent/src/trading/connections.py:172-191 \u2014 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 \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/hypotheses/registry.py"},"region":{"startLine":371}}}],"partialFingerprints":{"codehealthFindingId/v1":"7a9d7fe56b88c6ba675fd308f0bdac59d9c8969d9a2f5c94730eae1b4feb2180"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (19 corresponding lines): agent/src/live/mandate/commit.py:168-186 | agent/src/live/runtime/reconcile.py:577-608 \u2014 These two members are one piece of code written twice and then edited apart: 19 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/live/mandate/commit.py"},"region":{"startLine":168}}}],"partialFingerprints":{"codehealthFindingId/v1":"892707af6c50c6249267f20a84314a1f0d82bfbd8bd6f70e74a7425cbb219d86"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (54 corresponding lines): agent/src/quantlib/fundmath.py:1254-1308 | agent/src/quantlib/fundmath.py:2102-2155 \u2014 These two members are one piece of code written twice and then edited apart: 54 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/fundmath.py"},"region":{"startLine":1254}}}],"partialFingerprints":{"codehealthFindingId/v1":"ab431b1b9dfd9a7a9831285fa96229ab2884651e8f699bf1f8330215c8dedc3e"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (19 corresponding lines): agent/backtest/loaders/nobitex.py:109-127 | agent/backtest/loaders/wallex.py:106-125 \u2014 These two members are one piece of code written twice and then edited apart: 19 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/nobitex.py"},"region":{"startLine":109}}}],"partialFingerprints":{"codehealthFindingId/v1":"3fe2055f666db8bf89910aab37cc5ffcff048c6abf44f72c4c6dd49c1e514573"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (15 corresponding lines): agent/src/factors/zoo/gtja191/alpha_160.py:54-68 | agent/src/factors/zoo/gtja191/alpha_174.py:54-68 \u2014 These two members are one piece of code written twice and then edited apart: 15 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/gtja191/alpha_160.py"},"region":{"startLine":54}}}],"partialFingerprints":{"codehealthFindingId/v1":"fa92ebe3dbef3c3bea6e18bf0251ea24d7390b6b5967ea64ff54b149f234f208"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (12 corresponding lines): agent/src/tools/_arguments.py:9-34 | agent/src/tools/strategy_discovery_tool.py:113-124 \u2014 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 \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/_arguments.py"},"region":{"startLine":9}}}],"partialFingerprints":{"codehealthFindingId/v1":"7489678222c694b022911aaaf8cf4e9638b4c1cc1b42c06051c4863e92bf76fd"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (9 corresponding lines): agent/src/trading/service.py:1113-1129 | agent/src/trading/service.py:1223-1231 \u2014 These two members are one piece of code written twice and then edited apart: 9 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/service.py"},"region":{"startLine":1113}}}],"partialFingerprints":{"codehealthFindingId/v1":"5882d53cac6024a26c3a510813fe01fb59854ba728f5e07a72e8ad5b36097f8e"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (7 corresponding lines): agent/src/factors/zoo/alpha101/alpha_024.py:88-107 | agent/src/factors/zoo/gtja191/alpha_098.py:49-55 \u2014 These two members are one piece of code written twice and then edited apart: 7 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/alpha101/alpha_024.py"},"region":{"startLine":88}}}],"partialFingerprints":{"codehealthFindingId/v1":"d779acc0cacbe789cea9c7b602f8e988b803c0ba13eb4bb152255aa07f848b67"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (16 corresponding lines): agent/src/factors/zoo/gtja191/alpha_125.py:55-70 | agent/src/factors/zoo/gtja191/alpha_130.py:55-71 \u2014 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 \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/gtja191/alpha_125.py"},"region":{"startLine":55}}}],"partialFingerprints":{"codehealthFindingId/v1":"cc086a312b57384f73963abf20d99b13269e2f276ddca9f21d32830f49bb902e"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (12 corresponding lines): agent/src/agent/instrument_identity.py:708-719 | agent/src/agent/instrument_identity.py:726-737 \u2014 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 \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/agent/instrument_identity.py"},"region":{"startLine":708}}}],"partialFingerprints":{"codehealthFindingId/v1":"e7a626e1e2491b96222e0ef7a003b59120377d18ebfa89b3d868cf9a917e7320"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (4 members, 13\u002B corresponding lines): agent/src/tools/trading_connector_tool.py:402-415 | agent/src/tools/trading_connector_tool.py:601-613 | agent/src/tools/trading_connector_tool.py:679-691 | agent/src/tools/trading_connector_tool.py:716-728 \u2014 These 4 members are one piece of code written 4 times and then edited apart: every two of them correspond over at least 13 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\u0027 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/trading_connector_tool.py"},"region":{"startLine":402}}}],"partialFingerprints":{"codehealthFindingId/v1":"689ae5e7af8012c1094c588e0795fb380d42653a5e759939e2fa5cb9f4b4813a"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (27 corresponding lines): agent/backtest/engines/china_futures.py:246-272 | agent/backtest/engines/global_futures.py:281-307 \u2014 These two members are one piece of code written twice and then edited apart: 27 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/engines/china_futures.py"},"region":{"startLine":246}}}],"partialFingerprints":{"codehealthFindingId/v1":"c0431cf1e0d538c43dd0d3ba6d8050b0e2f28a2e07e3388d868cc5312b9748bf"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (13 corresponding lines): agent/backtest/loaders/base.py:368-380 | agent/backtest/loaders/base.py:384-396 \u2014 These two members are one piece of code written twice and then edited apart: 13 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/base.py"},"region":{"startLine":368}}}],"partialFingerprints":{"codehealthFindingId/v1":"dc068f6607b7e300591c3a6d3ef69771f61052c377487bab0b2414268dcfea1e"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (21 corresponding lines): agent/backtest/loaders/futu.py:68-88 | agent/backtest/loaders/longbridge.py:113-133 \u2014 These two members are one piece of code written twice and then edited apart: 21 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/futu.py"},"region":{"startLine":68}}}],"partialFingerprints":{"codehealthFindingId/v1":"095b278d87cd60a0bab4cfccf57db45a34a02e2df4215aa0cb9910c812f583b3"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (9 corresponding lines): agent/cli/commands/slash_router.py:125-153 | agent/cli/main.py:90-98 \u2014 These two members are one piece of code written twice and then edited apart: 9 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/commands/slash_router.py"},"region":{"startLine":125}}}],"partialFingerprints":{"codehealthFindingId/v1":"681c2c5a9d76459ff98ca6c201e92520d481b3a25229722e72e09c6704ae4aff"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (8 corresponding lines): agent/src/channels/weixin.py:281-288 | agent/src/channels/weixin.py:299-307 \u2014 These two members are one piece of code written twice and then edited apart: 8 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/weixin.py"},"region":{"startLine":281}}}],"partialFingerprints":{"codehealthFindingId/v1":"a3d29642c6e99efd4d2d21d73a7173cebce0b45d7b558c556af854cfe49765b4"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 12\u002B corresponding lines): agent/src/factors/zoo/alpha101/alpha_069.py:86-98 | agent/src/factors/zoo/alpha101/alpha_070.py:86-98 | agent/src/factors/zoo/alpha101/alpha_090.py:86-97 \u2014 These 3 members are one piece of code written 3 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\u0027 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/alpha101/alpha_069.py"},"region":{"startLine":86}}}],"partialFingerprints":{"codehealthFindingId/v1":"17a4dfd4658154a4ea618d1444889f7a1f8de794896fa1eb07b3880536813d05"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 17\u002B corresponding lines): agent/src/factors/zoo/gtja191/alpha_109.py:54-71 | agent/src/factors/zoo/gtja191/alpha_111.py:54-71 | agent/src/factors/zoo/gtja191/alpha_158.py:54-70 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 17 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\u0027 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/gtja191/alpha_109.py"},"region":{"startLine":54}}}],"partialFingerprints":{"codehealthFindingId/v1":"9ee8eb7242109ced954d30697f3e617d03267965b657b71fc1079e5ad560b696"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (22 corresponding lines): agent/src/skills/candlestick/example_signal_engine.py:293-314 | agent/src/skills/candlestick/example_signal_engine.py:318-339 \u2014 These two members are one piece of code written twice and then edited apart: 22 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/skills/candlestick/example_signal_engine.py"},"region":{"startLine":293}}}],"partialFingerprints":{"codehealthFindingId/v1":"880635dbe677fc7b0cabe68af3b616cd588f05636b01d31d1565fb2ceb851138"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (20 corresponding lines): agent/backtest/metrics.py:449-471 | agent/backtest/metrics.py:475-494 \u2014 These two members are one piece of code written twice and then edited apart: 20 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/metrics.py"},"region":{"startLine":449}}}],"partialFingerprints":{"codehealthFindingId/v1":"516af28c5c51bb0a6681ccb496729eb2497e09f3fa327dc6cc6337c430364fa0"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (8 corresponding lines): agent/cli/commands/chat.py:31-38 | agent/cli/commands/session.py:71-78 \u2014 These two members are one piece of code written twice and then edited apart: 8 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/commands/chat.py"},"region":{"startLine":31}}}],"partialFingerprints":{"codehealthFindingId/v1":"ba280eb5ac36d937c965971d2779fdd118714fb24dd6e11851afb7228d8262c3"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 15\u002B corresponding lines): agent/src/factors/zoo/gtja191/alpha_122.py:54-68 | agent/src/factors/zoo/gtja191/alpha_152.py:54-70 | agent/src/factors/zoo/gtja191/alpha_169.py:54-68 \u2014 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\u0027 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/gtja191/alpha_122.py"},"region":{"startLine":54}}}],"partialFingerprints":{"codehealthFindingId/v1":"9a607df7022d997d65c63b6895c31273ab28d86ce86fb04de4e55a641c52b2fe"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (10 corresponding lines): agent/src/tools/sdm_status_tool.py:187-200 | agent/src/tools/sdm_status_tool.py:205-214 \u2014 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 \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/sdm_status_tool.py"},"region":{"startLine":187}}}],"partialFingerprints":{"codehealthFindingId/v1":"ff808822d7f0317835c304fb0b73a974a9c10f7a16db4cae1bf5eaf158460994"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (13 corresponding lines): agent/cli/commands/show.py:25-37 | agent/cli/commands/show.py:54-66 \u2014 These two members are one piece of code written twice and then edited apart: 13 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/commands/show.py"},"region":{"startLine":25}}}],"partialFingerprints":{"codehealthFindingId/v1":"e27c03b2b809612090cf1931a7b72f06cc194e4c72b91e24e98b9070cf292223"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (12 corresponding lines): agent/src/strategy_discovery/facade.py:85-96 | agent/src/tools/taiwan_stock_data_tool.py:102-114 \u2014 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 \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/strategy_discovery/facade.py"},"region":{"startLine":85}}}],"partialFingerprints":{"codehealthFindingId/v1":"cd4b4fde9040913ea7b07436df830776b19e04a94da2c27ff609b1b2d226dd18"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (21 corresponding lines): agent/src/tools/fred_macro_tool.py:210-233 | agent/src/tools/research_reports_tool.py:240-260 \u2014 These two members are one piece of code written twice and then edited apart: 21 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/fred_macro_tool.py"},"region":{"startLine":210}}}],"partialFingerprints":{"codehealthFindingId/v1":"b44285e98af949611535d219630ece83d1dd3c9ad92196a19175e8ae82fdbb51"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 13\u002B corresponding lines): agent/src/api/runs_routes.py:65-79 | agent/src/tools/backtest_summary.py:194-206 | agent/src/tools/trade_journal_tool.py:657-669 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 13 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\u0027 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/api/runs_routes.py"},"region":{"startLine":65}}}],"partialFingerprints":{"codehealthFindingId/v1":"3a47b7dda5e380404bcb0133a5257043a8bf7e518189f293beeffe4b0eb08c5c"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (12 corresponding lines): agent/src/factors/zoo/alpha101/alpha_061.py:56-67 | agent/src/factors/zoo/gtja191/alpha_154.py:56-72 \u2014 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 \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/alpha101/alpha_061.py"},"region":{"startLine":56}}}],"partialFingerprints":{"codehealthFindingId/v1":"b64bbed9451db7d028cf562159f7d1f0946b60696337203a42e8f3d715267a83"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (10 corresponding lines): agent/src/tools/options_payoff_tool.py:414-423 | agent/src/tools/options_payoff_tool.py:427-437 \u2014 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 \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/options_payoff_tool.py"},"region":{"startLine":414}}}],"partialFingerprints":{"codehealthFindingId/v1":"e2f0cf7e724944b68367d024979624c89f9947fbe4cea5e43751841f965ed3e0"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (22 corresponding lines): agent/src/quantlib/valuation/contracts.py:139-160 | agent/src/quantlib/valuation/dcf.py:227-251 \u2014 These two members are one piece of code written twice and then edited apart: 22 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/valuation/contracts.py"},"region":{"startLine":139}}}],"partialFingerprints":{"codehealthFindingId/v1":"6821ed92589b332816aed85d41ed717c2df441941d2149a03ef77f2497ac4575"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (19 corresponding lines): agent/src/skills/candlestick/example_signal_engine.py:107-125 | agent/src/skills/candlestick/example_signal_engine.py:150-168 \u2014 These two members are one piece of code written twice and then edited apart: 19 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/skills/candlestick/example_signal_engine.py"},"region":{"startLine":107}}}],"partialFingerprints":{"codehealthFindingId/v1":"b6530c403fdd49bb9102694c16d575250cd3f0198bdb551f0d1cdc19f1147eb5"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 21\u002B corresponding lines): agent/mcp_server.py:1035-1055 | agent/mcp_server.py:1252-1305 | agent/mcp_server.py:2543-2564 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 21 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\u0027 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/mcp_server.py"},"region":{"startLine":1035}}}],"partialFingerprints":{"codehealthFindingId/v1":"190b9837db55d25d0dfe5121768c5eced9dfa332294f5ebca60dbdcf1954a97c"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (4 corresponding lines): agent/src/factors/zoo/gtja191/alpha_053.py:49-52 | agent/src/factors/zoo/gtja191/alpha_058.py:49-52 \u2014 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 \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/gtja191/alpha_053.py"},"region":{"startLine":49}}}],"partialFingerprints":{"codehealthFindingId/v1":"ba2b7d5631c3dfeab1059563c9fbbd8f8b6d9494f41527596f08b3511a4e1125"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (8 corresponding lines): agent/src/agent/tool_progress.py:43-52 | agent/src/agent/tool_results.py:32-39 \u2014 These two members are one piece of code written twice and then edited apart: 8 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/agent/tool_progress.py"},"region":{"startLine":43}}}],"partialFingerprints":{"codehealthFindingId/v1":"babebc3bffe4e5d6f642e8fb4fc615e328c4e86bcc8a8bf41a371d9ecfbd7c13"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (17 corresponding lines): agent/backtest/runner.py:1056-1072 | agent/backtest/runner.py:1076-1092 \u2014 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 \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/runner.py"},"region":{"startLine":1056}}}],"partialFingerprints":{"codehealthFindingId/v1":"67a636b4930bb1aca7a29759ce2ebdff1c7e51f825640debeb66fc6a9c58addc"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (16 corresponding lines): agent/src/quantlib/fundmath.py:264-283 | agent/src/quantlib/fundmath.py:287-302 \u2014 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 \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/fundmath.py"},"region":{"startLine":264}}}],"partialFingerprints":{"codehealthFindingId/v1":"06ef2821b63410d6cc7698367bfcf978b51cc1fb972bf5c5fff9f26de1e09b51"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (25 corresponding lines): agent/src/tools/path_utils.py:323-348 | agent/src/tools/path_utils.py:384-408 \u2014 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 \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/path_utils.py"},"region":{"startLine":323}}}],"partialFingerprints":{"codehealthFindingId/v1":"785edbb23ed1a1c7417e45089df2f8d2ab2f3a76941d1d1350cafdd7ee5e4059"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (11 corresponding lines): agent/src/tools/stock_news_tool.py:389-399 | agent/src/tools/stock_news_tool.py:402-413 \u2014 These two members are one piece of code written twice and then edited apart: 11 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/stock_news_tool.py"},"region":{"startLine":389}}}],"partialFingerprints":{"codehealthFindingId/v1":"3df6e7419c85f9cebc0a47fa72b75b53d872fd187bcc8910fb6d36815a694114"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (3 corresponding lines): agent/src/br_data/cvm_funds.py:52-55 | agent/src/br_data/cvm_companies.py:47-49 \u2014 These two members are one piece of code written twice and then edited apart: 3 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/br_data/cvm_funds.py"},"region":{"startLine":52}}}],"partialFingerprints":{"codehealthFindingId/v1":"f3d3560465ae529fe2f66f42ab235afc6212c8663d07bf254c59fc14dac998fe"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (8 corresponding lines): agent/src/live/runtime/jobstore.py:234-252 | agent/src/scheduled_research/store.py:284-291 \u2014 These two members are one piece of code written twice and then edited apart: 8 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/live/runtime/jobstore.py"},"region":{"startLine":234}}}],"partialFingerprints":{"codehealthFindingId/v1":"b99cd7b5876631132978bdc4a6e917764f5a6ad573b18016429243c1873478fb"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (15 corresponding lines): agent/src/trading/connectors/longbridge/sdk.py:392-411 | agent/src/trading/connectors/okx/sdk.py:299-313 \u2014 These two members are one piece of code written twice and then edited apart: 15 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/longbridge/sdk.py"},"region":{"startLine":392}}}],"partialFingerprints":{"codehealthFindingId/v1":"d2feaf304d8652f00025ef4dd34e47b6ca3fceb1292f9488951b20422093a088"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (12 corresponding lines): agent/mcp_server.py:178-200 | agent/src/api/security.py:119-130 \u2014 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 \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/mcp_server.py"},"region":{"startLine":178}}}],"partialFingerprints":{"codehealthFindingId/v1":"019a19fa938f74250eb459fbd9d81b6fb81b90cc1896126fba1b92334befa349"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (4 members, 11\u002B corresponding lines): agent/src/channels/signal.py:92-102 | agent/src/channels/slack.py:757-767 | agent/src/channels/telegram.py:183-193 | agent/src/tools/report_audit_tool.py:134-144 \u2014 These 4 members are one piece of code written 4 times and then edited apart: every two of them correspond over at least 11 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\u0027 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/signal.py"},"region":{"startLine":92}}}],"partialFingerprints":{"codehealthFindingId/v1":"54389bff668467c6caf9d3f4b83599074774263db388cceb275f5bda2d445208"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (17 corresponding lines): agent/backtest/engines/china_a.py:163-180 | agent/backtest/engines/china_a.py:184-200 \u2014 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 \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/engines/china_a.py"},"region":{"startLine":163}}}],"partialFingerprints":{"codehealthFindingId/v1":"150953889e3d952ad07e0c3831ae321a85e501732f0eac68482730bf010006b4"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (6 corresponding lines): agent/src/tools/etf_holdings_tool.py:690-704 | agent/src/tools/tushare_fallbacks.py:55-60 \u2014 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 \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/etf_holdings_tool.py"},"region":{"startLine":690}}}],"partialFingerprints":{"codehealthFindingId/v1":"d35b20a82609ec524943bd6e47389db6c8413a009a4a3e6fc31144cc6e94b6c9"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (11 corresponding lines): agent/src/tools/trading_connector_tool.py:369-379 | agent/src/tools/trading_connector_tool.py:524-535 \u2014 These two members are one piece of code written twice and then edited apart: 11 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/trading_connector_tool.py"},"region":{"startLine":369}}}],"partialFingerprints":{"codehealthFindingId/v1":"bc8b3f3e751486a84e1ffdfd0158d8277acaac5e2901022c960079b5fafc6ae9"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (10 corresponding lines): agent/src/goal/store.py:965-976 | agent/src/goal/store.py:980-989 \u2014 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 \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/goal/store.py"},"region":{"startLine":965}}}],"partialFingerprints":{"codehealthFindingId/v1":"7e4e173f8f868898803e09171eca4330cf6813fab05ff2990cb87d3dcaab25c6"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (8 corresponding lines): agent/src/live/order_guard.py:798-810 | agent/src/live/sdk_order_gate.py:1087-1094 \u2014 These two members are one piece of code written twice and then edited apart: 8 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/live/order_guard.py"},"region":{"startLine":798}}}],"partialFingerprints":{"codehealthFindingId/v1":"7bc5bdd0b30dafe506a446e94eeff2712e447255b517fc3f804c3e16c086b509"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 8\u002B corresponding lines): agent/src/channels/websocket.py:1153-1160 | agent/src/channels/websocket.py:1169-1182 | agent/src/channels/websocket.py:1185-1194 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 8 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\u0027 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/websocket.py"},"region":{"startLine":1153}}}],"partialFingerprints":{"codehealthFindingId/v1":"afd3bd69671f4cc3c435321f75a2f8b2ab7e799fbfb9ac581d8d08c3d4de8f7b"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (11 corresponding lines): agent/src/skills/tushare/scripts/fund_data_example.py:36-46 | agent/src/skills/tushare/scripts/stock_data_example.py:36-46 \u2014 These two members are one piece of code written twice and then edited apart: 11 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/skills/tushare/scripts/fund_data_example.py"},"region":{"startLine":36}}}],"partialFingerprints":{"codehealthFindingId/v1":"e143a30b2f832ebbd3c5ad3cf80781006a14f9d6ad935e82ec0d9db63166f024"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (7 corresponding lines): agent/src/tools/financial_statements_tool.py:473-479 | agent/src/tools/sec_filings_tool.py:326-339 \u2014 These two members are one piece of code written twice and then edited apart: 7 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/financial_statements_tool.py"},"region":{"startLine":473}}}],"partialFingerprints":{"codehealthFindingId/v1":"827906b8832d5b05f4d7fc83d5ea96b786cf158696d8c638ba7202e5f4df0e10"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (13 corresponding lines): agent/backtest/optimizers/turnover_aware.py:146-158 | agent/backtest/optimizers/mean_variance.py:21-34 \u2014 These two members are one piece of code written twice and then edited apart: 13 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/optimizers/turnover_aware.py"},"region":{"startLine":146}}}],"partialFingerprints":{"codehealthFindingId/v1":"cd4471c397c7039cb2ce55058066c3d4770f1fb474e691cbebb9f587f321620a"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (8 corresponding lines): agent/evals/grounding/evidence.py:358-375 | agent/src/trading/connectors/binance/shaping.py:12-19 \u2014 These two members are one piece of code written twice and then edited apart: 8 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/grounding/evidence.py"},"region":{"startLine":358}}}],"partialFingerprints":{"codehealthFindingId/v1":"fb64ae17306ecfae4d1ed6da1b62437fc9b155f9e256cef50a3b1a950757c666"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (9 corresponding lines): agent/src/trading/connectors/kis/sdk.py:885-894 | agent/src/trading/connectors/upbit/sdk.py:617-625 \u2014 These two members are one piece of code written twice and then edited apart: 9 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/kis/sdk.py"},"region":{"startLine":885}}}],"partialFingerprints":{"codehealthFindingId/v1":"9509b84e1f8f7688e5809fd9524d1879bdf7d34a65c3e6b86c44c5fe3a21e458"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (9 corresponding lines): agent/src/factors/zoo/gtja191/alpha_136.py:54-67 | agent/src/factors/zoo/alpha101/alpha_014.py:55-63 \u2014 These two members are one piece of code written twice and then edited apart: 9 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/gtja191/alpha_136.py"},"region":{"startLine":54}}}],"partialFingerprints":{"codehealthFindingId/v1":"99f3071581f2c3054f08ce0028b158321cee177135fcedd64b59fcf4c2713ff8"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (14 corresponding lines): agent/src/factors/zoo/gtja191/alpha_155.py:54-68 | agent/src/factors/zoo/gtja191/alpha_151.py:54-67 \u2014 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 \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/gtja191/alpha_155.py"},"region":{"startLine":54}}}],"partialFingerprints":{"codehealthFindingId/v1":"b3a98c69e24706f63372c436f50279d9ce1016ec4abc3e7ef8354e50db5c4d83"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (7 corresponding lines): agent/src/tools/goal_tool.py:25-32 | agent/src/hypotheses/registry.py:50-56 \u2014 These two members are one piece of code written twice and then edited apart: 7 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/goal_tool.py"},"region":{"startLine":25}}}],"partialFingerprints":{"codehealthFindingId/v1":"1db2ef82abbb0b4cae4c9088d264a80f1f2df2b731708d407c53a67daae0b926"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (6 corresponding lines): agent/src/trading/connectors/etoro/sdk.py:153-161 | agent/src/trading/connectors/longbridge/sdk.py:307-312 \u2014 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 \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/etoro/sdk.py"},"region":{"startLine":153}}}],"partialFingerprints":{"codehealthFindingId/v1":"da575250a058bc838917837dcd1b4e2663dc9792df88fa737df4a095c513f9dd"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 10\u002B corresponding lines): agent/src/governance/ledger.py:329-340 | agent/src/live/daily_count.py:53-62 | agent/src/providers/openai_codex.py:131-140 \u2014 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\u0027 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/governance/ledger.py"},"region":{"startLine":329}}}],"partialFingerprints":{"codehealthFindingId/v1":"ecf76dfa9736d60fc2b880d5bf766e93ac7f72e8822cb67c5c7c1cfd627cfc85"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (4 corresponding lines): agent/src/quantlib/combination.py:76-79 | agent/src/quantlib/neutralization.py:42-45 \u2014 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 \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/combination.py"},"region":{"startLine":76}}}],"partialFingerprints":{"codehealthFindingId/v1":"a38cfbda36703e18c1df0bda3bc749390596ccbdd9c38c698eb7ca76cc616d59"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (10 corresponding lines): agent/src/live/runtime/jobstore.py:197-215 | agent/src/scheduled_research/store.py:264-273 \u2014 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 \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/live/runtime/jobstore.py"},"region":{"startLine":197}}}],"partialFingerprints":{"codehealthFindingId/v1":"556b3f4953336d5ebf22bb1251663ceba4a1c777caa12576905bd73e6fe66af8"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (7 corresponding lines): agent/src/market_data.py:211-217 | agent/src/tools/get_fundamentals_tool.py:37-44 \u2014 These two members are one piece of code written twice and then edited apart: 7 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/market_data.py"},"region":{"startLine":211}}}],"partialFingerprints":{"codehealthFindingId/v1":"21ebc50bc96708e144bb4f93e8723f3ee6583b7487635753f191d196423fd757"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 8\u002B corresponding lines): agent/src/trading/connectors/etoro/instruments.py:147-154 | agent/src/trading/connectors/toss/sdk.py:604-612 | agent/src/trading/connectors/trading212/sdk.py:501-508 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 8 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\u0027 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/etoro/instruments.py"},"region":{"startLine":147}}}],"partialFingerprints":{"codehealthFindingId/v1":"e91d1e0f3902fea2841ecf09c4a3f6420b2d850b1b1687d4148d43484b56cc19"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (5 corresponding lines): agent/src/factors/zoo/alpha101/alpha_053.py:55-64 | agent/src/factors/zoo/gtja191/alpha_002.py:49-53 \u2014 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 \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/alpha101/alpha_053.py"},"region":{"startLine":55}}}],"partialFingerprints":{"codehealthFindingId/v1":"768bed79aec2d6c3178218aa1486a99ad85df7f64e8e474c99790c69e8a37054"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (11 corresponding lines): agent/src/agent/trace.py:270-284 | agent/src/governance/ledger.py:356-366 \u2014 These two members are one piece of code written twice and then edited apart: 11 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/agent/trace.py"},"region":{"startLine":270}}}],"partialFingerprints":{"codehealthFindingId/v1":"a7d9556b6fe4af249ed2ddf55a47fef04b2267bd74798e2ac40d53a5f83aaa55"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (9 corresponding lines): agent/src/factors/zoo/alpha101/alpha_058.py:86-94 | agent/src/factors/zoo/alpha101/alpha_059.py:86-95 \u2014 These two members are one piece of code written twice and then edited apart: 9 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/alpha101/alpha_058.py"},"region":{"startLine":86}}}],"partialFingerprints":{"codehealthFindingId/v1":"0a43b47b62eafc67e11bd51ce5f210991618a3382921ca7743e2926f5b5399ff"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (5 corresponding lines): agent/backtest/run_card.py:285-289 | agent/src/shadow_account/storage.py:53-59 \u2014 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 \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/run_card.py"},"region":{"startLine":285}}}],"partialFingerprints":{"codehealthFindingId/v1":"396eaf194b241eaaa450a8739e7d0a8d31a55f19d97f8971a74118c6d39f4a76"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (7 corresponding lines): agent/mcp_server.py:2491-2514 | agent/src/channels/mochat.py:931-937 \u2014 These two members are one piece of code written twice and then edited apart: 7 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/mcp_server.py"},"region":{"startLine":2491}}}],"partialFingerprints":{"codehealthFindingId/v1":"947da701154a1845eb4f8c959f4e6e441a8faf38a10c833a6bedf9fa418f85ac"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (17 corresponding lines): agent/src/live/runtime/flatten.py:427-448 | agent/src/tools/prediction_market_tool.py:286-302 \u2014 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 \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/live/runtime/flatten.py"},"region":{"startLine":427}}}],"partialFingerprints":{"codehealthFindingId/v1":"3cb84ef086c083c3d9295331fa9a0d53c1e5c371878248f55981dd85ec2b4168"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (3 corresponding lines): agent/backtest/binance_account_reconciliation.py:34-36 | agent/backtest/binance_shadow_evidence.py:244-246 \u2014 These two members are one piece of code written twice and then edited apart: 3 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/binance_account_reconciliation.py"},"region":{"startLine":34}}}],"partialFingerprints":{"codehealthFindingId/v1":"0dd1faf124125cd72e3c224b0fe6f626a65a297298ca720dbc5ef0ad41cf800f"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (8 corresponding lines): agent/src/factors/zoo/alpha101/alpha_015.py:60-68 | agent/src/factors/zoo/alpha101/alpha_050.py:55-62 \u2014 These two members are one piece of code written twice and then edited apart: 8 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/alpha101/alpha_015.py"},"region":{"startLine":60}}}],"partialFingerprints":{"codehealthFindingId/v1":"33c9e8c97dc9195d8cc4d7c9a57632f0a89149283744756ecb9ad0ea4fec846f"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (25 corresponding lines): agent/src/trading/connectors/dhan/sdk.py:254-279 | agent/src/trading/connectors/shoonya/sdk.py:252-276 \u2014 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 \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/dhan/sdk.py"},"region":{"startLine":254}}}],"partialFingerprints":{"codehealthFindingId/v1":"e740e499b016c0924e53ac3e82c73beae41497419eb0e2ae1d235f6a87715270"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (4 members, 6\u002B corresponding lines): agent/src/channels/signal.py:1148-1156 | agent/src/live/order_guard.py:835-841 | agent/src/live/sdk_order_gate.py:1098-1103 | agent/src/trading/tap_forward.py:228-233 \u2014 These 4 members are one piece of code written 4 times and then edited apart: every two of them correspond over at least 6 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/signal.py"},"region":{"startLine":1148}}}],"partialFingerprints":{"codehealthFindingId/v1":"7e333e74f88bad692c885991087402a90dbe9bed189ecc4ee310aa45d682a553"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (4 members, 6\u002B corresponding lines): agent/src/factors/zoo/qlib158/klow.py:27-32 | agent/src/factors/zoo/qlib158/klow2.py:27-33 | agent/src/factors/zoo/qlib158/kup.py:27-32 | agent/src/factors/zoo/qlib158/kup2.py:27-33 \u2014 These 4 members are one piece of code written 4 times and then edited apart: every two of them correspond over at least 6 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/qlib158/klow.py"},"region":{"startLine":27}}}],"partialFingerprints":{"codehealthFindingId/v1":"b6b49c1f17b3b92d9d0514b154823b139d2119393aef581586b693cddd1e7b92"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (3 corresponding lines): agent/src/factors/zoo/alpha101/alpha_026.py:55-62 | agent/src/factors/zoo/gtja191/alpha_005.py:49-51 \u2014 These two members are one piece of code written twice and then edited apart: 3 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/alpha101/alpha_026.py"},"region":{"startLine":55}}}],"partialFingerprints":{"codehealthFindingId/v1":"ac15507a11ab71296fcdd42c895c71e2ca7408bfc5c5c0c2764f000294ebee45"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (27 corresponding lines): agent/src/live/order_guard.py:586-616 | agent/src/live/sdk_order_gate.py:864-890 \u2014 These two members are one piece of code written twice and then edited apart: 27 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/live/order_guard.py"},"region":{"startLine":586}}}],"partialFingerprints":{"codehealthFindingId/v1":"a9ced3ef27dc935dd5317cf9fcf8be4d75cda58853378d1e0973a08cd53493db"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 2\u002B corresponding lines): agent/src/tools/paper_trade/data.py:143-144 | agent/src/tools/paper_trade/data_5m.py:234-235 | agent/src/tools/paper_trade/strategy_exec.py:175-176 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 2 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\u0027 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/paper_trade/data.py"},"region":{"startLine":143}}}],"partialFingerprints":{"codehealthFindingId/v1":"57a1fee9e5ae517f0511d2df0ec8f27889fa357e9be77bad25752593af10f631"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (4 corresponding lines): agent/backtest/binance_account_reconciliation.py:27-30 | agent/backtest/binance_tolerance_calibration.py:24-27 \u2014 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 \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/binance_account_reconciliation.py"},"region":{"startLine":27}}}],"partialFingerprints":{"codehealthFindingId/v1":"480bb37605c79fc34fac861253a8cdd30d9235fca194125f6d59eb064235d02d"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (8 corresponding lines): agent/src/factors/zoo/alpha101/alpha_038.py:55-62 | agent/src/factors/zoo/alpha101/alpha_040.py:55-62 \u2014 These two members are one piece of code written twice and then edited apart: 8 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/alpha101/alpha_038.py"},"region":{"startLine":55}}}],"partialFingerprints":{"codehealthFindingId/v1":"12f89b7abffa9d666695f14b548e58584221336173ba4147ae496e5d0d31231b"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 4\u002B corresponding lines): agent/src/tools/fred_macro_tool.py:266-269 | agent/src/tools/research_reports_tool.py:384-387 | agent/src/tools/shareholder_count_tool.py:285-288 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 4 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\u0027 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/fred_macro_tool.py"},"region":{"startLine":266}}}],"partialFingerprints":{"codehealthFindingId/v1":"ac1e332fd8effb4ab59ea8b746bd4e688f467a709b565b85d35c559b1d74f58a"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (4 corresponding lines): agent/cli/ui/rail.py:216-219 | agent/cli/ui/transcript.py:167-170 \u2014 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 \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/ui/rail.py"},"region":{"startLine":216}}}],"partialFingerprints":{"codehealthFindingId/v1":"acd417d8bd18187fbe907e0d2c067fc8fde61e3ff58a7078a6b0f8e3d821f8c1"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 6\u002B corresponding lines): agent/src/channels/mochat.py:80-85 | agent/src/live/enforcement.py:412-417 | agent/src/trading/connectors/robinhood/extractor.py:127-132 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 6 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/mochat.py"},"region":{"startLine":80}}}],"partialFingerprints":{"codehealthFindingId/v1":"c9e727c62ae8a32cc8736bd0dca00d710ccb5f82ed47df051d04d9d21da87a8c"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (5 members, 4\u002B corresponding lines): agent/src/factors/zoo/qlib158/imxd10.py:27-30 | agent/src/factors/zoo/qlib158/imxd20.py:27-30 | agent/src/factors/zoo/qlib158/imxd30.py:27-30 | agent/src/factors/zoo/qlib158/imxd5.py:27-30 | agent/src/factors/zoo/qlib158/imxd60.py:27-30 \u2014 These 5 members are one piece of code written 5 times and then edited apart: every two of them correspond over at least 4 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\u0027 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/qlib158/imxd10.py"},"region":{"startLine":27}}}],"partialFingerprints":{"codehealthFindingId/v1":"d2b8b7c9d502c1269c8c7c886919302b7455944c87498d2dffa8bba3ff43f93e"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 6\u002B corresponding lines): agent/src/factors/zoo/qlib158/kmid2.py:27-32 | agent/src/factors/zoo/qlib158/ksft.py:27-32 | agent/src/factors/zoo/qlib158/ksft2.py:27-32 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 6 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/qlib158/kmid2.py"},"region":{"startLine":27}}}],"partialFingerprints":{"codehealthFindingId/v1":"aa5cb3d598f3fe898962e0cd1cedc7d604edf7d0b8427c020c1654c4afe4ceb7"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (6 corresponding lines): agent/src/shadow_account/codegen.py:66-74 | agent/src/shadow_account/reporter.py:289-294 \u2014 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 \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/shadow_account/codegen.py"},"region":{"startLine":66}}}],"partialFingerprints":{"codehealthFindingId/v1":"8ad7d7cd42c85e07947dba659b584d489a028022fa3c0413b4d4006b7b8c1695"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (5 corresponding lines): agent/backtest/loaders/fmp_loader.py:60-75 | agent/backtest/loaders/gildata_codes.py:52-56 \u2014 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 \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/fmp_loader.py"},"region":{"startLine":60}}}],"partialFingerprints":{"codehealthFindingId/v1":"ae51727f5862f5728d77b128935dc9bc6161a72f508b3837e6bc571133212f8f"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (8 corresponding lines): agent/src/factors/zoo/alpha101/alpha_033.py:55-62 | agent/src/factors/zoo/gtja191/alpha_185.py:54-65 \u2014 These two members are one piece of code written twice and then edited apart: 8 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/alpha101/alpha_033.py"},"region":{"startLine":55}}}],"partialFingerprints":{"codehealthFindingId/v1":"be232ac146f68f10e4d6213a5f479cc7e2492b88fb4b51df295f9cdf40e56abb"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (2 corresponding lines): agent/src/quantlib/combination.py:93-94 | agent/src/quantlib/neutralization.py:73-74 \u2014 These two members are one piece of code written twice and then edited apart: 2 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/combination.py"},"region":{"startLine":93}}}],"partialFingerprints":{"codehealthFindingId/v1":"131616706b6080999ceaba80ab26ba5538393ebc7d3a64facaa6a77c0acbf90a"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (13 corresponding lines): agent/src/factors/zoo/gtja191/alpha_126.py:54-66 | agent/src/factors/zoo/gtja191/alpha_150.py:54-67 \u2014 These two members are one piece of code written twice and then edited apart: 13 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/gtja191/alpha_126.py"},"region":{"startLine":54}}}],"partialFingerprints":{"codehealthFindingId/v1":"6eb13d842ff9ef768881aeff03b447d4a5064742879fd00bce07b99bb5c97390"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (4 corresponding lines): agent/src/channels/manager.py:410-413 | agent/src/channels/registry.py:233-237 \u2014 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 \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/manager.py"},"region":{"startLine":410}}}],"partialFingerprints":{"codehealthFindingId/v1":"90daf8e28189a95952801f496c5f796fe9477a18c6669b74f76849054fdfde5a"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (8 corresponding lines): agent/src/factors/zoo/alpha101/alpha_042.py:55-62 | agent/src/factors/zoo/gtja191/alpha_120.py:55-67 \u2014 These two members are one piece of code written twice and then edited apart: 8 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/alpha101/alpha_042.py"},"region":{"startLine":55}}}],"partialFingerprints":{"codehealthFindingId/v1":"ca4384700d962453c43d0c00180ab93dda7d5dfc0fe50046ff3c85dead94e72f"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (20 corresponding lines): agent/src/quantlib/fundmath.py:174-193 | agent/src/quantlib/impact.py:75-100 \u2014 These two members are one piece of code written twice and then edited apart: 20 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/fundmath.py"},"region":{"startLine":174}}}],"partialFingerprints":{"codehealthFindingId/v1":"fd241edf5805f2f59268256a2a795574881caa6a367ad4a80bc571be7409371c"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (4 corresponding lines): agent/src/factors/zoo/academic/mkt_rf.py:56-59 | agent/src/factors/zoo/academic/rmw.py:56-60 \u2014 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 \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/academic/mkt_rf.py"},"region":{"startLine":56}}}],"partialFingerprints":{"codehealthFindingId/v1":"fbbd56dc0fd6e5761335a2cd80ab604045ef76dbba56b5ff62f3b41b7cb5a7c3"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (6 corresponding lines): agent/src/trading/connectors/binance/sdk.py:868-873 | agent/src/trading/connectors/okx/sdk.py:621-628 \u2014 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 \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/binance/sdk.py"},"region":{"startLine":868}}}],"partialFingerprints":{"codehealthFindingId/v1":"aa9e47a36ed089bd1c0b87ee4e503f8df02ad5904ee445fc5667534f5eef1a82"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (3 corresponding lines): agent/src/factors/zoo/gtja191/alpha_041.py:50-52 | agent/src/factors/zoo/gtja191/alpha_090.py:50-52 \u2014 These two members are one piece of code written twice and then edited apart: 3 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/gtja191/alpha_041.py"},"region":{"startLine":50}}}],"partialFingerprints":{"codehealthFindingId/v1":"f1269f84199f23e1333c40e145a32550a48026b6ac4324159ff5a75f694fcba7"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (6 corresponding lines): agent/src/trading/connectors/alpaca/sdk.py:853-860 | agent/src/trading/connectors/upbit/sdk.py:629-634 \u2014 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 \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/alpaca/sdk.py"},"region":{"startLine":853}}}],"partialFingerprints":{"codehealthFindingId/v1":"440ff20186364127548d42f8cdd47c57f6eb29ad5e1d8056bfd3483ae1bc856c"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (3 corresponding lines): agent/src/agent/loop.py:1659-1661 | agent/src/api/security.py:670-672 \u2014 These two members are one piece of code written twice and then edited apart: 3 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/agent/loop.py"},"region":{"startLine":1659}}}],"partialFingerprints":{"codehealthFindingId/v1":"b6d159bed2f58f2e6a97438e3350f8185a1c2e05edcaa76fdf6edc93f997e182"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (51\u201354 lines \u00D7 2): agent/src/factors/bench_runner.py:383-433 | agent/src/factors/bench_runner_strict.py:641-694 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060agent/src/factors/bench_runner.py:383\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, \u0060agent/src/factors/bench_runner_strict.py:640\u0060 calls \u0060sorted\u0060 and \u0060agent/src/factors/bench_runner.py:381\u0060 does not \u2014 after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/bench_runner.py"},"region":{"startLine":383}}}],"partialFingerprints":{"codehealthFindingId/v1":"9161472b2d07010d28407c2cf20862228aa600e871d34af0b14da47bde2af3b0"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (45\u201353 lines \u00D7 2): agent/backtest/loaders/akshare_loader.py:135-179 | agent/backtest/loaders/eastmoney_loader.py:80-132 \u2014 before extracting anything, compare \u0060agent/backtest/loaders/akshare_loader.py\u0060 and \u0060agent/backtest/loaders/eastmoney_loader.py\u0060 as WHOLE FILES: this scan already matched 6 separate duplicated blocks between them, totalling at least 130 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together \u2014 extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at \u0060agent/backtest/loaders/akshare_loader.py:135\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/akshare_loader.py"},"region":{"startLine":135}}}],"partialFingerprints":{"codehealthFindingId/v1":"b281e1e50792ac7e0dded8bd0ab094934f8e920a636c0814f1ad719c3e7e4e9c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (43\u201345 lines \u00D7 2): agent/backtest/loaders/fmp_loader.py:265-309 | agent/backtest/loaders/tiingo_loader.py:197-239 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/fmp_loader.py"},"region":{"startLine":265}}}],"partialFingerprints":{"codehealthFindingId/v1":"4652a0c9d37096cd01d87e819095508e2d605e3a0e0b04c506ddd1008378d916"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (34\u201338 lines \u00D7 2): agent/src/quantlib/crossvalidation.py:233-266 | agent/src/quantlib/crossvalidation.py:424-461 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/crossvalidation.py"},"region":{"startLine":233}}}],"partialFingerprints":{"codehealthFindingId/v1":"02ea96731ca0a022ef3733a182c6b6fc9cbf8c33010285794d27a169dd4bd750"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (4\u201335 lines \u00D7 3): agent/backtest/engines/base.py:755-758 | agent/backtest/engines/korea_equity.py:231-265 | agent/backtest/engines/vietnam_equity.py:224-257 \u2014 before extracting anything, compare \u0060agent/backtest/engines/korea_equity.py\u0060 and \u0060agent/backtest/engines/vietnam_equity.py\u0060 as WHOLE FILES: this scan already matched 6 separate duplicated blocks between them, totalling at least 118 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together \u2014 extracting one helper per block leaves the fork in place. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/engines/base.py"},"region":{"startLine":755}}}],"partialFingerprints":{"codehealthFindingId/v1":"2ae7215bd99a8fa5a3cb1b711dba8ac38e99742dc87b31dd9c08f197571a3132"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (27\u201334 lines \u00D7 2): agent/src/quantlib/risk.py:256-282 | agent/src/quantlib/risk.py:330-363 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/risk.py"},"region":{"startLine":256}}}],"partialFingerprints":{"codehealthFindingId/v1":"ee46f66259380caf4b2049e5cefb314b90822260d90806bb6dd085740385450e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (25\u201333 lines \u00D7 2): agent/src/api/attribution_routes.py:40-72 | agent/src/api/runs_routes.py:846-870 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/api/attribution_routes.py"},"region":{"startLine":40}}}],"partialFingerprints":{"codehealthFindingId/v1":"f7c4c3edc3b84a4d746143de3a9093b29f0c0db812a91ec8c997c90362b11ac8"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (31 lines \u00D7 2): agent/src/tools/trade_journal_tool.py:147-177 | agent/src/tools/trade_journal_tool.py:199-229 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/trade_journal_tool.py"},"region":{"startLine":147}}}],"partialFingerprints":{"codehealthFindingId/v1":"6ca9cbbd3bbf6a0e58a4ff5f5599fa8df760fa28f36b85f5025d8912d5a24914"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (27\u201329 lines \u00D7 4): agent/src/trading/connectors/dhan/sdk.py:537-565 | agent/src/trading/connectors/shoonya/sdk.py:510-538 | agent/src/trading/connectors/upbit/sdk.py:508-536 | agent/src/trading/connectors/zerodha/sdk.py:633-659 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 4 call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made 4 times. 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/dhan/sdk.py"},"region":{"startLine":537}}}],"partialFingerprints":{"codehealthFindingId/v1":"68ca0b242d83ab7288ffcb8397da6635a1400804fc2d5d21e27ee18d751c0f88"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (28 lines \u00D7 18): agent/src/factors/zoo/alpha101/alpha_048.py:67-94 | agent/src/factors/zoo/alpha101/alpha_058.py:55-82 | agent/src/factors/zoo/alpha101/alpha_059.py:55-82 | agent/src/factors/zoo/alpha101/alpha_063.py:60-87 | agent/src/factors/zoo/alpha101/alpha_067.py:55-82 | agent/src/factors/zoo/alpha101/alpha_069.py:55-82 | agent/src/factors/zoo/alpha101/alpha_070.py:55-82 | agent/src/factors/zoo/alpha101/alpha_076.py:56-83 | agent/src/factors/zoo/alpha101/alpha_079.py:56-83 | agent/src/factors/zoo/alpha101/alpha_080.py:55-82 | agent/src/factors/zoo/alpha101/alpha_082.py:56-83 | agent/src/factors/zoo/alpha101/alpha_087.py:56-83 | agent/src/factors/zoo/alpha101/alpha_089.py:55-82 | agent/src/factors/zoo/alpha101/alpha_090.py:55-82 | agent/src/factors/zoo/alpha101/alpha_091.py:55-82 | agent/src/factors/zoo/alpha101/alpha_093.py:55-82 | agent/src/factors/zoo/alpha101/alpha_097.py:55-82 | agent/src/factors/zoo/alpha101/alpha_100.py:55-82 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from all 18 call sites, so a change lands once. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, \u0060agent/src/factors/zoo/alpha101/alpha_063.py:54\u0060 calls \u0060_rolling_sum\u0060, \u0060rolling\u0060, \u0060sum\u0060 and \u0060agent/src/factors/zoo/alpha101/alpha_058.py:51\u0060 does not \u2014 after which the two agree again for 3 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/alpha101/alpha_048.py"},"region":{"startLine":67}}}],"partialFingerprints":{"codehealthFindingId/v1":"80c8e240e5faadd663fab86963e65eb014281562a73ca87345f7d13164eb4d53"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (23\u201328 lines \u00D7 2): agent/src/agent/instrument_identity.py:268-295 | agent/src/agent/instrument_identity.py:370-392 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/agent/instrument_identity.py"},"region":{"startLine":268}}}],"partialFingerprints":{"codehealthFindingId/v1":"1276d386af62e6848e02dc34488e1e2c9e82dcd1ed2defea9aa3d4760803fae9"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (28 lines \u00D7 2): agent/src/quantlib/credit.py:296-327 | agent/src/quantlib/credit.py:419-446 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/credit.py"},"region":{"startLine":296}}}],"partialFingerprints":{"codehealthFindingId/v1":"ff8d64564b8ae6f50990074c67ad84bd9ea2d7f67088c200394c2ebf26cc7b7e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (26\u201328 lines \u00D7 2): agent/src/trading/connectors/dhan/sdk.py:453-480 | agent/src/trading/connectors/shoonya/sdk.py:434-459 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/dhan/sdk.py"},"region":{"startLine":453}}}],"partialFingerprints":{"codehealthFindingId/v1":"8d243b00ec2641cb3c68892dc9ec0c5ecf24d0f92e318a92e7cca075b33e8cd2"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (24\u201327 lines \u00D7 5): agent/src/skills/elliott-wave/example_signal_engine.py:414-440 | agent/src/skills/harmonic/example_signal_engine.py:431-457 | agent/src/skills/ichimoku/example_signal_engine.py:135-161 | agent/src/skills/smc/example_signal_engine.py:26-49 | agent/src/skills/technical-basic/example_signal_engine.py:250-273 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 5 call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made 5 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/skills/elliott-wave/example_signal_engine.py"},"region":{"startLine":414}}}],"partialFingerprints":{"codehealthFindingId/v1":"e0e7efee52fd2178f59e25ffd8c5982b3e37694d1a54b500fe9a5df4e00bc4a7"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (27 lines \u00D7 2): agent/backtest/loaders/nobitex.py:162-188 | agent/backtest/loaders/wallex.py:160-186 \u2014 before extracting anything, compare \u0060agent/backtest/loaders/nobitex.py\u0060 and \u0060agent/backtest/loaders/wallex.py\u0060 as WHOLE FILES: this scan already matched 3 separate duplicated blocks between them, totalling at least 49 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together \u2014 extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at \u0060agent/backtest/loaders/nobitex.py:162\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, \u0060agent/backtest/loaders/nobitex.py:161\u0060 calls \u0060sorted\u0060 and \u0060agent/backtest/loaders/wallex.py:159\u0060 does not \u2014 after which the two agree again for 4 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/nobitex.py"},"region":{"startLine":162}}}],"partialFingerprints":{"codehealthFindingId/v1":"1458465a00136164694b8218208e1d786151b39c8d66c918df37068937c50402"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14\u201327 lines \u00D7 2): agent/src/tools/orderbook_depth_tool.py:178-191 | agent/src/tools/prediction_market_tool.py:949-975 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/orderbook_depth_tool.py"},"region":{"startLine":178}}}],"partialFingerprints":{"codehealthFindingId/v1":"f6d23cf0a6e4cefb776ded0a6be36f1e56858db5f8abe575405895301475661b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (22\u201327 lines \u00D7 2): agent/src/trading/connectors/robinhood/mcp.py:484-510 | agent/src/trading/connectors/robinhood/mcp.py:531-552 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/robinhood/mcp.py"},"region":{"startLine":484}}}],"partialFingerprints":{"codehealthFindingId/v1":"3d4717aeb2a81383a53bc64b89e4c907a0363854d1e43a895a3691b3d9b9a94e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (20\u201326 lines \u00D7 4): agent/src/trading/connectors/binance/sdk.py:219-244 | agent/src/trading/connectors/dhan/sdk.py:198-217 | agent/src/trading/connectors/tiger/sdk.py:189-210 | agent/src/trading/connectors/upbit/sdk.py:192-211 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 4 call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made 4 times. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. Note first that the copies are not typed on the same thing: the declarations holding them bind \u0060config\u0060 to \u0060BinanceConfig | None = None\u0060 in one and \u0060DhanConfig | None = None\u0060 in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH \u2014 their common supertype where they have one, or a new abstraction over them where they do not \u2014 and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/binance/sdk.py"},"region":{"startLine":219}}}],"partialFingerprints":{"codehealthFindingId/v1":"dcab45e6268b82b2c7e8abc5102ef278ffd072fce3aac239a2d6f78fe370fe2f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12\u201326 lines \u00D7 2): agent/cli/_legacy.py:968-993 | agent/src/api/sessions_routes.py:263-274 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":968}}}],"partialFingerprints":{"codehealthFindingId/v1":"696961c15464179bd6bd817f7e49676fa90883f16bc64e836d634264b966df1c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14\u201326 lines \u00D7 2): agent/cli/_legacy.py:3162-3187 | agent/cli/_legacy.py:3191-3204 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":3162}}}],"partialFingerprints":{"codehealthFindingId/v1":"392eae621c6092950b480e8435d1e57b763dec962ae0fd561bce74f3202cb234"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (24\u201326 lines \u00D7 2): agent/src/tools/research_reports_tool.py:114-139 | agent/src/tools/shareholder_count_tool.py:86-109 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/research_reports_tool.py"},"region":{"startLine":114}}}],"partialFingerprints":{"codehealthFindingId/v1":"bfa763b2c05ac0f029a9f90bd0710e5c893836e45d772388d2ca10cf1685ed5a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (24\u201325 lines \u00D7 2): agent/src/quantlib/valuation/dcf.py:255-279 | agent/src/quantlib/valuation/threestatement.py:451-474 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/valuation/dcf.py"},"region":{"startLine":255}}}],"partialFingerprints":{"codehealthFindingId/v1":"429d20c6aee20f425cfb150656011ce0ffb5f6a389a02272018ad74d51e71f63"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (25 lines \u00D7 2): agent/src/strategy_discovery/evidence_store.py:244-268 | agent/src/strategy_discovery/evidence_store.py:298-322 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/strategy_discovery/evidence_store.py"},"region":{"startLine":244}}}],"partialFingerprints":{"codehealthFindingId/v1":"855dcd9ef0d3a338b2cd93c9303c51bf6440ece5d481dd776d6621f07d016806"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (23\u201324 lines \u00D7 3): agent/backtest/loaders/akshare_loader.py:183-205 | agent/backtest/loaders/eastmoney_loader.py:137-160 | agent/backtest/loaders/tencent_loader.py:133-156 \u2014 before extracting anything, compare \u0060agent/backtest/loaders/akshare_loader.py\u0060 and \u0060agent/backtest/loaders/eastmoney_loader.py\u0060 as WHOLE FILES: this scan already matched 6 separate duplicated blocks between them, totalling at least 130 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together \u2014 extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at \u0060agent/backtest/loaders/akshare_loader.py:183\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/akshare_loader.py"},"region":{"startLine":183}}}],"partialFingerprints":{"codehealthFindingId/v1":"044ac9ef3433ad779f5792e42506324155c0975404e4734ae281fce28913dbf5"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (23 lines \u00D7 2): agent/src/api/alpha_routes.py:623-645 | agent/src/api/alpha_routes.py:719-741 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/api/alpha_routes.py"},"region":{"startLine":623}}}],"partialFingerprints":{"codehealthFindingId/v1":"6d80f3d5592d615d243b0a6ea7ba7041e36b71bb46bd52ff2950b94c2902e79e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (23 lines \u00D7 2): agent/src/tools/autopilot_tool.py:461-483 | agent/src/tools/autopilot_tool.py:580-602 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/autopilot_tool.py"},"region":{"startLine":461}}}],"partialFingerprints":{"codehealthFindingId/v1":"879031d4196c836966b64539c6c14b668e65ec30644bf3c76ed23c2de6b57903"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (22 lines \u00D7 2): agent/backtest/runner.py:1170-1191 | agent/backtest/runner.py:1249-1270 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 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 \u0060agent/backtest/runner.py:1170\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/runner.py"},"region":{"startLine":1170}}}],"partialFingerprints":{"codehealthFindingId/v1":"08fd1cfc7f9014912522d2b2e8b8935eb416502bd47e23a39a30bfd667dc733c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (22 lines \u00D7 2): agent/src/quantlib/impact.py:184-205 | agent/src/quantlib/impact.py:217-243 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/impact.py"},"region":{"startLine":184}}}],"partialFingerprints":{"codehealthFindingId/v1":"7de12511ba01028634ebb25218b7f929623eaabd73a1e15df69666d9ee679ba9"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (16\u201321 lines \u00D7 6): agent/src/channels/config_meta.py:78-93 | agent/src/channels/config_meta.py:113-128 | agent/src/channels/config_meta.py:137-152 | agent/src/channels/config_meta.py:193-208 | agent/src/channels/config_meta.py:232-247 | agent/src/channels/config_meta.py:289-309 \u2014 all 6 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 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 \u0060agent/src/channels/config_meta.py:78\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/config_meta.py"},"region":{"startLine":78}}}],"partialFingerprints":{"codehealthFindingId/v1":"e7d7bf32f59ae7620ca72e0fcddd020500dfc7492fa73cf9b6fb2cf521c31de5"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (19\u201321 lines \u00D7 2): agent/src/trading/connectors/futu/sdk.py:316-334 | agent/src/trading/connectors/futu/sdk.py:345-365 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 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 \u0060agent/src/trading/connectors/futu/sdk.py:316\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/futu/sdk.py"},"region":{"startLine":316}}}],"partialFingerprints":{"codehealthFindingId/v1":"0ba8889ee8b0e406db8f3602db1310b6ea3cb007de6038a622bc9e32e90faa40"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (19\u201320 lines \u00D7 2): agent/src/quantlib/fundmath.py:1528-1546 | agent/src/quantlib/fundmath.py:1678-1697 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 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 \u0060agent/src/quantlib/fundmath.py:1678\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, \u0060agent/src/quantlib/fundmath.py:1699\u0060 calls \u0060ValueError\u0060 and \u0060agent/src/quantlib/fundmath.py:1547\u0060 does not \u2014 after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/fundmath.py"},"region":{"startLine":1528}}}],"partialFingerprints":{"codehealthFindingId/v1":"b013f9636d3c063a921ce11b5d0af57d7a686496e0809c3a7beafda760e340c2"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (18\u201320 lines \u00D7 2): agent/src/tools/autopilot_tool.py:597-616 | agent/src/tools/backtest_tool.py:203-220 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/autopilot_tool.py"},"region":{"startLine":597}}}],"partialFingerprints":{"codehealthFindingId/v1":"5887f53ec7cf0d7a52f0a77496f94989a3906025531e18deaf128533d49dd89c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (20 lines \u00D7 2): agent/src/trading/connectors/longbridge/sdk.py:552-571 | agent/src/trading/connectors/tiger/sdk.py:398-417 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/longbridge/sdk.py"},"region":{"startLine":552}}}],"partialFingerprints":{"codehealthFindingId/v1":"6bc1e0db73262d7f5bf790182774cb6fe8c108d60315e7ebf62f2d6f5954f7f8"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (19 lines \u00D7 3): agent/src/factors/zoo/gtja191/alpha_149.py:56-74 | agent/src/factors/zoo/gtja191/alpha_181.py:54-72 | agent/src/factors/zoo/gtja191/alpha_182.py:54-72 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from all 3 call sites, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/gtja191/alpha_149.py"},"region":{"startLine":56}}}],"partialFingerprints":{"codehealthFindingId/v1":"2a4563a3d04e7639e8589b664c1e10bd722bef4a0a82a6b2f6ed94dc064226df"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (18\u201319 lines \u00D7 2): agent/src/channels/websocket.py:1014-1032 | agent/src/channels/websocket.py:1042-1059 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/websocket.py"},"region":{"startLine":1014}}}],"partialFingerprints":{"codehealthFindingId/v1":"26925e545675957821829e81139ab6ca3ca313b0718a9ad12c31213ba05f8934"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9\u201319 lines \u00D7 2): agent/src/factors/bench_runner.py:350-368 | agent/src/factors/bench_runner_strict.py:616-624 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060agent/src/factors/bench_runner_strict.py:616\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/bench_runner.py"},"region":{"startLine":350}}}],"partialFingerprints":{"codehealthFindingId/v1":"3b4ec32e568e20b9a4e8695148d3b60ffc1951adfba171ae60460dad122016e7"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (21 lines \u00D7 2): agent/src/skills/candlestick/example_signal_engine.py:347-367 | agent/src/skills/candlestick/example_signal_engine.py:381-401 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/skills/candlestick/example_signal_engine.py"},"region":{"startLine":347}}}],"partialFingerprints":{"codehealthFindingId/v1":"8136e84115e39ce5599167435ba818fbb9db7ebe860be360fa99cc6df1a16d1b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (32\u201333 lines \u00D7 2): agent/src/strategy_store/sqlite_store.py:409-441 | agent/src/strategy_store/sqlite_store.py:584-615 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/strategy_store/sqlite_store.py"},"region":{"startLine":409}}}],"partialFingerprints":{"codehealthFindingId/v1":"f9318b3550075036e7564910513ff4f5841a72e4164195d323c12128a128f315"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (17\u201319 lines \u00D7 2): agent/src/tools/trade_journal_parsers.py:387-405 | agent/src/tools/trade_journal_parsers.py:675-691 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/trade_journal_parsers.py"},"region":{"startLine":387}}}],"partialFingerprints":{"codehealthFindingId/v1":"a4af078efc84439092062f4c784976b37a4a69d9c1d7546e805fe0f8825b5ac8"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (17\u201318 lines \u00D7 2): agent/src/api/runs_routes.py:918-934 | agent/src/api/runs_routes.py:937-954 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/api/runs_routes.py"},"region":{"startLine":918}}}],"partialFingerprints":{"codehealthFindingId/v1":"9592ed64f35204ff02f64a489016aae4f228382c9c26afe27e5d41141cbfdee9"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (18 lines \u00D7 2): agent/src/skills/okx-market/scripts/candle_data_example.py:18-35 | agent/src/skills/okx-market/scripts/candle_data_example.py:49-66 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/skills/okx-market/scripts/candle_data_example.py"},"region":{"startLine":18}}}],"partialFingerprints":{"codehealthFindingId/v1":"ca241a9fb1a3747b8000c9aaac0f1b6a015568e3903ec5c96cc130f929fc6765"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (18 lines \u00D7 2): agent/src/tools/autopilot_tool.py:101-118 | agent/src/tools/autopilot_tool.py:301-318 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/autopilot_tool.py"},"region":{"startLine":101}}}],"partialFingerprints":{"codehealthFindingId/v1":"c36f16207dd943ba371632bc26dabf042646fc035ad19f9ee0715cec9c2d5a2a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10\u201318 lines \u00D7 2): agent/src/tools/block_trades_tool.py:155-172 | agent/src/tools/symbol_search_tool.py:739-748 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/block_trades_tool.py"},"region":{"startLine":155}}}],"partialFingerprints":{"codehealthFindingId/v1":"3b9c75dec2abd66f8effac1baf51f893a9341b0b392590269d25d8d713f1f2d6"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (17\u201318 lines \u00D7 2): agent/src/tools/skill_writer_tool.py:111-127 | agent/src/tools/skill_writer_tool.py:180-197 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/skill_writer_tool.py"},"region":{"startLine":111}}}],"partialFingerprints":{"codehealthFindingId/v1":"2b7ade3772ec018a43f7c08a177046f2c3a6f96ea0f24fec9f4676fc38460f87"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (18 lines \u00D7 2): agent/src/tools/skill_writer_tool.py:356-373 | agent/src/tools/skill_writer_tool.py:392-409 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/skill_writer_tool.py"},"region":{"startLine":356}}}],"partialFingerprints":{"codehealthFindingId/v1":"81f662c05d811fea6743e61ebd55dfcc85dd8330184db5d31edca3056949b5d8"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (18 lines \u00D7 2): agent/src/trading/connectors/mt5/orders.py:89-106 | agent/src/trading/connectors/okx/sdk.py:411-428 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/mt5/orders.py"},"region":{"startLine":89}}}],"partialFingerprints":{"codehealthFindingId/v1":"206b450937edc2f4dbc5a4d287b5bdf7f33523a2d34f44d49524d3b97b70d27a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13\u201317 lines \u00D7 6): agent/src/trading/connectors/binance/sdk.py:227-242 | agent/src/trading/connectors/dhan/sdk.py:200-215 | agent/src/trading/connectors/mt5/reads.py:69-81 | agent/src/trading/connectors/shoonya/sdk.py:199-215 | agent/src/trading/connectors/tiger/sdk.py:195-208 | agent/src/trading/connectors/upbit/sdk.py:194-209 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 6 call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made 6 times. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. Note first that the copies are not typed on the same thing: the declarations holding them bind \u0060config\u0060 to \u0060BinanceConfig | None = None\u0060 in one and \u0060DhanConfig | None = None\u0060 in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH \u2014 their common supertype where they have one, or a new abstraction over them where they do not \u2014 and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/binance/sdk.py"},"region":{"startLine":227}}}],"partialFingerprints":{"codehealthFindingId/v1":"e31c53cd10f9fe7faefc5de3983922e5b09c3bcc970f7065166278e7f73ca48e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (17 lines \u00D7 4): agent/src/swarm/worker.py:749-765 | agent/src/swarm/worker.py:771-787 | agent/src/swarm/worker.py:815-831 | agent/src/swarm/worker.py:950-966 \u2014 all 4 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/swarm/worker.py"},"region":{"startLine":749}}}],"partialFingerprints":{"codehealthFindingId/v1":"a9e9970df16217af4110cf49b9461363aaee7436fcc435a218f269c65722bbe2"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12\u201317 lines \u00D7 2): agent/src/channels/telegram.py:167-178 | agent/src/channels/telegram.py:282-298 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 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 \u0060agent/src/channels/telegram.py:167\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/telegram.py"},"region":{"startLine":167}}}],"partialFingerprints":{"codehealthFindingId/v1":"3e298b6b6028bd65969348fa4524f29533a10291f3636474442bf64c8615f1b4"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (17 lines \u00D7 2): agent/src/memory/persistent.py:348-364 | agent/src/memory/persistent.py:700-716 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/memory/persistent.py"},"region":{"startLine":348}}}],"partialFingerprints":{"codehealthFindingId/v1":"2f9fb0bf4079229d9798ae036489c29583ee916a820c5cc1a061a9cbfaf75e13"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10\u201317 lines \u00D7 2): agent/src/providers/chat.py:370-386 | agent/src/providers/chat.py:392-401 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/providers/chat.py"},"region":{"startLine":370}}}],"partialFingerprints":{"codehealthFindingId/v1":"6cb2701fd269dbc4100a5f0e1bdb208860fc51e82b42ef5eb4ef8eb59b72c652"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (16\u201317 lines \u00D7 2): agent/src/tools/web_search_tool.py:70-85 | agent/src/tools/web_search_tool.py:105-121 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/web_search_tool.py"},"region":{"startLine":70}}}],"partialFingerprints":{"codehealthFindingId/v1":"70ff2c678b8fe452fc8b20b4a2f7f14480f0bf2f72aedc4be461d8b97a614d15"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (17 lines \u00D7 2): agent/src/trading/connectors/futu/sdk.py:844-860 | agent/src/trading/connectors/futu/sdk.py:934-950 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, \u0060agent/src/trading/connectors/futu/sdk.py:932\u0060 calls \u0060str\u0060, \u0060strip\u0060, \u0060upper\u0060 and \u0060agent/src/trading/connectors/futu/sdk.py:842\u0060 does not \u2014 after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/futu/sdk.py"},"region":{"startLine":844}}}],"partialFingerprints":{"codehealthFindingId/v1":"422b3ef65cb21cab1a1e5ee494c807ea8112eb6dcc8a27038e7c0a1a5fabf5bf"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (17 lines \u00D7 2): agent/src/trading/connectors/kis/sdk.py:248-264 | agent/src/trading/connectors/toss/sdk.py:180-197 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. Note first that the copies are not typed on the same thing: the declarations holding them bind \u0060config\u0060 to \u0060KISConfig | None = None\u0060 in one and \u0060TossConfig | None = None\u0060 in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH \u2014 their common supertype where they have one, or a new abstraction over them where they do not \u2014 and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/kis/sdk.py"},"region":{"startLine":248}}}],"partialFingerprints":{"codehealthFindingId/v1":"6cf5e55dd5eb1f9eb6efbcc24fe43a5f97f4fde6112b8258603b886dd6427541"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9\u201316 lines \u00D7 10): agent/src/trading/connectors/alpaca/sdk.py:175-183 | agent/src/trading/connectors/binance/sdk.py:198-206 | agent/src/trading/connectors/etoro/client.py:169-177 | agent/src/trading/connectors/futu/sdk.py:215-223 | agent/src/trading/connectors/ibkr/local.py:161-176 | agent/src/trading/connectors/mt5/_client.py:164-172 | agent/src/trading/connectors/okx/sdk.py:168-176 | agent/src/trading/connectors/tiger/sdk.py:168-176 | agent/src/trading/connectors/toss/sdk.py:168-176 | agent/src/trading/connectors/trading212/sdk.py:151-159 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 10 call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made 10 times. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on. Note first that the copies are not typed on the same thing: the declarations holding them bind \u0060config\u0060 to \u0060AlpacaConfig\u0060 in one and \u0060BinanceConfig\u0060 in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH \u2014 their common supertype where they have one, or a new abstraction over them where they do not \u2014 and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/alpaca/sdk.py"},"region":{"startLine":175}}}],"partialFingerprints":{"codehealthFindingId/v1":"2f1e47be8eda9ebafdc8b4ea034ab5fa42f209b2b9bc84840e77cf8266fccbb2"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10\u201316 lines \u00D7 6): agent/mcp_server.py:953-968 | agent/src/trading/connectors/binance/sdk.py:126-137 | agent/src/trading/connectors/futu/sdk.py:146-157 | agent/src/trading/connectors/kis/sdk.py:165-174 | agent/src/trading/connectors/okx/sdk.py:107-118 | agent/src/trading/connectors/toss/sdk.py:116-125 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 6 call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made 6 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/mcp_server.py"},"region":{"startLine":953}}}],"partialFingerprints":{"codehealthFindingId/v1":"2c97a1279f8e4cc743210311cd855b1c9fbb2cdfed4d9d9efdb886d95144828b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (16 lines \u00D7 4): agent/backtest/loaders/fmp_loader.py:133-148 | agent/backtest/loaders/pykrx_loader.py:129-144 | agent/backtest/loaders/sina_loader.py:166-181 | agent/backtest/loaders/stooq_loader.py:216-231 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from all 4 call sites, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/fmp_loader.py"},"region":{"startLine":133}}}],"partialFingerprints":{"codehealthFindingId/v1":"0333e44555ff36a18521cd0e6a6330bc280a92c69e1145c1ae82efb5761ade73"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (15\u201316 lines \u00D7 2): agent/src/api/live_routes.py:1384-1399 | agent/src/api/live_routes.py:1434-1448 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/api/live_routes.py"},"region":{"startLine":1384}}}],"partialFingerprints":{"codehealthFindingId/v1":"a2dff1e9387505c8b18c172c86c9c33b5fae9f606fb6b25711dfbe2881281db6"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (20 lines \u00D7 2): agent/src/tools/pattern_tool.py:236-255 | agent/src/tools/pattern_tool.py:271-290 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 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 \u0060agent/src/tools/pattern_tool.py:236\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/pattern_tool.py"},"region":{"startLine":236}}}],"partialFingerprints":{"codehealthFindingId/v1":"7368010ff607cce949190109fdcaa092c99e73aa180197800f75b89f37e99fd3"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (16 lines \u00D7 2): agent/src/trading/connectors/dhan/sdk.py:295-310 | agent/src/trading/connectors/shoonya/sdk.py:291-306 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/dhan/sdk.py"},"region":{"startLine":295}}}],"partialFingerprints":{"codehealthFindingId/v1":"fd70c82722aa1216c2819088a1f9cf92132814f2169f8d441fc28bef70df17eb"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (16 lines \u00D7 2): agent/src/trading/connectors/toss/sdk.py:408-423 | agent/src/trading/connectors/trading212/sdk.py:361-376 \u2014 \u0060agent/src/trading/connectors/toss/sdk.py\u0060 and \u0060agent/src/trading/connectors/trading212/sdk.py\u0060 are one unit implemented once per sibling directory, so they are most likely parallel implementations of one contract rather than a copy of each other \u2014 this scan matched 6 separate duplicated blocks between them, totalling at least 61 lines. If both are selected at run time, neither can be retired in favour of the other, and the lines that DIFFER between them are the reason both exist. The move that pays here is to hoist the identical part into a shared location the whole family can reach and give what differs a parameter or a seam, so a change lands once instead of once per sibling; extracting one helper per block leaves every sibling to drift on its own. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. Note first that the copies are not typed on the same thing: the declarations holding them bind \u0060config\u0060 to \u0060TossConfig | None = None\u0060 in one and \u0060Trading212Config | None = None\u0060 in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH \u2014 their common supertype where they have one, or a new abstraction over them where they do not \u2014 and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/toss/sdk.py"},"region":{"startLine":408}}}],"partialFingerprints":{"codehealthFindingId/v1":"63113af1bb2ea65938bf812ee456895127510e75dc35f7f4c8a656ba69d388de"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14\u201315 lines \u00D7 3): agent/backtest/loaders/akshare_loader.py:168-181 | agent/backtest/loaders/eastmoney_loader.py:120-134 | agent/backtest/loaders/tencent_loader.py:117-130 \u2014 before extracting anything, compare \u0060agent/backtest/loaders/akshare_loader.py\u0060 and \u0060agent/backtest/loaders/eastmoney_loader.py\u0060 as WHOLE FILES: this scan already matched 6 separate duplicated blocks between them, totalling at least 130 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together \u2014 extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at \u0060agent/backtest/loaders/akshare_loader.py:168\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/akshare_loader.py"},"region":{"startLine":168}}}],"partialFingerprints":{"codehealthFindingId/v1":"2a05a43c67d5cbfe6913d49d59b68cd4cf9cdb3eb372335ddb4893cfe47d9221"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8\u201315 lines \u00D7 3): agent/backtest/loaders/yahoo_client.py:222-236 | agent/backtest/loaders/yahoo_client.py:350-357 | agent/backtest/loaders/yahoo_client.py:412-419 \u2014 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 \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/yahoo_client.py"},"region":{"startLine":222}}}],"partialFingerprints":{"codehealthFindingId/v1":"716349a6e810958f566d4cac6d8abf34973a0fda620cb05c12cd3b344ee8a029"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10\u201315 lines \u00D7 2): agent/backtest/correlation.py:208-222 | agent/backtest/regime.py:118-127 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/correlation.py"},"region":{"startLine":208}}}],"partialFingerprints":{"codehealthFindingId/v1":"21e1475a2f7a50b771f46030f34c0fe3ec3220117ef54464f0980d0cb34b5b70"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (15 lines \u00D7 2): agent/backtest/engines/korea_equity.py:206-220 | agent/backtest/engines/vietnam_equity.py:304-318 \u2014 before extracting anything, compare \u0060agent/backtest/engines/korea_equity.py\u0060 and \u0060agent/backtest/engines/vietnam_equity.py\u0060 as WHOLE FILES: this scan already matched 6 separate duplicated blocks between them, totalling at least 118 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together \u2014 extracting one helper per block leaves the fork in place. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/engines/korea_equity.py"},"region":{"startLine":206}}}],"partialFingerprints":{"codehealthFindingId/v1":"807e660828b13a0f7b5764a78530478deb4882b7308de1dafa67e6ebd37fa67d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (15 lines \u00D7 2): agent/src/channels/weixin.py:1312-1326 | agent/src/channels/weixin.py:1463-1477 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/weixin.py"},"region":{"startLine":1312}}}],"partialFingerprints":{"codehealthFindingId/v1":"6a16b4c0044bbff42e1e55f72b31a1d2027c004778966c118f619f29b384f245"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14\u201315 lines \u00D7 2): agent/src/config/writer.py:130-144 | agent/src/tools/background_store.py:170-183 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 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 \u0060agent/src/config/writer.py:130\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/config/writer.py"},"region":{"startLine":130}}}],"partialFingerprints":{"codehealthFindingId/v1":"7238709129278cbf4fb96343f2eb6fa238ec2f8cad7e22b820bf1e0902aa04ea"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (15 lines \u00D7 2): agent/src/factors/cli_handlers.py:452-466 | agent/src/factors/cli_handlers.py:523-537 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/cli_handlers.py"},"region":{"startLine":452}}}],"partialFingerprints":{"codehealthFindingId/v1":"66a5d0903ff30ff4a1bf9f87dc27bcc9f6a3a20d102e9076e7d02a4b20e8eae2"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (15 lines \u00D7 2): agent/src/factors/zoo/gtja191/alpha_109.py:54-68 | agent/src/factors/zoo/gtja191/alpha_188.py:54-68 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/gtja191/alpha_109.py"},"region":{"startLine":54}}}],"partialFingerprints":{"codehealthFindingId/v1":"1849120434ea11590feee061b1236c36f0fcd78b256e648524f7d4650f11848a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (27 lines \u00D7 2): agent/src/factors/zoo/gtja191/alpha_172.py:54-80 | agent/src/factors/zoo/gtja191/alpha_186.py:54-80 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/gtja191/alpha_172.py"},"region":{"startLine":54}}}],"partialFingerprints":{"codehealthFindingId/v1":"e22f9ce4be09c49fa300fbe315dd1bd4ee7897c2ab8113a29eee20b364e97580"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10\u201315 lines \u00D7 2): agent/src/live/order_guard.py:276-290 | agent/src/live/sdk_order_gate.py:911-920 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060agent/src/live/order_guard.py:276\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/live/order_guard.py"},"region":{"startLine":276}}}],"partialFingerprints":{"codehealthFindingId/v1":"02213548346596aabe47a3ad9d18e9572595711c00a514166d2af9fd35510e66"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (15 lines \u00D7 2): agent/src/skills/elliott-wave/example_signal_engine.py:317-331 | agent/src/skills/elliott-wave/example_signal_engine.py:349-363 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/skills/elliott-wave/example_signal_engine.py"},"region":{"startLine":317}}}],"partialFingerprints":{"codehealthFindingId/v1":"1d64683878b09e22bcb6482d6ff9c6c013706f695ce7fa50f00b0b10a2157684"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13\u201314 lines \u00D7 2): agent/backtest/engines/china_a.py:87-100 | agent/backtest/engines/india_equity.py:113-125 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/engines/china_a.py"},"region":{"startLine":87}}}],"partialFingerprints":{"codehealthFindingId/v1":"3e90d5e7b2273982db6fcbd0f4d533c1d61f53606927d012bc65fe6cbfe31d4e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 2): agent/backtest/loaders/nobitex.py:220-233 | agent/backtest/loaders/wallex.py:219-232 \u2014 before extracting anything, compare \u0060agent/backtest/loaders/nobitex.py\u0060 and \u0060agent/backtest/loaders/wallex.py\u0060 as WHOLE FILES: this scan already matched 3 separate duplicated blocks between them, totalling at least 49 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together \u2014 extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at \u0060agent/backtest/loaders/nobitex.py:220\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/nobitex.py"},"region":{"startLine":220}}}],"partialFingerprints":{"codehealthFindingId/v1":"aba7dcd73dacaa9ebc76086b999d52d30afee4090852bc9636158cba4ddfed39"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 2): agent/cli/_legacy.py:3268-3281 | agent/cli/_legacy.py:3285-3298 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":3268}}}],"partialFingerprints":{"codehealthFindingId/v1":"7a0ee96c5b320689fc0d4358485602ddd4b313eae1b9b5a631a5fa076152fae2"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13\u201314 lines \u00D7 2): agent/cli/onboard.py:223-236 | agent/cli/onboard.py:262-274 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 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 \u0060agent/cli/onboard.py:223\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/onboard.py"},"region":{"startLine":223}}}],"partialFingerprints":{"codehealthFindingId/v1":"2e3b5a9fca1388373bc79f2f25236a10a207c6bc4ce532aaea8624038b57f3f5"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 2): agent/mcp_server.py:3057-3070 | agent/mcp_server.py:3082-3097 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/mcp_server.py"},"region":{"startLine":3057}}}],"partialFingerprints":{"codehealthFindingId/v1":"44b57da925a9e974d0197dcb6bc5bd718bf0ad53d3648238729bdbbcb658bf45"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11\u201314 lines \u00D7 2): agent/src/agent/loop.py:973-986 | agent/src/agent/loop.py:1003-1013 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 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 \u0060agent/src/agent/loop.py:973\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/agent/loop.py"},"region":{"startLine":973}}}],"partialFingerprints":{"codehealthFindingId/v1":"7e8e140480acec55dd76e32b7cdad798f434245028855ed4e0a6c28298c5b980"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13\u201314 lines \u00D7 2): agent/src/agent/tool_lifecycle.py:606-618 | agent/src/agent/tool_lifecycle.py:660-673 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/agent/tool_lifecycle.py"},"region":{"startLine":606}}}],"partialFingerprints":{"codehealthFindingId/v1":"b45c6d977865546fdc04e62603dbead3c806950fc50802fcc31b12d6dd7c5f4d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12\u201314 lines \u00D7 2): agent/src/api/security.py:440-451 | agent/src/api/security.py:646-659 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/api/security.py"},"region":{"startLine":440}}}],"partialFingerprints":{"codehealthFindingId/v1":"780a4bd5093b65a3a247d024ab21f1aacefb73dcb4c8211daa71548294d1a605"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12\u201314 lines \u00D7 2): agent/src/channels/discord.py:532-545 | agent/src/channels/telegram.py:1046-1057 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/discord.py"},"region":{"startLine":532}}}],"partialFingerprints":{"codehealthFindingId/v1":"33ea3998e8476f7da9b7ccd9e24fa31548b9f81bd8d2cf3bd7d0dd4e9bb24040"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 2): agent/src/channels/mochat.py:551-564 | agent/src/channels/mochat.py:585-598 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/mochat.py"},"region":{"startLine":551}}}],"partialFingerprints":{"codehealthFindingId/v1":"e5607d4483a3dcf5d8ef44b469d71adfb6bfa129dd2b6632031bb29e469b752c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 2): agent/src/preflight.py:108-121 | agent/src/preflight.py:127-140 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, \u0060agent/src/preflight.py:123\u0060 calls \u0060lower\u0060, \u0060get_claude_cli_auth_status\u0060 and \u0060agent/src/preflight.py:142\u0060 does not \u2014 after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/preflight.py"},"region":{"startLine":108}}}],"partialFingerprints":{"codehealthFindingId/v1":"2af7f56a49d624b0205cf2820fd38c191ff555fec9e1184fbb9459e997deab1b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 2): agent/src/tools/get_fundamentals_tool.py:129-142 | agent/src/tools/market_data_tool.py:173-189 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, \u0060agent/src/tools/get_fundamentals_tool.py:127\u0060 calls \u0060public_data_read\u0060 and \u0060agent/src/tools/market_data_tool.py:170\u0060 does not \u2014 after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/get_fundamentals_tool.py"},"region":{"startLine":129}}}],"partialFingerprints":{"codehealthFindingId/v1":"8bc8e11b6e439d591dec488d00de1512e1ea53373f34fd3993aa203aff975ed3"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 2): agent/src/trading/connectors/longbridge/sdk.py:530-543 | agent/src/trading/connectors/tiger/sdk.py:377-390 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/longbridge/sdk.py"},"region":{"startLine":530}}}],"partialFingerprints":{"codehealthFindingId/v1":"fda4db6bd72e311cae188dc4c5dd90042458fa43f3743b1ca67e62d08db8a181"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 4): agent/backtest/loaders/alphavantage_loader.py:151-163 | agent/backtest/loaders/finnhub_loader.py:216-228 | agent/backtest/loaders/tiingo_loader.py:327-339 | agent/backtest/loaders/yahoo_loader.py:252-264 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from all 4 call sites, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/alphavantage_loader.py"},"region":{"startLine":151}}}],"partialFingerprints":{"codehealthFindingId/v1":"7db218f9faecd256e9b99bc8ec73da4eb6057be833daacc0eee5f908d39e04df"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12\u201313 lines \u00D7 3): agent/backtest/loaders/akshare_loader.py:155-166 | agent/backtest/loaders/eastmoney_loader.py:106-118 | agent/backtest/loaders/tencent_loader.py:104-115 \u2014 before extracting anything, compare \u0060agent/backtest/loaders/akshare_loader.py\u0060 and \u0060agent/backtest/loaders/eastmoney_loader.py\u0060 as WHOLE FILES: this scan already matched 6 separate duplicated blocks between them, totalling at least 130 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together \u2014 extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at \u0060agent/backtest/loaders/akshare_loader.py:155\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/akshare_loader.py"},"region":{"startLine":155}}}],"partialFingerprints":{"codehealthFindingId/v1":"5040183ab42eca3cdec561405d8308275a371fd7319823dae66adf8e57dd6ee5"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 3): agent/backtest/loaders/alphavantage_loader.py:147-159 | agent/backtest/loaders/finnhub_loader.py:212-224 | agent/backtest/loaders/fmp_loader.py:129-141 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from all 3 call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060agent/backtest/loaders/alphavantage_loader.py:147\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/alphavantage_loader.py"},"region":{"startLine":147}}}],"partialFingerprints":{"codehealthFindingId/v1":"89d785883c64cdf9fe0fbc5599efcef906f27d190cb51353fe4d964c927bfa46"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11\u201313 lines \u00D7 3): agent/backtest/loaders/alphavantage_loader.py:156-168 | agent/backtest/loaders/finnhub_loader.py:221-233 | agent/backtest/loaders/mootdx_loader.py:151-161 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from all 3 call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060agent/backtest/loaders/alphavantage_loader.py:156\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/alphavantage_loader.py"},"region":{"startLine":156}}}],"partialFingerprints":{"codehealthFindingId/v1":"47a50d8a7f5263519e93379240756c64246d7f6b1b7955c57acc37bce236d487"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 3): agent/src/api/attribution_routes.py:55-67 | agent/src/api/runs_routes.py:853-865 | agent/src/api/scheduled_routes.py:458-470 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from all 3 call sites, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/api/attribution_routes.py"},"region":{"startLine":55}}}],"partialFingerprints":{"codehealthFindingId/v1":"ccd24a9b98f4575a6d6fbf52fbe759f8210d653cea2c3159cb9053f3df346bde"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 3): agent/src/channels/websocket.py:1021-1033 | agent/src/channels/websocket.py:1048-1060 | agent/src/channels/websocket.py:1138-1150 \u2014 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 \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/websocket.py"},"region":{"startLine":1021}}}],"partialFingerprints":{"codehealthFindingId/v1":"4e89538dd090b90bb4414b0567e23e3924cfe57d80af32b76204d299a4f78f17"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12\u201313 lines \u00D7 2): agent/scripts/w4a_run_benches.py:82-94 | agent/scripts/w4a_run_benches.py:99-110 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 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 \u0060agent/scripts/w4a_run_benches.py:82\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/scripts/w4a_run_benches.py"},"region":{"startLine":82}}}],"partialFingerprints":{"codehealthFindingId/v1":"33d39fe601195ac5b17e41b93213fd873c340c25268bc1a9e68d496b3d6b7c0f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (19 lines \u00D7 2): agent/src/channels/signal.py:115-133 | agent/src/channels/telegram.py:206-224 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/signal.py"},"region":{"startLine":115}}}],"partialFingerprints":{"codehealthFindingId/v1":"5f900e04a0008cc21d9acea8d923b666710bc94d7d984a9742a1fba7d23e6c35"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (19 lines \u00D7 2): agent/src/factors/zoo/gtja191/alpha_161.py:54-72 | agent/src/factors/zoo/gtja191/alpha_175.py:54-72 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/gtja191/alpha_161.py"},"region":{"startLine":54}}}],"partialFingerprints":{"codehealthFindingId/v1":"e1aee532316839f9efda29d7fef5eb05d38572cf45147e96c35e4356fc0a38d4"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): agent/src/live/enforcement.py:270-282 | agent/src/live/enforcement.py:761-773 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/live/enforcement.py"},"region":{"startLine":270}}}],"partialFingerprints":{"codehealthFindingId/v1":"c6b40b7406e2ffa03b232237c29d67a44503c46ede99a4a55eb3ab7fb25bb534"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12\u201313 lines \u00D7 2): agent/src/quantlib/fundmath.py:1547-1558 | agent/src/quantlib/fundmath.py:1702-1714 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 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 \u0060agent/src/quantlib/fundmath.py:1702\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, \u0060agent/src/quantlib/fundmath.py:1546\u0060 calls \u0060tuple\u0060, \u0060filter\u0060 and \u0060agent/src/quantlib/fundmath.py:1702\u0060 does not \u2014 after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/fundmath.py"},"region":{"startLine":1547}}}],"partialFingerprints":{"codehealthFindingId/v1":"20719e1e95ab7b3837b5d464e6f6760b1c6881c3c7448f87d7cbf8a3d137d73b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12\u201313 lines \u00D7 2): agent/src/tools/gildata_fin_query_tool.py:139-151 | agent/src/tools/gildata_stock_selection_tool.py:49-60 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/gildata_fin_query_tool.py"},"region":{"startLine":139}}}],"partialFingerprints":{"codehealthFindingId/v1":"525c261c02d59141245014a161db7fc6840348ffc919370437545d80af9cc347"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12\u201313 lines \u00D7 2): agent/src/trading/connectors/shoonya/sdk.py:467-479 | agent/src/trading/connectors/zerodha/sdk.py:591-602 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/shoonya/sdk.py"},"region":{"startLine":467}}}],"partialFingerprints":{"codehealthFindingId/v1":"0139e0b6632b717fd2ccfb9e61a40f44449e81c099d7643fbce71076e296ea23"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 6): agent/backtest/loaders/alphavantage_loader.py:148-159 | agent/backtest/loaders/finnhub_loader.py:213-224 | agent/backtest/loaders/fmp_loader.py:130-141 | agent/backtest/loaders/pykrx_loader.py:125-137 | agent/backtest/loaders/stooq_loader.py:212-224 | agent/backtest/loaders/tiingo_loader.py:324-335 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from all 6 call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060agent/backtest/loaders/alphavantage_loader.py:148\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/alphavantage_loader.py"},"region":{"startLine":148}}}],"partialFingerprints":{"codehealthFindingId/v1":"0d17db28e7a7ff2ee9cdc817b78842154dcd067804dad8721ffe797b3232166b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10\u201312 lines \u00D7 5): agent/backtest/loaders/alphavantage_loader.py:154-165 | agent/backtest/loaders/finnhub_loader.py:219-230 | agent/backtest/loaders/mootdx_loader.py:149-158 | agent/backtest/loaders/tiingo_loader.py:330-341 | agent/backtest/loaders/yahoo_loader.py:255-266 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from all 5 call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060agent/backtest/loaders/alphavantage_loader.py:154\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, \u0060agent/backtest/loaders/yahoo_loader.py:268\u0060 calls \u0060acquisition_error_kind\u0060 and \u0060agent/backtest/loaders/alphavantage_loader.py:167\u0060 does not \u2014 after which the two agree again for 3 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/alphavantage_loader.py"},"region":{"startLine":154}}}],"partialFingerprints":{"codehealthFindingId/v1":"180abf4a0e2d5250f4c1a22fcf95e14afe95620e28b1fcc6c5943b9c40dfaffd"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 5): agent/src/trading/connectors/binance/sdk.py:235-246 | agent/src/trading/connectors/dhan/sdk.py:208-219 | agent/src/trading/connectors/okx/sdk.py:209-220 | agent/src/trading/connectors/tiger/sdk.py:201-212 | agent/src/trading/connectors/upbit/sdk.py:202-213 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 5 call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made 5 times. 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/binance/sdk.py"},"region":{"startLine":235}}}],"partialFingerprints":{"codehealthFindingId/v1":"b4b3941736108b3f30ce8fa15d88280b507962dac06f8d8df903e55b6a78467e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 3): agent/cli/_legacy.py:5044-5055 | agent/cli/_legacy.py:5109-5120 | agent/cli/_legacy.py:5172-5183 \u2014 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 \u2014 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 \u0060agent/cli/_legacy.py:5044\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 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. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, \u0060agent/cli/_legacy.py:5187\u0060 calls \u0060isinstance\u0060 and \u0060agent/cli/_legacy.py:5057\u0060 does not \u2014 after which the two agree again for 3 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":5044}}}],"partialFingerprints":{"codehealthFindingId/v1":"348a650684b53dac8ccb21b7b379bc01f18bebbe54d0a1c870ce793df48465f4"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 3): agent/src/trading/connectors/alpaca/sdk.py:537-548 | agent/src/trading/connectors/longbridge/sdk.py:548-559 | agent/src/trading/connectors/tiger/sdk.py:394-405 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 3 call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made 3 times. 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/alpaca/sdk.py"},"region":{"startLine":537}}}],"partialFingerprints":{"codehealthFindingId/v1":"1873cd64b9dcfb838402ba6664be558f433f663e6e580dffc4e11e794221805f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): agent/backtest/optimizers/max_diversification.py:37-48 | agent/backtest/optimizers/mean_variance.py:53-64 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/optimizers/max_diversification.py"},"region":{"startLine":37}}}],"partialFingerprints":{"codehealthFindingId/v1":"f8664183d802f364690646f0f3c03d69dc5e0f8a37ebd5aef21f8925c473208e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): agent/src/channels/telegram.py:74-85 | agent/src/channels/utils.py:81-92 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/telegram.py"},"region":{"startLine":74}}}],"partialFingerprints":{"codehealthFindingId/v1":"0c21d589e7765c52e6e75f7c12da47713d0c00c0ab262a8e2bdd433bb992748a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10\u201312 lines \u00D7 2): agent/src/channels/whatsapp.py:223-232 | agent/src/channels/whatsapp.py:253-264 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 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 \u0060agent/src/channels/whatsapp.py:223\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/whatsapp.py"},"region":{"startLine":223}}}],"partialFingerprints":{"codehealthFindingId/v1":"0ac3645fe6da37b162539e18ce07a012975878da5dab04c14d0e30b68ddfe8f6"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): agent/src/factors/zoo/alpha101/alpha_009.py:76-87 | agent/src/factors/zoo/alpha101/alpha_010.py:76-87 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/alpha101/alpha_009.py"},"region":{"startLine":76}}}],"partialFingerprints":{"codehealthFindingId/v1":"deb6b7f3978aa7efa7035ed11072bbc0ba185dd8eb4bd871efeb0e9b9b7e9284"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): agent/src/factors/zoo/alpha101/alpha_049.py:93-104 | agent/src/factors/zoo/alpha101/alpha_051.py:93-104 \u2014 before extracting anything, compare \u0060agent/src/factors/zoo/alpha101/alpha_049.py\u0060 and \u0060agent/src/factors/zoo/alpha101/alpha_051.py\u0060 as WHOLE FILES: this scan already matched 3 separate duplicated blocks between them, totalling at least 40 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together \u2014 extracting one helper per block leaves the fork in place. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/alpha101/alpha_049.py"},"region":{"startLine":93}}}],"partialFingerprints":{"codehealthFindingId/v1":"4d9a4a0fa222dfb001fd45df460dc576080b8dcf0e194c76bfbea4e48db30980"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11\u201312 lines \u00D7 2): agent/src/quantlib/crossvalidation.py:258-269 | agent/src/quantlib/crossvalidation.py:527-537 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 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 \u0060agent/src/quantlib/crossvalidation.py:527\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/crossvalidation.py"},"region":{"startLine":258}}}],"partialFingerprints":{"codehealthFindingId/v1":"f92729cd92298deabeeb5bd3d3ff133f3bd10997728b626392a47dd0f623be98"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): agent/src/tools/trade_journal_parsers.py:496-507 | agent/src/tools/trade_journal_parsers.py:510-521 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/trade_journal_parsers.py"},"region":{"startLine":496}}}],"partialFingerprints":{"codehealthFindingId/v1":"c7e84539d69849d865f10ffe76a3092cd0e31e53a8b53f960fad2f88cae13061"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (18 lines \u00D7 10): agent/src/factors/zoo/alpha101/alpha_007.py:60-77 | agent/src/factors/zoo/alpha101/alpha_009.py:55-72 | agent/src/factors/zoo/alpha101/alpha_010.py:55-72 | agent/src/factors/zoo/alpha101/alpha_021.py:65-82 | agent/src/factors/zoo/alpha101/alpha_023.py:60-77 | agent/src/factors/zoo/alpha101/alpha_024.py:67-84 | agent/src/factors/zoo/alpha101/alpha_027.py:65-82 | agent/src/factors/zoo/alpha101/alpha_046.py:67-84 | agent/src/factors/zoo/alpha101/alpha_049.py:67-84 | agent/src/factors/zoo/alpha101/alpha_051.py:67-84 \u2014 before extracting anything, compare \u0060agent/src/factors/zoo/alpha101/alpha_049.py\u0060 and \u0060agent/src/factors/zoo/alpha101/alpha_051.py\u0060 as WHOLE FILES: this scan already matched 3 separate duplicated blocks between them, totalling at least 40 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together \u2014 extracting one helper per block leaves the fork in place. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, \u0060agent/src/factors/zoo/alpha101/alpha_007.py:54\u0060 calls \u0060_make_one\u0060, \u0060DataFrame\u0060 and \u0060agent/src/factors/zoo/alpha101/alpha_009.py:51\u0060 does not \u2014 after which the two agree again for 3 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/alpha101/alpha_007.py"},"region":{"startLine":60}}}],"partialFingerprints":{"codehealthFindingId/v1":"9e594954821703e321260edf08a5b47fcfbcfad6c10e173e6a7cb86a7370a0f5"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10\u201311 lines \u00D7 8): agent/backtest/loaders/alphavantage_loader.py:150-160 | agent/backtest/loaders/finnhub_loader.py:215-225 | agent/backtest/loaders/fmp_loader.py:132-141 | agent/backtest/loaders/pykrx_loader.py:128-137 | agent/backtest/loaders/sina_loader.py:165-174 | agent/backtest/loaders/stooq_loader.py:215-224 | agent/backtest/loaders/tiingo_loader.py:326-336 | agent/backtest/loaders/yahoo_loader.py:251-261 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from all 8 call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060agent/backtest/loaders/alphavantage_loader.py:150\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/alphavantage_loader.py"},"region":{"startLine":150}}}],"partialFingerprints":{"codehealthFindingId/v1":"f3e896c49fb8f0afc43690384945a81470155166b1a264dafd8900e7fe381207"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 5): agent/src/trading/connectors/dhan/sdk.py:171-181 | agent/src/trading/connectors/kis/sdk.py:229-239 | agent/src/trading/connectors/shoonya/sdk.py:171-181 | agent/src/trading/connectors/upbit/sdk.py:165-175 | agent/src/trading/connectors/zerodha/sdk.py:165-175 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 5 call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made 5 times. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on. Note first that the copies are not typed on the same thing: the declarations holding them bind \u0060config\u0060 to \u0060DhanConfig\u0060 in one and \u0060KISConfig\u0060 in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH \u2014 their common supertype where they have one, or a new abstraction over them where they do not \u2014 and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/dhan/sdk.py"},"region":{"startLine":171}}}],"partialFingerprints":{"codehealthFindingId/v1":"1c2792bd792bfdb3e6c4e7d0b736ded7b58f500b877a2ed40936b6d2926fde62"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 3): agent/backtest/loaders/akshare_loader.py:158-168 | agent/backtest/loaders/eastmoney_loader.py:109-121 | agent/backtest/loaders/mootdx_loader.py:146-156 \u2014 before extracting anything, compare \u0060agent/backtest/loaders/akshare_loader.py\u0060 and \u0060agent/backtest/loaders/eastmoney_loader.py\u0060 as WHOLE FILES: this scan already matched 6 separate duplicated blocks between them, totalling at least 130 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together \u2014 extracting one helper per block leaves the fork in place."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/akshare_loader.py"},"region":{"startLine":158}}}],"partialFingerprints":{"codehealthFindingId/v1":"e8c0a93294559a1d925cbcf131466dd260c74c4f341593ae44bd71437c50e337"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): agent/backtest/engines/korea_equity.py:158-168 | agent/backtest/engines/vietnam_equity.py:378-388 \u2014 before extracting anything, compare \u0060agent/backtest/engines/korea_equity.py\u0060 and \u0060agent/backtest/engines/vietnam_equity.py\u0060 as WHOLE FILES: this scan already matched 6 separate duplicated blocks between them, totalling at least 118 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together \u2014 extracting one helper per block leaves the fork in place."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/engines/korea_equity.py"},"region":{"startLine":158}}}],"partialFingerprints":{"codehealthFindingId/v1":"4c1711f2993b11f8023ef331df5529a4852115ce2ed7a116c9a680a2be9cdee7"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10\u201311 lines \u00D7 2): agent/backtest/loaders/ccxt_loader.py:98-108 | agent/backtest/loaders/okx.py:87-96 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/ccxt_loader.py"},"region":{"startLine":98}}}],"partialFingerprints":{"codehealthFindingId/v1":"c2ed737ce890e58b58e481ccb1f63bb90ae8992211e45a64dbba9bd176936ae3"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10\u201311 lines \u00D7 2): agent/cli/_legacy.py:4868-4878 | agent/cli/_legacy.py:4968-4977 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":4868}}}],"partialFingerprints":{"codehealthFindingId/v1":"305d003cb0c99749460dbe52482af578ab10bf79e2d3c208296c929a42f4aa2d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): agent/cli/_legacy.py:6212-6222 | agent/cli/_legacy.py:6302-6312 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 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 \u0060agent/cli/_legacy.py:6212\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":6212}}}],"partialFingerprints":{"codehealthFindingId/v1":"f168fcf67cb4c44897d00ed7560bebaf0b16a25ee016b6fced33fc0d224e4891"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): agent/src/channels/feishu.py:1461-1471 | agent/src/channels/feishu.py:1496-1506 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 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 \u0060agent/src/channels/feishu.py:1461\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/feishu.py"},"region":{"startLine":1461}}}],"partialFingerprints":{"codehealthFindingId/v1":"9e116941df00afa72e161762c65847258f6959fc2ef035fb32a3783fda33128e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): agent/src/entities/ingest.py:1083-1093 | agent/src/entities/ingest.py:1212-1224 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 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 \u0060agent/src/entities/ingest.py:1083\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/entities/ingest.py"},"region":{"startLine":1083}}}],"partialFingerprints":{"codehealthFindingId/v1":"530ef60ef64ebdc034fdf8a2daaee55e79330db5c2a306573977d71862f487ed"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): agent/src/trading/connectors/binance/sdk.py:578-588 | agent/src/trading/connectors/upbit/sdk.py:420-430 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/binance/sdk.py"},"region":{"startLine":578}}}],"partialFingerprints":{"codehealthFindingId/v1":"85da51c5fbc0a2c05f2b9785b59c4e9e4bedff7cd00ba1022c55331d163e833d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): agent/src/trading/service.py:233-243 | agent/src/trading/service.py:281-291 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/service.py"},"region":{"startLine":233}}}],"partialFingerprints":{"codehealthFindingId/v1":"8506ddb489b956382927669dab9bce22c0f87a8b47a98d1915597e0887ad9e8c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10\u201311 lines \u00D7 2): agent/src/ui_services.py:165-175 | agent/src/ui_services.py:178-187 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/ui_services.py"},"region":{"startLine":165}}}],"partialFingerprints":{"codehealthFindingId/v1":"4cd943fe0e082a3a896bb48952e2af47b787f57ade16cf8be0748d4542a2661f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 7): agent/backtest/loaders/akshare_loader.py:159-168 | agent/backtest/loaders/alphavantage_loader.py:152-163 | agent/backtest/loaders/eastmoney_loader.py:110-121 | agent/backtest/loaders/finnhub_loader.py:217-228 | agent/backtest/loaders/mootdx_loader.py:147-156 | agent/backtest/loaders/tiingo_loader.py:328-339 | agent/backtest/loaders/yahoo_loader.py:253-264 \u2014 before extracting anything, compare \u0060agent/backtest/loaders/akshare_loader.py\u0060 and \u0060agent/backtest/loaders/eastmoney_loader.py\u0060 as WHOLE FILES: this scan already matched 6 separate duplicated blocks between them, totalling at least 130 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together \u2014 extracting one helper per block leaves the fork in place."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/akshare_loader.py"},"region":{"startLine":159}}}],"partialFingerprints":{"codehealthFindingId/v1":"65bf7f7f7ccabc86d0fc59ba5f9bb1fee48e6c1e3981c00ae75bef803f827712"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 5): agent/backtest/loaders/fmp_loader.py:134-143 | agent/backtest/loaders/pykrx_loader.py:130-139 | agent/backtest/loaders/sina_loader.py:167-176 | agent/backtest/loaders/stooq_loader.py:217-226 | agent/backtest/loaders/tencent_loader.py:108-117 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from all 5 call sites, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/fmp_loader.py"},"region":{"startLine":134}}}],"partialFingerprints":{"codehealthFindingId/v1":"f73edde0943ab1eac1a77ae406e61919ce1a66fe5214b1e43c5226ff1946f3ab"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9\u201310 lines \u00D7 4): agent/src/trading/connectors/longbridge/sdk.py:536-545 | agent/src/trading/connectors/longbridge/sdk.py:553-561 | agent/src/trading/connectors/tiger/sdk.py:383-392 | agent/src/trading/connectors/tiger/sdk.py:399-407 \u2014 there are 4 copies across 2 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 4 sites; resolving a subset leaves the remainder to drift apart. 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/longbridge/sdk.py"},"region":{"startLine":536}}}],"partialFingerprints":{"codehealthFindingId/v1":"fe0165ba816f0ad3fc5ed04d3150ce5b9794cc85e1af094754285ec400945163"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 3): agent/src/factors/zoo/alpha101/alpha_046.py:88-97 | agent/src/factors/zoo/alpha101/alpha_049.py:88-97 | agent/src/factors/zoo/alpha101/alpha_051.py:88-97 \u2014 before extracting anything, compare \u0060agent/src/factors/zoo/alpha101/alpha_049.py\u0060 and \u0060agent/src/factors/zoo/alpha101/alpha_051.py\u0060 as WHOLE FILES: this scan already matched 3 separate duplicated blocks between them, totalling at least 40 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together \u2014 extracting one helper per block leaves the fork in place."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/alpha101/alpha_046.py"},"region":{"startLine":88}}}],"partialFingerprints":{"codehealthFindingId/v1":"ee63a28b0b632b0b6e0cfa85d6981436a35f7355578199113e14d638e4d54585"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): agent/backtest/loaders/futu.py:189-198 | agent/backtest/loaders/longbridge.py:292-301 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/futu.py"},"region":{"startLine":189}}}],"partialFingerprints":{"codehealthFindingId/v1":"41d0f7d626fde1b961db08ec986f99f966ea8a82b33c23c1678850ced8d756c1"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9\u201310 lines \u00D7 2): agent/cli/_legacy.py:5128-5136 | agent/cli/_legacy.py:5199-5208 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":5128}}}],"partialFingerprints":{"codehealthFindingId/v1":"1b209f33278945cd2492ef79fa72f13ce9c5a4699da1e6ef801cb93a18e65ebe"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): agent/src/agent/instrument_identity.py:709-718 | agent/src/agent/instrument_identity.py:728-737 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/agent/instrument_identity.py"},"region":{"startLine":709}}}],"partialFingerprints":{"codehealthFindingId/v1":"b1303c7e65362763038942c9511be9b191f805ea17fd0c5af2f6cff545358f26"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): agent/src/api/system_routes.py:324-334 | agent/src/api/system_routes.py:370-380 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/api/system_routes.py"},"region":{"startLine":324}}}],"partialFingerprints":{"codehealthFindingId/v1":"465a7608270d50c6e765919c571d4c33dc9168e0a613afc12f6b841710e8268c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): agent/src/channelsui/cli_apps_api.py:9-19 | agent/src/channelsui/mcp_presets_api.py:9-19 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channelsui/cli_apps_api.py"},"region":{"startLine":9}}}],"partialFingerprints":{"codehealthFindingId/v1":"e94a5e3a3449ee52a68c58abebf85c43470099700b678b6a780b393fa2109a44"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): agent/src/live/order_guard.py:952-961 | agent/src/live/sdk_order_gate.py:1107-1116 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/live/order_guard.py"},"region":{"startLine":952}}}],"partialFingerprints":{"codehealthFindingId/v1":"27c7048be121f1e47e0e6047d3ed91b82b5f125e85fe7ff6e7fb24aa520433ce"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): agent/src/live/runtime/jobstore.py:175-184 | agent/src/scheduled_research/store.py:242-251 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/live/runtime/jobstore.py"},"region":{"startLine":175}}}],"partialFingerprints":{"codehealthFindingId/v1":"f3a18eade0d94d5c210c817703e0f62f3ecc242114253c3870d455c993c36908"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9\u201310 lines \u00D7 2): agent/src/quantlib/performance.py:327-336 | agent/src/quantlib/performance.py:862-870 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 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 \u0060agent/src/quantlib/performance.py:327\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/performance.py"},"region":{"startLine":327}}}],"partialFingerprints":{"codehealthFindingId/v1":"02016cc7fc289005249b3ef0fee16b3816b9c484f452945125fa6502034673d1"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): agent/src/skills/elliott-wave/example_signal_engine.py:217-226 | agent/src/skills/elliott-wave/example_signal_engine.py:340-349 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/skills/elliott-wave/example_signal_engine.py"},"region":{"startLine":217}}}],"partialFingerprints":{"codehealthFindingId/v1":"b4ecfacef97252d424e7c08073c8f14bab7d267465eb109eb2f39eae8a11643c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): agent/src/skills/elliott-wave/example_signal_engine.py:213-222 | agent/src/skills/elliott-wave/example_signal_engine.py:249-258 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/skills/elliott-wave/example_signal_engine.py"},"region":{"startLine":213}}}],"partialFingerprints":{"codehealthFindingId/v1":"3d82c65678d9e535d882307b14522fe84dc14908a7d6290c73f466543cf77fb3"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): agent/src/skills/elliott-wave/example_signal_engine.py:253-262 | agent/src/skills/elliott-wave/example_signal_engine.py:308-317 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/skills/elliott-wave/example_signal_engine.py"},"region":{"startLine":253}}}],"partialFingerprints":{"codehealthFindingId/v1":"1e6f39371747d7a01e1d06c93406d7aab628050883fb6027b92ff05ac127ca35"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): agent/src/skills/fundamental-filter/example_signal_engine.py:117-126 | agent/src/skills/multi-factor/example_signal_engine.py:159-168 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/skills/fundamental-filter/example_signal_engine.py"},"region":{"startLine":117}}}],"partialFingerprints":{"codehealthFindingId/v1":"9c12ed3860c807cd5101349c3fe518b905f6fb5cb358e9c1cabe5196c62e896a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): agent/src/trading/connectors/etoro/copy_trading.py:53-62 | agent/src/trading/connectors/etoro/copy_trading.py:85-94 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/etoro/copy_trading.py"},"region":{"startLine":53}}}],"partialFingerprints":{"codehealthFindingId/v1":"cb04f26f81b57cfd72614b592615fa4218b700ed517c3ee990c450d1c9ed25be"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): agent/src/trading/connectors/toss/sdk.py:545-554 | agent/src/trading/connectors/trading212/sdk.py:442-451 \u2014 \u0060agent/src/trading/connectors/toss/sdk.py\u0060 and \u0060agent/src/trading/connectors/trading212/sdk.py\u0060 are one unit implemented once per sibling directory, so they are most likely parallel implementations of one contract rather than a copy of each other \u2014 this scan matched 6 separate duplicated blocks between them, totalling at least 61 lines. If both are selected at run time, neither can be retired in favour of the other, and the lines that DIFFER between them are the reason both exist. The move that pays here is to hoist the identical part into a shared location the whole family can reach and give what differs a parameter or a seam, so a change lands once instead of once per sibling; extracting one helper per block leaves every sibling to drift on its own. 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/toss/sdk.py"},"region":{"startLine":545}}}],"partialFingerprints":{"codehealthFindingId/v1":"e2f417953e5d7c405c5e488aa9b16adb5ae5523fbc19c763351231f45a4c9a30"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8\u20139 lines \u00D7 4): agent/cli/commands/goal.py:155-163 | agent/cli/commands/goal.py:225-232 | agent/cli/commands/goal.py:266-274 | agent/cli/commands/goal.py:298-306 \u2014 all 4 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/commands/goal.py"},"region":{"startLine":155}}}],"partialFingerprints":{"codehealthFindingId/v1":"d541394be80c0c2b6a66a1dc9233ca7803d9cb5b961ae27d2f4e50247e8b9bc5"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 3): agent/src/goal/store.py:117-125 | agent/src/research_artifacts/store.py:90-98 | agent/src/strategy_store/sqlite_store.py:145-153 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 3 call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made 3 times. Note first that the copies are not typed on the same thing: the declarations holding them bind \u0060db_path\u0060 to \u0060Path | None = None\u0060 in one and \u0060Path | str | None = None\u0060 in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH \u2014 their common supertype where they have one, or a new abstraction over them where they do not \u2014 and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/goal/store.py"},"region":{"startLine":117}}}],"partialFingerprints":{"codehealthFindingId/v1":"97c4c6f5f2b6f61d758bddb169e15a1e69df8798c55e486a2456f86b7f800a70"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): agent/backtest/loaders/sina_loader.py:106-114 | agent/backtest/loaders/tencent_loader.py:230-238 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/sina_loader.py"},"region":{"startLine":106}}}],"partialFingerprints":{"codehealthFindingId/v1":"a4134b882a552d92e0848026b26fcc9f7fe8d44c5a32eea58d33e6db93191559"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): agent/mcp_server.py:709-717 | agent/mcp_server.py:818-826 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/mcp_server.py"},"region":{"startLine":709}}}],"partialFingerprints":{"codehealthFindingId/v1":"4fec9b7063409f7268448fe6acb3ae7e36069ca968d22f55dbbfa1f3f5937a3e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): agent/src/api/sessions_routes.py:595-605 | agent/src/api/sessions_routes.py:697-707 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 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 \u0060agent/src/api/sessions_routes.py:595\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/api/sessions_routes.py"},"region":{"startLine":595}}}],"partialFingerprints":{"codehealthFindingId/v1":"1a2a466af11efbf9e25578e503a4a51fc555bd01dc305631d955e5b91782c757"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): agent/src/api/system_routes.py:474-482 | agent/src/api/system_routes.py:489-497 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/api/system_routes.py"},"region":{"startLine":474}}}],"partialFingerprints":{"codehealthFindingId/v1":"94d47c94e187115f1415d6cec7896ae37487383f7390a413a1907702d2382b14"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): agent/src/channels/manager.py:147-155 | agent/src/channels/manager.py:334-342 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/manager.py"},"region":{"startLine":147}}}],"partialFingerprints":{"codehealthFindingId/v1":"f5d21cc4664a2a874203c3b12975204aaba1fa22e04bbd978b17a06444079fa5"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): agent/src/channels/signal.py:157-165 | agent/src/channels/telegram.py:244-252 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/signal.py"},"region":{"startLine":157}}}],"partialFingerprints":{"codehealthFindingId/v1":"807ea932d7e267432fb6f7ce80da58e2e51ef9c91bb037bd33fc406509a88abe"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (16 lines \u00D7 2): agent/src/factors/zoo/gtja191/alpha_003.py:49-64 | agent/src/factors/zoo/gtja191/alpha_059.py:49-64 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/gtja191/alpha_003.py"},"region":{"startLine":49}}}],"partialFingerprints":{"codehealthFindingId/v1":"6664e2d1d967683027b4277f68b5ea849473316b76c69f1ac64980a08b8e408d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7\u20139 lines \u00D7 2): agent/src/quantlib/crossvalidation.py:268-274 | agent/src/quantlib/crossvalidation.py:365-373 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 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 \u0060agent/src/quantlib/crossvalidation.py:365\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/crossvalidation.py"},"region":{"startLine":268}}}],"partialFingerprints":{"codehealthFindingId/v1":"bbcc6e23099c3722fbad73eacff0b749d9040f103c4fdd60891480d6a29a6a81"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): agent/src/quantlib/risk.py:276-284 | agent/src/quantlib/risk.py:485-493 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/risk.py"},"region":{"startLine":276}}}],"partialFingerprints":{"codehealthFindingId/v1":"c9b0e132c0f1798e7af274568ad3f5d8b713ecf1d840794af622999102ae3725"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): agent/src/skills/tushare/scripts/fund_data_example.py:72-80 | agent/src/skills/tushare/scripts/stock_data_example.py:72-80 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/skills/tushare/scripts/fund_data_example.py"},"region":{"startLine":72}}}],"partialFingerprints":{"codehealthFindingId/v1":"89e6075e8c54e5f8c3369041c9f1e38a3cf8eaa558cba9c8dacabd38ed000800"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): agent/src/strategy_discovery/models.py:236-244 | agent/src/strategy_discovery/models.py:276-284 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/strategy_discovery/models.py"},"region":{"startLine":236}}}],"partialFingerprints":{"codehealthFindingId/v1":"4718b3dc0b2481812032d33c22411ed5950ecfb869eeabb9bbc5e115cfa476bc"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): agent/src/tools/financial_rigor_tool.py:221-229 | agent/src/tools/financial_rigor_tool.py:233-241 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/financial_rigor_tool.py"},"region":{"startLine":221}}}],"partialFingerprints":{"codehealthFindingId/v1":"30a5834a94ea0327596978f1132063f3dfd565eac8ecd1bf62d6a06b980b05ea"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): agent/src/tools/goal_tool.py:289-297 | agent/src/tools/goal_tool.py:360-368 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/goal_tool.py"},"region":{"startLine":289}}}],"partialFingerprints":{"codehealthFindingId/v1":"d5160322e8e5e91bda0f3754579be3b0ac02288bfbae6e366d465f2bc1372c87"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): agent/src/trading/connectors/ibkr/local.py:428-436 | agent/src/trading/connectors/ibkr/local.py:489-497 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/ibkr/local.py"},"region":{"startLine":428}}}],"partialFingerprints":{"codehealthFindingId/v1":"a2b5d3cb62aa6d613b9394dc515f6ffb2ed78a880dc96973ea55986c6a931285"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): agent/src/trading/connectors/shoonya/sdk.py:455-463 | agent/src/trading/connectors/zerodha/sdk.py:585-593 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/shoonya/sdk.py"},"region":{"startLine":455}}}],"partialFingerprints":{"codehealthFindingId/v1":"60e924733c668542cfe140e7f7123c50fcdd1508a9f1e22960489502eae0ce00"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 3): agent/src/trading/connectors/alpaca/sdk.py:501-508 | agent/src/trading/connectors/kis/sdk.py:503-510 | agent/src/trading/connectors/upbit/sdk.py:416-423 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 3 call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made 3 times. 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/alpaca/sdk.py"},"region":{"startLine":501}}}],"partialFingerprints":{"codehealthFindingId/v1":"4b8af2f62cd4b006c9a6fc0498942b0c7e8df1af146fe77df7ef095a31de90a8"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): agent/backtest/metrics.py:668-675 | agent/backtest/metrics.py:731-738 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/metrics.py"},"region":{"startLine":668}}}],"partialFingerprints":{"codehealthFindingId/v1":"74fad904b70457c00436203192aac50b5afd9d5516211de0473ea6ecb50749a0"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): agent/mcp_server.py:509-516 | agent/src/tools/goal_tool.py:48-55 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 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 \u0060agent/mcp_server.py:509\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/mcp_server.py"},"region":{"startLine":509}}}],"partialFingerprints":{"codehealthFindingId/v1":"46ecd5f232e590b54de85f1a1779d133190fc29b353e167d96b98dea50e1f037"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): agent/src/api/connection_routes.py:114-121 | agent/src/api/connection_routes.py:134-141 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/api/connection_routes.py"},"region":{"startLine":114}}}],"partialFingerprints":{"codehealthFindingId/v1":"e7280c1f3b7c73377f97a51d7cbbe6bd048b2ebcc3718dee099f2932f450861a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): agent/src/api/sessions_routes.py:731-738 | agent/src/api/sessions_routes.py:747-758 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/api/sessions_routes.py"},"region":{"startLine":731}}}],"partialFingerprints":{"codehealthFindingId/v1":"1339f644baf433b289796e03c609929f007bbadec5a63c3fb0aa717ad8ee7085"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): agent/src/factors/base.py:234-245 | agent/src/factors/base.py:253-260 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/base.py"},"region":{"startLine":234}}}],"partialFingerprints":{"codehealthFindingId/v1":"59c3633d884c22a0d090d403f98388ad78ac6746aad855d69e21251e59714d03"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): agent/src/live/mandate/commit.py:178-186 | agent/src/live/runtime/reconcile.py:600-608 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/live/mandate/commit.py"},"region":{"startLine":178}}}],"partialFingerprints":{"codehealthFindingId/v1":"612166636ab3476727401efcdf9c7c76ab10622152d7c1a3207f189d664aead2"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): agent/src/quantlib/valuation/dcf.py:1028-1035 | agent/src/quantlib/valuation/dcf.py:1133-1140 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/valuation/dcf.py"},"region":{"startLine":1028}}}],"partialFingerprints":{"codehealthFindingId/v1":"1c85ac26c762c7d12f4f1f0abf8710d35f643ed4a2bc69b68d238e6bb738b8f1"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): agent/src/skills/elliott-wave/example_signal_engine.py:306-313 | agent/src/skills/elliott-wave/example_signal_engine.py:338-345 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/skills/elliott-wave/example_signal_engine.py"},"region":{"startLine":306}}}],"partialFingerprints":{"codehealthFindingId/v1":"a270ac4c21658b0e2b871d78c7813f29346ab822d1d018520a51678a97eb7d69"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): agent/src/tools/financial_research_artifact_tool.py:219-226 | agent/src/tools/research_artifact_tool.py:65-72 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060agent/src/tools/financial_research_artifact_tool.py:219\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/financial_research_artifact_tool.py"},"region":{"startLine":219}}}],"partialFingerprints":{"codehealthFindingId/v1":"683cd42d9b16dda6813aa0b08c41b3c358897f57043bcbfee8fc5adc3fb184ba"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 4): agent/src/trading/connectors/alpaca/sdk.py:504-510 | agent/src/trading/connectors/binance/sdk.py:577-583 | agent/src/trading/connectors/kis/sdk.py:506-512 | agent/src/trading/connectors/upbit/sdk.py:419-425 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 4 call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made 4 times. 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/alpaca/sdk.py"},"region":{"startLine":504}}}],"partialFingerprints":{"codehealthFindingId/v1":"0e497a6000e0a39c5f9352cafe33e12e22df23b39385e9c6f6e138037e818b99"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 3): agent/src/factors/zoo/gtja191/alpha_047.py:49-55 | agent/src/factors/zoo/gtja191/alpha_072.py:49-55 | agent/src/factors/zoo/gtja191/alpha_082.py:49-55 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from all 3 call sites, so a change lands once. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/gtja191/alpha_047.py"},"region":{"startLine":49}}}],"partialFingerprints":{"codehealthFindingId/v1":"4f68d03a40a33aeb054e566d0a6adeada233f799d52153d14afb766e8467b574"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 3): agent/src/tools/get_fundamentals_tool.py:139-145 | agent/src/tools/get_fundamentals_tool.py:146-152 | agent/src/tools/market_data_tool.py:186-192 \u2014 there are 3 copies across 2 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 3 sites; resolving a subset leaves the remainder to drift apart. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/get_fundamentals_tool.py"},"region":{"startLine":139}}}],"partialFingerprints":{"codehealthFindingId/v1":"0e0925580048560162d4259d56c239ad2bb2b0b0291e4fe0d6fabba8ceeafac0"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): agent/backtest/engines/composite.py:363-369 | agent/backtest/engines/crypto.py:644-650 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/engines/composite.py"},"region":{"startLine":363}}}],"partialFingerprints":{"codehealthFindingId/v1":"0112ab413104cdf511293eeb0ece6bf1e078e75bfc1a25cbebe980f6ef3da6cb"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): agent/backtest/loaders/nobitex.py:278-285 | agent/backtest/loaders/wallex.py:262-269 \u2014 before extracting anything, compare \u0060agent/backtest/loaders/nobitex.py\u0060 and \u0060agent/backtest/loaders/wallex.py\u0060 as WHOLE FILES: this scan already matched 3 separate duplicated blocks between them, totalling at least 49 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together \u2014 extracting one helper per block leaves the fork in place. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/nobitex.py"},"region":{"startLine":278}}}],"partialFingerprints":{"codehealthFindingId/v1":"7d82b3a0859d0a7258bb393e662d4409f13962886f9cf2f1e955b7b1763d0ad3"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): agent/cli/_legacy.py:4673-4679 | agent/cli/_legacy.py:5193-5199 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 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 \u0060agent/cli/_legacy.py:4673\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":4673}}}],"partialFingerprints":{"codehealthFindingId/v1":"0a6fb8887c78a3059c50a91e633ba3e8e67d0ad834169f8ad0808881921903e8"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): agent/scripts/w4a_patch_blog.py:136-142 | agent/scripts/w4a_patch_blog.py:158-164 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, \u0060agent/scripts/w4a_patch_blog.py:164\u0060 calls \u0060get\u0060 and \u0060agent/scripts/w4a_patch_blog.py:142\u0060 does not \u2014 after which the two agree again for 5 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/scripts/w4a_patch_blog.py"},"region":{"startLine":136}}}],"partialFingerprints":{"codehealthFindingId/v1":"46f5ac47da2406f4dad82f2c37f7a282c0637cb288f80a5f05eee3b79a1c5b58"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): agent/src/channels/wecom.py:277-283 | agent/src/channels/wecom.py:326-332 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/wecom.py"},"region":{"startLine":277}}}],"partialFingerprints":{"codehealthFindingId/v1":"93540a9ae84d8606686e1fc057bc48ab7f237805471820ceb005e10ff456746f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (2\u20137 lines \u00D7 5): agent/src/factors/zoo/alpha101/alpha_071.py:67-73 | agent/src/factors/zoo/alpha101/alpha_073.py:67-73 | agent/src/factors/zoo/alpha101/alpha_076.py:102-103 | agent/src/factors/zoo/alpha101/alpha_087.py:102-103 | agent/src/factors/zoo/alpha101/alpha_096.py:65-66 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from all 5 call sites, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/alpha101/alpha_071.py"},"region":{"startLine":67}}}],"partialFingerprints":{"codehealthFindingId/v1":"258a50d14fca614d35c4ffbd162add53f2c754e6b5f5dd1ff2949ab5b3512bfd"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 10): agent/src/factors/zoo/qlib158/sumd10.py:27-36 | agent/src/factors/zoo/qlib158/sumd20.py:27-36 | agent/src/factors/zoo/qlib158/sumd30.py:27-36 | agent/src/factors/zoo/qlib158/sumd5.py:27-36 | agent/src/factors/zoo/qlib158/sumd60.py:27-36 | agent/src/factors/zoo/qlib158/vsumd10.py:27-36 | agent/src/factors/zoo/qlib158/vsumd20.py:27-36 | agent/src/factors/zoo/qlib158/vsumd30.py:27-36 | agent/src/factors/zoo/qlib158/vsumd5.py:27-36 | agent/src/factors/zoo/qlib158/vsumd60.py:27-36 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from all 10 call sites, so a change lands once. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/qlib158/sumd10.py"},"region":{"startLine":27}}}],"partialFingerprints":{"codehealthFindingId/v1":"5b08018761ae8f9cff3af029c69d56bb09674ce926384b69fa55888e424310a8"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 10): agent/src/factors/zoo/qlib158/sumn10.py:27-34 | agent/src/factors/zoo/qlib158/sumn20.py:27-34 | agent/src/factors/zoo/qlib158/sumn30.py:27-34 | agent/src/factors/zoo/qlib158/sumn5.py:27-34 | agent/src/factors/zoo/qlib158/sumn60.py:27-34 | agent/src/factors/zoo/qlib158/vsumn10.py:27-34 | agent/src/factors/zoo/qlib158/vsumn20.py:27-34 | agent/src/factors/zoo/qlib158/vsumn30.py:27-34 | agent/src/factors/zoo/qlib158/vsumn5.py:27-34 | agent/src/factors/zoo/qlib158/vsumn60.py:27-34 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from all 10 call sites, so a change lands once. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/qlib158/sumn10.py"},"region":{"startLine":27}}}],"partialFingerprints":{"codehealthFindingId/v1":"94bc8fd238caa6a904675c503ee6d39b89624cec6e32cabe191c6ff605ab826a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 10): agent/src/factors/zoo/qlib158/sump10.py:27-34 | agent/src/factors/zoo/qlib158/sump20.py:27-34 | agent/src/factors/zoo/qlib158/sump30.py:27-34 | agent/src/factors/zoo/qlib158/sump5.py:27-34 | agent/src/factors/zoo/qlib158/sump60.py:27-34 | agent/src/factors/zoo/qlib158/vsump10.py:27-34 | agent/src/factors/zoo/qlib158/vsump20.py:27-34 | agent/src/factors/zoo/qlib158/vsump30.py:27-34 | agent/src/factors/zoo/qlib158/vsump5.py:27-34 | agent/src/factors/zoo/qlib158/vsump60.py:27-34 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from all 10 call sites, so a change lands once. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/qlib158/sump10.py"},"region":{"startLine":27}}}],"partialFingerprints":{"codehealthFindingId/v1":"a1e12e65b63e01abc9e3290cd3fafe81dadf848fcb47175f3ca9099df13dae99"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 4): agent/src/channels/config_meta.py:77-82 | agent/src/channels/config_meta.py:135-140 | agent/src/channels/config_meta.py:283-288 | agent/src/channels/config_meta.py:344-349 \u2014 all 4 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/config_meta.py"},"region":{"startLine":77}}}],"partialFingerprints":{"codehealthFindingId/v1":"5926e8665f8a1dc3b354e764e50e504904c7c43536f2ca9bca398cc0dcc915a8"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 3): agent/cli/_legacy.py:4672-4677 | agent/cli/_legacy.py:4723-4728 | agent/cli/_legacy.py:5192-5197 \u2014 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 \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":4672}}}],"partialFingerprints":{"codehealthFindingId/v1":"488f2509492855bd0a857ad9ea10a55039a2759f05ee931ed9851fcdc6a51224"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 3): agent/cli/ui/transcript.py:151-156 | agent/src/channels/feishu.py:1151-1156 | agent/src/channels/slack.py:762-767 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 3 call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made 3 times. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/ui/transcript.py"},"region":{"startLine":151}}}],"partialFingerprints":{"codehealthFindingId/v1":"f7c6c9c8ec2a4d85c828e4c3d767e1826fb9890f457089b18210ffe7ec336159"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 3): agent/mcp_server.py:3065-3070 | agent/mcp_server.py:3092-3097 | agent/mcp_server.py:3199-3204 \u2014 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 \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/mcp_server.py"},"region":{"startLine":3065}}}],"partialFingerprints":{"codehealthFindingId/v1":"751259b8211ebf8aa94e8fc11929aa9dd91670d29042b37c7990043d2e459e64"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 3): agent/src/factors/zoo/gtja191/alpha_049.py:49-59 | agent/src/factors/zoo/gtja191/alpha_050.py:49-59 | agent/src/factors/zoo/gtja191/alpha_051.py:49-59 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from all 3 call sites, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/gtja191/alpha_049.py"},"region":{"startLine":49}}}],"partialFingerprints":{"codehealthFindingId/v1":"a3bf9d1c4e6e5b1f426710f9de11fdd3fd0830b297477476e3272916834b1d62"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): agent/backtest/loaders/fmp_loader.py:312-317 | agent/backtest/loaders/tickerall_loader.py:442-447 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/fmp_loader.py"},"region":{"startLine":312}}}],"partialFingerprints":{"codehealthFindingId/v1":"4f3247abc3e49bf45251309789623c6d72ca222f86089bf482c8a2e19ea2d973"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): agent/backtest/loaders/tushare.py:248-254 | agent/backtest/loaders/tushare.py:380-386 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/tushare.py"},"region":{"startLine":248}}}],"partialFingerprints":{"codehealthFindingId/v1":"fe90f958a299efba2dd1f16bea3292365fecb54c1fb291999f1f33184c68965f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): agent/cli/_legacy.py:4006-4011 | agent/cli/_legacy.py:4227-4232 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":4006}}}],"partialFingerprints":{"codehealthFindingId/v1":"53053758e065801b584bc15ac8a288d1df26e66ecfedd3e0335f8e2f13eb9645"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): agent/cli/_legacy.py:4932-4937 | agent/cli/_legacy.py:4958-4963 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":4932}}}],"partialFingerprints":{"codehealthFindingId/v1":"175fe7af75bf7ebddbf58456725e89aa7e93bedf5ddb8458c6bfa2753ab0d65c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): agent/src/factors/base.py:207-212 | agent/src/factors/base.py:401-406 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/base.py"},"region":{"startLine":207}}}],"partialFingerprints":{"codehealthFindingId/v1":"64bb3ac35f60b902df009f07a488db7fb9dc522f25025d602d7f0849cb646ca1"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): agent/src/factors/zoo/gtja191/alpha_009.py:49-55 | agent/src/factors/zoo/gtja191/alpha_068.py:49-55 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/gtja191/alpha_009.py"},"region":{"startLine":49}}}],"partialFingerprints":{"codehealthFindingId/v1":"573d59f8694689ec4192e341b06c10f25edd74c83073783a939e31a2b0882bec"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): agent/src/factors/zoo/gtja191/alpha_011.py:49-54 | agent/src/factors/zoo/gtja191/alpha_060.py:49-54 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/gtja191/alpha_011.py"},"region":{"startLine":49}}}],"partialFingerprints":{"codehealthFindingId/v1":"e571f850e0cca6c2ab9355c8268fcf47e31d0067f6efdca40ebbb10b770d36ee"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): agent/src/factors/zoo/gtja191/alpha_049.py:56-63 | agent/src/factors/zoo/gtja191/alpha_050.py:56-63 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060agent/src/factors/zoo/gtja191/alpha_049.py:56\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/gtja191/alpha_049.py"},"region":{"startLine":56}}}],"partialFingerprints":{"codehealthFindingId/v1":"cddaafc3321dc4e65da6cf61ea960aa8f38ab84efd58d5f6e849d0663362f03e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): agent/src/providers/settings.py:139-144 | agent/src/trading/tap_forward.py:65-70 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/providers/settings.py"},"region":{"startLine":139}}}],"partialFingerprints":{"codehealthFindingId/v1":"28631bc35d0d2ee8f58b72b3ff45fdf1ec3b9d819ad38b4b69afbccd9eb7b892"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): agent/src/quantlib/attribution.py:332-337 | agent/src/quantlib/attribution.py:443-448 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/attribution.py"},"region":{"startLine":332}}}],"partialFingerprints":{"codehealthFindingId/v1":"19a6dd857e760baf0f071fc10cd766dbc8a31f8387ac887affc0a22f8a2dda3b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): agent/src/quantlib/combination.py:83-89 | agent/src/quantlib/neutralization.py:49-55 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/combination.py"},"region":{"startLine":83}}}],"partialFingerprints":{"codehealthFindingId/v1":"af1e9e7c6a00fb0a8731bfd866b1707ad8fd8e7667fc556afcc6b65f935b43dd"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): agent/src/tools/goal_tool.py:306-312 | agent/src/tools/goal_tool.py:375-381 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 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 \u0060agent/src/tools/goal_tool.py:306\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 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. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, \u0060agent/src/tools/goal_tool.py:304\u0060 calls \u0060_coerce_audit_rows\u0060, \u0060get\u0060, \u0060str\u0060 and \u0060agent/src/tools/goal_tool.py:374\u0060 does not \u2014 after which the two agree again for 3 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/goal_tool.py"},"region":{"startLine":306}}}],"partialFingerprints":{"codehealthFindingId/v1":"639ea096428284e946e4460f65edb15cc2050df1f0017090a782f0c6169bf93e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): agent/src/tools/trade_journal_parsers.py:359-364 | agent/src/tools/trade_journal_parsers.py:440-445 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/trade_journal_parsers.py"},"region":{"startLine":359}}}],"partialFingerprints":{"codehealthFindingId/v1":"de5d00d7b877efbc90cde6e043dec10b89e857506f05400a2524c8330b11e1a6"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 6): agent/src/skills/candlestick/example_signal_engine.py:557-563 | agent/src/skills/elliott-wave/example_signal_engine.py:438-444 | agent/src/skills/harmonic/example_signal_engine.py:455-461 | agent/src/skills/ichimoku/example_signal_engine.py:159-165 | agent/src/skills/smc/example_signal_engine.py:47-53 | agent/src/skills/technical-basic/example_signal_engine.py:271-277 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 6 call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made 6 times. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/skills/candlestick/example_signal_engine.py"},"region":{"startLine":557}}}],"partialFingerprints":{"codehealthFindingId/v1":"b289fd45eee72b3a6fbf395095c338810a7ce0c62164c6b5d3521bed72b6d590"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 3): agent/src/api/sessions_routes.py:551-555 | agent/src/api/sessions_routes.py:598-603 | agent/src/api/sessions_routes.py:700-705 \u2014 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 \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, \u0060agent/src/api/sessions_routes.py:597\u0060 calls \u0060HTTPException\u0060, \u0060str\u0060 and \u0060agent/src/api/sessions_routes.py:550\u0060 does not \u2014 after which the two agree again for 3 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/api/sessions_routes.py"},"region":{"startLine":551}}}],"partialFingerprints":{"codehealthFindingId/v1":"6e504d413f12e9f0311a2608298ba44596519f0356917f29e71541b9d6ef6e5e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 3): agent/src/factors/zoo/gtja191/alpha_043.py:49-55 | agent/src/factors/zoo/gtja191/alpha_084.py:49-55 | agent/src/factors/zoo/gtja191/alpha_094.py:49-55 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from all 3 call sites, so a change lands once. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/gtja191/alpha_043.py"},"region":{"startLine":49}}}],"partialFingerprints":{"codehealthFindingId/v1":"95757d31a6eac66d6fe9f0254c44cdd945af654c1b575f4ef3850e69e8f41439"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): agent/backtest/run_card.py:376-382 | agent/src/tools/backtest_summary.py:200-206 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/run_card.py"},"region":{"startLine":376}}}],"partialFingerprints":{"codehealthFindingId/v1":"5c09833c71a458f6e2bd48f8484f954c984a07c53bbc6989be5e842cdf720130"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): agent/src/factors/zoo/gtja191/alpha_055.py:58-62 | agent/src/factors/zoo/gtja191/alpha_137.py:70-75 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, \u0060agent/src/factors/zoo/gtja191/alpha_055.py:57\u0060 calls \u0060abs\u0060 and \u0060agent/src/factors/zoo/gtja191/alpha_137.py:69\u0060 does not \u2014 after which the two agree again for 3 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/gtja191/alpha_055.py"},"region":{"startLine":58}}}],"partialFingerprints":{"codehealthFindingId/v1":"b4c437b3a02dd6620c737eb76a923625f621f443ba0c5aef68ea855e19d14962"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): agent/src/factors/zoo/gtja191/alpha_063.py:49-55 | agent/src/factors/zoo/gtja191/alpha_067.py:49-55 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/gtja191/alpha_063.py"},"region":{"startLine":49}}}],"partialFingerprints":{"codehealthFindingId/v1":"111214e740ed7f275c2c8b2f7f802ab5778117c17312a1ad990ae3fee44454b4"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): agent/src/quantlib/crossvalidation.py:596-601 | agent/src/quantlib/crossvalidation.py:615-620 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 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 \u0060agent/src/quantlib/crossvalidation.py:596\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/crossvalidation.py"},"region":{"startLine":596}}}],"partialFingerprints":{"codehealthFindingId/v1":"824c9355d787e8566e55587e59b4a9ef97cf9c086df3ab801f940779ee93c8fa"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): agent/src/skills/event-driven/example_signal_engine.py:50-54 | agent/src/skills/fundamental-filter/example_signal_engine.py:86-91 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/skills/event-driven/example_signal_engine.py"},"region":{"startLine":50}}}],"partialFingerprints":{"codehealthFindingId/v1":"62ffd7e5d0a0230a61399488a8f45f794f438a830153210a670f3b9fb512ab3f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): agent/src/tools/trading_connector_tool.py:406-410 | agent/src/tools/trading_connector_tool.py:448-452 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/trading_connector_tool.py"},"region":{"startLine":406}}}],"partialFingerprints":{"codehealthFindingId/v1":"ca22c447b7d19ec36b29ce551af5c96b87a8c8aab6ae2cbbf13d23c99b052504"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): agent/src/trading/connectors/dhan/sdk.py:103-107 | agent/src/trading/connectors/zerodha/sdk.py:100-104 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 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 \u0060agent/src/trading/connectors/dhan/sdk.py:103\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/dhan/sdk.py"},"region":{"startLine":103}}}],"partialFingerprints":{"codehealthFindingId/v1":"ce852381a630dfd98d17f5837e70b964ac990e12898af6bd8842c979115bf50d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (4\u201313 lines \u00D7 12): agent/src/factors/zoo/academic/bab.py:53-56 | agent/src/factors/zoo/academic/carhart_mom.py:48-51 | agent/src/factors/zoo/academic/cma.py:48-51 | agent/src/factors/zoo/academic/corr_rewire.py:151-154 | agent/src/factors/zoo/academic/high52w.py:47-50 | agent/src/factors/zoo/academic/hml.py:48-66 | agent/src/factors/zoo/academic/illiq.py:47-50 | agent/src/factors/zoo/academic/mkt_rf.py:45-48 | agent/src/factors/zoo/academic/retskew.py:47-50 | agent/src/factors/zoo/academic/rmw.py:47-50 | agent/src/factors/zoo/academic/smb.py:46-49 | agent/src/factors/zoo/academic/strev.py:46-58 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from all 12 call sites, so a change lands once. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/academic/bab.py"},"region":{"startLine":53}}}],"partialFingerprints":{"codehealthFindingId/v1":"0f338b8ce78b5f7ae6746736b5cbdd2a7d0df65160252b38c48149a661c88e78"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (31 lines \u00D7 2): agent/backtest/engines/china_futures.py:202-232 | agent/backtest/engines/global_futures.py:236-267 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/engines/china_futures.py"},"region":{"startLine":202}}}],"partialFingerprints":{"codehealthFindingId/v1":"249bcc2f9f1115dcbc221c83157ac59dc9e75430631183e0fe3715799fe99f12"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (15 lines \u00D7 2): agent/backtest/loaders/industry_loader.py:94-108 | agent/backtest/loaders/valuation_loader.py:83-97 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/industry_loader.py"},"region":{"startLine":94}}}],"partialFingerprints":{"codehealthFindingId/v1":"a95a289b98f174e29558ce71d56e5128fcf3eb363d074cba8a2d7db1e9a9e629"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 3): agent/backtest/loaders/mt5_loader.py:128-134 | agent/backtest/loaders/tickerall_loader.py:137-143 | agent/src/trading/connectors/mt5/symbols.py:30-41 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 3 call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made 3 times. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/mt5_loader.py"},"region":{"startLine":128}}}],"partialFingerprints":{"codehealthFindingId/v1":"4f573ca752144292c1be7c6fb7bb840afea66122c21658e93989ba35e4ed7b3a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 3): agent/backtest/rebalance_notes.py:191-204 | agent/backtest/risk_xray.py:415-426 | agent/backtest/validation.py:541-557 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from all 3 call sites, so a change lands once. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/rebalance_notes.py"},"region":{"startLine":191}}}],"partialFingerprints":{"codehealthFindingId/v1":"670245b42fa135dc05d3dc277bb8a061d11c6a83bf6a4249af2dc73beb658f02"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): agent/backtest/risk_xray.py:39-46 | agent/src/tools/backtest_summary.py:210-222 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/risk_xray.py"},"region":{"startLine":39}}}],"partialFingerprints":{"codehealthFindingId/v1":"a326b766e0c0fb5ef1232f9cf6233d4c2e903d529a498eef7a863dac77da59a5"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): agent/cli/commands/chat.py:101-113 | agent/cli/commands/research_playbook.py:373-380 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/commands/chat.py"},"region":{"startLine":101}}}],"partialFingerprints":{"codehealthFindingId/v1":"745ce5b68e84422ced89f75ca0899406a4213247b7e9da0e72b191ad480c3fcb"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 3): agent/cli/commands/chat.py:238-244 | agent/cli/commands/session.py:89-95 | agent/cli/commands/show.py:77-83 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from all 3 call sites, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. Note first that the copies are not typed on the same thing: the declarations holding them bind \u0060command\u0060 to \u0060str = \u0022model\u0022\u0060 in one and \u0060str = \u0022history\u0022\u0060 in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH \u2014 their common supertype where they have one, or a new abstraction over them where they do not \u2014 and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/commands/chat.py"},"region":{"startLine":238}}}],"partialFingerprints":{"codehealthFindingId/v1":"be55fea1205985ff25dfca009fb7e06311c4d5a55c4dc6fd266a563ef08952d6"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 3): agent/src/api/attribution_core.py:75-80 | agent/src/api/runs_routes.py:49-61 | agent/src/tools/report_audit_tool.py:331-345 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 3 call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made 3 times. 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/api/attribution_core.py"},"region":{"startLine":75}}}],"partialFingerprints":{"codehealthFindingId/v1":"b1d4785d1809138bdde7ab6c7776d09e83726167a2bc6d10db4b91ea4d7f4d48"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): agent/src/channels/qq.py:87-91 | agent/src/channels/wecom.py:31-35 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/qq.py"},"region":{"startLine":87}}}],"partialFingerprints":{"codehealthFindingId/v1":"82188e82b5fc3ddf3719bfa0c1f32956e08474bd7725965b6c8cdd45404b8ee9"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): agent/src/factors/zoo/alpha101/alpha_003.py:55-62 | agent/src/factors/zoo/gtja191/alpha_105.py:54-65 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/alpha101/alpha_003.py"},"region":{"startLine":55}}}],"partialFingerprints":{"codehealthFindingId/v1":"a0c0f996d3e79589a3e8a4157c935eca2b2c9f33ca5a5e5336888d210ee6e4ec"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): agent/src/factors/zoo/alpha101/alpha_013.py:55-62 | agent/src/factors/zoo/alpha101/alpha_016.py:55-62 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/alpha101/alpha_013.py"},"region":{"startLine":55}}}],"partialFingerprints":{"codehealthFindingId/v1":"c63898f8df963d58fcdd62a0661564ff48e6ebcb688d2e2795df292a4de3e719"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): agent/src/factors/zoo/gtja191/alpha_134.py:54-65 | agent/src/factors/zoo/gtja191/alpha_178.py:54-65 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/gtja191/alpha_134.py"},"region":{"startLine":54}}}],"partialFingerprints":{"codehealthFindingId/v1":"df5b5c79c50735c5c22585114ef36c18df0ee9b857466e2d55c3ea459d2b2837"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): agent/src/factors/zoo/gtja191/alpha_165.py:54-66 | agent/src/factors/zoo/gtja191/alpha_183.py:54-66 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/gtja191/alpha_165.py"},"region":{"startLine":54}}}],"partialFingerprints":{"codehealthFindingId/v1":"c1627db40d701a85bee9f93329d6052e00d857f3acd1a824886a7dfaf22a8aea"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 5): agent/src/factors/zoo/qlib158/cntn10.py:27-31 | agent/src/factors/zoo/qlib158/cntn20.py:27-31 | agent/src/factors/zoo/qlib158/cntn30.py:27-31 | agent/src/factors/zoo/qlib158/cntn5.py:27-31 | agent/src/factors/zoo/qlib158/cntn60.py:27-31 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from all 5 call sites, so a change lands once. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/qlib158/cntn10.py"},"region":{"startLine":27}}}],"partialFingerprints":{"codehealthFindingId/v1":"151fc1d59da2ebb6106d4132a35d343d32071d948b80bff8680a9ad648891d70"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 5): agent/src/factors/zoo/qlib158/cntp10.py:27-31 | agent/src/factors/zoo/qlib158/cntp20.py:27-31 | agent/src/factors/zoo/qlib158/cntp30.py:27-31 | agent/src/factors/zoo/qlib158/cntp5.py:27-31 | agent/src/factors/zoo/qlib158/cntp60.py:27-31 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from all 5 call sites, so a change lands once. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/qlib158/cntp10.py"},"region":{"startLine":27}}}],"partialFingerprints":{"codehealthFindingId/v1":"7c2a9b8efe6d0826bb432764b8fa461ed8438a3b75860bb2f5957da90c4df6b6"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 5): agent/src/factors/zoo/qlib158/cord10.py:28-34 | agent/src/factors/zoo/qlib158/cord20.py:28-34 | agent/src/factors/zoo/qlib158/cord30.py:28-34 | agent/src/factors/zoo/qlib158/cord5.py:28-34 | agent/src/factors/zoo/qlib158/cord60.py:28-34 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from all 5 call sites, so a change lands once. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/qlib158/cord10.py"},"region":{"startLine":28}}}],"partialFingerprints":{"codehealthFindingId/v1":"da804820f48f77dd0a2f94480ef40310d70489b9f7e585b684728115779bad04"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 5): agent/src/factors/zoo/qlib158/corr10.py:28-32 | agent/src/factors/zoo/qlib158/corr20.py:28-32 | agent/src/factors/zoo/qlib158/corr30.py:28-32 | agent/src/factors/zoo/qlib158/corr5.py:28-32 | agent/src/factors/zoo/qlib158/corr60.py:28-32 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from all 5 call sites, so a change lands once. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/qlib158/corr10.py"},"region":{"startLine":28}}}],"partialFingerprints":{"codehealthFindingId/v1":"084b130c24722f916661f58820a61aee12746fe3dee7aea8b3b2decc154613eb"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 5): agent/src/factors/zoo/qlib158/rsv10.py:27-33 | agent/src/factors/zoo/qlib158/rsv20.py:27-33 | agent/src/factors/zoo/qlib158/rsv30.py:27-33 | agent/src/factors/zoo/qlib158/rsv5.py:27-33 | agent/src/factors/zoo/qlib158/rsv60.py:27-33 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from all 5 call sites, so a change lands once. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/qlib158/rsv10.py"},"region":{"startLine":27}}}],"partialFingerprints":{"codehealthFindingId/v1":"b8c6d190abc931d9b2fd49c2cbe0c4766e6321cf7af3f94a2ffc6c91b58ba975"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 5): agent/src/factors/zoo/qlib158/wvma10.py:27-32 | agent/src/factors/zoo/qlib158/wvma20.py:27-32 | agent/src/factors/zoo/qlib158/wvma30.py:27-32 | agent/src/factors/zoo/qlib158/wvma5.py:27-32 | agent/src/factors/zoo/qlib158/wvma60.py:27-32 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from all 5 call sites, so a change lands once. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/qlib158/wvma10.py"},"region":{"startLine":27}}}],"partialFingerprints":{"codehealthFindingId/v1":"ed0cf62d4f459d53c9b2e9fdd5e7be1e884f7bf3b01683e80b98f227ac177c44"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 3): agent/src/goal/store.py:96-103 | agent/src/strategy_store/sqlite_store.py:111-118 | agent/src/strategy_store/store.py:53-60 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 3 call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made 3 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/goal/store.py"},"region":{"startLine":96}}}],"partialFingerprints":{"codehealthFindingId/v1":"68741ed2e9d18dd38101e85c123264e884ef0abdd3536c4bb97156a7c40a4f68"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): agent/src/goal/store.py:250-258 | agent/src/strategy_store/sqlite_store.py:276-284 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/goal/store.py"},"region":{"startLine":250}}}],"partialFingerprints":{"codehealthFindingId/v1":"67a5cb1f58ee655c2737f2b78dab730b32b489dbc089032898be3e07fb14e912"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): agent/src/governance/ledger.py:346-352 | agent/src/providers/openai_codex.py:144-150 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. Note first that the copies are not typed on the same thing: the declarations holding them bind \u0060handle\u0060 to \u0060BinaryIO\u0060 in one and \u0060Any\u0060 in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH \u2014 their common supertype where they have one, or a new abstraction over them where they do not \u2014 and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/governance/ledger.py"},"region":{"startLine":346}}}],"partialFingerprints":{"codehealthFindingId/v1":"179d4914f3ca338f69ac793ee8d7adb494fe90b2bb95c6556b450811fc762bdf"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): agent/src/memory/search_index.py:230-237 | agent/src/session/search.py:173-178 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/memory/search_index.py"},"region":{"startLine":230}}}],"partialFingerprints":{"codehealthFindingId/v1":"7c489ffff3c4738e67f7dc0dfc5d9675182cf102e0b42dc3e3cbe6fc27674eb6"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): agent/src/portfolio/normalization.py:39-45 | agent/src/portfolio/service.py:150-156 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/portfolio/normalization.py"},"region":{"startLine":39}}}],"partialFingerprints":{"codehealthFindingId/v1":"130d1ba2689ff2d52b1e2617c8e051f5fd68eb91c76ffb8b1f6b342f8dcf84e7"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): agent/src/research_lab/execution.py:23-28 | agent/src/tools/goal_tool.py:64-69 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/research_lab/execution.py"},"region":{"startLine":23}}}],"partialFingerprints":{"codehealthFindingId/v1":"a79c21bbc44f73e3a42cbdefda19c3027bd887c5a63fb1d8e0ebc483ab3c661f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): agent/src/tools/etf_holdings_tool.py:708-714 | agent/src/tools/institutional_holdings_tool.py:1643-1649 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/etf_holdings_tool.py"},"region":{"startLine":708}}}],"partialFingerprints":{"codehealthFindingId/v1":"a56aa5b20195f96c6ce55b0cba3d7a35c7f2b6609d97edcdcacb756315d7fc85"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): agent/src/tools/financial_statements_tool.py:463-469 | agent/src/tools/northbound_tool.py:51-65 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/financial_statements_tool.py"},"region":{"startLine":463}}}],"partialFingerprints":{"codehealthFindingId/v1":"5245a1412cec68f9e48e5b1c57ce2cab73d3ef4467dc13c0e9b13c705f0a5c76"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 4): agent/src/tools/fred_macro_tool.py:257-262 | agent/src/tools/research_reports_tool.py:231-236 | agent/src/tools/sec_filings_tool.py:179-184 | agent/src/tools/symbol_search_tool.py:429-434 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from all 4 call sites, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/fred_macro_tool.py"},"region":{"startLine":257}}}],"partialFingerprints":{"codehealthFindingId/v1":"fcbb84e7615a759759a17317fce4983fbfc92785d99e20a1b0df169611cde6ac"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): agent/src/trading/connectors/alpaca/sdk.py:864-871 | agent/src/trading/connectors/binance/sdk.py:877-884 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on. Note first that the copies are not typed on the same thing: the declarations holding them bind \u0060cfg\u0060 to \u0060AlpacaConfig\u0060 in one and \u0060BinanceConfig\u0060 in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH \u2014 their common supertype where they have one, or a new abstraction over them where they do not \u2014 and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/alpaca/sdk.py"},"region":{"startLine":864}}}],"partialFingerprints":{"codehealthFindingId/v1":"04ddb968a47acc8aec0468e88e038e3b74915280d0736983fbce75ab9a652192"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 8): agent/src/trading/connectors/alpaca/sdk.py:888-892 | agent/src/trading/connectors/binance/shaping.py:31-35 | agent/src/trading/connectors/ibkr/local.py:692-696 | agent/src/trading/connectors/longbridge/sdk.py:801-805 | agent/src/trading/connectors/okx/sdk.py:659-663 | agent/src/trading/connectors/tiger/sdk.py:644-648 | agent/src/trading/connectors/toss/sdk.py:621-625 | agent/src/trading/connectors/trading212/sdk.py:520-524 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 8 call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made 8 times. 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/alpaca/sdk.py"},"region":{"startLine":888}}}],"partialFingerprints":{"codehealthFindingId/v1":"eca7bb359c2ce869e3699222d3c5a5105a001f95ae688e84867f694e2983e6c6"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): agent/src/trading/connectors/mt5/orders.py:399-410 | agent/src/trading/connectors/okx/sdk.py:532-543 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on. Note first that the copies are not typed on the same thing: the declarations holding them bind \u0060cfg\u0060 to \u0060MT5Config\u0060 in one and \u0060OKXConfig\u0060 in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH \u2014 their common supertype where they have one, or a new abstraction over them where they do not \u2014 and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/mt5/orders.py"},"region":{"startLine":399}}}],"partialFingerprints":{"codehealthFindingId/v1":"b7255499b143b7280f0a96fb0325a7eb64889ac6f6ee4ed167b427cff9003512"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (17 lines \u00D7 2): agent/src/trading/connectors/okx/sdk.py:794-810 | agent/src/trading/connectors/tiger/sdk.py:727-743 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/okx/sdk.py"},"region":{"startLine":794}}}],"partialFingerprints":{"codehealthFindingId/v1":"7a211a9ab5578a5fd9b31be35749f6ccdc50efa8937ab9812ae7f30edd093bf8"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): agent/src/trading/connectors/toss/sdk.py:432-437 | agent/src/trading/connectors/trading212/sdk.py:385-390 \u2014 \u0060agent/src/trading/connectors/toss/sdk.py\u0060 and \u0060agent/src/trading/connectors/trading212/sdk.py\u0060 are one unit implemented once per sibling directory, so they are most likely parallel implementations of one contract rather than a copy of each other \u2014 this scan matched 6 separate duplicated blocks between them, totalling at least 61 lines. If both are selected at run time, neither can be retired in favour of the other, and the lines that DIFFER between them are the reason both exist. The move that pays here is to hoist the identical part into a shared location the whole family can reach and give what differs a parameter or a seam, so a change lands once instead of once per sibling; extracting one helper per block leaves every sibling to drift on its own. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. Note first that the copies are not typed on the same thing: the declarations holding them bind \u0060config\u0060 to \u0060TossConfig | None = None\u0060 in one and \u0060Trading212Config | None = None\u0060 in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH \u2014 their common supertype where they have one, or a new abstraction over them where they do not \u2014 and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/toss/sdk.py"},"region":{"startLine":432}}}],"partialFingerprints":{"codehealthFindingId/v1":"c3e7093e8cdd84b5636d5d3763dba731f5b2774724e26169c91de0701ccaaff4"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): agent/src/trading/connectors/toss/sdk.py:578-585 | agent/src/trading/connectors/trading212/sdk.py:482-489 \u2014 \u0060agent/src/trading/connectors/toss/sdk.py\u0060 and \u0060agent/src/trading/connectors/trading212/sdk.py\u0060 are one unit implemented once per sibling directory, so they are most likely parallel implementations of one contract rather than a copy of each other \u2014 this scan matched 6 separate duplicated blocks between them, totalling at least 61 lines. If both are selected at run time, neither can be retired in favour of the other, and the lines that DIFFER between them are the reason both exist. The move that pays here is to hoist the identical part into a shared location the whole family can reach and give what differs a parameter or a seam, so a change lands once instead of once per sibling; extracting one helper per block leaves every sibling to drift on its own. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on. Note first that the copies are not typed on the same thing: the declarations holding them bind \u0060config\u0060 to \u0060TossConfig\u0060 in one and \u0060Trading212Config\u0060 in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH \u2014 their common supertype where they have one, or a new abstraction over them where they do not \u2014 and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/toss/sdk.py"},"region":{"startLine":578}}}],"partialFingerprints":{"codehealthFindingId/v1":"fce60b25665bd144cd37d6202b7e3924e864448a5eeb91ae135a8137852c62bd"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (15 lines \u00D7 2): agent/backtest/engines/korea_equity.py:81-96 | agent/backtest/engines/vietnam_equity.py:94-108 \u2014 before extracting anything, compare \u0060agent/backtest/engines/korea_equity.py\u0060 and \u0060agent/backtest/engines/vietnam_equity.py\u0060 as WHOLE FILES: this scan already matched 6 separate duplicated blocks between them, totalling at least 118 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together \u2014 extracting one helper per block leaves the fork in place. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/engines/korea_equity.py"},"region":{"startLine":81}}}],"partialFingerprints":{"codehealthFindingId/v1":"367060ca4149d6ab5f9057a108c871f73ced9cf403591237d8d3a1f73db9c202"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (22 lines \u00D7 2): agent/backtest/engines/korea_equity.py:274-296 | agent/backtest/engines/vietnam_equity.py:465-486 \u2014 before extracting anything, compare \u0060agent/backtest/engines/korea_equity.py\u0060 and \u0060agent/backtest/engines/vietnam_equity.py\u0060 as WHOLE FILES: this scan already matched 6 separate duplicated blocks between them, totalling at least 118 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together \u2014 extracting one helper per block leaves the fork in place. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/engines/korea_equity.py"},"region":{"startLine":274}}}],"partialFingerprints":{"codehealthFindingId/v1":"5e273928c1ac2b778d82470bc4e9fd91c4b5e6489128903a7ac4dbedf056e0dc"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (17 lines \u00D7 2): agent/backtest/engines/korea_equity.py:299-316 | agent/backtest/engines/vietnam_equity.py:489-505 \u2014 before extracting anything, compare \u0060agent/backtest/engines/korea_equity.py\u0060 and \u0060agent/backtest/engines/vietnam_equity.py\u0060 as WHOLE FILES: this scan already matched 6 separate duplicated blocks between them, totalling at least 118 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together \u2014 extracting one helper per block leaves the fork in place. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/engines/korea_equity.py"},"region":{"startLine":299}}}],"partialFingerprints":{"codehealthFindingId/v1":"724dce375da3971c4edd6adbee352ba3af2484ac8160a4d7fcf4bd0bfcdd7c33"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (18 lines \u00D7 2): agent/cli/commands/research_playbook.py:673-690 | agent/cli/commands/strategy_evidence.py:177-194 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/commands/research_playbook.py"},"region":{"startLine":673}}}],"partialFingerprints":{"codehealthFindingId/v1":"8f8cf86c2478cc064aacc597b60863093cedf4839f8f0efde0e7a3b576e553b7"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): agent/cli/commands/session.py:26-35 | agent/cli/commands/show.py:41-50 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/commands/session.py"},"region":{"startLine":26}}}],"partialFingerprints":{"codehealthFindingId/v1":"5da4845632686fdce3abd789ccf19cdf8ad815ef2e5da0dc5fa71ef9a798c6c3"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): agent/src/factors/zoo/gtja191/alpha_103.py:38-49 | agent/src/factors/zoo/gtja191/alpha_177.py:38-49 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/gtja191/alpha_103.py"},"region":{"startLine":38}}}],"partialFingerprints":{"codehealthFindingId/v1":"4f329fc27d193b43bb46fc4e3e5b4f523c601eb19943581a20edcdb2e7c6e6b5"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): agent/src/goal/store.py:933-937 | agent/src/research_artifacts/store.py:173-181 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/goal/store.py"},"region":{"startLine":933}}}],"partialFingerprints":{"codehealthFindingId/v1":"612395e2d2f40b5bfe14911315c4b082a0ad6d040ab4e3c22b4a69ed79cac843"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (17 lines \u00D7 2): agent/src/tools/block_trades_tool.py:77-93 | agent/src/tools/northbound_tool.py:184-200 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/block_trades_tool.py"},"region":{"startLine":77}}}],"partialFingerprints":{"codehealthFindingId/v1":"87df7d54c231da8bfdd19f0aab5e955f9efe34f9de3e049986f3f383f592ae21"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (15 lines \u00D7 2): agent/src/tools/lockup_expiry_tool.py:59-73 | agent/src/tools/stock_news_tool.py:59-74 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/lockup_expiry_tool.py"},"region":{"startLine":59}}}],"partialFingerprints":{"codehealthFindingId/v1":"534518e264b4437ab2a6dfaf0fbccf9be220034b1153e3b91f26427098fd7aef"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 3): agent/src/trading/connectors/dhan/sdk.py:116-124 | agent/src/trading/connectors/etoro/client.py:100-108 | agent/src/trading/connectors/upbit/sdk.py:110-118 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 3 call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made 3 times. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/dhan/sdk.py"},"region":{"startLine":116}}}],"partialFingerprints":{"codehealthFindingId/v1":"4a30e745fdda4ad36eab0db2777b21eea2abff792f62279a415e04e0540e6041"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): agent/src/trading/connectors/kis/sdk.py:898-905 | agent/src/trading/connectors/longbridge/sdk.py:757-764 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on. Note first that the copies are not typed on the same thing: the declarations holding them bind \u0060cfg\u0060 to \u0060KISConfig\u0060 in one and \u0060LongbridgeConfig\u0060 in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH \u2014 their common supertype where they have one, or a new abstraction over them where they do not \u2014 and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/kis/sdk.py"},"region":{"startLine":898}}}],"partialFingerprints":{"codehealthFindingId/v1":"221f4b557a2dfb7f28d46e6d2a7326e0cddae15ce7b0c02ac111e4e4e83d886e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): agent/backtest/frozen.py:48-52 | agent/src/research_lab/execution.py:104-108 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/frozen.py"},"region":{"startLine":48}}}],"partialFingerprints":{"codehealthFindingId/v1":"9461e9488f1acd751cc6a8b79a4d28b9af70a6428d6b99650dfcd6173637e7f0"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): agent/backtest/loaders/gildata_loader.py:214-219 | agent/src/tools/gildata_srv.py:102-107 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, \u0060agent/backtest/loaders/gildata_loader.py:220\u0060 calls \u0060get\u0060, \u0060isinstance\u0060, \u0060ValueError\u0060 and \u0060agent/src/tools/gildata_srv.py:109\u0060 does not \u2014 after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/gildata_loader.py"},"region":{"startLine":214}}}],"partialFingerprints":{"codehealthFindingId/v1":"49a8d051f68d121bb054cbbb237637b175b9c05d805d8402507d9a3f372c00fa"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): agent/backtest/loaders/mootdx_loader.py:229-233 | agent/backtest/loaders/mootdx_loader.py:257-261 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, \u0060agent/backtest/loaders/mootdx_loader.py:256\u0060 calls \u0060sort_index\u0060 and \u0060agent/backtest/loaders/mootdx_loader.py:228\u0060 does not \u2014 after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/mootdx_loader.py"},"region":{"startLine":229}}}],"partialFingerprints":{"codehealthFindingId/v1":"09ce2cba3aade1990e311645d740d062b4fff94c304f871e88b848e50716dd3f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): agent/src/factors/zoo/gtja191/alpha_116.py:64-69 | agent/src/factors/zoo/gtja191/alpha_147.py:65-70 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, \u0060agent/src/factors/zoo/gtja191/alpha_147.py:64\u0060 calls \u0060ts_mean\u0060 and \u0060agent/src/factors/zoo/gtja191/alpha_116.py:63\u0060 does not \u2014 after which the two agree again for 4 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/gtja191/alpha_116.py"},"region":{"startLine":64}}}],"partialFingerprints":{"codehealthFindingId/v1":"1bf20359c5f9ccef53a71aa052bc164af2073c40b64e6c95dfd7d754793190a6"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 5): agent/src/factors/zoo/qlib158/cntd10.py:27-34 | agent/src/factors/zoo/qlib158/cntd20.py:27-34 | agent/src/factors/zoo/qlib158/cntd30.py:27-34 | agent/src/factors/zoo/qlib158/cntd5.py:27-34 | agent/src/factors/zoo/qlib158/cntd60.py:27-34 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from all 5 call sites, so a change lands once. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/qlib158/cntd10.py"},"region":{"startLine":27}}}],"partialFingerprints":{"codehealthFindingId/v1":"6a090750a49251596adfece2354003b82317c6e01ce9b6ffe9330649cac3b84f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 5): agent/src/factors/zoo/qlib158/rsqr10.py:28-33 | agent/src/factors/zoo/qlib158/rsqr20.py:28-33 | agent/src/factors/zoo/qlib158/rsqr30.py:28-33 | agent/src/factors/zoo/qlib158/rsqr5.py:28-33 | agent/src/factors/zoo/qlib158/rsqr60.py:28-33 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from all 5 call sites, so a change lands once. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/qlib158/rsqr10.py"},"region":{"startLine":28}}}],"partialFingerprints":{"codehealthFindingId/v1":"20c8f878d666d0dbe694dc078e1de998f4d23f09ee6f3f097e718049873a00c5"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): agent/src/tools/paper_trade/engine.py:316-320 | agent/src/tools/paper_trade/engine.py:339-343 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/paper_trade/engine.py"},"region":{"startLine":316}}}],"partialFingerprints":{"codehealthFindingId/v1":"ee1e421d9cd21769e1dd351fce20243132936e5e0bd3c45f38a17db69d7c8de4"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): agent/src/tools/pattern_tool.py:215-220 | agent/src/tools/pattern_tool.py:223-228 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/pattern_tool.py"},"region":{"startLine":215}}}],"partialFingerprints":{"codehealthFindingId/v1":"ac61072530bb59784ca6f044acae09e9239a4866434de3b346d34210e431d94a"}},{"ruleId":"D4","level":"warning","message":{"text":"Near-duplicate member pair (51 shared lines): tools/gateway_minute_restart_probe.py:85-298 | tools/gateway_ten_job_restart_probe.py:230-471 \u2014 These two members are variants of one another: 51 of their lines are already reported as duplicated blocks below, spread through both bodies rather than gathered into one. Read them as a single construct written twice. The repair is at the members\u0027 grain \u2014 factor the shared pipeline into one implementation the two call with their differences as parameters or as an injected step, or, where the difference is systematic (sync against async, one transport against another), generate one from the other. Extracting the individual blocks below is not the same fix: it leaves the two bodies in place and the next edit still has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"tools/gateway_minute_restart_probe.py"},"region":{"startLine":85}}}],"partialFingerprints":{"codehealthFindingId/v1":"30c5c0fb8e9ac8ec966bd7ced3e17e78661cc2ad9b7f5f17fb72dd00fb16aed9"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (15 corresponding lines): tools/gateway_minute_restart_probe.py:302-318 | tools/gateway_ten_job_restart_probe.py:474-488 \u2014 These two members are one piece of code written twice and then edited apart: 15 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"tools/gateway_minute_restart_probe.py"},"region":{"startLine":302}}}],"partialFingerprints":{"codehealthFindingId/v1":"6a06891ee1ab391fe7ca79bad8d7622196bbb6006647eef1bd99a4bb6636d7bd"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (7 corresponding lines): tools/gateway_combined_report.py:27-33 | tools/gateway_full_scan_report.py:21-27 \u2014 These two members are one piece of code written twice and then edited apart: 7 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 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\u0027 grain \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"tools/gateway_combined_report.py"},"region":{"startLine":27}}}],"partialFingerprints":{"codehealthFindingId/v1":"d121f0f65115ef6d050acf1ca6754ee8967551a1355d93479f23a7050b731551"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (21 lines \u00D7 2): tools/gateway_minute_restart_probe.py:128-148 | tools/gateway_ten_job_restart_probe.py:306-326 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"tools/gateway_minute_restart_probe.py"},"region":{"startLine":128}}}],"partialFingerprints":{"codehealthFindingId/v1":"b4a14e018dbb980b11254d6d1b08403ff38104a9711f8157185e6aa805619145"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (19 lines \u00D7 3): tools/gateway_history_restart_probe.py:68-86 | tools/gateway_minute_restart_probe.py:129-149 | tools/gateway_ten_job_restart_probe.py:307-327 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from all 3 call sites, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"tools/gateway_history_restart_probe.py"},"region":{"startLine":68}}}],"partialFingerprints":{"codehealthFindingId/v1":"ad128e3599105599340bc9d08950c74d88483388cc5475bd7d5ce6d2d09abccd"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): tools/gateway_full_scan_probe.py:138-149 | tools/gateway_mixed_memory_probe.py:141-152 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"tools/gateway_full_scan_probe.py"},"region":{"startLine":138}}}],"partialFingerprints":{"codehealthFindingId/v1":"6a2a4bd2ab681c77803cb9fe26288b1379303262b432ca2f6e1177dc5f23b492"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): tools/gateway_minute_restart_probe.py:104-115 | tools/gateway_ten_job_restart_probe.py:249-260 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"tools/gateway_minute_restart_probe.py"},"region":{"startLine":104}}}],"partialFingerprints":{"codehealthFindingId/v1":"1c0667e33857a4e0cc1b5243f445eb5d63773c5105e491b0abaa8cae7a8db9eb"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): tools/gateway_full_scan_probe.py:189-199 | tools/gateway_mixed_memory_probe.py:184-194 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"tools/gateway_full_scan_probe.py"},"region":{"startLine":189}}}],"partialFingerprints":{"codehealthFindingId/v1":"fdc7704e2d3fe3dc97ef97369d5477846a003da09341a372c54450f94272859b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7\u20139 lines \u00D7 3): tools/gateway_full_scan_probe.py:80-86 | tools/gateway_minute_restart_probe.py:109-117 | tools/gateway_ten_job_restart_probe.py:254-262 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from all 3 call sites, so a change lands once. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, \u0060tools/gateway_full_scan_probe.py:88\u0060 calls \u0060monotonic\u0060 and \u0060tools/gateway_ten_job_restart_probe.py:264\u0060 does not \u2014 after which the two agree again for 3 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"tools/gateway_full_scan_probe.py"},"region":{"startLine":80}}}],"partialFingerprints":{"codehealthFindingId/v1":"8d375247d46c397eda324af158c74eccf8d16850df76d8aaf6afae14ecfa2dac"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): tools/gateway_minute_restart_probe.py:271-278 | tools/gateway_ten_job_restart_probe.py:437-444 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060tools/gateway_minute_restart_probe.py:271\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"tools/gateway_minute_restart_probe.py"},"region":{"startLine":271}}}],"partialFingerprints":{"codehealthFindingId/v1":"6324b783188087bf034e5fdac2e98c8734b8af7c8484e5f86bffd5f9ca5adc11"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): tools/gateway_history_validate.py:34-40 | tools/gateway_ten_job_restart_probe.py:153-159 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, \u0060tools/gateway_history_validate.py:42\u0060 calls \u0060now\u0060, \u0060isoformat\u0060 and \u0060tools/gateway_ten_job_restart_probe.py:161\u0060 does not \u2014 after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"tools/gateway_history_validate.py"},"region":{"startLine":34}}}],"partialFingerprints":{"codehealthFindingId/v1":"b58f8dc4b65d8a9434e833c7ed5dea69ae5155a6daac8cc4b542f6a72425a782"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): tools/gateway_minute_restart_probe.py:180-186 | tools/gateway_ten_job_restart_probe.py:336-342 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"tools/gateway_minute_restart_probe.py"},"region":{"startLine":180}}}],"partialFingerprints":{"codehealthFindingId/v1":"4bc6075d16ac97a89a1f8e5d043b94618f823ebdc3b1af78e9361cb0608467e0"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): tools/gateway_soak_history.py:178-183 | tools/gateway_soak_history.py:216-221 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"tools/gateway_soak_history.py"},"region":{"startLine":178}}}],"partialFingerprints":{"codehealthFindingId/v1":"e4e267db8519ced0e782cb52742d76be0910652a486479f0920c1292b27c987d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): tools/gateway_minute_restart_probe.py:71-76 | tools/gateway_ten_job_restart_probe.py:121-126 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"tools/gateway_minute_restart_probe.py"},"region":{"startLine":71}}}],"partialFingerprints":{"codehealthFindingId/v1":"d7d837d5890af0f103d5f94badfd145ae1cdda56c49390149b0420e52a8b50ff"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): tools/gateway_route_benchmark.py:91-95 | tools/gateway_stream_latency.py:102-106 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"tools/gateway_route_benchmark.py"},"region":{"startLine":91}}}],"partialFingerprints":{"codehealthFindingId/v1":"cc02040c09664e35be9e261b4b96ca4ea7dc4541c8685b156a68f060e66fd377"}},{"ruleId":"D6","level":"warning","message":{"text":"Low cohesion: BrazilEquityEngine (LCOM4 4): BrazilEquityEngine\u0027s methods fall into 4 groups that share no field and call none of each other, against a bar of more than 3 for this run (LCOM4, configurable \u2014 your repository\u0027s bar is the one quoted here). Each group is a set of methods reachable from one another through shared fields or direct calls, so 4 groups means the type has that many internally-connected clusters with nothing tying them together. Types whose shape makes a high count expected \u2014 and which would otherwise dominate this list \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/engines/brazil_equity.py"},"region":{"startLine":42}}}],"partialFingerprints":{"codehealthFindingId/v1":"1698ebd54475b264da3338419c4291e4de8ed7d01a5b00e920c8419697d00935"}},{"ruleId":"D6","level":"warning","message":{"text":"Low cohesion: VolGatedStrangleEngine (LCOM4 4): VolGatedStrangleEngine\u0027s methods fall into 4 groups that share no field and call none of each other, against a bar of more than 3 for this run (LCOM4, configurable \u2014 your repository\u0027s bar is the one quoted here). Each group is a set of methods reachable from one another through shared fields or direct calls, so 4 groups means the type has that many internally-connected clusters with nothing tying them together. Types whose shape makes a high count expected \u2014 and which would otherwise dominate this list \u2014 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/skills/options-strategy/example_signal_engine.py"},"region":{"startLine":213}}}],"partialFingerprints":{"codehealthFindingId/v1":"87602b00e28d7234d5d8c12372746185a0823bfb05a3a037da440a850083f34e"}},{"ruleId":"D10","level":"note","message":{"text":"Mock-dominated test: saves $provider.name credentials (desktop=$isDesktop): This test sets up 3 test doubles (for example \u0060vi.fn\u0060) against 0 real object(s) of its own, and its only verification is 5 check(s) that the doubles were called. It pins how the code is wired, not what it does: it passes with a wrong result and fails when a call is harmlessly reordered or merged. Assert the outcome instead (the value returned, the state left behind), build collaborators and value objects for real or with a small hand-written fake, and keep doubles for the boundaries the test cannot own \u2014 the network, the clock, the file system."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/__tests__/SettingsClaudeCliModels.test.tsx"},"region":{"startLine":105}}}],"partialFingerprints":{"codehealthFindingId/v1":"e91fa764d212f08f018f096b38c40e7eb600c30c16c742204671c8db39b958dc"}},{"ruleId":"D10","level":"note","message":{"text":"Mock-dominated test: downloads PDF bytes with bearer authentication and keeps the key out of the URL: This test sets up 7 test doubles (for example \u0060vi.fn\u0060) against 1 real object(s) of its own, and its only verification is 2 check(s) that the doubles were called. It pins how the code is wired, not what it does: it passes with a wrong result and fails when a call is harmlessly reordered or merged. Assert the outcome instead (the value returned, the state left behind), build collaborators and value objects for real or with a small hand-written fake, and keep doubles for the boundaries the test cannot own \u2014 the network, the clock, the file system."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/lib/__tests__/api.test.ts"},"region":{"startLine":11}}}],"partialFingerprints":{"codehealthFindingId/v1":"f6da09cb5bdde8b7656ad73f31751a494143fa9dd3d5dc2af7eb441151a43ae8"}},{"ruleId":"D14","level":"error","message":{"text":"Banned license: python-telegram-bot: \u0060python-telegram-bot\u0060 22.8 is published on PyPI under \u0060LGPL-3.0-only\u0060, which this policy bans, and it is in the SHIPPED closure of this repository \u2014 so it is installed by everything that depends on this repository, not just by its test environment. A distribution offering SEVERAL licences is a choice and is only charged when every one of them is banned. Replace the package, or record an accepted exception. \u2605 The licence that makes this row is LGPL-3.0, and unmodified use is often permitted: the LGPL lets your code use an UNMODIFIED copy of the library that stays a separately installed package (its own entry in node_modules, site-packages or the gem path, which a user can replace) without your code coming under the LGPL. What it then asks is that you pass on its licence and notices and let users swap in their own build of it (LGPL-3.0 section 4). Modifying it, copying its code into yours, or merging it into one bundled or statically linked artifact is where the obligations grow, and this policy cannot see which you do \u2014 that is why it denies LGPL-3.0 by default. If you use it unmodified and separately installed, allow it in your repository\u0027s licence policy rather than replacing it: add \u0060LGPL-3.0-only\u0060 / \u0060LGPL-3.0-or-later\u0060 to the allow-list of the licence check your CI runs (\u0060license-checker --onlyAllow\u0060, the \u0060allow-licenses\u0060 input of GitHub\u0027s dependency-review-action, \u0060[licenses] allow\u0060 in cargo-deny\u0027s deny.toml), record why in the same change, and hide this row on the findings page with that reason. This scan\u0027s banned set is not read from that file, so the row stays until it is hidden."},"locations":[],"partialFingerprints":{"codehealthFindingId/v1":"440d7a9cc333c1566f0fc4c73fe2d51a14ec6b5f01455056a72a5c0274d0f018"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: frontend/src/pages/Agent.tsx: frontend/src/pages/Agent.tsx changed 18 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 364 in Agent.Agent at line 227. 10 of those changes were fix/bug commits, so the churn is repair rather than feature work. Before the next change lands here, make sure the area it touches is under test, then split that area out of the file so the following change is smaller than this one \u2014 a file this often edited pays the complexity back every time. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- frontend/src/pages/Agent.tsx\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Agent.tsx"},"region":{"startLine":227}}}],"partialFingerprints":{"codehealthFindingId/v1":"a754569cc94e896d2bf4ca057caf85ca0749b99c4379e419ec51c32b4894159d"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/agent/loop.py: agent/src/agent/loop.py changed 60 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 92 in AgentLoop._run_bound at line 386. 42 of those changes were fix/bug commits, so the churn is repair rather than feature work. Before the next change lands here, make sure the area it touches is under test, then split that area out of the file so the following change is smaller than this one \u2014 a file this often edited pays the complexity back every time. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/agent/loop.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/agent/loop.py"},"region":{"startLine":386}}}],"partialFingerprints":{"codehealthFindingId/v1":"6c3486929719d4e947f08c3ead1844d85ed2ebd87483a9210d4ca78e8bda7c27"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/evals/grounding/policies.py: agent/evals/grounding/policies.py changed 52 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 49 in _PolicyMixin._derivation at line 1957. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/evals/grounding/policies.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/grounding/policies.py"},"region":{"startLine":1957}}}],"partialFingerprints":{"codehealthFindingId/v1":"cc189768aaec4b278b7789ff3d89252f7f17830c9edc78519f46d70b7cd1200e"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/cli/_legacy.py: agent/cli/_legacy.py changed 37 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 63 in _legacy.main at line 6402. 12 of those changes were fix/bug commits, and the other 25 changed it for other reasons \u2014 this file is under both repair and feature pressure. Before the next change lands here, make sure the area it touches is under test, then split that area out of the file so the following change is smaller than this one \u2014 a file this often edited pays the complexity back every time. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/cli/_legacy.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":6402}}}],"partialFingerprints":{"codehealthFindingId/v1":"b3f7cb2533ae51af11e40417a87b59606930faa65a763dfb3deae5cf03b66883"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/backtest/engines/base.py: agent/backtest/engines/base.py changed 37 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 47 in BaseEngine._execute_bars at line 1290. 25 of those changes were fix/bug commits, so the churn is repair rather than feature work. Before the next change lands here, make sure the area it touches is under test, then split that area out of the file so the following change is smaller than this one \u2014 a file this often edited pays the complexity back every time. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/backtest/engines/base.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/engines/base.py"},"region":{"startLine":1290}}}],"partialFingerprints":{"codehealthFindingId/v1":"b67f668ebcf977ee467dd2e30b2de2b9df2bb031477b17699f2703bb8e1c9b4d"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: frontend/src/lib/api.ts: frontend/src/lib/api.ts changed 64 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 25 in api.errorFromResponse at line 403. 22 of those changes were fix/bug commits, and the other 42 changed it for other reasons \u2014 this file is under both repair and feature pressure. Before the next change lands here, make sure the area it touches is under test, then split that area out of the file so the following change is smaller than this one \u2014 a file this often edited pays the complexity back every time. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- frontend/src/lib/api.ts\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/lib/api.ts"},"region":{"startLine":403}}}],"partialFingerprints":{"codehealthFindingId/v1":"83345f22f6b6c237966a3ce57d83685608aca3371abf05058a8befb8446dd590"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/backtest/runner.py: agent/backtest/runner.py changed 34 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 44 in runner.fetch_data_map at line 2060. 25 of those changes were fix/bug commits, so the churn is repair rather than feature work. Before the next change lands here, make sure the area it touches is under test, then split that area out of the file so the following change is smaller than this one \u2014 a file this often edited pays the complexity back every time. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/backtest/runner.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/runner.py"},"region":{"startLine":2060}}}],"partialFingerprints":{"codehealthFindingId/v1":"12bff7a92e638c95f24e874074cdf6463c4fa9fae8acbf24f1f2a30f782d213e"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/evals/grounding/figures.py: agent/evals/grounding/figures.py changed 33 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 44 in figures.scan_figures at line 1254. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/evals/grounding/figures.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/grounding/figures.py"},"region":{"startLine":1254}}}],"partialFingerprints":{"codehealthFindingId/v1":"3a409bacb192295efc000fc61905740595b15a9b6c88ec035ddc741b4497e434"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: frontend/src/components/settings/ChannelConfigPanel.tsx: frontend/src/components/settings/ChannelConfigPanel.tsx changed 11 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 113 in ChannelConfigPanel.ChannelConfigPanel at line 193. 4 of those changes were fix/bug commits, and the other 7 changed it for other reasons \u2014 this file is under both repair and feature pressure. Before the next change lands here, make sure the area it touches is under test, then split that area out of the file so the following change is smaller than this one \u2014 a file this often edited pays the complexity back every time. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- frontend/src/components/settings/ChannelConfigPanel.tsx\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/settings/ChannelConfigPanel.tsx"},"region":{"startLine":193}}}],"partialFingerprints":{"codehealthFindingId/v1":"bc48768ec60071cd35ce3538d50cb2944e73a6f10dcb1a83dc5f07ca73053dba"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/mcp_server.py: agent/mcp_server.py changed 59 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 20 in mcp_server.alpha_bench at line 1059. 21 of those changes were fix/bug commits, and the other 38 changed it for other reasons \u2014 this file is under both repair and feature pressure. Before the next change lands here, make sure the area it touches is under test, then split that area out of the file so the following change is smaller than this one \u2014 a file this often edited pays the complexity back every time. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/mcp_server.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/mcp_server.py"},"region":{"startLine":1059}}}],"partialFingerprints":{"codehealthFindingId/v1":"fc02f7790871052ccec05691675d7bdcb0c95c5f1e0e5fbf9cb73dfd47c6745e"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/swarm/worker.py: agent/src/swarm/worker.py changed 22 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 52 in worker._run_worker_impl at line 557. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/swarm/worker.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/swarm/worker.py"},"region":{"startLine":557}}}],"partialFingerprints":{"codehealthFindingId/v1":"7d671ab7cfced749a9ff303dd150096a2633d34f56b4a6a01f1b5c0462ee556d"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/providers/llm.py: agent/src/providers/llm.py changed 28 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 40 in llm.build_llm at line 1454. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/providers/llm.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/providers/llm.py"},"region":{"startLine":1454}}}],"partialFingerprints":{"codehealthFindingId/v1":"26b06a0220ac46cb23bffb7d3424a422f509b5f62d9bb88d633631ae3adea973"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/evals/grounding/evidence.py: agent/evals/grounding/evidence.py changed 36 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 29 in _EvidenceMixin._ingest_engine_table at line 1199. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/evals/grounding/evidence.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/grounding/evidence.py"},"region":{"startLine":1199}}}],"partialFingerprints":{"codehealthFindingId/v1":"472d77a65fb912dea77233efce277949e5a4c66bf15fcacddebe354bf9689ed0"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/backtest/engines/options_portfolio.py: agent/backtest/engines/options_portfolio.py changed 18 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 58 in options_portfolio._calc_options_metrics at line 705. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/backtest/engines/options_portfolio.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/engines/options_portfolio.py"},"region":{"startLine":705}}}],"partialFingerprints":{"codehealthFindingId/v1":"2539a68336751370e6fa19fcea9a8c887d1800af6d947ed8f9c1ef567effa058"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: frontend/src/pages/Settings.tsx: frontend/src/pages/Settings.tsx changed 10 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 104 in Settings.Settings at line 42. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- frontend/src/pages/Settings.tsx\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Settings.tsx"},"region":{"startLine":42}}}],"partialFingerprints":{"codehealthFindingId/v1":"feb6015ca8a4114cfa99eab282d6ca91a79460709a568e6f28b4738cd332d574"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: frontend/src/pages/Portfolio.tsx: frontend/src/pages/Portfolio.tsx changed 13 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 78 in Portfolio.Portfolio at line 135. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- frontend/src/pages/Portfolio.tsx\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Portfolio.tsx"},"region":{"startLine":135}}}],"partialFingerprints":{"codehealthFindingId/v1":"6c3b0c632b0a3d7e7fc7243b1b13aa492dc7824802999cc9367cb9f0e8de6ed8"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/portfolio/service.py: agent/src/portfolio/service.py changed 19 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 53 in PortfolioService._collect_source at line 962. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/portfolio/service.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/portfolio/service.py"},"region":{"startLine":962}}}],"partialFingerprints":{"codehealthFindingId/v1":"9f2af55fdbd2fa77c4ea8d73500ed0a51e43f49bb0e1106822c8d0d7fa41ad1c"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: frontend/src/pages/Scheduled.tsx: frontend/src/pages/Scheduled.tsx changed 7 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 116 in Scheduled.Scheduled at line 92. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- frontend/src/pages/Scheduled.tsx\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Scheduled.tsx"},"region":{"startLine":92}}}],"partialFingerprints":{"codehealthFindingId/v1":"05ffacc45a3473ccaf91677c81685e242819bbd277423f394710b4788c754044"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/data_gateway/historical.py: agent/src/data_gateway/historical.py changed 14 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 55 in historical._walk_bars at line 121. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/data_gateway/historical.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/data_gateway/historical.py"},"region":{"startLine":121}}}],"partialFingerprints":{"codehealthFindingId/v1":"ac21ec0bcc7ce6b4f1763a3ecceb2ad690ce29aabbe03680e390411180130743"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/tools/market_data_tool.py: agent/src/tools/market_data_tool.py changed 19 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 39 in MarketDataTool.execute at line 172. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/tools/market_data_tool.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/market_data_tool.py"},"region":{"startLine":172}}}],"partialFingerprints":{"codehealthFindingId/v1":"07f8d0e15096a2a8a24a98f462a706eb0b0e49b9cdc68319f9cc363cc7714926"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/providers/chat.py: agent/src/providers/chat.py changed 15 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 49 in ChatLLM.stream_chat at line 495. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/providers/chat.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/providers/chat.py"},"region":{"startLine":495}}}],"partialFingerprints":{"codehealthFindingId/v1":"bcee55ec61aeabd659418a571a125ab00765aede1eecc61d401c06d53b9d09c2"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/market_data.py: agent/src/market_data.py changed 30 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 23 in market_data._fetch_market_data_direct at line 220. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/market_data.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/market_data.py"},"region":{"startLine":220}}}],"partialFingerprints":{"codehealthFindingId/v1":"98783ea57102d15bb5b39f92f6fa73232fe2304a14aca068166127f726b8f937"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/tools/symbol_search_tool.py: agent/src/tools/symbol_search_tool.py changed 19 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 36 in symbol_search_tool._search_selected_connector at line 573. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/tools/symbol_search_tool.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/symbol_search_tool.py"},"region":{"startLine":573}}}],"partialFingerprints":{"codehealthFindingId/v1":"b5b3bbe27aa1ecf8ba83fa4c86ff06192ef39292cf338191d0d6f8da99ef3685"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: frontend/src/pages/RunDetail.tsx: frontend/src/pages/RunDetail.tsx changed 9 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 75 in RunDetail.RunDetail at line 124. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- frontend/src/pages/RunDetail.tsx\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/RunDetail.tsx"},"region":{"startLine":124}}}],"partialFingerprints":{"codehealthFindingId/v1":"444c4b336a016f1ac6428b4d0f9d38ef40a1f5b276b966177fa431efc1e3c4c0"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: tools/gateway_combined_report.py: tools/gateway_combined_report.py changed 10 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 62 in gateway_combined_report.summarize at line 36. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- tools/gateway_combined_report.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"tools/gateway_combined_report.py"},"region":{"startLine":36}}}],"partialFingerprints":{"codehealthFindingId/v1":"b2f1473bf0dd0b6ff6e4edfc75add1a2141ce80ae5b17815c86ab2275f424da7"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/data_gateway/history_store.py: agent/src/data_gateway/history_store.py changed 12 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 47 in HistoryStore.run at line 526. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/data_gateway/history_store.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/data_gateway/history_store.py"},"region":{"startLine":526}}}],"partialFingerprints":{"codehealthFindingId/v1":"766ce8e91d414a0e9134b7a159ac5495d66922b73885713184b5109c0356660c"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/tools/alpha_bench_tool.py: agent/src/tools/alpha_bench_tool.py changed 14 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 34 in alpha_bench_tool.run_alpha_bench at line 1270. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/tools/alpha_bench_tool.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/alpha_bench_tool.py"},"region":{"startLine":1270}}}],"partialFingerprints":{"codehealthFindingId/v1":"851d9baae6ead368b65d367b01cf4426d8e6d9f37f6b2b41e6a1bb6f42fe14af"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/channels/email.py: agent/src/channels/email.py changed 11 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 42 in EmailChannel.send at line 265. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/channels/email.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/email.py"},"region":{"startLine":265}}}],"partialFingerprints":{"codehealthFindingId/v1":"806a32d0062e3973b86347eaf8fc338c6b66bafdfd2cad25ed7bb4a8ad719757"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: tools/gateway_soak.py: tools/gateway_soak.py changed 12 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 36 in gateway_soak.exercise at line 359. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- tools/gateway_soak.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"tools/gateway_soak.py"},"region":{"startLine":359}}}],"partialFingerprints":{"codehealthFindingId/v1":"89d26e430d58c95c64693e23df07a0cf8e3190ea7ad1ed2c4f5749499a5eb92b"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/backtest/metrics.py: agent/backtest/metrics.py changed 13 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 31 in metrics.calc_metrics at line 606. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/backtest/metrics.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/metrics.py"},"region":{"startLine":606}}}],"partialFingerprints":{"codehealthFindingId/v1":"a917acf4ea5b4ca7085aee481dd2167fedec28ee2d182b26b8a60ca8216870d7"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/backtest/loaders/base.py: agent/backtest/loaders/base.py changed 16 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 25 in base._read_loader_cache_frame at line 741. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/backtest/loaders/base.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/base.py"},"region":{"startLine":741}}}],"partialFingerprints":{"codehealthFindingId/v1":"1c7669f18f999f54e08fa5c6357a288a40c149b8f1b15003cbfdcc0f418ba36c"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/agent/tool_lifecycle.py: agent/src/agent/tool_lifecycle.py changed 7 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 57 in ToolCallLifecycle._process_tool_calls at line 95. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/agent/tool_lifecycle.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/agent/tool_lifecycle.py"},"region":{"startLine":95}}}],"partialFingerprints":{"codehealthFindingId/v1":"82bb8b6ae2a152bdb136587b8c73d895d3753c0d2b605db08fdd4276c38b472f"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/channels/weixin.py: agent/src/channels/weixin.py changed 6 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 66 in WeixinChannel._process_message at line 600. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/channels/weixin.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/weixin.py"},"region":{"startLine":600}}}],"partialFingerprints":{"codehealthFindingId/v1":"b2d8451dbd0cb06409342f2a2e9404260b0fc22d9004f26498cabd2ae51c9fcf"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/scheduled_research/models.py: agent/src/scheduled_research/models.py changed 10 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 39 in ScheduledResearchJob.from_dict at line 313. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/scheduled_research/models.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/scheduled_research/models.py"},"region":{"startLine":313}}}],"partialFingerprints":{"codehealthFindingId/v1":"009f90edd94d8c31daeaa950fc07832157891bbd4e7d24b55ea316ac67a23809"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/factors/bench_runner_strict.py: agent/src/factors/bench_runner_strict.py changed 8 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 46 in bench_runner_strict.run_bench_strict at line 326. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/factors/bench_runner_strict.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/bench_runner_strict.py"},"region":{"startLine":326}}}],"partialFingerprints":{"codehealthFindingId/v1":"f3a5362ac48c78dcecbe27c76fd13289372fe97f17616038e056775e28a425c9"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/trading/service.py: agent/src/trading/service.py changed 21 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 17 in service._sdk_config at line 82. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/trading/service.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/service.py"},"region":{"startLine":82}}}],"partialFingerprints":{"codehealthFindingId/v1":"9ce527baa33067f3662c6301e00888477408ab7419fcfbfc42591a6c2c878c11"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/swarm/runtime.py: agent/src/swarm/runtime.py changed 14 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 24 in SwarmRuntime._apply_resume_overlay at line 783. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/swarm/runtime.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/swarm/runtime.py"},"region":{"startLine":783}}}],"partialFingerprints":{"codehealthFindingId/v1":"2b79c803507425f7bcf37a119011fe7668f10293d16e415e88fbb77162db238c"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/quantlib/eventstudy.py: agent/src/quantlib/eventstudy.py changed 8 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 41 in eventstudy.event_study at line 325. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/quantlib/eventstudy.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/eventstudy.py"},"region":{"startLine":325}}}],"partialFingerprints":{"codehealthFindingId/v1":"de3f3987494cd3f125def08b93f94467a007ff4d3fe81f32fdc0e969293a8e3d"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: frontend/src/pages/ResearchArtifacts.tsx: frontend/src/pages/ResearchArtifacts.tsx changed 5 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 63 in ResearchArtifacts.ResearchArtifacts at line 80. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- frontend/src/pages/ResearchArtifacts.tsx\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/ResearchArtifacts.tsx"},"region":{"startLine":80}}}],"partialFingerprints":{"codehealthFindingId/v1":"3a0bd0031e92f9682c90581c2db2ca488be3d3a97094ba3f2a4bfc568a9dec7b"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/backtest/validation.py: agent/backtest/validation.py changed 13 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 24 in validation.walk_forward_analysis at line 246. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/backtest/validation.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/validation.py"},"region":{"startLine":246}}}],"partialFingerprints":{"codehealthFindingId/v1":"d4f3720685b23d00f3e5ebbbacb0bece8f127ecef2e23c18f489cbc359e8a6d6"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/tools/trade_journal_tool.py: agent/src/tools/trade_journal_tool.py changed 13 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 24 in trade_journal_tool.pair_trades_fifo at line 76. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/tools/trade_journal_tool.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/trade_journal_tool.py"},"region":{"startLine":76}}}],"partialFingerprints":{"codehealthFindingId/v1":"4d20d434d3d0264927c4c1f9e198b04accccc417d573bc27a9e0ca627592766c"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/session/service.py: agent/src/session/service.py changed 17 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 18 in SessionService._run_attempt at line 446. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/session/service.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/session/service.py"},"region":{"startLine":446}}}],"partialFingerprints":{"codehealthFindingId/v1":"a2d0b3385a283cf7a3840ef779fc2208a812aa8252c559c6fe0bc2fb627df8d3"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/memory/persistent.py: agent/src/memory/persistent.py changed 10 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 30 in PersistentMemory.find_relevant at line 366. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/memory/persistent.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/memory/persistent.py"},"region":{"startLine":366}}}],"partialFingerprints":{"codehealthFindingId/v1":"b75a2db1d4209daf00fd8b2c3d253ced2a5d10577c6491ce8c77ad22dcef5918"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/data_gateway/service.py: agent/src/data_gateway/service.py changed 12 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 24 in MarketDataGateway._fetch at line 185. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/data_gateway/service.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/data_gateway/service.py"},"region":{"startLine":185}}}],"partialFingerprints":{"codehealthFindingId/v1":"3a8514db3bf756b28cea4e24d2de2e56f6d54c8502062c0f3f0fc7e245efc6c5"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: frontend/src/lib/options.ts: frontend/src/lib/options.ts changed 9 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 32 in options.buildPayoffRequest at line 373. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- frontend/src/lib/options.ts\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/lib/options.ts"},"region":{"startLine":373}}}],"partialFingerprints":{"codehealthFindingId/v1":"23e5e9f9d85b3733376458c1a4fa66368b8f205f3f2a278b0c49c99df5072f89"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/backtest/engines/composite.py: agent/backtest/engines/composite.py changed 14 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 20 in composite._build_rule_engines at line 29. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/backtest/engines/composite.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/engines/composite.py"},"region":{"startLine":29}}}],"partialFingerprints":{"codehealthFindingId/v1":"820d5bed3dec1132c5bed2c6f7040a8c1c142d67949f82f4c2323d608ea548eb"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: frontend/src/lib/swarmStatus.ts: frontend/src/lib/swarmStatus.ts changed 6 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 46 in swarmStatus.applySwarmEvent at line 209. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- frontend/src/lib/swarmStatus.ts\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/lib/swarmStatus.ts"},"region":{"startLine":209}}}],"partialFingerprints":{"codehealthFindingId/v1":"f3dff72d75ea61c6ec567116688870972e5c570afe2c78065923bfad915b1799"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: frontend/src/components/portfolio/ConnectionCenter.tsx: frontend/src/components/portfolio/ConnectionCenter.tsx changed 6 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 44 in ConnectionCenter.ConnectionCard at line 183. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- frontend/src/components/portfolio/ConnectionCenter.tsx\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/portfolio/ConnectionCenter.tsx"},"region":{"startLine":183}}}],"partialFingerprints":{"codehealthFindingId/v1":"a0add6783bf346f9e7c2c90cc0d3ffdbc72cfb6a84fce81c489e1896a9712200"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/tools/technical_indicator_tool.py: agent/src/tools/technical_indicator_tool.py changed 8 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 33 in TechnicalIndicatorTool.execute at line 322. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/tools/technical_indicator_tool.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/technical_indicator_tool.py"},"region":{"startLine":322}}}],"partialFingerprints":{"codehealthFindingId/v1":"f88e88b838d029cb20ea97498f6bad57455d1009b5b1a6f8faf07fc5cee74608"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/scheduled_research/executor.py: agent/src/scheduled_research/executor.py changed 12 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 22 in ScheduledResearchExecutor.sweep_deliveries at line 567. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/scheduled_research/executor.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/scheduled_research/executor.py"},"region":{"startLine":567}}}],"partialFingerprints":{"codehealthFindingId/v1":"5a26872263273c2582f28165cddb1d3f25da894c173cafc80424968bbe77d2f3"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/tools/trade_journal_parsers.py: agent/src/tools/trade_journal_parsers.py changed 13 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 20 in trade_journal_parsers.parse_generic at line 571. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/tools/trade_journal_parsers.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/trade_journal_parsers.py"},"region":{"startLine":571}}}],"partialFingerprints":{"codehealthFindingId/v1":"c7479e33cb064e1daacd5a4f90fd2b8e9989d70eb510e267ff920b04f14c0a44"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/providers/openai_codex.py: agent/src/providers/openai_codex.py changed 6 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 43 in openai_codex._message_chunks_from_events at line 632. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/providers/openai_codex.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/providers/openai_codex.py"},"region":{"startLine":632}}}],"partialFingerprints":{"codehealthFindingId/v1":"a87e2e29e82c32f148a9230920ac8236e715b700976fb78c175d2b839ced67c2"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/channels/manager.py: agent/src/channels/manager.py changed 14 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 18 in ChannelManager._dispatch_outbound at line 458. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/channels/manager.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/manager.py"},"region":{"startLine":458}}}],"partialFingerprints":{"codehealthFindingId/v1":"f8190b3caa4dff6a60be5a1625fde9bfa20e0e8ebeefbb756a9a71bce57d1246"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: frontend/src/pages/OptionsLab.tsx: frontend/src/pages/OptionsLab.tsx changed 5 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 50 in OptionsLab.OptionsLab at line 61. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- frontend/src/pages/OptionsLab.tsx\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/OptionsLab.tsx"},"region":{"startLine":61}}}],"partialFingerprints":{"codehealthFindingId/v1":"8e432e822f80d573da03daeec7daa91cfa8b2f2bdbf3e1adcd980c9267e77dc0"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/factors/bench_runner.py: agent/src/factors/bench_runner.py changed 5 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 47 in bench_runner.run_bench at line 144. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/factors/bench_runner.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/bench_runner.py"},"region":{"startLine":144}}}],"partialFingerprints":{"codehealthFindingId/v1":"0600b255058a267b51de097e660e57fd1cc6d32d0b1ba9570d217067730cf565"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/portfolio/normalization.py: agent/src/portfolio/normalization.py changed 6 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 39 in normalization.normalize_position at line 56. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/portfolio/normalization.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/portfolio/normalization.py"},"region":{"startLine":56}}}],"partialFingerprints":{"codehealthFindingId/v1":"3d763a3c36bd99ad30c82a0dbf6556854035de553a429cb5196fdad5d287e583"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/api/channels_config_routes.py: agent/src/api/channels_config_routes.py changed 13 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 18 in channels_config_routes._apply_update at line 454. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/api/channels_config_routes.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/api/channels_config_routes.py"},"region":{"startLine":454}}}],"partialFingerprints":{"codehealthFindingId/v1":"4420eab724380fc424385870ee009163219b090025866e5b7c807e882c56f270"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/channels/slack.py: agent/src/channels/slack.py changed 6 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 39 in SlackChannel._on_socket_request at line 335. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/channels/slack.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/slack.py"},"region":{"startLine":335}}}],"partialFingerprints":{"codehealthFindingId/v1":"5690c3f16ed3155aad41bdeab4c14e2b6708c69e5e55555cff70dffe806e893e"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/tools/financial_rigor_tool.py: agent/src/tools/financial_rigor_tool.py changed 8 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 29 in FinancialRigorTool.execute at line 549. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/tools/financial_rigor_tool.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/financial_rigor_tool.py"},"region":{"startLine":549}}}],"partialFingerprints":{"codehealthFindingId/v1":"c46f10e152a8ac6e33fcbcefdec2c7e7c4c9aad2db1de4e4d8909bfb7de19c03"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: frontend/src/components/layout/Layout.tsx: frontend/src/components/layout/Layout.tsx changed 4 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 58 in Layout.Layout at line 21. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- frontend/src/components/layout/Layout.tsx\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/layout/Layout.tsx"},"region":{"startLine":21}}}],"partialFingerprints":{"codehealthFindingId/v1":"f2c5ba446a2ee7923a6778df55fb7b664fa015bf95bbcdb3e979412fa3a1f0ed"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/channels/feishu.py: agent/src/channels/feishu.py changed 9 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 25 in FeishuChannel.send at line 2037. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/channels/feishu.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/feishu.py"},"region":{"startLine":2037}}}],"partialFingerprints":{"codehealthFindingId/v1":"457f5f5389411eb82862fb7cd5287626311b2462b74bb96f3a97077563e76b27"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/scheduled_research/service.py: agent/src/scheduled_research/service.py changed 5 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 45 in service.build_job_from_draft at line 136. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/scheduled_research/service.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/scheduled_research/service.py"},"region":{"startLine":136}}}],"partialFingerprints":{"codehealthFindingId/v1":"89e2fc43fb4b96abfca45098b5a4b33a5c50b77b40f3ee172691f24faf24348f"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/channels/runtime.py: agent/src/channels/runtime.py changed 8 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 28 in ChannelRuntime._handle_inbound at line 122. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/channels/runtime.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/runtime.py"},"region":{"startLine":122}}}],"partialFingerprints":{"codehealthFindingId/v1":"6c7ae833f257c7442dff9d2bf95f003e995ac8536bc4e94e26a6bfc1cd3f295b"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/tools/__init__.py: agent/src/tools/__init__.py changed 7 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 32 in tools.build_registry at line 77. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/tools/__init__.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/__init__.py"},"region":{"startLine":77}}}],"partialFingerprints":{"codehealthFindingId/v1":"62f98c8bf8f3a317f1adef15fdd83a33f76d069e3e0508c285e12cae50f32af9"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/cli/main.py: agent/cli/main.py changed 7 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 31 in main._interactive_loop at line 1303. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/cli/main.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/main.py"},"region":{"startLine":1303}}}],"partialFingerprints":{"codehealthFindingId/v1":"f4769529982abf702c838bd08830c3ca395a33d06e9d409ebb0375f85c6893d9"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/tools/paper_trade/session_5m.py: agent/src/tools/paper_trade/session_5m.py changed 6 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 36 in session_5m.match_orders_5m at line 141. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/tools/paper_trade/session_5m.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/paper_trade/session_5m.py"},"region":{"startLine":141}}}],"partialFingerprints":{"codehealthFindingId/v1":"8b9d0618f84cd52af44d872ac3814423412a7cbdd71e2a2a52e14c924ba55c8d"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/factors/cli_handlers.py: agent/src/factors/cli_handlers.py changed 5 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 42 in cli_handlers.cmd_alpha_bench at line 566. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/factors/cli_handlers.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/cli_handlers.py"},"region":{"startLine":566}}}],"partialFingerprints":{"codehealthFindingId/v1":"38f33eadbea80cdafe7493c34f6a09cb9656a18c2b0fa3c5c06fab76eabc5e08"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/backtest/correlation.py: agent/backtest/correlation.py changed 13 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 16 in correlation.infer_market at line 20. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/backtest/correlation.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/correlation.py"},"region":{"startLine":20}}}],"partialFingerprints":{"codehealthFindingId/v1":"efa61bb400549ac80752fd7ffb4e0f639c43d56d8676c0dd8f62192bac08307d"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/tools/redaction.py: agent/src/tools/redaction.py changed 13 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 16 in redaction.is_sensitive_arg at line 284. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/tools/redaction.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/redaction.py"},"region":{"startLine":284}}}],"partialFingerprints":{"codehealthFindingId/v1":"7a45828a24bf8e8643c29798aca76a98f06be285755bca101256d3d4aeece776"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/agent/result_artifacts.py: agent/src/agent/result_artifacts.py changed 9 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 23 in result_artifacts.deliver_tool_result at line 136. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/agent/result_artifacts.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/agent/result_artifacts.py"},"region":{"startLine":136}}}],"partialFingerprints":{"codehealthFindingId/v1":"d085c7d0d407638b690048fbc9aa19fd6a26651438e8bbee7e0e73906deebbe1"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/live/sdk_order_gate.py: agent/src/live/sdk_order_gate.py changed 9 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 23 in sdk_order_gate._allow at line 434. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/live/sdk_order_gate.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/live/sdk_order_gate.py"},"region":{"startLine":434}}}],"partialFingerprints":{"codehealthFindingId/v1":"45d7db896c7b83cc784766fa5af4951d03ffac4190307d280307de31dc9cd6ae"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/backtest/loaders/tencent_loader.py: agent/backtest/loaders/tencent_loader.py changed 10 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 20 in DataLoader._fetch_one at line 241. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/backtest/loaders/tencent_loader.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/tencent_loader.py"},"region":{"startLine":241}}}],"partialFingerprints":{"codehealthFindingId/v1":"0ea081a30caac7cc3e7895144d8a3d48c75b6a08fab1cb05f961c2795ecc063e"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/trading/connectors/robinhood/mcp.py: agent/src/trading/connectors/robinhood/mcp.py changed 5 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 40 in mcp.quote_summary at line 352. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/trading/connectors/robinhood/mcp.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/robinhood/mcp.py"},"region":{"startLine":352}}}],"partialFingerprints":{"codehealthFindingId/v1":"4729a00a755d76804a55193bccc67e71f4f9a74018e6edaaf00733da84b81da3"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/live/runtime/runner.py: agent/src/live/runtime/runner.py changed 12 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 16 in LiveRunner._run_preemptive_sweep at line 624. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/live/runtime/runner.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/live/runtime/runner.py"},"region":{"startLine":624}}}],"partialFingerprints":{"codehealthFindingId/v1":"1ac333c6916160b369e9abd1dd0ef490a154a8a6dfb9cfd4811b2d86cd201049"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/quantlib/options.py: agent/src/quantlib/options.py changed 5 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 38 in options.barrier_option_price at line 517. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/quantlib/options.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/options.py"},"region":{"startLine":517}}}],"partialFingerprints":{"codehealthFindingId/v1":"b786c3f16ba665a0f483851b853dd004606eec39345a36a37a5c6f2b54eb2604"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/channels/telegram.py: agent/src/channels/telegram.py changed 5 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 37 in TelegramChannel.send_delta at line 937. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/channels/telegram.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/telegram.py"},"region":{"startLine":937}}}],"partialFingerprints":{"codehealthFindingId/v1":"3c8dbc907eea2d0fe8c22ad6ed9bdb1d7e74a64cb3aaee34c86f3c2708b00ed3"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/tools/backtest_tool.py: agent/src/tools/backtest_tool.py changed 10 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 18 in backtest_tool.run_backtest at line 193. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/tools/backtest_tool.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/backtest_tool.py"},"region":{"startLine":193}}}],"partialFingerprints":{"codehealthFindingId/v1":"12e45cc6ab272afb1ce43bff5f9566972b659b3675f2f979454f31bfaf4cec65"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/quantlib/factormodel.py: agent/src/quantlib/factormodel.py changed 9 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 20 in factormodel.factor_risk_decomposition at line 601. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/quantlib/factormodel.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/factormodel.py"},"region":{"startLine":601}}}],"partialFingerprints":{"codehealthFindingId/v1":"8c8da94cd682734f04f5a2e1eebf67a856c02aceafda5dbc91cfd450c97209b0"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/trading/connectors/alpaca/sdk.py: agent/src/trading/connectors/alpaca/sdk.py changed 6 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 30 in sdk.place_order at line 460. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/trading/connectors/alpaca/sdk.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/alpaca/sdk.py"},"region":{"startLine":460}}}],"partialFingerprints":{"codehealthFindingId/v1":"7ed394d87f6bc5f10593fdb7841d8435affe51fcd1597db0cade877ebb0931b7"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/quantlib/crossvalidation.py: agent/src/quantlib/crossvalidation.py changed 9 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 20 in crossvalidation.group_purged_kfold_splits at line 292. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/quantlib/crossvalidation.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/crossvalidation.py"},"region":{"startLine":292}}}],"partialFingerprints":{"codehealthFindingId/v1":"b2f6e3b2d7cb8335372a42ebe2d72c93300e2455ad5a6bd07c6d83c6301f32cb"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/tools/options_chain_tool.py: agent/src/tools/options_chain_tool.py changed 8 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 22 in OptionsChainTool.execute at line 71. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/tools/options_chain_tool.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/options_chain_tool.py"},"region":{"startLine":71}}}],"partialFingerprints":{"codehealthFindingId/v1":"111cab443c5b6b541b228e4082c54e7e7e86ce17a8074fc43e51e782919099fa"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/api/settings_routes.py: agent/src/api/settings_routes.py changed 10 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 17 in settings_routes._build_llm_settings_response at line 203. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/api/settings_routes.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/api/settings_routes.py"},"region":{"startLine":203}}}],"partialFingerprints":{"codehealthFindingId/v1":"75555f671558e1234a7460b4b4c8a1ce58a74cc0d9cdb893875ef9f3c0e60f50"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/tools/quantlib_tool.py: agent/src/tools/quantlib_tool.py changed 10 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 17 in quantlib_tool._encode at line 184. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/tools/quantlib_tool.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/quantlib_tool.py"},"region":{"startLine":184}}}],"partialFingerprints":{"codehealthFindingId/v1":"e30c334160374e7b8670e8d8573023ac5f24172381b2c6ea71183baa20170d5d"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/quantlib/fixedincome.py: agent/src/quantlib/fixedincome.py changed 10 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 17 in fixedincome.fit_yield_curve at line 733. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/quantlib/fixedincome.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/fixedincome.py"},"region":{"startLine":733}}}],"partialFingerprints":{"codehealthFindingId/v1":"328b02b284eac5dad71bd06a49bb58a96979391d906bb355a710999230c011d1"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/api/attribution_core.py: agent/src/api/attribution_core.py changed 6 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 27 in attribution_core._build_attribution_payload at line 776. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/api/attribution_core.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/api/attribution_core.py"},"region":{"startLine":776}}}],"partialFingerprints":{"codehealthFindingId/v1":"482485d49166302b9168f931dc29ac2f03b33b4c3cac2709dfb97d33c3d8a028"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/backtest/loaders/yahoo_client.py: agent/backtest/loaders/yahoo_client.py changed 7 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 22 in yahoo_client._parse_chart at line 221. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/backtest/loaders/yahoo_client.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/yahoo_client.py"},"region":{"startLine":221}}}],"partialFingerprints":{"codehealthFindingId/v1":"6b238c661777a8221381ac04a06fa2bbaa08d701538167f5ec858bdc74bb98ce"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/tools/financial_statements_tool.py: agent/src/tools/financial_statements_tool.py changed 9 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 17 in financial_statements_tool._fetch_yahoo_statement at line 333. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/tools/financial_statements_tool.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/financial_statements_tool.py"},"region":{"startLine":333}}}],"partialFingerprints":{"codehealthFindingId/v1":"780cef4d7ca19672f0beec32c967e1c5e19be3a643ada27d43b5166b4f33945a"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/backtest/run_card.py: agent/backtest/run_card.py changed 6 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 24 in run_card._render_markdown at line 521. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/backtest/run_card.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/run_card.py"},"region":{"startLine":521}}}],"partialFingerprints":{"codehealthFindingId/v1":"c0f9feebfdcb42b8b3d78e1b47086751839efa781e726014bc73f21f631ec232"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/data_gateway/history_router.py: agent/src/data_gateway/history_router.py changed 5 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 28 in history_router.fetch_chunk at line 296. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/data_gateway/history_router.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/data_gateway/history_router.py"},"region":{"startLine":296}}}],"partialFingerprints":{"codehealthFindingId/v1":"ff0140cb7094c8c195e12029683e50da4702acea48b7b59148c548dea2f97918"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/providers/claude_cli.py: agent/src/providers/claude_cli.py changed 7 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 20 in claude_cli._decide at line 377. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/providers/claude_cli.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/providers/claude_cli.py"},"region":{"startLine":377}}}],"partialFingerprints":{"codehealthFindingId/v1":"ccd345dc7c797f00c39bc104b800a5b3bf079d77bb2d9e9748e10dc16549d12b"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/channels/discord.py: agent/src/channels/discord.py changed 7 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 20 in DiscordChannel.send_delta at line 513. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/channels/discord.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/discord.py"},"region":{"startLine":513}}}],"partialFingerprints":{"codehealthFindingId/v1":"3b4543e444b3c64c5568dc22a4f5dac541a0fdbbdf8a598a353d2763748cfcd9"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/portfolio/compatibility.py: agent/src/portfolio/compatibility.py changed 8 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 17 in compatibility.adapt_and_validate_payloads at line 131. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/portfolio/compatibility.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/portfolio/compatibility.py"},"region":{"startLine":131}}}],"partialFingerprints":{"codehealthFindingId/v1":"9ba477b2154ff59f9d2dc9cef15d157b07c40fc0dc334832b0b4b841d1833b2d"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: frontend/src/components/settings/HistoryStorageSettings.tsx: frontend/src/components/settings/HistoryStorageSettings.tsx changed 4 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 33 in HistoryStorageSettings.HistoryStorageSettings at line 9. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- frontend/src/components/settings/HistoryStorageSettings.tsx\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/settings/HistoryStorageSettings.tsx"},"region":{"startLine":9}}}],"partialFingerprints":{"codehealthFindingId/v1":"3fe7ca8e68fd8bbd397f0735a6ce8326d45ac400dbacbb68c43da4444b93e7fa"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/tools/doc_reader_tool.py: agent/src/tools/doc_reader_tool.py changed 6 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 22 in doc_reader_tool._read_pdf at line 133. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/tools/doc_reader_tool.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/doc_reader_tool.py"},"region":{"startLine":133}}}],"partialFingerprints":{"codehealthFindingId/v1":"58fe349f6a19c83734079732d2d2a7df1a34225328c9049a8c5ea5173a4283da"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/strategy_discovery/evidence_harness.py: agent/src/strategy_discovery/evidence_harness.py changed 5 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 26 in evidence_harness.compute_evidence_for_run at line 411. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/strategy_discovery/evidence_harness.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/strategy_discovery/evidence_harness.py"},"region":{"startLine":411}}}],"partialFingerprints":{"codehealthFindingId/v1":"d9912345e2d291965496f6129fc915eac255f8f4c3da2e69408389f1d5555161"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/tools/report_audit_tool.py: agent/src/tools/report_audit_tool.py changed 6 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 21 in report_audit_tool._report_value at line 64. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/tools/report_audit_tool.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/report_audit_tool.py"},"region":{"startLine":64}}}],"partialFingerprints":{"codehealthFindingId/v1":"9d1ec979f91290a273f94e8b5972efbed5103c84acb8ec266222652f1dbc0dca"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/live/pending_action.py: agent/src/live/pending_action.py changed 5 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 25 in PendingAction.validate_evidence at line 161. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/live/pending_action.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/live/pending_action.py"},"region":{"startLine":161}}}],"partialFingerprints":{"codehealthFindingId/v1":"f657fe9bc6ec6de07d66d650ccafb480435dfc35731bf118c00db0ccca8456ea"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: frontend/src/components/options/OptionsChainTable.tsx: frontend/src/components/options/OptionsChainTable.tsx changed 4 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 31 in OptionsChainTable.OptionsChainTable at line 139. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- frontend/src/components/options/OptionsChainTable.tsx\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/options/OptionsChainTable.tsx"},"region":{"startLine":139}}}],"partialFingerprints":{"codehealthFindingId/v1":"e02435dd8dd724bc357f194e219d542c3b86f1e04dd7103199ed0996891f0ec8"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: frontend/src/components/charts/StrategyResearchDashboard.tsx: frontend/src/components/charts/StrategyResearchDashboard.tsx changed 4 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 30 in StrategyResearchDashboard.StrategyResearchDashboard at line 122. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- frontend/src/components/charts/StrategyResearchDashboard.tsx\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/charts/StrategyResearchDashboard.tsx"},"region":{"startLine":122}}}],"partialFingerprints":{"codehealthFindingId/v1":"7b7f7dc1049cad1aa697977317532063961247b24559aa0db4057cfbc58e92eb"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/tools/background_tools.py: agent/src/tools/background_tools.py changed 7 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 17 in BackgroundManager._execute at line 296. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/tools/background_tools.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/background_tools.py"},"region":{"startLine":296}}}],"partialFingerprints":{"codehealthFindingId/v1":"efb8686610415a4a93796953ed11848c4b2cd6f88895cedd6018ee170e360c10"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/tools/web_search_tool.py: agent/src/tools/web_search_tool.py changed 3 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 39 in WebSearchTool.execute at line 175. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/tools/web_search_tool.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/web_search_tool.py"},"region":{"startLine":175}}}],"partialFingerprints":{"codehealthFindingId/v1":"f12e03d4654b88379a4ce6e3b7932d1d204cf894cfd443fcef7e7ec6597bf0a3"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: frontend/src/components/settings/SourcePrioritySettings.tsx: frontend/src/components/settings/SourcePrioritySettings.tsx changed 4 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 29 in SourcePrioritySettings.SourcePrioritySettings at line 24. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- frontend/src/components/settings/SourcePrioritySettings.tsx\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/settings/SourcePrioritySettings.tsx"},"region":{"startLine":24}}}],"partialFingerprints":{"codehealthFindingId/v1":"29ed08d46e1bc11cb7d27e1ffac97f6af3c1de6ee68dd5e37954af12b96bddf2"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/portfolio/config.py: agent/src/portfolio/config.py changed 4 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 29 in config.parse_settings at line 144. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/portfolio/config.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/portfolio/config.py"},"region":{"startLine":144}}}],"partialFingerprints":{"codehealthFindingId/v1":"8b148ead920148d5ce61a622b295d24ba7710b2e631b294f95ea995d70947924"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/tools/swarm_tool.py: agent/src/tools/swarm_tool.py changed 5 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 23 in SwarmTool.execute at line 540. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/tools/swarm_tool.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/swarm_tool.py"},"region":{"startLine":540}}}],"partialFingerprints":{"codehealthFindingId/v1":"80ca7e98ba135bf46eedd703257446892da1c4b03eaa2e1d23a02d382f97f409"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/trading/connections.py: agent/src/trading/connections.py changed 4 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 28 in ConnectionStore._parse at line 356. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/trading/connections.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connections.py"},"region":{"startLine":356}}}],"partialFingerprints":{"codehealthFindingId/v1":"67a4348b3bacc8b4ac39064885cc4a39267f08562e0b235a6f6e0d3bf59eac4c"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/tools/fund_nav_tool.py: agent/src/tools/fund_nav_tool.py changed 5 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 22 in GildataFundNavTool.execute at line 140. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/tools/fund_nav_tool.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/fund_nav_tool.py"},"region":{"startLine":140}}}],"partialFingerprints":{"codehealthFindingId/v1":"85fa79ef79fca503b71cc9f7d101170562f1d51f9bb81ab59dd90a8645392ed4"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/tools/paper_trade/tool.py: agent/src/tools/paper_trade/tool.py changed 3 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 36 in tool._execute_step at line 229. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/tools/paper_trade/tool.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/paper_trade/tool.py"},"region":{"startLine":229}}}],"partialFingerprints":{"codehealthFindingId/v1":"4a0f5339114e32caeafa89f399b035c8607894f7c45daaedc06220fccd4ee224"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/channels/whatsapp.py: agent/src/channels/whatsapp.py changed 3 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 35 in WhatsAppChannel._handle_neonize_message at line 503. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/channels/whatsapp.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/whatsapp.py"},"region":{"startLine":503}}}],"partialFingerprints":{"codehealthFindingId/v1":"146e743c11a1ab4c0010c1a3b59d078e4c8ec98d440dad33e4f487a2cdb05b1b"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/portfolio/store.py: agent/src/portfolio/store.py changed 6 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 17 in PortfolioStore.history at line 143. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/portfolio/store.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/portfolio/store.py"},"region":{"startLine":143}}}],"partialFingerprints":{"codehealthFindingId/v1":"b4097a472687342cdce259db73911514865b71690e4bb048ab5b3f25c2557eb8"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/quantlib/volatility.py: agent/src/quantlib/volatility.py changed 5 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 20 in volatility.implied_volatility_surface at line 279. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/quantlib/volatility.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/volatility.py"},"region":{"startLine":279}}}],"partialFingerprints":{"codehealthFindingId/v1":"799fdbcad61677be4ff5711393d15c8bbeb4ff519c4216abfd4681d031c4e844"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/data_gateway/__main__.py: agent/src/data_gateway/__main__.py changed 6 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 16 in __main__.run_history at line 28. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/data_gateway/__main__.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/data_gateway/__main__.py"},"region":{"startLine":28}}}],"partialFingerprints":{"codehealthFindingId/v1":"00517595d63c9db5c56b38560af8cf3f117deb826fd2973bea9cf5e333487c18"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/tools/history_data_tool.py: agent/src/tools/history_data_tool.py changed 6 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 16 in HistoryDataTool.execute at line 100. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/tools/history_data_tool.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/history_data_tool.py"},"region":{"startLine":100}}}],"partialFingerprints":{"codehealthFindingId/v1":"c1d115310a8201b8fb1668e9337335c1e33c01f8b13c78c2d1c996c068fb91a7"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/trading/connectors/upbit/sdk.py: agent/src/trading/connectors/upbit/sdk.py changed 4 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 23 in sdk.place_order at line 376. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/trading/connectors/upbit/sdk.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/upbit/sdk.py"},"region":{"startLine":376}}}],"partialFingerprints":{"codehealthFindingId/v1":"ecfb3a8cc72ddc901a67039f71b036ba419637ebf73b2ee9cbe5f03814fd6dd2"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/trading/connectors/kis/sdk.py: agent/src/trading/connectors/kis/sdk.py changed 5 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 18 in sdk.cancel_order at line 562. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/trading/connectors/kis/sdk.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/kis/sdk.py"},"region":{"startLine":562}}}],"partialFingerprints":{"codehealthFindingId/v1":"6bd5d0b61d32dd72f579d9ff9009e9f3ba640e572e2cf295f7bbdd85a8076555"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: frontend/src/components/options/StrategyBuilder.tsx: frontend/src/components/options/StrategyBuilder.tsx changed 5 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 17 in StrategyBuilder.StrategyBuilder at line 25. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- frontend/src/components/options/StrategyBuilder.tsx\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/options/StrategyBuilder.tsx"},"region":{"startLine":25}}}],"partialFingerprints":{"codehealthFindingId/v1":"77f006a03aa6df8dcea83f0f2a685c0ce9d467132e3f77fea0acb344e3af76ac"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/factors/registry.py: agent/src/factors/registry.py changed 5 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 17 in Registry.compute at line 325. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/factors/registry.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/registry.py"},"region":{"startLine":325}}}],"partialFingerprints":{"codehealthFindingId/v1":"53c301c463d52ed524e949e41fffdd6b2de76f9fa43b4c7b5f3086cb41a87793"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/tools/options_payoff_tool.py: agent/src/tools/options_payoff_tool.py changed 4 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 21 in OptionsPayoffTool._execute_single at line 203. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/tools/options_payoff_tool.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/options_payoff_tool.py"},"region":{"startLine":203}}}],"partialFingerprints":{"codehealthFindingId/v1":"d394c359d05d8586d424c574be0d1d10c3000e29ae05c1a31ffde464e83ab8fa"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/tools/read_file_tool.py: agent/src/tools/read_file_tool.py changed 3 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 28 in ReadFileTool.execute at line 107. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/tools/read_file_tool.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/read_file_tool.py"},"region":{"startLine":107}}}],"partialFingerprints":{"codehealthFindingId/v1":"4f9c51d0a84fa52cc48eaf5b72d7b9539dfc8e8b867e4c1b2d67913eed5e56b9"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: frontend/src/pages/Runtime.tsx: frontend/src/pages/Runtime.tsx changed 3 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 28 in Runtime.Runtime at line 25. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- frontend/src/pages/Runtime.tsx\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Runtime.tsx"},"region":{"startLine":25}}}],"partialFingerprints":{"codehealthFindingId/v1":"d2a0207375b96f0a97d4c3d34eb0ec1fe09ded1a87f3b480549c463c39104903"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/live/mandate/commit.py: agent/src/live/mandate/commit.py changed 4 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 21 in commit._resolve_profile at line 265. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/live/mandate/commit.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/live/mandate/commit.py"},"region":{"startLine":265}}}],"partialFingerprints":{"codehealthFindingId/v1":"e043b2ff5dec7dc3b0f9c18dd6887312e1a024033c1a937867722a251836643b"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/portfolio/extraetf.py: agent/src/portfolio/extraetf.py changed 5 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 16 in extraetf._parse_decimal at line 787. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/portfolio/extraetf.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/portfolio/extraetf.py"},"region":{"startLine":787}}}],"partialFingerprints":{"codehealthFindingId/v1":"d8bb0f4dc0edf9a3f93e53b648b8c15c2ee79a75c7f77bc55265341a367edc0f"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/backtest/loaders/tushare_fundamentals.py: agent/backtest/loaders/tushare_fundamentals.py changed 3 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 25 in tushare_fundamentals.enrich_price_frames_with_fundamentals at line 313. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/backtest/loaders/tushare_fundamentals.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/tushare_fundamentals.py"},"region":{"startLine":313}}}],"partialFingerprints":{"codehealthFindingId/v1":"8b7e5e22640f28b215da3c3336107eb25dcd3ef0b7385bfc096e53a46b1f945b"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: frontend/src/pages/Correlation.tsx: frontend/src/pages/Correlation.tsx changed 3 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 25 in Correlation.CorrelationAnalysis at line 44. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- frontend/src/pages/Correlation.tsx\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Correlation.tsx"},"region":{"startLine":44}}}],"partialFingerprints":{"codehealthFindingId/v1":"dfb4b5deb5e6db4c6df0525f2359b3aaacc12efb09e3ef5a1adcc7f49ef8a43d"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: frontend/src/components/chat/SwarmStatusCard.tsx: frontend/src/components/chat/SwarmStatusCard.tsx changed 3 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 24 in SwarmStatusCard.SwarmStatusCard at line 182. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- frontend/src/components/chat/SwarmStatusCard.tsx\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/chat/SwarmStatusCard.tsx"},"region":{"startLine":182}}}],"partialFingerprints":{"codehealthFindingId/v1":"d019920d341df4cd074dd5b8eff8052d0b87bcfb2944b356aaf1627d4e9dfa0a"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/quantlib/portfolio.py: agent/src/quantlib/portfolio.py changed 3 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 24 in portfolio.hierarchical_risk_parity at line 102. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/quantlib/portfolio.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/portfolio.py"},"region":{"startLine":102}}}],"partialFingerprints":{"codehealthFindingId/v1":"abeb85b04e3c05c190b93785656fb3f0fa48dcd12df622ca4c8e410cdc04a118"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/evals/harness/assertions.py: agent/evals/harness/assertions.py changed 4 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 17 in assertions._evidence_verdicts at line 456. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/evals/harness/assertions.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/harness/assertions.py"},"region":{"startLine":456}}}],"partialFingerprints":{"codehealthFindingId/v1":"36e3d827cec5d94e0ff747d1bf438c5320f72f833b1c0d7a8363ee62c6e3bd80"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/trading/connectors/dhan/sdk.py: agent/src/trading/connectors/dhan/sdk.py changed 4 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 17 in sdk.place_order at line 439. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/trading/connectors/dhan/sdk.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/dhan/sdk.py"},"region":{"startLine":439}}}],"partialFingerprints":{"codehealthFindingId/v1":"1202f38fc12367648a132f5185d408a888c7db1999cd457d6e11455c45c52c41"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/quantlib/microstructure.py: agent/src/quantlib/microstructure.py changed 4 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 16 in microstructure.vpin at line 132. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/quantlib/microstructure.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/microstructure.py"},"region":{"startLine":132}}}],"partialFingerprints":{"codehealthFindingId/v1":"5ae12ebb288fc93a1fcc5066c1c771614fc808130cc7bd3edeae680951c6d80c"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: frontend/src/components/chat/MessageBubble.tsx: frontend/src/components/chat/MessageBubble.tsx changed 4 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 16 in MessageBubble.MessageBubble at line 204. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- frontend/src/components/chat/MessageBubble.tsx\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/chat/MessageBubble.tsx"},"region":{"startLine":204}}}],"partialFingerprints":{"codehealthFindingId/v1":"4f1fe866f03e698e1cc9fbe932766b4fe33f3774e47abab751a41a6e70f1c92b"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/backtest/loaders/fmp_loader.py: agent/backtest/loaders/fmp_loader.py changed 4 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 16 in fmp_loader._parse_historical at line 220. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/backtest/loaders/fmp_loader.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/fmp_loader.py"},"region":{"startLine":220}}}],"partialFingerprints":{"codehealthFindingId/v1":"e36b947d59344e464483b7d1620a85399cf814f78ddfde8e5a1bfeb625af99ec"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: frontend/src/components/portfolio/PortfolioSourceEditor.tsx: frontend/src/components/portfolio/PortfolioSourceEditor.tsx changed 3 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 20 in PortfolioSourceEditor.PortfolioSourceEditor at line 29. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- frontend/src/components/portfolio/PortfolioSourceEditor.tsx\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/portfolio/PortfolioSourceEditor.tsx"},"region":{"startLine":29}}}],"partialFingerprints":{"codehealthFindingId/v1":"5ea2b7c66fc9e135a8c5e27e3f82451bcf910e71725900ae303e10a054856d52"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/tools/fred_macro_tool.py: agent/src/tools/fred_macro_tool.py changed 3 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 19 in FredMacroTool.execute at line 116. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/tools/fred_macro_tool.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/fred_macro_tool.py"},"region":{"startLine":116}}}],"partialFingerprints":{"codehealthFindingId/v1":"dc4b0ffe1d5fd600851297229b9163a332c3f3c083a983edb60fd7bed2593046"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: desktop/electron/src/main.ts: desktop/electron/src/main.ts changed 3 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 19 in main.installUpdate at line 305. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- desktop/electron/src/main.ts\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"desktop/electron/src/main.ts"},"region":{"startLine":305}}}],"partialFingerprints":{"codehealthFindingId/v1":"ce6e56fd766c930d5bfd84cab4c6f8333036d6ba710a9fbb66cfd810c0f81a7c"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: frontend/src/components/chat/Composer.tsx: frontend/src/components/chat/Composer.tsx changed 3 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 18 in Composer at line 82. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- frontend/src/components/chat/Composer.tsx\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/chat/Composer.tsx"},"region":{"startLine":82}}}],"partialFingerprints":{"codehealthFindingId/v1":"9b9d4f1064ee5ff5c80cc3a7dcdf8c2490cf93f64599acb1e66fdd077c0340cc"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/memory/lifecycle.py: agent/src/memory/lifecycle.py changed 3 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 18 in MemoryLifecycle.run_gc at line 183. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/memory/lifecycle.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/memory/lifecycle.py"},"region":{"startLine":183}}}],"partialFingerprints":{"codehealthFindingId/v1":"847d7932f5493f1f9303e9c6590018a1abcef6679debdd1f97c670d544bd4177"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/backtest/loaders/mt5_loader.py: agent/backtest/loaders/mt5_loader.py changed 3 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 17 in mt5_loader._ensure_initialized at line 77. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/backtest/loaders/mt5_loader.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/mt5_loader.py"},"region":{"startLine":77}}}],"partialFingerprints":{"codehealthFindingId/v1":"12b82cb745d468057e487668ca0bae48f0948906d34f918fc98d7f34de99fcff"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/data_gateway/scans.py: agent/src/data_gateway/scans.py changed 2 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 22 in ScanQueue._run at line 110. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/data_gateway/scans.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/data_gateway/scans.py"},"region":{"startLine":110}}}],"partialFingerprints":{"codehealthFindingId/v1":"43195c8b021a89095a11bbc7d850085e87e2a674a85f819a0157d5f4070d1ffa"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/strategy_discovery/facade.py: agent/src/strategy_discovery/facade.py changed 2 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 21 in StrategyDiscoveryFacade.get_strategy_evidence at line 606. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/strategy_discovery/facade.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/strategy_discovery/facade.py"},"region":{"startLine":606}}}],"partialFingerprints":{"codehealthFindingId/v1":"d057c0f9d4b25cbb2fed655044c32edfd53dd7550b967d7ee89b10a33119da6a"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/scheduled_research/playbooks.py: agent/src/scheduled_research/playbooks.py changed 2 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 21 in ResearchPlaybook.to_job at line 142. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/scheduled_research/playbooks.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/scheduled_research/playbooks.py"},"region":{"startLine":142}}}],"partialFingerprints":{"codehealthFindingId/v1":"5ae15f1d9abbbecd58c6653a8ace94743c0f778052d103ff1e0d94faebdf5dfe"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/data_gateway/reads.py: agent/src/data_gateway/reads.py changed 2 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 19 in reads.read at line 50. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/data_gateway/reads.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/data_gateway/reads.py"},"region":{"startLine":50}}}],"partialFingerprints":{"codehealthFindingId/v1":"5b6162f74e5cbd3e8cecca35aa47bcd8797020b4a7a88825a45e32d31efaeb9a"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: frontend/src/components/chat/ScheduledResearchProposalCard.tsx: frontend/src/components/chat/ScheduledResearchProposalCard.tsx changed 2 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 19 in ScheduledResearchProposalCard.ScheduledResearchProposalCard at line 19. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- frontend/src/components/chat/ScheduledResearchProposalCard.tsx\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/chat/ScheduledResearchProposalCard.tsx"},"region":{"startLine":19}}}],"partialFingerprints":{"codehealthFindingId/v1":"576eaa3ff96db081021de45398a03d65832b683f0f2b3b35687a43899877f0fa"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/quantlib/attribution.py: agent/src/quantlib/attribution.py changed 2 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 18 in attribution.brinson_fachler at line 209. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/quantlib/attribution.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/attribution.py"},"region":{"startLine":209}}}],"partialFingerprints":{"codehealthFindingId/v1":"51d3911cd214e07d839b7cc78a29ad5903b97ddc5d4076b882509eb89c2cbccc"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: tools/gateway_soak_history.py: tools/gateway_soak_history.py changed 2 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 17 in HistoryDriver.route_workload at line 175. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- tools/gateway_soak_history.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"tools/gateway_soak_history.py"},"region":{"startLine":175}}}],"partialFingerprints":{"codehealthFindingId/v1":"61c0e2169de7a9f29a45f3f8282a12c8d194691c4c7e1662759614f3346d1305"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/tools/sdm_decay_scan_tool.py: agent/src/tools/sdm_decay_scan_tool.py changed 2 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 17 in SdmDecayScanTool.execute at line 64. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/tools/sdm_decay_scan_tool.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/sdm_decay_scan_tool.py"},"region":{"startLine":64}}}],"partialFingerprints":{"codehealthFindingId/v1":"fa0d990c3e5fcef89958aee817250c7e70a91b3a6ba6e26b18f5fd0909f38ad3"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/trading/connectors/shoonya/sdk.py: agent/src/trading/connectors/shoonya/sdk.py changed 2 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 16 in sdk.place_order at line 421. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/trading/connectors/shoonya/sdk.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/shoonya/sdk.py"},"region":{"startLine":421}}}],"partialFingerprints":{"codehealthFindingId/v1":"2a4f8eb39131d4f972873ba5f7c0b5174e3736fec39235c8b42d8659bb137348"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: agent/src/factors/compare_runner.py: agent/src/factors/compare_runner.py changed 2 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 16 in compare_runner.compare_alphas at line 88. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/factors/compare_runner.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/compare_runner.py"},"region":{"startLine":88}}}],"partialFingerprints":{"codehealthFindingId/v1":"5894cb04841128a584dd4a1d00d0f9c9a9092d0454cfb94609e490fdba2ca198"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: agent/backtest/engines/_market_hooks.py: agent/backtest/engines/_market_hooks.py changed 33 times in last 90 days and 27 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 12 (its worst body is _market_hooks.calc_crypto_funding_fee at line 522), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix: route Japan data safely and reduce agent acquisition overhead\u201D; \u201Cfix(backtest): recognise bare three-digit Zhengzhou futures codes\u201D; \u201Cfix(backtest): recognise bare codes for every China futures product the engine prices (#2177)\u201D; \u201Cfix(backtest): select and report the benchmark actually evaluated\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/backtest/engines/_market_hooks.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/engines/_market_hooks.py"},"region":{"startLine":522}}}],"partialFingerprints":{"codehealthFindingId/v1":"5c0aa38c2e9b782aced7e7e72bdc2d2537adcd946fca64714a1a8f87a09c3531"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: agent/backtest/loaders/registry.py: agent/backtest/loaders/registry.py changed 33 times in last 90 days and 20 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 12 (its worst body is registry.refresh_source_order_overrides at line 539), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix: route Japan data safely and reduce agent acquisition overhead\u201D; \u201Cfix(gateway): bound source recovery and paced work under mixed load\u201D; \u201Cfix: complete October 11-12 maintenance and research updates\u201D; \u201Cfix(loaders): retire mootdx from the default A-share chain and health canary\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/backtest/loaders/registry.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/registry.py"},"region":{"startLine":539}}}],"partialFingerprints":{"codehealthFindingId/v1":"7219d03b9e6bece85bfafd2cdbac35587ae50d8aac09d8398bb8c8d4671a514d"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: agent/src/agent/context.py: agent/src/agent/context.py changed 24 times in last 90 days and 18 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 7 (its worst body is ContextBuilder.build_messages at line 352), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix: guide generated Python and MCP data reads through gateway\u201D; \u201Cfix(grounding): bind bare integers to exact source quotations\u201D; \u201Cfix(agent): recover from native claude-cli tool attempts\u201D; \u201Cfix: complete October 11-12 maintenance and research updates\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/agent/context.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/agent/context.py"},"region":{"startLine":352}}}],"partialFingerprints":{"codehealthFindingId/v1":"c9afd4277af19833b88601a329f2c2a9ea9d048d36dc0f5656a0fd1773774fcc"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: agent/backtest/engines/global_futures.py: agent/backtest/engines/global_futures.py changed 10 times in last 90 days and 10 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 7 (its worst body is global_futures._extract_product at line 138), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix(backtest): apply the equity-index price limit to MYM and M2K\u201D; \u201Cfix(backtest): report the global futures leverage default\u201D; \u201Cfix: complete review repairs for the ten integrated PRs\u201D; \u201Cfix(backtest): price micro equity-index contracts at the micro rate\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/backtest/engines/global_futures.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/engines/global_futures.py"},"region":{"startLine":138}}}],"partialFingerprints":{"codehealthFindingId/v1":"9f4319a47e79e49fc5f950b29d460cdd7597d34f41c634161e8740dc279588e3"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: agent/backtest/loaders/yfinance_loader.py: agent/backtest/loaders/yfinance_loader.py changed 13 times in last 90 days and 9 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 15 (its worst body is DataLoader.fetch at line 285), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix: route Japan data safely and reduce agent acquisition overhead\u201D; \u201Cfix(gateway): overlap cold market routes and verify exchange calendars\u201D; \u201Cfix: complete October 11-12 maintenance and research updates\u201D; \u201Cfix(loaders): a BYMA line enters the ARS pool only when it is declared ARS (#1576)\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/backtest/loaders/yfinance_loader.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/yfinance_loader.py"},"region":{"startLine":285}}}],"partialFingerprints":{"codehealthFindingId/v1":"6274356d220314dbc0501737f3ca2c05299f2afd00ae15cd2dc1bf59e3f888d8"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: agent/backtest/loaders/yahoo_loader.py: agent/backtest/loaders/yahoo_loader.py changed 12 times in last 90 days and 9 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 7 (its worst body is yahoo_loader._rows_to_frame at line 148), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix: route Japan data safely and reduce agent acquisition overhead\u201D; \u201Cfix(gateway): overlap cold market routes and verify exchange calendars\u201D; \u201Cfix(gateway): bound source recovery and paced work under mixed load\u201D; \u201Cfix: complete October 11-12 maintenance and research updates\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/backtest/loaders/yahoo_loader.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/yahoo_loader.py"},"region":{"startLine":148}}}],"partialFingerprints":{"codehealthFindingId/v1":"1ddba7a85472f7d5b251b0fdbc465c001c7af2a0a7b9ba69da6df8056d3a9043"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: agent/src/shadow_account/backtester.py: agent/src/shadow_account/backtester.py changed 9 times in last 90 days and 9 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 15 (its worst body is backtester.run_shadow_backtest at line 164), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix: correct shadow capital and committee completion contracts\u201D; \u201Cfix(shadow-account): stop the result cache hiding rules and currencies (#2075)\u201D; \u201Cfix(shadow-account): overtrading span uses the true trading window\u201D; \u201Cfix(shadow-account): exclude already explained trades from overtrading pnl\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/shadow_account/backtester.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/shadow_account/backtester.py"},"region":{"startLine":164}}}],"partialFingerprints":{"codehealthFindingId/v1":"9932f4d1f83b9ee2772580d72672710f6d2114b6d5686e61b2017da533a3c9ff"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: agent/src/api/sessions_routes.py: agent/src/api/sessions_routes.py changed 10 times in last 90 days and 8 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 11 (its worst body is sessions_routes._strip_prompt_wrappers at line 56), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix(session): keep deletion retryable when search purge fails\u201D; \u201Cfix(sessions): auto-title sessions whose first message is wrapped\u201D; \u201Cfix(session): preserve live updates while generating conversation titles\u201D; \u201Cfix(session): synchronize renamed conversation titles with search\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/api/sessions_routes.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/api/sessions_routes.py"},"region":{"startLine":56}}}],"partialFingerprints":{"codehealthFindingId/v1":"6b132f0d985f4175f11693621f97d026bfd8b9671ad5b3d40b39a2abcf9a877c"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: agent/src/session/search.py: agent/src/session/search.py changed 8 times in last 90 days and 8 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 15 (its worst body is search._search_snippet at line 44), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix(runtime): preserve Unicode records and handoff summaries\u201D; \u201Cfix(session): keep deletion retryable when search purge fails\u201D; \u201Cfix(session): clear the search index when a session is deleted\u201D; \u201Cfix(session): anchor search snippets to native token matches\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/session/search.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/session/search.py"},"region":{"startLine":44}}}],"partialFingerprints":{"codehealthFindingId/v1":"2d685e16f2b44f40b11c6cfeb94099a3a78017331483c9e5d454ba6ff8ebb7a0"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: agent/src/channels/config_meta.py: agent/src/channels/config_meta.py changed 13 times in last 90 days and 7 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 6 (its worst body is config_meta._derive_hints at line 396), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix(channels): keep redacting url userinfo when the authority has whitespace\u201D; \u201Cfix(channels): strip URL userinfo when the port cannot be parsed\u201D; \u201Cfix(channels): finish trusted email delivery and scheduling workflows\u201D; \u201Cfix(channels): plain IMAP upgrades with STARTTLS before the password goes out\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/channels/config_meta.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/config_meta.py"},"region":{"startLine":396}}}],"partialFingerprints":{"codehealthFindingId/v1":"f0c7223fcb2efe4e5d66dc9658d97c2d1aa9909039958815422f8f3b22110a2c"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: agent/backtest/benchmark.py: agent/backtest/benchmark.py changed 8 times in last 90 days and 7 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 11 (its worst body is benchmark.resolve_benchmark at line 103), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix(backtest): buy the benchmark at the first evaluated open, as the strategy is\u201D; \u201Cfix(backtest): select and report the benchmark actually evaluated\u201D; \u201Cfix(benchmark): give hong kong runs a fetchable 2828.HK benchmark\u201D; \u201Cfix: complete October 11-12 maintenance and research updates\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/backtest/benchmark.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/benchmark.py"},"region":{"startLine":103}}}],"partialFingerprints":{"codehealthFindingId/v1":"ce0d98f64db67f5c005f743fd9f1e0873a7b016a2be74031faf066dea1d85622"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: agent/backtest/loaders/akshare_loader.py: agent/backtest/loaders/akshare_loader.py changed 8 times in last 90 days and 6 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 11 (its worst body is DataLoader.fetch at line 126), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix(akshare): probe both forex symbol-map layouts after akshare 1.20 move\u201D; \u201Cfix(loaders): support Akshare 1.20 forex symbols\u201D; \u201Cfix(loaders): try the amex and nyse arca market id for akshare us bars\u201D; \u201Cfix(loaders): a one-bar plateau at the window edge refuses the conversion\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/backtest/loaders/akshare_loader.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/akshare_loader.py"},"region":{"startLine":126}}}],"partialFingerprints":{"codehealthFindingId/v1":"ee6131a94c48efefc3cfdb44db3b180d8fc7ddf096fb1cf2db73660fd394c5de"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: agent/src/tools/mcp.py: agent/src/tools/mcp.py changed 7 times in last 90 days and 6 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 13 (its worst body is MCPServerAdapter._build_client at line 662), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix: guide generated Python and MCP data reads through gateway\u201D; \u201Cfix(mcp): remove redundant payload copies before agent-context consumption\u201D; \u201Cfix(tools): MCP tool schemas with a malformed properties field no longer lose the properties key entirely\u201D; \u201Cfix(ibkr): support official MCP OAuth and reads\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/tools/mcp.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/mcp.py"},"region":{"startLine":662}}}],"partialFingerprints":{"codehealthFindingId/v1":"1c494349a721a7a7e531a53de8e7041c51f77f6591f1b9aeccd125c1139eaf76"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: frontend/src/components/chat/WelcomeScreen.tsx: frontend/src/components/chat/WelcomeScreen.tsx changed 8 times in last 90 days and 5 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 9 (its worst body is WelcomeScreen.WelcomeScreen at line 255), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix(welcome): lay the welcome screen out for the 768px chat column it renders in\u201D; \u201Cfix(welcome): drop duplicated cards, the thrice-repeated hint and a static counter\u201D; \u201Cfix(welcome): make side-panel examples clickable and label each by its category\u201D; \u201Cfix(welcome): align welcome copy to the reading direction in RTL locales\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- frontend/src/components/chat/WelcomeScreen.tsx\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/chat/WelcomeScreen.tsx"},"region":{"startLine":255}}}],"partialFingerprints":{"codehealthFindingId/v1":"f0109a157f252f4a3e54bd3f029a02d72825c28f7a84b9d253ed1e890b78b772"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: agent/src/quantlib/risk.py: agent/src/quantlib/risk.py changed 7 times in last 90 days and 5 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 13 (its worst body is risk.drawdown_distribution_analysis at line 327), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix: expose exact research calculations through existing tools\u201D; \u201Cfix: preserve research evidence and validate committee risk basis\u201D; \u201Cfix(risk): count drawdown days on the civil calendar\u201D; \u201Cfix(quantlib): preserve exact decimal tail ranks in historical risk (#1950)\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/quantlib/risk.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/risk.py"},"region":{"startLine":327}}}],"partialFingerprints":{"codehealthFindingId/v1":"a9918a8a2dd1f6fb2cd0dc001dc5db232c804fcd9b370b5589b351a37478e4c1"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: agent/src/factors/base.py: agent/src/factors/base.py changed 7 times in last 90 days and 5 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 11 (its worst body is base.zscore_by_group at line 99), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix(factors): use OLS for Qlib BETA and RESI (#2062)\u201D; \u201Cfix(factors): weight the most recent bar heaviest in decay_linear\u201D; \u201Cfix(factors): make ts_argmax/ts_argmin tie-breaking backend-independent\u201D; \u201Cfix(factors): comparison gates stop reading a missing input as a verdict (#1463)\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/factors/base.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/base.py"},"region":{"startLine":99}}}],"partialFingerprints":{"codehealthFindingId/v1":"75e26ef9cb918989b88b6abf66b2c5f800836fbfdd982e677556ffccd1b9b919"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: agent/backtest/engines/crypto.py: agent/backtest/engines/crypto.py changed 7 times in last 90 days and 5 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 9 (its worst body is CryptoEngine._execute_open_order at line 511), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix(backtest): stop default spot funding and honor crypto commission\u201D; \u201Cfix(backtest): mark halted positions at last traded close, not entry cost\u201D; \u201Cfix(backtest): fill liquidation at the adverse mark used for its check (#1291)\u201D; \u201Cfix(backtest): settle perpetual funding by bar span on 8h\u002B intervals\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/backtest/engines/crypto.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/engines/crypto.py"},"region":{"startLine":511}}}],"partialFingerprints":{"codehealthFindingId/v1":"24aff3e25f703ed509e7b4846862a45074461c5d19ee454cb73f5282dee807d5"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: agent/backtest/loaders/baostock_loader.py: agent/backtest/loaders/baostock_loader.py changed 6 times in last 90 days and 5 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 13 (its worst body is baostock_loader._session_admission at line 43), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix: defer unstarted SDK reads and close gateway probe catalogs\u201D; \u201Cfix: preserve scan deadlines across source failures and SDK contention\u201D; \u201Cfix(loaders): preserve bounded BaoStock 0.9.4 connections\u201D; \u201Cfix: complete September 28 reliability reviews and broker documentation\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/backtest/loaders/baostock_loader.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/baostock_loader.py"},"region":{"startLine":43}}}],"partialFingerprints":{"codehealthFindingId/v1":"f5fc625231f4cc4c89b092a5899959fb4ff4d106ad75cfb931f690caf5423a8b"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: agent/src/tools/paper_trade/rules.py: agent/src/tools/paper_trade/rules.py changed 6 times in last 90 days and 5 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 8 (its worst body is MarketRules.band_rejection at line 198), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix(paper-trade): gate volume-share sell overdrafts\u201D; \u201Cfix(paper-trade): version volume-share matching as pt-rules-v5\u201D; \u201Cfix(paper-trade): match symbols on a shared timeline\u201D; \u201Cfix(paper-trade): cancel price-limit market orders (#2176)\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/tools/paper_trade/rules.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/paper_trade/rules.py"},"region":{"startLine":198}}}],"partialFingerprints":{"codehealthFindingId/v1":"2df2c170bab2d545e78262f02320eb10a1e40abf83b27f9224ac49b2ac6034ab"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: agent/src/governance/ledger.py: agent/src/governance/ledger.py changed 5 times in last 90 days and 5 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 9 (its worst body is ledger.append_record at line 369), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix(runtime): preserve Unicode records and handoff summaries\u201D; \u201Cfix: complete review repairs for the ten integrated PRs\u201D; \u201Cfix(governance): verify the whole history before sealing a ledger segment\u201D; \u201Cfix(governance): make archive ledger verification report corruption instead of crashing\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/governance/ledger.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/governance/ledger.py"},"region":{"startLine":369}}}],"partialFingerprints":{"codehealthFindingId/v1":"0a024372abb05fb685f727dbf31dc2af367735b008ad290fdf644654ac47ce93"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: agent/backtest/loaders/stooq_loader.py: agent/backtest/loaders/stooq_loader.py changed 5 times in last 90 days and 5 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 10 (its worst body is stooq_loader._parse_csv at line 268), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix(loaders): ask Stooq for class shares by their hyphenated ticker\u201D; \u201Cfix(loaders): make the stooq latch see every refusal, and probe once\u201D; \u201Cfix(loaders): make the stooq challenge latch stop probing, not just logging\u201D; \u201Cfix(stooq): name the override variable the config layer actually reads\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/backtest/loaders/stooq_loader.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/stooq_loader.py"},"region":{"startLine":268}}}],"partialFingerprints":{"codehealthFindingId/v1":"52fdb36fb965de3c6b974c6e3f2f97e8ffb35cd7addb4760bcfb3eeaf0377b90"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: agent/src/goal/policy.py: agent/src/goal/policy.py changed 5 times in last 90 days and 5 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 3 (its worst body is policy.reject_live_execution_objective at line 60), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix(goal): keep long-term and short-term objectives\u201D; \u201Cfix: complete September 27 reviews and surface verified run-card evidence\u201D; \u201Cfix(goal): reject execution objectives that put the immediacy cue before the verb\u201D; \u201Cfix(goal): an objective that is an order is still refused after #1562\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/goal/policy.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/goal/policy.py"},"region":{"startLine":60}}}],"partialFingerprints":{"codehealthFindingId/v1":"00a204b1dde75cc7876fa68f0bb44499f0f9683e00ead4a9cf705e86e8993d35"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: agent/src/strategy_store/metrics.py: agent/src/strategy_store/metrics.py changed 5 times in last 90 days and 5 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 12 (its worst body is metrics.compute_decay_metrics at line 29), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix(sdm): record bench history so decay monitoring has data to read\u201D; \u201Cfix: finish research prompts and grouped validation boundaries\u201D; \u201Cfix(sdm): stop treating overlapping IC windows as an unchanged ratio\u201D; \u201Cfix(sdm): fix IC ratio sign flip for a negative baseline\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/strategy_store/metrics.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/strategy_store/metrics.py"},"region":{"startLine":29}}}],"partialFingerprints":{"codehealthFindingId/v1":"20bcde3e9f1c0385efabd170596ab931ecfbac723d2e5dec4ce3104e72edf54b"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: agent/src/live/runtime/flatten.py: agent/src/live/runtime/flatten.py changed 5 times in last 90 days and 5 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 11 (its worst body is flatten._flatten_open_positions at line 321), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix(live): stop active attempts and isolate durable schedules\u201D; \u201Cfix(live): harden the preemptive halt sweep against ledger failures and malformed broker records\u201D; \u201Cfix(live): inter-process sweep claim, durable-write audit, nested broker errors\u201D; \u201Cfix(live): reject broker read-error envelopes in the halt sweep\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/live/runtime/flatten.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/live/runtime/flatten.py"},"region":{"startLine":321}}}],"partialFingerprints":{"codehealthFindingId/v1":"1a30db3b61b2424910bab87ad2f1702a0275823dbdf1cb1f2e967ad3b8889c23"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: agent/src/live/runtime/sweep_latch.py: agent/src/live/runtime/sweep_latch.py changed 5 times in last 90 days and 5 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 7 (its worst body is sweep_latch.sweep_already_fired at line 200), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix(live): latch only the swept episodes under per-episode latch files\u201D; \u201Cfix(live): record all active halt episodes; wrap latch write in double-failure branch\u201D; \u201Cfix(live): episode-key the sweep claim \u2014 orphan claims never block future trips\u201D; \u201Cfix(live): inter-process sweep claim, durable-write audit, nested broker errors\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/live/runtime/sweep_latch.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/live/runtime/sweep_latch.py"},"region":{"startLine":200}}}],"partialFingerprints":{"codehealthFindingId/v1":"27a27a445a2a3f64602fda9f31e0637d8cc72e592ab22dd00552e8b9db1d2d67"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: agent/src/data_gateway/routing.py: agent/src/data_gateway/routing.py changed 6 times in last 90 days and 4 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 9 (its worst body is NetworkRouter.recovery_probe at line 86), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix: preserve scan deadlines across source failures and SDK contention\u201D; \u201Cfix(gateway): recover cooldown-only gaps from fresh route evidence\u201D; \u201Cfix(gateway): align skipped-route retries with source recovery deadline\u201D; \u201Cfix(gateway): bound source recovery and paced work under mixed load\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/data_gateway/routing.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/data_gateway/routing.py"},"region":{"startLine":86}}}],"partialFingerprints":{"codehealthFindingId/v1":"6edfc3b58150f753f8abc9c031f130c87edf0bcc73be3f4f2fac020a68b7e5c3"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: agent/src/api/custom_provider_routes.py: agent/src/api/custom_provider_routes.py changed 6 times in last 90 days and 4 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 3 (its worst body is custom_provider_routes._prune_tests at line 43), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix(providers): preserve Copilot credentials across all invocation paths\u201D; \u201Crefactor(providers): consolidate regression fixtures and remove forwarding helpers\u201D; \u201Cfix(providers): re-check custom endpoints on every connection\u201D; \u201Cfix: close pre-release audit findings for 0.1.17\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/api/custom_provider_routes.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/api/custom_provider_routes.py"},"region":{"startLine":43}}}],"partialFingerprints":{"codehealthFindingId/v1":"7a6edf62a31e61dd657d945abbd7acf37edf08c70cde14d01aa553c86a64dd2e"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: agent/backtest/engines/global_equity.py: agent/backtest/engines/global_equity.py changed 6 times in last 90 days and 4 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 9 (its worst body is GlobalEquityEngine.apply_slippage at line 228), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix: preserve research evidence and validate committee risk basis\u201D; \u201Cfix(backtest): disclose lot assumptions and reuse aligned calendar mappings\u201D; \u201Cfix(uk): apply whole-share and slippage rules\u201D; \u201Cfix(equity): SDRT buy-side detection on position-side close path\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/backtest/engines/global_equity.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/engines/global_equity.py"},"region":{"startLine":228}}}],"partialFingerprints":{"codehealthFindingId/v1":"955a82c88340295b3e90b91bd77b1f53fb7776db71b2e547e17f42bb072378fa"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: agent/src/tools/shareholder_count_tool.py: agent/src/tools/shareholder_count_tool.py changed 5 times in last 90 days and 4 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 15 (its worst body is ShareholderCountTool.execute at line 85), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix(tools): block trades, margin and statements stop reading a rejected query as no data\u201D; \u201Cfix(tools): shareholder-count history says when the latest join fails (#1518)\u201D; \u201Cfix(tools): serve shareholder-count history from the per-period report\u201D; \u201Cfix(tools): get_shareholder_count called a report column that no longer exists\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/tools/shareholder_count_tool.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/shareholder_count_tool.py"},"region":{"startLine":85}}}],"partialFingerprints":{"codehealthFindingId/v1":"bd8743c17c502ea7ec63bd32090715c17face8413421eced8a8c0c9cd04445f7"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: agent/src/swarm/store.py: agent/src/swarm/store.py changed 5 times in last 90 days and 4 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 9 (its worst body is SwarmStore.reconcile_run at line 395), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix(swarm): preserve Unicode heartbeat liveness\u201D; \u201Cfix: validate swarm tails precisely and exercise Matrix optional dependency path\u201D; \u201Cfix(swarm): tolerate a half-written final line in read_events\u201D; \u201Cfix(swarm): stop concurrent SwarmStore writers from clobbering run state\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/swarm/store.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/swarm/store.py"},"region":{"startLine":395}}}],"partialFingerprints":{"codehealthFindingId/v1":"260febdf67d786c36f2e6287d85445b23719619f3667c8d91b67b6a3cee4a4cc"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: agent/backtest/risk_xray.py: agent/backtest/risk_xray.py changed 5 times in last 90 days and 4 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 12 (its worst body is risk_xray.compute_risk_xray at line 94), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix(risk): preserve signed exposure in long-short backtest reports\u201D; \u201Cfix(risk-xray): measure downside deviation as zero-target RMS over all bars\u201D; \u201Cfix: Compute risk-xray returns before calendar alignment so missing prices cannot fabricate multi-bar one-period returns.\u201D; \u201Cfix(risk-xray): honor bars_per_year=None in cross-market annualization\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/backtest/risk_xray.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/risk_xray.py"},"region":{"startLine":94}}}],"partialFingerprints":{"codehealthFindingId/v1":"e42a7cadfaf7c04d16b4f726eef77326ca871c2aa0003244f8d286a1a5c6eff8"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: agent/src/api/live_routes.py: agent/src/api/live_routes.py changed 5 times in last 90 days and 4 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 15 (its worst body is live_routes._fetch_broker_ceilings at line 418), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix(live): bound model spending and isolate decision context (#1854)\u201D; \u201Cfix(live): stop active attempts and isolate durable schedules\u201D; \u201Cfix(live): keep the runner driver alive for the scheduler\u0027s lifetime\u201D; \u201Cfix(live): latch the halt sweep on attempted side effects, not on reads succeeding\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/api/live_routes.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/api/live_routes.py"},"region":{"startLine":418}}}],"partialFingerprints":{"codehealthFindingId/v1":"90ecbeebc61882367a32763b07c69bc9391e841234c7a4ad1b9fcf8dc70c5418"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: agent/backtest/loaders/acquisition.py: agent/backtest/loaders/acquisition.py changed 4 times in last 90 days and 4 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 3 (its worst body is acquisition.remaining_timeout at line 18), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix: defer unstarted SDK reads and close gateway probe catalogs\u201D; \u201Cfix: preserve scan deadlines across source failures and SDK contention\u201D; \u201Cfix(gateway): isolate inherited heavy SDKs and enforce source deadlines\u201D; \u201Cfix(gateway): bound source recovery and paced work under mixed load\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/backtest/loaders/acquisition.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/acquisition.py"},"region":{"startLine":18}}}],"partialFingerprints":{"codehealthFindingId/v1":"7f6e2f19338086bee84176d5877a7a89965f48daa28174b1a259c6b18ade3627"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: agent/src/agent/resolution_context.py: agent/src/agent/resolution_context.py changed 4 times in last 90 days and 4 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 10 (its worst body is resolution_context._extract_market_constraints at line 218), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix: report absent numeric diagnostics as unevaluated for current runs\u201D; \u201Cfix(agent): stop reading a ticker\u0027s last letter as an A-share or A/H constraint\u201D; \u201Cfix(grounding): identity and symbol search know every market the data layer routes (#1565)\u201D; \u201Cfix(grounding): add Argentina listing identity\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/agent/resolution_context.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/agent/resolution_context.py"},"region":{"startLine":218}}}],"partialFingerprints":{"codehealthFindingId/v1":"628ada1b670f33833027018939cf18f2b7101ad7cc495818965a6b4d0d6cd14e"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: agent/src/tools/portfolio_risk_tool.py: agent/src/tools/portfolio_risk_tool.py changed 4 times in last 90 days and 4 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 11 (its worst body is PortfolioRiskXrayTool._run at line 98), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix(risk): preserve signed exposure in long-short backtest reports\u201D; \u201Cfix(risk): complete monthly history and turnover lifecycle guards\u201D; \u201Cfix(portfolio): annualize weekly and monthly risk bars correctly\u201D; \u201Cfix(portfolio): fetch full history in risk x-ray instead of sampled rows\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/tools/portfolio_risk_tool.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/portfolio_risk_tool.py"},"region":{"startLine":98}}}],"partialFingerprints":{"codehealthFindingId/v1":"e14b734ce7026b762bbcd0117659382519f34cd60034947e88e262cb93ca734a"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: agent/src/tools/path_utils.py: agent/src/tools/path_utils.py changed 4 times in last 90 days and 4 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 11 (its worst body is path_utils.resolve_safe_path at line 214), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix(tools): resolve fallback paths against a checked run directory\u201D; \u201Cfix(mcp): read .env in the MCP server, after the shell-tool decision\u201D; \u201Cfix: complete eight user blocker fixes and report delivery\u201D; \u201Cfix(tools): name the write-roots escape hatch in file-tool rejections\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/tools/path_utils.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/path_utils.py"},"region":{"startLine":214}}}],"partialFingerprints":{"codehealthFindingId/v1":"e15e18c71b2747c85def49eacb37c45e800971de08973cb62101f590afd4bb71"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: agent/backtest/engines/china_a.py: agent/backtest/engines/china_a.py changed 4 times in last 90 days and 4 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 8 (its worst body is china_a._blocked_by_limit at line 103), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix(china-a): size STAR Market and Beijing buys on their own order grid\u201D; \u201Cfix: preserve financial precision and invalidate stale portfolio aggregates\u201D; \u201Cfix(china-a): apply board price limits to 301, 689 and Beijing 920 codes\u201D; \u201Cfix(backtest): enforce A-share and India rules through composite state\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/backtest/engines/china_a.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/engines/china_a.py"},"region":{"startLine":103}}}],"partialFingerprints":{"codehealthFindingId/v1":"b668a3e99c50a1fef4f8f9dba547c5289ba618867e05694d7fbd6ba9651d04fe"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: agent/backtest/loaders/tiingo_loader.py: agent/backtest/loaders/tiingo_loader.py changed 4 times in last 90 days and 4 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 12 (its worst body is tiingo_loader._rows_to_frame at line 164), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix(loaders): ask Tiingo for class shares by their hyphenated ticker\u201D; \u201Cfix: complete eight user blocker fixes and report delivery\u201D; \u201Cfix(loaders): never mix adjusted and raw prices in one series\u201D; \u201Cfix(loaders): serve adjusted prices on FMP and Tiingo paths\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/backtest/loaders/tiingo_loader.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/tiingo_loader.py"},"region":{"startLine":164}}}],"partialFingerprints":{"codehealthFindingId/v1":"bd02e8575dc42a80a29bd0a745d8c9dcc9b59377e0a9e9e13c187444d02b117a"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: agent/src/trading/connectors/zerodha/sdk.py: agent/src/trading/connectors/zerodha/sdk.py changed 4 times in last 90 days and 4 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 11 (its worst body is sdk.get_historical_bars at line 293), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix(trading): reject fractional quantities in zerodha and shoonya paper orders\u201D; \u201Cfix(trading): a simulated paper cancel only acknowledges orders the simulator issued\u201D; \u201Cfix(broker): declare [zerodha] extra and point install hints at it\u201D; \u201Cfix(broker): zerodha review hardening \u2014 tz-correct day bars, 4h fail-closed, interval-aware pagination, cred-gated availability, cached instruments, service-layer surface\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/trading/connectors/zerodha/sdk.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/zerodha/sdk.py"},"region":{"startLine":293}}}],"partialFingerprints":{"codehealthFindingId/v1":"24c937c1c569467498c5e14a42a031b3e7eac47f0f57157ef3b5cf75b10f5486"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: agent/backtest/regime.py: agent/backtest/regime.py changed 4 times in last 90 days and 4 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 8 (its worst body is regime.detect_regimes at line 60), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix(correlation): align closes before taking returns across calendars\u201D; \u201CFix analysis data fallback and recoverable research workflows\u201D; \u201Cfix: Keep correlation density unknown when constant or missing series make asset pairs unmeasurable.\u201D; \u201Cfix: Align daily correlation and regime bars by each source local calendar date before joining.\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/backtest/regime.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/regime.py"},"region":{"startLine":60}}}],"partialFingerprints":{"codehealthFindingId/v1":"cbfe8c48d626da2e0f7128ad0e6a73cd661f2e8ffbfe23826b0aee79c6bd6a1f"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: agent/src/tools/tushare_fallbacks.py: agent/src/tools/tushare_fallbacks.py changed 4 times in last 90 days and 4 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 11 (its worst body is tushare_fallbacks._ts_code at line 91), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix(fund-flow): preserve source and bucket semantics on fallback (#1954)\u201D; \u201Cfix(symbols): resolve Beijing 920/4/8 codes to .BJ in search and Tushare fallback\u201D; \u201Cfix(tools): separate northbound turnover after disclosure cutover\u201D; \u201Cfix(tools): northbound flow stops serving a silent empty envelope off a dead feed\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/tools/tushare_fallbacks.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/tushare_fallbacks.py"},"region":{"startLine":91}}}],"partialFingerprints":{"codehealthFindingId/v1":"3b28813af7e48f1aaca944df309aaf635fecb966d1d2674d196960a19f03214b"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: agent/backtest/loaders/local_loader.py: agent/backtest/loaders/local_loader.py changed 4 times in last 90 days and 4 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 15 (its worst body is DataLoader._fetch_one at line 355), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix(loaders): refresh local source revisions in bounded cache entries\u201D; \u201Cfix(loaders): let indexed Parquet bars load under a configured date_format\u201D; \u201Cfix(loaders): include fractional seconds on the end day\u201D; \u201Cfix(loaders): scope local caches to source declarations\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/backtest/loaders/local_loader.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/local_loader.py"},"region":{"startLine":355}}}],"partialFingerprints":{"codehealthFindingId/v1":"400583f6ae20685cf6649be3e614cc9a0267d3d1a6a1595109d95a775c522ba1"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: agent/src/tools/skill_writer_tool.py: agent/src/tools/skill_writer_tool.py changed 4 times in last 90 days and 4 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 11 (its worst body is SkillFileTool._remove_file at line 384), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix: close reviewed tool identity and credential redaction edge cases\u201D; \u201Cfix(agent): keep saved skill frontmatter name in sync with its slug\u201D; \u201Cfix(tools): fit structured evidence to consumer limits and file boundaries\u201D; \u201Cfix(tools): skill remove_file restricted to the same subdirs write_file allows\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/tools/skill_writer_tool.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/skill_writer_tool.py"},"region":{"startLine":384}}}],"partialFingerprints":{"codehealthFindingId/v1":"0554080c73d144985f26ffc1b4554f6dee17f938e528c97443923f66315edf2f"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: agent/src/quantlib/copula.py: agent/src/quantlib/copula.py changed 4 times in last 90 days and 4 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 11 (its worst body is copula.fit_copula_from_tau at line 211), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix(quantlib): handle Gaussian copula correlations near their limits\u201D; \u201Cfix(quantlib): preserve ties in copula pseudo-observations\u201D; \u201Cfix(quantlib): make the Frank copula stable at both ends of theta\u201D; \u201Cfix(quantlib): stabilize Archimedean copula CDFs under large parameters\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/quantlib/copula.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/copula.py"},"region":{"startLine":211}}}],"partialFingerprints":{"codehealthFindingId/v1":"7b46df0a299a2602aec199357ab3263aea06a4d94800ee0a7844ccee48f57e53"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: agent/backtest/optimizers/base.py: agent/backtest/optimizers/base.py changed 4 times in last 90 days and 4 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 11 (its worst body is BaseOptimizer.optimize at line 36), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix(risk): complete monthly history and turnover lifecycle guards\u201D; \u201Cfix(optimizers): price turnover from signed position changes\u201D; \u201Cfix(backtest): optimizers see the window in position space, so shorts hedge (#1548)\u201D; \u201Cfix(backtest): size short positions by their own expected return\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/backtest/optimizers/base.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/optimizers/base.py"},"region":{"startLine":36}}}],"partialFingerprints":{"codehealthFindingId/v1":"7407430209984ada541b5804355ee22537cbe3dd2f446ca3918467302a6a8a29"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: agent/src/agent/tool_progress.py: agent/src/agent/tool_progress.py changed 4 times in last 90 days and 4 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 9 (its worst body is ToolProgress.record at line 78), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix(agent): size context compaction to the model\u0027s real window\u201D; \u201Cfix(agent): preserve no-progress recovery detail\u201D; \u201Cfix(agent): bound readonly replay after compaction\u201D; \u201Cfix(agent): refuse an identical call on its second failure, not its first\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/agent/tool_progress.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/agent/tool_progress.py"},"region":{"startLine":78}}}],"partialFingerprints":{"codehealthFindingId/v1":"acf81c11efc348858b1d68a75ef7a297253622969b1a967c6662bbb182e7a6b7"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: agent/src/trading/connectors/toss/sdk.py: agent/src/trading/connectors/toss/sdk.py changed 4 times in last 90 days and 4 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 12 (its worst body is sdk._access_token at line 449), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix(toss): a hasNext page without a cursor is an error, not the last page\u201D; \u201Cfix(toss): page CLOSED order history to completion, fail loud past the cap\u201D; \u201Cfix(toss): match the real /orders and /holdings schemas from the spec\u201D; \u201Cfix(toss): correct the read paths, response envelope, and candle param on #1409\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/trading/connectors/toss/sdk.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/toss/sdk.py"},"region":{"startLine":449}}}],"partialFingerprints":{"codehealthFindingId/v1":"f05709c1256dd8b017768b30bfd4aa34c4d3e35dab5a1e395c51b2af240240c6"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: agent/src/live/daily_count.py: agent/src/live/daily_count.py changed 4 times in last 90 days and 4 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 14 (its worst body is daily_count.increment_daily_count at line 125), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix(windows): cross-platform locks, path handling, and test robustness\u201D; \u201Cfix(live): reject malformed recovery counters\u201D; \u201Cfix(live): close exact recovery restart gaps\u201D; \u201Cfix(live): recover Alpaca submits by exact identity\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/live/daily_count.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/live/daily_count.py"},"region":{"startLine":125}}}],"partialFingerprints":{"codehealthFindingId/v1":"e89e40e1941281912fd2a84fe7e6b35bfe030fd0b063138f174f36b3d8a2b125"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: agent/src/factors/zoo/gtja191/alpha_017.py: agent/src/factors/zoo/gtja191/alpha_017.py changed 5 times in last 90 days and 3 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 1 (its worst body is alpha_017.compute at line 38), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix(factors): keep GTJA #17 missing while either power operand is missing\u201D; \u201Cfix(factors): raise GTJA #17 to the signed 5-day close change\u201D; \u201Cfix(factors): route GTJA VWAP through base.vwap so Tushare units scale\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/factors/zoo/gtja191/alpha_017.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/zoo/gtja191/alpha_017.py"},"region":{"startLine":38}}}],"partialFingerprints":{"codehealthFindingId/v1":"46c2502af174f997407e961bbba2d6a218e3d47e9cc86a04e717958026cca0aa"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: agent/src/strategy_store/sqlite_store.py: agent/src/strategy_store/sqlite_store.py changed 5 times in last 90 days and 3 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 7 (its worst body is SqliteStrategyStore.register_artifact at line 378), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix(sdm): deduplicate copied bench measurements atomically\u201D; \u201Cfix(sdm): record bench history so decay monitoring has data to read\u201D; \u201Cfix(strategy_store): break created_at ties so history is really newest first\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/strategy_store/sqlite_store.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/strategy_store/sqlite_store.py"},"region":{"startLine":378}}}],"partialFingerprints":{"codehealthFindingId/v1":"7da310048f51c7aa5bef41a2e93a25c16b30f96f0b81a0f765cf34385a82bd6c"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: agent/src/live/runtime/triggers.py: agent/src/live/runtime/triggers.py changed 5 times in last 90 days and 3 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 9 (its worst body is triggers.due_now at line 311), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix(live): close the us_equity session at the early bell on half-days\u201D; \u201Cfix: finish numeric boundaries, replay coverage and Trigger inheritance\u201D; \u201Cfix(live): restore the market field default on non-market triggers\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/live/runtime/triggers.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/live/runtime/triggers.py"},"region":{"startLine":311}}}],"partialFingerprints":{"codehealthFindingId/v1":"1c1c578f0301b3db92d09cebe69c3e2fc24223720f7b154e7edd75018313cce1"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: agent/src/tools/dragon_tiger_tool.py: agent/src/tools/dragon_tiger_tool.py changed 4 times in last 90 days and 3 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 8 (its worst body is DragonTigerTool.execute at line 224), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix(tools): block trades, margin and statements stop reading a rejected query as no data\u201D; \u201Cfix(tools): dragon-tiger seats rank within each listing reason (#1512)\u201D; \u201Cfix(tools): restore dragon-tiger seat reports\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/tools/dragon_tiger_tool.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/dragon_tiger_tool.py"},"region":{"startLine":224}}}],"partialFingerprints":{"codehealthFindingId/v1":"cbcff16242958388dc2b4ff114b798a16d1df39eeda2c128c1244c4353c7a950"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: agent/src/tools/lockup_expiry_tool.py: agent/src/tools/lockup_expiry_tool.py changed 4 times in last 90 days and 3 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 8 (its worst body is lockup_expiry_tool.get_lockup_expiry at line 241), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix(tools): block trades, margin and statements stop reading a rejected query as no data\u201D; \u201Cfix(tools): lockup free_shares is the unlock, not the float (#1513)\u201D; \u201Cfix(tools): repair lockup expiry report handling\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/tools/lockup_expiry_tool.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/lockup_expiry_tool.py"},"region":{"startLine":241}}}],"partialFingerprints":{"codehealthFindingId/v1":"f618624198aa8e28a6a8e6a26eece0d3b29f5248244267a795e3dccc53ad5393"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: agent/backtest/engines/china_futures.py: agent/backtest/engines/china_futures.py changed 4 times in last 90 days and 3 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 5 (its worst body is ChinaFuturesEngine.can_execute at line 245), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix(backtest): charge the 30-year treasury future the treasury fee\u201D; \u201Cfix(backtest): fold china futures product casing at extraction, not per lookup\u201D; \u201Cfix(backtest): match china futures product codes case-insensitively\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/backtest/engines/china_futures.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/engines/china_futures.py"},"region":{"startLine":245}}}],"partialFingerprints":{"codehealthFindingId/v1":"970ffe1106e083d73b8e9f1c0e830159bf1d0409763824fafdd15f983a6e23c7"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: agent/src/api/alpha_routes.py: agent/src/api/alpha_routes.py changed 4 times in last 90 days and 3 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 8 (its worst body is alpha_routes._run_bench_blocking at line 264), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix(api): treat whitespace-only TUSHARE_TOKEN as unconfigured in alpha readiness\u201D; \u201Cfix(api): read TUSHARE_TOKEN via the config accessor in alpha readiness\u201D; \u201CFix analysis data fallback and recoverable research workflows\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/api/alpha_routes.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/api/alpha_routes.py"},"region":{"startLine":264}}}],"partialFingerprints":{"codehealthFindingId/v1":"fac6f3b53386ada20b3ec382d259638d748055e4c0bd7c3a70b93c596ae384d3"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: agent/src/shadow_account/extractor.py: agent/src/shadow_account/extractor.py changed 4 times in last 90 days and 3 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 9 (its worst body is extractor._extract_rules at line 329), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix: finish research prompts and grouped validation boundaries\u201D; \u201Cfix(shadow-account): seed Wilder RSI with a simple average, not the first observation\u201D; \u201Cfix(shadow-account): use true Wilder recursive smoothing for RSI\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/shadow_account/extractor.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/shadow_account/extractor.py"},"region":{"startLine":329}}}],"partialFingerprints":{"codehealthFindingId/v1":"3ae8062957e25c9e71b1ed676743979be0fcf4456cbfb31546604a8c04c2fd01"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: agent/src/live/order_guard.py: agent/src/live/order_guard.py changed 4 times in last 90 days and 3 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 14 (its worst body is LiveOrderGuardTool.execute at line 134), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix(live): size MCP buy-limit orders at the worse of quote and limit\u201D; \u201Cfix(live): keep asset_class through the order-guard notional rebuild\u201D; \u201Cfix(live): size buy-limit orders at the worse of quote and limit\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/live/order_guard.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/live/order_guard.py"},"region":{"startLine":134}}}],"partialFingerprints":{"codehealthFindingId/v1":"73a7a996a1bc85c68e28c78be794c1f0308d52c25418d3a0d26c3beaaa8a60a5"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: agent/src/tools/bash_tool.py: agent/src/tools/bash_tool.py changed 3 times in last 90 days and 3 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 13 (its worst body is BashTool.execute at line 83), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix: guide generated Python and MCP data reads through gateway\u201D; \u201Cfix(agent): allow heredoc commands in the bash tool on posix hosts\u201D; \u201Cfix(agent): stall watchdog, bash tree-kill timeout, compaction verification ledger\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/tools/bash_tool.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/bash_tool.py"},"region":{"startLine":83}}}],"partialFingerprints":{"codehealthFindingId/v1":"6fe8a464e2c99c1ca6ae0efd1c95895085c470e622145d3c62b61b7b86abe1aa"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: agent/backtest/loaders/rsshub_events.py: agent/backtest/loaders/rsshub_events.py changed 3 times in last 90 days and 3 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 10 (its worst body is rsshub_events.enrich_price_frames_with_events at line 528), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix: close data gateway bypasses across consumers and skills\u201D; \u201Cfix(events): preserve share-class dots in configured RSS routes\u201D; \u201Cfix(events): preserve daily calendar keys with timezone-aware inputs\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/backtest/loaders/rsshub_events.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/rsshub_events.py"},"region":{"startLine":528}}}],"partialFingerprints":{"codehealthFindingId/v1":"b1e38feccc973b5758766e99482103b1c3a2d16cae7ae22a05268f3e020f3767"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: agent/backtest/loaders/tushare.py: agent/backtest/loaders/tushare.py changed 3 times in last 90 days and 3 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 14 (its worst body is DataLoader._fetch_minutes at line 333), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix: close data gateway bypasses across consumers and skills\u201D; \u201Cfix(loaders): report tushare minute volume in the declared board lots\u201D; \u201Cfix(loaders): serve futures from a chain that implements them\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/backtest/loaders/tushare.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/tushare.py"},"region":{"startLine":333}}}],"partialFingerprints":{"codehealthFindingId/v1":"82328328c3897b4e3ce0482db0c661efc088c2d047d0bb6bea320df0ec60dd37"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: agent/src/quantlib/valuation/comps.py: agent/src/quantlib/valuation/comps.py changed 3 times in last 90 days and 3 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 7 (its worst body is comps.calendarise_metric at line 231), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix(comps): reject a non-finite target book value\u201D; \u201Cfix(quantlib): refuse negative comps bridge magnitudes\u201D; \u201Cfix(valuation): refuse non-finite comps and three-statement inputs\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/quantlib/valuation/comps.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/valuation/comps.py"},"region":{"startLine":231}}}],"partialFingerprints":{"codehealthFindingId/v1":"b6c4d487652882a7828a04a6c909945395b87a1d4e92cdd1a88451eb627ed68a"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: agent/src/shadow_account/models.py: agent/src/shadow_account/models.py changed 3 times in last 90 days and 3 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 1 (its worst body is ShadowProfile.to_dict at line 122), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix(shadow-account): honour every documented entry condition in the engine\u201D; \u201Cfix(shadow): scope attribution to the pool currency and make buckets exclusive\u201D; \u201Cfix(shadow): derive shadow PnL from runner metrics, fail closed when unknown\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/shadow_account/models.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/shadow_account/models.py"},"region":{"startLine":122}}}],"partialFingerprints":{"codehealthFindingId/v1":"e60bdeaebc7d3a5ba27f002a0aa32bbfd27df0453af361b35294ab8e34046693"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: agent/src/tools/autopilot_tool.py: agent/src/tools/autopilot_tool.py changed 3 times in last 90 days and 3 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 14 (its worst body is LinkAutopilotBacktestTool.execute at line 579), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix(tools): reject ambiguous boolean flags before changing state\u201D; \u201Cfix(config): honor VIBE_TRADING_HOME for autopilot runs, alpha-bench cache/reports and gildata codes\u201D; \u201Cfix(autopilot): surface run_card validation evidence in link_autopilot_backtest\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/tools/autopilot_tool.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/autopilot_tool.py"},"region":{"startLine":579}}}],"partialFingerprints":{"codehealthFindingId/v1":"51e88768e913acfc0461514ebd93f26a128aca6604673263c4372107b4038e47"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: agent/backtest/engines/india_equity.py: agent/backtest/engines/india_equity.py changed 3 times in last 90 days and 3 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 11 (its worst body is india_equity.india_can_execute at line 128), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix(backtest): charge india stamp duty on the buy side of a short\u201D; \u201Cfix(backtest): India engine checks the right circuit band when covering a short\u201D; \u201Cfix(backtest): enforce A-share and India rules through composite state\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/backtest/engines/india_equity.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/engines/india_equity.py"},"region":{"startLine":128}}}],"partialFingerprints":{"codehealthFindingId/v1":"3292bf7cfc31cd3d283da53add638212726bb9572e95c87b3e9834202be0a3a6"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: agent/src/api/uploads_routes.py: agent/src/api/uploads_routes.py changed 3 times in last 90 days and 3 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 4 (its worst body is uploads_routes.register_uploads_routes at line 79), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix(api): remove unpublished uploads when cancelled (#1945)\u201D; \u201Cfix(api): serve shadow reports from the configured runtime root\u201D; \u201Cfix: complete eight user blocker fixes and report delivery\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/api/uploads_routes.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/api/uploads_routes.py"},"region":{"startLine":79}}}],"partialFingerprints":{"codehealthFindingId/v1":"e81d55c57a7e374c6d0c05f7d77f4af95494572b16267f7d2c1255102ee4d23d"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: agent/src/tools/pattern_tool.py: agent/src/tools/pattern_tool.py changed 3 times in last 90 days and 3 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 14 (its worst body is PatternTool.execute at line 412), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix(pattern): return a JSON error for malformed tool arguments instead of raising (#1923)\u201D; \u201Cfix(pattern): report a flat top or bottom as one extremum\u201D; \u201Cfix(pattern-tool): use abs average in head and shoulders symmetry check\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/tools/pattern_tool.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/pattern_tool.py"},"region":{"startLine":412}}}],"partialFingerprints":{"codehealthFindingId/v1":"145828a7faf36aa48aef7ddc5f7eb42cf4733087e9365af87aa43f4cc6998928"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: agent/src/memory/search_index.py: agent/src/memory/search_index.py changed 3 times in last 90 days and 3 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 11 (its worst body is search_index._merge_cjk_group at line 88), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix(memory): honor VIBE_TRADING_HOME for persistent memory and search index\u201D; \u201Cfix(tools): fit structured evidence to consumer limits and file boundaries\u201D; \u201Cfix: make the memory search snippet and CJK titles read back clean\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/memory/search_index.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/memory/search_index.py"},"region":{"startLine":88}}}],"partialFingerprints":{"codehealthFindingId/v1":"396217d855a62cdf17bd8fc784e8864eccc89335cc743010ea2eebc3be723ec7"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: agent/src/strategy_store/store.py: agent/src/strategy_store/store.py changed 3 times in last 90 days and 3 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 8 (its worst body is InMemoryStrategyStore.list_artifacts at line 226), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix(sdm): deduplicate copied bench measurements atomically\u201D; \u201Cfix(sdm): record bench history so decay monitoring has data to read\u201D; \u201Cfix(strategy_store): break created_at ties so history is really newest first\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/strategy_store/store.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/strategy_store/store.py"},"region":{"startLine":226}}}],"partialFingerprints":{"codehealthFindingId/v1":"53e5a415ff51d64096324bd53859627e60ca76fc16fa2d9d48e6e40294b75725"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: agent/src/tools/shadow_account_tool.py: agent/src/tools/shadow_account_tool.py changed 3 times in last 90 days and 3 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 10 (its worst body is RenderShadowReportTool.execute at line 270), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix: complete eight user blocker fixes and report delivery\u201D; \u201Cfix(shadow): key the result cache by window and journal hash, not shadow alone\u201D; \u201Cfix(shadow): derive shadow PnL from runner metrics, fail closed when unknown\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/tools/shadow_account_tool.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/shadow_account_tool.py"},"region":{"startLine":270}}}],"partialFingerprints":{"codehealthFindingId/v1":"3eb62c618334400b894f81aeb77c61bdc21491b8ba9f9e3cc45fe5335c55792f"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: agent/backtest/rebalance_mask.py: agent/backtest/rebalance_mask.py changed 3 times in last 90 days and 3 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 13 (its worst body is rebalance_mask.resolve_rebalance_dates at line 47), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix(backtest): rebalance mask works with non-nanosecond dates\u201D; \u201Cfix(backtest): bound non-fixed rebalance aliases\u201D; \u201Cfix(backtest): harden scheduled rebalancing\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/backtest/rebalance_mask.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/rebalance_mask.py"},"region":{"startLine":47}}}],"partialFingerprints":{"codehealthFindingId/v1":"01f62b5da6d5bf959fcfaae76b521fe1cf46d25522c4aa91fad3102cce2837f2"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: agent/src/agent/tools.py: agent/src/agent/tools.py changed 3 times in last 90 days and 3 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 8 (its worst body is ToolRegistry.execute at line 107), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix(agent): bound readonly replay after compaction\u201D; \u201Cfix(agent): stall watchdog, bash tree-kill timeout, compaction verification ledger\u201D; \u201Cfix(tools): report partial registry construction\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-17..2026-11-15, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-17 20:31:38 \u002B08:00\u0027 --until=\u00272026-11-15 20:31:38 \u002B08:00\u0027 --full-history --no-merges -- agent/src/agent/tools.py\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/agent/tools.py"},"region":{"startLine":107}}}],"partialFingerprints":{"codehealthFindingId/v1":"84bd3b052f786e83d83825da74e0397d0d61f5629ab595072b960b5eff33cac3"}},{"ruleId":"D16","level":"note","message":{"text":"Off-boarding risk: anonymized user #1: If anonymized user #1 becomes unavailable, 22 significant file(s) lose their only recent owner: agent/src/tools/institutional_holdings_tool.py, agent/src/quantlib/performance.py, wiki/scripts/build_alpha_library.py, agent/backtest/options_payoff.py, agent/src/live/runtime/decision_budget.py, agent/src/live/runtime/jobstore.py, agent/src/tools/pdf_report.py, frontend/src/components/chat/LiveRuntimePanel.tsx (\u002B14 more). Pair on, review, or document these before any departure."},"locations":[],"partialFingerprints":{"codehealthFindingId/v1":"2ee8373011c6a758840feccdbdc79af089b4d7e48a27917c88d60f9a44f20d5d"}},{"ruleId":"D16","level":"note","message":{"text":"Off-boarding risk: anonymized user #2: If anonymized user #2 becomes unavailable, 16 significant file(s) lose their only recent owner: agent/src/scheduling/system_jobs.py, agent/src/scheduling/triggers.py, agent/src/live/advisory/__init__.py, agent/src/scheduled_research/internal_dispatch.py, agent/src/channels/token_probe.py, agent/src/memory/consolidation.py, frontend/src/components/charts/OptionsPayoffChart.tsx, agent/src/config/writer.py (\u002B8 more). Pair on, review, or document these before any departure."},"locations":[],"partialFingerprints":{"codehealthFindingId/v1":"2f529f7bf74dd26033adbe8b5380884bc37e6baca507914414d51d96dc5fbe11"}},{"ruleId":"D16","level":"note","message":{"text":"Off-boarding risk: anonymized user #3: If anonymized user #3 becomes unavailable, 4 significant file(s) lose their only recent owner: agent/src/factors/zoo/academic/illiq.py, agent/src/factors/zoo/academic/retskew.py, agent/src/factors/zoo/academic/high52w.py, agent/src/factors/zoo/academic/strev.py. Pair on, review, or document these before any departure."},"locations":[],"partialFingerprints":{"codehealthFindingId/v1":"2bb4c2be2465dfa2a1b70792305a1b768cf319da89ee6d948913be2f4a99fcd0"}},{"ruleId":"D16","level":"note","message":{"text":"Off-boarding risk: anonymized user #4: If anonymized user #4 becomes unavailable, 3 significant file(s) lose their only recent owner: agent/src/trading/connectors/etoro/instruments.py, agent/src/trading/connectors/etoro/sdk.py, agent/src/trading/connectors/etoro/profiles.py. Pair on, review, or document these before any departure."},"locations":[],"partialFingerprints":{"codehealthFindingId/v1":"f3ad64b3b8c246ca742bf792e62fe5d3566e852a8fb4e607f8e0fadbaa55a8d1"}},{"ruleId":"D16","level":"note","message":{"text":"Further sole-owners (lower concentration): 20 other contributor(s) are each the sole owner of a small amount of code below the off-boarding threshold \u2014 folded into the bus-factor score and metrics (69 single-owned of 821 analysed files in total, 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; 821 of the 1453 production source files in this repository met that bar). They are anonymized user #5 (2 file(s)), anonymized user #6 (1 file(s)), anonymized user #7 (1 file(s)), anonymized user #8 (1 file(s)), anonymized user #9 (1 file(s)), anonymized user #10 (1 file(s)) (\u002B14 more) \u2014 spread or document their files in the same way, at lower priority than the named off-boarding risks above. The files folded here: agent/backtest/binance_account_reconciliation.py, agent/backtest/binance_shadow_evidence.py, agent/src/portfolio/extraetf.py, agent/src/live/runtime/reconcile.py, agent/src/trading/connectors/upbit/sdk.py, agent/backtest/engines/vietnam_equity.py, agent/src/skills/options-strategy/example_signal_engine.py, agent/src/live/pending_action.py (\u002B13 more)."},"locations":[],"partialFingerprints":{"codehealthFindingId/v1":"6eac528f2429e724e1a97ed868f79eefbcf1888dab4af9a9e673429369bb5b2f"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: # TODO: Replace with actual factor formula from paper \u2014 source code is not a task system: move the work to your tracker and leave a reference instead (e.g. \u0060# REF: #123\u0060), so the task is planned where tasks live and the ticket links back to the code."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/skills/strategy-dev-manager/templates/factor_signal_engine.py"},"region":{"startLine":47}}}],"partialFingerprints":{"codehealthFindingId/v1":"4030c9485b81c3e50e8a256a60e88d808a84bcac15f087f9e49d193308cf561c"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: # TODO: Replace with actual strategy logic from paper \u2014 source code is not a task system: move the work to your tracker and leave a reference instead (e.g. \u0060# REF: #123\u0060), so the task is planned where tasks live and the ticket links back to the code."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/skills/strategy-dev-manager/templates/strategy_signal_engine.py"},"region":{"startLine":53}}}],"partialFingerprints":{"codehealthFindingId/v1":"bae266503ec078d0e26f243c3c5dea8049421c64ccb1db8cdc05791526561f3e"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: # TODO(L6): pin the exact Robinhood positions envelope key once the real \u2014 source code is not a task system: move the work to your tracker and leave a reference instead (e.g. \u0060# REF: #123\u0060), so the task is planned where tasks live and the ticket links back to the code."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/live/enforcement.py"},"region":{"startLine":353}}}],"partialFingerprints":{"codehealthFindingId/v1":"b8308cdd7a64bf9bbde4b69ee0c446d0e25d8510ce2fd48085d1bd91bbb42859"}},{"ruleId":"D20","level":"note","message":{"text":"No ADRs found: No ADRs found. No recognised ADR directory (\u0060docs/adr/\u0060, \u0060docs/decisions/\u0060, \u0060adr/\u0060, \u0060docs/rfcs/\u0060, an \u0060ADR0001/\u0060 folder, or their siblings) exists anywhere in this tree. What was searched, so you can tell an empty log from a search that missed one: every directory under the tree (build output, dependencies and VCS metadata excepted), for a document that is either any non-index page inside a recognised ADR directory, whatever its name and however deeply nested (\u0060docs/adr/use-postgres.md\u0060, \u0060docs/adr/2024/0001-x.md\u0060); or a file anywhere whose name is ADR-shaped (\u00600001-use-postgres.md\u0060, \u0060adr-012-caching.md\u0060); or, when neither turned anything up, a document carrying the decision-record signature (an \u0022Architecture Decision Record\u0022 heading, or Status / Context / Decision / Consequences as section headings). A decision log that clears none of these \u2014 unnumbered files outside any recognised directory, without those headings \u2014 is not seen by this check and this row is then wrong. If that is your case, say so rather than renaming anything; otherwise, consider recording architectural decisions in \u0060docs/adr/\u0060. ADRs are expected here because \u0060pyproject.toml\u0060 makes this repository a deployable product (line 108)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"pyproject.toml"},"region":{"startLine":108}}}],"partialFingerprints":{"codehealthFindingId/v1":"6f93f7a2c78f190233679ac8202a9f8e691d2305d697b777ee579589e9c4bff1"}},{"ruleId":"D24","level":"note","message":{"text":"redundant comment: \u0022max_consecutive_loss\u0022 repeats the code it sits on: 3 of its 3 words (max, consecutive, loss) are already in \u0060it(\u0022max_consecutive_loss: \u003C= 3 positive, \u003C= 6 neutral, \u003E 6 negative\u0022, () =\u003E\u0060. Delete it, or replace it with what the code cannot say (why it is done here, a constraint, or a consequence)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/lib/__tests__/formatters.test.ts"},"region":{"startLine":107}}}],"partialFingerprints":{"codehealthFindingId/v1":"224576bd8b81d5ec2b4e42d7beb3687a8e97611b2f05b39f2ec4e832298df151"}},{"ruleId":"D24","level":"note","message":{"text":"redundant comment: \u0022The recovered episode keeps its recovery time\u0022 repeats the code it sits on: 4 of its 5 words (recovered, episode, recovery, time) are already in \u0060const recovered = episodes.find((e) =\u003E e.recoveryTime !== null);\u0060. Delete it, or replace it with what the code cannot say (why it is done here, a constraint, or a consequence)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/lib/__tests__/tearsheet.test.ts"},"region":{"startLine":243}}}],"partialFingerprints":{"codehealthFindingId/v1":"be177190887428125cd901a8a1a44d5edb536d44ba46b93894a29774021b0dfd"}},{"ruleId":"D26","level":"note","message":{"text":"Projects may be oversized for their cohesion: \u0060agent\u0060 (256678 LoC, 2100 module-visible types across 105 directories) overshoots its size bounds. 2 of 5 build unit(s) (Python, npm) overshoot their size bounds, lowering Project Cohesion to 2.0/10. Review these for cohesion \u2014 draw the boundary inside the module first (group each responsibility into its own package or directory and keep the cross-boundary members non-public), since splitting a published package moves types between packages and breaks consumers."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/requirements.txt"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"47032785a3522b6d6af4e942b3fa14de3f3436571dde4428e019ffdd63c20335"}},{"ruleId":"D26","level":"note","message":{"text":"Projects may be oversized for their cohesion: \u0060frontend\u0060 (27590 LoC, 352 module-visible types across 15 directories) overshoots its size bounds. 2 of 5 build unit(s) (Python, npm) overshoot their size bounds, lowering Project Cohesion to 2.0/10. Review these for cohesion \u2014 draw the boundary inside the module first (group each responsibility into its own package or directory and keep the cross-boundary members non-public), since splitting a published package moves types between packages and breaks consumers."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/package.json"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"ad0c0cc89c5cef671b3a0a4e5f2ad266bd9b26cbd43efdf415b0f62913ad1ac6"}},{"ruleId":"D29","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"d5b8f11381d61a58459ffc7c595fd52d09c03c711894a63a9578043d2338412b"},"taxa":[{"id":"CWE-829","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"A08:2025","toolComponent":{"name":"OWASP Top 10","guid":"7d1f0c2e-4b6a-4e39-9a51-0b2e8c3d5f61"}}]},{"ruleId":"D29","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"c75153da8f66a9d7d522d4ea3308777af21e9334e3f13aadbfe8078cecb13203"},"taxa":[{"id":"CWE-732","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"A01:2025","toolComponent":{"name":"OWASP Top 10","guid":"7d1f0c2e-4b6a-4e39-9a51-0b2e8c3d5f61"}}]},{"ruleId":"D29","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"ab8ce016c05617d2bea946f803bbeb3700de85a9611a8808cd4bc113313a14a3"},"taxa":[{"id":"CWE-1357","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-829","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"A03:2025","toolComponent":{"name":"OWASP Top 10","guid":"7d1f0c2e-4b6a-4e39-9a51-0b2e8c3d5f61"}}]},{"ruleId":"D29","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"d7bb75c1ebf3bb334045594f9036e16ac7bca60fda7779808713e53eb9dd8953"},"taxa":[{"id":"CWE-1357","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-829","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"A03:2025","toolComponent":{"name":"OWASP Top 10","guid":"7d1f0c2e-4b6a-4e39-9a51-0b2e8c3d5f61"}}]},{"ruleId":"D29","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"f34d25654731fc5939636286f91760323b6f14136a3feab90deaabcfbadeaec4"},"taxa":[{"id":"CWE-611","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"A02:2025","toolComponent":{"name":"OWASP Top 10","guid":"7d1f0c2e-4b6a-4e39-9a51-0b2e8c3d5f61"}}]},{"ruleId":"D29","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"df9cf53ffcec997f682516bc488cf4f1db453169d03a4a6ece0fb82cf50a8b3c"},"taxa":[{"id":"CWE-532","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"A09:2025","toolComponent":{"name":"OWASP Top 10","guid":"7d1f0c2e-4b6a-4e39-9a51-0b2e8c3d5f61"}}]},{"ruleId":"D29","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"d04b10c30f92e9ba2ebf7027796738ef52fd71b110ddb0e2e5f159976aac0160"},"taxa":[{"id":"CWE-327","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"A04:2025","toolComponent":{"name":"OWASP Top 10","guid":"7d1f0c2e-4b6a-4e39-9a51-0b2e8c3d5f61"}}]},{"ruleId":"D29","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"abb0f81aca128c53017d3aef1064a8862bea4de05fab9eeaeab2b4b646c608af"},"taxa":[{"id":"CWE-532","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"A09:2025","toolComponent":{"name":"OWASP Top 10","guid":"7d1f0c2e-4b6a-4e39-9a51-0b2e8c3d5f61"}}]},{"ruleId":"D29","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"9bc625871478f13ecff47d6da5fb1ce02ee37e65b8299879d08c284ce22d4ca3"},"taxa":[{"id":"CWE-327","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"A04:2025","toolComponent":{"name":"OWASP Top 10","guid":"7d1f0c2e-4b6a-4e39-9a51-0b2e8c3d5f61"}}]},{"ruleId":"D29","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"7a51d69f50b4d23b897d63dfb63c55947db6277e9a2a146be8f2a92863353dbd"},"taxa":[{"id":"CWE-327","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"A04:2025","toolComponent":{"name":"OWASP Top 10","guid":"7d1f0c2e-4b6a-4e39-9a51-0b2e8c3d5f61"}}]},{"ruleId":"D29","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"2323699e845d17bbc24fbacb53ab1d188d0943de16e1301af490be1714da29d3"},"taxa":[{"id":"CWE-276","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"A01:2025","toolComponent":{"name":"OWASP Top 10","guid":"7d1f0c2e-4b6a-4e39-9a51-0b2e8c3d5f61"}}]},{"ruleId":"D29","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"6ebf5e9f069a6029931451d1f9b1d9da9ab92f3378bd500f7fb8b144db432c84"},"taxa":[{"id":"CWE-276","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"A01:2025","toolComponent":{"name":"OWASP Top 10","guid":"7d1f0c2e-4b6a-4e39-9a51-0b2e8c3d5f61"}}]},{"ruleId":"D29","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"97eeb1c17373c0f05cb40e2b635e5924421907eba39c384b1deefbcf41977148"},"taxa":[{"id":"CWE-327","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"A04:2025","toolComponent":{"name":"OWASP Top 10","guid":"7d1f0c2e-4b6a-4e39-9a51-0b2e8c3d5f61"}}]},{"ruleId":"D29","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"d478cfb777e5665ef553b6e6b593733156bded09b08ab4251d77cdd0b456bd0f"},"taxa":[{"id":"CWE-327","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"A04:2025","toolComponent":{"name":"OWASP Top 10","guid":"7d1f0c2e-4b6a-4e39-9a51-0b2e8c3d5f61"}}]},{"ruleId":"D29","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"bce3f6dc0b410be54f21bbd7dc43edc27bffc486e1a1cc6e6049a5ea5917fc48"},"taxa":[{"id":"CWE-611","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"A02:2025","toolComponent":{"name":"OWASP Top 10","guid":"7d1f0c2e-4b6a-4e39-9a51-0b2e8c3d5f61"}}]},{"ruleId":"D29","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"c6375c90bfec38b8aa007e1e126e1f15f4ad29faac7d7118ef6b1558331b3cc9"},"taxa":[{"id":"CWE-327","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"A04:2025","toolComponent":{"name":"OWASP Top 10","guid":"7d1f0c2e-4b6a-4e39-9a51-0b2e8c3d5f61"}}]},{"ruleId":"D29","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"c9994f6eb26eb3cd3bb8e404a2a1db340fd70f2fcb13840bec465c4730aec987"},"taxa":[{"id":"CWE-319","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"A04:2025","toolComponent":{"name":"OWASP Top 10","guid":"7d1f0c2e-4b6a-4e39-9a51-0b2e8c3d5f61"}}]},{"ruleId":"D29","level":"note","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"146157a59501d47c86a394b79786319568170c8c2a6a5e86e1eed7aad9aa92e5"},"taxa":[{"id":"CWE-939","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}}]},{"ruleId":"D29","level":"note","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"1d7b5caac449dd9ba25df3221932abfa122c2a31bfa52968d84d31c19d08d459"},"taxa":[{"id":"CWE-939","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}}]},{"ruleId":"D30","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"b2ee1ea4ba3afd498c8969fb60307e01dd19c04e289ae9255e71097b8f6499e3"},"properties":{"dependency":{"package":"dnspython","version":"2.9.0","advisory":"[GHSA redacted]","aliases":["[CVE redacted]"],"reachability":{"kind":"unknown"}}}},{"ruleId":"D30","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"b1c4339ef19bdfa6c420fa51378ad99950e04855a92f0ad6e4be3fa9501d535f"},"properties":{"dependency":{"package":"soupsieve","version":"2.9.1","advisory":"[GHSA redacted]","aliases":["[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]"],"reachability":{"kind":"unknown"}}}},{"ruleId":"D30","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"8488623a8b9e579411ee0a0b0c34e9524ca3f4965ae69e04ace1845dd138e2ad"},"properties":{"dependency":{"package":"dnspython","version":"2.9.0","advisory":"[GHSA redacted]","aliases":["[CVE redacted]"],"reachability":{"kind":"unknown"}}}},{"ruleId":"D30","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"6282d74f00431a154e87b6b232bf5dd8467af16df41a5f3602ab815a032dbdfc"},"properties":{"dependency":{"package":"soupsieve","version":"2.10","advisory":"[GHSA redacted]","aliases":["[CVE redacted]","[CVE redacted]","[CVE redacted]","[GHSA redacted]","[GHSA redacted]"],"reachability":{"kind":"unknown"}}}},{"ruleId":"D30","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"fcdb9d3fd32cec75e32678ed863dcae493c8fa5567c64a303a1e277913a08d51"},"properties":{"dependency":{"package":"undici","version":"7.24.8","advisory":"[GHSA redacted]","aliases":["[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]"],"reachability":{"kind":"unknown"}}}},{"ruleId":"D30","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"8654fba2dbaa39367193a889deb317d2bd9190479cd259bd2263fbb717c68e07"},"properties":{"dependency":{"package":"sharp","version":"0.34.5","advisory":"[GHSA redacted]","aliases":["[CVE redacted]","[CVE redacted]","[CVE redacted]","[GHSA redacted]","[GHSA redacted]"],"reachability":{"kind":"not-imported"}}}},{"ruleId":"D30","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"f0e09d4ae0e523d6cd7faecdf10aa6aae3acb6b50f96d19fd1d613170e20b612"},"properties":{"dependency":{"package":"ws","version":"8.20.1","advisory":"[GHSA redacted]","aliases":["[CVE redacted]"],"reachability":{"kind":"not-imported"}}}},{"ruleId":"D30","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"a5fc3a95c722cc602d4db60f38f441a226d6e2d336c0b46cca23cb98c91906e7"},"properties":{"dependency":{"package":"mistune","version":"3.0.0","advisory":"[GHSA redacted]","aliases":["[CVE redacted]","PYSEC-2026-2206"],"reachability":{"kind":"production","file":"agent/src/channels/matrix.py","line":21}}}},{"ruleId":"D30","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"c591d93cc08b663dcba14154bb4eca5e45738020ca55abd5b314e909cc5730b3"},"properties":{"dependency":{"package":"weasyprint","version":"60.0","advisory":"[GHSA redacted]","aliases":["[CVE redacted]","PYSEC-2026-3412"],"reachability":{"kind":"production","file":"agent/src/channels/rich_text.py","line":83}}}},{"ruleId":"D30","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"35d9472f68a301829013014bb5b8e879ce79e936088e3333fb91bd84586d464d"},"properties":{"dependency":{"package":"opentelemetry-api","version":"1.45.1","advisory":"[GHSA redacted]","aliases":["[CVE redacted]"],"reachability":{"kind":"unknown"}}}},{"ruleId":"D30","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"7ff95769d51837dad1d16efc11d80cdb570569e7303c7bde8ef05fb7a58e18d7"},"properties":{"dependency":{"package":"opentelemetry-api","version":"1.45.1","advisory":"[GHSA redacted]","aliases":["[CVE redacted]"],"reachability":{"kind":"unknown"}}}},{"ruleId":"D30","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"87fc45c40440ea7ff9b6c1d82af53a3c155b2904c1fb3e09c44e0c760f932d34"},"properties":{"dependency":{"package":"minimatch","version":"9.0.9","advisory":"[GHSA redacted]","aliases":["[CVE redacted]"],"reachability":{"kind":"not-imported"}}}},{"ruleId":"D30","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"479e30fc138aca0445f4c9c2a00c69fdf0801394595b6ccaa64eea6bc9d87d32"},"properties":{"dependency":{"package":"minimatch","version":"10.2.6","advisory":"[GHSA redacted]","aliases":["[CVE redacted]"],"reachability":{"kind":"not-imported"}}}},{"ruleId":"D30","level":"note","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"0765ea3d4e88d47c7f2e398b3b66d02f3b7c01144ff448596d69ff23db0b00dc"},"properties":{"dependency":{"package":"katex","version":"0.16.47","advisory":"[GHSA redacted]","aliases":["[CVE redacted]"],"reachability":{"kind":"production","file":"frontend/src/components/chat/EnhancedMarkdown.tsx","line":4}}}},{"ruleId":"D30","level":"note","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"12615185744e76939dc456e691e105ac2d39427f4bea95f5880b75fdceaca151"},"properties":{"dependency":{"package":"esbuild","version":"0.27.3","advisory":"[GHSA redacted]","reachability":{"kind":"not-imported"}}}},{"ruleId":"D32","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"17e908d9e16ad3c93f746e8cfba89f74aa3fffa27563fa904349f461c37d58f6"}},{"ruleId":"D34","level":"error","message":{"text":"Orphaned knowledge: No living knowledge remains for this large file \u2014 its last meaningful change has decayed away; if it breaks, no one currently understands it. Schedule a read-through / add characterisation tests before it bites."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/trading212/sdk.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"717a8ea87c83fd2889308a2fa2bf9c9dfc0d32e73ab1924108642d89def8b092"}},{"ruleId":"D34","level":"error","message":{"text":"Orphaned knowledge: No living knowledge remains for this large file \u2014 its last meaningful change has decayed away; if it breaks, no one currently understands it. Schedule a read-through / add characterisation tests before it bites."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/tickerall_loader.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"dafe968e9df95747e4b4e204988d847a4f6cbaef27b838bcb214078f37528f34"}},{"ruleId":"D34","level":"note","message":{"text":"Further orphaned files (smaller): 13 smaller file(s) also have no living knowledge \u2014 folded into the freshness score and metrics rather than raised one row each \u2014 most significant first: agent/backtest/engines/korea_equity.py, agent/src/openbb_bridge/context_injector.py, agent/backtest/loaders/pykrx_loader.py, agent/src/openbb_bridge/routes.py, agent/src/openbb_bridge/event_mapper.py, frontend/src/components/charts/RegimeTimeline.tsx, agent/src/skills/vnpy-export/scripts/cta_template.py, agent/src/config/migrate.py (and 5 more) (15 orphaned of 821 analysed files in total, 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; 821 of the 1453 production source files in this repository met that bar). 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."},"locations":[],"partialFingerprints":{"codehealthFindingId/v1":"ce861fd78f6935114d3a342cb90ad25870f984e1042954fcbbe27c0e23be3658"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/engines/korea_equity.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"2eed4167e0407cea48b106771d789def180181521a56088291e810e2ba1c277b"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/openbb_bridge/context_injector.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"e30af3dad16073c2d142b054f50a5cc45234d5b473211add3fcad73fc682cbe5"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/pykrx_loader.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"e55b7d5b441eab224d1fe12069d794ad2121d926aafef989a69ca382c9be305e"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/openbb_bridge/routes.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"a17c5f56359a6a03079eca1db76ed5696544c0a28d5ccaaa5e2d6fdcd3dba0a0"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/config/migrate.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"efb56dada5e83c9edce029f94bf7261b1db6a2f58594c90afc548747eb02b54b"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/openbb_bridge/event_mapper.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"2bfab151616ade42f450435caf7c3228b0db2b02911aebc7f534885d2771254a"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/charts/RegimeTimeline.tsx"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"4575710f49f6b5d5e9e7789c7e1766f1bef62834c482a10ff52d833412e3e99b"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/skills/vnpy-export/scripts/cta_template.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"bb4fb6f52466b368e7fcb3ba3de88fcbd96ef7ee2f68206ef74ecd9422d76df5"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/lib/cadence.ts"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"c2a0824ec333e5ebe26ca1b0cdec1f8d2f70e35eacdad1eaa8c5b7c8edc3604d"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/mt5/symbols.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"865d7a98be2ae479f9babcf81b7f8d59ca5340c5bff0e2a990f5d6310ea3d3eb"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/mt5/profiles.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"ed94049ce1197b39ead784ef515db2814092f83115d4de1812d8d384c7056887"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/shoonya/profiles.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"408df97c9c56b3bce8975e62b2ab324b45650126903d0aab46f97911818d90bd"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: 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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/dhan/profiles.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"56e66b10b7378f2ec25b95a9cb97564408df860e0197032fd46f14dbceb6e646"}},{"ruleId":"D36","level":"note","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"1b213f6eedd4b140d0bc37bdf1496f72811a643f34064f12518b32e9e83bcfc7"},"taxa":[{"id":"CICD-SEC-9","toolComponent":{"name":"OWASP Top 10 CI/CD Security Risks","guid":"3c9b2a6e-5d14-4f7b-8e02-6a1d9c4b7f35"}}]},{"ruleId":"D36","level":"note","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"0e17f71490e4d120a48b2b2881ab866c93b272bef2febb673a3e8e42b2c288ab"},"taxa":[{"id":"CICD-SEC-9","toolComponent":{"name":"OWASP Top 10 CI/CD Security Risks","guid":"3c9b2a6e-5d14-4f7b-8e02-6a1d9c4b7f35"}}]},{"ruleId":"D36","level":"note","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"eb00976a698a5d68999b7ee6d27206fd374e916853e7ff1ead5eed42386f043f"},"taxa":[{"id":"CICD-SEC-9","toolComponent":{"name":"OWASP Top 10 CI/CD Security Risks","guid":"3c9b2a6e-5d14-4f7b-8e02-6a1d9c4b7f35"}}]},{"ruleId":"D36","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"6b1273c81a1ca9b5eb097489b2567416912a145951451afeec807249ffa5e5b8"},"taxa":[{"id":"CICD-SEC-4","toolComponent":{"name":"OWASP Top 10 CI/CD Security Risks","guid":"3c9b2a6e-5d14-4f7b-8e02-6a1d9c4b7f35"}}]},{"ruleId":"D36","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"636afabe291e0f35f3390380676be08e404a09392116e35010a714eb4c62fff5"},"taxa":[{"id":"CICD-SEC-4","toolComponent":{"name":"OWASP Top 10 CI/CD Security Risks","guid":"3c9b2a6e-5d14-4f7b-8e02-6a1d9c4b7f35"}}]},{"ruleId":"AC2","level":"error","message":{"text":"\u003Cbutton\u003E with no accessible text: A button with no text and no aria-label has no accessible name. Add visible text or an aria-label (an icon-only button still needs one)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"desktop/electron/src/loading.html"},"region":{"startLine":38}}}],"partialFingerprints":{"codehealthFindingId/v1":"9bb1d208cd92e314f2bf21e86f18e708c0132f2a8abcc90e5fe7788008ccaeed"}},{"ruleId":"AC2","level":"error","message":{"text":"\u003Cbutton\u003E with no accessible text: A button with no text and no aria-label has no accessible name. Add visible text or an aria-label (an icon-only button still needs one)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"desktop/electron/src/loading.html"},"region":{"startLine":39}}}],"partialFingerprints":{"codehealthFindingId/v1":"13d39263517d07ecf35fe64b72cf6b1b1e341f2d4a78092357010dfa9b59377b"}},{"ruleId":"AC2","level":"error","message":{"text":"\u003Cbutton\u003E with no accessible text: A button with no text and no aria-label has no accessible name. Add visible text or an aria-label (an icon-only button still needs one)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/chat/Composer.tsx"},"region":{"startLine":280}}}],"partialFingerprints":{"codehealthFindingId/v1":"cce4fa96a087671afa9cdcf7470b1442cae25e10cc2ded1b0077b229ca66e915"}},{"ruleId":"AC2","level":"error","message":{"text":"\u003Cbutton\u003E with no accessible text: A button with no text and no aria-label has no accessible name. Add visible text or an aria-label (an icon-only button still needs one)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/chat/Composer.tsx"},"region":{"startLine":291}}}],"partialFingerprints":{"codehealthFindingId/v1":"5a97da841cc0601766edc287121b35b956f804be742b85caf7083fb82cb99571"}},{"ruleId":"AC2","level":"warning","message":{"text":"\u003Cfieldset\u003E without a \u003Clegend\u003E: A fieldset groups related controls but has no \u003Clegend\u003E to name the group. Add a \u003Clegend\u003E as its first child \u2014 or, if the group already has a visible caption beside it (or the fieldset is there only to disable its subtree and carries no group box), point aria-labelledby at that caption\u0027s id instead, which names the group without rendering a second one."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/chat/RunnerBudgetControls.tsx"},"region":{"startLine":48}}}],"partialFingerprints":{"codehealthFindingId/v1":"2ba068049d1b983ba5dcbac205fc722b45f7fc6eba00d84360edc030c562c7b7"}},{"ruleId":"AC2","level":"warning","message":{"text":"\u003Cfieldset\u003E without a \u003Clegend\u003E: A fieldset groups related controls but has no \u003Clegend\u003E to name the group. Add a \u003Clegend\u003E as its first child \u2014 or, if the group already has a visible caption beside it (or the fieldset is there only to disable its subtree and carries no group box), point aria-labelledby at that caption\u0027s id instead, which names the group without rendering a second one."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/portfolio/ConnectionCenter.tsx"},"region":{"startLine":242}}}],"partialFingerprints":{"codehealthFindingId/v1":"c8ac0276a4aa03a41990d848586b3c8c23e6965e25e4e7358774f0da07239ed1"}},{"ruleId":"AC2","level":"error","message":{"text":"\u003Clabel\u003E that labels no control: This \u003Clabel\u003E has no htmlFor and wraps no form control, so it names nothing: assistive tech never announces it, and clicking the caption focuses no field. Note that an id on the label is not an association \u2014 it is the TARGET of one, so a control still has to point at it. Give the label htmlFor=\u0022\u003Cthe control\u0027s id\u003E\u0022, move the control inside the label, or point the control\u0027s aria-labelledby at this label\u0027s id."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Compare.tsx"},"region":{"startLine":336}}}],"partialFingerprints":{"codehealthFindingId/v1":"d55a88a6ff9ddec5ca4f2f51d000ca34ec2d4656a31cc45717f9166cb3554934"}},{"ruleId":"AC2","level":"error","message":{"text":"\u003Clabel\u003E that labels no control: This \u003Clabel\u003E has no htmlFor and wraps no form control, so it names nothing: assistive tech never announces it, and clicking the caption focuses no field. Note that an id on the label is not an association \u2014 it is the TARGET of one, so a control still has to point at it. Give the label htmlFor=\u0022\u003Cthe control\u0027s id\u003E\u0022, move the control inside the label, or point the control\u0027s aria-labelledby at this label\u0027s id."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Compare.tsx"},"region":{"startLine":352}}}],"partialFingerprints":{"codehealthFindingId/v1":"8444948c463100de8713893ede362ae5bacaaedeee0abca069e889dd0a740f04"}},{"ruleId":"AC2","level":"error","message":{"text":"\u003Clabel\u003E that labels no control: This \u003Clabel\u003E has no htmlFor and wraps no form control, so it names nothing: assistive tech never announces it, and clicking the caption focuses no field. Note that an id on the label is not an association \u2014 it is the TARGET of one, so a control still has to point at it. Give the label htmlFor=\u0022\u003Cthe control\u0027s id\u003E\u0022, move the control inside the label, or point the control\u0027s aria-labelledby at this label\u0027s id."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Correlation.tsx"},"region":{"startLine":129}}}],"partialFingerprints":{"codehealthFindingId/v1":"889fb7eea2326151b06261eaeafa997083fa8eececb630b4ec7bf523be313758"}},{"ruleId":"AC2","level":"error","message":{"text":"\u003Clabel\u003E that labels no control: This \u003Clabel\u003E has no htmlFor and wraps no form control, so it names nothing: assistive tech never announces it, and clicking the caption focuses no field. Note that an id on the label is not an association \u2014 it is the TARGET of one, so a control still has to point at it. Give the label htmlFor=\u0022\u003Cthe control\u0027s id\u003E\u0022, move the control inside the label, or point the control\u0027s aria-labelledby at this label\u0027s id."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Correlation.tsx"},"region":{"startLine":151}}}],"partialFingerprints":{"codehealthFindingId/v1":"cc3ba8351f4b38a4112fe8facb667798e48a824834eac40e4565c61d3bc21b2f"}},{"ruleId":"AC2","level":"warning","message":{"text":"\u003Cfieldset\u003E without a \u003Clegend\u003E: A fieldset groups related controls but has no \u003Clegend\u003E to name the group. Add a \u003Clegend\u003E as its first child \u2014 or, if the group already has a visible caption beside it (or the fieldset is there only to disable its subtree and carries no group box), point aria-labelledby at that caption\u0027s id instead, which names the group without rendering a second one."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/PixelOffice.tsx"},"region":{"startLine":86}}}],"partialFingerprints":{"codehealthFindingId/v1":"8b328bdfd793967aca2620b575571b5ee85441ca96de60c1f11e1e7cf696796e"}},{"ruleId":"AC2","level":"warning","message":{"text":"\u003Cfieldset\u003E without a \u003Clegend\u003E: A fieldset groups related controls but has no \u003Clegend\u003E to name the group. Add a \u003Clegend\u003E as its first child \u2014 or, if the group already has a visible caption beside it (or the fieldset is there only to disable its subtree and carries no group box), point aria-labelledby at that caption\u0027s id instead, which names the group without rendering a second one."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/PixelOffice.tsx"},"region":{"startLine":105}}}],"partialFingerprints":{"codehealthFindingId/v1":"19514ddc44e922a5dab1156bc91b7e12cfd62229de0a254b9f2dfe80753f84fb"}},{"ruleId":"AC2","level":"warning","message":{"text":"\u003Cfieldset\u003E without a \u003Clegend\u003E: A fieldset groups related controls but has no \u003Clegend\u003E to name the group. Add a \u003Clegend\u003E as its first child \u2014 or, if the group already has a visible caption beside it (or the fieldset is there only to disable its subtree and carries no group box), point aria-labelledby at that caption\u0027s id instead, which names the group without rendering a second one."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/ResearchLab.tsx"},"region":{"startLine":140}}}],"partialFingerprints":{"codehealthFindingId/v1":"dd97a73a4311c527f86ea10a41d86b09a6599cec7ed40f76bcec7dd5505d0a33"}},{"ruleId":"AC3","level":"warning","message":{"text":"Page without a main landmark: No \u003Cmain\u003E (or role=\u0022main\u0022) means no \u0022skip to content\u0022 target and a weaker landmark map. Wrap the primary content in \u003Cmain\u003E."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/shadow_account/templates/shadow_report.html"},"region":{"startLine":2}}}],"partialFingerprints":{"codehealthFindingId/v1":"36018751e732e2723569a45c27a95d7835df58e7a5b2fb34f7a2a06c88ba8667"}},{"ruleId":"AC3","level":"warning","message":{"text":"Data table has no header cells: A \u003Ctable\u003E with data cells but no \u003Cth\u003E gives assistive technology no way to associate cells with their headers. Mark the header row/column cells as \u003Cth\u003E (with a scope)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/charts/StrategyResearchDashboard.tsx"},"region":{"startLine":287}}}],"partialFingerprints":{"codehealthFindingId/v1":"d63c7b430b4cf72f329ccd457fb52c55e6830098fa46ff35217b8002fed7a426"}},{"ruleId":"AC3","level":"warning","message":{"text":"Data table has no header cells: A \u003Ctable\u003E with data cells but no \u003Cth\u003E gives assistive technology no way to associate cells with their headers. Mark the header row/column cells as \u003Cth\u003E (with a scope)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/run/RunCard.tsx"},"region":{"startLine":55}}}],"partialFingerprints":{"codehealthFindingId/v1":"70b8d1c7b5b073d23115cb128b98d51dc821c515662bc2de439bba78035c36cb"}},{"ruleId":"AC3","level":"warning","message":{"text":"Heading level jumps from h1 to h3: Skipping heading levels breaks the document outline assistive tech relies on. Don\u0027t jump levels \u2014 increase by at most one."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/AlphaZoo.tsx"},"region":{"startLine":243}}}],"partialFingerprints":{"codehealthFindingId/v1":"77fcd6414e1fb7e9e18ccf5464f9b39ec619a1aa0e60ecc3d8586532939d139d"}},{"ruleId":"AC3","level":"warning","message":{"text":"Heading level jumps from h1 to h3: Skipping heading levels breaks the document outline assistive tech relies on. Don\u0027t jump levels \u2014 increase by at most one."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"wiki/alpha-library/index.html"},"region":{"startLine":121}}}],"partialFingerprints":{"codehealthFindingId/v1":"0cd6368410fe9abaf2c541bbd4e8d91ef80d361e37634fca0ae883505f13fc34"}},{"ruleId":"AC3","level":"warning","message":{"text":"Heading level jumps from h1 to h3: Skipping heading levels breaks the document outline assistive tech relies on. Don\u0027t jump levels \u2014 increase by at most one."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"wiki/tutorials/index.html"},"region":{"startLine":66}}}],"partialFingerprints":{"codehealthFindingId/v1":"6aa1ba71359beb03dd701ebb021bd90285018ffb9eb3709426ec2a9b3bcb63b7"}},{"ruleId":"AC4","level":"warning","message":{"text":"Modal dialog does not manage focus: This \u003Cdiv role=\u0022dialog\u0022\u003E is a modal dialog, but focus is moved into it, but nothing keeps it there: Tab walks out to the page behind, so a keyboard or screen-reader user keeps acting on the content behind it (WCAG 2.4.3). Use a native \u003Cdialog\u003E opened with showModal(), a dialog component that traps focus, or move focus to the dialog on open, trap Tab inside it (or make the page behind inert) and return focus to the control that opened it on close."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/chat/PineScriptViewer.tsx"},"region":{"startLine":51}}}],"partialFingerprints":{"codehealthFindingId/v1":"3eca0e5339580114a7a0dd7b79e65b5926bc6c1a1ad7b57c0f27665a1a8c8501"}},{"ruleId":"AC4","level":"warning","message":{"text":"Modal dialog does not manage focus: This \u003Csection role=\u0022dialog\u0022\u003E is a modal dialog, but nothing moves focus into it when it opens and nothing keeps focus inside it while it is open, so a keyboard or screen-reader user keeps acting on the content behind it (WCAG 2.4.3). Use a native \u003Cdialog\u003E opened with showModal(), a dialog component that traps focus, or move focus to the dialog on open, trap Tab inside it (or make the page behind inert) and return focus to the control that opened it on close."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/portfolio/ConnectionCenter.tsx"},"region":{"startLine":147}}}],"partialFingerprints":{"codehealthFindingId/v1":"9d01f9bf9392d3849843b88aea4a34af0eaa1b82fde1ca751e7b9af3df39dd04"}},{"ruleId":"AC4","level":"warning","message":{"text":"Modal dialog does not manage focus: This \u003Csection role=\u0022dialog\u0022\u003E is a modal dialog, but nothing moves focus into it when it opens and nothing keeps focus inside it while it is open, so a keyboard or screen-reader user keeps acting on the content behind it (WCAG 2.4.3). Use a native \u003Cdialog\u003E opened with showModal(), a dialog component that traps focus, or move focus to the dialog on open, trap Tab inside it (or make the page behind inert) and return focus to the control that opened it on close."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/portfolio/PortfolioSourceEditor.tsx"},"region":{"startLine":96}}}],"partialFingerprints":{"codehealthFindingId/v1":"331d0b05af526054fa6705b33b7437db09706f1ce40190bee88b0f4636daf78b"}},{"ruleId":"AC6","level":"warning","message":{"text":"Animation without a prefers-reduced-motion guard: \u0060.bar\u0060 moves (\u0060animation: loading 1.25s ease-in-out infinite\u0060) and nothing reads prefers-reduced-motion for it \u2014 no @media (prefers-reduced-motion) rule for this element, no reset this project loads \u2014 so a motion-sensitive user cannot turn it off (WCAG 2.3.3). Declare it under @media (prefers-reduced-motion: no-preference), or neutralise it under reduce."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"desktop/electron/src/loading.html"},"region":{"startLine":20}}}],"partialFingerprints":{"codehealthFindingId/v1":"c40eb9878169fe3823a037d67f775ade5f5e51e2d635e48f05fb6a4c6501898e"}},{"ruleId":"AC6","level":"warning","message":{"text":"Focus outline removed inline: \u003Ctextarea\u003E takes keyboard focus, and its outline-none utility removes the focus ring with no focus-state ring, shadow, border or outline utility in its place. Add one (e.g. focus-visible:ring-2)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/chat/Composer.tsx"},"region":{"startLine":420}}}],"partialFingerprints":{"codehealthFindingId/v1":"e2ddc26e81ed0653fac23ef285affb166504f5fb7da8c53004651798dcbf719d"}},{"ruleId":"AC6","level":"warning","message":{"text":"Animation without a prefers-reduced-motion guard: \u003Cdiv\u003E moves \u2014 its \u0060animate-[pulse-slide_2s_ease-in-out_infinite]\u0060 utility runs with no motion-safe:/motion-reduce: variant \u2014 and nothing reads prefers-reduced-motion for it, so a motion-sensitive user cannot turn it off (WCAG 2.3.3). Gate it on @media (prefers-reduced-motion: no-preference) or motion-safe:."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/chat/SwarmStatusCard.tsx"},"region":{"startLine":46}}}],"partialFingerprints":{"codehealthFindingId/v1":"5821b3d126840b17ec86ece57f69bf2219c68b047c5ff623a825d426eba0fcf3"}},{"ruleId":"AC6","level":"warning","message":{"text":"Focus outline removed inline: \u003Cinput\u003E takes keyboard focus, and its outline-none utility removes the focus ring with no focus-state ring, shadow, border or outline utility in its place. Add one (e.g. focus-visible:ring-2)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Reports.tsx"},"region":{"startLine":112}}}],"partialFingerprints":{"codehealthFindingId/v1":"091fecc263b8697c11730c8aed8527deeea32b4114488e8831afa5130d179402"}},{"ruleId":"AC6","level":"warning","message":{"text":"Animation without a prefers-reduced-motion guard: \u0060.alpha-zoo-card\u0060 moves (\u0060transition: border-color 0.15s ease, transform 0.15s ease\u0060) and nothing reads prefers-reduced-motion for it \u2014 no @media (prefers-reduced-motion) rule for this element, no reset this project loads \u2014 so a motion-sensitive user cannot turn it off (WCAG 2.3.3). Declare it under @media (prefers-reduced-motion: no-preference), or neutralise it under reduce."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"wiki/alpha-library/index.html"},"region":{"startLine":42}}}],"partialFingerprints":{"codehealthFindingId/v1":"99e55cb1dc200154d93bad0a061d1ea5acddbfd55a1516b0daab14b4c0ac53a6"}},{"ruleId":"AC6","level":"warning","message":{"text":"Low contrast colour pair in CSS (2.9:1): \u0060thead th\u0060 sets color: #5f6878 on background-color: #1a1f29 \u2014 2.9:1, below the 4.5:1 WCAG AA minimum for normal text. Darken or lighten one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/shadow_account/templates/shadow_report.css"},"region":{"startLine":250}}}],"partialFingerprints":{"codehealthFindingId/v1":"f7b4201762cd9872bead486e7b2c279f6342d3b5b3d3ed476b843128c7ee0eb0"}},{"ruleId":"AC6","level":"warning","message":{"text":"Focus outline removed in CSS without a :focus replacement: \u0060.docs-article\u0060 sets the outline to none/0 and no visible :focus / :focus-visible style for that element replaces it in this stylesheet, so a keyboard user cannot see where focus is. Draw a focus ring (outline, box-shadow or border) under :focus-visible."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"wiki/docs/styles.css"},"region":{"startLine":112}}}],"partialFingerprints":{"codehealthFindingId/v1":"92c74cf03229ec5fa358316cfadd32b4958a57f57f175b1780a1f315215f98b3"}},{"ruleId":"AC6","level":"warning","message":{"text":"Animation without a prefers-reduced-motion guard: \u0060.knowledge-card\u0060 moves (\u0060transition: border-color 160ms ease, transform 160ms ease, background 160ms ease\u0060) and nothing reads prefers-reduced-motion for it \u2014 no @media (prefers-reduced-motion) rule for this element, no reset this project loads \u2014 so a motion-sensitive user cannot turn it off (WCAG 2.3.3). Declare it under @media (prefers-reduced-motion: no-preference), or neutralise it under reduce."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"wiki/styles.css"},"region":{"startLine":498}}}],"partialFingerprints":{"codehealthFindingId/v1":"0703dba872795bb79a263b5cd2fda33235d99563fe90d6342506b8a8fec51a67"}},{"ruleId":"AC6","level":"warning","message":{"text":"Animation without a prefers-reduced-motion guard: \u0060.pixel-character__typing\u0060 moves (\u0060animation: pixel-typing 900ms steps(2, end) infinite\u0060) and nothing reads prefers-reduced-motion for it \u2014 no @media (prefers-reduced-motion) rule for this element, no reset this project loads \u2014 so a motion-sensitive user cannot turn it off (WCAG 2.3.3). Declare it under @media (prefers-reduced-motion: no-preference), or neutralise it under reduce."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/index.css"},"region":{"startLine":185}}}],"partialFingerprints":{"codehealthFindingId/v1":"061cb9ea9fd322bed8a375e9ba5615dfd7e0bec4d8cf1e21deaa95ae458a11ae"}},{"ruleId":"C2","level":"note","message":{"text":"No named authorization policies: Authorization IS enforced here (by route guards, auth middleware or checks that refuse a caller) \u2014 this is NOT a claim that endpoints are unprotected. What\u0027s missing is a NAMED rule set: who may do what is encoded inline where it is checked, so the rules can\u0027t be listed, reviewed or tested apart from the code that applies them. Recommendation, not a defect."},"locations":[],"partialFingerprints":{"codehealthFindingId/v1":"b048fdf3fa524ac68c7874fdfcdb4c49d5f010013f2cb22a0bd84cb12ceb951f"}},{"ruleId":"M2","level":"note","message":{"text":"No ADRs: No Architecture Decision Records found \u2014 no conventional ADR directory, no numbered \u0060NNNN-title\u0060 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."},"locations":[],"partialFingerprints":{"codehealthFindingId/v1":"670b3d6e36a756d63097d0dfbf90afd5fc761308800b9354894a07c3f4e4aa14"}},{"ruleId":"M2","level":"note","message":{"text":"No architecture diagram/doc: No C4/Structurizr/PlantUML/Mermaid/Graphviz/D2 diagram, no drawn diagram named for the architecture, no file named \u0060architecture\u0060 or \u0060design\u0060 in any markup this check reads, and nothing in the README, docs or contributor guides that announces the shape \u2014 no \u0060## Architecture\u0060 heading, no \u0022architecture overview\u0022/\u0022high-level design\u0022 phrasing, no \u0022the architecture is \u2026\u0022 introduction, no guided code tour. A shape laid out in prose that never names itself as the architecture is not visible to this check, and neither is one kept outside the repository, so this row reports the absence of a re-findable shape document \u2014 not evidence that nobody wrote the shape down."},"locations":[],"partialFingerprints":{"codehealthFindingId/v1":"0c190e7c159d1850ee706c3ac4486e151e8a4fe169de4bf61436b9f399654f06"}},{"ruleId":"P2","level":"note","message":{"text":"Logging is not universal: Only 1/2 runnable modules use logging (modules with no entry point or server are excluded \u2014 they are libraries a runnable module hosts). Silent: \u0060desktop/electron\u0060."},"locations":[],"partialFingerprints":{"codehealthFindingId/v1":"91a94e21d6d4d0e6a2003f94505b0b02b157176f0b24c4820f3f82b4447a97fe"}},{"ruleId":"P3","level":"note","message":{"text":"No SAST: No static application security testing detected. For this repository\u0027s stack, add bandit, \u0060semgrep --config=p/python\u0060, or CodeQL\u0027s python pack as a CI step. What was searched, so you can tell an absence from a miss: the 6 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\u0027s web UI rather than in a committed file, or a tool whose name is none of those this check carries, is not seen \u2014 if that is your case the row is wrong, and saying so is more useful than adding a second scanner."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":".github/workflows/desktop-windows.yml"},"region":{"startLine":13}}}],"partialFingerprints":{"codehealthFindingId/v1":"6e54424179c892f03ef2fd003130ac4bd43f39bbf3b1ca0a0143e25acb80ec87"}},{"ruleId":"P4","level":"note","message":{"text":"No release approval gate: Deployment is automated and no gate that pauses it for a human is DECLARED IN THIS REPOSITORY\u0027S PIPELINE FILES. What was read: every file under \u0060.github/workflows/\u0060, \u0060.forgejo/workflows/\u0060, \u0060.gitea/workflows/\u0060, \u0060.azuredevops/\u0060 and \u0060.azure-pipelines/\u0060, plus \u0060.gitlab-ci*\u0060 and \u0060azure-pipelines*\u0060 \u2014 with comment text stripped, so documenting a gate is not declaring one. What would have counted: GitLab\u0027s \u0060when: manual\u0060, CircleCI\u0027s \u0060type: approval\u0060, an Azure \u0060ManualValidation@\u0060 task or an \u0060approvals:\u0060 block, a Jenkins \u0060input\u0060 step, a \u0060uses:\u0060 step naming an approval action, an \u0060environment:\u0060 paired with \u0060reviewers\u0060 / \u0060required_reviewers\u0060 / \u0060protection\u0060 / \u0060wait-timer\u0060 / \u0060deployment_branch_policy\u0060, a draft-release step, a \u0060workflow_dispatch\u0060 promotion, or a release-event gate. \u2605 What this cannot see, because none of it is a file: a GitHub environment whose required reviewers are configured in repo SETTINGS, a branch protection rule, or an organisation deployment policy \u2014 all of them real, enforced gates that live outside the repository. If yours is one of those, this row is wrong and nothing in the tree could have told us. Otherwise: whatever reaches the release trigger goes to production unreviewed, so a mistaken merge or tag is live before anyone can stop it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":".github/workflows/docker-build.yml"},"region":{"startLine":71}}}],"partialFingerprints":{"codehealthFindingId/v1":"6c11e2dbd483b4b423b95ac61bfcc7af1d55351b28a20d2b1105b31cfe38cc60"}},{"ruleId":"PF3","level":"warning","message":{"text":"Sync-over-async blocking: \u0060start\u0060 is async and calls time.sleep \u2014 a blocking call inside async code stalls the event loop \u2014 every other task on it waits for as long as it runs."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/feishu.py"},"region":{"startLine":713}}}],"partialFingerprints":{"codehealthFindingId/v1":"9fead87043ca249d05ebc6cdf0750a02a7ecb8c937359c1975cfe1d1bb21d408"}},{"ruleId":"PF3","level":"warning","message":{"text":"Sync-over-async blocking: \u0060exercise\u0060 is async and calls subprocess.check_output \u2014 a blocking call inside async code stalls the event loop \u2014 every other task on it waits for as long as it runs."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"tools/gateway_full_scan_probe.py"},"region":{"startLine":43}}}],"partialFingerprints":{"codehealthFindingId/v1":"82a5394483be62d29bfe46d39e87a42ee2374d9217a9fbdf4e4e605d13a7f85f"}},{"ruleId":"PF3","level":"warning","message":{"text":"Sync-over-async blocking: \u0060mkdirSync\u0060 in \u0060start\u0060 blocks the event loop until it finishes \u2014 a blocking call inside async code stalls the event loop \u2014 every other request waits for as long as it runs."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"desktop/electron/src/backend-manager.ts"},"region":{"startLine":94}}}],"partialFingerprints":{"codehealthFindingId/v1":"6f4c555c6c2006e8bb4991e323eae9f9edfc6034b0a24509ef419c7c04bedcbf"}},{"ruleId":"PF3","level":"warning","message":{"text":"Sync-over-async blocking: \u0060existsSync\u0060 in \u0060start\u0060 blocks the event loop until it finishes \u2014 a blocking call inside async code stalls the event loop \u2014 every other request waits for as long as it runs."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"desktop/electron/src/backend-manager.ts"},"region":{"startLine":124}}}],"partialFingerprints":{"codehealthFindingId/v1":"08789d2fce99699d582bdb95a0be3e9c518393a984504550eae73ac6e26b4fdb"}},{"ruleId":"PF3","level":"warning","message":{"text":"Sync-over-async blocking: \u0060readFileSync\u0060 in \u0060loadPage\u0060 blocks the event loop until it finishes \u2014 a blocking call inside async code stalls the event loop \u2014 every other request waits for as long as it runs."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"tools/wiki/dom.mjs"},"region":{"startLine":11}}}],"partialFingerprints":{"codehealthFindingId/v1":"d0697cda75e4c36e818e92dd5b5043d170d2f21341f37b8467de6495f863b4d3"}},{"ruleId":"PF3","level":"warning","message":{"text":"Sync-over-async blocking: \u0060readFileSync\u0060 in \u0060json\u0060 blocks the event loop until it finishes \u2014 a blocking call inside async code stalls the event loop \u2014 every other request waits for as long as it runs."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"tools/wiki/dom.mjs"},"region":{"startLine":19}}}],"partialFingerprints":{"codehealthFindingId/v1":"3fce9adf641ba4d5aed986345983b1e9063ee6b75008e76615b6a485926bc40e"}},{"ruleId":"PF3","level":"warning","message":{"text":"Sync-over-async blocking: \u0060readFileSync\u0060 in \u0060load\u0060 blocks the event loop until it finishes \u2014 a blocking call inside async code stalls the event loop \u2014 every other request waits for as long as it runs."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"tools/wiki/dom.mjs"},"region":{"startLine":25}}}],"partialFingerprints":{"codehealthFindingId/v1":"8652536a07cb18ecd692e834a36d17980f7a04ad552dc3967e906b8a4e0da330"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplication concentrated across 2 sibling directories (24 clone groups): 24 duplicated blocks under frontend/src/ have copies in at least two of the sibling directories components, pages \u2014 8 of them are reported below, and 16 are counted here but not reported individually: those copies match on shape but no longer clear R10\u0027s bar for an individually reported row \u2014 either they kept neither their own names nor their values, or what was copied is too small to stand on its own (it reports near-exact duplication only, and only of substantial extent). What this row states is the concentration, which the detector measured over all 24 and which does not depend on how exactly each block\u0027s copies still match. That concentration is one structural fact, not 24 local ones: the siblings replicate behaviour none of them owns, which is the shape of a missing shared module \u2014 a common library every sibling imports \u2014 rather than 24 separate extractions. Check first whether the siblings are deliberately standalone deliverables (scaffold templates, demo apps that must stay copy-pasteable); where they are, the duplication is the design and the per-block rows are the ones to act on."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/charts/RegimeTimeline.tsx"},"region":{"startLine":121}}}],"partialFingerprints":{"codehealthFindingId/v1":"d23054e0ea51626333990effd63fc2e1193f1da90b150fa822b19fad5b4dcf63"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block with local edits (86 matched lines \u00D7 2 locations): desktop/electron/scripts/build-review-installer.mjs:34 \u00B7 desktop/electron/scripts/build-signed-installer.mjs:48 \u2014 the two spans are one implementation copied and then locally edited \u2014 581 tokens are still identical, in the same order in both files, with only local edits between them. The copies have already begun to drift, which is this row\u0027s finding: an edit made to one and not the other changes behaviour silently. Diff the two spans first to learn what genuinely differs, then extract the shared core into one module both sites use, passing the differences in as parameters \u2014 or, if one copy exists only because the other could not be imported from its context, make one of them the single source the other is generated or re-exported from. If one copy is no longer reachable, delete it rather than letting it shadow the live one."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"desktop/electron/scripts/build-review-installer.mjs"},"region":{"startLine":34}}}],"partialFingerprints":{"codehealthFindingId/v1":"09228f112443df3dec0b27083c9b1a96c714edc18f15266f92446f09971f16c5"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block with local edits (64 matched lines \u00D7 2 locations): frontend/src/lib/api.ts:674 \u00B7 frontend/src/lib/api.ts:843 \u2014 the two spans are one implementation copied and then locally edited \u2014 501 tokens are still identical, in the same order in both spans, with only local edits between them. The copies have already begun to drift, which is this row\u0027s finding: an edit made to one and not the other changes behaviour silently. Diff the two spans first to learn what genuinely differs, then extract the shared core into one module both sites use, passing the differences in as parameters \u2014 or, if one copy exists only because the other could not be imported from its context, make one of them the single source the other is generated or re-exported from. If one copy is no longer reachable, delete it rather than letting it shadow the live one."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/lib/api.ts"},"region":{"startLine":674}}}],"partialFingerprints":{"codehealthFindingId/v1":"bc1dcc0b4f595b1536adf9cc8b232a16051d1972ca78da34ea48d5b67a0508c8"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (33 lines \u00D7 2 locations): frontend/src/pages/Settings.tsx:658 \u00B7 frontend/src/pages/Settings.tsx:693 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Settings.tsx"},"region":{"startLine":658}}}],"partialFingerprints":{"codehealthFindingId/v1":"edac7621e1f979f7e72886310f5ddc0c889026518860b61f5038ef4226341fc9"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (27 lines \u00D7 2 locations): frontend/src/pages/AlphaZoo.tsx:717 \u00B7 frontend/src/pages/AlphaZoo.tsx:1097 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/AlphaZoo.tsx"},"region":{"startLine":717}}}],"partialFingerprints":{"codehealthFindingId/v1":"9f1fdc047d66611958b555b223035777c2831868ac120d5099795e3c1287c77b"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (25 lines \u00D7 2 locations): frontend/src/pages/Compare.tsx:258 \u00B7 frontend/src/pages/Compare.tsx:289 \u2014 all 2 copies are in the same file, and the CITED SPAN is not a self-contained block \u2014 it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead \u2014 the whole function, component or branch these lines sit in \u2014 and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Compare.tsx"},"region":{"startLine":258}}}],"partialFingerprints":{"codehealthFindingId/v1":"ea039bcf5c0f4b34ddda0d0bccf74789353c851b992c90be374f3a016dd4dfe5"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (25 lines \u00D7 2 locations): frontend/src/pages/PaperTrading.tsx:295 \u00B7 frontend/src/pages/PaperTrading.tsx:426 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/PaperTrading.tsx"},"region":{"startLine":295}}}],"partialFingerprints":{"codehealthFindingId/v1":"e90ab460df35ee71b7611d7877c63a315a9ad01a930cb9ff8e5f0f5ccc6b2bcc"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (20 lines \u00D7 2 locations): frontend/src/components/chat/Composer.tsx:350 \u00B7 frontend/src/components/chat/Composer.tsx:370 \u2014 all 2 copies are in the same file, and the CITED SPAN is not a self-contained block \u2014 it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead \u2014 the whole function, component or branch these lines sit in \u2014 and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/chat/Composer.tsx"},"region":{"startLine":350}}}],"partialFingerprints":{"codehealthFindingId/v1":"4a03933e77b72caa41f0bd253362070ba38bb88de7b65de65ca959de41a0cfb9"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (19 lines \u00D7 2 locations): frontend/src/components/charts/RegimeTimeline.tsx:121 \u00B7 frontend/src/pages/Compare.tsx:209 \u2014 the 2 copies are spread across 2 files, and the CITED SPAN is not a self-contained block \u2014 it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead \u2014 the whole function, component or branch these lines sit in \u2014 and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/charts/RegimeTimeline.tsx"},"region":{"startLine":121}}}],"partialFingerprints":{"codehealthFindingId/v1":"d617e9b6dc9f55ab424db120f58aa7e65078f7278b67d93f2098b5d62338a499"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (19 lines \u00D7 2 locations): frontend/src/pages/PaperTrading.tsx:256 \u00B7 frontend/src/pages/PaperTrading.tsx:383 \u2014 all 2 copies are in the same file, and the SHAPE of this repetition could not be determined. It is not a run of declarations, a listing, a declaration header, a type body or a slice through a construct \u2014 and it was not measured as a run of executable statements either, so this row cannot tell you whether a function can stand where these lines are. Read the two spans before acting, because the move is opposite in the two cases. Where they are statements, the ordinary answer holds: give the shared part one home and call it from each site. Where they turn out to be declarations, a literal\u0027s entries, or the cases of an enumeration, there is no call site to call anything from, and collapsing them would delete what each copy pins \u2014 a shared base type, a generated set, or one exported constant each site refers to is the move instead, and sometimes the honest answer is that there is nothing to extract at all. Reported because the copies drift apart the first time only one of them is edited, which is true whichever of those they are."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/PaperTrading.tsx"},"region":{"startLine":256}}}],"partialFingerprints":{"codehealthFindingId/v1":"6a3c8a7df3480310cc84fc232c20630e8415b5984e161ec5c489e56d152d507c"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (17 lines \u00D7 2 locations): frontend/src/pages/Settings.tsx:621 \u00B7 frontend/src/pages/Settings.tsx:735 \u2014 all 2 copies are in the same file, and the CITED SPAN is not a self-contained block \u2014 it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead \u2014 the whole function, component or branch these lines sit in \u2014 and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Settings.tsx"},"region":{"startLine":621}}}],"partialFingerprints":{"codehealthFindingId/v1":"37e2969dbced4ddc817b0b2a8e23ce805dedc5cfd2f1b681a182b5bf864a21f6"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (16 lines \u00D7 2 locations): desktop/electron/scripts/process-sentinel.mjs:34 \u00B7 desktop/electron/src/backend-manager.ts:521 \u2014 the 2 copies are spread across 2 directories, so the shared home is a decision rather than an obvious spot: check first whether one of them already owns this behaviour, and otherwise put the extracted module somewhere all of the sites already reach rather than making one of them depend on another."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"desktop/electron/scripts/process-sentinel.mjs"},"region":{"startLine":34}}}],"partialFingerprints":{"codehealthFindingId/v1":"3282fe82ae6bddd485b0439e2d54aa67cdb6d0b5cd79d3309d3d88d0949e231b"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (16 lines \u00D7 3 locations): frontend/src/lib/swarmStatus.ts:308 \u00B7 frontend/src/lib/swarmStatus.ts:328 \u00B7 frontend/src/lib/swarmStatus.ts:347 \u2014 all 3 copies are in the same file, and the CITED SPAN is not a self-contained block \u2014 it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead \u2014 the whole function, component or branch these lines sit in \u2014 and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/lib/swarmStatus.ts"},"region":{"startLine":308}}}],"partialFingerprints":{"codehealthFindingId/v1":"2ab7cb1312c0fad6b13bfb53a7728a95575eab4b234ff7cb2dfc19648f44230b"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (16 lines \u00D7 3 locations): frontend/src/pages/Settings.tsx:509 \u00B7 frontend/src/pages/Settings.tsx:659 \u00B7 frontend/src/pages/Settings.tsx:694 \u2014 all 3 copies are in the same file, and the CITED SPAN is not a self-contained block \u2014 it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead \u2014 the whole function, component or branch these lines sit in \u2014 and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Settings.tsx"},"region":{"startLine":509}}}],"partialFingerprints":{"codehealthFindingId/v1":"563596c1d046c9d807f70e362ca3347408b8dd2d6a41268b5885f0443888333f"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block with local edits (15 matched lines \u00D7 2 locations): frontend/src/components/portfolio/ConnectionCenter.tsx:74 \u00B7 frontend/src/components/portfolio/ConnectionCenter.tsx:103 \u2014 the two spans are one implementation copied and then locally edited \u2014 73 tokens are still identical, in the same order in both spans, with only local edits between them. The copies have already begun to drift, which is this row\u0027s finding: an edit made to one and not the other changes behaviour silently. Diff the two spans first to learn what genuinely differs, then extract the shared core into one module both sites use, passing the differences in as parameters \u2014 or, if one copy exists only because the other could not be imported from its context, make one of them the single source the other is generated or re-exported from. If one copy is no longer reachable, delete it rather than letting it shadow the live one."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/portfolio/ConnectionCenter.tsx"},"region":{"startLine":74}}}],"partialFingerprints":{"codehealthFindingId/v1":"8ac6f87003ee718a48b84d1c6985d7626f9548968a95316a5a06ca81ff573cb2"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (15 lines \u00D7 2 locations): frontend/src/components/settings/HistoryStorageSettings.tsx:15 \u00B7 frontend/src/components/settings/SourcePrioritySettings.tsx:34 \u2014 the 2 copies sit in sibling files in one directory, so check first whether one of them (or an existing module there) already owns this behaviour and the others should call it; otherwise extract it into one module in that directory and have each site call it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/settings/HistoryStorageSettings.tsx"},"region":{"startLine":15}}}],"partialFingerprints":{"codehealthFindingId/v1":"39b4ce64970b26bf542776fdb48cc6351c20ffffa0acf9baf526db8e34b144e9"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (15 lines \u00D7 2 locations): frontend/src/pages/Agent.tsx:1062 \u00B7 frontend/src/pages/Agent.tsx:1099 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Agent.tsx"},"region":{"startLine":1062}}}],"partialFingerprints":{"codehealthFindingId/v1":"d0bc921ff73802df9cde9baee54caab3eb8315938ea860d19e8263ad2ebf8fdf"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (15 lines \u00D7 2 locations): frontend/src/pages/Reports.tsx:161 \u00B7 frontend/src/pages/Runtime.tsx:113 \u2014 the 2 copies are spread across 2 files, and the SHAPE of this repetition could not be determined. It is not a run of declarations, a listing, a declaration header, a type body or a slice through a construct \u2014 and it was not measured as a run of executable statements either, so this row cannot tell you whether a function can stand where these lines are. Read the two spans before acting, because the move is opposite in the two cases. Where they are statements, the ordinary answer holds: give the shared part one home and call it from each site. Where they turn out to be declarations, a literal\u0027s entries, or the cases of an enumeration, there is no call site to call anything from, and collapsing them would delete what each copy pins \u2014 a shared base type, a generated set, or one exported constant each site refers to is the move instead, and sometimes the honest answer is that there is nothing to extract at all. Reported because the copies drift apart the first time only one of them is edited, which is true whichever of those they are."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Reports.tsx"},"region":{"startLine":161}}}],"partialFingerprints":{"codehealthFindingId/v1":"41e498dd32ef98d5f0e20fb51c4f5e8621eb34429acfc7a4686f63ecaf8ba7aa"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (15 lines \u00D7 2 locations): frontend/src/pages/Runtime.tsx:516 \u00B7 frontend/src/pages/Scheduled.tsx:76 \u2014 the 2 copies sit in sibling files in one directory, so check first whether one of them (or an existing module there) already owns this behaviour and the others should call it; otherwise extract it into one module in that directory and have each site call it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Runtime.tsx"},"region":{"startLine":516}}}],"partialFingerprints":{"codehealthFindingId/v1":"01a980739dcac2b493ec3a2687b9eb53cc769bab1d429a0cee5a7c63c42fcbdc"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (15 lines \u00D7 2 locations): frontend/src/pages/Settings.tsx:255 \u00B7 frontend/src/pages/Settings.tsx:300 \u2014 all 2 copies are in the same file, and the CITED SPAN is not a self-contained block \u2014 it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead \u2014 the whole function, component or branch these lines sit in \u2014 and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Settings.tsx"},"region":{"startLine":255}}}],"partialFingerprints":{"codehealthFindingId/v1":"739d3d48861fb3528762be9939474e28d4d1c1c40864edda4bf2ba8a08f36aa7"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 2 locations): frontend/src/components/charts/AttributionCumulativeChart.tsx:24 \u00B7 frontend/src/components/charts/RollingBetaAlphaChart.tsx:23 \u2014 the 2 copies are spread across 2 files, and the CITED SPAN is not a self-contained block \u2014 it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead \u2014 the whole function, component or branch these lines sit in \u2014 and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/charts/AttributionCumulativeChart.tsx"},"region":{"startLine":24}}}],"partialFingerprints":{"codehealthFindingId/v1":"aa7cf74005ffcad1c96b7486819759d8e6e5b65bd167b5a82e807b44854a61b8"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 2 locations): frontend/src/components/charts/CandlestickChart.tsx:94 \u00B7 frontend/src/components/charts/MiniEquityChart.tsx:38 \u2014 the 2 copies are spread across 2 files, and the CITED SPAN is not a self-contained block \u2014 it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead \u2014 the whole function, component or branch these lines sit in \u2014 and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/charts/CandlestickChart.tsx"},"region":{"startLine":94}}}],"partialFingerprints":{"codehealthFindingId/v1":"bc7c6ae55a4b1f73e52ea6c67b45c8830a7d458a1ef74b6f65d6cc1b6fd02daa"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block with local edits (14 matched lines \u00D7 2 locations): frontend/src/components/charts/EquityChart.tsx:32 \u00B7 frontend/src/components/charts/WalkForwardChart.tsx:31 \u2014 the two spans are one implementation copied and then locally edited \u2014 87 tokens are still identical, in the same order in both files, with only local edits between them. The copies have already begun to drift, which is this row\u0027s finding: an edit made to one and not the other changes behaviour silently. Diff the two spans first to learn what genuinely differs, then extract the shared core into one module both sites use, passing the differences in as parameters \u2014 or, if one copy exists only because the other could not be imported from its context, make one of them the single source the other is generated or re-exported from. If one copy is no longer reachable, delete it rather than letting it shadow the live one."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/charts/EquityChart.tsx"},"region":{"startLine":32}}}],"partialFingerprints":{"codehealthFindingId/v1":"88f57b93163bdaf998a43e77c892b43de5fc7436d2d996e81d2f24d9be7cedf2"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block with local edits (13 matched lines \u00D7 2 locations): frontend/src/components/charts/EquityChart.tsx:32 \u00B7 frontend/src/components/charts/RegimeTimeline.tsx:39 \u2014 the two spans are one implementation copied and then locally edited \u2014 84 tokens are still identical, in the same order in both files, with only local edits between them. The copies have already begun to drift, which is this row\u0027s finding: an edit made to one and not the other changes behaviour silently. Diff the two spans first to learn what genuinely differs, then extract the shared core into one module both sites use, passing the differences in as parameters \u2014 or, if one copy exists only because the other could not be imported from its context, make one of them the single source the other is generated or re-exported from. If one copy is no longer reachable, delete it rather than letting it shadow the live one."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/charts/EquityChart.tsx"},"region":{"startLine":32}}}],"partialFingerprints":{"codehealthFindingId/v1":"1703e750962d9ae1268de8253f6ae3b64073292184d16d188486426bc05a25ac"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2 locations): frontend/src/components/charts/FactorResearchPanel.tsx:193 \u00B7 frontend/src/components/charts/StrategyResearchDashboard.tsx:196 \u2014 the 2 copies are spread across 2 files, and the CITED SPAN is not a self-contained block \u2014 it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead \u2014 the whole function, component or branch these lines sit in \u2014 and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/charts/FactorResearchPanel.tsx"},"region":{"startLine":193}}}],"partialFingerprints":{"codehealthFindingId/v1":"1de5df241160cd2ae290e3062ad48613d6386d5dcc9ca0d316c2297898714745"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block with local edits (13 matched lines \u00D7 2 locations): frontend/src/components/chat/Composer.tsx:236 \u00B7 frontend/src/components/layout/Layout.tsx:40 \u2014 the two spans are one implementation copied and then locally edited \u2014 77 tokens are still identical, in the same order in both files, with only local edits between them. The copies have already begun to drift, which is this row\u0027s finding: an edit made to one and not the other changes behaviour silently. Diff the two spans first to learn what genuinely differs, then extract the shared core into one module both sites use, passing the differences in as parameters \u2014 or, if one copy exists only because the other could not be imported from its context, make one of them the single source the other is generated or re-exported from. If one copy is no longer reachable, delete it rather than letting it shadow the live one."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/chat/Composer.tsx"},"region":{"startLine":236}}}],"partialFingerprints":{"codehealthFindingId/v1":"16eff5a5a012b5ef79ba2779c934835b4a33dfd4931564b14d22b604dd6bec39"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block with local edits (13 matched lines \u00D7 2 locations): frontend/src/components/chat/Composer.tsx:236 \u00B7 frontend/src/components/layout/SidebarNavigation.tsx:15 \u2014 the two spans are one implementation copied and then locally edited \u2014 78 tokens are still identical, in the same order in both files, with only local edits between them. The copies have already begun to drift, which is this row\u0027s finding: an edit made to one and not the other changes behaviour silently. Diff the two spans first to learn what genuinely differs, then extract the shared core into one module both sites use, passing the differences in as parameters \u2014 or, if one copy exists only because the other could not be imported from its context, make one of them the single source the other is generated or re-exported from. If one copy is no longer reachable, delete it rather than letting it shadow the live one."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/chat/Composer.tsx"},"region":{"startLine":236}}}],"partialFingerprints":{"codehealthFindingId/v1":"40d04b92ffbfc5a6bd2523bbe13350fb45b39543b1c41186d185b0dd2a27d71a"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2 locations): frontend/src/pages/Agent.tsx:1045 \u00B7 frontend/src/pages/Agent.tsx:1083 \u2014 all 2 copies are in the same file, and the CITED SPAN is not a self-contained block \u2014 it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead \u2014 the whole function, component or branch these lines sit in \u2014 and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Agent.tsx"},"region":{"startLine":1045}}}],"partialFingerprints":{"codehealthFindingId/v1":"431898b87eeeafd994cdabeba2a7fb9a9fe9b44b1c3a655b91a1bead37938043"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2 locations): frontend/src/pages/Agent.tsx:1485 \u00B7 frontend/src/pages/Agent.tsx:1590 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Agent.tsx"},"region":{"startLine":1485}}}],"partialFingerprints":{"codehealthFindingId/v1":"a158b853f77be6073a26d22fc7b1895bf2ddd6a39aae4d3adf8f94ec84912289"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 3 locations): frontend/src/pages/AlphaZoo.tsx:272 \u00B7 frontend/src/pages/AlphaZoo.tsx:288 \u00B7 frontend/src/pages/AlphaZoo.tsx:306 \u2014 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 \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/AlphaZoo.tsx"},"region":{"startLine":272}}}],"partialFingerprints":{"codehealthFindingId/v1":"bff355d0bf8ca9395f5486d72104037bb86988f48ae61cf0c3baef775e23b38f"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2 locations): frontend/src/pages/AlphaZoo.tsx:667 \u00B7 frontend/src/pages/AlphaZoo.tsx:1048 \u2014 all 2 copies are in the same file, and the CITED SPAN is not a self-contained block \u2014 it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead \u2014 the whole function, component or branch these lines sit in \u2014 and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/AlphaZoo.tsx"},"region":{"startLine":667}}}],"partialFingerprints":{"codehealthFindingId/v1":"87896b1eeb5c4d4effaeb7a96ad919044174f15b9376c03a92fef0e49b25e193"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2 locations): frontend/src/components/charts/CandlestickChart.tsx:213 \u00B7 frontend/src/pages/Compare.tsx:151 \u2014 the 2 copies are spread across 2 files, and the CITED SPAN is not a self-contained block \u2014 it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead \u2014 the whole function, component or branch these lines sit in \u2014 and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/charts/CandlestickChart.tsx"},"region":{"startLine":213}}}],"partialFingerprints":{"codehealthFindingId/v1":"3e1d2a0961a366d39268fb289b3e6a3258a9b3de86c42332abd4786f62592f78"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2 locations): frontend/src/components/charts/FactorResearchPanel.tsx:18 \u00B7 frontend/src/components/charts/StrategyResearchDashboard.tsx:18 \u2014 the 2 copies are spread across 2 files, and the CITED SPAN is not a self-contained block \u2014 it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead \u2014 the whole function, component or branch these lines sit in \u2014 and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/charts/FactorResearchPanel.tsx"},"region":{"startLine":18}}}],"partialFingerprints":{"codehealthFindingId/v1":"064428709655c38735053dc79ce89d379821fce7da2e69c32895673c40e8c504"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2 locations): frontend/src/components/charts/MonteCarloPathsChart.tsx:124 \u00B7 frontend/src/components/charts/WalkForwardChart.tsx:92 \u2014 the 2 copies are spread across 2 files, and the CITED SPAN is not a self-contained block \u2014 it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead \u2014 the whole function, component or branch these lines sit in \u2014 and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/charts/MonteCarloPathsChart.tsx"},"region":{"startLine":124}}}],"partialFingerprints":{"codehealthFindingId/v1":"01afd7a582057b5a7ecf25599c99c8cec860ccac60019b2d3fe6cca0c40ad7ce"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block with local edits (12 matched lines \u00D7 2 locations): frontend/src/components/layout/Layout.tsx:114 \u00B7 frontend/src/components/layout/Layout.tsx:128 \u2014 the two spans are one implementation copied and then locally edited \u2014 92 tokens are still identical, in the same order in both spans, with only local edits between them. The copies have already begun to drift, which is this row\u0027s finding: an edit made to one and not the other changes behaviour silently. Diff the two spans first to learn what genuinely differs, then extract the shared core into one module both sites use, passing the differences in as parameters \u2014 or, if one copy exists only because the other could not be imported from its context, make one of them the single source the other is generated or re-exported from. If one copy is no longer reachable, delete it rather than letting it shadow the live one."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/layout/Layout.tsx"},"region":{"startLine":114}}}],"partialFingerprints":{"codehealthFindingId/v1":"25dd57905ba27364a5ce80a49e79bef33dd900a2e85d8f4e7f503a6b5a2c7976"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2 locations): frontend/src/lib/chart-theme.ts:5 \u00B7 frontend/src/lib/pnl-colors.ts:14 \u2014 the 2 copies sit in sibling files in one directory, so check first whether one of them (or an existing module there) already owns this behaviour and the others should call it; otherwise extract it into one module in that directory and have each site call it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/lib/chart-theme.ts"},"region":{"startLine":5}}}],"partialFingerprints":{"codehealthFindingId/v1":"1a59cac47eba35b38ca2bdcd1c3aba90af01fb8811ef3bf04bb886f390de33bd"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2 locations): frontend/src/pages/Settings.tsx:84 \u00B7 frontend/src/pages/Settings.tsx:99 \u2014 all 2 copies are in the same file, and the CITED SPAN is not a self-contained block \u2014 it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead \u2014 the whole function, component or branch these lines sit in \u2014 and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Settings.tsx"},"region":{"startLine":84}}}],"partialFingerprints":{"codehealthFindingId/v1":"6000d09bfd2f1ba5bd3474aed55e665cfea2944cc938d68115f58bccef26d9ad"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 3 locations): frontend/src/pages/Settings.tsx:526 \u00B7 frontend/src/pages/Settings.tsx:678 \u00B7 frontend/src/pages/Settings.tsx:713 \u2014 all 3 copies are in the same file, and the SHAPE of this repetition could not be determined. It is not a run of declarations, a listing, a declaration header, a type body or a slice through a construct \u2014 and it was not measured as a run of executable statements either, so this row cannot tell you whether a function can stand where these lines are. Read the two spans before acting, because the move is opposite in the two cases. Where they are statements, the ordinary answer holds: give the shared part one home and call it from each site. Where they turn out to be declarations, a literal\u0027s entries, or the cases of an enumeration, there is no call site to call anything from, and collapsing them would delete what each copy pins \u2014 a shared base type, a generated set, or one exported constant each site refers to is the move instead, and sometimes the honest answer is that there is nothing to extract at all. Reported because the copies drift apart the first time only one of them is edited, which is true whichever of those they are."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Settings.tsx"},"region":{"startLine":526}}}],"partialFingerprints":{"codehealthFindingId/v1":"0b1defb856c6025ac98503bd327606d4fb93bc883a285b978d5d19ab14e28e0f"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 3 locations): frontend/src/pages/Settings.tsx:550 \u00B7 frontend/src/pages/Settings.tsx:563 \u00B7 frontend/src/pages/Settings.tsx:576 \u2014 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 \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Settings.tsx"},"region":{"startLine":550}}}],"partialFingerprints":{"codehealthFindingId/v1":"1d5aaee78c39b3d8d06b40a30af6320a65d93290ee89102d63992f237059d409"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2 locations): desktop/electron/src/backend-manager.ts:480 \u00B7 desktop/electron/src/backend-watchdog.ts:128 \u2014 the 2 copies sit in sibling files in one directory, so check first whether one of them (or an existing module there) already owns this behaviour and the others should call it; otherwise extract it into one module in that directory and have each site call it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"desktop/electron/src/backend-manager.ts"},"region":{"startLine":480}}}],"partialFingerprints":{"codehealthFindingId/v1":"1cf40ecdab76d4a2a3912270af65666f7ec17e4dbb17ccafa60114c45062f977"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2 locations): frontend/src/components/charts/MonteCarloPathsChart.tsx:9 \u00B7 frontend/src/components/charts/RegimeTimeline.tsx:8 \u2014 the 2 copies sit in sibling files in one directory, so check first whether one of them (or an existing module there) already owns this behaviour and the others should call it; otherwise extract it into one module in that directory and have each site call it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/charts/MonteCarloPathsChart.tsx"},"region":{"startLine":9}}}],"partialFingerprints":{"codehealthFindingId/v1":"45ff7d11aa085ec1a2c99dc7dfb8ca1032e304474dd01912f18df27110d71286"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2 locations): frontend/src/components/charts/ValidationPanel.tsx:68 \u00B7 frontend/src/components/charts/ValidationPanel.tsx:117 \u2014 all 2 copies are in the same file, and the CITED SPAN is a run of DECLARATIONS inside a construct \u2014 the members of a type, or the entries of an object or array literal \u2014 with no statement anywhere in it. Do not read this as an extract-a-helper row: nothing here executes, so there is no call site, and a call expression cannot stand where a member declaration or a literal\u0027s entry was. What repeats is a SHAPE, and which shape decides the move. Where the copies declare the same members, the repetition is a missing common ancestor: give it a base type, an interface both extend, a generic instantiated twice, or \u2014 where the copies are a literal\u0027s entries rather than a type\u0027s members \u2014 one shared constant each site spreads or refers to, so the set is written once. Where they declare DIFFERENT members and only the form is shared \u2014 a decorator and its options, an annotation, a registration table\u0027s keys \u2014 the form is prescribed by a framework or a schema rather than copied, and the only collapse available is to generate the declarations from that schema; where you do not own the generator, this is the cost of the framework and there is nothing to extract. Check which of the two it is before acting: these copies still drift apart the first time only one of them is edited, which is why the repetition is reported, but the sentence to act on is not the same in both cases."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/charts/ValidationPanel.tsx"},"region":{"startLine":68}}}],"partialFingerprints":{"codehealthFindingId/v1":"56336b8d7d22480e7ea7695af25ac64c631ff3699e54bf1db0b9253f88ab212f"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2 locations): frontend/src/components/chat/MandateProposalCard.tsx:114 \u00B7 frontend/src/components/chat/MandateProposalCard.tsx:441 \u2014 all 2 copies are in the same file, and the SHAPE of this repetition could not be determined. It is not a run of declarations, a listing, a declaration header, a type body or a slice through a construct \u2014 and it was not measured as a run of executable statements either, so this row cannot tell you whether a function can stand where these lines are. Read the two spans before acting, because the move is opposite in the two cases. Where they are statements, the ordinary answer holds: give the shared part one home and call it from each site. Where they turn out to be declarations, a literal\u0027s entries, or the cases of an enumeration, there is no call site to call anything from, and collapsing them would delete what each copy pins \u2014 a shared base type, a generated set, or one exported constant each site refers to is the move instead, and sometimes the honest answer is that there is nothing to extract at all. Reported because the copies drift apart the first time only one of them is edited, which is true whichever of those they are."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/chat/MandateProposalCard.tsx"},"region":{"startLine":114}}}],"partialFingerprints":{"codehealthFindingId/v1":"72ed80f88dfc0e72e87c146e60bfd4d0b4b5d22b17d9f467f6ab74ec5b9080ec"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 3 locations): frontend/src/components/options/StrategyBuilder.tsx:193 \u00B7 frontend/src/components/options/StrategyBuilder.tsx:205 \u00B7 frontend/src/components/options/StrategyBuilder.tsx:232 \u2014 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 \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/options/StrategyBuilder.tsx"},"region":{"startLine":193}}}],"partialFingerprints":{"codehealthFindingId/v1":"d4f693dc4f789ae2e651ec7d341d853fef18b2ed2fae9d436c937db3fc2f04d2"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2 locations): frontend/src/components/settings/ChannelConfigPanel.tsx:601 \u00B7 frontend/src/components/settings/ChannelConfigPanel.tsx:634 \u2014 all 2 copies are in the same file, and the CITED SPAN is not a self-contained block \u2014 it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead \u2014 the whole function, component or branch these lines sit in \u2014 and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/settings/ChannelConfigPanel.tsx"},"region":{"startLine":601}}}],"partialFingerprints":{"codehealthFindingId/v1":"9514c0ac7e289aa640210c4d42d8aea4dd0865c56ff15c81c0c97bd6113de601"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2 locations): frontend/src/pages/PaperTrading.tsx:43 \u00B7 frontend/src/pages/PaperTrading.tsx:63 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/PaperTrading.tsx"},"region":{"startLine":43}}}],"partialFingerprints":{"codehealthFindingId/v1":"cba7476f1f3ade8afc6cab3bca402b5c9b92499492ad30eb0e0970314b834def"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 3 locations): frontend/src/components/charts/AnnualReturnsChart.tsx:71 \u00B7 frontend/src/components/charts/AttributionCumulativeChart.tsx:101 \u00B7 frontend/src/components/charts/RollingBetaAlphaChart.tsx:102 \u2014 the 3 copies are spread across 3 files, and the CITED SPAN is not a self-contained block \u2014 it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead \u2014 the whole function, component or branch these lines sit in \u2014 and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/charts/AnnualReturnsChart.tsx"},"region":{"startLine":71}}}],"partialFingerprints":{"codehealthFindingId/v1":"564350114becf30e96d1ecd8f5f363c877bc26e63065d596cbba0d3a73339da1"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2 locations): frontend/src/components/charts/CorrelationMatrix.tsx:54 \u00B7 frontend/src/components/charts/OptionsScenarioMatrix.tsx:44 \u2014 the 2 copies are spread across 2 files, and the CITED SPAN is not a self-contained block \u2014 it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead \u2014 the whole function, component or branch these lines sit in \u2014 and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/charts/CorrelationMatrix.tsx"},"region":{"startLine":54}}}],"partialFingerprints":{"codehealthFindingId/v1":"b6756f70bde4dc8e1c37dc53fb0794f407d9d424516ec3a1318810fda36aaf09"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2 locations): frontend/src/components/charts/EquityChart.tsx:110 \u00B7 frontend/src/components/charts/MonthlyReturnsHeatmap.tsx:109 \u2014 the 2 copies are spread across 2 files, and the CITED SPAN is not a self-contained block \u2014 it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead \u2014 the whole function, component or branch these lines sit in \u2014 and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/charts/EquityChart.tsx"},"region":{"startLine":110}}}],"partialFingerprints":{"codehealthFindingId/v1":"c702661923468ccaa08cb754156d30c98155b7ff949c9cb7828f31b904b7361c"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2 locations): frontend/src/components/options/StrategyBuilder.tsx:121 \u00B7 frontend/src/components/options/StrategyBuilder.tsx:131 \u2014 all 2 copies are in the same file, and the SHAPE of this repetition could not be determined. It is not a run of declarations, a listing, a declaration header, a type body or a slice through a construct \u2014 and it was not measured as a run of executable statements either, so this row cannot tell you whether a function can stand where these lines are. Read the two spans before acting, because the move is opposite in the two cases. Where they are statements, the ordinary answer holds: give the shared part one home and call it from each site. Where they turn out to be declarations, a literal\u0027s entries, or the cases of an enumeration, there is no call site to call anything from, and collapsing them would delete what each copy pins \u2014 a shared base type, a generated set, or one exported constant each site refers to is the move instead, and sometimes the honest answer is that there is nothing to extract at all. Reported because the copies drift apart the first time only one of them is edited, which is true whichever of those they are."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/options/StrategyBuilder.tsx"},"region":{"startLine":121}}}],"partialFingerprints":{"codehealthFindingId/v1":"4c820e3a0d54b2b23a0518cca81796cbf2895bcfcd8eb52b8a3914fbebf6b5c8"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2 locations): frontend/src/pages/AlphaZoo.tsx:759 \u00B7 frontend/src/pages/AlphaZoo.tsx:1140 \u2014 all 2 copies are in the same file, and the CITED SPAN is not a self-contained block \u2014 it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead \u2014 the whole function, component or branch these lines sit in \u2014 and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/AlphaZoo.tsx"},"region":{"startLine":759}}}],"partialFingerprints":{"codehealthFindingId/v1":"9df948f027fe9c7cdbd64886c73d79f5e5b5a69e6288c36de0566290e98a94a0"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2 locations): frontend/src/pages/Compare.tsx:437 \u00B7 frontend/src/pages/Compare.tsx:447 \u2014 all 2 copies are in the same file, and the SHAPE of this repetition could not be determined. It is not a run of declarations, a listing, a declaration header, a type body or a slice through a construct \u2014 and it was not measured as a run of executable statements either, so this row cannot tell you whether a function can stand where these lines are. Read the two spans before acting, because the move is opposite in the two cases. Where they are statements, the ordinary answer holds: give the shared part one home and call it from each site. Where they turn out to be declarations, a literal\u0027s entries, or the cases of an enumeration, there is no call site to call anything from, and collapsing them would delete what each copy pins \u2014 a shared base type, a generated set, or one exported constant each site refers to is the move instead, and sometimes the honest answer is that there is nothing to extract at all. Reported because the copies drift apart the first time only one of them is edited, which is true whichever of those they are."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Compare.tsx"},"region":{"startLine":437}}}],"partialFingerprints":{"codehealthFindingId/v1":"aa916a98fd394c4b045cf032f7b0e550450135941bb0edc9cc218ac919385a20"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 3 locations): frontend/src/components/charts/DistributionChart.tsx:96 \u00B7 frontend/src/components/charts/MonteCarloPathsChart.tsx:126 \u00B7 frontend/src/components/charts/WalkForwardChart.tsx:94 \u2014 the 3 copies are spread across 3 files, and the CITED SPAN is not a self-contained block \u2014 it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead \u2014 the whole function, component or branch these lines sit in \u2014 and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/charts/DistributionChart.tsx"},"region":{"startLine":96}}}],"partialFingerprints":{"codehealthFindingId/v1":"53626548103cc88f3e27398ed8e70c3ea8661e9d1bd0701efa5125d3d994e941"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2 locations): frontend/src/components/chat/GoalPanel.tsx:8 \u00B7 frontend/src/pages/Agent.tsx:197 \u2014 the 2 copies are spread across 2 files, and the CITED SPAN is not a self-contained block \u2014 it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead \u2014 the whole function, component or branch these lines sit in \u2014 and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/chat/GoalPanel.tsx"},"region":{"startLine":8}}}],"partialFingerprints":{"codehealthFindingId/v1":"8562c3a10248e2772e9ffd6638745aef9ee22fe15754851be9205d9182b4cc79"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2 locations): frontend/src/lib/swarmStatus.ts:338 \u00B7 frontend/src/lib/swarmStatus.ts:358 \u2014 all 2 copies are in the same file, and the CITED SPAN is not a self-contained block \u2014 it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead \u2014 the whole function, component or branch these lines sit in \u2014 and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/lib/swarmStatus.ts"},"region":{"startLine":338}}}],"partialFingerprints":{"codehealthFindingId/v1":"357add7b7a5a371e94d11bc1cdd23b85457850880d0a55c5fc20cd60c4d9bb88"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2 locations): frontend/src/lib/tearsheet.ts:92 \u00B7 frontend/src/lib/tearsheet.ts:135 \u2014 all 2 copies are in the same file, and the CITED SPAN is not a self-contained block \u2014 it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead \u2014 the whole function, component or branch these lines sit in \u2014 and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/lib/tearsheet.ts"},"region":{"startLine":92}}}],"partialFingerprints":{"codehealthFindingId/v1":"12143f614f294bb2f196099f0ca1d02b04034aa39fefc5c16761256550568c98"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2 locations): frontend/src/pages/ResearchArtifacts.tsx:310 \u00B7 frontend/src/pages/ResearchArtifacts.tsx:320 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/ResearchArtifacts.tsx"},"region":{"startLine":310}}}],"partialFingerprints":{"codehealthFindingId/v1":"f9dd320d4d7f4878233aa2b8a546c1661c93b26909c49242e4db90aa40fd9a2c"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2 locations): frontend/src/pages/RunDetail.tsx:542 \u00B7 frontend/src/pages/RunDetail.tsx:566 \u2014 all 2 copies are in the same file, and the CITED SPAN is not a self-contained block \u2014 it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead \u2014 the whole function, component or branch these lines sit in \u2014 and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/RunDetail.tsx"},"region":{"startLine":542}}}],"partialFingerprints":{"codehealthFindingId/v1":"9ae89b3815ede7be65db1e48834d90fc270f67a31373aab2e141223f4d518655"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2 locations): frontend/src/pages/Settings.tsx:318 \u00B7 frontend/src/pages/Settings.tsx:649 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Settings.tsx"},"region":{"startLine":318}}}],"partialFingerprints":{"codehealthFindingId/v1":"913b11b7788827a1bdd01d7a08988c1d4d2d82b76f0fb82c8b7af69a5f58785b"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2 locations): frontend/src/pages/Settings.tsx:360 \u00B7 frontend/src/pages/Settings.tsx:404 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Settings.tsx"},"region":{"startLine":360}}}],"partialFingerprints":{"codehealthFindingId/v1":"5199879eb2670b2c955afbdebd865465fc4b7d63656644b36b106fe00793f978"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2 locations): frontend/src/stores/agent.ts:199 \u00B7 frontend/src/stores/agent.ts:216 \u2014 all 2 copies are in the same file, and the SHAPE of this repetition could not be determined. It is not a run of declarations, a listing, a declaration header, a type body or a slice through a construct \u2014 and it was not measured as a run of executable statements either, so this row cannot tell you whether a function can stand where these lines are. Read the two spans before acting, because the move is opposite in the two cases. Where they are statements, the ordinary answer holds: give the shared part one home and call it from each site. Where they turn out to be declarations, a literal\u0027s entries, or the cases of an enumeration, there is no call site to call anything from, and collapsing them would delete what each copy pins \u2014 a shared base type, a generated set, or one exported constant each site refers to is the move instead, and sometimes the honest answer is that there is nothing to extract at all. Reported because the copies drift apart the first time only one of them is edited, which is true whichever of those they are."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/stores/agent.ts"},"region":{"startLine":199}}}],"partialFingerprints":{"codehealthFindingId/v1":"5f5cbc303a285a7478d17f09f4b920f54b9e7bd601243e60300affbe9bf11247"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2 locations): desktop/electron/scripts/smoke-lifecycle.mjs:35 \u00B7 desktop/electron/scripts/smoke-lifecycle.mjs:43 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"desktop/electron/scripts/smoke-lifecycle.mjs"},"region":{"startLine":35}}}],"partialFingerprints":{"codehealthFindingId/v1":"ae2939e3799a7be171cc19d200bf81b1df39023a2010dcaa84bde43a2d281922"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 4 locations): frontend/src/components/charts/AnnualReturnsChart.tsx:8 \u00B7 frontend/src/components/charts/AttributionCumulativeChart.tsx:10 \u00B7 frontend/src/components/charts/AttributionWaterfallChart.tsx:37 \u00B7 frontend/src/components/charts/RollingBetaAlphaChart.tsx:9 \u2014 the 4 copies are spread across 4 files, and the CITED SPAN is not a self-contained block \u2014 it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead \u2014 the whole function, component or branch these lines sit in \u2014 and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/charts/AnnualReturnsChart.tsx"},"region":{"startLine":8}}}],"partialFingerprints":{"codehealthFindingId/v1":"fb24e516a65753aee446aade617b12a567c7abc41bb461ddcd7ca50fc0d0a656"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 4 locations): frontend/src/components/charts/MiniEquityChart.tsx:7 \u00B7 frontend/src/components/charts/MonteCarloPathsChart.tsx:10 \u00B7 frontend/src/components/charts/RegimeTimeline.tsx:9 \u00B7 frontend/src/components/charts/WalkForwardChart.tsx:11 \u2014 the 4 copies are spread across 4 files, and the CITED SPAN is not a self-contained block \u2014 it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead \u2014 the whole function, component or branch these lines sit in \u2014 and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/charts/MiniEquityChart.tsx"},"region":{"startLine":7}}}],"partialFingerprints":{"codehealthFindingId/v1":"2f569565a1ce3722535eddbf08eee5e96d9c5610535ec32ced23246ab2209332"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2 locations): frontend/src/components/options/StrategyBuilder.tsx:245 \u00B7 frontend/src/components/options/StrategyBuilder.tsx:254 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/options/StrategyBuilder.tsx"},"region":{"startLine":245}}}],"partialFingerprints":{"codehealthFindingId/v1":"e49c613b56517e363176d160f600ca343b41b17a5a2ab03bf6bec9ef3b30ecf9"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2 locations): frontend/src/components/settings/ChannelSettings.tsx:175 \u00B7 frontend/src/components/settings/ChannelSettings.tsx:184 \u2014 all 2 copies are in the same file, and the SHAPE of this repetition could not be determined. It is not a run of declarations, a listing, a declaration header, a type body or a slice through a construct \u2014 and it was not measured as a run of executable statements either, so this row cannot tell you whether a function can stand where these lines are. Read the two spans before acting, because the move is opposite in the two cases. Where they are statements, the ordinary answer holds: give the shared part one home and call it from each site. Where they turn out to be declarations, a literal\u0027s entries, or the cases of an enumeration, there is no call site to call anything from, and collapsing them would delete what each copy pins \u2014 a shared base type, a generated set, or one exported constant each site refers to is the move instead, and sometimes the honest answer is that there is nothing to extract at all. Reported because the copies drift apart the first time only one of them is edited, which is true whichever of those they are."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/settings/ChannelSettings.tsx"},"region":{"startLine":175}}}],"partialFingerprints":{"codehealthFindingId/v1":"cf5f042f0df5f8d471de5b0321b680396ce99b2a55c50751371f02c7fc0ff7b6"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block with local edits (8 matched lines \u00D7 2 locations): frontend/src/components/settings/SourcePrioritySettings.tsx:50 \u00B7 frontend/src/pages/Settings.tsx:60 \u2014 the two spans are one implementation copied and then locally edited \u2014 66 tokens are still identical, in the same order in both files, with only local edits between them. The copies have already begun to drift, which is this row\u0027s finding: an edit made to one and not the other changes behaviour silently. Diff the two spans first to learn what genuinely differs, then extract the shared core into one module both sites use, passing the differences in as parameters \u2014 or, if one copy exists only because the other could not be imported from its context, make one of them the single source the other is generated or re-exported from. If one copy is no longer reachable, delete it rather than letting it shadow the live one."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/settings/SourcePrioritySettings.tsx"},"region":{"startLine":50}}}],"partialFingerprints":{"codehealthFindingId/v1":"c37a863b2a301f7c3510136af9ab519cb6f0343bce3ac954c264b7ae21d6f8df"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2 locations): frontend/src/pages/Agent.tsx:1427 \u00B7 frontend/src/pages/Agent.tsx:1580 \u2014 all 2 copies are in the same file, and the CITED SPAN is not a self-contained block \u2014 it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead \u2014 the whole function, component or branch these lines sit in \u2014 and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Agent.tsx"},"region":{"startLine":1427}}}],"partialFingerprints":{"codehealthFindingId/v1":"d02c6fa952d1a193b40b6cffd8fa1e6a0ad5f5cf3bd7279021d9928d3c63502a"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2 locations): frontend/src/pages/Agent.tsx:1689 \u00B7 frontend/src/pages/Portfolio.tsx:260 \u2014 the 2 copies sit in sibling files in one directory, so check first whether one of them (or an existing module there) already owns this behaviour and the others should call it; otherwise extract it into one module in that directory and have each site call it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Agent.tsx"},"region":{"startLine":1689}}}],"partialFingerprints":{"codehealthFindingId/v1":"cb88b58b6efbff1497ee359753afb942ec9eab3c6da7c59fded916dafed406f5"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 3 locations): frontend/src/pages/AlphaZoo.tsx:319 \u00B7 frontend/src/pages/AlphaZoo.tsx:721 \u00B7 frontend/src/pages/AlphaZoo.tsx:1101 \u2014 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 \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/AlphaZoo.tsx"},"region":{"startLine":319}}}],"partialFingerprints":{"codehealthFindingId/v1":"96a74300f8221ec76949752c2c8944e64d507c71fac72c98cedd22d159b394bf"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 6 locations): frontend/src/pages/AlphaZoo.tsx:695 \u00B7 frontend/src/pages/AlphaZoo.tsx:711 \u00B7 frontend/src/pages/AlphaZoo.tsx:727 \u00B7 frontend/src/pages/AlphaZoo.tsx:1091 \u00B7 \u002B2 more site(s) not listed \u2014 all 6 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/AlphaZoo.tsx"},"region":{"startLine":695}}}],"partialFingerprints":{"codehealthFindingId/v1":"7e57a1073794a6d4b821141dd24f92d2545a440526e7429e1e5ec546a9ce2661"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2 locations): frontend/src/pages/RunDetail.tsx:560 \u00B7 frontend/src/pages/RunDetail.tsx:579 \u2014 all 2 copies are in the same file, and the CITED SPAN is not a self-contained block \u2014 it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead \u2014 the whole function, component or branch these lines sit in \u2014 and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/RunDetail.tsx"},"region":{"startLine":560}}}],"partialFingerprints":{"codehealthFindingId/v1":"66fe18e34a6b5dc48a3d0ecd88470ff69189e5fde2ce1af4fab0ad401b876366"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2 locations): frontend/src/pages/Settings.tsx:133 \u00B7 frontend/src/pages/Settings.tsx:151 \u2014 all 2 copies are in the same file, and the CITED SPAN is not a self-contained block \u2014 it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead \u2014 the whole function, component or branch these lines sit in \u2014 and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Settings.tsx"},"region":{"startLine":133}}}],"partialFingerprints":{"codehealthFindingId/v1":"47838ca58d394960d1b4bbb5a378f8532c2e23b3f38e53f31ca2c925f3064d12"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 8 locations): frontend/src/components/charts/AttributionTab.tsx:112 \u00B7 frontend/src/components/charts/TopDrawdownsPanel.tsx:21 \u00B7 frontend/src/components/charts/ValidationPanel.tsx:181 \u00B7 frontend/src/pages/AlphaZoo.tsx:939 \u00B7 \u002B4 more site(s) not listed \u2014 the 8 copies are spread across 6 files, and the CITED SPAN is not a self-contained block \u2014 it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead \u2014 the whole function, component or branch these lines sit in \u2014 and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/charts/AttributionTab.tsx"},"region":{"startLine":112}}}],"partialFingerprints":{"codehealthFindingId/v1":"b7eb8e3d637d0bf50ad4676043ae3cbd65d8b94308e2f251c2f84bd338826420"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2 locations): frontend/src/components/charts/DistributionChart.tsx:28 \u00B7 frontend/src/components/charts/WalkForwardChart.tsx:16 \u2014 the 2 copies are spread across 2 files, and the CITED SPAN is not a self-contained block \u2014 it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead \u2014 the whole function, component or branch these lines sit in \u2014 and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/charts/DistributionChart.tsx"},"region":{"startLine":28}}}],"partialFingerprints":{"codehealthFindingId/v1":"47ffccb01ca3cfe026eb7a2adda6eb28593e4f8cc1f6fa4f9d715bb5852591ab"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2 locations): frontend/src/components/charts/FactorResearchPanel.tsx:114 \u00B7 frontend/src/components/charts/StrategyResearchDashboard.tsx:145 \u2014 the 2 copies are spread across 2 files, and the SHAPE of this repetition could not be determined. It is not a run of declarations, a listing, a declaration header, a type body or a slice through a construct \u2014 and it was not measured as a run of executable statements either, so this row cannot tell you whether a function can stand where these lines are. Read the two spans before acting, because the move is opposite in the two cases. Where they are statements, the ordinary answer holds: give the shared part one home and call it from each site. Where they turn out to be declarations, a literal\u0027s entries, or the cases of an enumeration, there is no call site to call anything from, and collapsing them would delete what each copy pins \u2014 a shared base type, a generated set, or one exported constant each site refers to is the move instead, and sometimes the honest answer is that there is nothing to extract at all. Reported because the copies drift apart the first time only one of them is edited, which is true whichever of those they are."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/charts/FactorResearchPanel.tsx"},"region":{"startLine":114}}}],"partialFingerprints":{"codehealthFindingId/v1":"c5696d5e5a2ee63f22ca34eea8cfe44ad46c971b767bfd03f0c6137bbf4e6adb"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 3 locations): frontend/src/pages/AlphaZoo.tsx:497 \u00B7 frontend/src/pages/AlphaZoo.tsx:676 \u00B7 frontend/src/pages/AlphaZoo.tsx:1057 \u2014 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 \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/AlphaZoo.tsx"},"region":{"startLine":497}}}],"partialFingerprints":{"codehealthFindingId/v1":"d9c1f19a9265c1f29bee82f42b60fea82d29ba58eb0def8176d89731b6a80c3e"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2 locations): desktop/electron/src/backend-manager.ts:436 \u00B7 desktop/electron/src/backend-watchdog.ts:163 \u2014 the 2 copies are spread across 2 files, and the CITED SPAN is not a self-contained block \u2014 it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead \u2014 the whole function, component or branch these lines sit in \u2014 and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"desktop/electron/src/backend-manager.ts"},"region":{"startLine":436}}}],"partialFingerprints":{"codehealthFindingId/v1":"f314291ae8f445ec9bec0ffb62b8f03a3c0b0985793b1d31b292993c6fc71b88"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block with local edits (6 matched lines \u00D7 2 locations): frontend/src/components/chat/Composer.tsx:117 \u00B7 frontend/src/pages/Agent.tsx:1404 \u2014 the two spans are one implementation copied and then locally edited \u2014 56 tokens are still identical, in the same order in both files, with only local edits between them. The copies have already begun to drift, which is this row\u0027s finding: an edit made to one and not the other changes behaviour silently. Diff the two spans first to learn what genuinely differs, then extract the shared core into one module both sites use, passing the differences in as parameters \u2014 or, if one copy exists only because the other could not be imported from its context, make one of them the single source the other is generated or re-exported from. If one copy is no longer reachable, delete it rather than letting it shadow the live one."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/chat/Composer.tsx"},"region":{"startLine":117}}}],"partialFingerprints":{"codehealthFindingId/v1":"df6ea8723bcbb052cec54f4fadfe107c6561a0f546e259e8d9f56365bb892ee0"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2 locations): frontend/src/components/chat/LiveRuntimePanel.tsx:124 \u00B7 frontend/src/components/settings/CustomProviderManager.tsx:25 \u2014 the 2 copies are spread across 2 directories, so the shared home is a decision rather than an obvious spot: check first whether one of them already owns this behaviour, and otherwise put the extracted module somewhere all of the sites already reach rather than making one of them depend on another."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/chat/LiveRuntimePanel.tsx"},"region":{"startLine":124}}}],"partialFingerprints":{"codehealthFindingId/v1":"4deeea676a82d6deb71d8942664f69ac269af58613c831e4d7f67295946adbc9"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block with local edits (6 matched lines \u00D7 2 locations): frontend/src/components/options/OptionsChainTable.tsx:143 \u00B7 frontend/src/pages/OptionsLab.tsx:77 \u2014 the two spans are one implementation copied and then locally edited \u2014 53 tokens are still identical, in the same order in both files, with only local edits between them. The copies have already begun to drift, which is this row\u0027s finding: an edit made to one and not the other changes behaviour silently. Diff the two spans first to learn what genuinely differs, then extract the shared core into one module both sites use, passing the differences in as parameters \u2014 or, if one copy exists only because the other could not be imported from its context, make one of them the single source the other is generated or re-exported from. If one copy is no longer reachable, delete it rather than letting it shadow the live one."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/options/OptionsChainTable.tsx"},"region":{"startLine":143}}}],"partialFingerprints":{"codehealthFindingId/v1":"596bf82f6860a57ed980b7a3522d47d1926366a8ab745d430d0ef0e4221d6183"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2 locations): frontend/src/components/portfolio/ExtraEtfImport.tsx:10 \u00B7 frontend/src/pages/PaperTrading.tsx:27 \u2014 the 2 copies are spread across 2 directories, so the shared home is a decision rather than an obvious spot: check first whether one of them already owns this behaviour, and otherwise put the extracted module somewhere all of the sites already reach rather than making one of them depend on another."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/portfolio/ExtraEtfImport.tsx"},"region":{"startLine":10}}}],"partialFingerprints":{"codehealthFindingId/v1":"d70ed39a76adb5814bb739f3cb15fe2cfd38cd64b06ab07ccd4352b02a4c4e06"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2 locations): frontend/src/components/run/PositionsTab.tsx:200 \u00B7 frontend/src/components/run/PositionsTab.tsx:209 \u2014 all 2 copies are in the same file, and the CITED SPAN is not a self-contained block \u2014 it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead \u2014 the whole function, component or branch these lines sit in \u2014 and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/run/PositionsTab.tsx"},"region":{"startLine":200}}}],"partialFingerprints":{"codehealthFindingId/v1":"3aaa2fa76b901876af25ec3fdcfd8f691e34a86ffb13f46deaa38ac3de4ea4a9"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2 locations): frontend/src/pages/Compare.tsx:235 \u00B7 frontend/src/pages/PaperTrading.tsx:18 \u2014 the 2 copies are spread across 2 files, and the CITED SPAN is not a self-contained block \u2014 it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead \u2014 the whole function, component or branch these lines sit in \u2014 and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Compare.tsx"},"region":{"startLine":235}}}],"partialFingerprints":{"codehealthFindingId/v1":"f8f88e9cd4c372fb96799c8f52a22c0aece2857dd871e845ef907e29b95ab34f"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2 locations): frontend/src/pages/PaperTrading.tsx:29 \u00B7 frontend/src/pages/PixelOffice.tsx:8 \u2014 the 2 copies sit in sibling files in one directory, so check first whether one of them (or an existing module there) already owns this behaviour and the others should call it; otherwise extract it into one module in that directory and have each site call it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/PaperTrading.tsx"},"region":{"startLine":29}}}],"partialFingerprints":{"codehealthFindingId/v1":"140e0eae6064d688b22e73f3692754e6dfaf9dfb6548bef1ef8161640e264feb"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2 locations): frontend/src/pages/PixelOffice.tsx:9 \u00B7 frontend/src/pages/Reports.tsx:26 \u2014 the 2 copies sit in sibling files in one directory, so check first whether one of them (or an existing module there) already owns this behaviour and the others should call it; otherwise extract it into one module in that directory and have each site call it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/PixelOffice.tsx"},"region":{"startLine":9}}}],"partialFingerprints":{"codehealthFindingId/v1":"8b67956a3d503d2f4e0aa886db893be4b1ece3e76465c7d9fdf20ea3e5c4bcde"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2 locations): frontend/src/pages/Portfolio.tsx:641 \u00B7 frontend/src/pages/Portfolio.tsx:674 \u2014 all 2 copies are in the same file, and the CITED SPAN is not a self-contained block \u2014 it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead \u2014 the whole function, component or branch these lines sit in \u2014 and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Portfolio.tsx"},"region":{"startLine":641}}}],"partialFingerprints":{"codehealthFindingId/v1":"167ee9e73d9640ebd58189c7400bf8d8c5c2d69a3fa1e452f9bf7486469a7fd7"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2 locations): frontend/src/pages/Settings.tsx:427 \u00B7 frontend/src/pages/Settings.tsx:546 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Settings.tsx"},"region":{"startLine":427}}}],"partialFingerprints":{"codehealthFindingId/v1":"fd68d02e527f73ad12b891379fac80e3c5846b6e4086b26c4fbc51ab93690fef"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block with local edits (5 matched lines \u00D7 2 locations): desktop/electron/scripts/test-update-safety.mjs:324 \u00B7 desktop/electron/src/backend-manager.ts:413 \u2014 the two spans are one implementation copied and then locally edited \u2014 50 tokens are still identical, in the same order in both files, with only local edits between them. The copies have already begun to drift, which is this row\u0027s finding: an edit made to one and not the other changes behaviour silently. Diff the two spans first to learn what genuinely differs, then extract the shared core into one module both sites use, passing the differences in as parameters \u2014 or, if one copy exists only because the other could not be imported from its context, make one of them the single source the other is generated or re-exported from. If one copy is no longer reachable, delete it rather than letting it shadow the live one."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"desktop/electron/scripts/test-update-safety.mjs"},"region":{"startLine":324}}}],"partialFingerprints":{"codehealthFindingId/v1":"91668d1040af25c68c61c369c0b662e907df732b7ac1edcc8b333ef136fb46a9"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2 locations): frontend/src/pages/Agent.tsx:546 \u00B7 frontend/src/pages/Agent.tsx:556 \u2014 all 2 copies are in the same file, and the CITED SPAN is not a self-contained block \u2014 it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead \u2014 the whole function, component or branch these lines sit in \u2014 and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Agent.tsx"},"region":{"startLine":546}}}],"partialFingerprints":{"codehealthFindingId/v1":"98178ea45947adb8d4f9a8d4341b3d96c1f2ad1b305aa1a6ff9a17b301e23662"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2 locations): frontend/src/pages/ResearchArtifacts.tsx:89 \u00B7 frontend/src/pages/Settings.tsx:45 \u2014 the 2 copies sit in sibling files in one directory, so check first whether one of them (or an existing module there) already owns this behaviour and the others should call it; otherwise extract it into one module in that directory and have each site call it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/ResearchArtifacts.tsx"},"region":{"startLine":89}}}],"partialFingerprints":{"codehealthFindingId/v1":"f5cefef4cfc0dc3ec5eefe439b9171cf17e2bb48b9651476bd31bc875034ecd1"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2 locations): frontend/src/pages/ResearchArtifacts.tsx:92 \u00B7 frontend/src/pages/ResearchLab.tsx:34 \u2014 the 2 copies sit in sibling files in one directory, so check first whether one of them (or an existing module there) already owns this behaviour and the others should call it; otherwise extract it into one module in that directory and have each site call it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/ResearchArtifacts.tsx"},"region":{"startLine":92}}}],"partialFingerprints":{"codehealthFindingId/v1":"946fc89354550e5ff752de84a4436310dd1d970eabc9711156e7f784fbc355c1"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function OptionsLab (cyclomatic 47, cognitive 42): OptionsLab has cyclomatic complexity 47 and cognitive complexity 42; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth \u2014 arms side by side rather than stacked \u2014 and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/OptionsLab.tsx"},"region":{"startLine":61}}}],"partialFingerprints":{"codehealthFindingId/v1":"770f9608ea599600d8317ea3021043ba2dc5a6dd96dabf7bd7ba48dfd5f59130"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function (anonymous) (cyclomatic 45, cognitive 72): (anonymous) has cyclomatic complexity 45 and cognitive complexity 72; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side \u2014 extracting each decision into its own named function is the change that pays. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Agent.tsx"},"region":{"startLine":539}}}],"partialFingerprints":{"codehealthFindingId/v1":"589622c89dfa17e01eca022f69d5ce2c86033d6f74ff9a780c408c1869cd5fdd"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function Settings (cyclomatic 45, cognitive 41): Settings has cyclomatic complexity 45 and cognitive complexity 41; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth \u2014 arms side by side rather than stacked \u2014 and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Settings.tsx"},"region":{"startLine":42}}}],"partialFingerprints":{"codehealthFindingId/v1":"5e2308442e4bdcef75a07dab1571b49cedbdb08e1079ed965252bbd01c312b8a"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function RunDetail (cyclomatic 41, cognitive 30): RunDetail has cyclomatic complexity 41 and cognitive complexity 30; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth \u2014 arms side by side rather than stacked \u2014 and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/RunDetail.tsx"},"region":{"startLine":124}}}],"partialFingerprints":{"codehealthFindingId/v1":"fe2290118d461c08596b493171a643925dbe5b3a0ec5bd7a82c02ecc1fcfca8a"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function attempt.completed (cyclomatic 39, cognitive 42): attempt.completed has cyclomatic complexity 39 and cognitive complexity 42; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side \u2014 extracting each decision into its own named function is the change that pays. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Agent.tsx"},"region":{"startLine":921}}}],"partialFingerprints":{"codehealthFindingId/v1":"aa7d794565526619cd64e4edf763e9b092f254c034171e353766984996fcd410"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function Scheduled (cyclomatic 38, cognitive 33): Scheduled has cyclomatic complexity 38 and cognitive complexity 33; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth \u2014 arms side by side rather than stacked \u2014 and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Scheduled.tsx"},"region":{"startLine":92}}}],"partialFingerprints":{"codehealthFindingId/v1":"933f622fb7a9429e278b535823fd6577da190cdc1801259bbb7ed5f067682d35"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function BrokerRow (cyclomatic 37, cognitive 34): BrokerRow has cyclomatic complexity 37 and cognitive complexity 34; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth \u2014 arms side by side rather than stacked \u2014 and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/chat/RunnerStatus.tsx"},"region":{"startLine":121}}}],"partialFingerprints":{"codehealthFindingId/v1":"5434091f5a8875db2c9ac613b79f85cbf95654dc8cc256c9c1ca316f9599d4b8"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function ConnectionCard (cyclomatic 37, cognitive 32): ConnectionCard has cyclomatic complexity 37 and cognitive complexity 32; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth \u2014 arms side by side rather than stacked \u2014 and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/portfolio/ConnectionCenter.tsx"},"region":{"startLine":183}}}],"partialFingerprints":{"codehealthFindingId/v1":"03af8e3f8ffe1d4bbce346b61b316bdcb7205ca2636441683e936988c14ae87c"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function ChannelConfigPanel (cyclomatic 35, cognitive 32): ChannelConfigPanel has cyclomatic complexity 35 and cognitive complexity 32; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth \u2014 arms side by side rather than stacked \u2014 and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/settings/ChannelConfigPanel.tsx"},"region":{"startLine":193}}}],"partialFingerprints":{"codehealthFindingId/v1":"cc00abb2aa5dcefeb0f85e06c1889b38be170a4663a6847cf7e0ebbc13b7b402"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function buildPayoffRequest (cyclomatic 33, cognitive 35): buildPayoffRequest has cyclomatic complexity 33 and cognitive complexity 35; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side \u2014 extracting each decision into its own named function is the change that pays. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/lib/options.ts"},"region":{"startLine":373}}}],"partialFingerprints":{"codehealthFindingId/v1":"585517c0d9f2ea9884bc8b6a3edf41db3e90b595a0bb86a78b1faa5ef5d66e01"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function ShannonPortfolio (cyclomatic 32, cognitive 27): ShannonPortfolio has cyclomatic complexity 32 and cognitive complexity 27; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth \u2014 arms side by side rather than stacked \u2014 and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/charts/ShannonPortfolio.tsx"},"region":{"startLine":31}}}],"partialFingerprints":{"codehealthFindingId/v1":"3d55ebcedad679856f980e92aaf47d28978d4c53a17247efe9d113b95b299373"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function renderField (cyclomatic 31, cognitive 37): renderField has cyclomatic complexity 31 and cognitive complexity 37; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side \u2014 extracting each decision into its own named function is the change that pays. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/settings/ChannelConfigPanel.tsx"},"region":{"startLine":534}}}],"partialFingerprints":{"codehealthFindingId/v1":"9ffcb375fca61cd9f679115eee4a939d5cbc4a299503c68335cd791ea86d1b2a"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function applySwarmEvent (cyclomatic 30, cognitive 31): applySwarmEvent has cyclomatic complexity 30 and cognitive complexity 31; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side \u2014 extracting each decision into its own named function is the change that pays. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/lib/swarmStatus.ts"},"region":{"startLine":209}}}],"partialFingerprints":{"codehealthFindingId/v1":"5970f1137f57158df96302537c057655e5c1cbe0535333c42ccc4c5d55a20aa5"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function Portfolio (cyclomatic 30, cognitive 28): Portfolio has cyclomatic complexity 30 and cognitive complexity 28; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth \u2014 arms side by side rather than stacked \u2014 and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Portfolio.tsx"},"region":{"startLine":135}}}],"partialFingerprints":{"codehealthFindingId/v1":"16204f4f63de7b699e72f86493997c63a0c668399c737c4ac0dccd371b5ed775"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function MandateProposalCard (cyclomatic 26, cognitive 26): MandateProposalCard has cyclomatic complexity 26 and cognitive complexity 26; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side \u2014 extracting each decision into its own named function is the change that pays. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/chat/MandateProposalCard.tsx"},"region":{"startLine":203}}}],"partialFingerprints":{"codehealthFindingId/v1":"c684cb0310348961d0c01b69203523cd08db7c0c32aa4be04b7631c79c1eccf1"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function ResearchArtifacts (cyclomatic 26, cognitive 21): ResearchArtifacts has cyclomatic complexity 26 and cognitive complexity 21; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth \u2014 arms side by side rather than stacked \u2014 and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/ResearchArtifacts.tsx"},"region":{"startLine":80}}}],"partialFingerprints":{"codehealthFindingId/v1":"9cabb2b1ae14399e461e094906457dd0ac6f3638711178e46488cd6b48d0a982"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function ToolRow (cyclomatic 25, cognitive 25): ToolRow has cyclomatic complexity 25 and cognitive complexity 25; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side \u2014 extracting each decision into its own named function is the change that pays. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/chat/ToolProgressIndicator.tsx"},"region":{"startLine":128}}}],"partialFingerprints":{"codehealthFindingId/v1":"616aa497c249c9a31472f43e77a5b6621d27e01db8715287117a535bb208ed31"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function Layout (cyclomatic 25, cognitive 23): Layout has cyclomatic complexity 25 and cognitive complexity 23; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth \u2014 arms side by side rather than stacked \u2014 and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/layout/Layout.tsx"},"region":{"startLine":21}}}],"partialFingerprints":{"codehealthFindingId/v1":"394dcb3f28cd92295fb740fd382036428a9baf398af6896706f8dc656196e4ae"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function (anonymous) (cyclomatic 23, cognitive 31): (anonymous) has cyclomatic complexity 23 and cognitive complexity 31; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side \u2014 extracting each decision into its own named function is the change that pays. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Agent.tsx"},"region":{"startLine":1401}}}],"partialFingerprints":{"codehealthFindingId/v1":"5b5b8d8ef1af2cfe889a789deacab5738eed290add35780ebe7fb1f4f488c69a"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function CustomProviderManager (cyclomatic 23, cognitive 16): CustomProviderManager has cyclomatic complexity 23 and cognitive complexity 16; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth \u2014 arms side by side rather than stacked \u2014 and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/settings/CustomProviderManager.tsx"},"region":{"startLine":20}}}],"partialFingerprints":{"codehealthFindingId/v1":"dde96eec30d3e6ef8aa3e37c431d8c09df4083dd278590ba7c131e7d79435376"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function submitDataSources (cyclomatic 22, cognitive 22): submitDataSources has cyclomatic complexity 22 and cognitive complexity 22; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side \u2014 extracting each decision into its own named function is the change that pays. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Settings.tsx"},"region":{"startLine":270}}}],"partialFingerprints":{"codehealthFindingId/v1":"96e6836c6dc39e1198ff85c06ba337d8a25cca770ec3bc0e299f8aaae5404013"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function Agent (cyclomatic 22, cognitive 20): Agent has cyclomatic complexity 22 and cognitive complexity 20; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth \u2014 arms side by side rather than stacked \u2014 and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Agent.tsx"},"region":{"startLine":227}}}],"partialFingerprints":{"codehealthFindingId/v1":"774a66c2a3de2fc7e5f599a1d68ca9920f0833db52b233a2c6a7bc47adf1ec18"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function ResearchLab (cyclomatic 22, cognitive 19): ResearchLab has cyclomatic complexity 22 and cognitive complexity 19; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth \u2014 arms side by side rather than stacked \u2014 and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/ResearchLab.tsx"},"region":{"startLine":20}}}],"partialFingerprints":{"codehealthFindingId/v1":"c6ba3905ec0d72437803c4623cb285ffbe7dcecf529694de319a933973d78337"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function compareSemanticVersions (cyclomatic 21, cognitive 36): compareSemanticVersions has cyclomatic complexity 21 and cognitive complexity 36; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side \u2014 extracting each decision into its own named function is the change that pays. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"desktop/electron/src/update-verification.ts"},"region":{"startLine":237}}}],"partialFingerprints":{"codehealthFindingId/v1":"f550d526e3d4c40d1cb591417fb1e4ee43806af5f01016d403651631615ef364"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function metricSentiment (cyclomatic 21, cognitive 29): metricSentiment has cyclomatic complexity 21 and cognitive complexity 29; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side \u2014 extracting each decision into its own named function is the change that pays. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/lib/formatters.ts"},"region":{"startLine":69}}}],"partialFingerprints":{"codehealthFindingId/v1":"e312d028f9a64f213e16a9f81e3a41240cec1de99f2f58a8636a596e29aa5911"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function StudioTab (cyclomatic 21, cognitive 18): StudioTab has cyclomatic complexity 21 and cognitive complexity 18; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth \u2014 arms side by side rather than stacked \u2014 and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/RunDetail.tsx"},"region":{"startLine":622}}}],"partialFingerprints":{"codehealthFindingId/v1":"0fe2727c0ff36d4dd05ff5d5feaafe08f85b187b6932e40ac9a0440521c151c7"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function volatilitySurfaceIssue (cyclomatic 20, cognitive 29): volatilitySurfaceIssue has cyclomatic complexity 20 and cognitive complexity 29; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side \u2014 extracting each decision into its own named function is the change that pays. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/lib/options.ts"},"region":{"startLine":292}}}],"partialFingerprints":{"codehealthFindingId/v1":"66e421cfd2c1e54f9189c0bf9268ff0ea871e3a6b4f8869845fa333a7575b042"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function errorFromResponse (cyclomatic 20, cognitive 23): errorFromResponse has cyclomatic complexity 20 and cognitive complexity 23; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side \u2014 extracting each decision into its own named function is the change that pays. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/lib/api.ts"},"region":{"startLine":403}}}],"partialFingerprints":{"codehealthFindingId/v1":"23e7b86cf7e113f6cb013df4b0df872ab84c18d451a2c2ffc381d60ddee3060e"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function buildVolatilitySurfaceRequest (cyclomatic 20, cognitive 21): buildVolatilitySurfaceRequest has cyclomatic complexity 20 and cognitive complexity 21; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side \u2014 extracting each decision into its own named function is the change that pays. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/lib/options.ts"},"region":{"startLine":258}}}],"partialFingerprints":{"codehealthFindingId/v1":"e55fa44d74403d43f6de9ea483947741685f71083678c8534528bb123aef57ce"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function verifyWindowsUpdateCandidate (cyclomatic 20, cognitive 19): verifyWindowsUpdateCandidate has cyclomatic complexity 20 and cognitive complexity 19; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth \u2014 arms side by side rather than stacked \u2014 and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"desktop/electron/src/update-verification.ts"},"region":{"startLine":53}}}],"partialFingerprints":{"codehealthFindingId/v1":"0036ecea256b516fb8765c7ae56082ee003f7c3575fc6eee297d92a5c27befa2"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function OptionsChainTable (cyclomatic 20, cognitive 18): OptionsChainTable has cyclomatic complexity 20 and cognitive complexity 18; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth \u2014 arms side by side rather than stacked \u2014 and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/options/OptionsChainTable.tsx"},"region":{"startLine":139}}}],"partialFingerprints":{"codehealthFindingId/v1":"faca62550012cd1f81ef50ed0e1fd5c857ffd8efcea28ca374965176c2013933"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function DetailView (cyclomatic 20, cognitive 18): DetailView has cyclomatic complexity 20 and cognitive complexity 18; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth \u2014 arms side by side rather than stacked \u2014 and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/AlphaZoo.tsx"},"region":{"startLine":457}}}],"partialFingerprints":{"codehealthFindingId/v1":"e703a5437d059b7f034de1cc5829e10146613e2abd1491aa1bb5e5f510fe1d1e"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function CorrelationAnalysis (cyclomatic 20, cognitive 18): CorrelationAnalysis has cyclomatic complexity 20 and cognitive complexity 18; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth \u2014 arms side by side rather than stacked \u2014 and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Correlation.tsx"},"region":{"startLine":44}}}],"partialFingerprints":{"codehealthFindingId/v1":"7f09c293293cf83f789deb38d06756e49d1bc310fda447161e91f77839b8a0fb"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function SoftwareUpdateSettings (cyclomatic 20, cognitive 17): SoftwareUpdateSettings has cyclomatic complexity 20 and cognitive complexity 17; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth \u2014 arms side by side rather than stacked \u2014 and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/settings/SoftwareUpdateSettings.tsx"},"region":{"startLine":5}}}],"partialFingerprints":{"codehealthFindingId/v1":"0ed0a2d717423736974da0cbbdda11e9e654bb334f00461087f962bcd4e015a1"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function (anonymous) (cyclomatic 20, cognitive 14): (anonymous) has cyclomatic complexity 20 and cognitive complexity 14; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth \u2014 arms side by side rather than stacked \u2014 and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/settings/ChannelSettings.tsx"},"region":{"startLine":235}}}],"partialFingerprints":{"codehealthFindingId/v1":"b32e8f9ac9df87cef8518abf5ce55041fc93f58c93a2ea933a8a72116e46a485"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function parseHoldings (cyclomatic 19, cognitive 23): parseHoldings has cyclomatic complexity 19 and cognitive complexity 23; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side \u2014 extracting each decision into its own named function is the change that pays. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/lib/shannon.ts"},"region":{"startLine":37}}}],"partialFingerprints":{"codehealthFindingId/v1":"a47fef4028bc9d3b9bfdf061adab4258381cc88e5819c3e95ba99a7bc79778a2"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function AccountCard (cyclomatic 19, cognitive 18): AccountCard has cyclomatic complexity 19 and cognitive complexity 18; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth \u2014 arms side by side rather than stacked \u2014 and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Portfolio.tsx"},"region":{"startLine":547}}}],"partialFingerprints":{"codehealthFindingId/v1":"ff27642506a7668b440e187123a88fb767a4f2c3f4960233984ed6c01f582c1d"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function ChartTab (cyclomatic 19, cognitive 16): ChartTab has cyclomatic complexity 19 and cognitive complexity 16; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth \u2014 arms side by side rather than stacked \u2014 and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/RunDetail.tsx"},"region":{"startLine":825}}}],"partialFingerprints":{"codehealthFindingId/v1":"7186317ce51d1a4a08b0f041a224c7f56e5d89246c04c6aea1c7abc4c778b5ba"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function installUpdate (cyclomatic 19, cognitive 14): installUpdate has cyclomatic complexity 19 and cognitive complexity 14; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth \u2014 arms side by side rather than stacked \u2014 and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"desktop/electron/src/main.ts"},"region":{"startLine":305}}}],"partialFingerprints":{"codehealthFindingId/v1":"eb9304c75fb82062dd4dd9735903de7648556734362d88d7b935d1d12fbf4cc9"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function (anonymous) (cyclomatic 18, cognitive 26): (anonymous) has cyclomatic complexity 18 and cognitive complexity 26; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side \u2014 extracting each decision into its own named function is the change that pays. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Agent.tsx"},"region":{"startLine":1829}}}],"partialFingerprints":{"codehealthFindingId/v1":"5f2f4bb42f6d010f8b77451b7ec8d6d2a30d518e9ba603e5f39411ef6ebbce8c"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function computeMonthlyReturns (cyclomatic 18, cognitive 23): computeMonthlyReturns has cyclomatic complexity 18 and cognitive complexity 23; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side \u2014 extracting each decision into its own named function is the change that pays. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/lib/tearsheet.ts"},"region":{"startLine":106}}}],"partialFingerprints":{"codehealthFindingId/v1":"198a115b78f4e1fcb5bf95e380f6fa8d869537ed1820c6c4b3556bcf76a81f01"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function Composer (cyclomatic 18, cognitive 17): Composer has cyclomatic complexity 18 and cognitive complexity 17; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth \u2014 arms side by side rather than stacked \u2014 and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/chat/Composer.tsx"},"region":{"startLine":82}}}],"partialFingerprints":{"codehealthFindingId/v1":"c04a7dbbf0edccb6fd2870ff60debbcf1331f2465afd5c86d86446221fed6fe9"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function calculateEta (cyclomatic 18, cognitive 17): calculateEta has cyclomatic complexity 18 and cognitive complexity 17; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth \u2014 arms side by side rather than stacked \u2014 and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/chat/ToolProgressIndicator.tsx"},"region":{"startLine":15}}}],"partialFingerprints":{"codehealthFindingId/v1":"c5e58d018ab896f6cc39656afcfef24256acddee931f1090fe7c013bcaae7786"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function BrokerRuntimeCard (cyclomatic 18, cognitive 17): BrokerRuntimeCard has cyclomatic complexity 18 and cognitive complexity 17; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth \u2014 arms side by side rather than stacked \u2014 and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Runtime.tsx"},"region":{"startLine":227}}}],"partialFingerprints":{"codehealthFindingId/v1":"30ef40e3d280fd1bc6df5b72a911d898d20e9e429be6dfb56bc6267801e0349a"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function (anonymous) (cyclomatic 18, cognitive 16): (anonymous) has cyclomatic complexity 18 and cognitive complexity 16; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth \u2014 arms side by side rather than stacked \u2014 and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Scheduled.tsx"},"region":{"startLine":731}}}],"partialFingerprints":{"codehealthFindingId/v1":"6e391a068ae7b4192f66d9dec3c319ef21c0e4ebe70185c44c818b8c804a3093"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function MessageBubble (cyclomatic 17, cognitive 16): MessageBubble has cyclomatic complexity 17 and cognitive complexity 16; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth \u2014 arms side by side rather than stacked \u2014 and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/chat/MessageBubble.tsx"},"region":{"startLine":204}}}],"partialFingerprints":{"codehealthFindingId/v1":"292d1b3c999f78c0513ecac749bf2c3b745d4634e76f64d3ae6988c5661c84fd"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function RunCardTab (cyclomatic 17, cognitive 16): RunCardTab has cyclomatic complexity 17 and cognitive complexity 16; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth \u2014 arms side by side rather than stacked \u2014 and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/RunDetail.tsx"},"region":{"startLine":477}}}],"partialFingerprints":{"codehealthFindingId/v1":"8fd7e51808dd9f53eba6e9c2c232183f84fa0616bc26bdbe3869eda5876089a1"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function submit (cyclomatic 17, cognitive 16): submit has cyclomatic complexity 17 and cognitive complexity 16; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth \u2014 arms side by side rather than stacked \u2014 and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Settings.tsx"},"region":{"startLine":232}}}],"partialFingerprints":{"codehealthFindingId/v1":"883d25f8c3561e47da2d9f9a05b0a281ee749e9314d4677b59d78a216d05514b"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function Runtime (cyclomatic 17, cognitive 15): Runtime has cyclomatic complexity 17 and cognitive complexity 15; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth \u2014 arms side by side rather than stacked \u2014 and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Runtime.tsx"},"region":{"startLine":25}}}],"partialFingerprints":{"codehealthFindingId/v1":"ba0ec84c274b82ecbfdc93ab7212f041d903e0ca59c8e9e2a3730a77c3a460b2"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function Compare (cyclomatic 17, cognitive 14): Compare has cyclomatic complexity 17 and cognitive complexity 14; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth \u2014 arms side by side rather than stacked \u2014 and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Compare.tsx"},"region":{"startLine":235}}}],"partialFingerprints":{"codehealthFindingId/v1":"9d1dcfbd86f8be119e545a9a2b77f8c1f54e61ac5069473a441eb8e69b184a04"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function rebuildLegacyActivity (cyclomatic 16, cognitive 22): rebuildLegacyActivity has cyclomatic complexity 16 and cognitive complexity 22; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side \u2014 extracting each decision into its own named function is the change that pays. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/chat/ThinkingTimeline.tsx"},"region":{"startLine":17}}}],"partialFingerprints":{"codehealthFindingId/v1":"72a72f85b674f10003bc42c1baf1491d98befb555afe39247d6f20f11fab5611"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function translateElement (cyclomatic 16, cognitive 20): translateElement has cyclomatic complexity 16 and cognitive complexity 20; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side \u2014 extracting each decision into its own named function is the change that pays. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"wiki/site.js"},"region":{"startLine":62}}}],"partialFingerprints":{"codehealthFindingId/v1":"cbc89e7e9b8cfc6c46e40ff39c12954caa71777c76cdc3a2fec827d72aeaf1e0"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function (anonymous) (cyclomatic 16, cognitive 19): (anonymous) has cyclomatic complexity 16 and cognitive complexity 19; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side \u2014 extracting each decision into its own named function is the change that pays. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Agent.tsx"},"region":{"startLine":1265}}}],"partialFingerprints":{"codehealthFindingId/v1":"af401c1959d4594655e4774d756452be74aabee39522c62ac1f52a7dabe87cf8"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function ScheduledResearchProposalCard (cyclomatic 16, cognitive 16): ScheduledResearchProposalCard has cyclomatic complexity 16 and cognitive complexity 16; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side \u2014 extracting each decision into its own named function is the change that pays. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/chat/ScheduledResearchProposalCard.tsx"},"region":{"startLine":19}}}],"partialFingerprints":{"codehealthFindingId/v1":"e61ab6ae60fe2d0bac9e2be453b82c200f91fa26079653d54831275fc42ee639"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function stop (cyclomatic 16, cognitive 15): stop has cyclomatic complexity 16 and cognitive complexity 15; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth \u2014 arms side by side rather than stacked \u2014 and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"desktop/electron/src/backend-manager.ts"},"region":{"startLine":162}}}],"partialFingerprints":{"codehealthFindingId/v1":"afbb0048a861ce3e894dc5ff45da990333ebf0c462bb3e2cb759aa4c5f51cfa5"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function SourcePrioritySettings (cyclomatic 16, cognitive 15): SourcePrioritySettings has cyclomatic complexity 16 and cognitive complexity 15; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth \u2014 arms side by side rather than stacked \u2014 and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/settings/SourcePrioritySettings.tsx"},"region":{"startLine":24}}}],"partialFingerprints":{"codehealthFindingId/v1":"023dda4f8dac39d3cf2a5e337378b586ec2e1f3f67af27269e72d4a91cad6ad8"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function PaperTrading (cyclomatic 16, cognitive 15): PaperTrading has cyclomatic complexity 16 and cognitive complexity 15; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth \u2014 arms side by side rather than stacked \u2014 and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/PaperTrading.tsx"},"region":{"startLine":18}}}],"partialFingerprints":{"codehealthFindingId/v1":"47008baf066096edd40b157e7192cee5275e59f807691afd66f8db35f1ba2093"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function (anonymous) (cyclomatic 16, cognitive 14): (anonymous) has cyclomatic complexity 16 and cognitive complexity 14; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth \u2014 arms side by side rather than stacked \u2014 and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Portfolio.tsx"},"region":{"startLine":458}}}],"partialFingerprints":{"codehealthFindingId/v1":"b6d63ee04a516e253e6540328931b7cce1c66fd0503bfc9b827b6b6c74a75ae6"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function getStrategyReportIdentity (cyclomatic 16, cognitive 13): getStrategyReportIdentity has cyclomatic complexity 16 and cognitive complexity 13; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth \u2014 arms side by side rather than stacked \u2014 and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/charts/StrategyResearchDashboard.tsx"},"region":{"startLine":69}}}],"partialFingerprints":{"codehealthFindingId/v1":"a1b0033699ce8007e75da338938a0b75a95e1ab5487a05f274b950125726579f"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function BenchView (cyclomatic 16, cognitive 13): BenchView has cyclomatic complexity 16 and cognitive complexity 13; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth \u2014 arms side by side rather than stacked \u2014 and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/AlphaZoo.tsx"},"region":{"startLine":641}}}],"partialFingerprints":{"codehealthFindingId/v1":"8c0c517f3b85274c30f889b90c697004020ba1b8ab0bdcc46a7b1a9fb4b686f4"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function resolveBackend (cyclomatic 15, cognitive 25): resolveBackend has cyclomatic complexity 15 and cognitive complexity 25; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side \u2014 extracting each decision into its own named function is the change that pays. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"desktop/electron/src/backend-manager.ts"},"region":{"startLine":310}}}],"partialFingerprints":{"codehealthFindingId/v1":"e2b425932ab3b233e9adb8b6b4bdee27b64d332a433af67e7ca16895b6e91d12"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function handleSubmit (cyclomatic 15, cognitive 15): handleSubmit has cyclomatic complexity 15 and cognitive complexity 15; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side \u2014 extracting each decision into its own named function is the change that pays. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Scheduled.tsx"},"region":{"startLine":256}}}],"partialFingerprints":{"codehealthFindingId/v1":"bafbcb831f7b880c9e12b808e83a2ee72f04bfe819c421575f99e9863b391d29"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function SwarmStatusCard (cyclomatic 15, cognitive 14): SwarmStatusCard has cyclomatic complexity 15 and cognitive complexity 14; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth \u2014 arms side by side rather than stacked \u2014 and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/chat/SwarmStatusCard.tsx"},"region":{"startLine":182}}}],"partialFingerprints":{"codehealthFindingId/v1":"e29fa27e260dc1594c4619c250eec768c52e887f54ce9bfcd311804df725c80d"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function ChannelSettings (cyclomatic 15, cognitive 14): ChannelSettings has cyclomatic complexity 15 and cognitive complexity 14; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth \u2014 arms side by side rather than stacked \u2014 and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/settings/ChannelSettings.tsx"},"region":{"startLine":24}}}],"partialFingerprints":{"codehealthFindingId/v1":"50aa8f81ca743727c0de90ddacde6524fa43d9000f6ba5122d5cf7c4474bc47e"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function submit (cyclomatic 14, cognitive 23): submit has cyclomatic complexity 14 and cognitive complexity 23; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side \u2014 extracting each decision into its own named function is the change that pays. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/ResearchLab.tsx"},"region":{"startLine":96}}}],"partialFingerprints":{"codehealthFindingId/v1":"891614d9934ac8e0383af42252c0b817f79ee0e4d90121877a6cd0ce2a142c74"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function buildSwarmStatusFromToolResultPreview (cyclomatic 14, cognitive 15): buildSwarmStatusFromToolResultPreview has cyclomatic complexity 14 and cognitive complexity 15; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side \u2014 extracting each decision into its own named function is the change that pays. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/lib/swarmStatus.ts"},"region":{"startLine":388}}}],"partialFingerprints":{"codehealthFindingId/v1":"c0360ed4fd284170a51e77092e8966193d3c853be92b80d7a00737d55e6e3e74"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function (anonymous) (cyclomatic 14, cognitive 15): (anonymous) has cyclomatic complexity 14 and cognitive complexity 15; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side \u2014 extracting each decision into its own named function is the change that pays. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Agent.tsx"},"region":{"startLine":1669}}}],"partialFingerprints":{"codehealthFindingId/v1":"60f6786b8c2635cd3e71a19cda1419c15cc4221283efa602f53d9f9d83dd833f"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function buildTheme (cyclomatic 14, cognitive 13): buildTheme has cyclomatic complexity 14 and cognitive complexity 13; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth \u2014 arms side by side rather than stacked \u2014 and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/lib/chart-theme.ts"},"region":{"startLine":25}}}],"partialFingerprints":{"codehealthFindingId/v1":"e47d896d44fdd9ede720a2abe9e05e991f5d49395d5c13a036f9d1bff23eccfd"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function (anonymous) (cyclomatic 14, cognitive 13): (anonymous) has cyclomatic complexity 14 and cognitive complexity 13; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth \u2014 arms side by side rather than stacked \u2014 and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Compare.tsx"},"region":{"startLine":422}}}],"partialFingerprints":{"codehealthFindingId/v1":"00c8de9dee024d5fe45fbf02c6827f7e60c53c0bf5d05baec1b42446b5e1e37b"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function StrategyResearchDashboard (cyclomatic 14, cognitive 12): StrategyResearchDashboard has cyclomatic complexity 14 and cognitive complexity 12; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth \u2014 arms side by side rather than stacked \u2014 and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/charts/StrategyResearchDashboard.tsx"},"region":{"startLine":122}}}],"partialFingerprints":{"codehealthFindingId/v1":"b76a996155031e5872027cbd8f226606341fc8acd44c02c5723564d8b493ff8e"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function Reports (cyclomatic 14, cognitive 11): Reports has cyclomatic complexity 14 and cognitive complexity 11; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth \u2014 arms side by side rather than stacked \u2014 and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Reports.tsx"},"region":{"startLine":23}}}],"partialFingerprints":{"codehealthFindingId/v1":"276435afc126794b2c0998c56d480710a6c25d31ee9df50f13780a8ff147cc5e"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function normalizeEquitySeries (cyclomatic 13, cognitive 16): normalizeEquitySeries has cyclomatic complexity 13 and cognitive complexity 16; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side \u2014 extracting each decision into its own named function is the change that pays. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/lib/tearsheet.ts"},"region":{"startLine":69}}}],"partialFingerprints":{"codehealthFindingId/v1":"a2dab38952ae226987a142802222d6bd2418f4c4655ae50f0fe206e7e84fdebb"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function classifyAssetClass (cyclomatic 13, cognitive 15): classifyAssetClass has cyclomatic complexity 13 and cognitive complexity 15; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side \u2014 extracting each decision into its own named function is the change that pays. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/lib/positions.ts"},"region":{"startLine":131}}}],"partialFingerprints":{"codehealthFindingId/v1":"a145ca1286723b1fb11c170e7886b950ecc736f086f9ceb339cbdb7ac61a4be5"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function refreshModels (cyclomatic 13, cognitive 14): refreshModels has cyclomatic complexity 13 and cognitive complexity 14; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side \u2014 extracting each decision into its own named function is the change that pays. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Settings.tsx"},"region":{"startLine":164}}}],"partialFingerprints":{"codehealthFindingId/v1":"1062a4ca6096421929b8177eb42480b2ef7f18a81966d2f2f43e3b0b5668aca5"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function computeAnnualReturns (cyclomatic 13, cognitive 13): computeAnnualReturns has cyclomatic complexity 13 and cognitive complexity 13; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side \u2014 extracting each decision into its own named function is the change that pays. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/lib/tearsheet.ts"},"region":{"startLine":147}}}],"partialFingerprints":{"codehealthFindingId/v1":"b50316f75b8f013418f0fcfba6919ad0b7eb1dc2a4094c4b152b7e3e8ba23d10"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function restoreJob (cyclomatic 13, cognitive 13): restoreJob has cyclomatic complexity 13 and cognitive complexity 13; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side \u2014 extracting each decision into its own named function is the change that pays. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/ResearchLab.tsx"},"region":{"startLine":56}}}],"partialFingerprints":{"codehealthFindingId/v1":"6a418e0cd34ea8086d995ac69274b5580319a83ff10e9b59e598577c609164e6"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function (anonymous) (cyclomatic 13, cognitive 12): (anonymous) has cyclomatic complexity 13 and cognitive complexity 12; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth \u2014 arms side by side rather than stacked \u2014 and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/RunDetail.tsx"},"region":{"startLine":1112}}}],"partialFingerprints":{"codehealthFindingId/v1":"51b7a1e2a89fb8802f3224c90e8f8f09e57f2d3ef9649336d0667fdc51351fa8"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function SdkBrokerRuntimeCard (cyclomatic 13, cognitive 12): SdkBrokerRuntimeCard has cyclomatic complexity 13 and cognitive complexity 12; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth \u2014 arms side by side rather than stacked \u2014 and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Runtime.tsx"},"region":{"startLine":302}}}],"partialFingerprints":{"codehealthFindingId/v1":"fab9dbd5efbc997c485a995d7e6eb2c36fa6efa1ab1ad527be8e443bf038dc10"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function inspectAuthenticodeSignature (cyclomatic 13, cognitive 11): inspectAuthenticodeSignature has cyclomatic complexity 13 and cognitive complexity 11; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth \u2014 arms side by side rather than stacked \u2014 and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"desktop/electron/src/update-verification.ts"},"region":{"startLine":175}}}],"partialFingerprints":{"codehealthFindingId/v1":"e720e6cceb37db913ca13db70665ef53528887ad960b5af8893939b04f17ff47"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function (anonymous) (cyclomatic 13, cognitive 11): (anonymous) has cyclomatic complexity 13 and cognitive complexity 11; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth \u2014 arms side by side rather than stacked \u2014 and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Agent.tsx"},"region":{"startLine":725}}}],"partialFingerprints":{"codehealthFindingId/v1":"0bf6dc1916882cb6364f796d0959893503a2b70b51ad55ac40a83259ae168514"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function BrowseView (cyclomatic 13, cognitive 11): BrowseView has cyclomatic complexity 13 and cognitive complexity 11; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth \u2014 arms side by side rather than stacked \u2014 and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/AlphaZoo.tsx"},"region":{"startLine":143}}}],"partialFingerprints":{"codehealthFindingId/v1":"71d93d11e4226176d93bb89464c8783054ea59e4fcdedb25263da06865a1aa81"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function (anonymous) (cyclomatic 13, cognitive 11): (anonymous) has cyclomatic complexity 13 and cognitive complexity 11; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth \u2014 arms side by side rather than stacked \u2014 and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"wiki/theme-init.js"},"region":{"startLine":7}}}],"partialFingerprints":{"codehealthFindingId/v1":"0dbca4ebeda856a1b76ad49c0f21b5a9753e0fc26f0ebba4e63234338e192965"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function FactorResearchPanel (cyclomatic 13, cognitive 10): FactorResearchPanel has cyclomatic complexity 13 and cognitive complexity 10; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth \u2014 arms side by side rather than stacked \u2014 and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/charts/FactorResearchPanel.tsx"},"region":{"startLine":84}}}],"partialFingerprints":{"codehealthFindingId/v1":"87cb261a317c8a20d2350cefeb74ca25e420b31a918e8543321df2b8dbee5988"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function RunCompleteCard (cyclomatic 13, cognitive 10): RunCompleteCard has cyclomatic complexity 13 and cognitive complexity 10; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth \u2014 arms side by side rather than stacked \u2014 and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/chat/RunCompleteCard.tsx"},"region":{"startLine":25}}}],"partialFingerprints":{"codehealthFindingId/v1":"54141a58b07258018a9ad2d51bd860b080e3d96b6204df98d3739e544e692727"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function agentTokenText (cyclomatic 13, cognitive 9): agentTokenText has cyclomatic complexity 13 and cognitive complexity 9; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth \u2014 arms side by side rather than stacked \u2014 and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/chat/SwarmDashboard.tsx"},"region":{"startLine":125}}}],"partialFingerprints":{"codehealthFindingId/v1":"fd2830384c410f8340eb246397376d788a79ceb76f8e158542d114d363392084"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function formatter (cyclomatic 12, cognitive 20): formatter has cyclomatic complexity 12 and cognitive complexity 20; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side \u2014 extracting each decision into its own named function is the change that pays. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/charts/CandlestickChart.tsx"},"region":{"startLine":222}}}],"partialFingerprints":{"codehealthFindingId/v1":"28a6fb1115b3e50198bea63cf5ac23d678f427a9e528d80d142ded84336365a5"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function (anonymous) (cyclomatic 12, cognitive 15): (anonymous) has cyclomatic complexity 12 and cognitive complexity 15; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side \u2014 extracting each decision into its own named function is the change that pays. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/charts/MonthlyReturnsHeatmap.tsx"},"region":{"startLine":20}}}],"partialFingerprints":{"codehealthFindingId/v1":"3e5c7b06883bc0eb4f16873fc49633ee775b4e11cb530ff6a7a1d010dbc2ccea"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function getPypi (cyclomatic 12, cognitive 15): getPypi has cyclomatic complexity 12 and cognitive complexity 15; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side \u2014 extracting each decision into its own named function is the change that pays. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"wiki/functions/api/stats.js"},"region":{"startLine":13}}}],"partialFingerprints":{"codehealthFindingId/v1":"3baf5d6be94aed3b74cb89097caabef4fcaa6a72690537641b986050ba4ba5ab"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function (anonymous) (cyclomatic 12, cognitive 13): (anonymous) has cyclomatic complexity 12 and cognitive complexity 13; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side \u2014 extracting each decision into its own named function is the change that pays. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/charts/CandlestickChart.tsx"},"region":{"startLine":114}}}],"partialFingerprints":{"codehealthFindingId/v1":"c623c3525b99cca984cc4846d1aa3dadaa50e67b07563ec5e9d5d2faa81654a6"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function buildSwarmStatusFromStarted (cyclomatic 12, cognitive 12): buildSwarmStatusFromStarted has cyclomatic complexity 12 and cognitive complexity 12; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side \u2014 extracting each decision into its own named function is the change that pays. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/lib/swarmStatus.ts"},"region":{"startLine":146}}}],"partialFingerprints":{"codehealthFindingId/v1":"3b3b9b15582781ef3ff134c639217db6b8a73a8f9824ed9cc2c17071154ed3f7"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function (anonymous) (cyclomatic 12, cognitive 12): (anonymous) has cyclomatic complexity 12 and cognitive complexity 12; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side \u2014 extracting each decision into its own named function is the change that pays. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Portfolio.tsx"},"region":{"startLine":313}}}],"partialFingerprints":{"codehealthFindingId/v1":"491d32905e3dbf200207c05e0397e59d95ba86191806d3e451b6d3a2405a429a"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function RunnerBudgetControls (cyclomatic 12, cognitive 11): RunnerBudgetControls has cyclomatic complexity 12 and cognitive complexity 11; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth \u2014 arms side by side rather than stacked \u2014 and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/chat/RunnerBudgetControls.tsx"},"region":{"startLine":6}}}],"partialFingerprints":{"codehealthFindingId/v1":"34115d520055dd3b412ba78cacf1c273700b22ba99b0a44604a9692fc216a47b"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function StrategyBuilder (cyclomatic 12, cognitive 11): StrategyBuilder has cyclomatic complexity 12 and cognitive complexity 11; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth \u2014 arms side by side rather than stacked \u2014 and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/options/StrategyBuilder.tsx"},"region":{"startLine":25}}}],"partialFingerprints":{"codehealthFindingId/v1":"452cc9160750fc2a4a9a970b3a31e72966ee073b5c36ad0f6e04368bc51447a0"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function AccountSelector (cyclomatic 12, cognitive 11): AccountSelector has cyclomatic complexity 12 and cognitive complexity 11; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth \u2014 arms side by side rather than stacked \u2014 and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/portfolio/ConnectionCenter.tsx"},"region":{"startLine":261}}}],"partialFingerprints":{"codehealthFindingId/v1":"6a187b8f36f4ac7d89210fc16549f4f00cb21dc3e9acb94071d0d37d9caa5941"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function (anonymous) (cyclomatic 12, cognitive 11): (anonymous) has cyclomatic complexity 12 and cognitive complexity 11; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth \u2014 arms side by side rather than stacked \u2014 and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/settings/HistoryStorageSettings.tsx"},"region":{"startLine":130}}}],"partialFingerprints":{"codehealthFindingId/v1":"be4b595240b3e4c43a88e2203b2c9e08d7457c6af361e288a5752ca6cff8456a"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function isUpdateAttempt (cyclomatic 12, cognitive 10): isUpdateAttempt has cyclomatic complexity 12 and cognitive complexity 10; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth \u2014 arms side by side rather than stacked \u2014 and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"desktop/electron/src/update-recovery.ts"},"region":{"startLine":178}}}],"partialFingerprints":{"codehealthFindingId/v1":"a2ac8b364537828f68617a400517c2934a9a38cc4bae133cb909e124d85a4587"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function AttributionTab (cyclomatic 12, cognitive 10): AttributionTab has cyclomatic complexity 12 and cognitive complexity 10; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth \u2014 arms side by side rather than stacked \u2014 and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/charts/AttributionTab.tsx"},"region":{"startLine":182}}}],"partialFingerprints":{"codehealthFindingId/v1":"5364e67ac69bc925a40c9d007540bf7102d1307ad3e97f7f122fe20c87dc2c8b"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function RunnerStatus (cyclomatic 12, cognitive 10): RunnerStatus has cyclomatic complexity 12 and cognitive complexity 10; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth \u2014 arms side by side rather than stacked \u2014 and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/chat/RunnerStatus.tsx"},"region":{"startLine":341}}}],"partialFingerprints":{"codehealthFindingId/v1":"bfb88cc0ea9605691045d4bcadfcb9797e30b6e581bdba6e3ec3a741fce684e3"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function CompareView (cyclomatic 12, cognitive 10): CompareView has cyclomatic complexity 12 and cognitive complexity 10; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth \u2014 arms side by side rather than stacked \u2014 and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/AlphaZoo.tsx"},"region":{"startLine":1027}}}],"partialFingerprints":{"codehealthFindingId/v1":"5fcaa5928c2c1208d544df6f89da76820048b340b40482d0731312036adcfb88"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function displayValue (cyclomatic 12, cognitive 10): displayValue has cyclomatic complexity 12 and cognitive complexity 10; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth \u2014 arms side by side rather than stacked \u2014 and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Portfolio.tsx"},"region":{"startLine":71}}}],"partialFingerprints":{"codehealthFindingId/v1":"e0d9447e7d9a5bd5d2329911d721048fcabc87a868e7e999c4694b6be411afb3"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function parsePositionsPanel (cyclomatic 11, cognitive 20): parsePositionsPanel has cyclomatic complexity 11 and cognitive complexity 20; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side \u2014 extracting each decision into its own named function is the change that pays. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/lib/positions.ts"},"region":{"startLine":75}}}],"partialFingerprints":{"codehealthFindingId/v1":"d8053ca5a355f4b9a3cba53f9df57312c5f0f288b3b6b09db1a6f6fc59fabdc9"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function (anonymous) (cyclomatic 11, cognitive 18): (anonymous) has cyclomatic complexity 11 and cognitive complexity 18; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side \u2014 extracting each decision into its own named function is the change that pays. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Settings.tsx"},"region":{"startLine":74}}}],"partialFingerprints":{"codehealthFindingId/v1":"26a95dfebfb2e7965d0b46146307e7b1b2981d4228dcacaf6aad14ed7feb06c3"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function compute (cyclomatic 11, cognitive 14): compute has cyclomatic complexity 11 and cognitive complexity 14; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side \u2014 extracting each decision into its own named function is the change that pays. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/options/VolatilitySurfaceGrid.tsx"},"region":{"startLine":61}}}],"partialFingerprints":{"codehealthFindingId/v1":"d8f72f4a24e93136d9896800e4d31bc355df0d9f529c87b1ff686c3069c31639"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function setEnabled (cyclomatic 11, cognitive 14): setEnabled has cyclomatic complexity 11 and cognitive complexity 14; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side \u2014 extracting each decision into its own named function is the change that pays. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/settings/ChannelConfigPanel.tsx"},"region":{"startLine":492}}}],"partialFingerprints":{"codehealthFindingId/v1":"7f9ea5272766d8f4819ea27671be10ed22d9697902a33009987200daddd490db"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function computeTopDrawdowns (cyclomatic 11, cognitive 14): computeTopDrawdowns has cyclomatic complexity 11 and cognitive complexity 14; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side \u2014 extracting each decision into its own named function is the change that pays. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/lib/tearsheet.ts"},"region":{"startLine":189}}}],"partialFingerprints":{"codehealthFindingId/v1":"77a41aa36060880e83400a11ed4e10821f1750c51af5d992a190b641725369bb"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function (anonymous) (cyclomatic 11, cognitive 14): (anonymous) has cyclomatic complexity 11 and cognitive complexity 14; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side \u2014 extracting each decision into its own named function is the change that pays. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Runtime.tsx"},"region":{"startLine":41}}}],"partialFingerprints":{"codehealthFindingId/v1":"45f0ad9c0fac55f54fd8648d22e2d3d903e6f02b1b42b044b0f3cedc219cfa0a"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function onKeyDown (cyclomatic 11, cognitive 13): onKeyDown has cyclomatic complexity 11 and cognitive complexity 13; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side \u2014 extracting each decision into its own named function is the change that pays. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/settings/ModelPicker.tsx"},"region":{"startLine":45}}}],"partialFingerprints":{"codehealthFindingId/v1":"179372f423a2eb42695034cbcfc74a71a8694a80e2a77b2c6a23ca4cb5ea621b"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function connectorRank (cyclomatic 11, cognitive 13): connectorRank has cyclomatic complexity 11 and cognitive complexity 13; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side \u2014 extracting each decision into its own named function is the change that pays. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Runtime.tsx"},"region":{"startLine":543}}}],"partialFingerprints":{"codehealthFindingId/v1":"786dd5b975b370d50623b8aff733ffd8fbfeeb8cc28e4b188ef240f122cd90fe"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function formatLastTick (cyclomatic 11, cognitive 12): formatLastTick has cyclomatic complexity 11 and cognitive complexity 12; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side \u2014 extracting each decision into its own named function is the change that pays. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Runtime.tsx"},"region":{"startLine":631}}}],"partialFingerprints":{"codehealthFindingId/v1":"3e79e7217486c06d7e8b26384a4e82b754ab0051de81012f92f6bf4535765363"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function render (cyclomatic 11, cognitive 12): render has cyclomatic complexity 11 and cognitive complexity 12; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side \u2014 extracting each decision into its own named function is the change that pays. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"wiki/alpha-library/alpha.js"},"region":{"startLine":10}}}],"partialFingerprints":{"codehealthFindingId/v1":"d432bac2cdc2ebdc5d66f832ae85d1f4d610e31d925025e0339d25c5d1272247"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function save (cyclomatic 11, cognitive 11): save has cyclomatic complexity 11 and cognitive complexity 11; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side \u2014 extracting each decision into its own named function is the change that pays. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/ResearchArtifacts.tsx"},"region":{"startLine":190}}}],"partialFingerprints":{"codehealthFindingId/v1":"f267c1c7184b065a44208c3b3d63e0345766d97294f6e0cc6e909018f497c119"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function inferStrategyName (cyclomatic 11, cognitive 10): inferStrategyName has cyclomatic complexity 11 and cognitive complexity 10; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth \u2014 arms side by side rather than stacked \u2014 and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/charts/StrategyResearchDashboard.tsx"},"region":{"startLine":52}}}],"partialFingerprints":{"codehealthFindingId/v1":"ba32c8b5d963f0bcdba993b549ea6a406a89316913c8fe8a46670c47c5ded244"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function onKeyDown (cyclomatic 11, cognitive 10): onKeyDown has cyclomatic complexity 11 and cognitive complexity 10; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth \u2014 arms side by side rather than stacked \u2014 and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/common/ConfirmDialog.tsx"},"region":{"startLine":48}}}],"partialFingerprints":{"codehealthFindingId/v1":"95e5ae2e1dbd6d9994c1e798cfaab259326ad990f4a60010c6a227ac053c9174"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function (anonymous) (cyclomatic 11, cognitive 10): (anonymous) has cyclomatic complexity 11 and cognitive complexity 10; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth \u2014 arms side by side rather than stacked \u2014 and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/layout/Layout.tsx"},"region":{"startLine":234}}}],"partialFingerprints":{"codehealthFindingId/v1":"20a36502a3bf163d0bcf90bc78567be5de2ff722555593ef1705f359f0fff712"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function (anonymous) (cyclomatic 11, cognitive 10): (anonymous) has cyclomatic complexity 11 and cognitive complexity 10; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth \u2014 arms side by side rather than stacked \u2014 and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/hooks/useAnalysisState.ts"},"region":{"startLine":21}}}],"partialFingerprints":{"codehealthFindingId/v1":"44776ec541777742a21d9a8aed91e58471f4a2bf21b889e1e00cf2183652d554"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function TradesTab (cyclomatic 11, cognitive 10): TradesTab has cyclomatic complexity 11 and cognitive complexity 10; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth \u2014 arms side by side rather than stacked \u2014 and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/RunDetail.tsx"},"region":{"startLine":1001}}}],"partialFingerprints":{"codehealthFindingId/v1":"23afe7d4064a8e35d482ada6fc27c6dbd26365a36f95116e492db5f7ac1d1e31"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function resolveDesktopLocale (cyclomatic 11, cognitive 9): resolveDesktopLocale has cyclomatic complexity 11 and cognitive complexity 9; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth \u2014 arms side by side rather than stacked \u2014 and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"desktop/electron/src/locales.ts"},"region":{"startLine":239}}}],"partialFingerprints":{"codehealthFindingId/v1":"c963a381a41723bdcc83900dcd61a4fed75ef8394397ce9c681111fda5cd5e53"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function TokenUsageLine (cyclomatic 11, cognitive 9): TokenUsageLine has cyclomatic complexity 11 and cognitive complexity 9; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth \u2014 arms side by side rather than stacked \u2014 and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/chat/SwarmStatusCard.tsx"},"region":{"startLine":126}}}],"partialFingerprints":{"codehealthFindingId/v1":"3bd042e0956f969f2112d63141b677bcb8ba7b8b976f7d718aca6204113805cd"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function VolatilitySurfaceGrid (cyclomatic 11, cognitive 9): VolatilitySurfaceGrid has cyclomatic complexity 11 and cognitive complexity 9; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth \u2014 arms side by side rather than stacked \u2014 and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository\u0027s own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/options/VolatilitySurfaceGrid.tsx"},"region":{"startLine":25}}}],"partialFingerprints":{"codehealthFindingId/v1":"f3d5e78245b5ca1bad2e3dcb7dbf85bd248788c66f95057405957198cca50221"}},{"ruleId":"R3","level":"warning","message":{"text":"frontend/src/lib/api.ts: 2208 lines of code: frontend/src/lib/api.ts has 2208 significant lines (blank lines excluded), over the 400-line bar, and contains logic \u2014 a file this long is usually several responsibilities in one module."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/lib/api.ts"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"f3746981f739da932550eb620dbcd8177fc45d81b3d135f8fd4192e267d1e0f5"}},{"ruleId":"R3","level":"warning","message":{"text":"frontend/src/pages/Agent.tsx: 1858 lines of code: frontend/src/pages/Agent.tsx has 1858 significant lines (blank lines excluded), over the 400-line bar, and contains logic \u2014 a file this long is usually several responsibilities in one module."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Agent.tsx"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"77eb371947fb3a13d2ac6aa12eb58f46c08e9608e7cd5144564bf83138350558"}},{"ruleId":"R3","level":"warning","message":{"text":"frontend/src/pages/AlphaZoo.tsx: 1212 lines of code: frontend/src/pages/AlphaZoo.tsx has 1212 significant lines (blank lines excluded), over the 400-line bar, and contains logic \u2014 a file this long is usually several responsibilities in one module."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/AlphaZoo.tsx"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"2a1f0c134f7b93af9971cd284ed5764f8e9bcd2f021d2e7c2ec6145c00fde4ab"}},{"ruleId":"R3","level":"warning","message":{"text":"frontend/src/pages/RunDetail.tsx: 1141 lines of code: frontend/src/pages/RunDetail.tsx has 1141 significant lines (blank lines excluded), over the 400-line bar, and contains logic \u2014 a file this long is usually several responsibilities in one module."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/RunDetail.tsx"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"204d594cb29e075cea80bfd588ba37f5f4d80c58155698f929f5b054d35f147e"}},{"ruleId":"R3","level":"warning","message":{"text":"frontend/src/components/settings/ChannelConfigPanel.tsx: 820 lines of code: frontend/src/components/settings/ChannelConfigPanel.tsx has 820 significant lines (blank lines excluded), over the 400-line bar, and contains logic \u2014 a file this long is usually several responsibilities in one module."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/settings/ChannelConfigPanel.tsx"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"60341926fabaf48f2419761896e7c3feb2e9800aa386c86073f342f7ed2b47ee"}},{"ruleId":"R3","level":"warning","message":{"text":"frontend/src/pages/Scheduled.tsx: 818 lines of code: frontend/src/pages/Scheduled.tsx has 818 significant lines (blank lines excluded), over the 400-line bar, and contains logic \u2014 a file this long is usually several responsibilities in one module."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Scheduled.tsx"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"3b607679a03e8af7d35a7d91de659db4ccbab6fe580ea73d0cf93c5be18755c2"}},{"ruleId":"R3","level":"warning","message":{"text":"frontend/src/pages/Settings.tsx: 728 lines of code: frontend/src/pages/Settings.tsx has 728 significant lines (blank lines excluded), over the 400-line bar, and contains logic \u2014 a file this long is usually several responsibilities in one module."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Settings.tsx"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"7c3a8369f771506a6705f084d1c6dad04574597d19e43b64a0f4d695871fa7d3"}},{"ruleId":"R3","level":"warning","message":{"text":"frontend/src/pages/Portfolio.tsx: 659 lines of code: frontend/src/pages/Portfolio.tsx has 659 significant lines (blank lines excluded), over the 400-line bar, and contains logic \u2014 a file this long is usually several responsibilities in one module."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Portfolio.tsx"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"abba1f9b6462a351c49f6f363ec6d3109ecc3fd00c7b64331812a6719edbc125"}},{"ruleId":"R3","level":"warning","message":{"text":"frontend/src/pages/Runtime.tsx: 607 lines of code: frontend/src/pages/Runtime.tsx has 607 significant lines (blank lines excluded), over the 400-line bar, and contains logic \u2014 a file this long is usually several responsibilities in one module."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Runtime.tsx"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"0f08fdfdd11156afb197663a34f7db5445698b076f1922f949e0f11622055cb6"}},{"ruleId":"R3","level":"warning","message":{"text":"frontend/src/lib/options.ts: 579 lines of code: frontend/src/lib/options.ts has 579 significant lines (blank lines excluded), over the 400-line bar, and contains logic \u2014 a file this long is usually several responsibilities in one module."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/lib/options.ts"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"e3d036361154a36475a2c4ddde9680b6063e394c2806c8d4a71707c9b3a76da6"}},{"ruleId":"R3","level":"warning","message":{"text":"frontend/src/pages/PaperTrading.tsx: 569 lines of code: frontend/src/pages/PaperTrading.tsx has 569 significant lines (blank lines excluded), over the 400-line bar, and contains logic \u2014 a file this long is usually several responsibilities in one module."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/PaperTrading.tsx"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"8284b1006627190cb6113e4298954ccb778b642da456b01b0aca423c3058a254"}},{"ruleId":"R3","level":"warning","message":{"text":"frontend/src/components/run/PositionsTab.tsx: 565 lines of code: frontend/src/components/run/PositionsTab.tsx has 565 significant lines (blank lines excluded), over the 400-line bar, and contains logic \u2014 a file this long is usually several responsibilities in one module."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/run/PositionsTab.tsx"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"5db1192599fe58c0c3196c488ce6ceb0f0a43bfbccea3460dcbe3b7e448ddd0c"}},{"ruleId":"R3","level":"warning","message":{"text":"desktop/electron/src/backend-manager.ts: 495 lines of code: desktop/electron/src/backend-manager.ts has 495 significant lines (blank lines excluded), over the 400-line bar, and contains logic \u2014 a file this long is usually several responsibilities in one module."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"desktop/electron/src/backend-manager.ts"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"c3718658de424b676fbd7f36c1125de2d8f782f3f443c887c051cf61247e70c3"}},{"ruleId":"R3","level":"warning","message":{"text":"frontend/src/components/layout/Layout.tsx: 493 lines of code: frontend/src/components/layout/Layout.tsx has 493 significant lines (blank lines excluded), over the 400-line bar, and contains logic \u2014 a file this long is usually several responsibilities in one module."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/layout/Layout.tsx"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"785140336002c5dea006f3f3abd655496918f09cbe32d9b23d80bc89e1cc5366"}},{"ruleId":"R3","level":"warning","message":{"text":"frontend/src/lib/swarmStatus.ts: 492 lines of code: frontend/src/lib/swarmStatus.ts has 492 significant lines (blank lines excluded), over the 400-line bar, and contains logic \u2014 a file this long is usually several responsibilities in one module."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/lib/swarmStatus.ts"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"34a74ae661fdc1fea0db84568bc75dccc4650d31810e843b7ac8058882864eb2"}},{"ruleId":"R3","level":"warning","message":{"text":"frontend/src/components/chat/Composer.tsx: 486 lines of code: frontend/src/components/chat/Composer.tsx has 486 significant lines (blank lines excluded), over the 400-line bar, and contains logic \u2014 a file this long is usually several responsibilities in one module."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/chat/Composer.tsx"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"3fda9590226ab021a97839169b771f9a67302a9d36c9ed8c60e8a2ae313814ac"}},{"ruleId":"R3","level":"warning","message":{"text":"frontend/src/pages/Compare.tsx: 447 lines of code: frontend/src/pages/Compare.tsx has 447 significant lines (blank lines excluded), over the 400-line bar, and contains logic \u2014 a file this long is usually several responsibilities in one module."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Compare.tsx"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"5bbd680ed1de2f2af1857cc50c66ba41a285bb6fc6d940655fca0721af28e177"}},{"ruleId":"R3","level":"warning","message":{"text":"frontend/src/components/chat/MandateProposalCard.tsx: 435 lines of code: frontend/src/components/chat/MandateProposalCard.tsx has 435 significant lines (blank lines excluded), over the 400-line bar, and contains logic \u2014 a file this long is usually several responsibilities in one module."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/chat/MandateProposalCard.tsx"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"77f298405e2cac6eb60842ed7981ff5944df8b5d378c6d68f597de6720059701"}},{"ruleId":"R3","level":"warning","message":{"text":"frontend/src/pages/ResearchArtifacts.tsx: 408 lines of code: frontend/src/pages/ResearchArtifacts.tsx has 408 significant lines (blank lines excluded), over the 400-line bar, and contains logic \u2014 a file this long is usually several responsibilities in one module."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/ResearchArtifacts.tsx"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"abb37d838d1c8412d9d3b207e493a55c7d8d7800d4616b67bf0822bfe75f6b92"}},{"ruleId":"R3","level":"warning","message":{"text":"frontend/src/components/chat/WelcomeScreen.tsx: 402 lines of code: frontend/src/components/chat/WelcomeScreen.tsx has 402 significant lines (blank lines excluded), over the 400-line bar, and contains logic \u2014 a file this long is usually several responsibilities in one module."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/chat/WelcomeScreen.tsx"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"cef4de49334e6ea4aa10e48d05fbd9f9f9d195dab75beb1a5aaa16a184f36808"}},{"ruleId":"R4","level":"warning","message":{"text":"No test reaches this file: No test imports this module directly or transitively. Import reachability cannot see a test that executes a file by path instead of importing it, nor one that drives it through a running browser by navigating to a URL \u2014 if neither does, no test reaches this one."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"desktop/electron/src/main.ts"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"1d6689af5b9f1faf25491eab954a1a3f202e34e984c531f839b8d608070a3a73"}},{"ruleId":"R4","level":"warning","message":{"text":"No test reaches this file: No test imports this module directly or transitively. Import reachability cannot see a test that executes a file by path instead of importing it, nor one that drives it through a running browser by navigating to a URL \u2014 if neither does, no test reaches this one."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"desktop/electron/scripts/test-update-safety.mjs"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"98dd8656462583d79754590fefd87129423dd414b7cccf5dd5c447a2ffa05135"}},{"ruleId":"R4","level":"warning","message":{"text":"No test reaches this file: No test imports this module directly or transitively. Import reachability cannot see a test that executes a file by path instead of importing it, nor one that drives it through a running browser by navigating to a URL \u2014 if neither does, no test reaches this one."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"desktop/electron/src/update-verification.ts"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"85096e1a9039c8338f7d8ad0d4f2f022d508ec61299cc8affa5d2bd95e12b202"}},{"ruleId":"R4","level":"warning","message":{"text":"No test reaches this file: No test imports this module directly or transitively. Import reachability cannot see a test that executes a file by path instead of importing it, nor one that drives it through a running browser by navigating to a URL \u2014 if neither does, no test reaches this one."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"wiki/site.js"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"a4e774a33065e437fa533440e965e34891f14a66322aa6acf6264099e1028827"}},{"ruleId":"R4","level":"warning","message":{"text":"No test reaches this file: No test imports this module directly or transitively. Import reachability cannot see a test that executes a file by path instead of importing it, nor one that drives it through a running browser by navigating to a URL \u2014 if neither does, no test reaches this one."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"desktop/electron/src/update-recovery.ts"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"5143bee36ac609513d4d0c6fd3606d005c1dcbce565f20700af62ec74196d35c"}},{"ruleId":"R4","level":"warning","message":{"text":"No test reaches this file: No test imports this module directly or transitively. Import reachability cannot see a test that executes a file by path instead of importing it, nor one that drives it through a running browser by navigating to a URL \u2014 if neither does, no test reaches this one."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"desktop/electron/scripts/build-signed-installer.mjs"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"5aed017f8194edbcd6944478b3a4fd151ebff787a284699008f3ed915576b80b"}},{"ruleId":"R4","level":"warning","message":{"text":"No test reaches this file: No test imports this module directly or transitively. Import reachability cannot see a test that executes a file by path instead of importing it, nor one that drives it through a running browser by navigating to a URL \u2014 if neither does, no test reaches this one."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"desktop/electron/src/backend-watchdog.ts"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"7444e44b666f3f9571c50d77c3a486ae2a0a852018d66e0f22343b8213637698"}},{"ruleId":"R4","level":"warning","message":{"text":"No test reaches this file: No test imports this module directly or transitively. Import reachability cannot see a test that executes a file by path instead of importing it, nor one that drives it through a running browser by navigating to a URL \u2014 if neither does, no test reaches this one."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"desktop/electron/scripts/build-review-installer.mjs"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"b37855a7820efa9f941362c83cc36723d971e5dcad89a199125c2bc35e296600"}},{"ruleId":"R4","level":"warning","message":{"text":"No test reaches this file: No test imports this module directly or transitively. Import reachability cannot see a test that executes a file by path instead of importing it, nor one that drives it through a running browser by navigating to a URL \u2014 if neither does, no test reaches this one."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"wiki/scripts/gen_sitemap.mjs"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"ea39a2c6eb19b79f4c02c521a02da4616dc5a56b1ae0ba8899367359c950364f"}},{"ruleId":"R4","level":"warning","message":{"text":"No test reaches this file: No test imports this module directly or transitively. Import reachability cannot see a test that executes a file by path instead of importing it, nor one that drives it through a running browser by navigating to a URL \u2014 if neither does, no test reaches this one."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"wiki/scripts/prerender_docs.mjs"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"dac215c90ca5b656a2ab7a8b14a0602452fc608e64765bb74b5d8e423321c82b"}},{"ruleId":"R4","level":"warning","message":{"text":"No test reaches this file: No test imports this module directly or transitively. Import reachability cannot see a test that executes a file by path instead of importing it, nor one that drives it through a running browser by navigating to a URL \u2014 if neither does, no test reaches this one."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"desktop/electron/src/update.ts"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"d505eb9119356eb07d3651d37f644f32efa77c46e1f6554cfcdcc5df7a2aa4e1"}},{"ruleId":"R4","level":"warning","message":{"text":"No test reaches this file: No test imports this module directly or transitively. Import reachability cannot see a test that executes a file by path instead of importing it, nor one that drives it through a running browser by navigating to a URL \u2014 if neither does, no test reaches this one."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/router.tsx"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"6960268debc7da62258a509671e64ce262fe0b918ef22b36182e2e155b57167f"}},{"ruleId":"R4","level":"warning","message":{"text":"No test reaches this file: No test imports this module directly or transitively. Import reachability cannot see a test that executes a file by path instead of importing it, nor one that drives it through a running browser by navigating to a URL \u2014 if neither does, no test reaches this one."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"wiki/functions/api/stats.js"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"0ddf6aa8321e08aed1f8a9dc6f3b1bb7dd0f1bae7425604766c1bf99089137ee"}},{"ruleId":"R4","level":"warning","message":{"text":"No test reaches this file: No test imports this module directly or transitively. Import reachability cannot see a test that executes a file by path instead of importing it, nor one that drives it through a running browser by navigating to a URL \u2014 if neither does, no test reaches this one."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"wiki/functions/_middleware.js"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"cf75820522c8e03706fa8e61a6bf7bf41cde2080640c77043b5964e6ce1d54e3"}},{"ruleId":"R4","level":"warning","message":{"text":"No test reaches this file: No test imports this module directly or transitively. Import reachability cannot see a test that executes a file by path instead of importing it, nor one that drives it through a running browser by navigating to a URL \u2014 if neither does, no test reaches this one."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Home.tsx"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"c62bc4923ae6a6502d26af13ed4cb21d54022f138e7ec5cdce7e0466287078bd"}},{"ruleId":"R4","level":"warning","message":{"text":"No test reaches this file: No test imports this module directly or transitively. Import reachability cannot see a test that executes a file by path instead of importing it, nor one that drives it through a running browser by navigating to a URL \u2014 if neither does, no test reaches this one."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"wiki/scripts/check_docs_parity.mjs"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"3a7fd0e51cfd1be9630f89fd55ac109fd58534a3dc40f12e80aa9c7720d1cb2b"}},{"ruleId":"R4","level":"warning","message":{"text":"No test reaches this file: No test imports this module directly or transitively. Import reachability cannot see a test that executes a file by path instead of importing it, nor one that drives it through a running browser by navigating to a URL \u2014 if neither does, no test reaches this one."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"wiki/alpha-library/alpha.js"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"604c4ec9fabc1d4d29751c5f68e3644747af1050083539664af6f53593da623d"}},{"ruleId":"R4","level":"warning","message":{"text":"No test reaches this file: No test imports this module directly or transitively. Import reachability cannot see a test that executes a file by path instead of importing it, nor one that drives it through a running browser by navigating to a URL \u2014 if neither does, no test reaches this one."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"wiki/main.js"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"1f0dd348a1516e8ff867da6cecedc05e9b316e48b502225b2f7db309a62a7611"}},{"ruleId":"R4","level":"warning","message":{"text":"No test reaches this file: No test imports this module directly or transitively. Import reachability cannot see a test that executes a file by path instead of importing it, nor one that drives it through a running browser by navigating to a URL \u2014 if neither does, no test reaches this one."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/main.tsx"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"607d579fa60dcd8658f05471f5d913ea8f65a79cf231f2a66b2f02a839810aa4"}},{"ruleId":"R4","level":"warning","message":{"text":"No test reaches this file: No test imports this module directly or transitively. Import reachability cannot see a test that executes a file by path instead of importing it, nor one that drives it through a running browser by navigating to a URL \u2014 if neither does, no test reaches this one."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"wiki/theme-init.js"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"99240673627891caeb303c0375d3ee1f8ddfa3297cc7c9f66d5265dca033e7cb"}},{"ruleId":"R4","level":"warning","message":{"text":"No test reaches this file: No test imports this module directly or transitively. Import reachability cannot see a test that executes a file by path instead of importing it, nor one that drives it through a running browser by navigating to a URL \u2014 if neither does, no test reaches this one."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/public/theme-boot.js"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"dabb1ab095216cdff32ffb8a30cca6dc560f1c11448e7a751bdee512a2c84672"}},{"ruleId":"R4","level":"warning","message":{"text":"No test reaches this file: No test imports this module directly or transitively. Import reachability cannot see a test that executes a file by path instead of importing it, nor one that drives it through a running browser by navigating to a URL \u2014 if neither does, no test reaches this one."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"desktop/electron/src/preload.ts"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"49ad1c1867e52bb1592a17a1c75a246d66f3b7b0bb9b2b1b38cfb98cee61dbd3"}},{"ruleId":"R4","level":"warning","message":{"text":"No test reaches this file: No test imports this module directly or transitively. Import reachability cannot see a test that executes a file by path instead of importing it, nor one that drives it through a running browser by navigating to a URL \u2014 if neither does, no test reaches this one."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"desktop/electron/scripts/copy-static.mjs"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"e485465780fca912fce4f27fe513c861c3d0868c210f93c850f20610dfb15ce1"}},{"ruleId":"R6","level":"warning","message":{"text":"No lint script: test \u2713 \u00B7 lint \u2717 \u00B7 typecheck \u2713 \u2014 read from this repository\u0027s package.json scripts and corroborated against its CI workflows. A script counts when its name or command matches the step: \u0060test\u0060 for the suite, \u0060lint\u0060 or \u0060prettier\u0060 for linting, \u0060typecheck\u0060/\u0060type-check\u0060/\u0060tsc\u0060 for type checking. \u2717 therefore means no script or CI step under those names was found, NOT that the step is absent from your pipeline \u2014 a task invoked by a runner this check does not read, or named something else entirely, is not seen and is worth confirming before acting on a cross. A \u2713 means the wiring is DECLARED \u2014 a script or CI step under those names exists. It is not a statement that the step passes, or that it runs at all: nothing here installs a dependency or executes a suite."},"locations":[],"partialFingerprints":{"codehealthFindingId/v1":"bc8e67e81453cf5399dd04786d18b232180426b135169175fee670bdd83ccb03"}},{"ruleId":"R7","level":"warning","message":{"text":"Dead file (~169 LoC): no import path from any entry point (29 application, 15 tooling, 112 test roots considered), and no other file in the scanned tree imports it \u2014 nothing in-repo names this module at all, which is the strongest form of this claim the import graph can make"},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"desktop/electron/src/backend-watchdog.ts"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"dc5345458687b98737e9bde23af48e5cd015390fd9b8f9c063baf3440b488ade"}},{"ruleId":"R7","level":"warning","message":{"text":"Dead file (~87 LoC): no import path from any entry point (29 application, 15 tooling, 112 test roots considered), and no other file in the scanned tree imports it \u2014 nothing in-repo names this module at all, which is the strongest form of this claim the import graph can make"},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"wiki/functions/api/stats.js"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"dd11445b231031f2821c54bf303108c08107dc77f1acd329d3ce839981058026"}},{"ruleId":"R7","level":"warning","message":{"text":"Dead file (~73 LoC): no import path from any entry point (29 application, 15 tooling, 112 test roots considered), and no other file in the scanned tree imports it \u2014 nothing in-repo names this module at all, which is the strongest form of this claim the import graph can make"},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"wiki/functions/_middleware.js"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"9769b6c0b6fe377c77396fdf80cb689dfaaa2abf4331ba28b6b625f13463c48b"}},{"ruleId":"R7","level":"warning","message":{"text":"Dead file (~19 LoC): no import path from any entry point (29 application, 15 tooling, 112 test roots considered), and no other file in the scanned tree imports it \u2014 nothing in-repo names this module at all, which is the strongest form of this claim the import graph can make"},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"desktop/electron/src/preload.ts"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"b69cc87dd2a80a876f0e5b6d3b586681a0ce7a1194944e2c8f34dd9c6b8a2dc4"}},{"ruleId":"R8","level":"error","message":{"text":"Unlisted import \u0027@electron/get\u0027: Imported but not declared in any reachable package.json \u2014 installs work only by hoisting accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"desktop/electron/scripts/prepare-electron.mjs"},"region":{"startLine":15}}}],"partialFingerprints":{"codehealthFindingId/v1":"f7584f80f6dec42992e03f54a09fc1d55eed925c23298ed47bfeaed72b857216"}},{"ruleId":"R8","level":"warning","message":{"text":"Unused dependency \u0027@fontsource/inter\u0027: Declared in frontend/package.json but never imported anywhere in that package or its workspace members \u2014 no static import reaches it. Usually that is dead weight and attack surface, but two shapes are indistinguishable from source and are NOT dead: an optional or native peer that another dependency loads dynamically at runtime, and a package a build, docs or test step installs and invokes separately. Confirm which of the three this is before removing it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/package.json"},"region":{"startLine":18}}}],"partialFingerprints":{"codehealthFindingId/v1":"de99d6bb0c6d430c7e326d9d99034da2e176681376717ee2165d49f0b5268c6d"}},{"ruleId":"R8","level":"warning","message":{"text":"Unused dependency \u0027@fontsource/jetbrains-mono\u0027: Declared in frontend/package.json but never imported anywhere in that package or its workspace members \u2014 no static import reaches it. Usually that is dead weight and attack surface, but two shapes are indistinguishable from source and are NOT dead: an optional or native peer that another dependency loads dynamically at runtime, and a package a build, docs or test step installs and invokes separately. Confirm which of the three this is before removing it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/package.json"},"region":{"startLine":19}}}],"partialFingerprints":{"codehealthFindingId/v1":"79568e49835cd9e1129bab860bd519acdd60a5638f56a3e5400dee4f3a85a03d"}},{"ruleId":"S1","level":"note","message":{"text":"Security headers incomplete: Set: Content-Security-Policy, Permissions-Policy, Referrer-Policy, X-Content-Type-Options, X-Frame-Options. Missing: Strict-Transport-Security \u2014 the four headers that carry the points of this card\u0027s security-headers term (Content-Security-Policy, Strict-Transport-Security, X-Content-Type-Options, X-Frame-Options), 0.5 each. (\u22120.5 on this card.)"},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"wiki/_headers"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"2dab66141aa160cb3315865dfbb018ab32eb1f0792b3403ca3edd2e68fd00cb7"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060!Array.isArray(params) || !params.length\u0060 appears character-identically in 9 files \u2014 frontend/src/components/charts/AnnualReturnsChart.tsx, frontend/src/components/charts/AttributionCumulativeChart.tsx, frontend/src/components/charts/AttributionWaterfallChart.tsx, frontend/src/components/charts/CandlestickChart.tsx. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/charts/AnnualReturnsChart.tsx"},"region":{"startLine":30}}}],"partialFingerprints":{"codehealthFindingId/v1":"2be25a77507ef698edff3540f1f4501834e1592f0d78f8bec65285cfcb663710"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060entry.isFile() \u0026\u0026 /^Vibe-Trading-Desktop-Unofficial-.*-x64\\.exe$/u.test(entry.name)\u0060 appears character-identically in 2 files \u2014 desktop/electron/scripts/build-review-installer.mjs, desktop/electron/scripts/build-signed-installer.mjs. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"desktop/electron/scripts/build-review-installer.mjs"},"region":{"startLine":41}}}],"partialFingerprints":{"codehealthFindingId/v1":"1ea8c26df631fed988f6abe1fbedd3abec8270bbff44a012ebc3f465762aff54"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060entry.isFile() \u0026\u0026 entry.name.toLowerCase().endsWith(\u0022.exe\u0022)\u0060 appears character-identically in 2 files \u2014 desktop/electron/scripts/build-review-installer.mjs, desktop/electron/scripts/build-signed-installer.mjs. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"desktop/electron/scripts/build-review-installer.mjs"},"region":{"startLine":47}}}],"partialFingerprints":{"codehealthFindingId/v1":"a7326d42de3c9f5dbc2704b176125bd91e81d53051abd164da4104226fb575bb"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060error instanceof ApiError \u0026\u0026 error.status === 404\u0060 appears character-identically in 2 files \u2014 frontend/src/hooks/useAlphaJob.ts, frontend/src/pages/Agent.tsx. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/hooks/useAlphaJob.ts"},"region":{"startLine":59}}}],"partialFingerprints":{"codehealthFindingId/v1":"46088afc043778fe3c2da32d40157be94ad7a4559e6c3659f43adf09228a8311"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060isCriterionStatusMet(criterion.status) || criterionEvidenceCount(snapshot, criterion.criterion_id) \u003E 0\u0060 appears character-identically in 2 files \u2014 frontend/src/components/chat/GoalPanel.tsx, frontend/src/pages/Agent.tsx. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/chat/GoalPanel.tsx"},"region":{"startLine":16}}}],"partialFingerprints":{"codehealthFindingId/v1":"cc782070167f768db2ff07d74b95ce9e761d014594582d592a08bff29946be2c"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060tone === \u0022danger\u0022 \u0026\u0026 \u0022bg-danger/10 text-danger\u0022\u0060 appears character-identically in 2 files \u2014 frontend/src/pages/Runtime.tsx, frontend/src/pages/Scheduled.tsx. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Runtime.tsx"},"region":{"startLine":522}}}],"partialFingerprints":{"codehealthFindingId/v1":"1515fb4df423fed1c499b8472086e8179fc01fbc63d94c2847c0a012ce30aa55"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060tone === \u0022neutral\u0022 \u0026\u0026 \u0022bg-muted text-muted-foreground\u0022\u0060 appears character-identically in 2 files \u2014 frontend/src/pages/Runtime.tsx, frontend/src/pages/Scheduled.tsx. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Runtime.tsx"},"region":{"startLine":524}}}],"partialFingerprints":{"codehealthFindingId/v1":"06a1f3d9ef44e054a40628abff13f22ef0313abfdad841089347a6158e44d81e"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060tone === \u0022success\u0022 \u0026\u0026 \u0022bg-success/10 text-success\u0022\u0060 appears character-identically in 2 files \u2014 frontend/src/pages/Runtime.tsx, frontend/src/pages/Scheduled.tsx. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Runtime.tsx"},"region":{"startLine":521}}}],"partialFingerprints":{"codehealthFindingId/v1":"8342ac5e58219cecf2de30068de101f010af91947a9e9844cb2eccc02d823624"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060tone === \u0022warning\u0022 \u0026\u0026 \u0022bg-warning/10 text-warning\u0022\u0060 appears character-identically in 2 files \u2014 frontend/src/pages/Runtime.tsx, frontend/src/pages/Scheduled.tsx. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Runtime.tsx"},"region":{"startLine":523}}}],"partialFingerprints":{"codehealthFindingId/v1":"6c1b9567e42622a1242ac36bea4ad5d4ccb86eac6b77e0d20498821193dfeae7"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060url.protocol !== \u0022https:\u0022 || url.username || url.password\u0060 appears character-identically in 2 files \u2014 desktop/electron/scripts/build-signed-installer.mjs, desktop/electron/src/update.ts. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"desktop/electron/scripts/build-signed-installer.mjs"},"region":{"startLine":94}}}],"partialFingerprints":{"codehealthFindingId/v1":"dbc5017470260c0f0896642f15ff6b96cc78c8edb200cfe036c4cc4f3ff343b0"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060\u0022vol\u0022 in df.columns and \u0022volume\u0022 not in df.columns\u0060 appears character-identically in 2 files \u2014 agent/src/tools/paper_trade/data.py, agent/src/tools/paper_trade/data_5m.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/paper_trade/data.py"},"region":{"startLine":159}}}],"partialFingerprints":{"codehealthFindingId/v1":"b93d6c1d2f38da8cd24551cc533af6ae6ab7fea67eb0ea147453a9b2bd183e52"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060_first_proxy_env(\u0022HTTPS_PROXY\u0022, \u0022https_proxy\u0022) or all_proxy or http_proxy\u0060 appears character-identically in 2 files \u2014 agent/backtest/loaders/ccxt_loader.py, agent/backtest/loaders/okx.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/ccxt_loader.py"},"region":{"startLine":101}}}],"partialFingerprints":{"codehealthFindingId/v1":"0a50fbcd4fc9e43cb7bc7d2fec12ce5c51bbfd60b469c6cd40b93af8d5f050e6"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060_first_proxy_env(\u0022HTTP_PROXY\u0022, \u0022http_proxy\u0022) or all_proxy\u0060 appears character-identically in 2 files \u2014 agent/backtest/loaders/ccxt_loader.py, agent/backtest/loaders/okx.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/ccxt_loader.py"},"region":{"startLine":100}}}],"partialFingerprints":{"codehealthFindingId/v1":"1133b5fa779deafccdfbe9fc3b7f7e93e30704e5d9cc2a830f7c2027f3afcc9d"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060_sys.modules.get(\u0022api_server\u0022) or _sys.modules.get(\u0022agent.api_server\u0022)\u0060 appears character-identically in 16 files \u2014 agent/src/api/alpha_routes.py, agent/src/api/attribution_routes.py, agent/src/api/auth_routes.py, agent/src/api/channels_config_routes.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/api/alpha_routes.py"},"region":{"startLine":389}}}],"partialFingerprints":{"codehealthFindingId/v1":"a5ff86134ae9b6d28542c15860f045f2f1544b41d2e56d061a0bdbd4319b631d"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060amount.is_finite() and amount \u003E= 1 and amount == amount.to_integral_value()\u0060 appears character-identically in 3 files \u2014 agent/src/trading/connectors/dhan/sdk.py, agent/src/trading/connectors/shoonya/sdk.py, agent/src/trading/connectors/zerodha/sdk.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/dhan/sdk.py"},"region":{"startLine":490}}}],"partialFingerprints":{"codehealthFindingId/v1":"0ab56d363d9b8f2a71da6be13ce1624cb14d21d09e388ec4f19d8629431310d0"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060arguments.get(\u0022run_dir\u0022) or payload.get(\u0022run_dir\u0022)\u0060 appears character-identically in 2 files \u2014 agent/evals/grounding/evidence.py, agent/evals/grounding/ledger.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/grounding/evidence.py"},"region":{"startLine":1009}}}],"partialFingerprints":{"codehealthFindingId/v1":"0460a541c8fbad51d4a57fcd481d7841503f42a87ba07ccae88b73705567c1c8"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060asyncio.current_task() and asyncio.current_task().cancelling()\u0060 appears character-identically in 2 files \u2014 agent/src/channels/manager.py, agent/src/channels/websocket.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/manager.py"},"region":{"startLine":301}}}],"partialFingerprints":{"codehealthFindingId/v1":"2a6576b7f00cab16a595fcc5e570a4a1494e935eea6d1ccbcd060542b1be2f8b"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060bar.get(\u0022open\u0022, bar.get(\u0022close\u0022, 0.0)) or 0.0\u0060 appears character-identically in 2 files \u2014 agent/backtest/engines/korea_equity.py, agent/backtest/engines/vietnam_equity.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/engines/korea_equity.py"},"region":{"startLine":218}}}],"partialFingerprints":{"codehealthFindingId/v1":"0e986a56e33135fc9a54891c6b029200beb96e1ac2461955d1625c08da45a7f8"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060bar_date is not None and entry_date is not None and bar_date == entry_date\u0060 appears character-identically in 2 files \u2014 agent/backtest/engines/china_a.py, agent/backtest/engines/india_equity.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/engines/china_a.py"},"region":{"startLine":222}}}],"partialFingerprints":{"codehealthFindingId/v1":"05d10f65852fe8df829a420627b415dc264c6d5759f675b4eb98b962f53dc9c4"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060breach.detail or f\u0022order breaches {breach.limit}\u0022\u0060 appears character-identically in 2 files \u2014 agent/src/live/order_guard.py, agent/src/live/sdk_order_gate.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/live/order_guard.py"},"region":{"startLine":567}}}],"partialFingerprints":{"codehealthFindingId/v1":"27630978ba9c46950482c9cde713f4cc0889dfa0a5362ce203fd35434376f453"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060clean_type == \u0022limit\u0022 and limit_price is None\u0060 appears character-identically in 2 files \u2014 agent/src/trading/connectors/etoro/trading.py, agent/src/trading/connectors/mt5/orders.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/etoro/trading.py"},"region":{"startLine":59}}}],"partialFingerprints":{"codehealthFindingId/v1":"406fd492906c01593dc60d48cef74ef1ccf90c75a9a9a075d6a9f64875766737"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060close_arr is not None and col is not None and row \u003E= 0\u0060 appears character-identically in 3 files \u2014 agent/backtest/engines/base.py, agent/backtest/engines/korea_equity.py, agent/backtest/engines/vietnam_equity.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/engines/base.py"},"region":{"startLine":758}}}],"partialFingerprints":{"codehealthFindingId/v1":"56d191e4bb517c03ea64cf57d879a632f857d0bd73386e9f8347bc0bafdcbe21"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060ctx is None or not hasattr(ctx, \u0022pending_prompt\u0022)\u0060 appears character-identically in 2 files \u2014 agent/cli/commands/chat.py, agent/cli/commands/research_playbook.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/commands/chat.py"},"region":{"startLine":107}}}],"partialFingerprints":{"codehealthFindingId/v1":"7cc62ededd6cb2f13508456223807398ab69b421063ab592ff879614d4a67a3d"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060data.get(\u0022tool\u0022) != _PROPOSAL_TOOL_NAME or data.get(\u0022status\u0022) != \u0022ok\u0022\u0060 appears character-identically in 2 files \u2014 agent/cli/_legacy.py, agent/src/api/sessions_routes.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":1015}}}],"partialFingerprints":{"codehealthFindingId/v1":"c6c51e4fd4f781a50752b3dc6ae2b6cfa38f2ec528dde57a1a9dc8ad93df8510"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060data.get(\u0022tool\u0022) != _SCHEDULED_PROPOSAL_TOOL_NAME or data.get(\u0022status\u0022) != \u0022ok\u0022\u0060 appears character-identically in 2 files \u2014 agent/cli/_legacy.py, agent/src/api/sessions_routes.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":1025}}}],"partialFingerprints":{"codehealthFindingId/v1":"efdb3badce3bca7c8b72c948becdff4ae55a61aaa9d82a00d7580e31e5f9be65"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060dataclasses.is_dataclass(value) and not isinstance(value, type)\u0060 appears character-identically in 3 files \u2014 agent/cli/_legacy.py, agent/src/quantlib/valuation/artifact.py, agent/src/tools/quantlib_tool.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":4755}}}],"partialFingerprints":{"codehealthFindingId/v1":"1173db49a75092937263d7d4d79d5e1e5008e8ad494f7f470135af1a8632f52f"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060delivery_format is not None and delivery_channel != \u0022email\u0022\u0060 appears character-identically in 2 files \u2014 agent/src/api/scheduled_routes.py, agent/src/scheduled_research/service.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/api/scheduled_routes.py"},"region":{"startLine":803}}}],"partialFingerprints":{"codehealthFindingId/v1":"5726e9848b6d9813f0b928cf91e8931c363eea8413b6840ac01ea9db91186ccd"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060df is not None and not df.empty and _is_a_share(code) and not _is_etf_listed(code)\u0060 appears character-identically in 3 files \u2014 agent/backtest/loaders/akshare_loader.py, agent/backtest/loaders/eastmoney_loader.py, agent/backtest/loaders/tencent_loader.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/akshare_loader.py"},"region":{"startLine":169}}}],"partialFingerprints":{"codehealthFindingId/v1":"39fba30afcb52681297f1e7235e5024ad6cab903e08254c3039b8a49b8940435"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060direction == 0 and fill_price \u003C= lower \u002B _PRICE_EPS\u0060 appears character-identically in 2 files \u2014 agent/backtest/engines/korea_equity.py, agent/backtest/engines/vietnam_equity.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/engines/korea_equity.py"},"region":{"startLine":226}}}],"partialFingerprints":{"codehealthFindingId/v1":"5ae1c74a0949ad33045652ed216f82584e201557fffd4f8ba09575c52db1c363"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060direction == 1 and fill_price \u003E= upper - _PRICE_EPS\u0060 appears character-identically in 2 files \u2014 agent/backtest/engines/korea_equity.py, agent/backtest/engines/vietnam_equity.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/engines/korea_equity.py"},"region":{"startLine":224}}}],"partialFingerprints":{"codehealthFindingId/v1":"20736e0c2a7af9f4213a85a186d3af3e846e2a5790f500c6497b20d27b54cdbd"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060end_at is not None and next_run_at \u003E end_at\u0060 appears character-identically in 2 files \u2014 agent/src/api/scheduled_routes.py, agent/src/scheduled_research/service.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/api/scheduled_routes.py"},"region":{"startLine":743}}}],"partialFingerprints":{"codehealthFindingId/v1":"7aa551095bae526f60fd0a9462bc3812ff673e9219688b99a55e9c63c604e415"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060frame is None or frame.empty or \u0022close\u0022 not in frame.columns\u0060 appears character-identically in 2 files \u2014 agent/src/shadow_account/extractor.py, agent/src/tools/trade_journal_tool.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/shadow_account/extractor.py"},"region":{"startLine":198}}}],"partialFingerprints":{"codehealthFindingId/v1":"1d9d9c9a7607016c3c79ec035a07da80c08fb24cb6123b87bfdf7f96236581d5"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060get_env_config().data.tushare_token or ts.get_token()\u0060 appears character-identically in 2 files \u2014 agent/src/skills/tushare/scripts/fund_data_example.py, agent/src/skills/tushare/scripts/stock_data_example.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/skills/tushare/scripts/fund_data_example.py"},"region":{"startLine":15}}}],"partialFingerprints":{"codehealthFindingId/v1":"67bf58f3d8641f43075fb8ef216f99b84aa719c2ccb0b4ea39ce659a31109021"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060google_extra.get(\u0022thought_signature\u0022) or google_extra.get( \u0022thoughtSignature\u0022 )\u0060 appears character-identically in 2 files \u2014 agent/src/agent/context_compact.py, agent/src/providers/chat.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/agent/context_compact.py"},"region":{"startLine":473}}}],"partialFingerprints":{"codehealthFindingId/v1":"53e43b102bc94d90b7eff29b5d1b01c0d68bf50057b0dba7b69d7fba0516862f"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060hasattr(bar, \u0022name\u0022) and hasattr(bar.name, \u0022date\u0022)\u0060 appears character-identically in 2 files \u2014 agent/backtest/engines/china_a.py, agent/backtest/engines/india_equity.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/engines/china_a.py"},"region":{"startLine":98}}}],"partialFingerprints":{"codehealthFindingId/v1":"2cd0194cb92d221e16c50d0a8fd74278db9eee1fd1bcae401bc7b02185b07955"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060include_executions and status in (\u0022COMPLETE\u0022, \u0022FILLED\u0022)\u0060 appears character-identically in 2 files \u2014 agent/src/trading/connectors/shoonya/sdk.py, agent/src/trading/connectors/zerodha/sdk.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/shoonya/sdk.py"},"region":{"startLine":295}}}],"partialFingerprints":{"codehealthFindingId/v1":"9c8afa6f6099a4d1701f667024eee3976574ad1e927157834e249131f6b111bc"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060intent.side == \u0022buy\u0022 and intent.limit_price is not None and price is not None\u0060 appears character-identically in 2 files \u2014 agent/src/live/order_guard.py, agent/src/live/sdk_order_gate.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/live/order_guard.py"},"region":{"startLine":270}}}],"partialFingerprints":{"codehealthFindingId/v1":"74eb496f5e2fb909d1fdc0f35414f1c0a542889ccb1b309df72e0825c3de153b"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060is_system_job_id(job_id) or source_type == \u0022system\u0022\u0060 appears character-identically in 2 files \u2014 agent/src/api/scheduled_guards.py, agent/src/scheduled_research/proposals.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/api/scheduled_guards.py"},"region":{"startLine":48}}}],"partialFingerprints":{"codehealthFindingId/v1":"f5cec9874f6f136edeeb291093d6795ced753bb8fd1aa5315b5da958985d3f8a"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060isinstance(data, dict) and data.get(\u0022type\u0022) == \u0022mandate.proposal\u0022\u0060 appears character-identically in 2 files \u2014 agent/cli/_legacy.py, agent/src/api/sessions_routes.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":991}}}],"partialFingerprints":{"codehealthFindingId/v1":"02051e9187981dca6fd7a8cd3fbe43236c92c789254e22835e8bb5ac67988b72"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060isinstance(df, pd.DataFrame) and df.empty\u0060 appears character-identically in 2 files \u2014 agent/backtest/benchmark.py, agent/src/tools/technical_indicator_tool.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/benchmark.py"},"region":{"startLine":241}}}],"partialFingerprints":{"codehealthFindingId/v1":"40c56e3832f456a987b8cc9a25edefa0eba88346a60fff3ca806119dc7eb6367"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060isinstance(horizon, bool) or not isinstance(horizon, int) or not 1 \u003C= horizon \u003C= _MAX_HORIZON\u0060 appears character-identically in 3 files \u2014 agent/mcp_server.py, agent/src/factors/bench_runner.py, agent/src/factors/bench_runner_strict.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/mcp_server.py"},"region":{"startLine":1135}}}],"partialFingerprints":{"codehealthFindingId/v1":"a2bbe87df58a47980c3593022b22e59ce9bfcf655948379a474b1ab0cd473092"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060isinstance(horizon, int) and not isinstance(horizon, bool) and horizon \u003E 1\u0060 appears character-identically in 2 files \u2014 agent/src/factors/bench_runner.py, agent/src/factors/bench_runner_strict.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/bench_runner.py"},"region":{"startLine":206}}}],"partialFingerprints":{"codehealthFindingId/v1":"d90ac61cbb6e580f18d785dbc87abf2ed1eff91f0fce2dc179bec46ca7f8c788"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060isinstance(rows, list) and len(rows) \u003E= len(best_rows)\u0060 appears character-identically in 2 files \u2014 agent/src/tools/financial_statements_tool.py, agent/src/tools/sec_filings_tool.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/financial_statements_tool.py"},"region":{"startLine":477}}}],"partialFingerprints":{"codehealthFindingId/v1":"da3fa0ec754c1b110231abce01181c3c2238c4dac74c65e42856bdf82aaa6a86"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060isinstance(series, list) and 0 \u003C= index \u003C len(series)\u0060 appears character-identically in 2 files \u2014 agent/backtest/loaders/finnhub_loader.py, agent/backtest/loaders/yahoo_client.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/finnhub_loader.py"},"region":{"startLine":129}}}],"partialFingerprints":{"codehealthFindingId/v1":"efd021244389aa75da61cf469618c09f5095ffd4865a804f12542054e4255765"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060isinstance(symbol, str) and symbol.strip()\u0060 appears character-identically in 5 files \u2014 agent/src/trading/connectors/alpaca/sdk.py, agent/src/trading/connectors/dhan/sdk.py, agent/src/trading/connectors/kis/sdk.py, agent/src/trading/connectors/shoonya/sdk.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/alpaca/sdk.py"},"region":{"startLine":739}}}],"partialFingerprints":{"codehealthFindingId/v1":"22f91306a1aec254359d0e354eedb7f19969bb4750008c15333c492858eeb200"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060isinstance(value, bool) or not isinstance(value, (int, float))\u0060 appears character-identically in 4 files \u2014 agent/src/shadow_account/codegen.py, agent/src/tools/paper_trade/reconcile.py, agent/src/tools/paper_trade/schema.py, agent/src/tools/paper_trade/wire.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/shadow_account/codegen.py"},"region":{"startLine":79}}}],"partialFingerprints":{"codehealthFindingId/v1":"1353903ab25ab69abc038e96d49f64e3982ee5a1d05e4944733fa6ae2bb8c4a6"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060isinstance(value, bool) or not isinstance(value, (int, float)) or not math.isfinite(value)\u0060 appears character-identically in 2 files \u2014 agent/backtest/binance_shadow_evidence.py, agent/src/quantlib/units.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/binance_shadow_evidence.py"},"region":{"startLine":362}}}],"partialFingerprints":{"codehealthFindingId/v1":"e8c1b405a8420ef8521010b2edba888e1b4f6be66c7c31ba1afade5f7fe84dfe"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060isinstance(value, bool) or not isinstance(value, Integral) or value \u003C minimum\u0060 appears character-identically in 2 files \u2014 agent/src/quantlib/combination.py, agent/src/quantlib/neutralization.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/combination.py"},"region":{"startLine":93}}}],"partialFingerprints":{"codehealthFindingId/v1":"d83605fe9238f475a59b78a4f34fc0ee8f01050675999584d347c092418944a6"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060isinstance(value, bool) or not isinstance(value, Real)\u0060 appears character-identically in 3 files \u2014 agent/src/quantlib/combination.py, agent/src/quantlib/impact.py, agent/src/quantlib/volatility.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/combination.py"},"region":{"startLine":260}}}],"partialFingerprints":{"codehealthFindingId/v1":"3d467d10465d33655d34fcc1112ec9b0a616b36a0efaac9d5f27f542926b5d1a"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060isinstance(value, dict) and value.get(\u0022truncated\u0022) is True\u0060 appears character-identically in 2 files \u2014 agent/src/data_gateway/bar_artifact.py, agent/src/data_gateway/bar_summary.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/data_gateway/bar_artifact.py"},"region":{"startLine":59}}}],"partialFingerprints":{"codehealthFindingId/v1":"4eb6859302045c73df4cf8f4100b4dcad58484cd64a9ee110503bb13b3739b83"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060isinstance(value, float) and not math.isfinite(value)\u0060 appears character-identically in 4 files \u2014 agent/src/market_data.py, agent/src/strategy_discovery/facade.py, agent/src/tools/get_fundamentals_tool.py, agent/src/tools/taiwan_stock_data_tool.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/market_data.py"},"region":{"startLine":215}}}],"partialFingerprints":{"codehealthFindingId/v1":"a5845c8e87b7b9e78aec4f5366d76df9ece3edbf58e8419aa0a0f4610277e5aa"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060isinstance(value, int) and not isinstance(value, bool)\u0060 appears character-identically in 2 files \u2014 agent/src/providers/openai_codex.py, agent/src/strategy_discovery/facade.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/providers/openai_codex.py"},"region":{"startLine":693}}}],"partialFingerprints":{"codehealthFindingId/v1":"70d07e0d58fe72bbbe29caface98dfc660d4e8784756b0f24134019fa2aaa473"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060isinstance(value, str) and value.strip()\u0060 appears character-identically in 8 files \u2014 agent/src/channels/mochat.py, agent/src/channels/websocket.py, agent/src/live/enforcement.py, agent/src/tools/fund_nav_tool.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/mochat.py"},"region":{"startLine":944}}}],"partialFingerprints":{"codehealthFindingId/v1":"38bf4f617a84946bf962276574096825c1dc1f926fbd855a51bc92b6684c44ac"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060item.get(\u0022instrumentID\u0022) or item.get(\u0022instrumentId\u0022)\u0060 appears character-identically in 2 files \u2014 agent/src/trading/connectors/etoro/instruments.py, agent/src/trading/connectors/etoro/sdk.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/etoro/instruments.py"},"region":{"startLine":472}}}],"partialFingerprints":{"codehealthFindingId/v1":"ec986a914662e2acd6c3364d3ea1120a955bf23df1dceca7e544ce6fb7ccd507"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060item.get(\u0022lastExecution\u0022) or item.get(\u0022last\u0022) or item.get(\u0022rate\u0022)\u0060 appears character-identically in 2 files \u2014 agent/src/trading/connectors/etoro/instruments.py, agent/src/trading/connectors/etoro/sdk.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/etoro/instruments.py"},"region":{"startLine":482}}}],"partialFingerprints":{"codehealthFindingId/v1":"484860a0b1c80f992ece3fe051eb2736fc37adb7d209a0aedcd95bebd3a49758"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060k in _OVERRIDE_KEYS and v not in (None, \u0022\u0022)\u0060 appears character-identically in 14 files \u2014 agent/src/trading/connectors/alpaca/sdk.py, agent/src/trading/connectors/binance/sdk.py, agent/src/trading/connectors/dhan/sdk.py, agent/src/trading/connectors/etoro/client.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/alpaca/sdk.py"},"region":{"startLine":154}}}],"partialFingerprints":{"codehealthFindingId/v1":"1bf692a65e00b9318c5ee8af117011e4867da70ed95c4f7d74f69cf86090be25"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060kwargs.get(\u0022session_id\u0022) or self._default_session_id or \u0022\u0022\u0060 appears character-identically in 3 files \u2014 agent/src/tools/autopilot_tool.py, agent/src/tools/goal_tool.py, agent/src/tools/scheduled_research_tool.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/autopilot_tool.py"},"region":{"startLine":121}}}],"partialFingerprints":{"codehealthFindingId/v1":"34d74ffea885c6ec7d77e9dfa3db4115f734356e8309c3c39d7ffd9708d0445a"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060len(digits) != 8 or not digits.isdigit()\u0060 appears character-identically in 2 files \u2014 agent/src/tools/dragon_tiger_tool.py, agent/src/tools/tushare_fallbacks.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/dragon_tiger_tool.py"},"region":{"startLine":54}}}],"partialFingerprints":{"codehealthFindingId/v1":"fa9c665b8c8de93f9b75153b85c882233babc5bd20ef83cfc062b403c8a77d59"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060mandate is None or mandate.schema_version != MANDATE_SCHEMA_VERSION\u0060 appears character-identically in 2 files \u2014 agent/src/live/order_guard.py, agent/src/live/sdk_order_gate.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/live/order_guard.py"},"region":{"startLine":146}}}],"partialFingerprints":{"codehealthFindingId/v1":"cad52167fce97a1e6fe2d412649f9fc48fc252c9d6032dfa209e3ff58a0225ab"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060method == \u0022POST\u0022 and path.endswith(\u0022/resume\u0022)\u0060 appears character-identically in 4 files \u2014 tools/gateway_history_recovery_probe.py, tools/gateway_history_restart_probe.py, tools/gateway_minute_restart_probe.py, tools/gateway_ten_job_restart_probe.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"tools/gateway_history_recovery_probe.py"},"region":{"startLine":65}}}],"partialFingerprints":{"codehealthFindingId/v1":"e620b3b37be9321213ad89c69e0f6d9d0fcddda089962d06e67fd20554d8cac3"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060not acquired or bs.login().error_code != \u00220\u0022\u0060 appears character-identically in 3 files \u2014 tools/gateway_history_validate.py, tools/gateway_scale_probe.py, tools/gateway_ten_job_restart_probe.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"tools/gateway_history_validate.py"},"region":{"startLine":45}}}],"partialFingerprints":{"codehealthFindingId/v1":"ee256bbf75427b9b12c699fa747ea50c66fc24e70eb55512da247bcac6877257"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060not isinstance(code, str) or not code.strip()\u0060 appears character-identically in 6 files \u2014 agent/src/strategy_discovery/adaptation_workflow.py, agent/src/tools/financial_statements_tool.py, agent/src/tools/market_data_tool.py, agent/src/tools/research_reports_tool.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/strategy_discovery/adaptation_workflow.py"},"region":{"startLine":59}}}],"partialFingerprints":{"codehealthFindingId/v1":"4da6827f76e4d7ecd6790b62318ec8a4ff646684db9c7cd2a343c8dd116519c9"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060not isinstance(codes, list) or not codes\u0060 appears character-identically in 2 files \u2014 agent/src/tools/fund_flow_tool.py, agent/src/tools/market_data_tool.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/fund_flow_tool.py"},"region":{"startLine":237}}}],"partialFingerprints":{"codehealthFindingId/v1":"df4d851f7fee92b0ae193290bb7673a4d9fbdf0877c26492cb529543a98c5383"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060not isinstance(content, list) or len(content) != 1 or not isinstance(content[0], dict)\u0060 appears character-identically in 2 files \u2014 agent/backtest/loaders/gildata_loader.py, agent/src/tools/gildata_srv.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/gildata_loader.py"},"region":{"startLine":218}}}],"partialFingerprints":{"codehealthFindingId/v1":"3e824ec7165141ae47a62f5080d83fa90f34dc124abb03a5bc8915a3e7c18c25"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060not isinstance(content, str) or not content\u0060 appears character-identically in 2 files \u2014 agent/src/channels/mochat.py, agent/src/providers/chat.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/mochat.py"},"region":{"startLine":169}}}],"partialFingerprints":{"codehealthFindingId/v1":"bee002114f0bc57ea22f72dec41b057730cc176da6cdcb938abb87ccd706e34a"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060not isinstance(field, str) or not field.strip()\u0060 appears character-identically in 2 files \u2014 agent/backtest/engines/base.py, agent/src/tools/get_fundamentals_tool.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/engines/base.py"},"region":{"startLine":450}}}],"partialFingerprints":{"codehealthFindingId/v1":"0454be9497ad5daa6e302a520fb4f45ef50b8578defa2884f619576065866623"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060not isinstance(frame, pd.DataFrame) or frame.empty\u0060 appears character-identically in 2 files \u2014 agent/backtest/loader_health.py, agent/backtest/loaders/base.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loader_health.py"},"region":{"startLine":163}}}],"partialFingerprints":{"codehealthFindingId/v1":"a8fdcce78dffbb499594ca33c92b03fe18104adbfb33da4ec8ba49cb1dfa63db"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060not isinstance(frame.index, pd.DatetimeIndex) or not frame.index.is_unique\u0060 appears character-identically in 2 files \u2014 agent/backtest/frozen.py, agent/src/research_lab/execution.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/frozen.py"},"region":{"startLine":50}}}],"partialFingerprints":{"codehealthFindingId/v1":"2875e77f02dc4b34f3b7bf0bd68c2844e951e78fc33e878cb2eb143a5e486d1f"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060not isinstance(payload, dict) or payload.get(\u0022status\u0022) != \u0022ok\u0022\u0060 appears character-identically in 2 files \u2014 agent/src/agent/context_compact.py, agent/src/api/live_routes.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/agent/context_compact.py"},"region":{"startLine":141}}}],"partialFingerprints":{"codehealthFindingId/v1":"dc9c624f7606064e3279598312eb1ecd9a6837787ea80cf6b9d69e5f7e35c37a"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060not isinstance(payload, list) or not payload\u0060 appears character-identically in 2 files \u2014 agent/backtest/loaders/tiingo_loader.py, agent/src/tools/prediction_market_tool.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/tiingo_loader.py"},"region":{"startLine":384}}}],"partialFingerprints":{"codehealthFindingId/v1":"cced04efcf2bd81c6ec3c2ad8ce0e1f6b98a15d3c8e3638557b63f331cec1233"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060not isinstance(query, str) or not 1 \u003C= len(query.strip()) \u003C= 4000\u0060 appears character-identically in 2 files \u2014 agent/src/tools/gildata_fin_query_tool.py, agent/src/tools/gildata_stock_selection_tool.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/gildata_fin_query_tool.py"},"region":{"startLine":134}}}],"partialFingerprints":{"codehealthFindingId/v1":"2549e12da4299ce2c3767ae8b109f47acd503a714232cba59b9541ea898b82cf"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060not isinstance(query, str) or not query.strip()\u0060 appears character-identically in 3 files \u2014 agent/src/agent/instrument_identity.py, agent/src/tools/etf_holdings_tool.py, agent/src/tools/prediction_market_tool.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/agent/instrument_identity.py"},"region":{"startLine":485}}}],"partialFingerprints":{"codehealthFindingId/v1":"1693d58482873c489c7956d96541fad36400478163a895ed7135a21f86960211"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060not isinstance(raw, str) or not raw.strip()\u0060 appears character-identically in 2 files \u2014 agent/src/channels/matrix.py, agent/src/live/runtime/runner.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/matrix.py"},"region":{"startLine":384}}}],"partialFingerprints":{"codehealthFindingId/v1":"e0e0feec03dc6e33873112c13ef1638b606facef0da8fd43b3bd4ad8b0e4d537"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060not isinstance(result, dict) or result.get(\u0022isError\u0022)\u0060 appears character-identically in 2 files \u2014 agent/backtest/loaders/gildata_loader.py, agent/src/tools/gildata_srv.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/gildata_loader.py"},"region":{"startLine":215}}}],"partialFingerprints":{"codehealthFindingId/v1":"6a9ea1f6da99734d8cc3f4f6503d320dc649002d432d7685c429537ec549a5f7"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060not isinstance(seq, list) or idx \u003E= len(seq)\u0060 appears character-identically in 2 files \u2014 agent/src/tools/institutional_holdings_tool.py, agent/src/tools/sec_filings_tool.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/institutional_holdings_tool.py"},"region":{"startLine":1672}}}],"partialFingerprints":{"codehealthFindingId/v1":"f0e51b8b161b2361fc0fa77c1c3cda4de9b57b15f82bef9e2d0ee6dfc5a963e2"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060not isinstance(strategy_id, str) or not strategy_id.strip()\u0060 appears character-identically in 2 files \u2014 agent/src/strategy_discovery/facade.py, agent/src/tools/strategy_discovery_tool.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/strategy_discovery/facade.py"},"region":{"startLine":620}}}],"partialFingerprints":{"codehealthFindingId/v1":"78a91b1b097b3e138a540ebe7c7aeda0d4a6505b9a2ccbf24769de051e21b8c9"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060not isinstance(symbol, str) or not symbol.strip()\u0060 appears character-identically in 4 files \u2014 agent/src/live/runtime/flatten.py, agent/src/tools/etf_holdings_tool.py, agent/src/tools/get_fundamentals_tool.py, agent/src/trading/connectors/robinhood/mcp.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/live/runtime/flatten.py"},"region":{"startLine":365}}}],"partialFingerprints":{"codehealthFindingId/v1":"397ce7417368f0f9ed1a05266a8994eeff0557c0496518128e356871e02776bd"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060not isinstance(value, list) or not value\u0060 appears character-identically in 2 files \u2014 agent/backtest/rebalance_mask.py, agent/src/scheduled_research/playbooks.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/rebalance_mask.py"},"region":{"startLine":29}}}],"partialFingerprints":{"codehealthFindingId/v1":"05156c56b4f6278d4ab308b39e13cad185733ae3eb36ac7cdb1837cf5fa4aaaf"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060not isinstance(value, pd.Timestamp) or pd.isna(value) or value.tzinfo is None\u0060 appears character-identically in 2 files \u2014 agent/backtest/binance_account_reconciliation.py, agent/backtest/binance_shadow_evidence.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/binance_account_reconciliation.py"},"region":{"startLine":34}}}],"partialFingerprints":{"codehealthFindingId/v1":"594c9f0d34786eb15801a9fd8f8433d9fed63c4dd9e8b94839188cd3e89ce667"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060not isinstance(value, str) or not value.strip()\u0060 appears character-identically in 7 files \u2014 agent/src/channels/mochat.py, agent/src/factors/research_contract.py, agent/src/research_artifacts/financial_facts.py, agent/src/tools/fred_macro_tool.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/mochat.py"},"region":{"startLine":204}}}],"partialFingerprints":{"codehealthFindingId/v1":"8a8b898359c7767276643f134768d305eebe49c7dda393566f7af6d606d602b6"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060not line or line.startswith(\u0022#\u0022) or \u0022=\u0022 not in line\u0060 appears character-identically in 3 files \u2014 agent/src/config/dotenv.py, agent/src/providers/settings.py, agent/src/trading/tap_forward.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/config/dotenv.py"},"region":{"startLine":111}}}],"partialFingerprints":{"codehealthFindingId/v1":"bbceaee79fad3f8a6ad86044f38b7eac8c343679b2170f2a066bd97c35c9ac50"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060not math.isfinite(clean_units) or clean_units \u003C= 0\u0060 appears character-identically in 2 files \u2014 agent/src/trading/connectors/etoro/trading.py, agent/src/trading/service.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/etoro/trading.py"},"region":{"startLine":173}}}],"partialFingerprints":{"codehealthFindingId/v1":"3abc9de8e440a484378caefd77d0df6c769f386e6d02441996284aa1df3be62d"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060not np.isfinite(spread) or spread \u003C= 0.0\u0060 appears character-identically in 2 files \u2014 agent/src/quantlib/factormodel.py, agent/src/quantlib/multipletesting.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/factormodel.py"},"region":{"startLine":301}}}],"partialFingerprints":{"codehealthFindingId/v1":"e5ab08bec7c75ac9a046975398024fd2230c7873b1c808370259571d182f6cc7"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060not token or token == \u0022your-tushare-token\u0022\u0060 appears character-identically in 2 files \u2014 agent/src/preflight.py, agent/src/tools/alpha_bench_tool.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/preflight.py"},"region":{"startLine":235}}}],"partialFingerprints":{"codehealthFindingId/v1":"b7c338fc8acd5fb68d54975bdf451242c552d00294fb30dd6a1ba90c44498f19"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060np.isnan(cov).any() or np.isnan(mu).any()\u0060 appears character-identically in 2 files \u2014 agent/backtest/optimizers/mean_variance.py, agent/backtest/optimizers/turnover_aware.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/optimizers/mean_variance.py"},"region":{"startLine":32}}}],"partialFingerprints":{"codehealthFindingId/v1":"feb932c5abe178daaf23d0b741559111500b517b9e0cb6ca9d4c3017c6bbd625"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060order_id is None or str(order_id).strip() == \u0022\u0022\u0060 appears character-identically in 2 files \u2014 agent/src/trading/connectors/longbridge/sdk.py, agent/src/trading/connectors/tiger/sdk.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/longbridge/sdk.py"},"region":{"startLine":634}}}],"partialFingerprints":{"codehealthFindingId/v1":"34ef4329bcd2e9dc7ac1c83db861731a312a2b66105e6d4156fd7ab24aa2fd4b"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060os.getenv(key_env, \u0022\u0022) or os.getenv(\u0022OPENAI_API_KEY\u0022, \u0022\u0022)\u0060 appears character-identically in 2 files \u2014 agent/src/api/system_routes.py, agent/src/tools/ocr/llm_vision_ocr.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/api/system_routes.py"},"region":{"startLine":188}}}],"partialFingerprints":{"codehealthFindingId/v1":"dc3df528747563aae23bba9654acfa4613e2c6c140cecabeda445b50f4bf6d0c"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060panel.empty or not panel.index.is_unique or not panel.columns.is_unique\u0060 appears character-identically in 2 files \u2014 agent/src/quantlib/combination.py, agent/src/quantlib/neutralization.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/combination.py"},"region":{"startLine":78}}}],"partialFingerprints":{"codehealthFindingId/v1":"028cfb6d3579cc9343083c74e148e00becdf279a17ffe9966ef20254f2930af1"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060path or (get_runtime_root() / CONFIG_FILENAME)\u0060 appears character-identically in 3 files \u2014 agent/src/portfolio/config.py, agent/src/providers/custom_profiles.py, agent/src/trading/connections.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/portfolio/config.py"},"region":{"startLine":259}}}],"partialFingerprints":{"codehealthFindingId/v1":"fb4e0905da782c0621fb607a224d026e3f0d03568c16e28e8f7fe94e232461a7"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060payload.get(\u0022base_url\u0022) or DEFAULT_BASE_URL\u0060 appears character-identically in 2 files \u2014 agent/src/trading/connectors/toss/sdk.py, agent/src/trading/connectors/trading212/sdk.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/toss/sdk.py"},"region":{"startLine":92}}}],"partialFingerprints":{"codehealthFindingId/v1":"8e2b560a65d751aff8e07f866bc6db361d2b32f7edb30ea5719b5b9a97ac133a"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060payload.get(\u0022candles\u0022) or payload.get(\u0022data\u0022)\u0060 appears character-identically in 2 files \u2014 agent/backtest/loaders/tickerall_loader.py, agent/src/trading/connectors/etoro/sdk.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/tickerall_loader.py"},"region":{"startLine":379}}}],"partialFingerprints":{"codehealthFindingId/v1":"eda481620f313fc1ac28bd74a513fb915d1daf62f255c8d2878b4f122d0ca70d"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060payload.get(\u0022profile\u0022) or \u0022live-readonly\u0022\u0060 appears character-identically in 2 files \u2014 agent/src/trading/connectors/toss/sdk.py, agent/src/trading/connectors/trading212/sdk.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/toss/sdk.py"},"region":{"startLine":89}}}],"partialFingerprints":{"codehealthFindingId/v1":"c2d3f8f9c8ac50884d7810eab6ed01054f20a83bb1f3daba3d452e4344da1d2b"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060profile.connector == key and profile.environment == \u0022live\u0022\u0060 appears character-identically in 2 files \u2014 agent/src/api/live_routes.py, agent/src/trading/service.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/api/live_routes.py"},"region":{"startLine":1151}}}],"partialFingerprints":{"codehealthFindingId/v1":"392db43db8521ceb00b7e5a9c11172e67ce574fff27e144c2087a68ca702cad6"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060protect_pdf and delivery_format != \u0022pdf\u0022\u0060 appears character-identically in 3 files \u2014 agent/src/api/scheduled_routes.py, agent/src/channels/email.py, agent/src/scheduled_research/service.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/api/scheduled_routes.py"},"region":{"startLine":809}}}],"partialFingerprints":{"codehealthFindingId/v1":"bc9c3bfacabfc3b5a10f5aa4c2e753efc5ddda5b47e84ffcfc3fe440984f41df"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060remaining is not None and remaining \u003C= 0\u0060 appears character-identically in 2 files \u2014 agent/src/providers/chat.py, agent/src/providers/stream_guard.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/providers/chat.py"},"region":{"startLine":587}}}],"partialFingerprints":{"codehealthFindingId/v1":"6e25d4f034dbab42373db7bdf2a1561af23bbda9e308bb33d22d670a0bbb8193"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060response.text.strip() or response.reason or \u0022request failed\u0022\u0060 appears character-identically in 4 files \u2014 agent/src/trading/connectors/kis/sdk.py, agent/src/trading/connectors/toss/sdk.py, agent/src/trading/connectors/trading212/sdk.py, agent/src/trading/connectors/upbit/sdk.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/kis/sdk.py"},"region":{"startLine":888}}}],"partialFingerprints":{"codehealthFindingId/v1":"538d8a17d9f26715a05ad84604aa255d642ad331074470ec107b12f50488822f"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060result.error_code == \u00220\u0022 and result.next()\u0060 appears character-identically in 4 files \u2014 agent/src/data_gateway/history_source.py, tools/gateway_history_validate.py, tools/gateway_scale_probe.py, tools/gateway_ten_job_restart_probe.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/data_gateway/history_source.py"},"region":{"startLine":94}}}],"partialFingerprints":{"codehealthFindingId/v1":"9a19bbd9f4e95f83f3de87057c5db9d00bc02e73b01ff1bbc0f3ec5a3db63141"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060resume and reconciled.status not in (RunStatus.failed, RunStatus.cancelled)\u0060 appears character-identically in 3 files \u2014 agent/cli/_legacy.py, agent/mcp_server.py, agent/src/api/swarm_routes.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":2451}}}],"partialFingerprints":{"codehealthFindingId/v1":"0360a1a2ef1636272ad388d19fecd99ac5d46fc6a914710d72ca3b0b29890ed7"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060row.get(\u0022broker\u0022) == \u0022binance\u0022 and not row.get(\u0022priced\u0022)\u0060 appears character-identically in 2 files \u2014 agent/src/portfolio/service.py, agent/src/portfolio/store.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/portfolio/service.py"},"region":{"startLine":1247}}}],"partialFingerprints":{"codehealthFindingId/v1":"a1508cfb7d582ab699ba9e1760bb908375f99cc22c3155dc924956f1c73ff559"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060row.get(\u0022price_currency\u0022) or row.get(\u0022currency\u0022) or \u0022USD\u0022\u0060 appears character-identically in 2 files \u2014 agent/src/portfolio/compatibility.py, agent/src/portfolio/normalization.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/portfolio/compatibility.py"},"region":{"startLine":225}}}],"partialFingerprints":{"codehealthFindingId/v1":"a6d2b53d204d1eac2a9ccc988c53de714cde3b30fb9ccbbdd941e5c45c81c0c7"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060row.get(\u0022theme\u0022, []) or [\u0022uncategorised\u0022]\u0060 appears character-identically in 2 files \u2014 agent/src/factors/bench_runner.py, agent/src/factors/bench_runner_strict.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/bench_runner.py"},"region":{"startLine":134}}}],"partialFingerprints":{"codehealthFindingId/v1":"cd174b6bdac5c1f19ab99c268fedb04be4a88e8e22259831b1fa9036ded4805f"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060self.rebalance_mask is not None and self.position_adjustment != \u0022rebalance\u0022\u0060 appears character-identically in 2 files \u2014 agent/backtest/engines/base.py, agent/backtest/runner.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/engines/base.py"},"region":{"startLine":559}}}],"partialFingerprints":{"codehealthFindingId/v1":"d1cf053396e6a65b8f092904555493a78693c008dc4489ecfb10fd0a2ac092bf"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060snapshot or resolve_config(model_name=model_name)\u0060 appears character-identically in 2 files \u2014 agent/src/providers/chat.py, agent/src/providers/llm.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/providers/chat.py"},"region":{"startLine":360}}}],"partialFingerprints":{"codehealthFindingId/v1":"2ab8b935416f80cba4f3f5b4061635eab65264e77cbccb0073514196091309bc"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060state_summary and state_summary != \u0022(empty state)\u0022\u0060 appears character-identically in 2 files \u2014 agent/src/agent/context.py, agent/src/agent/loop.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/agent/context.py"},"region":{"startLine":396}}}],"partialFingerprints":{"codehealthFindingId/v1":"1aee12d2db010cca7dff26a2f138430c32284c7651b0d83b933e826e841eba55"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060stream_id is not None and buf.stream_id is not None and buf.stream_id != stream_id\u0060 appears character-identically in 2 files \u2014 agent/src/channels/discord.py, agent/src/channels/telegram.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/discord.py"},"region":{"startLine":529}}}],"partialFingerprints":{"codehealthFindingId/v1":"908d9d279a01c24923f6d5a0c98cb2ac938608aae1a9101ccf63c57769221451"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060type_token == \u0022limit\u0022 and limit_price is None\u0060 appears character-identically in 2 files \u2014 agent/src/trading/connectors/kis/sdk.py, agent/src/trading/connectors/upbit/sdk.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/kis/sdk.py"},"region":{"startLine":522}}}],"partialFingerprints":{"codehealthFindingId/v1":"61e5b4d7d895b4978e57cd21b3693ac29cb5e76d3732a3544c7ea095f1f0cc28"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060until is not None and time.monotonic() \u003E= until\u0060 appears character-identically in 3 files \u2014 agent/backtest/loaders/akshare_loader.py, agent/backtest/loaders/eastmoney_loader.py, agent/backtest/loaders/tencent_loader.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/akshare_loader.py"},"region":{"startLine":156}}}],"partialFingerprints":{"codehealthFindingId/v1":"ab8bd2af7e38eb178d262f8c0edd0720be0f974aa22bdd5f2147960168f775d1"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060value is None or isinstance(value, (str, int, float, bool))\u0060 appears character-identically in 2 files \u2014 agent/backtest/run_card.py, agent/src/factors/data_availability.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/run_card.py"},"region":{"startLine":386}}}],"partialFingerprints":{"codehealthFindingId/v1":"3406dd34f93f437a71089a3e4d82bdb1b9785449ffa5ec717e2f2c5fb10c750b"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060value is None or isinstance(value, bool)\u0060 appears character-identically in 2 files \u2014 agent/src/tools/options_chain_tool.py, agent/src/tools/prediction_market_tool.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/options_chain_tool.py"},"region":{"startLine":143}}}],"partialFingerprints":{"codehealthFindingId/v1":"91dd97a8e303a796af40251509d7940ca44ad17d4da363270e38049727e19750"}},{"ruleId":"X17","level":"warning","message":{"text":"Recursive walk over a caller-supplied document has no depth cap: \u0060resolve_data_refs\u0060 is public and takes \u0060value: Any\u0060 from its caller, and it calls itself at line 27 (\u0060resolve_data_refs\u0060) with a piece of \u0060value\u0060 (and at line 31) \u2014 and nowhere in \u0060resolve_data_refs\u0060 is there a depth parameter, a descent counter, or any other cap. The walk therefore spends one stack frame per LEVEL of the value it is handed, so the nesting of the caller\u0027s document \u2014 not this code \u2014 decides how deep the stack goes. Python\u0027s parsers accept far more nesting than its stack allows: \u0060json.loads\u0060 turns 3,000 bytes of brackets into 1,500 levels and \u0060xml.etree.ElementTree\u0060 parses tens of thousands, while a walk like this one raises \u0060RecursionError\u0060 once it passes the interpreter\u0027s default limit of 1,000 frames. Wherever that exception lands, the work fails: a request errors, and outside any \u0060try\u0060 the worker or the program exits with it. Raising \u0060sys.setrecursionlimit\u0060 only moves the number the document has to beat. Thread a depth argument through \u0060resolve_data_refs\u0060 and reject the value past a fixed maximum, or rewrite the descent with an explicit stack."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/data_refs.py"},"region":{"startLine":27}}}],"partialFingerprints":{"codehealthFindingId/v1":"dfd954154e0fd1513f52b337ea15065deafb6d32cc220c4f9d0f677827f510be"}},{"ruleId":"X17","level":"warning","message":{"text":"Recursive walk over a caller-supplied document has no depth cap: \u0060redact_payload\u0060 is public and takes \u0060obj: Any\u0060 from its caller, and it calls itself at line 389 (\u0060redact_payload\u0060) with a piece of \u0060obj\u0060 (and at line 393) \u2014 and nowhere in \u0060redact_payload\u0060 is there a depth parameter, a descent counter, or any other cap. The walk therefore spends one stack frame per LEVEL of the value it is handed, so the nesting of the caller\u0027s document \u2014 not this code \u2014 decides how deep the stack goes. Python\u0027s parsers accept far more nesting than its stack allows: \u0060json.loads\u0060 turns 3,000 bytes of brackets into 1,500 levels and \u0060xml.etree.ElementTree\u0060 parses tens of thousands, while a walk like this one raises \u0060RecursionError\u0060 once it passes the interpreter\u0027s default limit of 1,000 frames. Wherever that exception lands, the work fails: a request errors, and outside any \u0060try\u0060 the worker or the program exits with it. Raising \u0060sys.setrecursionlimit\u0060 only moves the number the document has to beat. Thread a depth argument through \u0060redact_payload\u0060 and reject the value past a fixed maximum, or rewrite the descent with an explicit stack."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/redaction.py"},"region":{"startLine":389}}}],"partialFingerprints":{"codehealthFindingId/v1":"b42b5e2c8ffed6568764e2d2c8f08b6c9402bc849e433e2845caa0cab7eed103"}},{"ruleId":"X17","level":"warning","message":{"text":"Recursive walk over a caller-supplied document has no depth cap: \u0060redact_payload\u0060 is public, takes a document from its caller (line 354) and hands it to \u0060_redact_token_usage\u0060, which calls itself at line 423 (\u0060_redact_token_usage\u0060) with a piece of \u0060value\u0060 \u2014 and nowhere in \u0060_redact_token_usage\u0060 is there a depth parameter, a descent counter, or any other cap. The walk therefore spends one stack frame per LEVEL of the value it is handed, so the nesting of the caller\u0027s document \u2014 not this code \u2014 decides how deep the stack goes. Python\u0027s parsers accept far more nesting than its stack allows: \u0060json.loads\u0060 turns 3,000 bytes of brackets into 1,500 levels and \u0060xml.etree.ElementTree\u0060 parses tens of thousands, while a walk like this one raises \u0060RecursionError\u0060 once it passes the interpreter\u0027s default limit of 1,000 frames. Wherever that exception lands, the work fails: a request errors, and outside any \u0060try\u0060 the worker or the program exits with it. Raising \u0060sys.setrecursionlimit\u0060 only moves the number the document has to beat. Thread a depth argument through \u0060_redact_token_usage\u0060 and reject the value past a fixed maximum, or rewrite the descent with an explicit stack."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/redaction.py"},"region":{"startLine":423}}}],"partialFingerprints":{"codehealthFindingId/v1":"91ef4038fa006c0b1783b2a0168a4697d4ffc5851dce8d8e0aec1c6394723585"}},{"ruleId":"X17","level":"warning","message":{"text":"Recursive walk over a caller-supplied document has no depth cap: \u0060validate_payload\u0060 is public, takes a document from its caller (line 760) and hands it to \u0060_validate_node\u0060, which calls itself at line 748 (\u0060_validate_node\u0060) with a piece of \u0060instance\u0060 (and at line 757) \u2014 and nowhere in \u0060_validate_node\u0060 is there a depth parameter, a descent counter, or any other cap. The walk therefore spends one stack frame per LEVEL of the value it is handed, so the nesting of the caller\u0027s document \u2014 not this code \u2014 decides how deep the stack goes. Python\u0027s parsers accept far more nesting than its stack allows: \u0060json.loads\u0060 turns 3,000 bytes of brackets into 1,500 levels and \u0060xml.etree.ElementTree\u0060 parses tens of thousands, while a walk like this one raises \u0060RecursionError\u0060 once it passes the interpreter\u0027s default limit of 1,000 frames. Wherever that exception lands, the work fails: a request errors, and outside any \u0060try\u0060 the worker or the program exits with it. Raising \u0060sys.setrecursionlimit\u0060 only moves the number the document has to beat. Thread a depth argument through \u0060_validate_node\u0060 and reject the value past a fixed maximum, or rewrite the descent with an explicit stack."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/paper_trade/schema.py"},"region":{"startLine":748}}}],"partialFingerprints":{"codehealthFindingId/v1":"ff272f4e5562b6ce227e3c0a555a378d9c89c9ffda445ec382b38a2eb8739653"}},{"ruleId":"X17","level":"warning","message":{"text":"Recursive walk over a caller-supplied document has no depth cap: \u0060canonicalize\u0060 is public and takes \u0060value: Any\u0060 from its caller, and it calls itself at line 160 (\u0060canonicalize\u0060) with a piece of \u0060value\u0060 \u2014 and nowhere in \u0060canonicalize\u0060 is there a depth parameter, a descent counter, or any other cap. The walk therefore spends one stack frame per LEVEL of the value it is handed, so the nesting of the caller\u0027s document \u2014 not this code \u2014 decides how deep the stack goes. Python\u0027s parsers accept far more nesting than its stack allows: \u0060json.loads\u0060 turns 3,000 bytes of brackets into 1,500 levels and \u0060xml.etree.ElementTree\u0060 parses tens of thousands, while a walk like this one raises \u0060RecursionError\u0060 once it passes the interpreter\u0027s default limit of 1,000 frames. Wherever that exception lands, the work fails: a request errors, and outside any \u0060try\u0060 the worker or the program exits with it. Raising \u0060sys.setrecursionlimit\u0060 only moves the number the document has to beat. Thread a depth argument through \u0060canonicalize\u0060 and reject the value past a fixed maximum, or rewrite the descent with an explicit stack."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/paper_trade/state_hash.py"},"region":{"startLine":160}}}],"partialFingerprints":{"codehealthFindingId/v1":"c6606bebc1848d3e636432b25685981fca53e0c6bb3d1fde8f678a7920099f62"}},{"ruleId":"X17","level":"warning","message":{"text":"Recursive walk over a caller-supplied document has no depth cap: \u0060with_security_warnings\u0060 is public, takes a document from its caller (line 177) and hands it to \u0060_iter_selected_targets\u0060, which calls itself at line 244 (\u0060_iter_selected_targets\u0060) with a piece of \u0060container\u0060 (and at line 253) \u2014 and nowhere in \u0060_iter_selected_targets\u0060 is there a depth parameter, a descent counter, or any other cap. The walk therefore spends one stack frame per LEVEL of the value it is handed, so the nesting of the caller\u0027s document \u2014 not this code \u2014 decides how deep the stack goes. Python\u0027s parsers accept far more nesting than its stack allows: \u0060json.loads\u0060 turns 3,000 bytes of brackets into 1,500 levels and \u0060xml.etree.ElementTree\u0060 parses tens of thousands, while a walk like this one raises \u0060RecursionError\u0060 once it passes the interpreter\u0027s default limit of 1,000 frames. Wherever that exception lands, the work fails: a request errors, and outside any \u0060try\u0060 the worker or the program exits with it. Raising \u0060sys.setrecursionlimit\u0060 only moves the number the document has to beat. Thread a depth argument through \u0060_iter_selected_targets\u0060 and reject the value past a fixed maximum, or rewrite the descent with an explicit stack."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/security/scanner.py"},"region":{"startLine":244}}}],"partialFingerprints":{"codehealthFindingId/v1":"7dc5027700935419526a41260d24542f0455ba2a6e186dea165e8db3f6a9d620"}},{"ruleId":"X17","level":"warning","message":{"text":"Recursive walk over a caller-supplied document has no depth cap: \u0060contains_pdf_password\u0060 is public and takes \u0060value: Any\u0060 from its caller, and it calls itself at line 187 (\u0060contains_pdf_password\u0060) with a piece of \u0060value\u0060 (and at line 191) \u2014 and nowhere in \u0060contains_pdf_password\u0060 is there a depth parameter, a descent counter, or any other cap. The walk therefore spends one stack frame per LEVEL of the value it is handed, so the nesting of the caller\u0027s document \u2014 not this code \u2014 decides how deep the stack goes. Python\u0027s parsers accept far more nesting than its stack allows: \u0060json.loads\u0060 turns 3,000 bytes of brackets into 1,500 levels and \u0060xml.etree.ElementTree\u0060 parses tens of thousands, while a walk like this one raises \u0060RecursionError\u0060 once it passes the interpreter\u0027s default limit of 1,000 frames. Wherever that exception lands, the work fails: a request errors, and outside any \u0060try\u0060 the worker or the program exits with it. Raising \u0060sys.setrecursionlimit\u0060 only moves the number the document has to beat. Thread a depth argument through \u0060contains_pdf_password\u0060 and reject the value past a fixed maximum, or rewrite the descent with an explicit stack."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/scheduled_research/models.py"},"region":{"startLine":187}}}],"partialFingerprints":{"codehealthFindingId/v1":"48f5cea8a27795313706626a3354cffcd4e01e33590726c9c3fac8f4cc96abd1"}},{"ruleId":"X17","level":"warning","message":{"text":"Recursive walk over a caller-supplied document has no depth cap: \u0060from_dict\u0060 is public and takes \u0060data: Dict[str, Any]\u0060 from its caller, and it calls itself at line 99 (\u0060self.from_dict\u0060) with a piece of \u0060data\u0060 \u2014 and nowhere in \u0060from_dict\u0060 is there a depth parameter, a descent counter, or any other cap. The walk therefore spends one stack frame per LEVEL of the value it is handed, so the nesting of the caller\u0027s document \u2014 not this code \u2014 decides how deep the stack goes. Python\u0027s parsers accept far more nesting than its stack allows: \u0060json.loads\u0060 turns 3,000 bytes of brackets into 1,500 levels and \u0060xml.etree.ElementTree\u0060 parses tens of thousands, while a walk like this one raises \u0060RecursionError\u0060 once it passes the interpreter\u0027s default limit of 1,000 frames. Wherever that exception lands, the work fails: a request errors, and outside any \u0060try\u0060 the worker or the program exits with it. Raising \u0060sys.setrecursionlimit\u0060 only moves the number the document has to beat. Thread a depth argument through \u0060from_dict\u0060 and reject the value past a fixed maximum, or rewrite the descent with an explicit stack."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/scheduled_research/verdict.py"},"region":{"startLine":99}}}],"partialFingerprints":{"codehealthFindingId/v1":"302377be855410cdd6892459ab673c17b2b01fd9dc42eeb1c6f77055f67beb1e"}},{"ruleId":"X17","level":"warning","message":{"text":"Recursive walk over a caller-supplied document has no depth cap: \u0060compute_input_hash\u0060 is public, takes a document from its caller (line 518) and hands it to \u0060_flatten\u0060, which calls itself at line 441 (\u0060_flatten\u0060) with a piece of \u0060value\u0060 (and at line 442, line 443, line 444, line 469, line 479) \u2014 and nowhere in \u0060_flatten\u0060 is there a depth parameter, a descent counter, or any other cap. The walk therefore spends one stack frame per LEVEL of the value it is handed, so the nesting of the caller\u0027s document \u2014 not this code \u2014 decides how deep the stack goes. Python\u0027s parsers accept far more nesting than its stack allows: \u0060json.loads\u0060 turns 3,000 bytes of brackets into 1,500 levels and \u0060xml.etree.ElementTree\u0060 parses tens of thousands, while a walk like this one raises \u0060RecursionError\u0060 once it passes the interpreter\u0027s default limit of 1,000 frames. Wherever that exception lands, the work fails: a request errors, and outside any \u0060try\u0060 the worker or the program exits with it. Raising \u0060sys.setrecursionlimit\u0060 only moves the number the document has to beat. Thread a depth argument through \u0060_flatten\u0060 and reject the value past a fixed maximum, or rewrite the descent with an explicit stack."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/quantlib/valuation/artifact.py"},"region":{"startLine":441}}}],"partialFingerprints":{"codehealthFindingId/v1":"6a8a8e067d4f64ef3ea2445da47481b400a7f2563d87fbafc13fed13704c0937"}},{"ruleId":"X17","level":"warning","message":{"text":"Recursive walk over a caller-supplied document has no depth cap: \u0060contains\u0060 is public and takes \u0060observed: Any\u0060 from its caller, and it calls itself at line 17 (\u0060contains\u0060) with a piece of \u0060observed\u0060 (and at line 24) \u2014 and nowhere in \u0060contains\u0060 is there a depth parameter, a descent counter, or any other cap. The walk therefore spends one stack frame per LEVEL of the value it is handed, so the nesting of the caller\u0027s document \u2014 not this code \u2014 decides how deep the stack goes. Python\u0027s parsers accept far more nesting than its stack allows: \u0060json.loads\u0060 turns 3,000 bytes of brackets into 1,500 levels and \u0060xml.etree.ElementTree\u0060 parses tens of thousands, while a walk like this one raises \u0060RecursionError\u0060 once it passes the interpreter\u0027s default limit of 1,000 frames. Wherever that exception lands, the work fails: a request errors, and outside any \u0060try\u0060 the worker or the program exits with it. Raising \u0060sys.setrecursionlimit\u0060 only moves the number the document has to beat. Thread a depth argument through \u0060contains\u0060 and reject the value past a fixed maximum, or rewrite the descent with an explicit stack."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/harness/observations.py"},"region":{"startLine":17}}}],"partialFingerprints":{"codehealthFindingId/v1":"00731cb981912c85190f2c413b4d6c38444fb2d7b067d28efc714578e28f5d2d"}},{"ruleId":"X17","level":"warning","message":{"text":"Recursive walk over a caller-supplied document has no depth cap: \u0060render_tool_event\u0060 is public, takes a document from its caller (line 150) and hands it to \u0060_render_value\u0060, which calls itself at line 109 (\u0060_render_value\u0060) with a piece of \u0060value\u0060 \u2014 and nowhere in \u0060_render_value\u0060 is there a depth parameter, a descent counter, or any other cap. The walk therefore spends one stack frame per LEVEL of the value it is handed, so the nesting of the caller\u0027s document \u2014 not this code \u2014 decides how deep the stack goes. Python\u0027s parsers accept far more nesting than its stack allows: \u0060json.loads\u0060 turns 3,000 bytes of brackets into 1,500 levels and \u0060xml.etree.ElementTree\u0060 parses tens of thousands, while a walk like this one raises \u0060RecursionError\u0060 once it passes the interpreter\u0027s default limit of 1,000 frames. Wherever that exception lands, the work fails: a request errors, and outside any \u0060try\u0060 the worker or the program exits with it. Raising \u0060sys.setrecursionlimit\u0060 only moves the number the document has to beat. Thread a depth argument through \u0060_render_value\u0060 and reject the value past a fixed maximum, or rewrite the descent with an explicit stack."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/components/tool_event.py"},"region":{"startLine":109}}}],"partialFingerprints":{"codehealthFindingId/v1":"b1443c5db36cb74bc9d4a77d9819b645d3d91e2e6edddf5c48d4995729dd6501"}},{"ruleId":"X17","level":"warning","message":{"text":"Recursive walk over a caller-supplied document has no depth cap: \u0060write_run_card\u0060 is public, takes a document from its caller (line 168) and hands it to \u0060_json_safe\u0060, which calls itself at line 379 (\u0060_json_safe\u0060) with a piece of \u0060value\u0060 (and at line 381) \u2014 and nowhere in \u0060_json_safe\u0060 is there a depth parameter, a descent counter, or any other cap. The walk therefore spends one stack frame per LEVEL of the value it is handed, so the nesting of the caller\u0027s document \u2014 not this code \u2014 decides how deep the stack goes. Python\u0027s parsers accept far more nesting than its stack allows: \u0060json.loads\u0060 turns 3,000 bytes of brackets into 1,500 levels and \u0060xml.etree.ElementTree\u0060 parses tens of thousands, while a walk like this one raises \u0060RecursionError\u0060 once it passes the interpreter\u0027s default limit of 1,000 frames. Wherever that exception lands, the work fails: a request errors, and outside any \u0060try\u0060 the worker or the program exits with it. Raising \u0060sys.setrecursionlimit\u0060 only moves the number the document has to beat. Thread a depth argument through \u0060_json_safe\u0060 and reject the value past a fixed maximum, or rewrite the descent with an explicit stack."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/run_card.py"},"region":{"startLine":379}}}],"partialFingerprints":{"codehealthFindingId/v1":"75491bad0940f32d56da7b0ac36992d53af372a9078a9d5a55c9f18c9b908a7d"}},{"ruleId":"X17","level":"warning","message":{"text":"Recursive walk over a caller-supplied document has no depth cap: \u0060write_validation_json\u0060 is public, takes a document from its caller (line 540) and hands it to \u0060_json_safe\u0060, which calls itself at line 528 (\u0060_json_safe\u0060) with a piece of \u0060value\u0060 (and at line 530, line 534, line 536) \u2014 and nowhere in \u0060_json_safe\u0060 is there a depth parameter, a descent counter, or any other cap. The walk therefore spends one stack frame per LEVEL of the value it is handed, so the nesting of the caller\u0027s document \u2014 not this code \u2014 decides how deep the stack goes. Python\u0027s parsers accept far more nesting than its stack allows: \u0060json.loads\u0060 turns 3,000 bytes of brackets into 1,500 levels and \u0060xml.etree.ElementTree\u0060 parses tens of thousands, while a walk like this one raises \u0060RecursionError\u0060 once it passes the interpreter\u0027s default limit of 1,000 frames. Wherever that exception lands, the work fails: a request errors, and outside any \u0060try\u0060 the worker or the program exits with it. Raising \u0060sys.setrecursionlimit\u0060 only moves the number the document has to beat. Thread a depth argument through \u0060_json_safe\u0060 and reject the value past a fixed maximum, or rewrite the descent with an explicit stack."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/validation.py"},"region":{"startLine":528}}}],"partialFingerprints":{"codehealthFindingId/v1":"414fe55b8ffe5dfa835d898ab377398cf53d42481fa52c193e4b90b5384983e2"}},{"ruleId":"X2","level":"note","message":{"text":"Not all async functions that make a request accept an AbortSignal: Only 5/8 async functions that make a cancellable request (fetch, axios, ky, ofetch, got, undici, node:http) accept an AbortSignal or pass one on, so a request keeps running after whatever wanted it has given up \u2014 a page navigated away from, an unmounted component, a timed-out job. Take a \u0060signal\u0060 (or an options object that carries one) and hand it to the request; where nothing could ever cancel the call, omitting it is a deliberate choice \u2014 judge against how the function is used."},"locations":[],"partialFingerprints":{"codehealthFindingId/v1":"bd89d014f84408f7063269aa5892ba3df7c9af3e981ecfb0752c5731bc62d406"}},{"ruleId":"X2","level":"warning","message":{"text":"Async function without AbortSignal: loadZh: \u0060loadZh\u0060 awaits \u0060fetch(\u2026)\u0060 but neither accepts an AbortSignal nor passes one on, so its caller cannot stop the request once it has started. Accept \u0060{ signal }\u0060 and pass it through: \u0060fetch(url, { signal })\u0060."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"wiki/site.js"},"region":{"startLine":49}}}],"partialFingerprints":{"codehealthFindingId/v1":"0dd361f43091ea41c2de3b9fa8095d0c826f729e315deda31ff5bd4a161d7381"}},{"ruleId":"X2","level":"warning","message":{"text":"Async function without AbortSignal: getPypi: \u0060getPypi\u0060 awaits \u0060fetch(\u2026)\u0060 but neither accepts an AbortSignal nor passes one on, so its caller cannot stop the request once it has started. Accept \u0060{ signal }\u0060 and pass it through: \u0060fetch(url, { signal })\u0060."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"wiki/functions/api/stats.js"},"region":{"startLine":13}}}],"partialFingerprints":{"codehealthFindingId/v1":"531375e5d82ac5dfb672748ec97c036ac468e1f22edbc02a6cf776d20fc587d7"}},{"ruleId":"X2","level":"warning","message":{"text":"Async function without AbortSignal: withAuthTicket: \u0060withAuthTicket\u0060 awaits \u0060fetch(\u2026)\u0060 but neither accepts an AbortSignal nor passes one on, so its caller cannot stop the request once it has started. Accept \u0060{ signal }\u0060 and pass it through: \u0060fetch(url, { signal })\u0060."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/lib/apiAuth.ts"},"region":{"startLine":36}}}],"partialFingerprints":{"codehealthFindingId/v1":"719206654617cf2c9a20af7e194f7f5c1dfb85d53f23f8550a1753268c7d96a8"}},{"ruleId":"X24","level":"warning","message":{"text":"Untrusted text written into markup unescaped: \u0060messages?.[html]??original\u0060 is text this program did not author, and it is written into the text of an element through \u0060innerHTML\u0060 with nothing encoding it for that place. Whoever controls the value controls the markup: it can close the element or attribute it sits in and open a script of its own. Encode it for HTML at this site, render it through the framework\u0027s escaping output, or sanitise it if it must stay markup."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"wiki/site.js"},"region":{"startLine":71}}}],"partialFingerprints":{"codehealthFindingId/v1":"df84b3d3605fa737504e13146aa5c63c6f27386fca00959822e90c2d78571db4"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (empty catch): An empty catch block silently discards the error \u2014 failures vanish with no log and no rethrow. Log it, handle it, or don\u0027t catch it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"wiki/main.js"},"region":{"startLine":23}}}],"partialFingerprints":{"codehealthFindingId/v1":"64b588738deb058dabcb5cf1c0aefc7f630db9ff8ae43ea0bb0379dd5da0dbde"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (empty catch): An empty catch block silently discards the error \u2014 failures vanish with no log and no rethrow. Log it, handle it, or don\u0027t catch it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"wiki/main.js"},"region":{"startLine":34}}}],"partialFingerprints":{"codehealthFindingId/v1":"fbbd8873c27ae8419fce8efc16d6a60222eebf3c9b3168480483fe4b5b8c84c3"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (empty catch): An empty catch block silently discards the error \u2014 failures vanish with no log and no rethrow. Log it, handle it, or don\u0027t catch it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"wiki/site.js"},"region":{"startLine":44}}}],"partialFingerprints":{"codehealthFindingId/v1":"d1ec1ec1c0f1bee676650f80a80cde4c0127b0fba97e9f08e587c676211f7651"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (empty catch): An empty catch block silently discards the error \u2014 failures vanish with no log and no rethrow. Log it, handle it, or don\u0027t catch it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"wiki/site.js"},"region":{"startLine":171}}}],"partialFingerprints":{"codehealthFindingId/v1":"20e36c770aa771f1d52aa3f98fa66199601667dba4b0b4f3ca9edebd97428c54"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (empty catch): An empty catch block silently discards the error \u2014 failures vanish with no log and no rethrow. Log it, handle it, or don\u0027t catch it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"wiki/site.js"},"region":{"startLine":202}}}],"partialFingerprints":{"codehealthFindingId/v1":"7cde13dddf675cbaaf0b5a4b5fdc837eb79f6ce0350877a5806091554c6f0659"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (empty catch): \u0060.catch(() =\u003E {})\u0060 handles the rejection by doing nothing \u2014 the failure is discarded with no log and no rethrow, and the chain carries on as if the work succeeded. Log it through whatever this codebase already uses to report problems, hand it to a caller that can (\u0060next(error)\u0060, a returned rejection), or don\u0027t catch it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"wiki/site.js"},"region":{"startLine":247}}}],"partialFingerprints":{"codehealthFindingId/v1":"00534fc638c2e1b02454f4aeb84ef7c4e0ca01c001a4cd0f312d9a337f395a94"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (empty catch): An empty catch block silently discards the error \u2014 failures vanish with no log and no rethrow. Log it, handle it, or don\u0027t catch it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"wiki/theme-init.js"},"region":{"startLine":28}}}],"partialFingerprints":{"codehealthFindingId/v1":"9d5e53f7a4bd9b296f22d66e831d6657132250c1010a926b3f27d8d1aafe502b"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (empty catch): \u0060.catch(() =\u003E {})\u0060 handles the rejection by doing nothing \u2014 the failure is discarded with no log and no rethrow, and the chain carries on as if the work succeeded. Log it through whatever this codebase already uses to report problems, hand it to a caller that can (\u0060next(error)\u0060, a returned rejection), or don\u0027t catch it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"wiki/functions/_middleware.js"},"region":{"startLine":66}}}],"partialFingerprints":{"codehealthFindingId/v1":"168e3ae69b4dbcdfd12e1058a01ca6cfa0eb17dec39c524f281640837cf86751"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (empty catch): An empty catch block silently discards the error \u2014 failures vanish with no log and no rethrow. Log it, handle it, or don\u0027t catch it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"wiki/functions/_middleware.js"},"region":{"startLine":69}}}],"partialFingerprints":{"codehealthFindingId/v1":"bd8f6d9a507cd1585bfdc3976b6a0855bca6cff78481e11870f43f9829a8a4ef"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (empty catch): \u0060.catch(() =\u003E {})\u0060 handles the rejection by doing nothing \u2014 the failure is discarded with no log and no rethrow, and the chain carries on as if the work succeeded. Log it through whatever this codebase already uses to report problems, hand it to a caller that can (\u0060next(error)\u0060, a returned rejection), or don\u0027t catch it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"wiki/functions/api/stats.js"},"region":{"startLine":34}}}],"partialFingerprints":{"codehealthFindingId/v1":"e331d87e382899f24af875f48d5988f93f0312aacd6d920dcdabd3f401c73fde"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (empty catch): An empty catch block silently discards the error \u2014 failures vanish with no log and no rethrow. Log it, handle it, or don\u0027t catch it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"wiki/functions/api/stats.js"},"region":{"startLine":38}}}],"partialFingerprints":{"codehealthFindingId/v1":"e3b8a3fc232d217c58f8fd8628db29e982e7dc56a4ab7327d92d4f4b848410a7"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (empty catch): An empty catch block silently discards the error \u2014 failures vanish with no log and no rethrow. Log it, handle it, or don\u0027t catch it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"wiki/functions/api/stats.js"},"region":{"startLine":49}}}],"partialFingerprints":{"codehealthFindingId/v1":"c30696ed295bfac2ba9f58c7f3a9fc5c8f80b2377ab003832203b06eddd7983c"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (empty catch): An empty catch block silently discards the error \u2014 failures vanish with no log and no rethrow. Log it, handle it, or don\u0027t catch it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"wiki/functions/api/stats.js"},"region":{"startLine":72}}}],"partialFingerprints":{"codehealthFindingId/v1":"e6f0935942d5f049f94a422c00f960754d17228b5d09b85b932a14a7b0817edf"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (empty catch): \u0060.catch(() =\u003E {})\u0060 handles the rejection by doing nothing \u2014 the failure is discarded with no log and no rethrow, and the chain carries on as if the work succeeded. Log it through whatever this codebase already uses to report problems, hand it to a caller that can (\u0060next(error)\u0060, a returned rejection), or don\u0027t catch it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Agent.tsx"},"region":{"startLine":1014}}}],"partialFingerprints":{"codehealthFindingId/v1":"a3e9b6ef8ea425133c46b290e572470ee62867aea6d489f82ff8d5ca5acf3565"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (empty catch): \u0060.catch(() =\u003E {})\u0060 handles the rejection by doing nothing \u2014 the failure is discarded with no log and no rethrow, and the chain carries on as if the work succeeded. Log it through whatever this codebase already uses to report problems, hand it to a caller that can (\u0060next(error)\u0060, a returned rejection), or don\u0027t catch it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Agent.tsx"},"region":{"startLine":1362}}}],"partialFingerprints":{"codehealthFindingId/v1":"326f9fa880c50280ed9f21cc1f7c70bb2753f9d9f15288b6158ed80d8594d1af"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (empty catch): \u0060.catch(() =\u003E {})\u0060 handles the rejection by doing nothing \u2014 the failure is discarded with no log and no rethrow, and the chain carries on as if the work succeeded. Log it through whatever this codebase already uses to report problems, hand it to a caller that can (\u0060next(error)\u0060, a returned rejection), or don\u0027t catch it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Agent.tsx"},"region":{"startLine":1537}}}],"partialFingerprints":{"codehealthFindingId/v1":"a36049a92ad9ef81504f805aa67cbab908969388205ef193bdc8f8f1a6d57b45"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (empty catch): An empty catch block silently discards the error \u2014 failures vanish with no log and no rethrow. Log it, handle it, or don\u0027t catch it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/PaperTrading.tsx"},"region":{"startLine":119}}}],"partialFingerprints":{"codehealthFindingId/v1":"6f686d1727dbeedc5637d107318b2037dcc09f0f1152f1262685131aab6ca145"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (empty catch): \u0060.then(\u2026, () =\u003E {})\u0060 handles the rejection by doing nothing \u2014 the failure is discarded with no log and no rethrow, and the chain carries on as if the work succeeded. Log it through whatever this codebase already uses to report problems, hand it to a caller that can (\u0060next(error)\u0060, a returned rejection), or don\u0027t catch it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/RunDetail.tsx"},"region":{"startLine":1176}}}],"partialFingerprints":{"codehealthFindingId/v1":"b12ecbf915772ab8e98262e899b8d13c342a40747e8b82518f65a444d3d551d3"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (empty catch): An empty catch block silently discards the error \u2014 failures vanish with no log and no rethrow. Log it, handle it, or don\u0027t catch it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/lib/attachments.ts"},"region":{"startLine":47}}}],"partialFingerprints":{"codehealthFindingId/v1":"5eeacc574dd9fb534b0285ddc06a77084033feaa9416971984b2879ecbebe848"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (empty catch): An empty catch block silently discards the error \u2014 failures vanish with no log and no rethrow. Log it, handle it, or don\u0027t catch it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/lib/storage.ts"},"region":{"startLine":18}}}],"partialFingerprints":{"codehealthFindingId/v1":"0c9f7646dca4577cd8495e9d3a1b0d08041c3a882fb84ed51ce17e3c56072ad1"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (empty catch): An empty catch block silently discards the error \u2014 failures vanish with no log and no rethrow. Log it, handle it, or don\u0027t catch it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/lib/storage.ts"},"region":{"startLine":26}}}],"partialFingerprints":{"codehealthFindingId/v1":"35755449fdcf9c65c46ca8d0b62e9370eed8acbb78731e0072ed50c45c9cec82"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (empty catch): An empty catch block silently discards the error \u2014 failures vanish with no log and no rethrow. Log it, handle it, or don\u0027t catch it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/hooks/useAlphaJob.ts"},"region":{"startLine":39}}}],"partialFingerprints":{"codehealthFindingId/v1":"57570314f6ec5adc92280ce21a4399b6c501ed5d726bdcd6fc1003c867768f21"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (empty catch): An empty catch block silently discards the error \u2014 failures vanish with no log and no rethrow. Log it, handle it, or don\u0027t catch it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/hooks/useAlphaJob.ts"},"region":{"startLine":43}}}],"partialFingerprints":{"codehealthFindingId/v1":"535232cc838053e53209120ddb75ee5b1acbe7c2353d10e18cfebb5b6ada4d1e"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (empty catch): An empty catch block silently discards the error \u2014 failures vanish with no log and no rethrow. Log it, handle it, or don\u0027t catch it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/hooks/useAlphaJob.ts"},"region":{"startLine":53}}}],"partialFingerprints":{"codehealthFindingId/v1":"55e2c63ecb810b064870f201862e1c8361c6eb52411113e939b5b9ef3bad50d9"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (empty catch): An empty catch block silently discards the error \u2014 failures vanish with no log and no rethrow. Log it, handle it, or don\u0027t catch it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/hooks/useAnalysisState.ts"},"region":{"startLine":10}}}],"partialFingerprints":{"codehealthFindingId/v1":"f28fb1aa2fa8ad85e395fc52ae4af5bfa2ad9f1d971bd01697b1b5f4b329b5e2"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (empty catch): An empty catch block silently discards the error \u2014 failures vanish with no log and no rethrow. Log it, handle it, or don\u0027t catch it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/hooks/useAnalysisState.ts"},"region":{"startLine":25}}}],"partialFingerprints":{"codehealthFindingId/v1":"436395f53068dac477fe65e42caad31b4fc590f80621ac9945bccded2f130674"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (empty catch): An empty catch block silently discards the error \u2014 failures vanish with no log and no rethrow. Log it, handle it, or don\u0027t catch it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/hooks/useAnalysisState.ts"},"region":{"startLine":40}}}],"partialFingerprints":{"codehealthFindingId/v1":"08af38245011738d64cac36dfdb4c8ab5b3255f925b1892aa04322dde951814f"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (empty catch): An empty catch block silently discards the error \u2014 failures vanish with no log and no rethrow. Log it, handle it, or don\u0027t catch it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/chat/MessageBubble.tsx"},"region":{"startLine":129}}}],"partialFingerprints":{"codehealthFindingId/v1":"7a0a161412dd22cb6f392a0321d36ed3f7ab10cbbb865527cd121753325d061c"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (empty catch): \u0060.catch(() =\u003E {})\u0060 handles the rejection by doing nothing \u2014 the failure is discarded with no log and no rethrow, and the chain carries on as if the work succeeded. Log it through whatever this codebase already uses to report problems, hand it to a caller that can (\u0060next(error)\u0060, a returned rejection), or don\u0027t catch it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/chat/RunCompleteCard.tsx"},"region":{"startLine":44}}}],"partialFingerprints":{"codehealthFindingId/v1":"cd0b6470d1c8e1ee845b5a4ae6cacce725fc639d8cf118e780247f7d558f48cf"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (empty catch): An empty catch block silently discards the error \u2014 failures vanish with no log and no rethrow. Log it, handle it, or don\u0027t catch it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/chat/RunCompleteCard.tsx"},"region":{"startLine":84}}}],"partialFingerprints":{"codehealthFindingId/v1":"1989b39bf3588f3f6da187f4ce227f8bd0233687fc521a8aed9c6a7ed27bf471"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (empty catch): An empty catch block silently discards the error \u2014 failures vanish with no log and no rethrow. Log it, handle it, or don\u0027t catch it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/chat/SwarmStatusCard.tsx"},"region":{"startLine":219}}}],"partialFingerprints":{"codehealthFindingId/v1":"59af28bde472e17b6c2858e4881c5fa534ef5a9dfa3a7c54786fcccc831584c3"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (empty catch): An empty catch block silently discards the error \u2014 failures vanish with no log and no rethrow. Log it, handle it, or don\u0027t catch it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/public/theme-boot.js"},"region":{"startLine":7}}}],"partialFingerprints":{"codehealthFindingId/v1":"91d457c547162a49d5585e316b7a358e5886930c9baaa201dba49a78d9ee54be"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (empty catch): An empty catch block silently discards the error \u2014 failures vanish with no log and no rethrow. Log it, handle it, or don\u0027t catch it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/public/theme-boot.js"},"region":{"startLine":15}}}],"partialFingerprints":{"codehealthFindingId/v1":"8377d07d68c79e9ae0acf44aed97a330230d898bbb5d34741025a8cb6a60a351"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (empty catch): An empty catch block silently discards the error \u2014 failures vanish with no log and no rethrow. Log it, handle it, or don\u0027t catch it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"desktop/electron/src/backend-manager.ts"},"region":{"startLine":278}}}],"partialFingerprints":{"codehealthFindingId/v1":"625b1233db0010d4aa946c81a6e052c895b7a481176bf43df26f56f6ed40194b"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (empty catch): An empty catch block silently discards the error \u2014 failures vanish with no log and no rethrow. Log it, handle it, or don\u0027t catch it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"desktop/electron/src/backend-manager.ts"},"region":{"startLine":524}}}],"partialFingerprints":{"codehealthFindingId/v1":"554753e0e97d5aef7bdf3fc80c335ceedee5062e45b5fecd3f6a621e3740cf56"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (empty catch): An empty catch block silently discards the error \u2014 failures vanish with no log and no rethrow. Log it, handle it, or don\u0027t catch it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"desktop/electron/src/backend-watchdog.ts"},"region":{"startLine":123}}}],"partialFingerprints":{"codehealthFindingId/v1":"1849b5b8e5d3fad0d6407f53bb29aa6ce566fd2e8b2f554563056ef62f096823"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (empty catch): An empty catch block silently discards the error \u2014 failures vanish with no log and no rethrow. Log it, handle it, or don\u0027t catch it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"desktop/electron/scripts/process-sentinel.mjs"},"region":{"startLine":37}}}],"partialFingerprints":{"codehealthFindingId/v1":"08c8bf3bf189c16e39e3557d7ab0cbf8dfd94e36a72e9126bba0e6ee6cf32990"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (empty catch): An empty catch block silently discards the error \u2014 failures vanish with no log and no rethrow. Log it, handle it, or don\u0027t catch it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/mcp_server.py"},"region":{"startLine":2035}}}],"partialFingerprints":{"codehealthFindingId/v1":"75a298187aa7e7c60fa01cd12a70984403aa1028cfe7ca65e8ca9cc50c4c22fa"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (empty catch): An empty catch block silently discards the error \u2014 failures vanish with no log and no rethrow. Log it, handle it, or don\u0027t catch it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/mcp_server.py"},"region":{"startLine":2064}}}],"partialFingerprints":{"codehealthFindingId/v1":"1cddbc1dfe762bda99ed6e70f3cd36a7d5c5c8251c16294d40967784c39c33b7"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060except Exception\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/ui_services.py"},"region":{"startLine":61}}}],"partialFingerprints":{"codehealthFindingId/v1":"43531b6ae19fb3f8807141fed3a6dd080dff2801e90ce7f91784dc58985798ce"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060except Exception\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/ui_services.py"},"region":{"startLine":82}}}],"partialFingerprints":{"codehealthFindingId/v1":"84a7cfad64835564bead60b29357dd6bd571ce1a1de5c560647068182a30d00c"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (empty catch): An empty catch block silently discards the error \u2014 failures vanish with no log and no rethrow. Log it, handle it, or don\u0027t catch it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/ui_services.py"},"region":{"startLine":465}}}],"partialFingerprints":{"codehealthFindingId/v1":"c89ca226f708e0b7d6536fa6ac2657555700d2b634645f2cbaeaa3e2fad03135"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060except Exception\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/credentials.py"},"region":{"startLine":150}}}],"partialFingerprints":{"codehealthFindingId/v1":"98530be4804e5c664e6e088fb2dfbd221d43db0e439459f59e8b0f91bdca98db"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (empty catch): An empty catch block silently discards the error \u2014 failures vanish with no log and no rethrow. Log it, handle it, or don\u0027t catch it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/mt5/_client.py"},"region":{"startLine":298}}}],"partialFingerprints":{"codehealthFindingId/v1":"1c8fa57bb6dd1992640bf1ef2474be58a8415b9a3ec440da1fb3299bd8fcb4c6"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (empty catch): An empty catch block silently discards the error \u2014 failures vanish with no log and no rethrow. Log it, handle it, or don\u0027t catch it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/ibkr/local.py"},"region":{"startLine":594}}}],"partialFingerprints":{"codehealthFindingId/v1":"7e637d1702044129636b1b65a433a29121f53a76cb8fede0b9587217fd1659df"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (empty catch): An empty catch block silently discards the error \u2014 failures vanish with no log and no rethrow. Log it, handle it, or don\u0027t catch it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/bash_tool.py"},"region":{"startLine":49}}}],"partialFingerprints":{"codehealthFindingId/v1":"2e37829341ce20c2d2bb75917fc68e9ef74f603eb110aa4b447f643c0289ab06"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (empty catch): An empty catch block silently discards the error \u2014 failures vanish with no log and no rethrow. Log it, handle it, or don\u0027t catch it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/bash_tool.py"},"region":{"startLine":57}}}],"partialFingerprints":{"codehealthFindingId/v1":"8aca87ebac87f60f62f61f527e1d2d00418d012eddfed5368b47de5c682d0a88"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060except Exception\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/bash_tool.py"},"region":{"startLine":157}}}],"partialFingerprints":{"codehealthFindingId/v1":"442cc066a4b1cfc69502736b23a0cdaf7a215f9823aa668ee7fcaef2eae133d5"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060except Exception\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/goal_tool.py"},"region":{"startLine":144}}}],"partialFingerprints":{"codehealthFindingId/v1":"ccdb5deee637088b8edfe897b01788b3da64fe7f10d690a01acbe4a2f7b57c16"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (empty catch): An empty catch block silently discards the error \u2014 failures vanish with no log and no rethrow. Log it, handle it, or don\u0027t catch it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/remember_tool.py"},"region":{"startLine":149}}}],"partialFingerprints":{"codehealthFindingId/v1":"d4089e6c341d45fe4a4a6b4acdc99e2d4e6c49b1966437795d993ad842fa83b5"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (empty catch): An empty catch block silently discards the error \u2014 failures vanish with no log and no rethrow. Log it, handle it, or don\u0027t catch it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/trade_journal_parsers.py"},"region":{"startLine":758}}}],"partialFingerprints":{"codehealthFindingId/v1":"9d405573e5625b4eef2871262578200f5265304d9db63fb4e3befafaf0a70088"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060except Exception\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/ocr/engine.py"},"region":{"startLine":113}}}],"partialFingerprints":{"codehealthFindingId/v1":"f574a42d72bcc1961f1f46081f3bb4b550f070c153fd71461f356203829d2ef7"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (empty catch): An empty catch block silently discards the error \u2014 failures vanish with no log and no rethrow. Log it, handle it, or don\u0027t catch it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/ocr/engine.py"},"region":{"startLine":186}}}],"partialFingerprints":{"codehealthFindingId/v1":"309dff89cff2774ab140f7f95c590a035be9355fbaf754a1f76aeb0654b49975"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060except Exception\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/ocr/llm_vision_ocr.py"},"region":{"startLine":185}}}],"partialFingerprints":{"codehealthFindingId/v1":"0bca53627e6a49b6d8361857403e4d56534f1476b2a530914e7609982b64ed6d"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060except Exception\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/swarm/presets.py"},"region":{"startLine":129}}}],"partialFingerprints":{"codehealthFindingId/v1":"9517ba20b3382d17f8c616bdc87c9fd9228286ae0151519bbf7f5cfa2bda0b0e"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (empty catch): An empty catch block silently discards the error \u2014 failures vanish with no log and no rethrow. Log it, handle it, or don\u0027t catch it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/swarm/store.py"},"region":{"startLine":555}}}],"partialFingerprints":{"codehealthFindingId/v1":"b56b174f6fdf8007b7770057702f345879fc9219b6c1257feec30a41bbf0d9cf"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060except Exception\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/swarm/worker.py"},"region":{"startLine":247}}}],"partialFingerprints":{"codehealthFindingId/v1":"bac7c2aae70bd96e7d25a21a57016cf602d767986668c82d8e86a18ac091abf7"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (empty catch): An empty catch block silently discards the error \u2014 failures vanish with no log and no rethrow. Log it, handle it, or don\u0027t catch it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/skills/harmonic/example_signal_engine.py"},"region":{"startLine":382}}}],"partialFingerprints":{"codehealthFindingId/v1":"e35d0c53772be5e7def966110a3b6f5e4acd59030e754a7dacf83f636814731b"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060except Exception\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/shadow_account/backtester.py"},"region":{"startLine":482}}}],"partialFingerprints":{"codehealthFindingId/v1":"c0ff6e92728317d25295a9628323fbe56ba12d755388e90991073e0bcd580c50"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060except Exception\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/shadow_account/pdf_fallback.py"},"region":{"startLine":44}}}],"partialFingerprints":{"codehealthFindingId/v1":"2446d49fb482d20c231efd8266c4620d73c7181cabcfd212381fcee1f9c99345"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060except Exception\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/shadow_account/scanner.py"},"region":{"startLine":99}}}],"partialFingerprints":{"codehealthFindingId/v1":"0141dbf3854b1a5c62c7caa6d58dcbfc9584e46d0ed81ac3075ee2079eb3652f"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060except Exception\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/session/service.py"},"region":{"startLine":887}}}],"partialFingerprints":{"codehealthFindingId/v1":"1e1ed6e6a48de97cb0d5efa04396d86dd7c7092de96fc500c0a0ee7b066188c3"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060except Exception\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/scheduled_research/service.py"},"region":{"startLine":73}}}],"partialFingerprints":{"codehealthFindingId/v1":"94e3b59aa469930446301ce186f384b1273857bfe4fa34d4c7c3aac940bde129"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060except Exception\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/scheduled_research/service.py"},"region":{"startLine":96}}}],"partialFingerprints":{"codehealthFindingId/v1":"48002b1553566cc7c91f29e86ac6e8503df607def47f0850fb63b8eb9a45132c"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060except Exception\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/providers/openai_codex.py"},"region":{"startLine":279}}}],"partialFingerprints":{"codehealthFindingId/v1":"7bc4ea47681e09057ea50ab5ffb7ce82f93f95bc47ff4926e2f0cac4040b0778"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060except BaseException\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/providers/stream_guard.py"},"region":{"startLine":88}}}],"partialFingerprints":{"codehealthFindingId/v1":"7193bcf8d1b0e151499a139d0c95599b03c7368c8362503eb317cfa7454b2d69"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060except Exception\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/portfolio/service.py"},"region":{"startLine":351}}}],"partialFingerprints":{"codehealthFindingId/v1":"3405b919f8b3175f8a56dc4aff0efe259cffdea158f5e72ab06c71f56215f66c"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060except Exception\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/memory/search_index.py"},"region":{"startLine":296}}}],"partialFingerprints":{"codehealthFindingId/v1":"90e6aed1768e5da173ccc8b646e7ce5e2cdae65a2de9b4831b2d2cbe51e98bb6"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060except Exception\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/live/enforcement.py"},"region":{"startLine":808}}}],"partialFingerprints":{"codehealthFindingId/v1":"7c7fbea5d2a2ab706c481c12b2560d8fbfc6510d52ea0c249682bd9c945f3b9f"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (empty catch): An empty catch block silently discards the error \u2014 failures vanish with no log and no rethrow. Log it, handle it, or don\u0027t catch it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/cli_handlers.py"},"region":{"startLine":42}}}],"partialFingerprints":{"codehealthFindingId/v1":"c63c634af1bb6162cb289aae1490555a9b298d59d6076fa3f5de623a4f8a7102"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (empty catch): An empty catch block silently discards the error \u2014 failures vanish with no log and no rethrow. Log it, handle it, or don\u0027t catch it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/cli_handlers.py"},"region":{"startLine":90}}}],"partialFingerprints":{"codehealthFindingId/v1":"52623ac6cd24ce49e84505134a48527e547ee39253bf23a8a4d4d36d6b04a658"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060except Exception\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/cli_handlers.py"},"region":{"startLine":143}}}],"partialFingerprints":{"codehealthFindingId/v1":"dcdf6c3ab56460a4b512d8ad78bc99187c660f3fabf52279ed15e77771bc0f5e"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060except Exception\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/cli_handlers.py"},"region":{"startLine":151}}}],"partialFingerprints":{"codehealthFindingId/v1":"333f152be1b941a340882a04883788977f1cf8fc02663c750edc9d9affbdeab6"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060except Exception\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/cli_handlers.py"},"region":{"startLine":428}}}],"partialFingerprints":{"codehealthFindingId/v1":"936243a17e8878e29438d46472e1a06451aae7d090779531bd2ab462f48f4b9c"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060except Exception\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/data_gateway/isolated.py"},"region":{"startLine":127}}}],"partialFingerprints":{"codehealthFindingId/v1":"92f11413729d6b620b6cf26a1dc34d66cc922d90900f265475880dfcd2e3acda"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060except Exception\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/data_gateway/service.py"},"region":{"startLine":163}}}],"partialFingerprints":{"codehealthFindingId/v1":"a7a6856f6d27710300cc3bb3db6b8e1252fc14e69c74c73d3e6dee1ee12d781b"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060except Exception\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/core/runner.py"},"region":{"startLine":498}}}],"partialFingerprints":{"codehealthFindingId/v1":"37b70e48a84d708aba067c32ca3b2f1ffa467de5b3cb1d4496099db86fedc761"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060except Exception\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/dingtalk.py"},"region":{"startLine":597}}}],"partialFingerprints":{"codehealthFindingId/v1":"8bbaa292ad6467f99042611b8c1f342e82866789709c1c4a8d3a6e4977c46a27"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060except Exception\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/email.py"},"region":{"startLine":915}}}],"partialFingerprints":{"codehealthFindingId/v1":"4b3154f3eb4f105b7be1f5dd3e0a4d00458d0714f7189781b1ece679cb99aa26"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060except Exception\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/matrix.py"},"region":{"startLine":138}}}],"partialFingerprints":{"codehealthFindingId/v1":"b5a5e439aede736e70a6e9a5f627be96fd92e4a98858ff4a096bfe42a5fba111"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060except Exception\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/mochat.py"},"region":{"startLine":919}}}],"partialFingerprints":{"codehealthFindingId/v1":"facc37c4b4ff3d0635a5fa56bf7ffecd21f9b67cabdfe9e0ade52bfe1abd938f"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (empty catch): An empty catch block silently discards the error \u2014 failures vanish with no log and no rethrow. Log it, handle it, or don\u0027t catch it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/napcat.py"},"region":{"startLine":157}}}],"partialFingerprints":{"codehealthFindingId/v1":"7520bb216c63847d513ef7e3f94beac307edc119cbb55f0a35c691c64992e6fc"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (empty catch): An empty catch block silently discards the error \u2014 failures vanish with no log and no rethrow. Log it, handle it, or don\u0027t catch it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/napcat.py"},"region":{"startLine":163}}}],"partialFingerprints":{"codehealthFindingId/v1":"4dccf013d2d1c616572fa94fdba061859c6dadd71a91b0f2199d1109c2a0c8bb"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060except Exception\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/qq.py"},"region":{"startLine":45}}}],"partialFingerprints":{"codehealthFindingId/v1":"9e3a2eb699b65d82380f576617b37a6837ae50cad57c3a97bd37a7f6b3d3e367"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (empty catch): An empty catch block silently discards the error \u2014 failures vanish with no log and no rethrow. Log it, handle it, or don\u0027t catch it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/signal.py"},"region":{"startLine":535}}}],"partialFingerprints":{"codehealthFindingId/v1":"05ff19784b6b0b65c214313f6bb3a4c79a49c0651decaff09dae627bbc395a09"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060except Exception\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/weixin.py"},"region":{"startLine":68}}}],"partialFingerprints":{"codehealthFindingId/v1":"a80fb601b1f12f7187ff0b55daae4139137d623e457b4a41c227f27129491eae"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (empty catch): An empty catch block silently discards the error \u2014 failures vanish with no log and no rethrow. Log it, handle it, or don\u0027t catch it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/whatsapp.py"},"region":{"startLine":104}}}],"partialFingerprints":{"codehealthFindingId/v1":"d17ba7e7902b7d797690fb6b71dab68e5c2f2efef60279d2bb21e3d3e9704efc"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060except Exception\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/api/live_routes.py"},"region":{"startLine":383}}}],"partialFingerprints":{"codehealthFindingId/v1":"3b20cb9be0181078a53dd15294c0db88e4ab46f9a7d669a3597622b9d4bb8a70"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060except Exception\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/api/runs_routes.py"},"region":{"startLine":153}}}],"partialFingerprints":{"codehealthFindingId/v1":"eb2befd3d688aa4bb73ea02731e9beb1c40036cda00ef2e8944b993487b0b6d1"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060except Exception\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/api/runs_routes.py"},"region":{"startLine":200}}}],"partialFingerprints":{"codehealthFindingId/v1":"0c042d7cca41f2cd4100985864bf7217d34d58641baeca0e1a1e54c1bc4fdc72"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060except Exception\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/api/runs_routes.py"},"region":{"startLine":499}}}],"partialFingerprints":{"codehealthFindingId/v1":"4ae5a1826d14ca94cf489ff48263fed1427f07b6cd54075a06cf757dc1e0eee3"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060except Exception\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/api/settings_routes.py"},"region":{"startLine":219}}}],"partialFingerprints":{"codehealthFindingId/v1":"fcf998474c37cda7eaf0fa2c47b72da1d0370d14a322282cc2993e2f047185ee"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060except Exception\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/api/settings_routes.py"},"region":{"startLine":228}}}],"partialFingerprints":{"codehealthFindingId/v1":"9a4456661710d1d0a1869a3cebe1377da69d4d7b3935bd229acebc0ca0d99246"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060except Exception\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/api/settings_routes.py"},"region":{"startLine":237}}}],"partialFingerprints":{"codehealthFindingId/v1":"1b56d0c50dbcf6d1b39e8ce88d4efcc97950b71ebb5ab45dc3962695f412b4e9"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060except Exception\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/agent/context.py"},"region":{"startLine":309}}}],"partialFingerprints":{"codehealthFindingId/v1":"eb7ecd85a8b81c8a6e9bd628b8fee4db99fe29622b16c8236d998fb3401863bc"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (empty catch): An empty catch block silently discards the error \u2014 failures vanish with no log and no rethrow. Log it, handle it, or don\u0027t catch it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/agent/loop.py"},"region":{"startLine":1641}}}],"partialFingerprints":{"codehealthFindingId/v1":"089272666777e967039f5ed7c9bf33e6c992fef6bd21eb67426107fcded23a66"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060except Exception\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/agent/skills.py"},"region":{"startLine":58}}}],"partialFingerprints":{"codehealthFindingId/v1":"8b59bf4def0103308cc7c83ae66e14d80d618fbfeec5a32ae4c9f1c3f9d8c217"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060except Exception\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/agent/skills.py"},"region":{"startLine":79}}}],"partialFingerprints":{"codehealthFindingId/v1":"bfe6a3763dbaf27b8ca9eacc5c1f8066f0ebbdd90959dc7bbaa0c744c5fd976f"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060except Exception\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/agent/tool_lifecycle.py"},"region":{"startLine":1024}}}],"partialFingerprints":{"codehealthFindingId/v1":"0d315ea20db3b6a516f3d0e52503ebf324248e4f234972b1eca82c1e130cbbf7"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060except Exception\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":353}}}],"partialFingerprints":{"codehealthFindingId/v1":"a94d1a3f8ae29bc9901cb9213801ebe7293faaaf3fae4a39ea8c98c997b3237c"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060except Exception\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":420}}}],"partialFingerprints":{"codehealthFindingId/v1":"c90638884a2f6ea962381ef155d75d01699735946dc9fb9dabac0d20839e5111"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (empty catch): An empty catch block silently discards the error \u2014 failures vanish with no log and no rethrow. Log it, handle it, or don\u0027t catch it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":430}}}],"partialFingerprints":{"codehealthFindingId/v1":"2cc6487acad22a198e304bfbd11415316a73daa068a416fc4bc9d4d0b2de9351"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (empty catch): An empty catch block silently discards the error \u2014 failures vanish with no log and no rethrow. Log it, handle it, or don\u0027t catch it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":2974}}}],"partialFingerprints":{"codehealthFindingId/v1":"e58396d1840a894ff2226a487e22989ab0b6c1d825c16750c1f0866a56c3feb5"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060except Exception\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":3602}}}],"partialFingerprints":{"codehealthFindingId/v1":"df4cecfbd831cfb5a89b22c191e94302986482885a53fc413d35b955d828b8af"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060except Exception\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":3958}}}],"partialFingerprints":{"codehealthFindingId/v1":"d691d2092a9ccd942b6ed835a07230b635fc37366808653994df8cb1bbb53be5"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060except Exception\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/main.py"},"region":{"startLine":170}}}],"partialFingerprints":{"codehealthFindingId/v1":"58cf0a290bfeb5ff51c1dd47f7f56edd111aac0f9ad9eefa2e667a3be16ec72b"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060except Exception\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/main.py"},"region":{"startLine":187}}}],"partialFingerprints":{"codehealthFindingId/v1":"76e61f6324385fc0555224d627bb7e3c21dfb35deec4c84391b80b4b8a8e899d"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (empty catch): An empty catch block silently discards the error \u2014 failures vanish with no log and no rethrow. Log it, handle it, or don\u0027t catch it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/main.py"},"region":{"startLine":433}}}],"partialFingerprints":{"codehealthFindingId/v1":"b18e5369c8a7138d48c5a5be35ca5861573d69a075a7cada9908242ba7b768b7"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (empty catch): An empty catch block silently discards the error \u2014 failures vanish with no log and no rethrow. Log it, handle it, or don\u0027t catch it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/main.py"},"region":{"startLine":473}}}],"partialFingerprints":{"codehealthFindingId/v1":"39ba21b4441ddff27d8b3ec62eab9c998c1c82e7d7c72da146a296e74d981e5b"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060except Exception\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/main.py"},"region":{"startLine":489}}}],"partialFingerprints":{"codehealthFindingId/v1":"74e6461423a7c64b836e89c3ae649ca7b134b8367dab313eb575ae9950ebb570"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (empty catch): An empty catch block silently discards the error \u2014 failures vanish with no log and no rethrow. Log it, handle it, or don\u0027t catch it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/main.py"},"region":{"startLine":536}}}],"partialFingerprints":{"codehealthFindingId/v1":"a927959938ecf6e51640e7e31596504fe4487851d02da776f494957de30aafef"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060except Exception\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/main.py"},"region":{"startLine":664}}}],"partialFingerprints":{"codehealthFindingId/v1":"9027e741de401e311995842f1377d35a899387c5482778465129cd5e64210a28"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060except Exception\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/main.py"},"region":{"startLine":1328}}}],"partialFingerprints":{"codehealthFindingId/v1":"4023aa355ba9c2f4bde8f86b99dcd727998f7079f4af82dc0f687f9e718eab65"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060except Exception\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/main.py"},"region":{"startLine":1362}}}],"partialFingerprints":{"codehealthFindingId/v1":"6ba91d67b3bc5846639d2616098a8d8ed0d4a652bc0bffcdd101d2dfd88bdb12"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (empty catch): An empty catch block silently discards the error \u2014 failures vanish with no log and no rethrow. Log it, handle it, or don\u0027t catch it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/stream.py"},"region":{"startLine":158}}}],"partialFingerprints":{"codehealthFindingId/v1":"5ca2b4605971f0edca24293f4f9a586e7efb4457897a0222158a35903f5f3766"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (empty catch): An empty catch block silently discards the error \u2014 failures vanish with no log and no rethrow. Log it, handle it, or don\u0027t catch it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/stream.py"},"region":{"startLine":193}}}],"partialFingerprints":{"codehealthFindingId/v1":"b9a3a989dd55ea26b0d87f07084905a779d80a051111abc626d274663e2396d1"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (empty catch): An empty catch block silently discards the error \u2014 failures vanish with no log and no rethrow. Log it, handle it, or don\u0027t catch it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/commands/chat.py"},"region":{"startLine":95}}}],"partialFingerprints":{"codehealthFindingId/v1":"74e9db4ff0f85f9e84fe47fed2f998629424b91262aa76b262513f0b33c208e5"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060except Exception\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/commands/goal.py"},"region":{"startLine":67}}}],"partialFingerprints":{"codehealthFindingId/v1":"ee704713527e34b82911bf4cadc6716e0bb74d8c75a2fefe5c0f49097ad001f5"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060except Exception\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/benchmark.py"},"region":{"startLine":147}}}],"partialFingerprints":{"codehealthFindingId/v1":"feb12b40dafbdccaded15aa4f396b5bc2e945e8bbff4f6cae6aaa4b7d96102e0"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060except Exception\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/akshare_loader.py"},"region":{"startLine":311}}}],"partialFingerprints":{"codehealthFindingId/v1":"e7ffbd071cfd57af27f8fc915812ffb58334cb4e9152975177ff49a74113ed0d"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060except Exception\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/futu.py"},"region":{"startLine":147}}}],"partialFingerprints":{"codehealthFindingId/v1":"0c906b55833ba21fac493ca62941b61bdb85db4cf1f7631f8b8daacda910ae2d"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060except Exception\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/gildata_codes.py"},"region":{"startLine":69}}}],"partialFingerprints":{"codehealthFindingId/v1":"86810d5e8a9a8a004bc4e11121221b21d31dadfbf52fe2118379c765cdf19126"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060except Exception\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/longbridge.py"},"region":{"startLine":253}}}],"partialFingerprints":{"codehealthFindingId/v1":"adb4c6059116529909b44b1c87dd3a9550985506f232572fb28b2919b18eb5d0"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060except Exception\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/longbridge.py"},"region":{"startLine":383}}}],"partialFingerprints":{"codehealthFindingId/v1":"fa4f587123417aa522ccf4ca9ac6ef15864044c4f633e1f5999972e3c0cf4d2f"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (empty catch): An empty catch block silently discards the error \u2014 failures vanish with no log and no rethrow. Log it, handle it, or don\u0027t catch it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/mt5_loader.py"},"region":{"startLine":121}}}],"partialFingerprints":{"codehealthFindingId/v1":"dd92ed95d27e119b656b99a5b857dda25a4725be2ddd82252410653bca7cdca9"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060except Exception\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/okx.py"},"region":{"startLine":224}}}],"partialFingerprints":{"codehealthFindingId/v1":"fa122c48c601b3e66f0ded73e7c3f8cda47603a16df9db800a1d8a29d763883d"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (empty catch): An empty catch block silently discards the error \u2014 failures vanish with no log and no rethrow. Log it, handle it, or don\u0027t catch it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/registry.py"},"region":{"startLine":137}}}],"partialFingerprints":{"codehealthFindingId/v1":"7a3cde5c3bdf1a706c530d426a291169c89abe216f00e1a909a43f4abc16494f"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060except Exception\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/engines/base.py"},"region":{"startLine":2459}}}],"partialFingerprints":{"codehealthFindingId/v1":"9b510e5fd4c894beb80f0620b30ca0dfa1d0d015318ad9e4ae5c83b16ab435d4"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (empty catch): An empty catch block silently discards the error \u2014 failures vanish with no log and no rethrow. Log it, handle it, or don\u0027t catch it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/engines/china_a.py"},"region":{"startLine":95}}}],"partialFingerprints":{"codehealthFindingId/v1":"de3d8f2773b14ca16cc75e696d8f55ee86b8a98d6d305e2bcba8382ef644bb37"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (empty catch): An empty catch block silently discards the error \u2014 failures vanish with no log and no rethrow. Log it, handle it, or don\u0027t catch it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/engines/india_equity.py"},"region":{"startLine":121}}}],"partialFingerprints":{"codehealthFindingId/v1":"a406c44f01d0d4ec7044dd6f6139c3bbf3a808759942f5625dab707824ac21d6"}},{"ruleId":"X4","level":"note","message":{"text":"Interpolated log message defeats structured logging: \u0060info\u0060 at line 605 is handed an f-string as its message, so the logger receives one finished string \u2014 the values in it cannot be queried, filtered or aggregated as fields, every occurrence reads as a different message, and the string is built even when the record is filtered out. Pass the values beside a constant message instead: \u0060logger.info(\u0022order %s moved to %s\u0022, order_id, status)\u0060 with the standard library\u0027s \u0060logging\u0060, which keeps the message and its arguments apart on the record, or \u0060log.info(\u0022order moved\u0022, order_id=order_id, status=status)\u0060 with structlog."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/agent/loop.py"},"region":{"startLine":605}}}],"partialFingerprints":{"codehealthFindingId/v1":"b033c76b298f001c4194b46ce423c7ec39f90ff7d3fa6765c69340e10f997964"}},{"ruleId":"X4","level":"note","message":{"text":"Interpolated log message defeats structured logging: \u0060info\u0060 at line 615 is handed an f-string as its message, so the logger receives one finished string \u2014 the values in it cannot be queried, filtered or aggregated as fields, every occurrence reads as a different message, and the string is built even when the record is filtered out. Pass the values beside a constant message instead: \u0060logger.info(\u0022order %s moved to %s\u0022, order_id, status)\u0060 with the standard library\u0027s \u0060logging\u0060, which keeps the message and its arguments apart on the record, or \u0060log.info(\u0022order moved\u0022, order_id=order_id, status=status)\u0060 with structlog."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/agent/loop.py"},"region":{"startLine":615}}}],"partialFingerprints":{"codehealthFindingId/v1":"134b9c985db5ac11ba62c5a2bba9fc877faf0f8b94857b9efdb756618157993d"}},{"ruleId":"X4","level":"note","message":{"text":"Interpolated log message defeats structured logging: \u0060exception\u0060 at line 1067 is handed an f-string as its message, so the logger receives one finished string \u2014 the values in it cannot be queried, filtered or aggregated as fields, every occurrence reads as a different message, and the string is built even when the record is filtered out. Pass the values beside a constant message instead: \u0060logger.exception(\u0022order %s moved to %s\u0022, order_id, status)\u0060 with the standard library\u0027s \u0060logging\u0060, which keeps the message and its arguments apart on the record, or \u0060log.exception(\u0022order moved\u0022, order_id=order_id, status=status)\u0060 with structlog."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/agent/loop.py"},"region":{"startLine":1067}}}],"partialFingerprints":{"codehealthFindingId/v1":"692862967e2458eb40b84a0289d47cf715d65b0468823cd20b394cd221cd9235"}},{"ruleId":"X4","level":"note","message":{"text":"Interpolated log message defeats structured logging: \u0060warning\u0060 at line 376 is handed an f-string as its message, so the logger receives one finished string \u2014 the values in it cannot be queried, filtered or aggregated as fields, every occurrence reads as a different message, and the string is built even when the record is filtered out. Pass the values beside a constant message instead: \u0060logger.warning(\u0022order %s moved to %s\u0022, order_id, status)\u0060 with the standard library\u0027s \u0060logging\u0060, which keeps the message and its arguments apart on the record, or \u0060log.warning(\u0022order moved\u0022, order_id=order_id, status=status)\u0060 with structlog."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/agent/tool_lifecycle.py"},"region":{"startLine":376}}}],"partialFingerprints":{"codehealthFindingId/v1":"b7c73fc38dc564e97d71d1275cf8b11ea897af5fb0b792cb79fd73a7708219d1"}},{"ruleId":"X4","level":"note","message":{"text":"Interpolated log message defeats structured logging: \u0060info\u0060 at line 674 is handed an f-string as its message, so the logger receives one finished string \u2014 the values in it cannot be queried, filtered or aggregated as fields, every occurrence reads as a different message, and the string is built even when the record is filtered out. Pass the values beside a constant message instead: \u0060logger.info(\u0022order %s moved to %s\u0022, order_id, status)\u0060 with the standard library\u0027s \u0060logging\u0060, which keeps the message and its arguments apart on the record, or \u0060log.info(\u0022order moved\u0022, order_id=order_id, status=status)\u0060 with structlog."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/agent/tool_lifecycle.py"},"region":{"startLine":674}}}],"partialFingerprints":{"codehealthFindingId/v1":"3d3e5108279a70826a6a064b12416ddfa45bb0acfeb87437b362678d59f5f162"}},{"ruleId":"X5","level":"note","message":{"text":"Null assertions (\u0060!\u0060) override strict null checking: ~1.1 \u0060!\u0060 null assertions per 1k TypeScript source lines \u2014 35 assertion(s) across the 31912 source line(s) of the 134 TypeScript file(s) read, which is the only code the operator asserts anything in (a \u0060!\u0060 in a \u0060.js\u0060 file is not this operator and was not counted, and one in a file whose null checking is off silences nothing). Densest: frontend/src/components/chat/ToolProgressIndicator.tsx (8), frontend/src/lib/indicators.ts (7), frontend/src/components/charts/ValidationPanel.tsx (3). Each one tells the compiler to trust the author about null, suppressing the very diagnostic \u0060strictNullChecks\u0060 exists to produce. Many are correct: each is a claim the checker could not verify, and it is wrong only where the value can in fact be missing, so review the densest places first."},"locations":[],"partialFingerprints":{"codehealthFindingId/v1":"1d83a7c69636a6290f63000d5c19b2073be1fa772f51977532af9ca6f745fc2a"}},{"ruleId":"X6","level":"note","message":{"text":"Hand-rolled JSON/XML parsing via regex: A regex whose pattern encodes JSON/XML syntax is parsing a structured format by hand \u2014 malformed or differently-typed content (e.g. \u0060\u0022amount\u0022: \u00225\u0022\u0060 as a string) silently mis-parses instead of failing validation. This JavaScript/TypeScript code already uses a real parser in the same package; use it here too."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Agent.tsx"},"region":{"startLine":1021}}}],"partialFingerprints":{"codehealthFindingId/v1":"08136c88a7a02fe1615b0281694a27aa8d6345d4babbab748ea4cba3825f39ba"}},{"ruleId":"X6","level":"note","message":{"text":"Hand-rolled JSON/XML parsing via regex: A regex whose pattern encodes JSON/XML syntax is parsing a structured format by hand \u2014 malformed or differently-typed content (e.g. \u0060\u0022amount\u0022: \u00225\u0022\u0060 as a string) silently mis-parses instead of failing validation. This JavaScript/TypeScript code already uses a real parser in the same package; use it here too."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/lib/swarmStatus.ts"},"region":{"startLine":416}}}],"partialFingerprints":{"codehealthFindingId/v1":"c46f00264c72a1a5cac61c69aea26156f76614efad0b5a0e8eff5db05adba94b"}},{"ruleId":"X6","level":"note","message":{"text":"Hand-rolled JSON/XML parsing via regex: A regex whose pattern encodes JSON/XML syntax is parsing a structured format by hand \u2014 malformed or differently-typed content (e.g. \u0060\u0022amount\u0022: \u00225\u0022\u0060 as a string) silently mis-parses instead of failing validation. This JavaScript/TypeScript code already uses a real parser in the same package; use it here too."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/lib/swarmStatus.ts"},"region":{"startLine":418}}}],"partialFingerprints":{"codehealthFindingId/v1":"0dfd86c1d18f408bcb40f493cfdd8551e133e7be7c1f5a6dc370e83dca778ea4"}},{"ruleId":"X6","level":"note","message":{"text":"Hand-rolled JSON/XML parsing via regex: A regex whose pattern encodes JSON/XML syntax is parsing a structured format by hand \u2014 malformed or differently-typed content (e.g. \u0060\u0022amount\u0022: \u00225\u0022\u0060 as a string) silently mis-parses instead of failing validation. This JavaScript/TypeScript code already uses a real parser in the same package; use it here too."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/lib/swarmStatus.ts"},"region":{"startLine":419}}}],"partialFingerprints":{"codehealthFindingId/v1":"278905e6c81e697ea900a044239800694bef5e551cab08239c8aeb3b522d9d80"}},{"ruleId":"X6","level":"note","message":{"text":"Hand-rolled JSON/XML parsing via regex: A regex whose pattern encodes JSON/XML syntax is parsing a structured format by hand \u2014 malformed or differently-typed content (e.g. \u0060\u0022amount\u0022: \u00225\u0022\u0060 as a string) silently mis-parses instead of failing validation. This JavaScript/TypeScript code already uses a real parser in the same package; use it here too."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/lib/swarmStatus.ts"},"region":{"startLine":425}}}],"partialFingerprints":{"codehealthFindingId/v1":"9d9ea4c387a88ad29dee457b6e931d694a6b8a3708fe742ef2a4364eec292ca1"}},{"ruleId":"X6","level":"note","message":{"text":"Hand-rolled JSON/XML parsing via regex: A regex whose pattern encodes JSON/XML syntax is parsing a structured format by hand \u2014 malformed or differently-typed content (e.g. \u0060\u0022amount\u0022: \u00225\u0022\u0060 as a string) silently mis-parses instead of failing validation. This Python code already uses a real parser in the same package; use it here too."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/etf_holdings_tool.py"},"region":{"startLine":826}}}],"partialFingerprints":{"codehealthFindingId/v1":"68573363a7d783284c639f0bcbb4f23493c9db60aabcd7964bf328fcc54f4230"}},{"ruleId":"X6","level":"note","message":{"text":"Hand-rolled JSON/XML parsing via regex: A regex whose pattern encodes JSON/XML syntax is parsing a structured format by hand \u2014 malformed or differently-typed content (e.g. \u0060\u0022amount\u0022: \u00225\u0022\u0060 as a string) silently mis-parses instead of failing validation. This Python code already uses a real parser in the same package; use it here too."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/etf_holdings_tool.py"},"region":{"startLine":837}}}],"partialFingerprints":{"codehealthFindingId/v1":"5c4758114dc9e92244c9bebc802b7cf19447099e24aa4dea9daea39715ff9912"}},{"ruleId":"X6","level":"note","message":{"text":"Hand-rolled JSON/XML parsing via regex: A regex whose pattern encodes JSON/XML syntax is parsing a structured format by hand \u2014 malformed or differently-typed content (e.g. \u0060\u0022amount\u0022: \u00225\u0022\u0060 as a string) silently mis-parses instead of failing validation. This Python code already uses a real parser in the same package; use it here too."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/etf_holdings_tool.py"},"region":{"startLine":839}}}],"partialFingerprints":{"codehealthFindingId/v1":"4e230f90979058f888f9c65cacf823648e93786b14784d976efceddb0340fa75"}},{"ruleId":"X6","level":"note","message":{"text":"Hand-rolled JSON/XML parsing via regex: A regex whose pattern encodes JSON/XML syntax is parsing a structured format by hand \u2014 malformed or differently-typed content (e.g. \u0060\u0022amount\u0022: \u00225\u0022\u0060 as a string) silently mis-parses instead of failing validation. This Python code already uses a real parser in the same package; use it here too."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/api/sessions_routes.py"},"region":{"startLine":255}}}],"partialFingerprints":{"codehealthFindingId/v1":"c65159a41943c1f28198b246d2124c5c44764a06c230effdd3ec9f25d23029eb"}},{"ruleId":"X6","level":"note","message":{"text":"Hand-rolled JSON/XML parsing via regex: A regex whose pattern encodes JSON/XML syntax is parsing a structured format by hand \u2014 malformed or differently-typed content (e.g. \u0060\u0022amount\u0022: \u00225\u0022\u0060 as a string) silently mis-parses instead of failing validation. This Python code already uses a real parser in the same package; use it here too."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/api/sessions_routes.py"},"region":{"startLine":258}}}],"partialFingerprints":{"codehealthFindingId/v1":"47af27559c17d77e2d274c8ced1e8f71dd52be236717767a12b09eed1306514f"}},{"ruleId":"X6","level":"note","message":{"text":"Hand-rolled JSON/XML parsing via regex: A regex whose pattern encodes JSON/XML syntax is parsing a structured format by hand \u2014 malformed or differently-typed content (e.g. \u0060\u0022amount\u0022: \u00225\u0022\u0060 as a string) silently mis-parses instead of failing validation. This Python code already uses a real parser in the same package; use it here too."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/api/sessions_routes.py"},"region":{"startLine":329}}}],"partialFingerprints":{"codehealthFindingId/v1":"81c9fa6a4c05dfed820649860de87f148b858fd58142fcb6120b490716392fd1"}},{"ruleId":"X6","level":"note","message":{"text":"Hand-rolled JSON/XML parsing via regex: A regex whose pattern encodes JSON/XML syntax is parsing a structured format by hand \u2014 malformed or differently-typed content (e.g. \u0060\u0022amount\u0022: \u00225\u0022\u0060 as a string) silently mis-parses instead of failing validation. This Python code already uses a real parser in the same package; use it here too."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":918}}}],"partialFingerprints":{"codehealthFindingId/v1":"59e5e037f5a5b868a7051569561cf21a7f6ee19b398ac280f229f6f2c0ad33e7"}},{"ruleId":"X6","level":"note","message":{"text":"Hand-rolled JSON/XML parsing via regex: A regex whose pattern encodes JSON/XML syntax is parsing a structured format by hand \u2014 malformed or differently-typed content (e.g. \u0060\u0022amount\u0022: \u00225\u0022\u0060 as a string) silently mis-parses instead of failing validation. This Python code already uses a real parser in the same package; use it here too."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":919}}}],"partialFingerprints":{"codehealthFindingId/v1":"eed6cfaddcf244200239a1c3282208cf57f0dfcc4d5907a8214b051373a08635"}},{"ruleId":"X6","level":"note","message":{"text":"Hand-rolled JSON/XML parsing via regex: A regex whose pattern encodes JSON/XML syntax is parsing a structured format by hand \u2014 malformed or differently-typed content (e.g. \u0060\u0022amount\u0022: \u00225\u0022\u0060 as a string) silently mis-parses instead of failing validation. This Python code already uses a real parser in the same package; use it here too."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":927}}}],"partialFingerprints":{"codehealthFindingId/v1":"2d32bf7657ce506d12efba776d4493cec005f53a36b6e576fe4e7fbea55c6dd6"}},{"ruleId":"X6","level":"note","message":{"text":"Hand-rolled JSON/XML parsing via regex: A regex whose pattern encodes JSON/XML syntax is parsing a structured format by hand \u2014 malformed or differently-typed content (e.g. \u0060\u0022amount\u0022: \u00225\u0022\u0060 as a string) silently mis-parses instead of failing validation. This Python code already uses a real parser in the same package; use it here too."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":932}}}],"partialFingerprints":{"codehealthFindingId/v1":"0fdf899d6ea4ff87c105f4af9d678a43b53110e867e13860690fb90a70f417fa"}},{"ruleId":"X6","level":"note","message":{"text":"Hand-rolled JSON/XML parsing via regex: A regex whose pattern encodes JSON/XML syntax is parsing a structured format by hand \u2014 malformed or differently-typed content (e.g. \u0060\u0022amount\u0022: \u00225\u0022\u0060 as a string) silently mis-parses instead of failing validation. This Python code already uses a real parser in the same package; use it here too."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":960}}}],"partialFingerprints":{"codehealthFindingId/v1":"8c285999cce10aedb8f31e10ef7509276b41bfba4a7ada9a908718c9db761154"}},{"ruleId":"X6","level":"note","message":{"text":"Hand-rolled JSON/XML parsing via regex: A regex whose pattern encodes JSON/XML syntax is parsing a structured format by hand \u2014 malformed or differently-typed content (e.g. \u0060\u0022amount\u0022: \u00225\u0022\u0060 as a string) silently mis-parses instead of failing validation. This Python code already uses a real parser in the same package; use it here too."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":963}}}],"partialFingerprints":{"codehealthFindingId/v1":"b15b33827d4ec11e1a06f271e1b2443a5d2896007a6511f10796b66503e143a1"}},{"ruleId":"X7","level":"note","message":{"text":"Pending state with no failure state: The view draws \u0060\u003CLoader2 class=\u0022h-3.5 w-3.5 animate-spin\u0022/\u003E\u0060 under \u0060pineLoading\u0060, but \u0060pineLoading\u0060 is settled by a load that can fail and the component draws no failure state, so a failed load is shown as \u0022not yet\u0022 for ever, or as the loaded state over its initial value. Give the component a failure state and draw it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/components/chat/RunCompleteCard.tsx"},"region":{"startLine":118}}}],"partialFingerprints":{"codehealthFindingId/v1":"35b2658a6c2c3f3b2b6a475ad3dc88c8aefffb416f4b5ef2f1b0da46ed981703"}},{"ruleId":"X7","level":"note","message":{"text":"Silent fallback default in catch: \u0060_load_cache\u0060 swallows every exception into \u0060return {}\u0060 \u2014 a data error becomes a silent behavior change with no trail. Log the failure or let it raise. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/gildata_codes.py"},"region":{"startLine":69}}}],"partialFingerprints":{"codehealthFindingId/v1":"e3cb2f106d512271f363d1f6dfd5a41f7bb4a50d708dc49d3d141a599a97dc22"}},{"ruleId":"X7","level":"note","message":{"text":"Silent fallback default on parse failure: \u0060_read_mt5_config\u0060 returns \u0060{}\u0060 when \u0060(OSError, ValueError)\u0060 is raised, with no log or raise \u2014 a malformed value silently becomes that default. Log the input or fail validation. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/mt5_loader.py"},"region":{"startLine":73}}}],"partialFingerprints":{"codehealthFindingId/v1":"2b586113d4b9b49358ab14bb5c24686069e2abc284ef53eca6a9462cd155fce2"}},{"ruleId":"X7","level":"note","message":{"text":"Silent fallback default on parse failure: \u0060_parse_items\u0060 returns \u0060[]\u0060 when \u0060(ParseError, DefusedXmlException)\u0060 is raised, with no log or raise \u2014 a malformed value silently becomes that default. Log the input or fail validation. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/backtest/loaders/rsshub_events.py"},"region":{"startLine":490}}}],"partialFingerprints":{"codehealthFindingId/v1":"8d552af8025a6f025fcdabbe42ce0401fe4c310f1d51efc21dfa4e36d0395702"}},{"ruleId":"X7","level":"note","message":{"text":"Silent fallback default on parse failure: \u0060_read_json\u0060 returns \u0060{}\u0060 when \u0060(json.JSONDecodeError, OSError)\u0060 is raised, with no log or raise \u2014 a malformed value silently becomes that default. Log the input or fail validation. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":330}}}],"partialFingerprints":{"codehealthFindingId/v1":"10edd21522e02eff7aa5e44c0018fd89f8d5c6b8fe7a7f8478e10b5d06de9ecd"}},{"ruleId":"X7","level":"note","message":{"text":"Silent fallback default in catch: \u0060_read_metrics\u0060 swallows every exception into \u0060return {}\u0060 \u2014 a data error becomes a silent behavior change with no trail. Log the failure or let it raise. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":353}}}],"partialFingerprints":{"codehealthFindingId/v1":"eaca6a9f18fa2401752364a97b63f408b71332bf1671cddc1846f2fdd2feba29"}},{"ruleId":"X7","level":"note","message":{"text":"Silent fallback default in catch: \u0060_terminal_width\u0060 swallows every exception into \u0060return 80\u0060 \u2014 a data error becomes a silent behavior change with no trail. Log the failure or let it raise. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":420}}}],"partialFingerprints":{"codehealthFindingId/v1":"5ffdaf7e6ef521511bc5bfa54a2ba74949ea7d9289540ceb47a25e5de0519df1"}},{"ruleId":"X7","level":"note","message":{"text":"Silent fallback default on parse failure: \u0060_metric_value_style\u0060 returns \u0060\u0027white\u0027\u0060 when \u0060(TypeError, ValueError)\u0060 is raised, with no log or raise \u2014 a malformed value silently becomes that default. Log the input or fail validation. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/_legacy.py"},"region":{"startLine":549}}}],"partialFingerprints":{"codehealthFindingId/v1":"8014c0e51ac6824c91525c81b957f78fc89b1f321bdd1043365d397b06a3e7ab"}},{"ruleId":"X7","level":"note","message":{"text":"Silent fallback default in catch: \u0060_probe_session_count\u0060 swallows every exception into \u0060return 0\u0060 \u2014 a data error becomes a silent behavior change with no trail. Log the failure or let it raise. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/main.py"},"region":{"startLine":187}}}],"partialFingerprints":{"codehealthFindingId/v1":"6aa9b6044fec0f1ba67b09fe9d0b29e2c354d0c419e1bd95cfb160d3782d3bb9"}},{"ruleId":"X7","level":"note","message":{"text":"Silent fallback default in catch: \u0060_build_session_history\u0060 swallows every exception into \u0060return []\u0060 \u2014 a data error becomes a silent behavior change with no trail. Log the failure or let it raise. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/main.py"},"region":{"startLine":395}}}],"partialFingerprints":{"codehealthFindingId/v1":"cd0c8b5832ab50ec9769ce9abb7aa4218e50f50b2d3c7d10249769e1fdde6fcd"}},{"ruleId":"X7","level":"note","message":{"text":"Silent fallback default in catch: \u0060_summarise_tool_result\u0060 swallows every exception into \u0060return \u0027\u0027\u0060 \u2014 a data error becomes a silent behavior change with no trail. Log the failure or let it raise. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/main.py"},"region":{"startLine":664}}}],"partialFingerprints":{"codehealthFindingId/v1":"324368acd60ec479477ebc75e9bf56d273de0e69e8c5a2ed47c08f9c75b23894"}},{"ruleId":"X7","level":"note","message":{"text":"Silent fallback default in catch: \u0060_interactive_loop\u0060 swallows every exception into \u0060return 1\u0060 \u2014 a data error becomes a silent behavior change with no trail. Log the failure or let it raise. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/main.py"},"region":{"startLine":1362}}}],"partialFingerprints":{"codehealthFindingId/v1":"ab81688325d84c5e4e38500d65121f493ab81a467d6ed37ec31429b0fa539e7d"}},{"ruleId":"X7","level":"note","message":{"text":"Silent fallback default on parse failure: \u0060_coerce_int\u0060 returns \u00600\u0060 when \u0060(TypeError, ValueError)\u0060 is raised, with no log or raise \u2014 a malformed value silently becomes that default. Log the input or fail validation. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/ui/rail.py"},"region":{"startLine":65}}}],"partialFingerprints":{"codehealthFindingId/v1":"5f8f00b2df137e67abafabbc348baa0949c049fde789fb25f2df5e207129f790"}},{"ruleId":"X7","level":"note","message":{"text":"Silent fallback default on parse failure: \u0060format_tokens\u0060 returns \u0060\u00270 tokens\u0027\u0060 when \u0060(TypeError, ValueError)\u0060 is raised, with no log or raise \u2014 a malformed value silently becomes that default. Log the input or fail validation. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/utils/format.py"},"region":{"startLine":91}}}],"partialFingerprints":{"codehealthFindingId/v1":"7779d9fe9f8198e9806c4b951a668a8c92ff65fd25f5abca36d5523bda6caa1b"}},{"ruleId":"X7","level":"note","message":{"text":"Silent fallback default on parse failure: \u0060abbreviate_num\u0060 returns \u0060\u0027\u2014\u0027\u0060 when \u0060(TypeError, ValueError)\u0060 is raised, with no log or raise \u2014 a malformed value silently becomes that default. Log the input or fail validation. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/cli/utils/format.py"},"region":{"startLine":136}}}],"partialFingerprints":{"codehealthFindingId/v1":"bc6b31f172465d7ea3a073ad7adbcf9ccf2b7193e50f88553f80d292067cec8e"}},{"ruleId":"X7","level":"note","message":{"text":"Silent fallback default on parse failure: \u0060_record_metrics_file\u0060 returns \u00600\u0060 when \u0060(OSError, UnicodeDecodeError)\u0060 is raised, with no log or raise \u2014 a malformed value silently becomes that default. Log the input or fail validation. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/grounding/evidence.py"},"region":{"startLine":1310}}}],"partialFingerprints":{"codehealthFindingId/v1":"227c6d0511d3f64cac793ade4b778972239487c79d8600da34bc53d376b7aa49"}},{"ruleId":"X7","level":"note","message":{"text":"Silent fallback default on parse failure: \u0060_run_card_manifest\u0060 returns \u0060{}\u0060 when \u0060(OSError, UnicodeDecodeError, json.JSONDecodeError)\u0060 is raised, with no log or raise \u2014 a malformed value silently becomes that default. Log the input or fail validation. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/grounding/evidence.py"},"region":{"startLine":297}}}],"partialFingerprints":{"codehealthFindingId/v1":"c17985c25ea620388f4084db332ae2fa5fc9f969222028bdf3d59994201337ca"}},{"ruleId":"X7","level":"note","message":{"text":"Silent fallback default on parse failure: \u0060_summary_scalars\u0060 returns \u0060[]\u0060 when \u0060(OSError, UnicodeDecodeError)\u0060 is raised, with no log or raise \u2014 a malformed value silently becomes that default. Log the input or fail validation. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/evals/grounding/evidence.py"},"region":{"startLine":318}}}],"partialFingerprints":{"codehealthFindingId/v1":"503e657f6b4d8a485976d0b025b4485f7886fd4afd6cf6e0ac8abc61abb2e00f"}},{"ruleId":"X7","level":"note","message":{"text":"Silent fallback default in catch: \u0060_count_data_sources\u0060 swallows every exception into \u0060return 18\u0060 \u2014 a data error becomes a silent behavior change with no trail. Log the failure or let it raise. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/agent/context.py"},"region":{"startLine":349}}}],"partialFingerprints":{"codehealthFindingId/v1":"982a2a700873e48c72bee2c57d794dd661dc22a926add6867c5fd7b6dfaaa57c"}},{"ruleId":"X7","level":"note","message":{"text":"Silent fallback default on parse failure: \u0060_coerce_usage_int\u0060 returns \u00600\u0060 when \u0060(TypeError, ValueError)\u0060 is raised, with no log or raise \u2014 a malformed value silently becomes that default. Log the input or fail validation. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/agent/llm_usage.py"},"region":{"startLine":31}}}],"partialFingerprints":{"codehealthFindingId/v1":"5324e755e88171e91a7ac335e832aa04e40c586ac2acad69a74c752b8e032740"}},{"ruleId":"X7","level":"note","message":{"text":"Silent fallback default on parse failure: \u0060_source_rank\u0060 returns \u0060-1\u0060 when \u0060ValueError\u0060 is raised, with no log or raise \u2014 a malformed value silently becomes that default. Log the input or fail validation. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/agent/resolution_context.py"},"region":{"startLine":186}}}],"partialFingerprints":{"codehealthFindingId/v1":"21b320d1bf28a91f9482c55f51c3c39390a4fc59c253d4160eaa16e11b56f8c8"}},{"ruleId":"X7","level":"note","message":{"text":"Silent fallback default on parse failure: \u0060_failure_code\u0060 returns \u0060\u0027\u0027\u0060 when \u0060(TypeError, ValueError)\u0060 is raised, with no log or raise \u2014 a malformed value silently becomes that default. Log the input or fail validation. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/agent/tool_results.py"},"region":{"startLine":35}}}],"partialFingerprints":{"codehealthFindingId/v1":"66f35d79379fca1ef1de8a45698e7917ca61bb2782e8bf9d5bd8c74f3bf1b766"}},{"ruleId":"X7","level":"note","message":{"text":"Silent fallback default on parse failure: \u0060_previously_archived\u0060 returns \u0060set()\u0060 when \u0060(OSError, json.JSONDecodeError)\u0060 is raised, with no log or raise \u2014 a malformed value silently becomes that default. Log the input or fail validation. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/agent/tool_results.py"},"region":{"startLine":170}}}],"partialFingerprints":{"codehealthFindingId/v1":"5ec9bf9a7e0a72f4cfca99e8e38c75a9275ebd547db94e224fd0d2068d113753"}},{"ruleId":"X7","level":"note","message":{"text":"Silent fallback default on parse failure: \u0060_pearson_correlation\u0060 returns \u00600.0\u0060 when \u0060(statistics.StatisticsError, ValueError, OverflowError, ZeroDivisionError)\u0060 is raised, with no log or raise \u2014 a malformed value silently becomes that default. Log the input or fail validation. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/api/runs_routes.py"},"region":{"startLine":410}}}],"partialFingerprints":{"codehealthFindingId/v1":"579a6a8f93d6bd77fb4e94e20232e490a05a41a90c4210a27f0dd3122241e529"}},{"ruleId":"X7","level":"note","message":{"text":"Silent fallback default in catch: \u0060_as_int\u0060 (in \u0060_build_client_version\u0060) swallows every exception into \u0060return 0\u0060 \u2014 a data error becomes a silent behavior change with no trail. Log the failure or let it raise. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/channels/weixin.py"},"region":{"startLine":68}}}],"partialFingerprints":{"codehealthFindingId/v1":"2e979e6921c884b957fc2954a678f355192599809ade85dd19f91b781d81758e"}},{"ruleId":"X7","level":"note","message":{"text":"Silent fallback default on parse failure: \u0060_url_host\u0060 returns \u0060\u0027\u0027\u0060 when \u0060ValueError\u0060 is raised, with no log or raise \u2014 a malformed value silently becomes that default. Log the input or fail validation. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/config/schema.py"},"region":{"startLine":68}}}],"partialFingerprints":{"codehealthFindingId/v1":"48428602345e0269bd522593e5aff6046f4a000367f4f73456c9a7bac4657724"}},{"ruleId":"X7","level":"note","message":{"text":"Silent fallback default in catch: \u0060_available\u0060 swallows every exception into \u0060return False\u0060 \u2014 a data error becomes a silent behavior change with no trail. Log the failure or let it raise. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/data_gateway/historical.py"},"region":{"startLine":15}}}],"partialFingerprints":{"codehealthFindingId/v1":"72afc7205a140eca573d29feb28ac2555dde1fd55a0e226d3cc62e08b72dbaba"}},{"ruleId":"X7","level":"note","message":{"text":"Silent fallback default on parse failure: \u0060_usable\u0060 returns \u0060False\u0060 when \u0060(TypeError, ValueError)\u0060 is raised, with no log or raise \u2014 a malformed value silently becomes that default. Log the input or fail validation. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/data_gateway/reads.py"},"region":{"startLine":28}}}],"partialFingerprints":{"codehealthFindingId/v1":"ee80d7b87647ad25bd7363a44c5d324e3dff41e66618be7f481d9b5c1922b208"}},{"ruleId":"X7","level":"note","message":{"text":"Silent fallback default on parse failure: \u0060_sort_value\u0060 returns \u00600.0\u0060 when \u0060(TypeError, ValueError)\u0060 is raised, with no log or raise \u2014 a malformed value silently becomes that default. Log the input or fail validation. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/compare_runner.py"},"region":{"startLine":40}}}],"partialFingerprints":{"codehealthFindingId/v1":"b76f76f2fdd028ac02d0a02a97bc2a8f5433114378eaa8f542a9e16b3e80d37d"}},{"ruleId":"X7","level":"note","message":{"text":"Silent fallback default in catch: \u0060_zoo_of\u0060 swallows every exception into \u0060return \u0027\u0027\u0060 \u2014 a data error becomes a silent behavior change with no trail. Log the failure or let it raise. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/factors/compare_runner.py"},"region":{"startLine":53}}}],"partialFingerprints":{"codehealthFindingId/v1":"9154c2f6ddab8ccfc2ee86837ecf796f3b84821dcd6cfb69169659c190a22942"}},{"ruleId":"X7","level":"note","message":{"text":"Silent fallback default on parse failure: \u0060read_daily_count\u0060 returns \u00600\u0060 when \u0060(OSError, ValueError)\u0060 is raised, with no log or raise \u2014 a malformed value silently becomes that default. Log the input or fail validation. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/live/daily_count.py"},"region":{"startLine":115}}}],"partialFingerprints":{"codehealthFindingId/v1":"083ff9a7452e09d274cabd8eb2732803c643dfed1a62408662b1fe75d82703f3"}},{"ruleId":"X7","level":"note","message":{"text":"Silent fallback default on parse failure: \u0060_position_qty\u0060 returns \u00600.0\u0060 when \u0060(TypeError, ValueError)\u0060 is raised, with no log or raise \u2014 a malformed value silently becomes that default. Log the input or fail validation. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/live/runtime/reconcile.py"},"region":{"startLine":270}}}],"partialFingerprints":{"codehealthFindingId/v1":"ce598894813e6c97fbd1f5a64227ce8085da4aa72334f55f39b08ab15d78e68e"}},{"ruleId":"X7","level":"note","message":{"text":"Silent fallback default in catch: \u0060main\u0060 swallows every exception into \u0060return 1\u0060 \u2014 a data error becomes a silent behavior change with no trail. Log the failure or let it raise. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/portfolio/oauth_worker.py"},"region":{"startLine":21}}}],"partialFingerprints":{"codehealthFindingId/v1":"3fe9effebc1c9aa5e1bfe49f81ae8aeda9ad33e7337e8136e30d851f0353e445"}},{"ruleId":"X7","level":"note","message":{"text":"Silent fallback default on parse failure: \u0060_redact_base_url_for_log\u0060 returns \u0060\u0027\u003Cbase-url\u003E\u0027\u0060 when \u0060ValueError\u0060 is raised, with no log or raise \u2014 a malformed value silently becomes that default. Log the input or fail validation. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/providers/llm.py"},"region":{"startLine":1628}}}],"partialFingerprints":{"codehealthFindingId/v1":"cdd5b65860c332cdf52af101976d1eb538ce9ec337d9ea7ede4ca64dfaf52382"}},{"ruleId":"X7","level":"note","message":{"text":"Silent fallback default on parse failure: \u0060_decode_jwt_claims\u0060 returns \u0060{}\u0060 when \u0060(IndexError, UnicodeError, ValueError, json.JSONDecodeError)\u0060 is raised, with no log or raise \u2014 a malformed value silently becomes that default. Log the input or fail validation. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/providers/openai_codex.py"},"region":{"startLine":178}}}],"partialFingerprints":{"codehealthFindingId/v1":"28990ed410d51034fa2e00a84cbb584a21c224c4f3d26f50e64b919d6614fee1"}},{"ruleId":"X7","level":"note","message":{"text":"Silent fallback default on parse failure: \u0060_token_expiry_ms\u0060 returns \u00600\u0060 when \u0060(TypeError, ValueError)\u0060 is raised, with no log or raise \u2014 a malformed value silently becomes that default. Log the input or fail validation. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/providers/openai_codex.py"},"region":{"startLine":192}}}],"partialFingerprints":{"codehealthFindingId/v1":"e004137bf2ab4fb97a068073c05926193f3add5a06a9fc4370d7e2d7e4959bb7"}},{"ruleId":"X7","level":"note","message":{"text":"Silent fallback default on parse failure: \u0060_format_time\u0060 returns \u0060\u0027unknown\u0027\u0060 when \u0060(OSError, ValueError)\u0060 is raised, with no log or raise \u2014 a malformed value silently becomes that default. Log the input or fail validation. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/session/search.py"},"region":{"startLine":470}}}],"partialFingerprints":{"codehealthFindingId/v1":"3315bec18bf0e9ec90704be5de590766c9578747be2321f73ff0cb907956f5d9"}},{"ruleId":"X7","level":"note","message":{"text":"Silent fallback default in catch: \u0060routing_block\u0060 swallows every exception into \u0060return \u0027\u0027\u0060 \u2014 a data error becomes a silent behavior change with no trail. Log the failure or let it raise. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/strategy_discovery/guard.py"},"region":{"startLine":70}}}],"partialFingerprints":{"codehealthFindingId/v1":"90040da88e519a08e40fc427b7088b500749799f2ed96b95a08d480d0f0b99c4"}},{"ruleId":"X7","level":"note","message":{"text":"Silent fallback default on parse failure: \u0060_read_json\u0060 returns \u0060{}\u0060 when \u0060(OSError, ValueError)\u0060 is raised, with no log or raise \u2014 a malformed value silently becomes that default. Log the input or fail validation. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/backtest_runs_tool.py"},"region":{"startLine":51}}}],"partialFingerprints":{"codehealthFindingId/v1":"9afd4a64054c065cf16f9527606fdb2b7f84a352264374a24aa8b6fe72d9091f"}},{"ruleId":"X7","level":"note","message":{"text":"Silent fallback default in catch: \u0060_http_error_body\u0060 swallows every exception into \u0060return \u0027\u0027\u0060 \u2014 a data error becomes a silent behavior change with no trail. Log the failure or let it raise. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/mcp.py"},"region":{"startLine":1430}}}],"partialFingerprints":{"codehealthFindingId/v1":"a9e40e072cf10a005bf3d7c4e29f575ade13d9b8166f74bf914707407d043e4b"}},{"ruleId":"X7","level":"note","message":{"text":"Silent fallback default on parse failure: \u0060_declared_universe\u0060 returns \u0060()\u0060 when \u0060(ValueError, TypeError, SyntaxError, MemoryError, RecursionError)\u0060 is raised, with no log or raise \u2014 a malformed value silently becomes that default. Log the input or fail validation. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/paper_trade/strategy_exec.py"},"region":{"startLine":260}}}],"partialFingerprints":{"codehealthFindingId/v1":"ddaaa6b0aca2707a321e8246624e363b9a32cfd30b3d5906b0ce910f97ab4146"}},{"ruleId":"X7","level":"note","message":{"text":"Silent fallback default on parse failure: \u0060_load_artifact_manifest\u0060 returns \u0060{}\u0060 when \u0060(OSError, ValueError, UnicodeDecodeError)\u0060 is raised, with no log or raise \u2014 a malformed value silently becomes that default. Log the input or fail validation. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/tools/run_artifact_tool.py"},"region":{"startLine":139}}}],"partialFingerprints":{"codehealthFindingId/v1":"9b3d997499a23eda8c94af85066ddce3fc01bfc3daac249c15cc2206f21c642d"}},{"ruleId":"X7","level":"note","message":{"text":"Silent fallback default on parse failure: \u0060_acc_id_of\u0060 returns \u00600\u0060 when \u0060(TypeError, ValueError)\u0060 is raised, with no log or raise \u2014 a malformed value silently becomes that default. Log the input or fail validation. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/futu/sdk.py"},"region":{"startLine":1207}}}],"partialFingerprints":{"codehealthFindingId/v1":"0b42ec289a995c92ab31c2cce1e71b56f2a2d4b8dfb55508b7c0cf49c390f7e2"}},{"ruleId":"X7","level":"note","message":{"text":"Silent fallback default on parse failure: \u0060_as_float\u0060 returns \u00600.0\u0060 when \u0060(TypeError, ValueError)\u0060 is raised, with no log or raise \u2014 a malformed value silently becomes that default. Log the input or fail validation. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/kis/sdk.py"},"region":{"startLine":933}}}],"partialFingerprints":{"codehealthFindingId/v1":"a14d0a7cf086041b9c0d87ba9de256cf72643f822f30691d080f045c4f96e4bb"}},{"ruleId":"X7","level":"note","message":{"text":"Silent fallback default in catch: \u0060_last_error\u0060 swallows every exception into \u0060return \u0027unknown\u0027\u0060 \u2014 a data error becomes a silent behavior change with no trail. Log the failure or let it raise. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/mt5/_client.py"},"region":{"startLine":235}}}],"partialFingerprints":{"codehealthFindingId/v1":"d6250d9592d56f7e8f6d499b61086c0da849478a1c36f09e902b170d16d708f0"}},{"ruleId":"X7","level":"note","message":{"text":"Silent fallback default on parse failure: \u0060_as_float\u0060 returns \u00600.0\u0060 when \u0060(TypeError, ValueError)\u0060 is raised, with no log or raise \u2014 a malformed value silently becomes that default. Log the input or fail validation. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"agent/src/trading/connectors/upbit/sdk.py"},"region":{"startLine":662}}}],"partialFingerprints":{"codehealthFindingId/v1":"ca11bb16839d3c886aeb70b7f2f61e8857a07183cc309d1f678a2ea2cf7cff81"}},{"ruleId":"X7","level":"note","message":{"text":"Silent fallback default in catch: \u0060browserTimezone\u0060 swallows every exception into \u0060return \u0022UTC\u0022\u0060 \u2014 a data error becomes a silent behavior change with no trail. Log the failure or let it raise. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"frontend/src/pages/Scheduled.tsx"},"region":{"startLine":34}}}],"partialFingerprints":{"codehealthFindingId/v1":"f66638000e09d942d3b90e3cd943e10b4d8b9b243d749da56e21521b8cfc8c3d"}}],"taxonomies":[{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d","organization":"MITRE","informationUri":"https://cwe.mitre.org/","isComprehensive":false,"shortDescription":{"text":"The MITRE Common Weakness Enumeration (CWE)."},"taxa":[{"id":"CWE-1032","guid":"5f21e517-68aa-a650-9a25-5771ef024637","name":"OWASP Top Ten \u2014 Security Misconfiguration category","shortDescription":{"text":"OWASP Top Ten \u2014 Security Misconfiguration category"},"helpUri":"https://cwe.mitre.org/data/definitions/1032.html"},{"id":"CWE-1059","guid":"a2381a08-60f6-9554-a8b8-f3018cfaaca5","name":"Insufficient Technical Documentation","shortDescription":{"text":"Insufficient Technical Documentation"},"helpUri":"https://cwe.mitre.org/data/definitions/1059.html"},{"id":"CWE-1357","guid":"e4d2e772-757e-0a5c-bd7d-77052949d866","name":"Reliance on Insufficiently Trustworthy Component","shortDescription":{"text":"Reliance on Insufficiently Trustworthy Component"},"helpUri":"https://cwe.mitre.org/data/definitions/1357.html"},{"id":"CWE-1395","guid":"800e09e7-c11a-8654-9fa6-86f398995fed","name":"Dependency on Vulnerable Third-Party Component","shortDescription":{"text":"Dependency on Vulnerable Third-Party Component"},"helpUri":"https://cwe.mitre.org/data/definitions/1395.html"},{"id":"CWE-16","guid":"659db3ea-affc-8453-8add-c1218fbfcb92","name":"Configuration","shortDescription":{"text":"Configuration"},"helpUri":"https://cwe.mitre.org/data/definitions/16.html"},{"id":"CWE-200","guid":"b0ce3b1d-7a29-fe50-8aab-9aba899d2988","name":"Exposure of Sensitive Information to an Unauthorized Actor","shortDescription":{"text":"Exposure of Sensitive Information to an Unauthorized Actor"},"helpUri":"https://cwe.mitre.org/data/definitions/200.html"},{"id":"CWE-259","guid":"ae9ad959-fbb6-9d5e-892d-3dca66da0b69","name":"Use of Hard-coded Password","shortDescription":{"text":"Use of Hard-coded Password"},"helpUri":"https://cwe.mitre.org/data/definitions/259.html"},{"id":"CWE-276","guid":"4e27da05-61af-1d5c-aeb5-9f56b6ede3e3","name":"Incorrect Default Permissions","shortDescription":{"text":"Incorrect Default Permissions"},"helpUri":"https://cwe.mitre.org/data/definitions/276.html"},{"id":"CWE-312","guid":"96724ece-b0b2-a45c-83f9-0869fa3f6bea","name":"Cleartext Storage of Sensitive Information","shortDescription":{"text":"Cleartext Storage of Sensitive Information"},"helpUri":"https://cwe.mitre.org/data/definitions/312.html"},{"id":"CWE-319","guid":"7af97476-9f0d-4458-9163-3d2043918a1a","name":"Cleartext Transmission of Sensitive Information","shortDescription":{"text":"Cleartext Transmission of Sensitive Information"},"helpUri":"https://cwe.mitre.org/data/definitions/319.html"},{"id":"CWE-327","guid":"e51910ff-67b5-3c51-aa3d-92837d9eab90","name":"Use of a Broken or Risky Cryptographic Algorithm","shortDescription":{"text":"Use of a Broken or Risky Cryptographic Algorithm"},"helpUri":"https://cwe.mitre.org/data/definitions/327.html"},{"id":"CWE-359","guid":"b7dfe5b0-0351-645b-a311-b936102c2929","name":"Exposure of Private Personal Information to an Unauthorized Actor","shortDescription":{"text":"Exposure of Private Personal Information to an Unauthorized Actor"},"helpUri":"https://cwe.mitre.org/data/definitions/359.html"},{"id":"CWE-494","guid":"b8a65e0d-e459-4a55-a931-fc1136482375","name":"Download of Code Without Integrity Check","shortDescription":{"text":"Download of Code Without Integrity Check"},"helpUri":"https://cwe.mitre.org/data/definitions/494.html"},{"id":"CWE-506","guid":"401d6455-56e3-0552-9a39-f77461673e3f","name":"Embedded Malicious Code","shortDescription":{"text":"Embedded Malicious Code"},"helpUri":"https://cwe.mitre.org/data/definitions/506.html"},{"id":"CWE-532","guid":"1cd8877a-76e8-ce54-b40b-779af23364a0","name":"Insertion of Sensitive Information into Log File","shortDescription":{"text":"Insertion of Sensitive Information into Log File"},"helpUri":"https://cwe.mitre.org/data/definitions/532.html"},{"id":"CWE-611","guid":"1afbae66-ea29-2d59-aaa2-134e3ae2e85a","name":"Improper Restriction of XML External Entity Reference","shortDescription":{"text":"Improper Restriction of XML External Entity Reference"},"helpUri":"https://cwe.mitre.org/data/definitions/611.html"},{"id":"CWE-732","guid":"1da27e8f-b330-7650-ab63-bd61953eae5d","name":"Incorrect Permission Assignment for Critical Resource","shortDescription":{"text":"Incorrect Permission Assignment for Critical Resource"},"helpUri":"https://cwe.mitre.org/data/definitions/732.html"},{"id":"CWE-77","guid":"332c8ade-6612-9f56-a06b-d8d90b1a8750","name":"Improper Neutralization of Special Elements used in a Command (\u0027Command Injection\u0027)","shortDescription":{"text":"Improper Neutralization of Special Elements used in a Command (\u0027Command Injection\u0027)"},"helpUri":"https://cwe.mitre.org/data/definitions/77.html"},{"id":"CWE-78","guid":"2e31ceaf-c7ae-2e5e-9661-cfb1362789cf","name":"Improper Neutralization of Special Elements used in an OS Command (\u0027OS Command Injection\u0027)","shortDescription":{"text":"Improper Neutralization of Special Elements used in an OS Command (\u0027OS Command Injection\u0027)"},"helpUri":"https://cwe.mitre.org/data/definitions/78.html"},{"id":"CWE-79","guid":"fd45580b-e8c4-fc5e-8c2f-aa8fab0b4dbf","name":"Improper Neutralization of Input During Web Page Generation (\u0027Cross-site Scripting\u0027)","shortDescription":{"text":"Improper Neutralization of Input During Web Page Generation (\u0027Cross-site Scripting\u0027)"},"helpUri":"https://cwe.mitre.org/data/definitions/79.html"},{"id":"CWE-798","guid":"5e8f057d-fee3-995a-a0cb-9fc5b0d174d1","name":"Use of Hard-coded Credentials","shortDescription":{"text":"Use of Hard-coded Credentials"},"helpUri":"https://cwe.mitre.org/data/definitions/798.html"},{"id":"CWE-829","guid":"13c33925-97fb-5a5e-b40c-56d328b8a4d7","name":"Inclusion of Functionality from Untrusted Control Sphere","shortDescription":{"text":"Inclusion of Functionality from Untrusted Control Sphere"},"helpUri":"https://cwe.mitre.org/data/definitions/829.html"},{"id":"CWE-89","guid":"6d08fdad-37eb-c150-bbf0-d7d946863407","name":"Improper Neutralization of Special Elements used in an SQL Command (\u0027SQL Injection\u0027)","shortDescription":{"text":"Improper Neutralization of Special Elements used in an SQL Command (\u0027SQL Injection\u0027)"},"helpUri":"https://cwe.mitre.org/data/definitions/89.html"},{"id":"CWE-937","guid":"16f316ae-415c-b354-a59b-1f7905f756e9","name":"Using Components with Known Vulnerabilities","shortDescription":{"text":"Using Components with Known Vulnerabilities"},"helpUri":"https://cwe.mitre.org/data/definitions/937.html"},{"id":"CWE-939","guid":"12397742-f2c4-8254-8012-482c3356c551","name":"CWE-939","shortDescription":{"text":"CWE-939"},"helpUri":"https://cwe.mitre.org/data/definitions/939.html"},{"id":"CWE-94","guid":"75e7f50c-6c2f-dd52-bf40-bf6c52b861fd","name":"Improper Control of Generation of Code (\u0027Code Injection\u0027)","shortDescription":{"text":"Improper Control of Generation of Code (\u0027Code Injection\u0027)"},"helpUri":"https://cwe.mitre.org/data/definitions/94.html"}]},{"name":"OWASP Top 10","guid":"7d1f0c2e-4b6a-4e39-9a51-0b2e8c3d5f61","version":"2025","organization":"OWASP Foundation","informationUri":"https://top10.owasp.org/2025/","isComprehensive":false,"shortDescription":{"text":"The OWASP Top 10:2025 web application security risks."},"taxa":[{"id":"A01:2025","guid":"df693558-c822-0452-8f7b-4d53cb6bcc59","name":"Broken Access Control","shortDescription":{"text":"Broken Access Control"},"helpUri":"https://top10.owasp.org/2025/A01_2025-Broken_Access_Control/"},{"id":"A02:2025","guid":"668dee9e-41bc-6354-97d0-fdf8f40c50c1","name":"Security Misconfiguration","shortDescription":{"text":"Security Misconfiguration"},"helpUri":"https://top10.owasp.org/2025/A02_2025-Security_Misconfiguration/"},{"id":"A03:2025","guid":"168e227c-7735-2e57-bc6e-997affe644c5","name":"Software Supply Chain Failures","shortDescription":{"text":"Software Supply Chain Failures"},"helpUri":"https://top10.owasp.org/2025/A03_2025-Software_Supply_Chain_Failures/"},{"id":"A04:2025","guid":"6a9f5bfd-1a56-6453-beec-a7eff0ba3007","name":"Cryptographic Failures","shortDescription":{"text":"Cryptographic Failures"},"helpUri":"https://top10.owasp.org/2025/A04_2025-Cryptographic_Failures/"},{"id":"A05:2025","guid":"87e86033-3231-8458-8e4a-5cb82743553a","name":"Injection","shortDescription":{"text":"Injection"},"helpUri":"https://top10.owasp.org/2025/A05_2025-Injection/"},{"id":"A07:2025","guid":"334ddd78-539d-d35c-83dd-253647eb7eaf","name":"Authentication Failures","shortDescription":{"text":"Authentication Failures"},"helpUri":"https://top10.owasp.org/2025/A07_2025-Authentication_Failures/"},{"id":"A08:2025","guid":"84b0c297-710e-9a5f-9335-936ecb260c36","name":"Software or Data Integrity Failures","shortDescription":{"text":"Software or Data Integrity Failures"},"helpUri":"https://top10.owasp.org/2025/A08_2025-Software_or_Data_Integrity_Failures/"},{"id":"A09:2025","guid":"78892bc9-3c98-495d-881c-8af1390d643c","name":"Security Logging \u0026 Alerting Failures","shortDescription":{"text":"Security Logging \u0026 Alerting Failures"},"helpUri":"https://top10.owasp.org/2025/A09_2025-Security_Logging_and_Alerting_Failures/"}]},{"name":"OWASP Top 10 CI/CD Security Risks","guid":"3c9b2a6e-5d14-4f7b-8e02-6a1d9c4b7f35","organization":"OWASP Foundation","informationUri":"https://owasp.org/www-project-top-10-ci-cd-security-risks/","isComprehensive":false,"shortDescription":{"text":"The OWASP Top 10 CI/CD Security Risks."},"taxa":[{"id":"CICD-SEC-4","guid":"c859d8ea-8b24-a157-9406-94929c10397a","name":"Poisoned Pipeline Execution (PPE)","shortDescription":{"text":"Poisoned Pipeline Execution (PPE)"},"helpUri":"https://owasp.github.io/www-project-top-10-ci-cd-security-risks/CICD-SEC-04-Poisoned-Pipeline-Execution"},{"id":"CICD-SEC-9","guid":"b3d36727-0395-5b51-94c4-5e173d62eab3","name":"Improper Artifact Integrity Validation","shortDescription":{"text":"Improper Artifact Integrity Validation"},"helpUri":"https://owasp.github.io/www-project-top-10-ci-cd-security-risks/CICD-SEC-09-Improper-Artifact-Integrity-Validation"}]}],"properties":{"codehealthPublication":{"public":true,"notice":"This is the PUBLIC form of this artifact. Findings are listed in full, but the details of SECURITY findings \u2014 which rule fired, in which file, on which line, and how to fix it \u2014 are deliberately withheld, and any secret-scanner results are excluded entirely. Where detail is absent here it was REMOVED FOR PUBLICATION; it is not missing from the analysis. The complete artifact is available from the repository owner.","securityFindingsRedacted":40,"secretScannerRunsExcluded":0}},"redactionTokens":["A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."]}]}