{"$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":"D8","name":"Code Coverage","shortDescription":{"text":"Code Coverage"},"helpUri":"https://codehealth.canine.dev/dimensions/D8"},{"id":"D10","name":"Test Quality","shortDescription":{"text":"Test Quality"},"helpUri":"https://codehealth.canine.dev/dimensions/D10"},{"id":"D11","name":"Test Reliability","shortDescription":{"text":"Test Reliability"},"helpUri":"https://codehealth.canine.dev/dimensions/D11"},{"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":"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":"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":"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":"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":"AX8","name":"Test isolation","shortDescription":{"text":"Test isolation"},"helpUri":"https://codehealth.canine.dev/dimensions/AX8"},{"id":"AX9","name":"CQS / query purity","shortDescription":{"text":"CQS / query purity"},"helpUri":"https://codehealth.canine.dev/dimensions/AX9"},{"id":"AXB2","name":"Runtime readiness","shortDescription":{"text":"Runtime readiness"},"helpUri":"https://codehealth.canine.dev/dimensions/AXB2"},{"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":"P6","name":"Release Hygiene","shortDescription":{"text":"Release Hygiene"},"helpUri":"https://codehealth.canine.dev/dimensions/P6"},{"id":"PF1","name":"Benchmark discipline","shortDescription":{"text":"Benchmark discipline"},"helpUri":"https://codehealth.canine.dev/dimensions/PF1"},{"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":"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":"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":"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":"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":"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":"X29","name":"Per-element action decided by a fixed element","shortDescription":{"text":"Per-element action decided by a fixed element"},"helpUri":"https://codehealth.canine.dev/dimensions/X29"},{"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":"loro_internal::dag::_find_meet_and_mode (cyclomatic 92): loro_internal::dag::_find_meet_and_mode has cyclomatic complexity 92 (threshold 15). Of this number, 53 points are the body\u0027s own statements and 39 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":"crates/loro-internal/src/dag.rs"},"region":{"startLine":740}}}],"partialFingerprints":{"codehealthFindingId/v1":"7592aae4fdc49e7eb36c86cc2e5b5acacb64e362e78320e4581203dd08557011"}},{"ruleId":"D1","level":"warning","message":{"text":"LoroDoc.#importBlob (cyclomatic 81): LoroDoc.#importBlob has cyclomatic complexity 81 (threshold 15). Of this number, 77 points are the body\u0027s own statements and 4 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":"loro-js/src/runtime/document.ts"},"region":{"startLine":792}}}],"partialFingerprints":{"codehealthFindingId/v1":"3609920b3bb05c4e2d319444c4f128fd9a0a0896bcb64d2114c0cda87242601e"}},{"ruleId":"D1","level":"warning","message":{"text":"LoroDoc.#applyVersionTransition (cyclomatic 53): LoroDoc.#applyVersionTransition 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. This shape REPEATS in the file: one other method here (LoroDoc.#applyVersionTransition::collect) 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":"loro-js/src/runtime/document.ts"},"region":{"startLine":5836}}}],"partialFingerprints":{"codehealthFindingId/v1":"c89fe1c31f32bbec588cc6a210a06e234f3ef11c629f390df70a9fe288211eba"}},{"ruleId":"D1","level":"warning","message":{"text":"LoroDoc.#alignFullState (cyclomatic 50): LoroDoc.#alignFullState has cyclomatic complexity 50 (threshold 15). Of this number, 46 points are the body\u0027s own statements and 4 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":"loro-js/src/runtime/document.ts"},"region":{"startLine":2127}}}],"partialFingerprints":{"codehealthFindingId/v1":"cf2cd48b50e6ba185244b22115fd86b8fc40cf1b72c0f88cee2dfc5003ecae5a"}},{"ruleId":"D1","level":"warning","message":{"text":"LoroDoc::check_apply_diff_creates_no_unknown_container (cyclomatic 48): LoroDoc::check_apply_diff_creates_no_unknown_container 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":"crates/loro-internal/src/loro.rs"},"region":{"startLine":2592}}}],"partialFingerprints":{"codehealthFindingId/v1":"fccbb2609276d0eb6b5a39e300dcf953fa230cc09ecbdc06fcbb7c0f709ca7f0"}},{"ruleId":"D1","level":"warning","message":{"text":"LoroDoc.#applyMovableListMoves (cyclomatic 47): LoroDoc.#applyMovableListMoves has cyclomatic complexity 47 (threshold 15). Of this number, 44 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":"loro-js/src/runtime/document.ts"},"region":{"startLine":1476}}}],"partialFingerprints":{"codehealthFindingId/v1":"ba680662a57ea305ac215a65e62921eb1f5758205cfc9b08327744fde63f4801"}},{"ruleId":"D1","level":"warning","message":{"text":"document.jsonOperationToDecoded (cyclomatic 42): document.jsonOperationToDecoded has cyclomatic complexity 42 (threshold 15). Of this number, 37 points are the body\u0027s own statements and 5 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":"loro-js/src/runtime/document.ts"},"region":{"startLine":10197}}}],"partialFingerprints":{"codehealthFindingId/v1":"ceec8f4d194f65bb4fd682cf25d1515be4a0e4065d8382bf262e53519dde063a"}},{"ruleId":"D1","level":"warning","message":{"text":"RichtextState::apply_diff (cyclomatic 40): RichtextState::apply_diff 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":"crates/loro-internal/src/state/richtext_state.rs"},"region":{"startLine":627}}}],"partialFingerprints":{"codehealthFindingId/v1":"57cd0c1f13c8c38f029fcec7c1a8117d6ce509726943564159b83f7c97be92ff"}},{"ruleId":"D1","level":"warning","message":{"text":"loro_internal::dag::_walk_to_meet (cyclomatic 40): loro_internal::dag::_walk_to_meet 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":"crates/loro-internal/src/dag.rs"},"region":{"startLine":442}}}],"partialFingerprints":{"codehealthFindingId/v1":"c7123b0792aebc5f3fbc784ed96cf586515192c2b20232bc12f3ab819fa9ba14"}},{"ruleId":"D1","level":"warning","message":{"text":"LoroDoc.#prepareEvent (cyclomatic 40): LoroDoc.#prepareEvent has cyclomatic complexity 40 (threshold 15). Of this number, 31 points are the body\u0027s own statements and 9 belong to 3 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":"loro-js/src/runtime/document.ts"},"region":{"startLine":4686}}}],"partialFingerprints":{"codehealthFindingId/v1":"f70a43de30c59d40c590a8eb18c5ff7d9ff99336dc759227fea8de520d0fc4f7"}},{"ruleId":"D1","level":"warning","message":{"text":"loro_internal::encoding::json_schema::encode_change (cyclomatic 38): loro_internal::encoding::json_schema::encode_change 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":"crates/loro-internal/src/encoding/json_schema.rs"},"region":{"startLine":291}}}],"partialFingerprints":{"codehealthFindingId/v1":"026da916ce70c2ba8d2286512e68e7b5933d46296f7c7428ef6056d3838b3f47"}},{"ruleId":"D1","level":"warning","message":{"text":"LoroDoc.#canTransitionRecords (cyclomatic 38): LoroDoc.#canTransitionRecords has cyclomatic complexity 38 (threshold 15). Of this number, 37 points are the body\u0027s own statements and 1 belongs 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":"loro-js/src/runtime/document.ts"},"region":{"startLine":5733}}}],"partialFingerprints":{"codehealthFindingId/v1":"9ed7d253bb3e9e9d64909dbd1f778c6946f908d11b1e05b634aa5d80394702df"}},{"ruleId":"D1","level":"warning","message":{"text":"LoroDoc.#applyVersionTransition::collect (cyclomatic 38): LoroDoc.#applyVersionTransition::collect 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. This shape REPEATS in the file: one other method here (LoroDoc.#applyVersionTransition) 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":"loro-js/src/runtime/document.ts"},"region":{"startLine":5891}}}],"partialFingerprints":{"codehealthFindingId/v1":"044b19b35f63432aade9e17ca8b26c57ab23d5c2e9789d51cdb074acc4793ae4"}},{"ruleId":"D1","level":"warning","message":{"text":"LoroDoc.#containerState (cyclomatic 38): LoroDoc.#containerState has cyclomatic complexity 38 (threshold 15). Of this number, 25 points are the body\u0027s own statements and 13 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":"loro-js/src/runtime/document.ts"},"region":{"startLine":8234}}}],"partialFingerprints":{"codehealthFindingId/v1":"10e3d6b30b03fdd55f624a53c8d8d42f03a90418da49653d4e700a0e58a629d8"}},{"ruleId":"D1","level":"warning","message":{"text":"MovableListState::apply_diff_and_convert (cyclomatic 37): MovableListState::apply_diff_and_convert 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":"crates/loro-internal/src/state/movable_list_state.rs"},"region":{"startLine":1092}}}],"partialFingerprints":{"codehealthFindingId/v1":"4eae81a3c7a691dbc2cb21c0ab454360a0b202f9b671fe56443e352a7f06c3d3"}},{"ruleId":"D1","level":"warning","message":{"text":"DocState::apply_diff (cyclomatic 37): DocState::apply_diff 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":"crates/loro-internal/src/state.rs"},"region":{"startLine":664}}}],"partialFingerprints":{"codehealthFindingId/v1":"92453a5919feb1e072411d0f1564c9ef4a02fe914c1de4ef18987f76d7f8a9ca"}},{"ruleId":"D1","level":"warning","message":{"text":"loro_internal::encoding::json_schema::decode_op (cyclomatic 37): loro_internal::encoding::json_schema::decode_op has cyclomatic complexity 37 (threshold 15). To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Where every arm is uniform \u2014 the same kind of value, with no behaviour of its own \u2014 a table keyed by the case is the shorter form; wherever the arms carry different data or different behaviour, keep them as cases, because collapsing those trades an explicit, reviewable set of cases for nothing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/encoding/json_schema.rs"},"region":{"startLine":780}}}],"partialFingerprints":{"codehealthFindingId/v1":"8b4c4ed3d3b287310837ccc57cf85fc04bd2c0c1b11962fd132d472695e4e208"}},{"ruleId":"D1","level":"warning","message":{"text":"MovableListState.transition (cyclomatic 37): MovableListState.transition has cyclomatic complexity 37 (threshold 15). Of this number, 33 points are the body\u0027s own statements and 4 belong to 3 function items inside it that branch. 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":"loro-js/src/runtime/movable-list.ts"},"region":{"startLine":540}}}],"partialFingerprints":{"codehealthFindingId/v1":"6315287b6c8eefae1e6efb637c2a377a4b6fedbe55ac1050d0e6e413321e8596"}},{"ruleId":"D1","level":"warning","message":{"text":"LoroDoc.#completeTreeRevivals (cyclomatic 37): LoroDoc.#completeTreeRevivals has cyclomatic complexity 37 (threshold 15). Of this number, 29 points are the body\u0027s own statements and 8 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":"loro-js/src/runtime/document.ts"},"region":{"startLine":1650}}}],"partialFingerprints":{"codehealthFindingId/v1":"14a36df2deded5fd2e46cee1deaafecb4a5b7f31ed8cc60583ad40d51823abb3"}},{"ruleId":"D1","level":"warning","message":{"text":"LoroDoc::import_changes_and_apply_delta_to_state_if_needed (cyclomatic 36): LoroDoc::import_changes_and_apply_delta_to_state_if_needed 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":"crates/loro-internal/src/loro.rs"},"region":{"startLine":973}}}],"partialFingerprints":{"codehealthFindingId/v1":"bc70652d4b83b887f0e778f9a4ad861e6cc098d833bd0d1cc34303ed63649594"}},{"ruleId":"D1","level":"warning","message":{"text":"DocState::get_value_by_path (cyclomatic 35): DocState::get_value_by_path 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":"crates/loro-internal/src/state.rs"},"region":{"startLine":2456}}}],"partialFingerprints":{"codehealthFindingId/v1":"5e406960317978249ba647811e097c98ce97da10bcb0316ead4652aa6ab9e671"}},{"ruleId":"D1","level":"warning","message":{"text":"LoroDoc.#sequenceTreeItems (cyclomatic 34): LoroDoc.#sequenceTreeItems has cyclomatic complexity 34 (threshold 15). Of this number, 20 points are the body\u0027s own statements and 14 belong to 9 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":"loro-js/src/runtime/document.ts"},"region":{"startLine":1824}}}],"partialFingerprints":{"codehealthFindingId/v1":"afc4e4846828b6c05cb481e9830655790172d6bef3152434bd9fe2fc1f9a4191"}},{"ruleId":"D1","level":"warning","message":{"text":"DiffCalculator::try_calc_diff_internal (cyclomatic 33): DiffCalculator::try_calc_diff_internal 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":"crates/loro-internal/src/diff_calc.rs"},"region":{"startLine":186}}}],"partialFingerprints":{"codehealthFindingId/v1":"f9113a9f0da534f5e48e6a6cdf3b0e9c080726dde6ad80968db73aee81c73255"}},{"ruleId":"D1","level":"warning","message":{"text":"LoroDoc.#undoOperation (cyclomatic 33): LoroDoc.#undoOperation 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":"loro-js/src/runtime/document.ts"},"region":{"startLine":3764}}}],"partialFingerprints":{"codehealthFindingId/v1":"823d2a1558fba5508a855c3edbee6e6bdc7eaffe2362281f2f0b5eab60b1aa05"}},{"ruleId":"D1","level":"warning","message":{"text":"Handler::apply_diff (cyclomatic 32): Handler::apply_diff has cyclomatic complexity 32 (threshold 15). Of this number, 30 points are the body\u0027s own statements and 2 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":"crates/loro-internal/src/handler.rs"},"region":{"startLine":1368}}}],"partialFingerprints":{"codehealthFindingId/v1":"3e6da648c070c97ef4b32614289d11af64382d9c7bbb7290ad22f016eab3b65b"}},{"ruleId":"D1","level":"warning","message":{"text":"LoroDoc.#undoMovableLists (cyclomatic 32): LoroDoc.#undoMovableLists has cyclomatic complexity 32 (threshold 15). Of this number, 24 points are the body\u0027s own statements and 8 belong to 3 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":"loro-js/src/runtime/document.ts"},"region":{"startLine":3623}}}],"partialFingerprints":{"codehealthFindingId/v1":"e276deabce6aa1962b3431f5b24eaa6163753d4e26ee9818e98ceb51273e3ef9"}},{"ruleId":"D1","level":"warning","message":{"text":"LoroDoc.#latestSingleHeadCriticalVersion (cyclomatic 32): LoroDoc.#latestSingleHeadCriticalVersion has cyclomatic complexity 32 (threshold 15). Of this number, 18 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":"loro-js/src/runtime/document.ts"},"region":{"startLine":7870}}}],"partialFingerprints":{"codehealthFindingId/v1":"9ead6d502cd9740ac7682adb1cd1cde8a596735eb53e571467f55461ac7c8746"}},{"ruleId":"D1","level":"warning","message":{"text":"LoroDoc::apply_diff_with_movable_undo (cyclomatic 30): LoroDoc::apply_diff_with_movable_undo 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":"crates/loro-internal/src/loro.rs"},"region":{"startLine":2182}}}],"partialFingerprints":{"codehealthFindingId/v1":"906c43e94cf0752d56bd6af94ad2dbe9df89bcc3492aaae148b502cda2342334"}},{"ruleId":"D1","level":"warning","message":{"text":"loro_internal::diff::diff_impl::dj_diff (cyclomatic 30): loro_internal::diff::diff_impl::dj_diff has cyclomatic complexity 30 (threshold 15). This file\u0027s own header attributes it to another copyright holder, so it is code this repository carries rather than code it wrote: restructuring the body in place forks it from upstream and turns every future re-sync into a manual merge. The performable moves are to leave the body as close to its upstream form as possible and keep it behind a narrow interface of your own, and to re-sync it when upstream changes \u2014 or, if it has already diverged far enough that you maintain it here, adopt it deliberately and then split the body into named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/diff/diff_impl.rs"},"region":{"startLine":364}}}],"partialFingerprints":{"codehealthFindingId/v1":"40843477e5ec5a906594b4409a6da457946bc18625d99464cd7e3597668c1580"}},{"ruleId":"D1","level":"warning","message":{"text":"jsonpath.applySelector (cyclomatic 30): jsonpath.applySelector 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":"loro-js/src/runtime/jsonpath.ts"},"region":{"startLine":281}}}],"partialFingerprints":{"codehealthFindingId/v1":"7f6dd5381603047bffc8c7a8b836164ac8da64baec0c0af00c77cd7b60a70ee6"}},{"ruleId":"D1","level":"warning","message":{"text":"document.decodeImportBlobMeta (cyclomatic 30): document.decodeImportBlobMeta has cyclomatic complexity 30 (threshold 15). Of this number, 26 points are the body\u0027s own statements and 4 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":"loro-js/src/runtime/document.ts"},"region":{"startLine":8895}}}],"partialFingerprints":{"codehealthFindingId/v1":"720e3ed9185ac8810b73ea222142581dadd485789eabc26fb398f5a3ccf32827"}},{"ruleId":"D1","level":"warning","message":{"text":"document.validateTreeItems (cyclomatic 30): document.validateTreeItems 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 6 function items inside it that branch (countOf, checkIndex, alive, \u2026). Those helpers are already separate functions, so extracting the branching again is not available. To reduce it, move them out of the body to the enclosing scope, where each is measured, reviewed and tested on its own, and reduce whichever one then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/document.ts"},"region":{"startLine":11160}}}],"partialFingerprints":{"codehealthFindingId/v1":"7c96e311ff683893b1a8f45a4955d00a278111a5385c945c64ca9706ea7049f5"}},{"ruleId":"D1","level":"warning","message":{"text":"SequenceIndex.insertSpanAtPhysical (cyclomatic 29): SequenceIndex.insertSpanAtPhysical 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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":1104}}}],"partialFingerprints":{"codehealthFindingId/v1":"df4e27976f99b77e93a3ac3ed81294001728197d755d493121a453b01eeb439c"}},{"ruleId":"D1","level":"warning","message":{"text":"LoroDoc.diff (cyclomatic 29): LoroDoc.diff has cyclomatic complexity 29 (threshold 15). Of this number, 25 points are the body\u0027s own statements and 4 belong to 3 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":"loro-js/src/runtime/document.ts"},"region":{"startLine":1263}}}],"partialFingerprints":{"codehealthFindingId/v1":"604a94bac5608a0b180a7d9fbbdc8225ea5c5a45d659f86a54f25de9964ba8e4"}},{"ruleId":"D1","level":"warning","message":{"text":"Model::undo (cyclomatic 28): Model::undo 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":"crates/loro-internal/src/undo/movable_list.rs"},"region":{"startLine":470}}}],"partialFingerprints":{"codehealthFindingId/v1":"7c713939a4ffa68c50db34c4b315c7105e16bf1e1333f81538d8bcd877edfb91"}},{"ruleId":"D1","level":"warning","message":{"text":"change-value.encodeChangeValueContent (cyclomatic 28): change-value.encodeChangeValueContent has cyclomatic complexity 28 (threshold 15). To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Where every arm is uniform \u2014 the same kind of value, with no behaviour of its own \u2014 a table keyed by the case is the shorter form; wherever the arms carry different data or different behaviour, keep them as cases, because collapsing those trades an explicit, reviewable set of cases for nothing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/codec/change-value.ts"},"region":{"startLine":212}}}],"partialFingerprints":{"codehealthFindingId/v1":"2a38923b86bddcbd1c6858e8f594cc86ac787429c433c88928872b77a525d7cc"}},{"ruleId":"D1","level":"warning","message":{"text":"MovableListUndoState.apply (cyclomatic 28): MovableListUndoState.apply has cyclomatic complexity 28 (threshold 15). Of this number, 27 points are the body\u0027s own statements and 1 belongs 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":"loro-js/src/runtime/movable-list-undo.ts"},"region":{"startLine":73}}}],"partialFingerprints":{"codehealthFindingId/v1":"102f231b7c0b02bb0898ce348196af3deb7eaa5f06f80b3b0376ec86cf2b433f"}},{"ruleId":"D1","level":"warning","message":{"text":"TextHandler::insert_with_txn_and_attr (cyclomatic 27): TextHandler::insert_with_txn_and_attr 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":"crates/loro-internal/src/handler.rs"},"region":{"startLine":2148}}}],"partialFingerprints":{"codehealthFindingId/v1":"9ae32369e2c28842cc2c45071ff2d01038ed28fa7a01bad422fbe84a59fdb588"}},{"ruleId":"D1","level":"warning","message":{"text":"ContainerHistoryCache::init_cache_by_visit_all_change_slow (cyclomatic 27): ContainerHistoryCache::init_cache_by_visit_all_change_slow 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":"crates/loro-internal/src/history_cache.rs"},"region":{"startLine":163}}}],"partialFingerprints":{"codehealthFindingId/v1":"5a82733b787a5482324624f2822df8d9159a91a1d948cc7b40f0f924922dc024"}},{"ruleId":"D1","level":"warning","message":{"text":"OpLog::check_changes_include_predecessors (cyclomatic 27): OpLog::check_changes_include_predecessors 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":"crates/loro-internal/src/oplog/known_history.rs"},"region":{"startLine":265}}}],"partialFingerprints":{"codehealthFindingId/v1":"73edad4d88370b7e218451f2a79341071b997f73fcdeb049ba672f2128abb1c7"}},{"ruleId":"D1","level":"warning","message":{"text":"loro_internal::encoding::outdated_encode_reordered::decode_op (cyclomatic 27): loro_internal::encoding::outdated_encode_reordered::decode_op has cyclomatic complexity 27 (threshold 15). To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Where every arm is uniform \u2014 the same kind of value, with no behaviour of its own \u2014 a table keyed by the case is the shorter form; wherever the arms carry different data or different behaviour, keep them as cases, because collapsing those trades an explicit, reviewable set of cases for nothing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/encoding/outdated_encode_reordered.rs"},"region":{"startLine":288}}}],"partialFingerprints":{"codehealthFindingId/v1":"a0612fb890795ba8c627086ade4c5545ef2b6a34a28a55a2e982ead222f90b62"}},{"ruleId":"D1","level":"warning","message":{"text":"jsonpath.primitiveCompare (cyclomatic 27): jsonpath.primitiveCompare 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":"loro-js/src/runtime/jsonpath.ts"},"region":{"startLine":766}}}],"partialFingerprints":{"codehealthFindingId/v1":"a9a2de21bcd173bbce7da3d085180647c90ef403b1c9a264e5e4d91ef5e2aab5"}},{"ruleId":"D1","level":"warning","message":{"text":"ListDiffCalculator::calculate_diff (cyclomatic 26): ListDiffCalculator::calculate_diff has cyclomatic complexity 26 (threshold 15). Of this number, 16 points are the body\u0027s own statements and 10 belong to one function item inside it that branches. 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":"crates/loro-internal/src/diff_calc.rs"},"region":{"startLine":945}}}],"partialFingerprints":{"codehealthFindingId/v1":"9d4c047e5b2d2f89b8f7eef333cec9493c5c8b848332697206a7f575fc84fb21"}},{"ruleId":"D1","level":"warning","message":{"text":"ChangeStore::get_change_by_lamport_lte (cyclomatic 26): ChangeStore::get_change_by_lamport_lte 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":"crates/loro-internal/src/oplog/change_store.rs"},"region":{"startLine":1554}}}],"partialFingerprints":{"codehealthFindingId/v1":"42325d096e630fabd3848d2eae83801455b2cf1b9dab6924c67c575a228fd46d"}},{"ruleId":"D1","level":"warning","message":{"text":"AppDag::debug_vv_from_block_headers (cyclomatic 26): AppDag::debug_vv_from_block_headers 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":"crates/loro-internal/src/oplog/loro_dag.rs"},"region":{"startLine":1446}}}],"partialFingerprints":{"codehealthFindingId/v1":"c4b09efab012b2cb39a2b6f3a54a7b9c702408eb670fa08c6fc4c8a0b882831f"}},{"ruleId":"D1","level":"warning","message":{"text":"OpLog::try_iter_from_replay_base_causally_filtered (cyclomatic 26): OpLog::try_iter_from_replay_base_causally_filtered 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":"crates/loro-internal/src/oplog.rs"},"region":{"startLine":1269}}}],"partialFingerprints":{"codehealthFindingId/v1":"260440c1887a56e0e015aa43fd6356d90c084e46be8caef9ad0bf00152a37d1c"}},{"ruleId":"D1","level":"warning","message":{"text":"SequenceIndex.insertAtPhysical (cyclomatic 26): SequenceIndex.insertAtPhysical 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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":1025}}}],"partialFingerprints":{"codehealthFindingId/v1":"6df5596906d787df94797c9757294bced999650c5d22be4f1420bc991b91f842"}},{"ruleId":"D1","level":"warning","message":{"text":"LoroDoc.#applyOperation (cyclomatic 26): LoroDoc.#applyOperation has cyclomatic complexity 26 (threshold 15). To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Where every arm is uniform \u2014 the same kind of value, with no behaviour of its own \u2014 a table keyed by the case is the shorter form; wherever the arms carry different data or different behaviour, keep them as cases, because collapsing those trades an explicit, reviewable set of cases for nothing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/document.ts"},"region":{"startLine":5167}}}],"partialFingerprints":{"codehealthFindingId/v1":"2d709f735c0cd6cfdbe7f47c9c6a4c9158e0d9d4dd5d67559f99dfc1533a734b"}},{"ruleId":"D1","level":"warning","message":{"text":"LoroDoc.#hydrateContainerState (cyclomatic 26): LoroDoc.#hydrateContainerState 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":"loro-js/src/runtime/document.ts"},"region":{"startLine":8545}}}],"partialFingerprints":{"codehealthFindingId/v1":"f023eab6c8604b6b8b74f025758da0784ec6bfd0c16912524b9795158e1d5c11"}},{"ruleId":"D1","level":"warning","message":{"text":"change-block-codec.decodeOperationContent (cyclomatic 25): change-block-codec.decodeOperationContent 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":"loro-js/src/codec/change-block-codec.ts"},"region":{"startLine":358}}}],"partialFingerprints":{"codehealthFindingId/v1":"592b7753bec0b37b1b31f75ead9efa270a0d3679ad278a14f185c65e1d32578b"}},{"ruleId":"D1","level":"warning","message":{"text":"sequence-index.recomputeOwnElements (cyclomatic 25): sequence-index.recomputeOwnElements 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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":2947}}}],"partialFingerprints":{"codehealthFindingId/v1":"e059a10e67c26f76f8fee2b2fd08cb1b35362ac86005b12ed3380232fa7fd36c"}},{"ruleId":"D1","level":"warning","message":{"text":"ValueReader::recursive_read_value_type_and_content (cyclomatic 24): ValueReader::recursive_read_value_type_and_content has cyclomatic complexity 24 (threshold 15). To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Where every arm is uniform \u2014 the same kind of value, with no behaviour of its own \u2014 a table keyed by the case is the shorter form; wherever the arms carry different data or different behaviour, keep them as cases, because collapsing those trades an explicit, reviewable set of cases for nothing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/encoding/value.rs"},"region":{"startLine":691}}}],"partialFingerprints":{"codehealthFindingId/v1":"c4dbff7d123628ce8667c889cd17efea889f3089fd9f121ad077d61c10605345"}},{"ruleId":"D1","level":"warning","message":{"text":"sequence-index.recomputeOwn (cyclomatic 24): sequence-index.recomputeOwn 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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":2834}}}],"partialFingerprints":{"codehealthFindingId/v1":"a50f6412544eb66e2fdbb32265142474a92fc1961f674da618e95c547742f99d"}},{"ruleId":"D1","level":"warning","message":{"text":"LoroDoc.#validateDiffBatch (cyclomatic 24): LoroDoc.#validateDiffBatch has cyclomatic complexity 24 (threshold 15). Of this number, 21 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":"loro-js/src/runtime/document.ts"},"region":{"startLine":2479}}}],"partialFingerprints":{"codehealthFindingId/v1":"92a4c876da8e561711ffbe9024c7b21e984abb9f11b46e4e2d30ceff434a8b6f"}},{"ruleId":"D1","level":"warning","message":{"text":"LoroDoc::undo_internal_with (cyclomatic 23): LoroDoc::undo_internal_with 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":"crates/loro-internal/src/loro.rs"},"region":{"startLine":1565}}}],"partialFingerprints":{"codehealthFindingId/v1":"e3eb232b97553acaef0294d70bb91731095d79fe7e01cbe0969d43dca7cc9823"}},{"ruleId":"D1","level":"warning","message":{"text":"loro_internal::txn::change_to_diff (cyclomatic 23): loro_internal::txn::change_to_diff has cyclomatic complexity 23 (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":"crates/loro-internal/src/txn.rs"},"region":{"startLine":968}}}],"partialFingerprints":{"codehealthFindingId/v1":"da6991c71cb426280b881fb52fdf34323343f2c274d3a2fcd185f5f57a69429a"}},{"ruleId":"D1","level":"warning","message":{"text":"jsonpath.lookupChild (cyclomatic 23): jsonpath.lookupChild 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":"loro-js/src/runtime/jsonpath.ts"},"region":{"startLine":369}}}],"partialFingerprints":{"codehealthFindingId/v1":"1df7456bd60bad3c4f91f0e829bd0de2fb8d98eb452429f0849a8015a187e51b"}},{"ruleId":"D1","level":"warning","message":{"text":"LoroDoc.#rebuildFromSnapshotState (cyclomatic 23): LoroDoc.#rebuildFromSnapshotState 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":"loro-js/src/runtime/document.ts"},"region":{"startLine":6676}}}],"partialFingerprints":{"codehealthFindingId/v1":"ed7a6d77b55998dc9e3db9b9597a933e29943f771d78351bc1b882179fbd463b"}},{"ruleId":"D1","level":"warning","message":{"text":"UndoManager.#record (cyclomatic 23): UndoManager.#record has cyclomatic complexity 23 (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":"loro-js/src/runtime/undo.ts"},"region":{"startLine":239}}}],"partialFingerprints":{"codehealthFindingId/v1":"3934fc1b3062178a7cab43ac9b7b6f6e05a962b59c3be21397092df7dd513d15"}},{"ruleId":"D1","level":"warning","message":{"text":"BTree::handle_lack_single_layer (cyclomatic 22): BTree::handle_lack_single_layer has cyclomatic complexity 22 (threshold 15). To reduce it, break up the iteration: give each loop body a named function, and split a multi-phase loop into one function per phase so no single body carries the whole pipeline."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/generic-btree/src/lib.rs"},"region":{"startLine":2004}}}],"partialFingerprints":{"codehealthFindingId/v1":"aaece1781b7c4f42bf5e65f3588053726aee9b5c22782b55ccf66fe331c99a0e"}},{"ruleId":"D1","level":"warning","message":{"text":"CrdtRope::insert (cyclomatic 22): CrdtRope::insert 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":"crates/loro-internal/src/container/richtext/tracker/crdt_rope.rs"},"region":{"startLine":63}}}],"partialFingerprints":{"codehealthFindingId/v1":"efde4f4ac9e37d42a31e859d6d9ebf47b5601a9bd965778ef63bbde2c9cfce94"}},{"ruleId":"D1","level":"warning","message":{"text":"RichtextDiffCalculator::calculate_diff (cyclomatic 22): RichtextDiffCalculator::calculate_diff has cyclomatic complexity 22 (threshold 15). Of this number, 12 points are the body\u0027s own statements and 10 belong to 2 function items inside it that branch. 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":"crates/loro-internal/src/diff_calc.rs"},"region":{"startLine":1829}}}],"partialFingerprints":{"codehealthFindingId/v1":"2f6ec359316fe03eb032223f555c9c12a2626bf205c13511cc6e0b76f2de2b30"}},{"ruleId":"D1","level":"warning","message":{"text":"loro_internal::diff::diff_impl::find_middle_snake (cyclomatic 22): loro_internal::diff::diff_impl::find_middle_snake has cyclomatic complexity 22 (threshold 15). This file\u0027s own header attributes it to another copyright holder, so it is code this repository carries rather than code it wrote: restructuring the body in place forks it from upstream and turns every future re-sync into a manual merge. The performable moves are to leave the body as close to its upstream form as possible and keep it behind a narrow interface of your own, and to re-sync it when upstream changes \u2014 or, if it has already diverged far enough that you maintain it here, adopt it deliberately and then split the body into named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/diff/diff_impl.rs"},"region":{"startLine":185}}}],"partialFingerprints":{"codehealthFindingId/v1":"ddaec15ad929516895a038851544d9e39e2092a69569e7470617136e8b05829b"}},{"ruleId":"D1","level":"warning","message":{"text":"leb128.writeSleb128 (cyclomatic 22): leb128.writeSleb128 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":"loro-js/src/codec/leb128.ts"},"region":{"startLine":94}}}],"partialFingerprints":{"codehealthFindingId/v1":"5302896cc8cbbe4bb3ece5b5a0d3d10e4573474a31672cd6a6ddba228da352e1"}},{"ruleId":"D1","level":"warning","message":{"text":"SequenceIndex.causalView (cyclomatic 22): SequenceIndex.causalView has cyclomatic complexity 22 (threshold 15). Most of this is not in the body itself: 5 of the 22 points are its own statements and the rest belongs to 3 function items inside it that branch (causalCount, a function literal at line 1655, isVisible). 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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":1597}}}],"partialFingerprints":{"codehealthFindingId/v1":"2f114ffb9debb81b183cad9b70811319e702b4e05c706be0bc3aa88ea794cc23"}},{"ruleId":"D1","level":"warning","message":{"text":"LoroDoc.#applyContainerDiff (cyclomatic 22): LoroDoc.#applyContainerDiff 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. This is NOT this file\u0027s highest cyclomatic complexity: document.decodedOperationToJson (cyclomatic 23) is higher and carries no row of its own \u2014 it was excluded as a flat dispatcher (a long switch/match over independent cases: many branches, almost no nesting), which this dimension does not treat as a refactor obligation. It is named here so the ranking you see in this file is not mistaken for the whole of it; the excluded method is counted neither in this dimension\u0027s figures nor in its score."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/document.ts"},"region":{"startLine":2585}}}],"partialFingerprints":{"codehealthFindingId/v1":"c786bed2ffdb3dfd5a0d73974540c4be5462809e612e82ca7dcc12e83c38f669"}},{"ruleId":"D1","level":"warning","message":{"text":"containers.styleValuesEqual (cyclomatic 22): containers.styleValuesEqual 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":"loro-js/src/runtime/containers.ts"},"region":{"startLine":2491}}}],"partialFingerprints":{"codehealthFindingId/v1":"ecbbb6c5b457faadcf606dcb9693954fbb18be602d3df0adc9790d03a7c5c6c9"}},{"ruleId":"D1","level":"warning","message":{"text":"BTree::update_leaf (cyclomatic 21): BTree::update_leaf 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":"crates/generic-btree/src/lib.rs"},"region":{"startLine":1267}}}],"partialFingerprints":{"codehealthFindingId/v1":"8253da04c2cee3ec8d9d93b2ee6082a4c1cf465d253f2dacd4499887a2e699df"}},{"ruleId":"D1","level":"warning","message":{"text":"MovableListDiffCalculator::calculate_diff (cyclomatic 21): MovableListDiffCalculator::calculate_diff 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":"crates/loro-internal/src/diff_calc.rs"},"region":{"startLine":2205}}}],"partialFingerprints":{"codehealthFindingId/v1":"272e793840730cb0ea93ba051d8df3eb6e2103b790beb0934d7f3d1a83cceba7"}},{"ruleId":"D1","level":"warning","message":{"text":"LoroDoc::order_mergeable_removals (cyclomatic 21): LoroDoc::order_mergeable_removals 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":"crates/loro-internal/src/loro.rs"},"region":{"startLine":2369}}}],"partialFingerprints":{"codehealthFindingId/v1":"3b17a4c86fecba4f459b48cccca3c07f32d91523775220f17fa13552328c69e9"}},{"ruleId":"D1","level":"warning","message":{"text":"AppDag::try_does_id_cover (cyclomatic 21): AppDag::try_does_id_cover 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":"crates/loro-internal/src/oplog/loro_dag.rs"},"region":{"startLine":1316}}}],"partialFingerprints":{"codehealthFindingId/v1":"b546c3df9f2f5d489e4ee3179594086f56080ab71e467a34c677cc65f79fa16b"}},{"ruleId":"D1","level":"warning","message":{"text":"DocState::ensure_containers_created_by_internal_diff (cyclomatic 21): DocState::ensure_containers_created_by_internal_diff 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":"crates/loro-internal/src/state.rs"},"region":{"startLine":938}}}],"partialFingerprints":{"codehealthFindingId/v1":"ccdbb185a44415a344f039192b6b1a7a367963bb29aeddaa3b9f2ead7c4cd80e"}},{"ruleId":"D1","level":"warning","message":{"text":"loro_internal::jsonpath::jsonpath_impl::apply_selectors (cyclomatic 21): loro_internal::jsonpath::jsonpath_impl::apply_selectors 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":"crates/loro-internal/src/jsonpath/jsonpath_impl.rs"},"region":{"startLine":113}}}],"partialFingerprints":{"codehealthFindingId/v1":"36a7633a37d68bf7211e5e5d7f8b4cab5f351e23c7ec7f644d400149aa55ecf2"}},{"ruleId":"D1","level":"warning","message":{"text":"change-block-codec.encodeChangeBlock (cyclomatic 21): change-block-codec.encodeChangeBlock 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":"loro-js/src/codec/change-block-codec.ts"},"region":{"startLine":234}}}],"partialFingerprints":{"codehealthFindingId/v1":"f20649011dbe226c6b82d92a35968229d04c625313d0d09e0ff8202ea6380449"}},{"ruleId":"D1","level":"warning","message":{"text":"SstableReader.rewrite (cyclomatic 21): SstableReader.rewrite has cyclomatic complexity 21 (threshold 15). Of this number, 19 points are the body\u0027s own statements and 2 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":"loro-js/src/codec/sstable.ts"},"region":{"startLine":162}}}],"partialFingerprints":{"codehealthFindingId/v1":"2cdf7dd76ef972885e8419659ac1a4db6cdb753264d404c6ae4b7e036a2aec7a"}},{"ruleId":"D1","level":"warning","message":{"text":"sequence-index.visitVisibleStorageRange (cyclomatic 21): sequence-index.visitVisibleStorageRange has cyclomatic complexity 21 (threshold 15). Of this number, 20 points are the body\u0027s own statements and 1 belongs 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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":3770}}}],"partialFingerprints":{"codehealthFindingId/v1":"444a4435df8b9c3f8b1d92437fff39ccbfa5dd9af7f9d39b1095ba4e7d922c7c"}},{"ruleId":"D1","level":"warning","message":{"text":"LoroDoc.#importBlobs (cyclomatic 21): LoroDoc.#importBlobs has cyclomatic complexity 21 (threshold 15). Of this number, 20 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top. This is NOT this file\u0027s highest cyclomatic complexity: document.decodedOperationToJson (cyclomatic 23) is higher and carries no row of its own \u2014 it was excluded as a flat dispatcher (a long switch/match over independent cases: many branches, almost no nesting), which this dimension does not treat as a refactor obligation. It is named here so the ranking you see in this file is not mistaken for the whole of it; the excluded method is counted neither in this dimension\u0027s figures nor in its score."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/document.ts"},"region":{"startLine":1079}}}],"partialFingerprints":{"codehealthFindingId/v1":"31f7e8eae9bd8fdc8792278fd859d9c069de06e8578d2f22606509245469cae6"}},{"ruleId":"D1","level":"warning","message":{"text":"LoroDoc.#recordedEventDiffs (cyclomatic 21): LoroDoc.#recordedEventDiffs 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. This is NOT this file\u0027s highest cyclomatic complexity: document.decodedOperationToJson (cyclomatic 23) is higher and carries no row of its own \u2014 it was excluded as a flat dispatcher (a long switch/match over independent cases: many branches, almost no nesting), which this dimension does not treat as a refactor obligation. It is named here so the ranking you see in this file is not mistaken for the whole of it; the excluded method is counted neither in this dimension\u0027s figures nor in its score."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/document.ts"},"region":{"startLine":4922}}}],"partialFingerprints":{"codehealthFindingId/v1":"8f5bcefcdfc64181f2875aa1097a01bd57df04d6753c39478d1a6761a478df20"}},{"ruleId":"D1","level":"warning","message":{"text":"LoroDoc.#recordsInSpans (cyclomatic 21): LoroDoc.#recordsInSpans 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. This is NOT this file\u0027s highest cyclomatic complexity: document.decodedOperationToJson (cyclomatic 23) is higher and carries no row of its own \u2014 it was excluded as a flat dispatcher (a long switch/match over independent cases: many branches, almost no nesting), which this dimension does not treat as a refactor obligation. It is named here so the ranking you see in this file is not mistaken for the whole of it; the excluded method is counted neither in this dimension\u0027s figures nor in its score."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/document.ts"},"region":{"startLine":7326}}}],"partialFingerprints":{"codehealthFindingId/v1":"62733998e0d3dfa660b4c23b56dff13405bc3054728e61c14fa348c1ab4e96b5"}},{"ruleId":"D1","level":"warning","message":{"text":"document.eventValuesEqual (cyclomatic 21): document.eventValuesEqual 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. This is NOT this file\u0027s highest cyclomatic complexity: document.decodedOperationToJson (cyclomatic 23) is higher and carries no row of its own \u2014 it was excluded as a flat dispatcher (a long switch/match over independent cases: many branches, almost no nesting), which this dimension does not treat as a refactor obligation. It is named here so the ranking you see in this file is not mistaken for the whole of it; the excluded method is counted neither in this dimension\u0027s figures nor in its score."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/document.ts"},"region":{"startLine":10924}}}],"partialFingerprints":{"codehealthFindingId/v1":"d510f8d5427cc85bce882d071211d413dc346c06c8a4ecb1e60c1b89cbfe9b31"}},{"ruleId":"D1","level":"warning","message":{"text":"loro_common::value::values_eq (cyclomatic 20): loro_common::value::values_eq 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":"crates/loro-common/src/value.rs"},"region":{"startLine":46}}}],"partialFingerprints":{"codehealthFindingId/v1":"12eaa9a1a00f2de02b1a064543eca3a26acbd6e0e8f7dab55767b7e23e9a56b3"}},{"ruleId":"D1","level":"warning","message":{"text":"LoroDoc::query_pos_internal (cyclomatic 20): LoroDoc::query_pos_internal 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":"crates/loro-internal/src/loro.rs"},"region":{"startLine":3698}}}],"partialFingerprints":{"codehealthFindingId/v1":"ec1c4c3565cbb91d3cf4709a6165d587761569b6b0032eec50f03884bb6fdf76"}},{"ruleId":"D1","level":"warning","message":{"text":"RichtextState::apply_diff_and_convert (cyclomatic 20): RichtextState::apply_diff_and_convert 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":"crates/loro-internal/src/state/richtext_state.rs"},"region":{"startLine":391}}}],"partialFingerprints":{"codehealthFindingId/v1":"ffae98252b0d515037abf6c6d4f48b14913399ceb7d0cd94eb4bf7cc2cdce479"}},{"ruleId":"D1","level":"warning","message":{"text":"loro_internal::encoding::shallow_snapshot::export_shallow_snapshot_inner (cyclomatic 20): loro_internal::encoding::shallow_snapshot::export_shallow_snapshot_inner 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":"crates/loro-internal/src/encoding/shallow_snapshot.rs"},"region":{"startLine":301}}}],"partialFingerprints":{"codehealthFindingId/v1":"6306bb8fd82490d5dfddc055b555ac23a921060ceff8221dc87c7977f8f14bfb"}},{"ruleId":"D1","level":"warning","message":{"text":"loro_internal::state::value_decode::encode_value (cyclomatic 20): loro_internal::state::value_decode::encode_value has cyclomatic complexity 20 (threshold 15). To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Where every arm is uniform \u2014 the same kind of value, with no behaviour of its own \u2014 a table keyed by the case is the shorter form; wherever the arms carry different data or different behaviour, keep them as cases, because collapsing those trades an explicit, reviewable set of cases for nothing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/state/value_decode.rs"},"region":{"startLine":190}}}],"partialFingerprints":{"codehealthFindingId/v1":"6dbcd92299f388e85a10f3fb144dc007dbc737aaa8423f67e1766940b66d027d"}},{"ruleId":"D1","level":"warning","message":{"text":"SequenceIndex.#markLocatedIdSpanVisibility (cyclomatic 20): SequenceIndex.#markLocatedIdSpanVisibility 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, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":1292}}}],"partialFingerprints":{"codehealthFindingId/v1":"46a3e326c5f1a498db69031dfbfc1d14732eb8ec77f5e07a49cfde350bed8566"}},{"ruleId":"D1","level":"warning","message":{"text":"movable-list.runtimeValuesEqual (cyclomatic 20): movable-list.runtimeValuesEqual has cyclomatic complexity 20 (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":"loro-js/src/runtime/movable-list.ts"},"region":{"startLine":146}}}],"partialFingerprints":{"codehealthFindingId/v1":"ab059c34fa2d317548fae3906767be2a0e3067c83e52922969954260f71a9494"}},{"ruleId":"D1","level":"warning","message":{"text":"LoroDoc.#completeDiffEntries (cyclomatic 20): LoroDoc.#completeDiffEntries has cyclomatic complexity 20 (threshold 15). Of this number, 19 points are the body\u0027s own statements and 1 belongs 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. This is NOT this file\u0027s highest cyclomatic complexity: document.decodedOperationToJson (cyclomatic 23) is higher and carries no row of its own \u2014 it was excluded as a flat dispatcher (a long switch/match over independent cases: many branches, almost no nesting), which this dimension does not treat as a refactor obligation. It is named here so the ranking you see in this file is not mistaken for the whole of it; the excluded method is counted neither in this dimension\u0027s figures nor in its score."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/document.ts"},"region":{"startLine":2295}}}],"partialFingerprints":{"codehealthFindingId/v1":"4547619a0e18c9a7b8982a730b2903b7ef132f93416c1108b39256b1da7fae66"}},{"ruleId":"D1","level":"warning","message":{"text":"LoroDoc.getCursorPos (cyclomatic 20): LoroDoc.getCursorPos has cyclomatic complexity 20 (threshold 15). Of this number, 19 points are the body\u0027s own statements and 1 belongs to one function item 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. This is NOT this file\u0027s highest cyclomatic complexity: document.decodedOperationToJson (cyclomatic 23) is higher and carries no row of its own \u2014 it was excluded as a flat dispatcher (a long switch/match over independent cases: many branches, almost no nesting), which this dimension does not treat as a refactor obligation. It is named here so the ranking you see in this file is not mistaken for the whole of it; the excluded method is counted neither in this dimension\u0027s figures nor in its score."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/document.ts"},"region":{"startLine":3371}}}],"partialFingerprints":{"codehealthFindingId/v1":"797e6672f1f65efbac7e5cd22b8f1c7987c7b0f7ba617a39864974998d6f11bd"}},{"ruleId":"D1","level":"warning","message":{"text":"LoroDoc._isContainerDeleted (cyclomatic 20): LoroDoc._isContainerDeleted has cyclomatic complexity 20 (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. This is NOT this file\u0027s highest cyclomatic complexity: document.decodedOperationToJson (cyclomatic 23) is higher and carries no row of its own \u2014 it was excluded as a flat dispatcher (a long switch/match over independent cases: many branches, almost no nesting), which this dimension does not treat as a refactor obligation. It is named here so the ranking you see in this file is not mistaken for the whole of it; the excluded method is counted neither in this dimension\u0027s figures nor in its score."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/document.ts"},"region":{"startLine":3532}}}],"partialFingerprints":{"codehealthFindingId/v1":"d5cacfd3b274f862a55a930164dceefc2f9c457a5da717166ff510d6e86982ec"}},{"ruleId":"D1","level":"warning","message":{"text":"document.containerDiff (cyclomatic 20): document.containerDiff 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, separate the cases: extract each independent 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 is NOT this file\u0027s highest cyclomatic complexity: document.decodedOperationToJson (cyclomatic 23) is higher and carries no row of its own \u2014 it was excluded as a flat dispatcher (a long switch/match over independent cases: many branches, almost no nesting), which this dimension does not treat as a refactor obligation. It is named here so the ranking you see in this file is not mistaken for the whole of it; the excluded method is counted neither in this dimension\u0027s figures nor in its score."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/document.ts"},"region":{"startLine":10702}}}],"partialFingerprints":{"codehealthFindingId/v1":"85441d246ae5f6cf5b3fd742ffac9d7200fe14e331124e575bd71e0b021a60bd"}},{"ruleId":"D1","level":"warning","message":{"text":"containers.indexedFugueInsertion (cyclomatic 20): containers.indexedFugueInsertion 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, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/containers.ts"},"region":{"startLine":3721}}}],"partialFingerprints":{"codehealthFindingId/v1":"ae09dee3c924d8db6ab62bc9e20e41f09a937ce2934bc3cac7797d70058ba495"}},{"ruleId":"D1","level":"warning","message":{"text":"LoroValue::apply (cyclomatic 19): LoroValue::apply has cyclomatic complexity 19 (threshold 15). To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Where every arm is uniform \u2014 the same kind of value, with no behaviour of its own \u2014 a table keyed by the case is the shorter form; wherever the arms carry different data or different behaviour, keep them as cases, because collapsing those trades an explicit, reviewable set of cases for nothing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/value.rs"},"region":{"startLine":444}}}],"partialFingerprints":{"codehealthFindingId/v1":"b30eaf59bab035a7b06d4c085b1ee84d8df6fe1e42e068d4d67d3b5a8a89d949"}},{"ruleId":"D1","level":"warning","message":{"text":"TextHandler::convert_pos (cyclomatic 19): TextHandler::convert_pos 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":"crates/loro-internal/src/handler.rs"},"region":{"startLine":2984}}}],"partialFingerprints":{"codehealthFindingId/v1":"761ff846ded7d6d19d7f5ec97e6fb7d0754e1d49d9aa2173c57043e38a6e00c7"}},{"ruleId":"D1","level":"warning","message":{"text":"ImportedValues::eq (cyclomatic 19): ImportedValues::eq has cyclomatic complexity 19 (threshold 15). To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Where every arm is uniform \u2014 the same kind of value, with no behaviour of its own \u2014 a table keyed by the case is the shorter form; wherever the arms carry different data or different behaviour, keep them as cases, because collapsing those trades an explicit, reviewable set of cases for nothing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/oplog/known_history.rs"},"region":{"startLine":43}}}],"partialFingerprints":{"codehealthFindingId/v1":"243979505771cc60c4f85cc860b7ffc3cca03b8406d10dcb77b32b841e6ba30f"}},{"ruleId":"D1","level":"warning","message":{"text":"loro_internal::encoding::json_schema::json::redact_op (cyclomatic 19): loro_internal::encoding::json_schema::json::redact_op has cyclomatic complexity 19 (threshold 15). To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Where every arm is uniform \u2014 the same kind of value, with no behaviour of its own \u2014 a table keyed by the case is the shorter form; wherever the arms carry different data or different behaviour, keep them as cases, because collapsing those trades an explicit, reviewable set of cases for nothing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/encoding/json_schema.rs"},"region":{"startLine":1791}}}],"partialFingerprints":{"codehealthFindingId/v1":"9400413eeb55d6e205dc00cf1cf05e2a568a5a0d9d266a415e5f8efb2886f522"}},{"ruleId":"D1","level":"warning","message":{"text":"loro_internal::jsonpath::jsonpath_impl::eval_expr (cyclomatic 19): loro_internal::jsonpath::jsonpath_impl::eval_expr has cyclomatic complexity 19 (threshold 15). To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Where every arm is uniform \u2014 the same kind of value, with no behaviour of its own \u2014 a table keyed by the case is the shorter form; wherever the arms carry different data or different behaviour, keep them as cases, because collapsing those trades an explicit, reviewable set of cases for nothing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/jsonpath/jsonpath_impl.rs"},"region":{"startLine":225}}}],"partialFingerprints":{"codehealthFindingId/v1":"ee3d1939489da2c724832d7608be50dda925006d7d3418cb858693b0b1de9578"}},{"ruleId":"D1","level":"warning","message":{"text":"sequence-index.visitVisibleIdRuns (cyclomatic 19): sequence-index.visitVisibleIdRuns 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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":3469}}}],"partialFingerprints":{"codehealthFindingId/v1":"f3d9e86953ac33387a4ea65e5048491ec2c60e69b22d4a1ce5d24ea160fa2101"}},{"ruleId":"D1","level":"warning","message":{"text":"LoroDoc.#emit (cyclomatic 19): LoroDoc.#emit has cyclomatic complexity 19 (threshold 15). 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, separate the cases: extract each independent 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 is NOT this file\u0027s highest cyclomatic complexity: document.decodedOperationToJson (cyclomatic 23) is higher and carries no row of its own \u2014 it was excluded as a flat dispatcher (a long switch/match over independent cases: many branches, almost no nesting), which this dimension does not treat as a refactor obligation. It is named here so the ranking you see in this file is not mistaken for the whole of it; the excluded method is counted neither in this dimension\u0027s figures nor in its score."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/document.ts"},"region":{"startLine":8781}}}],"partialFingerprints":{"codehealthFindingId/v1":"d708b5a60331f823c4e8a8aa644238cf31ba1439b68940a306c13d2c55b131f9"}},{"ruleId":"D1","level":"warning","message":{"text":"document.alignText (cyclomatic 19): document.alignText has cyclomatic complexity 19 (threshold 15). Of this number, 17 points are the body\u0027s own statements and 2 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. This is NOT this file\u0027s highest cyclomatic complexity: document.decodedOperationToJson (cyclomatic 23) is higher and carries no row of its own \u2014 it was excluded as a flat dispatcher (a long switch/match over independent cases: many branches, almost no nesting), which this dimension does not treat as a refactor obligation. It is named here so the ranking you see in this file is not mistaken for the whole of it; the excluded method is counted neither in this dimension\u0027s figures nor in its score."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/document.ts"},"region":{"startLine":11328}}}],"partialFingerprints":{"codehealthFindingId/v1":"8d794f7a487e98283e9316cb3dbb7e2e31e106322f54bfd85daab849c410e6cf"}},{"ruleId":"D1","level":"warning","message":{"text":"BTree::update_leaf_by_search (cyclomatic 18): BTree::update_leaf_by_search 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":"crates/generic-btree/src/lib.rs"},"region":{"startLine":1116}}}],"partialFingerprints":{"codehealthFindingId/v1":"0c1e8097f22d5cafd913b2d7191517cd5e1f679b8e0b2e056ca1479e42aa8687"}},{"ruleId":"D1","level":"warning","message":{"text":"RichtextState::find_best_insert_pos (cyclomatic 18): RichtextState::find_best_insert_pos 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":"crates/loro-internal/src/container/richtext/richtext_state.rs"},"region":{"startLine":1846}}}],"partialFingerprints":{"codehealthFindingId/v1":"883c6c127a4607df44701347c3f6b15cb39d6bf256b9d3ee0a2c91953b1b53f2"}},{"ruleId":"D1","level":"warning","message":{"text":"Delta::compose (cyclomatic 18): Delta::compose 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":"crates/loro-internal/src/delta/seq.rs"},"region":{"startLine":522}}}],"partialFingerprints":{"codehealthFindingId/v1":"8eb5987ad3e2fffb39f237ba90c22e485c4c3995665484ca6fd432f0980fc3c9"}},{"ruleId":"D1","level":"warning","message":{"text":"RichtextDiffCalculator::apply_crdt_op_to_tracker (cyclomatic 18): RichtextDiffCalculator::apply_crdt_op_to_tracker 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":"crates/loro-internal/src/diff_calc.rs"},"region":{"startLine":1276}}}],"partialFingerprints":{"codehealthFindingId/v1":"ebdc2edaadf3f42a90f4bebd0677f7288fa9e0ce478cb27785eaba10b2035900"}},{"ruleId":"D1","level":"warning","message":{"text":"TreeState::apply_diff_and_convert (cyclomatic 18): TreeState::apply_diff_and_convert 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":"crates/loro-internal/src/state/tree_state.rs"},"region":{"startLine":1196}}}],"partialFingerprints":{"codehealthFindingId/v1":"2cc1e052d7a8666769fda4f96fa1f7129faea7640766afc03e67f08a9894cfe0"}},{"ruleId":"D1","level":"warning","message":{"text":"LoroDoc.toJsonWithReplacer (cyclomatic 18): LoroDoc.toJsonWithReplacer has cyclomatic complexity 18 (threshold 15). Most of this is not in the body itself: 1 of the 18 points is its own statement and the rest belongs to 4 function items inside it that branch (visit, run, a function literal at line 1216, \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. This is NOT this file\u0027s highest cyclomatic complexity: document.decodedOperationToJson (cyclomatic 23) is higher and carries no row of its own \u2014 it was excluded as a flat dispatcher (a long switch/match over independent cases: many branches, almost no nesting), which this dimension does not treat as a refactor obligation. It is named here so the ranking you see in this file is not mistaken for the whole of it; the excluded method is counted neither in this dimension\u0027s figures nor in its score."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/document.ts"},"region":{"startLine":1207}}}],"partialFingerprints":{"codehealthFindingId/v1":"1b7a8f6de11dfb110ec55a13a782fdf8a644cd653af439e1bd225b166161e7d1"}},{"ruleId":"D1","level":"warning","message":{"text":"LoroDoc.#mergeTrailingTextDeletes (cyclomatic 18): LoroDoc.#mergeTrailingTextDeletes 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. This is NOT this file\u0027s highest cyclomatic complexity: document.decodedOperationToJson (cyclomatic 23) is higher and carries no row of its own \u2014 it was excluded as a flat dispatcher (a long switch/match over independent cases: many branches, almost no nesting), which this dimension does not treat as a refactor obligation. It is named here so the ranking you see in this file is not mistaken for the whole of it; the excluded method is counted neither in this dimension\u0027s figures nor in its score."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/document.ts"},"region":{"startLine":5033}}}],"partialFingerprints":{"codehealthFindingId/v1":"4246b798f571b1f7522efdf39a0598c5acce9265a44003ad6f7088d4a130e7b9"}},{"ruleId":"D1","level":"warning","message":{"text":"LoroDoc.#prepareSnapshotImport (cyclomatic 18): LoroDoc.#prepareSnapshotImport 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. This is NOT this file\u0027s highest cyclomatic complexity: document.decodedOperationToJson (cyclomatic 23) is higher and carries no row of its own \u2014 it was excluded as a flat dispatcher (a long switch/match over independent cases: many branches, almost no nesting), which this dimension does not treat as a refactor obligation. It is named here so the ranking you see in this file is not mistaken for the whole of it; the excluded method is counted neither in this dimension\u0027s figures nor in its score."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/document.ts"},"region":{"startLine":6459}}}],"partialFingerprints":{"codehealthFindingId/v1":"67181b76268acda6357f2c61d7eaebaf5f622464bdfc349346e93041f8040bcd"}},{"ruleId":"D1","level":"warning","message":{"text":"LoroDoc.#retainedContainerKeys (cyclomatic 18): LoroDoc.#retainedContainerKeys has cyclomatic complexity 18 (threshold 15). Of this number, 16 points are the body\u0027s own statements and 2 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. This is NOT this file\u0027s highest cyclomatic complexity: document.decodedOperationToJson (cyclomatic 23) is higher and carries no row of its own \u2014 it was excluded as a flat dispatcher (a long switch/match over independent cases: many branches, almost no nesting), which this dimension does not treat as a refactor obligation. It is named here so the ranking you see in this file is not mistaken for the whole of it; the excluded method is counted neither in this dimension\u0027s figures nor in its score."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/document.ts"},"region":{"startLine":8169}}}],"partialFingerprints":{"codehealthFindingId/v1":"b319814a60f79f8a5386ea445e9c55a11f4a90fec53d01dc4922739bc5953abf"}},{"ruleId":"D1","level":"warning","message":{"text":"document.containerPath (cyclomatic 18): document.containerPath 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. This is NOT this file\u0027s highest cyclomatic complexity: document.decodedOperationToJson (cyclomatic 23) is higher and carries no row of its own \u2014 it was excluded as a flat dispatcher (a long switch/match over independent cases: many branches, almost no nesting), which this dimension does not treat as a refactor obligation. It is named here so the ranking you see in this file is not mistaken for the whole of it; the excluded method is counted neither in this dimension\u0027s figures nor in its score."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/document.ts"},"region":{"startLine":11461}}}],"partialFingerprints":{"codehealthFindingId/v1":"4e4b519a24b13bf95a8da28d2b34ebefaccda8e6e85bbaae3b3ec82f17a472ac"}},{"ruleId":"D1","level":"warning","message":{"text":"LoroTree._positionFor (cyclomatic 18): LoroTree._positionFor has cyclomatic complexity 18 (threshold 15). Of this number, 16 points are the body\u0027s own statements and 2 belong to one function item 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":"loro-js/src/runtime/containers.ts"},"region":{"startLine":3023}}}],"partialFingerprints":{"codehealthFindingId/v1":"00142dac4af481c705720da9c93b42d05c698919743fa31bb81ce375d97197bb"}},{"ruleId":"D1","level":"warning","message":{"text":"SsTableIter::new_scan (cyclomatic 17): SsTableIter::new_scan 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":"crates/kv-store/src/sstable.rs"},"region":{"startLine":646}}}],"partialFingerprints":{"codehealthFindingId/v1":"50d3449f362b7af0d842c26d21b34076c3eeb5f850da23add4733471103b2671"}},{"ruleId":"D1","level":"warning","message":{"text":"RichtextDiffCalculator::seed_tracker_from_shallow_root (cyclomatic 17): RichtextDiffCalculator::seed_tracker_from_shallow_root 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":"crates/loro-internal/src/diff_calc.rs"},"region":{"startLine":1451}}}],"partialFingerprints":{"codehealthFindingId/v1":"ad91939fd19ed9654ec9bd5afae3bae1f1bb3ac66af02124396d44e5bec43648"}},{"ruleId":"D1","level":"warning","message":{"text":"LoroDoc::commit_internal_inner (cyclomatic 17): LoroDoc::commit_internal_inner 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":"crates/loro-internal/src/loro.rs"},"region":{"startLine":397}}}],"partialFingerprints":{"codehealthFindingId/v1":"c3274bdd0f716688fdd8f573ba0e44b4977a8e4a691a92a81b03ae076d4734f2"}},{"ruleId":"D1","level":"warning","message":{"text":"ChangeStore::build_root_history_names (cyclomatic 17): ChangeStore::build_root_history_names 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":"crates/loro-internal/src/oplog/change_store.rs"},"region":{"startLine":872}}}],"partialFingerprints":{"codehealthFindingId/v1":"87d03f4cb73786bbebdfc58283446960ec65fd4b4576aa377fc86c28ef0bdf92"}},{"ruleId":"D1","level":"warning","message":{"text":"DocState::get_alive_children_of (cyclomatic 17): DocState::get_alive_children_of has cyclomatic complexity 17 (threshold 15). To reduce it, break up the iteration: give each loop body a named function, and split a multi-phase loop into one function per phase so no single body carries the whole pipeline."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/state.rs"},"region":{"startLine":2027}}}],"partialFingerprints":{"codehealthFindingId/v1":"26360bb03f7562ff3717019910446b590ff213c5768cb23555d1b4b7b6a97b36"}},{"ruleId":"D1","level":"warning","message":{"text":"loro_internal::loro::isolated_scalar_root_batch (cyclomatic 17): loro_internal::loro::isolated_scalar_root_batch 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":"crates/loro-internal/src/loro.rs"},"region":{"startLine":4165}}}],"partialFingerprints":{"codehealthFindingId/v1":"5e9c4358727106bc7c7b46fc5e8b8c2be6e02003756f980abba47dda93389356"}},{"ruleId":"D1","level":"warning","message":{"text":"loro_internal::oplog::known_history::op_eq (cyclomatic 17): loro_internal::oplog::known_history::op_eq has cyclomatic complexity 17 (threshold 15). To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Where every arm is uniform \u2014 the same kind of value, with no behaviour of its own \u2014 a table keyed by the case is the shorter form; wherever the arms carry different data or different behaviour, keep them as cases, because collapsing those trades an explicit, reviewable set of cases for nothing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/oplog/known_history.rs"},"region":{"startLine":745}}}],"partialFingerprints":{"codehealthFindingId/v1":"62dc4f7dd428a5dd4e27eda8a21ac0c6e33bc1ed17a62b451c650789302a4f7c"}},{"ruleId":"D1","level":"warning","message":{"text":"loro_internal::undo::movable_list::prepare (cyclomatic 17): loro_internal::undo::movable_list::prepare 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":"crates/loro-internal/src/undo/movable_list.rs"},"region":{"startLine":590}}}],"partialFingerprints":{"codehealthFindingId/v1":"c6109ef7684bf1519aed49dde3f7b426b1c38f71db3c5193062654b7cc336db0"}},{"ruleId":"D1","level":"warning","message":{"text":"loro_internal::version::try_shrink_frontiers (cyclomatic 17): loro_internal::version::try_shrink_frontiers 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":"crates/loro-internal/src/version.rs"},"region":{"startLine":1009}}}],"partialFingerprints":{"codehealthFindingId/v1":"022cea5b8fafd7b029fe97b21ee7c55c9d8dcbedc0a70aa65e5e2349ec56e76f"}},{"ruleId":"D1","level":"warning","message":{"text":"loro_wasm::convert::js_value_to_loro_value (cyclomatic 17): loro_wasm::convert::js_value_to_loro_value 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":"crates/loro-wasm/src/convert.rs"},"region":{"startLine":661}}}],"partialFingerprints":{"codehealthFindingId/v1":"78c131d992447d98b19196279dbded18a33865c2df0339bc3369c9b46d8bda08"}},{"ruleId":"D1","level":"warning","message":{"text":"jsonpath.tokenizeFilter (cyclomatic 17): jsonpath.tokenizeFilter 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":"loro-js/src/runtime/jsonpath.ts"},"region":{"startLine":620}}}],"partialFingerprints":{"codehealthFindingId/v1":"c63ebf2c50e4ad3f4e4a169af8ff778d4ae9ad1235d3135ee0615d7c29ea615e"}},{"ruleId":"D1","level":"warning","message":{"text":"jsonpath.callFilterFunction (cyclomatic 17): jsonpath.callFilterFunction 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":"loro-js/src/runtime/jsonpath.ts"},"region":{"startLine":799}}}],"partialFingerprints":{"codehealthFindingId/v1":"050186f171a13b4f833204fe68866b7f84e8e5a38cf471a8f95d177e09fe390e"}},{"ruleId":"D1","level":"warning","message":{"text":"LoroDoc.#commit (cyclomatic 17): LoroDoc.#commit 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 is NOT this file\u0027s highest cyclomatic complexity: document.decodedOperationToJson (cyclomatic 23) is higher and carries no row of its own \u2014 it was excluded as a flat dispatcher (a long switch/match over independent cases: many branches, almost no nesting), which this dimension does not treat as a refactor obligation. It is named here so the ranking you see in this file is not mistaken for the whole of it; the excluded method is counted neither in this dimension\u0027s figures nor in its score."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/document.ts"},"region":{"startLine":506}}}],"partialFingerprints":{"codehealthFindingId/v1":"fd6d847b8d30b3cedf4b65da47c6a61a8fef33ad3d82b917b0a762aa81a152cd"}},{"ruleId":"D1","level":"warning","message":{"text":"LoroDoc.#prepareSnapshotTransition (cyclomatic 17): LoroDoc.#prepareSnapshotTransition 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. This is NOT this file\u0027s highest cyclomatic complexity: document.decodedOperationToJson (cyclomatic 23) is higher and carries no row of its own \u2014 it was excluded as a flat dispatcher (a long switch/match over independent cases: many branches, almost no nesting), which this dimension does not treat as a refactor obligation. It is named here so the ranking you see in this file is not mistaken for the whole of it; the excluded method is counted neither in this dimension\u0027s figures nor in its score."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/document.ts"},"region":{"startLine":6526}}}],"partialFingerprints":{"codehealthFindingId/v1":"8e08e185710e581d8053a24b5f6a564ace058817db316c71b4f538210938d7aa"}},{"ruleId":"D1","level":"warning","message":{"text":"LoroDoc.#validateDeferredFrontierBlocks (cyclomatic 17): LoroDoc.#validateDeferredFrontierBlocks has cyclomatic complexity 17 (threshold 15). Of this number, 16 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top. This is NOT this file\u0027s highest cyclomatic complexity: document.decodedOperationToJson (cyclomatic 23) is higher and carries no row of its own \u2014 it was excluded as a flat dispatcher (a long switch/match over independent cases: many branches, almost no nesting), which this dimension does not treat as a refactor obligation. It is named here so the ranking you see in this file is not mistaken for the whole of it; the excluded method is counted neither in this dimension\u0027s figures nor in its score."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/document.ts"},"region":{"startLine":7118}}}],"partialFingerprints":{"codehealthFindingId/v1":"2965a82c42a1db49fb48bffdeec9f2e0576c2ee59ac106392253840ff6ae8682"}},{"ruleId":"D1","level":"warning","message":{"text":"document.subtractSequenceIdRuns (cyclomatic 17): document.subtractSequenceIdRuns 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. This is NOT this file\u0027s highest cyclomatic complexity: document.decodedOperationToJson (cyclomatic 23) is higher and carries no row of its own \u2014 it was excluded as a flat dispatcher (a long switch/match over independent cases: many branches, almost no nesting), which this dimension does not treat as a refactor obligation. It is named here so the ranking you see in this file is not mistaken for the whole of it; the excluded method is counted neither in this dimension\u0027s figures nor in its score."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/document.ts"},"region":{"startLine":10964}}}],"partialFingerprints":{"codehealthFindingId/v1":"1b48006d303f406b6123d6d0f2141f6e8d8b291a51ad606869cf306653fba236"}},{"ruleId":"D1","level":"warning","message":{"text":"LoroText.iter (cyclomatic 17): LoroText.iter has cyclomatic complexity 17 (threshold 15). Most of this is not in the body itself: 3 of the 17 points are its own statements and the rest belongs to 3 function items inside it that branch (a function literal at line 1497, append, a function literal at line 1537). 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":"loro-js/src/runtime/containers.ts"},"region":{"startLine":1466}}}],"partialFingerprints":{"codehealthFindingId/v1":"4c90bcc2b85dec799e1722364ae6b2c5a4f1319e59903a70a886f977669a98e7"}},{"ruleId":"D1","level":"warning","message":{"text":"containers.fugueInsertion (cyclomatic 17): containers.fugueInsertion 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":"loro-js/src/runtime/containers.ts"},"region":{"startLine":3598}}}],"partialFingerprints":{"codehealthFindingId/v1":"f73894aadee659392fddb0686a8229b61bd6cce2a23ee815dc940597508cb1f0"}},{"ruleId":"D1","level":"warning","message":{"text":"LoroValue::apply_diff_shallow (cyclomatic 16): LoroValue::apply_diff_shallow has cyclomatic complexity 16 (threshold 15). To reduce it, break up the iteration: give each loop body a named function, and split a multi-phase loop into one function per phase so no single body carries the whole pipeline."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/value.rs"},"region":{"startLine":253}}}],"partialFingerprints":{"codehealthFindingId/v1":"7d2c82f40b383651460b855abbf0d8921037dbed11d4ef15e0b6c7bfdf6a8871"}},{"ruleId":"D1","level":"warning","message":{"text":"RichtextState::slice_delta (cyclomatic 16): RichtextState::slice_delta 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":"crates/loro-internal/src/container/richtext/richtext_state.rs"},"region":{"startLine":2149}}}],"partialFingerprints":{"codehealthFindingId/v1":"d170089caf457f5b3be3a7f145acee6c9180ce7a490a4e16d342c64e429942aa"}},{"ruleId":"D1","level":"warning","message":{"text":"DagCausalIter::next (cyclomatic 16): DagCausalIter::next 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":"crates/loro-internal/src/dag/iter.rs"},"region":{"startLine":295}}}],"partialFingerprints":{"codehealthFindingId/v1":"f07b757b7cf3b6ebaddd9c9e86833cbc2db5c4135919b56df56f3e92335bf226"}},{"ruleId":"D1","level":"warning","message":{"text":"MovableListDiffCalculator::apply_change (cyclomatic 16): MovableListDiffCalculator::apply_change 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":"crates/loro-internal/src/diff_calc.rs"},"region":{"startLine":2100}}}],"partialFingerprints":{"codehealthFindingId/v1":"ddbe60be2733c12cb1fab2ab04d729e41b49646f6280f648eadfefa5381e9f77"}},{"ruleId":"D1","level":"warning","message":{"text":"LoroDoc::import_blobs_as_batch (cyclomatic 16): LoroDoc::import_blobs_as_batch 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":"crates/loro-internal/src/loro.rs"},"region":{"startLine":3086}}}],"partialFingerprints":{"codehealthFindingId/v1":"e144be3c7b962d9437c0d63a137476c7fc4a9edf365dd221fd03053aeab666a5"}},{"ruleId":"D1","level":"warning","message":{"text":"InnerContent::visit_created_children (cyclomatic 16): InnerContent::visit_created_children has cyclomatic complexity 16 (threshold 15). To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Where every arm is uniform \u2014 the same kind of value, with no behaviour of its own \u2014 a table keyed by the case is the shorter form; wherever the arms carry different data or different behaviour, keep them as cases, because collapsing those trades an explicit, reviewable set of cases for nothing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/op/content.rs"},"region":{"startLine":28}}}],"partialFingerprints":{"codehealthFindingId/v1":"dab44a9062ed6be2e62c89cda83279a9b48de0be052deb440553511700e5473b"}},{"ruleId":"D1","level":"warning","message":{"text":"AppDag::try_ensure_vv_for (cyclomatic 16): AppDag::try_ensure_vv_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":"crates/loro-internal/src/oplog/loro_dag.rs"},"region":{"startLine":1161}}}],"partialFingerprints":{"codehealthFindingId/v1":"0a9501557f056ba9ea88095e3df03baa973111b912c8634f33b5c847fa6bf3cf"}},{"ruleId":"D1","level":"warning","message":{"text":"ListState::delete_range (cyclomatic 16): ListState::delete_range 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":"crates/loro-internal/src/state/list_state.rs"},"region":{"startLine":397}}}],"partialFingerprints":{"codehealthFindingId/v1":"a389bf251d2ecbcdc666e93b230bcb735dabf734ab746f9308ec0156087d9323"}},{"ruleId":"D1","level":"warning","message":{"text":"loro_internal::oplog::known_history::list_op_eq (cyclomatic 16): loro_internal::oplog::known_history::list_op_eq 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":"crates/loro-internal/src/oplog/known_history.rs"},"region":{"startLine":803}}}],"partialFingerprints":{"codehealthFindingId/v1":"60f638ff76374dc3b96f0d9ebc9f6c38454cdf61bc6f624e3ae4790faf5ab377"}},{"ruleId":"D1","level":"warning","message":{"text":"loro_internal::state::richtext_state::snapshot::redact_dead_style_values (cyclomatic 16): loro_internal::state::richtext_state::snapshot::redact_dead_style_values 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":"crates/loro-internal/src/state/richtext_state.rs"},"region":{"startLine":1403}}}],"partialFingerprints":{"codehealthFindingId/v1":"089ad4002fab43c2550a0e1558eb4eaf130af939026ed2429b3b888906990f9d"}},{"ruleId":"D1","level":"warning","message":{"text":"index.LoroDoc.toJsonWithReplacer (cyclomatic 16): index.LoroDoc.toJsonWithReplacer has cyclomatic complexity 16 (threshold 15). Most of this is not in the body itself: 1 of the 16 points is its own statement and the rest belongs to 2 function items inside it that branch (m, run). Those helpers are already separate functions, so extracting the branching again is not available. To reduce it, move them out of the body to the enclosing scope, where each is measured, reviewed and tested on its own, and reduce whichever one then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-wasm/index.ts"},"region":{"startLine":337}}}],"partialFingerprints":{"codehealthFindingId/v1":"986b39b3fdc8ee1734135de921c4a5106d4c69a73034e3e8595ca7adef75e880"}},{"ruleId":"D1","level":"warning","message":{"text":"SequenceIndex.compact (cyclomatic 16): SequenceIndex.compact 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 3 function items inside it that branch (flushElements, appendSpan, a function literal at line 1768). 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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":1734}}}],"partialFingerprints":{"codehealthFindingId/v1":"0c41eb901249039f180ec3c763100c53f6b911ce686e279824646311e4679f08"}},{"ruleId":"D1","level":"warning","message":{"text":"SequenceIndex.#appendToPreviousNodeWithLineBreaks (cyclomatic 16): SequenceIndex.#appendToPreviousNodeWithLineBreaks 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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":2143}}}],"partialFingerprints":{"codehealthFindingId/v1":"bf05dc69a78a928d1e5688e3e7c552172e9d58254b8d9d3bf5fc28d3c291fab9"}},{"ruleId":"D1","level":"warning","message":{"text":"SequenceIndex.#finishSpanAppend (cyclomatic 16): SequenceIndex.#finishSpanAppend 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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":2237}}}],"partialFingerprints":{"codehealthFindingId/v1":"b90663fa3141a2391077904e355fdc00ef0d5be36ea17caec3f81c7944389036"}},{"ruleId":"D1","level":"warning","message":{"text":"document.collectJsonPeers (cyclomatic 16): document.collectJsonPeers has cyclomatic complexity 16 (threshold 15). Of this number, 13 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. This is NOT this file\u0027s highest cyclomatic complexity: document.decodedOperationToJson (cyclomatic 23) is higher and carries no row of its own \u2014 it was excluded as a flat dispatcher (a long switch/match over independent cases: many branches, almost no nesting), which this dimension does not treat as a refactor obligation. It is named here so the ranking you see in this file is not mistaken for the whole of it; the excluded method is counted neither in this dimension\u0027s figures nor in its score."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/document.ts"},"region":{"startLine":9881}}}],"partialFingerprints":{"codehealthFindingId/v1":"d9a3e979a5700223ab2369799598618baa19093b7c23cd0d288dac7a40051384"}},{"ruleId":"D1","level":"warning","message":{"text":"document.jsonValueToChangeLoroValue (cyclomatic 16): document.jsonValueToChangeLoroValue has cyclomatic complexity 16 (threshold 15). Of this number, 15 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top. This is NOT this file\u0027s highest cyclomatic complexity: document.decodedOperationToJson (cyclomatic 23) is higher and carries no row of its own \u2014 it was excluded as a flat dispatcher (a long switch/match over independent cases: many branches, almost no nesting), which this dimension does not treat as a refactor obligation. It is named here so the ranking you see in this file is not mistaken for the whole of it; the excluded method is counted neither in this dimension\u0027s figures nor in its score."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/document.ts"},"region":{"startLine":10439}}}],"partialFingerprints":{"codehealthFindingId/v1":"46c82f4df6bfb12e04ae73d2aa8b797f4d92760ba083cc8742ee38db411be4a1"}},{"ruleId":"D1","level":"warning","message":{"text":"ephemeral.valueToEncoded (cyclomatic 16): ephemeral.valueToEncoded has cyclomatic complexity 16 (threshold 15). Of this number, 15 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":"loro-js/src/runtime/ephemeral.ts"},"region":{"startLine":539}}}],"partialFingerprints":{"codehealthFindingId/v1":"9dd84bb8000f2e8824efa961b74fabb4fcdc793c9be3d2fb0d7a305bc3b01a92"}},{"ruleId":"D2","level":"warning","message":{"text":"LoroDoc.#importBlob (cognitive 145): LoroDoc.#importBlob has cognitive complexity 145 (threshold 15). Drivers by points: if/else 33 (80 pts), loops 8 (26 pts), boolean chains 20, ternaries 8 (19 pts) (nesting depth added 76). Of this number, 142 points are the body\u0027s own statements and 3 belong to one function item 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. This file is where this pass\u0027s cognitive complexity CONCENTRATES: loro-js/src/runtime/document.ts holds 56 of the 301 methods over the threshold \u2014 including the worst \u2014 and 1420 of the 5127 points over it (28%), 4.3\u00D7 the next-largest file (crates/loro-internal/src/loro.rs at 332). No single row can show this, because each is measured only against the threshold: reducing this one file moves this dimension further than any other file in the repository."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/document.ts"},"region":{"startLine":792}}}],"partialFingerprints":{"codehealthFindingId/v1":"e5ccc6a43595adeed5b7dc4513c5fbd8409cf5dd8fe95b70345a22447efac483"}},{"ruleId":"D2","level":"warning","message":{"text":"RichtextState::apply_diff (cognitive 127): RichtextState::apply_diff has cognitive complexity 127 (threshold 15). Drivers by points: if/else 26 (75 pts), match/switch 6 (26 pts), loops 7 (22 pts), boolean chains 4 (nesting depth added 84). 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":"crates/loro-internal/src/state/richtext_state.rs"},"region":{"startLine":627}}}],"partialFingerprints":{"codehealthFindingId/v1":"da6a50e66ffff0320c4fff27491342b0ae9a5dddb70b9e648eecef4e613ec282"}},{"ruleId":"D2","level":"warning","message":{"text":"loro_internal::dag::_find_meet_and_mode (cognitive 123): loro_internal::dag::_find_meet_and_mode has cognitive complexity 123 (threshold 15). Drivers by points: if/else 75 (147 pts), loops 19 (34 pts), boolean chains 10 (nesting depth added 87). To reduce it, split the body into named stages: move each independent 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: 2 other methods here (loro_internal::dag::_find_meet_and_mode::all_tips_covered_by_ancestors, loro_internal::dag::_find_meet_and_mode::new_region_after_all_left_heads) 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":"crates/loro-internal/src/dag.rs"},"region":{"startLine":740}}}],"partialFingerprints":{"codehealthFindingId/v1":"3a9c3043d118182e5a30e9ee17df05f71dad0a16e7cbd6d0a74115bc1685e793"}},{"ruleId":"D2","level":"warning","message":{"text":"LoroDoc.#applyVersionTransition (cognitive 123): LoroDoc.#applyVersionTransition has cognitive complexity 123 (threshold 15). Drivers by points: if/else 45 (116 pts), loops 24 (49 pts), ternaries 11 (34 pts), boolean chains 22 (nesting depth added 119). To reduce it, split the body into named stages: move each independent 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 (LoroDoc.#applyVersionTransition::collect) 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. This file is where this pass\u0027s cognitive complexity CONCENTRATES: loro-js/src/runtime/document.ts holds 56 of the 301 methods over the threshold \u2014 including the worst \u2014 and 1420 of the 5127 points over it (28%), 4.3\u00D7 the next-largest file (crates/loro-internal/src/loro.rs at 332). No single row can show this, because each is measured only against the threshold: reducing this one file moves this dimension further than any other file in the repository."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/document.ts"},"region":{"startLine":5836}}}],"partialFingerprints":{"codehealthFindingId/v1":"915b2d644e1030aec057e107e2b5e59e58cab93769ca9ca02ee4557493c06bb4"}},{"ruleId":"D2","level":"warning","message":{"text":"LoroDoc::check_apply_diff_creates_no_unknown_container (cognitive 122): LoroDoc::check_apply_diff_creates_no_unknown_container has cognitive complexity 122 (threshold 15). Drivers by points: if/else 24 (75 pts), loops 7 (22 pts), match/switch 6 (16 pts), boolean chains 9 (nesting depth added 76). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/loro.rs"},"region":{"startLine":2592}}}],"partialFingerprints":{"codehealthFindingId/v1":"729f5d155e91d8bab92224ee0d15fa87062f2daff0d2c7b108299c739a91f26b"}},{"ruleId":"D2","level":"warning","message":{"text":"loro_internal::encoding::json_schema::encode_change (cognitive 98): loro_internal::encoding::json_schema::encode_change has cognitive complexity 98 (threshold 15). Drivers by points: if/else 17 (61 pts), match/switch 11 (36 pts), loops 1 (nesting depth added 69). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/encoding/json_schema.rs"},"region":{"startLine":291}}}],"partialFingerprints":{"codehealthFindingId/v1":"8b5887ae04280fc44fd5563ec5991cd0ac054bb6d22649f6752c282e10d8fe22"}},{"ruleId":"D2","level":"warning","message":{"text":"MovableListState::apply_diff_and_convert (cognitive 97): MovableListState::apply_diff_and_convert has cognitive complexity 97 (threshold 15). Drivers by points: if/else 23 (80 pts), boolean chains 7, match/switch 3 (6 pts), loops 4 (nesting depth added 60). 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":"crates/loro-internal/src/state/movable_list_state.rs"},"region":{"startLine":1092}}}],"partialFingerprints":{"codehealthFindingId/v1":"e160141d1d0fa46cd9826f0fa711e19b38f1b4fb313439c2cee5c6fee46153aa"}},{"ruleId":"D2","level":"warning","message":{"text":"LoroDoc.#applyMovableListMoves (cognitive 95): LoroDoc.#applyMovableListMoves has cognitive complexity 95 (threshold 15). Drivers by points: if/else 28 (60 pts), loops 10 (16 pts), ternaries 4 (11 pts), boolean chains 8 (nesting depth added 45). Of this number, 90 points are the body\u0027s own statements and 5 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. This file is where this pass\u0027s cognitive complexity CONCENTRATES: loro-js/src/runtime/document.ts holds 56 of the 301 methods over the threshold \u2014 including the worst \u2014 and 1420 of the 5127 points over it (28%), 4.3\u00D7 the next-largest file (crates/loro-internal/src/loro.rs at 332). No single row can show this, because each is measured only against the threshold: reducing this one file moves this dimension further than any other file in the repository."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/document.ts"},"region":{"startLine":1476}}}],"partialFingerprints":{"codehealthFindingId/v1":"6e8f7e1f70a5692e4668e6f238e1d0f6988d97f6b03cbf9592b9b94bda189787"}},{"ruleId":"D2","level":"warning","message":{"text":"LoroDoc.#alignFullState (cognitive 85): LoroDoc.#alignFullState has cognitive complexity 85 (threshold 15). Drivers by points: if/else 22 (50 pts), loops 9 (18 pts), boolean chains 15, ternaries 1 (2 pts) (nesting depth added 38). Of this number, 80 points are the body\u0027s own statements and 5 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. This file is where this pass\u0027s cognitive complexity CONCENTRATES: loro-js/src/runtime/document.ts holds 56 of the 301 methods over the threshold \u2014 including the worst \u2014 and 1420 of the 5127 points over it (28%), 4.3\u00D7 the next-largest file (crates/loro-internal/src/loro.rs at 332). No single row can show this, because each is measured only against the threshold: reducing this one file moves this dimension further than any other file in the repository."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/document.ts"},"region":{"startLine":2127}}}],"partialFingerprints":{"codehealthFindingId/v1":"97ba31097f0304984089f9e0fdf7bbb5842b86634cfba455756f24438c8f14df"}},{"ruleId":"D2","level":"warning","message":{"text":"LoroDoc.#applyVersionTransition::collect (cognitive 84): LoroDoc.#applyVersionTransition::collect has cognitive complexity 84 (threshold 15). Drivers by points: if/else 20 (61 pts), boolean chains 12, loops 4 (11 pts) (nesting depth added 48). To reduce it, split the body into named stages: move each independent 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 (LoroDoc.#applyVersionTransition) 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. This file is where this pass\u0027s cognitive complexity CONCENTRATES: loro-js/src/runtime/document.ts holds 56 of the 301 methods over the threshold \u2014 including the worst \u2014 and 1420 of the 5127 points over it (28%), 4.3\u00D7 the next-largest file (crates/loro-internal/src/loro.rs at 332). No single row can show this, because each is measured only against the threshold: reducing this one file moves this dimension further than any other file in the repository."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/document.ts"},"region":{"startLine":5891}}}],"partialFingerprints":{"codehealthFindingId/v1":"45ce70d5e9ab1aca5a945872f3eff99cdeb431ab62d75a10c0608d15bf0758bc"}},{"ruleId":"D2","level":"warning","message":{"text":"loro_internal::dag::_walk_to_meet (cognitive 82): loro_internal::dag::_walk_to_meet has cognitive complexity 82 (threshold 15). Drivers by points: if/else 21 (58 pts), match/switch 7 (14 pts), loops 5 (7 pts), boolean chains 3 (nesting depth added 46). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/dag.rs"},"region":{"startLine":442}}}],"partialFingerprints":{"codehealthFindingId/v1":"256e1bd944ac83889419e0bcdc9ae0be4a05202bf7c538da422d508c9ad8ac61"}},{"ruleId":"D2","level":"warning","message":{"text":"DiffCalculator::try_calc_diff_internal (cognitive 79): DiffCalculator::try_calc_diff_internal has cognitive complexity 79 (threshold 15). Drivers by points: if/else 24 (65 pts), loops 6 (9 pts), boolean chains 4, match/switch 1 (nesting depth added 44). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/diff_calc.rs"},"region":{"startLine":186}}}],"partialFingerprints":{"codehealthFindingId/v1":"5c1d3a374f308ac09cb6b49fdd027efe4a467c79c538339ec08c9421d4b800c0"}},{"ruleId":"D2","level":"warning","message":{"text":"jsonpath.applySelector (cognitive 77): jsonpath.applySelector has cognitive complexity 77 (threshold 15). Drivers by points: if/else 11 (40 pts), loops 9 (25 pts), ternaries 2 (9 pts), boolean chains 2, match/switch 1 (nesting depth added 52). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/jsonpath.ts"},"region":{"startLine":281}}}],"partialFingerprints":{"codehealthFindingId/v1":"9a372d53e0faba6af11887cbf96f0df4cb389abd43d114b3aa4bbcf253b655dd"}},{"ruleId":"D2","level":"warning","message":{"text":"loro_internal::encoding::json_schema::decode_op (cognitive 76): loro_internal::encoding::json_schema::decode_op has cognitive complexity 76 (threshold 15). Drivers by points: match/switch 15 (35 pts), if/else 8 (33 pts), loops 2 (8 pts) (nesting depth added 51). To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/encoding/json_schema.rs"},"region":{"startLine":780}}}],"partialFingerprints":{"codehealthFindingId/v1":"d5531a034e7d7a6004b2da127ccb3b46afe6b2dc75181ea90a83d05139abad0c"}},{"ruleId":"D2","level":"warning","message":{"text":"LoroDoc.#prepareEvent (cognitive 75): LoroDoc.#prepareEvent has cognitive complexity 75 (threshold 15). Drivers by points: if/else 24 (47 pts), ternaries 3 (11 pts), loops 3 (9 pts), boolean chains 8 (nesting depth added 37). Of this number, 52 points are the body\u0027s own statements and 23 belong to 3 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. This file is where this pass\u0027s cognitive complexity CONCENTRATES: loro-js/src/runtime/document.ts holds 56 of the 301 methods over the threshold \u2014 including the worst \u2014 and 1420 of the 5127 points over it (28%), 4.3\u00D7 the next-largest file (crates/loro-internal/src/loro.rs at 332). No single row can show this, because each is measured only against the threshold: reducing this one file moves this dimension further than any other file in the repository."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/document.ts"},"region":{"startLine":4686}}}],"partialFingerprints":{"codehealthFindingId/v1":"9a5e56dff470aaf616bc2b974b4dff4b710d2a12acb301648421b404eb1729b5"}},{"ruleId":"D2","level":"warning","message":{"text":"RichtextState::apply_diff_and_convert (cognitive 74): RichtextState::apply_diff_and_convert has cognitive complexity 74 (threshold 15). Drivers by points: if/else 8 (33 pts), match/switch 5 (21 pts), loops 5 (20 pts) (nesting depth added 56). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/state/richtext_state.rs"},"region":{"startLine":391}}}],"partialFingerprints":{"codehealthFindingId/v1":"6cc83d8978916fdc262d79e3531f245926b6a0a68e2ed9c718f3362c82585923"}},{"ruleId":"D2","level":"warning","message":{"text":"LoroDoc.#canTransitionRecords (cognitive 73): LoroDoc.#canTransitionRecords has cognitive complexity 73 (threshold 15). Drivers by points: if/else 22 (56 pts), loops 5 (9 pts), boolean chains 8 (nesting depth added 38). Of this number, 71 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. This file is where this pass\u0027s cognitive complexity CONCENTRATES: loro-js/src/runtime/document.ts holds 56 of the 301 methods over the threshold \u2014 including the worst \u2014 and 1420 of the 5127 points over it (28%), 4.3\u00D7 the next-largest file (crates/loro-internal/src/loro.rs at 332). No single row can show this, because each is measured only against the threshold: reducing this one file moves this dimension further than any other file in the repository."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/document.ts"},"region":{"startLine":5733}}}],"partialFingerprints":{"codehealthFindingId/v1":"655c5ccb8b4251d92348fe2c6bb6521def56df9f898b3a1e63fa8a844dfae110"}},{"ruleId":"D2","level":"warning","message":{"text":"LoroDoc.#containerState (cognitive 72): LoroDoc.#containerState has cognitive complexity 72 (threshold 15). Drivers by points: if/else 22 (43 pts), loops 8 (17 pts), ternaries 4 (11 pts), boolean chains 1 (nesting depth added 37). Of this number, 43 points are the body\u0027s own statements and 29 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. This file is where this pass\u0027s cognitive complexity CONCENTRATES: loro-js/src/runtime/document.ts holds 56 of the 301 methods over the threshold \u2014 including the worst \u2014 and 1420 of the 5127 points over it (28%), 4.3\u00D7 the next-largest file (crates/loro-internal/src/loro.rs at 332). No single row can show this, because each is measured only against the threshold: reducing this one file moves this dimension further than any other file in the repository."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/document.ts"},"region":{"startLine":8234}}}],"partialFingerprints":{"codehealthFindingId/v1":"f96aa08b1fef584aca244f48fc751dc17077052229394e600ddd36b081decbe0"}},{"ruleId":"D2","level":"warning","message":{"text":"DocState::apply_diff (cognitive 70): DocState::apply_diff has cognitive complexity 70 (threshold 15). Drivers by points: if/else 24 (51 pts), loops 5 (9 pts), boolean chains 8, match/switch 1 (2 pts) (nesting depth added 32). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/state.rs"},"region":{"startLine":664}}}],"partialFingerprints":{"codehealthFindingId/v1":"5826f2814e2e247a3cdb4868b562fd9cb7e5dbe94d55b3978c754d55b77fe733"}},{"ruleId":"D2","level":"warning","message":{"text":"BTree::handle_lack_single_layer (cognitive 69): BTree::handle_lack_single_layer has cognitive complexity 69 (threshold 15). Drivers by points: loops 11 (42 pts), if/else 13 (23 pts), match/switch 2 (4 pts) (nesting depth added 43). To reduce it, break up the iteration: give each loop body a named function, and split a multi-phase loop into one function per phase so no single body carries the whole pipeline."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/generic-btree/src/lib.rs"},"region":{"startLine":2004}}}],"partialFingerprints":{"codehealthFindingId/v1":"bb8c8724e13c4bdbd54b04ce1b539f4cd3072d78078cef350cc848d3dc0d5809"}},{"ruleId":"D2","level":"warning","message":{"text":"document.jsonOperationToDecoded (cognitive 69): document.jsonOperationToDecoded has cognitive complexity 69 (threshold 15). Drivers by points: if/else 22 (41 pts), ternaries 9 (19 pts), boolean chains 9 (nesting depth added 29). Of this number, 64 points are the body\u0027s own statements and 5 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. This file is where this pass\u0027s cognitive complexity CONCENTRATES: loro-js/src/runtime/document.ts holds 56 of the 301 methods over the threshold \u2014 including the worst \u2014 and 1420 of the 5127 points over it (28%), 4.3\u00D7 the next-largest file (crates/loro-internal/src/loro.rs at 332). No single row can show this, because each is measured only against the threshold: reducing this one file moves this dimension further than any other file in the repository."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/document.ts"},"region":{"startLine":10197}}}],"partialFingerprints":{"codehealthFindingId/v1":"968cd8399051d646abacb48b6f294e280c520333701e8547a20b9d9d9bdc5c14"}},{"ruleId":"D2","level":"warning","message":{"text":"LoroDoc::apply_diff_with_movable_undo (cognitive 67): LoroDoc::apply_diff_with_movable_undo has cognitive complexity 67 (threshold 15). Drivers by points: if/else 23 (47 pts), match/switch 3 (11 pts), loops 3 (5 pts), boolean chains 4 (nesting depth added 34). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/loro.rs"},"region":{"startLine":2182}}}],"partialFingerprints":{"codehealthFindingId/v1":"b657582671bacf83e1eb572d8156830e290b85b8f6d585c29c6e33285d21ba4e"}},{"ruleId":"D2","level":"warning","message":{"text":"AppDag::try_ensure_vv_for (cognitive 65): AppDag::try_ensure_vv_for has cognitive complexity 65 (threshold 15). Drivers by points: if/else 13 (51 pts), loops 4 (14 pts) (nesting depth added 48). 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":"crates/loro-internal/src/oplog/loro_dag.rs"},"region":{"startLine":1161}}}],"partialFingerprints":{"codehealthFindingId/v1":"05241ad305a0ac2f078951245fdba0d1a0fa88ee2bc4e81d3a29ea6ea2315bb8"}},{"ruleId":"D2","level":"warning","message":{"text":"DocState::get_value_by_path (cognitive 65): DocState::get_value_by_path has cognitive complexity 65 (threshold 15). Drivers by points: if/else 21 (47 pts), match/switch 7 (17 pts), loops 1 (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":"crates/loro-internal/src/state.rs"},"region":{"startLine":2456}}}],"partialFingerprints":{"codehealthFindingId/v1":"71d2bc5e313dd4ad994bd06713c9da1ffd80557409d4715e23466a2b673dc751"}},{"ruleId":"D2","level":"warning","message":{"text":"CrdtRope::insert (cognitive 64): CrdtRope::insert has cognitive complexity 64 (threshold 15). Drivers by points: if/else 22 (52 pts), match/switch 2 (8 pts), loops 2 (3 pts), boolean chains 1 (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":"crates/loro-internal/src/container/richtext/tracker/crdt_rope.rs"},"region":{"startLine":63}}}],"partialFingerprints":{"codehealthFindingId/v1":"938b42bfab67ac136eb01388780f8f570d5daf323e34fa008a9f48168ec0fc35"}},{"ruleId":"D2","level":"warning","message":{"text":"LoroDoc::import_changes_and_apply_delta_to_state_if_needed (cognitive 62): LoroDoc::import_changes_and_apply_delta_to_state_if_needed has cognitive complexity 62 (threshold 15). Drivers by points: if/else 22 (41 pts), match/switch 8 (13 pts), boolean chains 5, loops 1 (3 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":"crates/loro-internal/src/loro.rs"},"region":{"startLine":973}}}],"partialFingerprints":{"codehealthFindingId/v1":"c05be30cedc1e7aad5eb844d25b765c373a649cd5fa36d41055a901489f3af10"}},{"ruleId":"D2","level":"warning","message":{"text":"Model::undo (cognitive 62): Model::undo has cognitive complexity 62 (threshold 15). Drivers by points: if/else 15 (49 pts), match/switch 3 (6 pts), boolean chains 4, loops 3 (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":"crates/loro-internal/src/undo/movable_list.rs"},"region":{"startLine":470}}}],"partialFingerprints":{"codehealthFindingId/v1":"e076652d705032fcb7c75e156983b20959e16f2c08ed55920ac57e9422f6d94a"}},{"ruleId":"D2","level":"warning","message":{"text":"Handler::apply_diff (cognitive 61): Handler::apply_diff has cognitive complexity 61 (threshold 15). Drivers by points: if/else 11 (35 pts), match/switch 9 (18 pts), loops 3 (6 pts), boolean chains 2 (nesting depth added 36). Of this number, 57 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":"crates/loro-internal/src/handler.rs"},"region":{"startLine":1368}}}],"partialFingerprints":{"codehealthFindingId/v1":"9079702cf9354b3768d818aafdf99b66afcdb21b545ef11f5ebe10c802fa99da"}},{"ruleId":"D2","level":"warning","message":{"text":"loro_internal::jsonpath::jsonpath_impl::apply_selectors (cognitive 60): loro_internal::jsonpath::jsonpath_impl::apply_selectors has cognitive complexity 60 (threshold 15). Drivers by points: if/else 18 (49 pts), loops 3 (9 pts), match/switch 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":"crates/loro-internal/src/jsonpath/jsonpath_impl.rs"},"region":{"startLine":113}}}],"partialFingerprints":{"codehealthFindingId/v1":"55ede074b8982797159d8207206bfcffb125a33fc6acf2098a5e940d12634fd3"}},{"ruleId":"D2","level":"warning","message":{"text":"LoroDoc.#completeTreeRevivals (cognitive 59): LoroDoc.#completeTreeRevivals has cognitive complexity 59 (threshold 15). Drivers by points: if/else 18 (41 pts), loops 10 (13 pts), boolean chains 5 (nesting depth added 26). Of this number, 49 points are the body\u0027s own statements and 10 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. This file is where this pass\u0027s cognitive complexity CONCENTRATES: loro-js/src/runtime/document.ts holds 56 of the 301 methods over the threshold \u2014 including the worst \u2014 and 1420 of the 5127 points over it (28%), 4.3\u00D7 the next-largest file (crates/loro-internal/src/loro.rs at 332). No single row can show this, because each is measured only against the threshold: reducing this one file moves this dimension further than any other file in the repository."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/document.ts"},"region":{"startLine":1650}}}],"partialFingerprints":{"codehealthFindingId/v1":"21a69c84240767df77c065a0486c2d296bf3ad986a40864f5a8ee3e87fdd0fa2"}},{"ruleId":"D2","level":"warning","message":{"text":"loro_internal::diff::diff_impl::dj_diff (cognitive 56): loro_internal::diff::diff_impl::dj_diff has cognitive complexity 56 (threshold 15). Drivers by points: if/else 21 (46 pts), boolean chains 4, loops 3, match/switch 2 (3 pts) (nesting depth added 26). This file\u0027s own header attributes it to another copyright holder, so it is code this repository carries rather than code it wrote: restructuring the body in place forks it from upstream and turns every future re-sync into a manual merge. The performable moves are to leave the body as close to its upstream form as possible and keep it behind a narrow interface of your own, and to re-sync it when upstream changes \u2014 or, if it has already diverged far enough that you maintain it here, adopt it deliberately and then split the body into named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/diff/diff_impl.rs"},"region":{"startLine":364}}}],"partialFingerprints":{"codehealthFindingId/v1":"3acdcebe9d4024813b6af57f264fb906ccdd0aa311e8c5a2f6e2714270eab6dc"}},{"ruleId":"D2","level":"warning","message":{"text":"LoroDoc.#undoMovableLists (cognitive 55): LoroDoc.#undoMovableLists has cognitive complexity 55 (threshold 15). Drivers by points: if/else 13 (28 pts), loops 7 (12 pts), ternaries 3 (8 pts), boolean chains 7 (nesting depth added 25). Of this number, 38 points are the body\u0027s own statements and 17 belong to 3 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. This file is where this pass\u0027s cognitive complexity CONCENTRATES: loro-js/src/runtime/document.ts holds 56 of the 301 methods over the threshold \u2014 including the worst \u2014 and 1420 of the 5127 points over it (28%), 4.3\u00D7 the next-largest file (crates/loro-internal/src/loro.rs at 332). No single row can show this, because each is measured only against the threshold: reducing this one file moves this dimension further than any other file in the repository."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/document.ts"},"region":{"startLine":3623}}}],"partialFingerprints":{"codehealthFindingId/v1":"99ce73dcaea96e04ea247b3710f52029708ee05f99aba3a4f42ae129c01194e3"}},{"ruleId":"D2","level":"warning","message":{"text":"ChangeStore::get_change_by_lamport_lte (cognitive 53): ChangeStore::get_change_by_lamport_lte has cognitive complexity 53 (threshold 15). Drivers by points: if/else 17 (42 pts), match/switch 4 (6 pts), boolean chains 3, loops 2 (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":"crates/loro-internal/src/oplog/change_store.rs"},"region":{"startLine":1554}}}],"partialFingerprints":{"codehealthFindingId/v1":"188ab382e72035c5008b7a65b57c9e0a436fadcdc68f84f40c7ea84d8100b1e3"}},{"ruleId":"D2","level":"warning","message":{"text":"ContainerHistoryCache::init_cache_by_visit_all_change_slow (cognitive 52): ContainerHistoryCache::init_cache_by_visit_all_change_slow has cognitive complexity 52 (threshold 15). Drivers by points: if/else 9 (25 pts), loops 4 (12 pts), match/switch 4 (11 pts), boolean chains 4 (nesting depth added 31). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/history_cache.rs"},"region":{"startLine":163}}}],"partialFingerprints":{"codehealthFindingId/v1":"9c7587bac58baa9e0fd86acf8c6f7eb03b79a958fb7622b672d27f32030ea905"}},{"ruleId":"D2","level":"warning","message":{"text":"AppDag::debug_vv_from_block_headers (cognitive 50): AppDag::debug_vv_from_block_headers has cognitive complexity 50 (threshold 15). Drivers by points: if/else 18 (36 pts), loops 7 (11 pts), boolean chains 2, match/switch 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":"crates/loro-internal/src/oplog/loro_dag.rs"},"region":{"startLine":1446}}}],"partialFingerprints":{"codehealthFindingId/v1":"8b9f6c10f3a492b7e6d1f1712c4e953e9ed2dca52ae98c963d0e4de2d97862fa"}},{"ruleId":"D2","level":"warning","message":{"text":"OpLog::check_changes_include_predecessors (cognitive 50): OpLog::check_changes_include_predecessors has cognitive complexity 50 (threshold 15). Drivers by points: if/else 11 (24 pts), boolean chains 11, loops 4 (10 pts), match/switch 1 (5 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":"crates/loro-internal/src/oplog/known_history.rs"},"region":{"startLine":265}}}],"partialFingerprints":{"codehealthFindingId/v1":"c56f3234e419480b8f7c1e8d3ad3f2abc7dee43cd5becbcdefa52a380dcd346a"}},{"ruleId":"D2","level":"warning","message":{"text":"LoroDoc.#latestSingleHeadCriticalVersion (cognitive 50): LoroDoc.#latestSingleHeadCriticalVersion has cognitive complexity 50 (threshold 15). Drivers by points: if/else 14 (31 pts), loops 7 (11 pts), boolean chains 5, ternaries 2 (3 pts) (nesting depth added 22). Of this number, 28 points are the body\u0027s own statements and 22 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. This file is where this pass\u0027s cognitive complexity CONCENTRATES: loro-js/src/runtime/document.ts holds 56 of the 301 methods over the threshold \u2014 including the worst \u2014 and 1420 of the 5127 points over it (28%), 4.3\u00D7 the next-largest file (crates/loro-internal/src/loro.rs at 332). No single row can show this, because each is measured only against the threshold: reducing this one file moves this dimension further than any other file in the repository."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/document.ts"},"region":{"startLine":7870}}}],"partialFingerprints":{"codehealthFindingId/v1":"24ef39420525983efc094b0601fcf653e7e8d8c909ee3b44f338ccb872569ae9"}},{"ruleId":"D2","level":"warning","message":{"text":"MovableListHandler::unknown_container_created_by_delta (cognitive 49): MovableListHandler::unknown_container_created_by_delta has cognitive complexity 49 (threshold 15). Drivers by points: if/else 6 (26 pts), loops 5 (17 pts), match/switch 1 (4 pts), boolean chains 2 (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":"crates/loro-internal/src/handler/movable_list_apply_delta.rs"},"region":{"startLine":295}}}],"partialFingerprints":{"codehealthFindingId/v1":"d6c6f55e95c2a3b171454c6f1e1d580c53a51c2f789f45deb03bfca8c0f32294"}},{"ruleId":"D2","level":"warning","message":{"text":"TreeState::apply_diff_and_convert (cognitive 49): TreeState::apply_diff_and_convert has cognitive complexity 49 (threshold 15). Drivers by points: if/else 10 (40 pts), match/switch 2 (7 pts), loops 1 (2 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":"crates/loro-internal/src/state/tree_state.rs"},"region":{"startLine":1196}}}],"partialFingerprints":{"codehealthFindingId/v1":"ef83a76da989ee047c3b90fcbd2d8b92a8cc05f65cdc97ae6e3b105dbeb6ce7a"}},{"ruleId":"D2","level":"warning","message":{"text":"MovableListState.transition (cognitive 48): MovableListState.transition has cognitive complexity 48 (threshold 15). Drivers by points: if/else 11 (20 pts), loops 11 (18 pts), boolean chains 8, match/switch 1 (2 pts) (nesting depth added 17). Of this number, 44 points are the body\u0027s own statements and 4 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":"loro-js/src/runtime/movable-list.ts"},"region":{"startLine":540}}}],"partialFingerprints":{"codehealthFindingId/v1":"bce63ce5c95b0831e3edaf06d701e762b55aacf736b0c66631594d752097f2f3"}},{"ruleId":"D2","level":"warning","message":{"text":"LoroDoc.diff (cognitive 48): LoroDoc.diff has cognitive complexity 48 (threshold 15). Drivers by points: if/else 17 (30 pts), loops 3 (7 pts), boolean chains 6, ternaries 3, error handling 2 (nesting depth added 17). Of this number, 44 points are the body\u0027s own statements and 4 belong to 3 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. This file is where this pass\u0027s cognitive complexity CONCENTRATES: loro-js/src/runtime/document.ts holds 56 of the 301 methods over the threshold \u2014 including the worst \u2014 and 1420 of the 5127 points over it (28%), 4.3\u00D7 the next-largest file (crates/loro-internal/src/loro.rs at 332). No single row can show this, because each is measured only against the threshold: reducing this one file moves this dimension further than any other file in the repository."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/document.ts"},"region":{"startLine":1263}}}],"partialFingerprints":{"codehealthFindingId/v1":"b45122c17df90c1376e9db5319327f79a6721f830b5513be0122039d045165cb"}},{"ruleId":"D2","level":"warning","message":{"text":"LoroDoc.#recordsInSpans (cognitive 48): LoroDoc.#recordsInSpans has cognitive complexity 48 (threshold 15). Drivers by points: if/else 9 (24 pts), loops 6 (12 pts), ternaries 2 (8 pts), boolean chains 4 (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. This file is where this pass\u0027s cognitive complexity CONCENTRATES: loro-js/src/runtime/document.ts holds 56 of the 301 methods over the threshold \u2014 including the worst \u2014 and 1420 of the 5127 points over it (28%), 4.3\u00D7 the next-largest file (crates/loro-internal/src/loro.rs at 332). No single row can show this, because each is measured only against the threshold: reducing this one file moves this dimension further than any other file in the repository."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/document.ts"},"region":{"startLine":7326}}}],"partialFingerprints":{"codehealthFindingId/v1":"b3363dda23b99e2088434d1380dd596e3db88bf2203a9c77a44538a73ac73399"}},{"ruleId":"D2","level":"warning","message":{"text":"OpLog::try_iter_from_replay_base_causally_filtered (cognitive 47): OpLog::try_iter_from_replay_base_causally_filtered has cognitive complexity 47 (threshold 15). Drivers by points: if/else 20 (35 pts), match/switch 4 (7 pts), boolean chains 4, 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":"crates/loro-internal/src/oplog.rs"},"region":{"startLine":1269}}}],"partialFingerprints":{"codehealthFindingId/v1":"18c1e4ca4d7638bfe3872f3aa2458cdaa115280f8afc51acd901814897654485"}},{"ruleId":"D2","level":"warning","message":{"text":"loro_internal::diff::diff_impl::find_middle_snake (cognitive 47): loro_internal::diff::diff_impl::find_middle_snake has cognitive complexity 47 (threshold 15). Drivers by points: if/else 12 (34 pts), boolean chains 8, loops 3 (5 pts) (nesting depth added 24). This file\u0027s own header attributes it to another copyright holder, so it is code this repository carries rather than code it wrote: restructuring the body in place forks it from upstream and turns every future re-sync into a manual merge. The performable moves are to leave the body as close to its upstream form as possible and keep it behind a narrow interface of your own, and to re-sync it when upstream changes \u2014 or, if it has already diverged far enough that you maintain it here, adopt it deliberately and then split the body into named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/diff/diff_impl.rs"},"region":{"startLine":185}}}],"partialFingerprints":{"codehealthFindingId/v1":"8427f1a509a30824f9d03db0c8be979e0bb854204fe713a8368832a94393bb57"}},{"ruleId":"D2","level":"warning","message":{"text":"document.decodeImportBlobMeta (cognitive 47): document.decodeImportBlobMeta has cognitive complexity 47 (threshold 15). Drivers by points: if/else 14 (27 pts), loops 7 (12 pts), boolean chains 7, ternaries 1 (nesting depth added 18). Of this number, 41 points are the body\u0027s own statements and 6 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. This file is where this pass\u0027s cognitive complexity CONCENTRATES: loro-js/src/runtime/document.ts holds 56 of the 301 methods over the threshold \u2014 including the worst \u2014 and 1420 of the 5127 points over it (28%), 4.3\u00D7 the next-largest file (crates/loro-internal/src/loro.rs at 332). No single row can show this, because each is measured only against the threshold: reducing this one file moves this dimension further than any other file in the repository."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/document.ts"},"region":{"startLine":8895}}}],"partialFingerprints":{"codehealthFindingId/v1":"b1bf7b742bef3b7523afbddb0d619b7050290919cc234cd9d8db21126d147eb9"}},{"ruleId":"D2","level":"warning","message":{"text":"SequenceIndex.insertSpanAtPhysical (cognitive 46): SequenceIndex.insertSpanAtPhysical has cognitive complexity 46 (threshold 15). Drivers by points: if/else 19 (29 pts), loops 5 (11 pts), boolean chains 5, ternaries 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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":1104}}}],"partialFingerprints":{"codehealthFindingId/v1":"98f9f2c351cffb4cc5793099754ee8baabe946f63ffd3045ed8e7af73eb4a67a"}},{"ruleId":"D2","level":"warning","message":{"text":"LoroDoc.#completeDiffEntries (cognitive 46): LoroDoc.#completeDiffEntries has cognitive complexity 46 (threshold 15). Drivers by points: if/else 9 (28 pts), loops 5 (12 pts), boolean chains 6 (nesting depth added 26). Of this number, 43 points are the body\u0027s own statements and 3 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. This file is where this pass\u0027s cognitive complexity CONCENTRATES: loro-js/src/runtime/document.ts holds 56 of the 301 methods over the threshold \u2014 including the worst \u2014 and 1420 of the 5127 points over it (28%), 4.3\u00D7 the next-largest file (crates/loro-internal/src/loro.rs at 332). No single row can show this, because each is measured only against the threshold: reducing this one file moves this dimension further than any other file in the repository."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/document.ts"},"region":{"startLine":2295}}}],"partialFingerprints":{"codehealthFindingId/v1":"1dd25bbd17dc0bd949cf4bd2c6fa74dd8d0676ad7ef51ce6410f72efb6b250a2"}},{"ruleId":"D2","level":"warning","message":{"text":"LoroValue::apply_diff_shallow (cognitive 45): LoroValue::apply_diff_shallow has cognitive complexity 45 (threshold 15). Drivers by points: loops 6 (18 pts), match/switch 5 (18 pts), if/else 4 (9 pts) (nesting depth added 30). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/value.rs"},"region":{"startLine":253}}}],"partialFingerprints":{"codehealthFindingId/v1":"87426676c29cf3cbb548296ef48211f683fec44680c5730acdfcf37818e44d34"}},{"ruleId":"D2","level":"warning","message":{"text":"MovableListHandler::plan_moves (cognitive 45): MovableListHandler::plan_moves has cognitive complexity 45 (threshold 15). Drivers by points: if/else 8 (29 pts), loops 5 (14 pts), match/switch 1 (2 pts) (nesting depth added 31). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/handler/movable_list_apply_delta.rs"},"region":{"startLine":90}}}],"partialFingerprints":{"codehealthFindingId/v1":"6503cdc41931604849646cbe008a2f4c2f2e5a2536581ce340ada8ae37bfe6a5"}},{"ruleId":"D2","level":"warning","message":{"text":"ChangeStore::build_root_history_names (cognitive 45): ChangeStore::build_root_history_names has cognitive complexity 45 (threshold 15). Drivers by points: if/else 7 (24 pts), loops 6 (14 pts), match/switch 3 (7 pts) (nesting depth added 29). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/oplog/change_store.rs"},"region":{"startLine":872}}}],"partialFingerprints":{"codehealthFindingId/v1":"0b3978b944528a5e819f2b08f669a40689fabc9821e15a047943f1f61a8b26c4"}},{"ruleId":"D2","level":"warning","message":{"text":"loro_internal::encoding::shallow_snapshot::export_shallow_snapshot_inner (cognitive 45): loro_internal::encoding::shallow_snapshot::export_shallow_snapshot_inner has cognitive complexity 45 (threshold 15). Drivers by points: if/else 16 (31 pts), loops 3 (8 pts), match/switch 1 (4 pts), boolean chains 2 (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":"crates/loro-internal/src/encoding/shallow_snapshot.rs"},"region":{"startLine":301}}}],"partialFingerprints":{"codehealthFindingId/v1":"941ea6d8fbb5e4e8f566a4952b5821adba33462c53dce01c3d9e602e65db63fd"}},{"ruleId":"D2","level":"warning","message":{"text":"LoroDoc.#sequenceTreeItems (cognitive 45): LoroDoc.#sequenceTreeItems has cognitive complexity 45 (threshold 15). Drivers by points: if/else 11 (17 pts), ternaries 8 (13 pts), loops 11 (12 pts), boolean chains 3 (nesting depth added 12). Of this number, 29 points are the body\u0027s own statements and 16 belong to 9 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. This file is where this pass\u0027s cognitive complexity CONCENTRATES: loro-js/src/runtime/document.ts holds 56 of the 301 methods over the threshold \u2014 including the worst \u2014 and 1420 of the 5127 points over it (28%), 4.3\u00D7 the next-largest file (crates/loro-internal/src/loro.rs at 332). No single row can show this, because each is measured only against the threshold: reducing this one file moves this dimension further than any other file in the repository."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/document.ts"},"region":{"startLine":1824}}}],"partialFingerprints":{"codehealthFindingId/v1":"d295d37fc6123f13a34343bb17f1c092c28590387654e849eb06bdae460ee99b"}},{"ruleId":"D2","level":"warning","message":{"text":"LoroDoc.#validateDiffBatch (cognitive 45): LoroDoc.#validateDiffBatch has cognitive complexity 45 (threshold 15). Drivers by points: if/else 12 (24 pts), loops 4 (10 pts), ternaries 2 (7 pts), boolean chains 4 (nesting depth added 23). Of this number, 42 points are the body\u0027s own statements and 3 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. This file is where this pass\u0027s cognitive complexity CONCENTRATES: loro-js/src/runtime/document.ts holds 56 of the 301 methods over the threshold \u2014 including the worst \u2014 and 1420 of the 5127 points over it (28%), 4.3\u00D7 the next-largest file (crates/loro-internal/src/loro.rs at 332). No single row can show this, because each is measured only against the threshold: reducing this one file moves this dimension further than any other file in the repository."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/document.ts"},"region":{"startLine":2479}}}],"partialFingerprints":{"codehealthFindingId/v1":"64a1b32e5879cf6ece2bb780d7e62e94bab60acfb9fea72bacf8c81f0c562d22"}},{"ruleId":"D2","level":"warning","message":{"text":"LoroDoc.#hydrateContainerState (cognitive 45): LoroDoc.#hydrateContainerState has cognitive complexity 45 (threshold 15). Drivers by points: if/else 11 (22 pts), loops 8 (17 pts), boolean chains 6 (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. This file is where this pass\u0027s cognitive complexity CONCENTRATES: loro-js/src/runtime/document.ts holds 56 of the 301 methods over the threshold \u2014 including the worst \u2014 and 1420 of the 5127 points over it (28%), 4.3\u00D7 the next-largest file (crates/loro-internal/src/loro.rs at 332). No single row can show this, because each is measured only against the threshold: reducing this one file moves this dimension further than any other file in the repository."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/document.ts"},"region":{"startLine":8545}}}],"partialFingerprints":{"codehealthFindingId/v1":"2b0497e341a2cd9e1a46e6ffa39152326762672a87575aee7aa724e1d3519132"}},{"ruleId":"D2","level":"warning","message":{"text":"document.validateTreeItems (cognitive 44): document.validateTreeItems has cognitive complexity 44 (threshold 15). Drivers by points: if/else 14 (28 pts), loops 4 (7 pts), ternaries 3 (5 pts), boolean chains 4 (nesting depth added 19). Of this number, 30 points are the body\u0027s own statements and 14 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. This file is where this pass\u0027s cognitive complexity CONCENTRATES: loro-js/src/runtime/document.ts holds 56 of the 301 methods over the threshold \u2014 including the worst \u2014 and 1420 of the 5127 points over it (28%), 4.3\u00D7 the next-largest file (crates/loro-internal/src/loro.rs at 332). No single row can show this, because each is measured only against the threshold: reducing this one file moves this dimension further than any other file in the repository."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/document.ts"},"region":{"startLine":11160}}}],"partialFingerprints":{"codehealthFindingId/v1":"e625252f5f9c72144739b294b3eda19287175da303119d8839f92239114830db"}},{"ruleId":"D2","level":"warning","message":{"text":"BTree::update_leaf (cognitive 43): BTree::update_leaf has cognitive complexity 43 (threshold 15). Drivers by points: if/else 23 (41 pts), loops 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":"crates/generic-btree/src/lib.rs"},"region":{"startLine":1267}}}],"partialFingerprints":{"codehealthFindingId/v1":"eea251456404197f5f6628f47c77b3a25074c609b12ab0104bd826ff3ee90e3a"}},{"ruleId":"D2","level":"warning","message":{"text":"RichtextDiffCalculator::apply_crdt_op_to_tracker (cognitive 43): RichtextDiffCalculator::apply_crdt_op_to_tracker has cognitive complexity 43 (threshold 15). Drivers by points: if/else 9 (24 pts), loops 2 (10 pts), match/switch 3 (6 pts), boolean chains 3 (nesting depth added 26). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/diff_calc.rs"},"region":{"startLine":1276}}}],"partialFingerprints":{"codehealthFindingId/v1":"d2b48e9587ae50cfff47dbb40bdfaaa26585c68dc922a4e8aaaa637981f2faa2"}},{"ruleId":"D2","level":"warning","message":{"text":"MovableListUndoState.apply (cognitive 43): MovableListUndoState.apply has cognitive complexity 43 (threshold 15). Drivers by points: if/else 11 (22 pts), boolean chains 7, loops 5 (7 pts), ternaries 2 (7 pts) (nesting depth added 18). Of this number, 42 points are the body\u0027s own statements and 1 belongs to one function item inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/movable-list-undo.ts"},"region":{"startLine":73}}}],"partialFingerprints":{"codehealthFindingId/v1":"ffc7a550e6563197545d1d07d664ef964c82e23f575c6c0c224826f632b35b99"}},{"ruleId":"D2","level":"warning","message":{"text":"LoroDoc.#applyContainerDiff (cognitive 43): LoroDoc.#applyContainerDiff has cognitive complexity 43 (threshold 15). Drivers by points: if/else 20 (36 pts), loops 3 (6 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. This file is where this pass\u0027s cognitive complexity CONCENTRATES: loro-js/src/runtime/document.ts holds 56 of the 301 methods over the threshold \u2014 including the worst \u2014 and 1420 of the 5127 points over it (28%), 4.3\u00D7 the next-largest file (crates/loro-internal/src/loro.rs at 332). No single row can show this, because each is measured only against the threshold: reducing this one file moves this dimension further than any other file in the repository."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/document.ts"},"region":{"startLine":2585}}}],"partialFingerprints":{"codehealthFindingId/v1":"fe1361292aa229614ecf6eb3d1a2baaf714a7a1082f8ac93479be48b68bfb172"}},{"ruleId":"D2","level":"warning","message":{"text":"loro_internal::txn::change_to_diff (cognitive 41): loro_internal::txn::change_to_diff has cognitive complexity 41 (threshold 15). Drivers by points: if/else 6 (19 pts), loops 6 (15 pts), match/switch 2 (7 pts) (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":"crates/loro-internal/src/txn.rs"},"region":{"startLine":968}}}],"partialFingerprints":{"codehealthFindingId/v1":"03f83b2c70268eb455cf071c14fe59bdb0f01d5f46443aa9f7a38793b1b3d45c"}},{"ruleId":"D2","level":"warning","message":{"text":"UndoManager::setOnPush (cognitive 41): UndoManager::setOnPush has cognitive complexity 41 (threshold 15). Drivers by points: if/else 11 (26 pts), match/switch 4 (9 pts), loops 1 (6 pts) (nesting depth added 25). 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":"crates/loro-wasm/src/lib.rs"},"region":{"startLine":6055}}}],"partialFingerprints":{"codehealthFindingId/v1":"eaf3fa727c8005c00e0546fca870575dd3e86f94a06e7fb481dbcb5590dfb22b"}},{"ruleId":"D2","level":"warning","message":{"text":"sequence-index.recomputeOwnElements (cognitive 41): sequence-index.recomputeOwnElements has cognitive complexity 41 (threshold 15). Drivers by points: if/else 17 (32 pts), ternaries 4 (6 pts), loops 2 (3 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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":2947}}}],"partialFingerprints":{"codehealthFindingId/v1":"e2ce0a2f29420bc6db5983d8e57967262d2fc1089654c37fa598711f80e3070f"}},{"ruleId":"D2","level":"warning","message":{"text":"TextHandler::insert_with_txn_and_attr (cognitive 40): TextHandler::insert_with_txn_and_attr has cognitive complexity 40 (threshold 15). Drivers by points: if/else 17 (27 pts), match/switch 5 (8 pts), loops 2 (4 pts), boolean chains 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":"crates/loro-internal/src/handler.rs"},"region":{"startLine":2148}}}],"partialFingerprints":{"codehealthFindingId/v1":"d3c0af9d57c278c310cbdb50ef6f1e2cf594440fe911d69da4ccf67e5f50d6be"}},{"ruleId":"D2","level":"warning","message":{"text":"MovableListHandler::place_inserted_values (cognitive 40): MovableListHandler::place_inserted_values has cognitive complexity 40 (threshold 15). Drivers by points: if/else 5 (19 pts), match/switch 3 (10 pts), loops 3 (9 pts), boolean chains 2 (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":"crates/loro-internal/src/handler/movable_list_apply_delta.rs"},"region":{"startLine":185}}}],"partialFingerprints":{"codehealthFindingId/v1":"a8dad14cad9c06bfbee9216c771bc4e60a77bd8163c165bbbd223b5cdbd48f43"}},{"ruleId":"D2","level":"warning","message":{"text":"LoroDoc::order_mergeable_removals (cognitive 40): LoroDoc::order_mergeable_removals has cognitive complexity 40 (threshold 15). Drivers by points: if/else 13 (29 pts), loops 6 (9 pts), boolean chains 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":"crates/loro-internal/src/loro.rs"},"region":{"startLine":2369}}}],"partialFingerprints":{"codehealthFindingId/v1":"df71129e90caf98c327ad25a2facdaf3a5ff879934e2ca7b45f85147ce0cb947"}},{"ruleId":"D2","level":"warning","message":{"text":"DocState::ensure_containers_created_by_internal_diff (cognitive 40): DocState::ensure_containers_created_by_internal_diff has cognitive complexity 40 (threshold 15). Drivers by points: if/else 6 (21 pts), loops 6 (14 pts), match/switch 2 (5 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":"crates/loro-internal/src/state.rs"},"region":{"startLine":938}}}],"partialFingerprints":{"codehealthFindingId/v1":"3dfdbb11f411760e40c27ae0a46d7cc81ee3f15e31a714c4a73eb136443c6c43"}},{"ruleId":"D2","level":"warning","message":{"text":"change-block-codec.decodeOperationContent (cognitive 40): change-block-codec.decodeOperationContent has cognitive complexity 40 (threshold 15). Drivers by points: if/else 19 (33 pts), ternaries 2 (4 pts), boolean chains 3 (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":"loro-js/src/codec/change-block-codec.ts"},"region":{"startLine":358}}}],"partialFingerprints":{"codehealthFindingId/v1":"132b7119b363d63829ca343649226d99f714ebf0d4951825ff350788cd72570a"}},{"ruleId":"D2","level":"warning","message":{"text":"SstableReader.rewrite (cognitive 40): SstableReader.rewrite has cognitive complexity 40 (threshold 15). Drivers by points: if/else 8 (18 pts), ternaries 4 (10 pts), loops 5 (8 pts), boolean chains 4 (nesting depth added 19). Of this number, 37 points are the body\u0027s own statements and 3 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":"loro-js/src/codec/sstable.ts"},"region":{"startLine":162}}}],"partialFingerprints":{"codehealthFindingId/v1":"81999063ac0ada6be4ab9a99f1a140b75ad58db72d6162211d61d495f30cf58e"}},{"ruleId":"D2","level":"warning","message":{"text":"SequenceIndex.insertAtPhysical (cognitive 40): SequenceIndex.insertAtPhysical has cognitive complexity 40 (threshold 15). Drivers by points: if/else 17 (25 pts), loops 4 (9 pts), boolean chains 5, 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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":1025}}}],"partialFingerprints":{"codehealthFindingId/v1":"058b214eef270ba507317fbc3c3d895924c6e2e77320aa0085c3d592201a5bce"}},{"ruleId":"D2","level":"warning","message":{"text":"BTree::update_leaves_with_arg_in_ranges (cognitive 39): BTree::update_leaves_with_arg_in_ranges has cognitive complexity 39 (threshold 15). Drivers by points: loops 9 (22 pts), if/else 5 (16 pts), boolean chains 1 (nesting depth added 24). To reduce it, break up the iteration: give each loop body a named function, and split a multi-phase loop into one function per phase so no single body carries the whole pipeline."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/generic-btree/src/lib.rs"},"region":{"startLine":1404}}}],"partialFingerprints":{"codehealthFindingId/v1":"21867907570f433822209c7c6892c6c003666bcd26a8851f2076432a90c06463"}},{"ruleId":"D2","level":"warning","message":{"text":"LoroValue::apply_diff (cognitive 39): LoroValue::apply_diff has cognitive complexity 39 (threshold 15). Drivers by points: loops 6 (18 pts), match/switch 5 (18 pts), if/else 2 (3 pts) (nesting depth added 26). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/value.rs"},"region":{"startLine":354}}}],"partialFingerprints":{"codehealthFindingId/v1":"c3b0c01ddba326006b0003a3e6a151a7e27ea2726c26e9c76a4ae705ef535c72"}},{"ruleId":"D2","level":"warning","message":{"text":"DagCausalIter::next (cognitive 38): DagCausalIter::next has cognitive complexity 38 (threshold 15). Drivers by points: if/else 13 (29 pts), loops 4 (8 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":"crates/loro-internal/src/dag/iter.rs"},"region":{"startLine":295}}}],"partialFingerprints":{"codehealthFindingId/v1":"261398695e86bc24e75303554083e328673a1f3a685b86b1ae884639bcea2c5d"}},{"ruleId":"D2","level":"warning","message":{"text":"Delta::compose (cognitive 38): Delta::compose has cognitive complexity 38 (threshold 15). Drivers by points: if/else 13 (29 pts), boolean chains 5, loops 2 (4 pts) (nesting depth added 18). 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":"crates/loro-internal/src/delta/seq.rs"},"region":{"startLine":522}}}],"partialFingerprints":{"codehealthFindingId/v1":"79cabfad245a32aaf3524e0f79a11e996a74cac8cde996a5184f727db3b80fbb"}},{"ruleId":"D2","level":"warning","message":{"text":"sequence-index.recomputeOwn (cognitive 38): sequence-index.recomputeOwn has cognitive complexity 38 (threshold 15). Drivers by points: if/else 17 (31 pts), ternaries 3 (5 pts), 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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":2834}}}],"partialFingerprints":{"codehealthFindingId/v1":"0fa79dd83e11a5300db0c5ca77b44fe22ad7fac8644a9822bb01e541e04481a5"}},{"ruleId":"D2","level":"warning","message":{"text":"sequence-index.visitVisibleStorageRange (cognitive 38): sequence-index.visitVisibleStorageRange has cognitive complexity 38 (threshold 15). Drivers by points: if/else 14 (31 pts), boolean chains 5, loops 1 (2 pts) (nesting depth added 18). Of this number, 36 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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":3770}}}],"partialFingerprints":{"codehealthFindingId/v1":"e94f38b1efae6eaf35d4d874dc5eca861d1d01fce1d1fb1cc27a26501c4d217f"}},{"ruleId":"D2","level":"warning","message":{"text":"AppDag::try_does_id_cover (cognitive 37): AppDag::try_does_id_cover has cognitive complexity 37 (threshold 15). Drivers by points: if/else 17 (33 pts), loops 2 (3 pts), boolean chains 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":"crates/loro-internal/src/oplog/loro_dag.rs"},"region":{"startLine":1316}}}],"partialFingerprints":{"codehealthFindingId/v1":"1f15db592e522144b9c4c82001f6e949700341628f14e274f6522a14ce90c46b"}},{"ruleId":"D2","level":"warning","message":{"text":"LoroDoc.#recordedEventDiffs (cognitive 37): LoroDoc.#recordedEventDiffs has cognitive complexity 37 (threshold 15). Drivers by points: if/else 8 (19 pts), boolean chains 7, loops 3 (7 pts), ternaries 1 (4 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. This file is where this pass\u0027s cognitive complexity CONCENTRATES: loro-js/src/runtime/document.ts holds 56 of the 301 methods over the threshold \u2014 including the worst \u2014 and 1420 of the 5127 points over it (28%), 4.3\u00D7 the next-largest file (crates/loro-internal/src/loro.rs at 332). No single row can show this, because each is measured only against the threshold: reducing this one file moves this dimension further than any other file in the repository."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/document.ts"},"region":{"startLine":4922}}}],"partialFingerprints":{"codehealthFindingId/v1":"e888010534c6416635f178dafa9052bd0a916eaa9c354943bc132ea209351e69"}},{"ruleId":"D2","level":"warning","message":{"text":"containers.indexedFugueInsertion (cognitive 37): containers.indexedFugueInsertion has cognitive complexity 37 (threshold 15). Drivers by points: if/else 13 (25 pts), loops 3 (5 pts), ternaries 2 (4 pts), boolean chains 3 (nesting depth added 16). Of this number, 36 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/containers.ts"},"region":{"startLine":3721}}}],"partialFingerprints":{"codehealthFindingId/v1":"96c983341064b30413c8e9e3246faf594f30bb9ac5eac59694e464f0c3bc6848"}},{"ruleId":"D2","level":"warning","message":{"text":"RichtextState::find_best_insert_pos (cognitive 36): RichtextState::find_best_insert_pos has cognitive complexity 36 (threshold 15). Drivers by points: if/else 10 (17 pts), match/switch 5 (11 pts), loops 4 (8 pts) (nesting depth added 17). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/container/richtext/richtext_state.rs"},"region":{"startLine":1846}}}],"partialFingerprints":{"codehealthFindingId/v1":"4d06c08ce5b3a766b37ead51f42ed031de8740b75aa0b07b18db56e63c8de66d"}},{"ruleId":"D2","level":"warning","message":{"text":"LoroDoc.#importBlobs (cognitive 36): LoroDoc.#importBlobs has cognitive complexity 36 (threshold 15). Drivers by points: if/else 10 (19 pts), ternaries 4 (9 pts), boolean chains 5, loops 2 (3 pts) (nesting depth added 15). Of this number, 35 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body. This file is where this pass\u0027s cognitive complexity CONCENTRATES: loro-js/src/runtime/document.ts holds 56 of the 301 methods over the threshold \u2014 including the worst \u2014 and 1420 of the 5127 points over it (28%), 4.3\u00D7 the next-largest file (crates/loro-internal/src/loro.rs at 332). No single row can show this, because each is measured only against the threshold: reducing this one file moves this dimension further than any other file in the repository."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/document.ts"},"region":{"startLine":1079}}}],"partialFingerprints":{"codehealthFindingId/v1":"c5596841b733b54fb3c43ab4316e8aaced1f43b79174ffa39ed431f5e6718819"}},{"ruleId":"D2","level":"warning","message":{"text":"LoroDoc.#rebuildFromSnapshotState (cognitive 36): LoroDoc.#rebuildFromSnapshotState has cognitive complexity 36 (threshold 15). Drivers by points: if/else 7 (15 pts), loops 5 (8 pts), ternaries 3 (7 pts), boolean chains 6 (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. This file is where this pass\u0027s cognitive complexity CONCENTRATES: loro-js/src/runtime/document.ts holds 56 of the 301 methods over the threshold \u2014 including the worst \u2014 and 1420 of the 5127 points over it (28%), 4.3\u00D7 the next-largest file (crates/loro-internal/src/loro.rs at 332). No single row can show this, because each is measured only against the threshold: reducing this one file moves this dimension further than any other file in the repository."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/document.ts"},"region":{"startLine":6676}}}],"partialFingerprints":{"codehealthFindingId/v1":"e35167485340c140714c95be6d67bd64e571f891397adecc989414aa42d900a3"}},{"ruleId":"D2","level":"warning","message":{"text":"LoroDoc.#retainedContainerKeys (cognitive 36): LoroDoc.#retainedContainerKeys has cognitive complexity 36 (threshold 15). Drivers by points: if/else 10 (21 pts), loops 6 (14 pts), boolean chains 1 (nesting depth added 19). Of this number, 34 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. This file is where this pass\u0027s cognitive complexity CONCENTRATES: loro-js/src/runtime/document.ts holds 56 of the 301 methods over the threshold \u2014 including the worst \u2014 and 1420 of the 5127 points over it (28%), 4.3\u00D7 the next-largest file (crates/loro-internal/src/loro.rs at 332). No single row can show this, because each is measured only against the threshold: reducing this one file moves this dimension further than any other file in the repository."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/document.ts"},"region":{"startLine":8169}}}],"partialFingerprints":{"codehealthFindingId/v1":"a646ae1268b6496804b193cf89891ebf1201c772cabf2ff8f7311731b1c8590c"}},{"ruleId":"D2","level":"warning","message":{"text":"Rope::insert (cognitive 34): Rope::insert has cognitive complexity 34 (threshold 15). Drivers by points: if/else 15 (32 pts), loops 1 (2 pts) (nesting depth added 18). 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":"crates/generic-btree/src/generic_impl/rope.rs"},"region":{"startLine":48}}}],"partialFingerprints":{"codehealthFindingId/v1":"f527a3e52d755ed76e63cae320c5478b7ca3c1cbb543a950830dff7fb52c3eea"}},{"ruleId":"D2","level":"warning","message":{"text":"RichtextDiffCalculator::calculate_diff (cognitive 34): RichtextDiffCalculator::calculate_diff has cognitive complexity 34 (threshold 15). Drivers by points: if/else 5 (11 pts), loops 4 (11 pts), match/switch 4 (7 pts), boolean chains 5 (nesting depth added 16). Of this number, 18 points are the body\u0027s own statements and 16 belong to 2 function items inside it that branch. The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/diff_calc.rs"},"region":{"startLine":1829}}}],"partialFingerprints":{"codehealthFindingId/v1":"a0fb588a3eef8787f5a4e785e079cab49d926c6375297d255c993757abdefa0e"}},{"ruleId":"D2","level":"warning","message":{"text":"document.subtractSequenceIdRuns (cognitive 34): document.subtractSequenceIdRuns has cognitive complexity 34 (threshold 15). Drivers by points: if/else 11 (24 pts), loops 6 (9 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. This file is where this pass\u0027s cognitive complexity CONCENTRATES: loro-js/src/runtime/document.ts holds 56 of the 301 methods over the threshold \u2014 including the worst \u2014 and 1420 of the 5127 points over it (28%), 4.3\u00D7 the next-largest file (crates/loro-internal/src/loro.rs at 332). No single row can show this, because each is measured only against the threshold: reducing this one file moves this dimension further than any other file in the repository."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/document.ts"},"region":{"startLine":10964}}}],"partialFingerprints":{"codehealthFindingId/v1":"a844bcaac87a9afea16a645cec9226ca78cdd288d7af1922f02ae0d8b6402bb7"}},{"ruleId":"D2","level":"warning","message":{"text":"Drain::drop (cognitive 33): Drain::drop has cognitive complexity 33 (threshold 15). Drivers by points: if/else 14 (21 pts), loops 6 (12 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":"crates/generic-btree/src/iter.rs"},"region":{"startLine":135}}}],"partialFingerprints":{"codehealthFindingId/v1":"da96bbdba9a9ba583f7a5ff86db760c3b884798efdee25921509237b2c09a820"}},{"ruleId":"D2","level":"warning","message":{"text":"RichtextState::slice_delta (cognitive 33): RichtextState::slice_delta has cognitive complexity 33 (threshold 15). Drivers by points: if/else 7 (21 pts), loops 3 (8 pts), match/switch 3 (4 pts) (nesting depth added 20). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/container/richtext/richtext_state.rs"},"region":{"startLine":2149}}}],"partialFingerprints":{"codehealthFindingId/v1":"fba0dcbead4a8ceba16f76c94372ecbded7e6ef0e793d8755ff6d82d0d0d7bab"}},{"ruleId":"D2","level":"warning","message":{"text":"RichtextDiffCalculator::seed_tracker_from_shallow_root (cognitive 33): RichtextDiffCalculator::seed_tracker_from_shallow_root has cognitive complexity 33 (threshold 15). Drivers by points: if/else 11 (23 pts), loops 5, match/switch 2 (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":"crates/loro-internal/src/diff_calc.rs"},"region":{"startLine":1451}}}],"partialFingerprints":{"codehealthFindingId/v1":"1848b5f42f31faa09f779f94d24a67ceefa30459f7ae69cfe05fb09b88c4d61a"}},{"ruleId":"D2","level":"warning","message":{"text":"LoroDoc::plan_full_state_batch (cognitive 33): LoroDoc::plan_full_state_batch has cognitive complexity 33 (threshold 15). Drivers by points: if/else 10 (26 pts), loops 2 (4 pts), match/switch 1 (2 pts), boolean chains 1 (nesting depth added 19). 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":"crates/loro-internal/src/loro.rs"},"region":{"startLine":2472}}}],"partialFingerprints":{"codehealthFindingId/v1":"dc6096cd81f52d40becffdf583cfbc7dc7f94f0234988b318c893296e2bca8b2"}},{"ruleId":"D2","level":"warning","message":{"text":"loro_internal::loro::isolated_scalar_root_batch (cognitive 33): loro_internal::loro::isolated_scalar_root_batch has cognitive complexity 33 (threshold 15). Drivers by points: if/else 10 (25 pts), loops 4 (6 pts), boolean chains 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":"crates/loro-internal/src/loro.rs"},"region":{"startLine":4165}}}],"partialFingerprints":{"codehealthFindingId/v1":"c57e3f89b24d4bb91e5494ee8663906e8cde67e7b45f2e3373ec70c08725f700"}},{"ruleId":"D2","level":"warning","message":{"text":"SequenceIndex.#markLocatedIdSpanVisibility (cognitive 33): SequenceIndex.#markLocatedIdSpanVisibility has cognitive complexity 33 (threshold 15). Drivers by points: if/else 10 (19 pts), loops 8 (13 pts), ternaries 1 (nesting depth added 14). Of this number, 32 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":1292}}}],"partialFingerprints":{"codehealthFindingId/v1":"779a907182b0654d005a874cd75e25622c3826ee3646409373e9437d971c7198"}},{"ruleId":"D2","level":"warning","message":{"text":"LoroDoc.#integrateHistory (cognitive 33): LoroDoc.#integrateHistory has cognitive complexity 33 (threshold 15). Drivers by points: if/else 9 (25 pts), loops 3 (4 pts), ternaries 1 (3 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. This file is where this pass\u0027s cognitive complexity CONCENTRATES: loro-js/src/runtime/document.ts holds 56 of the 301 methods over the threshold \u2014 including the worst \u2014 and 1420 of the 5127 points over it (28%), 4.3\u00D7 the next-largest file (crates/loro-internal/src/loro.rs at 332). No single row can show this, because each is measured only against the threshold: reducing this one file moves this dimension further than any other file in the repository."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/document.ts"},"region":{"startLine":5503}}}],"partialFingerprints":{"codehealthFindingId/v1":"f735feab6ab432d7984e6b075a3883f42c55b88bc85d935821cef5c4de2bb28d"}},{"ruleId":"D2","level":"warning","message":{"text":"BTree::update_leaf_by_search (cognitive 32): BTree::update_leaf_by_search has cognitive complexity 32 (threshold 15). Drivers by points: if/else 14 (25 pts), loops 3 (4 pts), match/switch 1 (2 pts), boolean chains 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":"crates/generic-btree/src/lib.rs"},"region":{"startLine":1116}}}],"partialFingerprints":{"codehealthFindingId/v1":"7e96f3bcac4f28af3662d0547c19bddbde18653fd455209dddb13a776b1260d7"}},{"ruleId":"D2","level":"warning","message":{"text":"MemKvStore::export_with_encoded_block (cognitive 32): MemKvStore::export_with_encoded_block has cognitive complexity 32 (threshold 15). Drivers by points: if/else 6 (19 pts), loops 5 (9 pts), match/switch 1 (4 pts) (nesting depth added 20). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/kv-store/src/mem_store.rs"},"region":{"startLine":309}}}],"partialFingerprints":{"codehealthFindingId/v1":"a2b3fb32a86e52a361cdba1aea78499ff1405fd86ebad1741e91e2c3c648cbb5"}},{"ruleId":"D2","level":"warning","message":{"text":"MovableListDiffCalculator::calculate_diff (cognitive 32): MovableListDiffCalculator::calculate_diff has cognitive complexity 32 (threshold 15). Drivers by points: if/else 13 (21 pts), boolean chains 6, loops 2 (4 pts), match/switch 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":"crates/loro-internal/src/diff_calc.rs"},"region":{"startLine":2205}}}],"partialFingerprints":{"codehealthFindingId/v1":"eeb57b61ecab394c0b520e4bd0b575933b3c5cf054f95a2d1819b471e17feb61"}},{"ruleId":"D2","level":"warning","message":{"text":"CausalWorkspace::summary_of (cognitive 32): CausalWorkspace::summary_of has cognitive complexity 32 (threshold 15). Drivers by points: if/else 15 (31 pts), loops 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":"crates/loro-internal/src/oplog/known_history.rs"},"region":{"startLine":973}}}],"partialFingerprints":{"codehealthFindingId/v1":"29d93ccb247e9e9d36fdf5902efa9c32caa83e43a941f47aa967f76177430d6c"}},{"ruleId":"D2","level":"warning","message":{"text":"DocState::get_alive_children_of (cognitive 32): DocState::get_alive_children_of has cognitive complexity 32 (threshold 15). Drivers by points: loops 6 (16 pts), if/else 7 (14 pts), boolean chains 1, match/switch 1 (nesting depth added 17). To reduce it, break up the iteration: give each loop body a named function, and split a multi-phase loop into one function per phase so no single body carries the whole pipeline."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/state.rs"},"region":{"startLine":2027}}}],"partialFingerprints":{"codehealthFindingId/v1":"2ddd33ff850d046b1c6f2bde08fdecf8695ce022e99f331566f5cbd13f786f6b"}},{"ruleId":"D2","level":"warning","message":{"text":"jsonpath.lookupChild (cognitive 32): jsonpath.lookupChild has cognitive complexity 32 (threshold 15). Drivers by points: if/else 10 (14 pts), ternaries 7 (14 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":"loro-js/src/runtime/jsonpath.ts"},"region":{"startLine":369}}}],"partialFingerprints":{"codehealthFindingId/v1":"aa6efcd4dc400e4d4e96b20a5ce7de8aa93447a82236a9e9602768c395bdfcdb"}},{"ruleId":"D2","level":"warning","message":{"text":"RichtextState::drain_by_entity_index (cognitive 31): RichtextState::drain_by_entity_index has cognitive complexity 31 (threshold 15). Drivers by points: if/else 14 (26 pts), match/switch 2 (3 pts), loops 1 (2 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":"crates/loro-internal/src/container/richtext/richtext_state.rs"},"region":{"startLine":2317}}}],"partialFingerprints":{"codehealthFindingId/v1":"82f829ac254f0a230aa1b8aeae80a12ddd9e83747726a02c1dd9ecc70d1538b1"}},{"ruleId":"D2","level":"warning","message":{"text":"LoroDoc::commit_internal_inner (cognitive 30): LoroDoc::commit_internal_inner has cognitive complexity 30 (threshold 15). Drivers by points: if/else 14 (27 pts), boolean chains 2, 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":"crates/loro-internal/src/loro.rs"},"region":{"startLine":397}}}],"partialFingerprints":{"codehealthFindingId/v1":"37f69fff69609a330e58976dd4ff1a13e55dfc6b32f649fe4d2752de6327a239"}},{"ruleId":"D2","level":"warning","message":{"text":"loro_internal::dag::latest_single_head_critical_version (cognitive 30): loro_internal::dag::latest_single_head_critical_version has cognitive complexity 30 (threshold 15). Drivers by points: if/else 10 (21 pts), loops 3 (6 pts), match/switch 1 (2 pts), boolean chains 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":"crates/loro-internal/src/dag.rs"},"region":{"startLine":663}}}],"partialFingerprints":{"codehealthFindingId/v1":"0d3a0075c12e148120d489429c89dd1d33881569e0f17c891815f8feebcb7717"}},{"ruleId":"D2","level":"warning","message":{"text":"loro_internal::version::try_shrink_frontiers (cognitive 30): loro_internal::version::try_shrink_frontiers has cognitive complexity 30 (threshold 15). Drivers by points: if/else 13 (24 pts), loops 3 (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":"crates/loro-internal/src/version.rs"},"region":{"startLine":1009}}}],"partialFingerprints":{"codehealthFindingId/v1":"7d23ecd5d069d18cffb677664d0fd97f86a47ae713f3a5e15decd1910f935c87"}},{"ruleId":"D2","level":"warning","message":{"text":"SequenceIndex.causalView (cognitive 30): SequenceIndex.causalView has cognitive complexity 30 (threshold 15). Drivers by points: if/else 14 (23 pts), loops 3 (4 pts), boolean chains 3 (nesting depth added 10). Most of this is not in the body itself: 5 of the 30 points are its own statements and the rest belongs to 3 function items inside it that branch (a function literal at line 1655, causalCount, isVisible). 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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":1597}}}],"partialFingerprints":{"codehealthFindingId/v1":"9803b55cd20ba6b452638271b197c4a3f1ab3298e6bfb2558adabf70f080629f"}},{"ruleId":"D2","level":"warning","message":{"text":"LoroDoc.#emit (cognitive 30): LoroDoc.#emit has cognitive complexity 30 (threshold 15). Drivers by points: if/else 9 (16 pts), loops 6 (10 pts), boolean chains 2, ternaries 2 (nesting depth added 11). Of this number, 28 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. This file is where this pass\u0027s cognitive complexity CONCENTRATES: loro-js/src/runtime/document.ts holds 56 of the 301 methods over the threshold \u2014 including the worst \u2014 and 1420 of the 5127 points over it (28%), 4.3\u00D7 the next-largest file (crates/loro-internal/src/loro.rs at 332). No single row can show this, because each is measured only against the threshold: reducing this one file moves this dimension further than any other file in the repository."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/document.ts"},"region":{"startLine":8781}}}],"partialFingerprints":{"codehealthFindingId/v1":"753e737b52128156bdad2415b38dd97243b52bb0325d3f7091b9742cf2bb46c0"}},{"ruleId":"D2","level":"warning","message":{"text":"document.containerPath (cognitive 30): document.containerPath has cognitive complexity 30 (threshold 15). Drivers by points: if/else 10 (20 pts), ternaries 2 (6 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. This file is where this pass\u0027s cognitive complexity CONCENTRATES: loro-js/src/runtime/document.ts holds 56 of the 301 methods over the threshold \u2014 including the worst \u2014 and 1420 of the 5127 points over it (28%), 4.3\u00D7 the next-largest file (crates/loro-internal/src/loro.rs at 332). No single row can show this, because each is measured only against the threshold: reducing this one file moves this dimension further than any other file in the repository."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/document.ts"},"region":{"startLine":11461}}}],"partialFingerprints":{"codehealthFindingId/v1":"bceda59e35b05b9d05c194a26db792ba245172694fa49d71cc97dc113787dc70"}},{"ruleId":"D2","level":"warning","message":{"text":"ValueReader::recursive_read_value_type_and_content (cognitive 29): ValueReader::recursive_read_value_type_and_content has cognitive complexity 29 (threshold 15). Drivers by points: if/else 7 (17 pts), match/switch 5 (11 pts), loops 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":"crates/loro-internal/src/encoding/value.rs"},"region":{"startLine":691}}}],"partialFingerprints":{"codehealthFindingId/v1":"b349c9f071266c1a040805025ef3c26fab83eceb997fd613d03bc1c0e21a6db8"}},{"ruleId":"D2","level":"warning","message":{"text":"TextHandler::convert_pos (cognitive 29): TextHandler::convert_pos has cognitive complexity 29 (threshold 15). Drivers by points: if/else 14 (24 pts), match/switch 3 (4 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":"crates/loro-internal/src/handler.rs"},"region":{"startLine":2984}}}],"partialFingerprints":{"codehealthFindingId/v1":"b194ef72cd1dea178f151070c5bfd0102af83188a037bbead76dd2e0f3d133cc"}},{"ruleId":"D2","level":"warning","message":{"text":"LoroDoc::subscribe_jsonpath (cognitive 29): LoroDoc::subscribe_jsonpath has cognitive complexity 29 (threshold 15). Drivers by points: if/else 10 (23 pts), loops 2 (4 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":"crates/loro-internal/src/jsonpath/subscription.rs"},"region":{"startLine":258}}}],"partialFingerprints":{"codehealthFindingId/v1":"d425abf452986b887cbbc0b5bad36ce2037403479180a19298945e16c1857361"}},{"ruleId":"D2","level":"warning","message":{"text":"LoroDoc::import_blobs_as_batch (cognitive 29): LoroDoc::import_blobs_as_batch has cognitive complexity 29 (threshold 15). Drivers by points: if/else 9 (13 pts), loops 3 (8 pts), match/switch 2 (5 pts), boolean chains 3 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/loro.rs"},"region":{"startLine":3086}}}],"partialFingerprints":{"codehealthFindingId/v1":"c16af03046c1d44e36fb07dcd41baaeafc26737eb54cc29be31d68f03a44c9c3"}},{"ruleId":"D2","level":"warning","message":{"text":"UndoManager::new (cognitive 29): UndoManager::new has cognitive complexity 29 (threshold 15). Drivers by points: if/else 9 (21 pts), loops 2 (6 pts), boolean chains 1, match/switch 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":"crates/loro-internal/src/undo.rs"},"region":{"startLine":748}}}],"partialFingerprints":{"codehealthFindingId/v1":"b5dc4858b57a3cf9e41a08ef9a5a515436bd2838f16e415df33508b7f4a12b9a"}},{"ruleId":"D2","level":"warning","message":{"text":"loro_internal::state::trigger_on_new_container (cognitive 29): loro_internal::state::trigger_on_new_container has cognitive complexity 29 (threshold 15). Drivers by points: if/else 5 (18 pts), loops 4 (10 pts), match/switch 1 (nesting depth added 19). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/state.rs"},"region":{"startLine":2679}}}],"partialFingerprints":{"codehealthFindingId/v1":"48b65291de0e41aad8a7f87e6f1caf7d0c797ae5c30f3f92096f71b0017ee1d6"}},{"ruleId":"D2","level":"warning","message":{"text":"jsonpath.primitiveCompare (cognitive 29): jsonpath.primitiveCompare has cognitive complexity 29 (threshold 15). Drivers by points: if/else 8 (16 pts), boolean chains 10, ternaries 1 (2 pts), match/switch 1 (nesting depth added 9). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/jsonpath.ts"},"region":{"startLine":766}}}],"partialFingerprints":{"codehealthFindingId/v1":"08fd3a4d1333b2fbae17135d894bb5c566ecc2ea9f2ed4e16d3a7b1d8ca452ef"}},{"ruleId":"D2","level":"warning","message":{"text":"LoroDoc.#undoOperation (cognitive 29): LoroDoc.#undoOperation has cognitive complexity 29 (threshold 15). Drivers by points: if/else 11 (19 pts), ternaries 2 (5 pts), boolean chains 4, match/switch 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body. This file is where this pass\u0027s cognitive complexity CONCENTRATES: loro-js/src/runtime/document.ts holds 56 of the 301 methods over the threshold \u2014 including the worst \u2014 and 1420 of the 5127 points over it (28%), 4.3\u00D7 the next-largest file (crates/loro-internal/src/loro.rs at 332). No single row can show this, because each is measured only against the threshold: reducing this one file moves this dimension further than any other file in the repository."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/document.ts"},"region":{"startLine":3764}}}],"partialFingerprints":{"codehealthFindingId/v1":"22d60ffb37af9245642af8a3e5eb0cfc95b730c1a0d01b199ef44eda360188a8"}},{"ruleId":"D2","level":"warning","message":{"text":"LoroDoc.#validateDeferredFrontierBlocks (cognitive 29): LoroDoc.#validateDeferredFrontierBlocks has cognitive complexity 29 (threshold 15). Drivers by points: if/else 11 (22 pts), loops 4 (5 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. This file is where this pass\u0027s cognitive complexity CONCENTRATES: loro-js/src/runtime/document.ts holds 56 of the 301 methods over the threshold \u2014 including the worst \u2014 and 1420 of the 5127 points over it (28%), 4.3\u00D7 the next-largest file (crates/loro-internal/src/loro.rs at 332). No single row can show this, because each is measured only against the threshold: reducing this one file moves this dimension further than any other file in the repository."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/document.ts"},"region":{"startLine":7118}}}],"partialFingerprints":{"codehealthFindingId/v1":"8a7e69f58c50249080bc1aa57289077653e6de1b7ec1f4866206d393a02480c4"}},{"ruleId":"D2","level":"warning","message":{"text":"Tracker::_checkout (cognitive 28): Tracker::_checkout has cognitive complexity 28 (threshold 15). Drivers by points: match/switch 3 (13 pts), loops 5 (12 pts), if/else 3 (nesting depth added 17). To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/container/richtext/tracker.rs"},"region":{"startLine":393}}}],"partialFingerprints":{"codehealthFindingId/v1":"967f51ff9992101a6c41f500003dcc28dc5853ee2b8764daac433169ef1a9628"}},{"ruleId":"D2","level":"warning","message":{"text":"LoroDoc::query_pos_internal (cognitive 28): LoroDoc::query_pos_internal has cognitive complexity 28 (threshold 15). Drivers by points: if/else 11 (22 pts), match/switch 2 (6 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":"crates/loro-internal/src/loro.rs"},"region":{"startLine":3698}}}],"partialFingerprints":{"codehealthFindingId/v1":"d625aebdd278b02ef18f7d4197bfae75c76e0e7ed727a88b865a4878c218602c"}},{"ruleId":"D2","level":"warning","message":{"text":"AppDag::lazy_load_nodes_internal (cognitive 28): AppDag::lazy_load_nodes_internal has cognitive complexity 28 (threshold 15). Drivers by points: if/else 9 (19 pts), loops 4 (9 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":"crates/loro-internal/src/oplog/loro_dag.rs"},"region":{"startLine":457}}}],"partialFingerprints":{"codehealthFindingId/v1":"913f41e3e3d0f6cca5734f937d521ed82b3a7a4760b312f415e54ef30045c694"}},{"ruleId":"D2","level":"warning","message":{"text":"OpLog::uncovered_entry_parents (cognitive 28): OpLog::uncovered_entry_parents has cognitive complexity 28 (threshold 15). Drivers by points: if/else 8 (25 pts), loops 2 (3 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":"crates/loro-internal/src/oplog.rs"},"region":{"startLine":951}}}],"partialFingerprints":{"codehealthFindingId/v1":"174bf8674ebeb4edec62e533aa0365b159ff6276755b829c6cd2408a0014a3ab"}},{"ruleId":"D2","level":"warning","message":{"text":"loro_internal::state::richtext_state::snapshot::redact_dead_style_values (cognitive 28): loro_internal::state::richtext_state::snapshot::redact_dead_style_values has cognitive complexity 28 (threshold 15). Drivers by points: if/else 10 (24 pts), match/switch 1 (2 pts), boolean chains 1, 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":"crates/loro-internal/src/state/richtext_state.rs"},"region":{"startLine":1403}}}],"partialFingerprints":{"codehealthFindingId/v1":"e3c701b609e97824d846070bf62afd8eb487f6a394908d304d0d61a66bfe7874"}},{"ruleId":"D2","level":"warning","message":{"text":"loro_internal::undo::movable_list::prepare (cognitive 28): loro_internal::undo::movable_list::prepare has cognitive complexity 28 (threshold 15). Drivers by points: if/else 7 (14 pts), loops 6 (10 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":"crates/loro-internal/src/undo/movable_list.rs"},"region":{"startLine":590}}}],"partialFingerprints":{"codehealthFindingId/v1":"d7fc2b6b9e5bc101702ef266c6dbe8756aeea180f3c3a48805a51fe2e04d6ff7"}},{"ruleId":"D2","level":"warning","message":{"text":"LoroDoc.#prepareSnapshotTransition (cognitive 28): LoroDoc.#prepareSnapshotTransition has cognitive complexity 28 (threshold 15). Drivers by points: if/else 8 (19 pts), boolean chains 5, loops 3 (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. This file is where this pass\u0027s cognitive complexity CONCENTRATES: loro-js/src/runtime/document.ts holds 56 of the 301 methods over the threshold \u2014 including the worst \u2014 and 1420 of the 5127 points over it (28%), 4.3\u00D7 the next-largest file (crates/loro-internal/src/loro.rs at 332). No single row can show this, because each is measured only against the threshold: reducing this one file moves this dimension further than any other file in the repository."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/document.ts"},"region":{"startLine":6526}}}],"partialFingerprints":{"codehealthFindingId/v1":"90d387f7cd5a2a96848e85e3ed0f694758b7ba6966791ae45409eb966a740bdd"}},{"ruleId":"D2","level":"warning","message":{"text":"DeltaRope::transform_pos (cognitive 27): DeltaRope::transform_pos has cognitive complexity 27 (threshold 15). Drivers by points: if/else 7 (17 pts), match/switch 2 (6 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":"crates/delta/src/delta_rope.rs"},"region":{"startLine":296}}}],"partialFingerprints":{"codehealthFindingId/v1":"efd6545811ee7377a16c301da1d2dbd53a868cb8a60fde3c4405e4138d2660ba"}},{"ruleId":"D2","level":"warning","message":{"text":"SsTableIter::new_scan (cognitive 27): SsTableIter::new_scan has cognitive complexity 27 (threshold 15). Drivers by points: if/else 14 (23 pts), boolean chains 2, match/switch 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":"crates/kv-store/src/sstable.rs"},"region":{"startLine":646}}}],"partialFingerprints":{"codehealthFindingId/v1":"34f02f3d957e8562e544f91fbed3db9c7c7cd5e2a86785018fe04b3dbac90fd8"}},{"ruleId":"D2","level":"warning","message":{"text":"LoroDoc::undo_internal_with (cognitive 27): LoroDoc::undo_internal_with has cognitive complexity 27 (threshold 15). Drivers by points: if/else 17 (20 pts), loops 3 (4 pts), match/switch 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, 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":"crates/loro-internal/src/loro.rs"},"region":{"startLine":1565}}}],"partialFingerprints":{"codehealthFindingId/v1":"a22b3f4a8b5486b171735da2d88a40f0e1a06ffd83b185c5635a0ae8059dd557"}},{"ruleId":"D2","level":"warning","message":{"text":"ChangeStore::export_blocks_in_range (cognitive 27): ChangeStore::export_blocks_in_range has cognitive complexity 27 (threshold 15). Drivers by points: if/else 4 (12 pts), loops 7 (12 pts), match/switch 1 (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":"crates/loro-internal/src/oplog/change_store.rs"},"region":{"startLine":412}}}],"partialFingerprints":{"codehealthFindingId/v1":"bbecf5936e721b6a477a90f81c25f9278fde4a535992864e1c3798efaffc3bd4"}},{"ruleId":"D2","level":"warning","message":{"text":"Plan::apply_native (cognitive 27): Plan::apply_native has cognitive complexity 27 (threshold 15). Drivers by points: if/else 7 (17 pts), match/switch 3 (9 pts), loops 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":"crates/loro-internal/src/undo/movable_list.rs"},"region":{"startLine":763}}}],"partialFingerprints":{"codehealthFindingId/v1":"efed3d1f1dce1500fcbad6602feff369f90f5380807869c39f8a22340683852a"}},{"ruleId":"D2","level":"warning","message":{"text":"loro_internal::container::richtext::richtext_state::pos_type_offset_to_entity_offset (cognitive 27): loro_internal::container::richtext::richtext_state::pos_type_offset_to_entity_offset has cognitive complexity 27 (threshold 15). Drivers by points: if/else 11 (20 pts), match/switch 4 (7 pts) (nesting depth added 12). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/container/richtext/richtext_state.rs"},"region":{"startLine":3002}}}],"partialFingerprints":{"codehealthFindingId/v1":"40865a4c3225a5fdd641ee4a1051a990fa99f2efab4c95b4bdb237d331910eb1"}},{"ruleId":"D2","level":"warning","message":{"text":"loro_wasm::convert::js_value_to_loro_value (cognitive 27): loro_wasm::convert::js_value_to_loro_value has cognitive complexity 27 (threshold 15). Drivers by points: if/else 13 (18 pts), loops 3 (7 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":"crates/loro-wasm/src/convert.rs"},"region":{"startLine":661}}}],"partialFingerprints":{"codehealthFindingId/v1":"ae82068f1111a936b32ab59fc3a1e3ba0253b53b5973979be8bb753433032bfe"}},{"ruleId":"D2","level":"warning","message":{"text":"leb128.writeSleb128 (cognitive 27): leb128.writeSleb128 has cognitive complexity 27 (threshold 15). Drivers by points: boolean chains 9, if/else 5 (9 pts), ternaries 4 (6 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":"loro-js/src/codec/leb128.ts"},"region":{"startLine":94}}}],"partialFingerprints":{"codehealthFindingId/v1":"6b464e20d846b52361496ad2763c742bdcb04cf48b5127d2249ce8e16c5b8c0c"}},{"ruleId":"D2","level":"warning","message":{"text":"change-block-codec.encodeChangeBlock (cognitive 27): change-block-codec.encodeChangeBlock has cognitive complexity 27 (threshold 15). Drivers by points: if/else 11 (18 pts), loops 5 (7 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":"loro-js/src/codec/change-block-codec.ts"},"region":{"startLine":234}}}],"partialFingerprints":{"codehealthFindingId/v1":"6f7e4fe72300d86f65d3ac2860550c9b06261be236966574eb7f0a17ba6166bf"}},{"ruleId":"D2","level":"warning","message":{"text":"SequenceIndex.visibleIndexOfWidthElement (cognitive 27): SequenceIndex.visibleIndexOfWidthElement has cognitive complexity 27 (threshold 15). Drivers by points: if/else 8 (22 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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":800}}}],"partialFingerprints":{"codehealthFindingId/v1":"463843fc95200eab78bb96b29040c409b64100714e67b080bdc7fb642cb101e7"}},{"ruleId":"D2","level":"warning","message":{"text":"sequence-index.visitVisibleIdRuns (cognitive 27): sequence-index.visitVisibleIdRuns has cognitive complexity 27 (threshold 15). Drivers by points: if/else 10 (20 pts), boolean chains 4, loops 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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":3469}}}],"partialFingerprints":{"codehealthFindingId/v1":"7e9494fd4880b1b7c268dfe4aa1856d932309a13166f74ad09f3ab36d718a556"}},{"ruleId":"D2","level":"warning","message":{"text":"jsonpath.tokenizeFilter (cognitive 27): jsonpath.tokenizeFilter has cognitive complexity 27 (threshold 15). Drivers by points: if/else 12 (22 pts), boolean chains 4, 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":"loro-js/src/runtime/jsonpath.ts"},"region":{"startLine":620}}}],"partialFingerprints":{"codehealthFindingId/v1":"6f0051944cdc61f3b8b788d10760046b9822d8e1c8ff74a6ec8a215f54137c68"}},{"ruleId":"D2","level":"warning","message":{"text":"jsonpath.callFilterFunction (cognitive 27): jsonpath.callFilterFunction has cognitive complexity 27 (threshold 15). Drivers by points: if/else 11 (19 pts), ternaries 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":"loro-js/src/runtime/jsonpath.ts"},"region":{"startLine":799}}}],"partialFingerprints":{"codehealthFindingId/v1":"af1ee3e8213f6d29a6036a71574e1880f288173a6a5d088b5c6cf14c8dc4946b"}},{"ruleId":"D2","level":"warning","message":{"text":"LoroDoc.#planSnapshotStates (cognitive 27): LoroDoc.#planSnapshotStates has cognitive complexity 27 (threshold 15). Drivers by points: if/else 7 (17 pts), loops 4 (7 pts), boolean chains 3 (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body. This file is where this pass\u0027s cognitive complexity CONCENTRATES: loro-js/src/runtime/document.ts holds 56 of the 301 methods over the threshold \u2014 including the worst \u2014 and 1420 of the 5127 points over it (28%), 4.3\u00D7 the next-largest file (crates/loro-internal/src/loro.rs at 332). No single row can show this, because each is measured only against the threshold: reducing this one file moves this dimension further than any other file in the repository."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/document.ts"},"region":{"startLine":6763}}}],"partialFingerprints":{"codehealthFindingId/v1":"44c7cc3b20c6217961723cb96f58bcf37c3bb92dd35b38e78bb448b399226fc8"}},{"ruleId":"D2","level":"warning","message":{"text":"containers.fugueDescendsFrom (cognitive 27): containers.fugueDescendsFrom has cognitive complexity 27 (threshold 15). Drivers by points: if/else 8 (18 pts), loops 2 (4 pts), boolean chains 3, 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":"loro-js/src/runtime/containers.ts"},"region":{"startLine":3814}}}],"partialFingerprints":{"codehealthFindingId/v1":"e0ab4ba7e963e3dbf8bf4c15469cdc6c13d1045d0936cb9bacd4f241dda60b94"}},{"ruleId":"D2","level":"warning","message":{"text":"loro_common::value::values_eq (cognitive 26): loro_common::value::values_eq has cognitive complexity 26 (threshold 15). Drivers by points: if/else 7 (12 pts), match/switch 2 (7 pts), loops 2 (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":"crates/loro-common/src/value.rs"},"region":{"startLine":46}}}],"partialFingerprints":{"codehealthFindingId/v1":"3b4ee035cb2ff617629048e2e8ae2cf1a30053387bfa50c0bd469a3b662b24cf"}},{"ruleId":"D2","level":"warning","message":{"text":"DeleteSpanWithId::is_mergable (cognitive 26): DeleteSpanWithId::is_mergable has cognitive complexity 26 (threshold 15). Drivers by points: if/else 12 (21 pts), boolean chains 4, match/switch 1 (nesting depth added 9). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/container/list/list_op.rs"},"region":{"startLine":228}}}],"partialFingerprints":{"codehealthFindingId/v1":"3f2aa08490f1e0e6b79f9ff27a68c257696e01a55532d583c5941685df608abf"}},{"ruleId":"D2","level":"warning","message":{"text":"InsertSet::update_many (cognitive 26): InsertSet::update_many has cognitive complexity 26 (threshold 15). Drivers by points: loops 8 (17 pts), if/else 6 (8 pts), match/switch 1 (nesting depth added 11). To reduce it, break up the iteration: give each loop body a named function, and split a multi-phase loop into one function per phase so no single body carries the whole pipeline."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/container/richtext/tracker/id_to_cursor.rs"},"region":{"startLine":423}}}],"partialFingerprints":{"codehealthFindingId/v1":"22e5ebcf11735191aa98f9fff0d27739258163bd970b6cd305e3585de36e8759"}},{"ruleId":"D2","level":"warning","message":{"text":"TreeDiff::try_from (cognitive 26): TreeDiff::try_from has cognitive complexity 26 (threshold 15). Drivers by points: if/else 10 (19 pts), boolean chains 4, match/switch 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":"crates/loro-internal/src/value.rs"},"region":{"startLine":871}}}],"partialFingerprints":{"codehealthFindingId/v1":"9ad39d56cff42502e16ef13e4b6198ea0f9bccc23772bf3f14fd0080dad44c10"}},{"ruleId":"D2","level":"warning","message":{"text":"ListDiffCalculator::calculate_diff::handle_unknown (cognitive 26): ListDiffCalculator::calculate_diff::handle_unknown has cognitive complexity 26 (threshold 15). Drivers by points: if/else 6 (15 pts), loops 3 (8 pts), match/switch 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. This shape REPEATS in the file: one other method here (ListDiffCalculator::calculate_diff) 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":"crates/loro-internal/src/diff_calc.rs"},"region":{"startLine":1038}}}],"partialFingerprints":{"codehealthFindingId/v1":"7f2af1b39fe83922abd8fe22261e8e0c926fecfb97c3fb0d3d0f4c9061d862fb"}},{"ruleId":"D2","level":"warning","message":{"text":"DocState::unreached_stored_containers (cognitive 26): DocState::unreached_stored_containers has cognitive complexity 26 (threshold 15). Drivers by points: if/else 8 (19 pts), loops 3 (4 pts), match/switch 1 (2 pts), boolean chains 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":"crates/loro-internal/src/state.rs"},"region":{"startLine":1864}}}],"partialFingerprints":{"codehealthFindingId/v1":"e86589eca46829446ba3531378e58cd03ee5caaad6d248229f2c82a96d146cd7"}},{"ruleId":"D2","level":"warning","message":{"text":"loro_internal::encoding::json_schema::json::redact_op (cognitive 26): loro_internal::encoding::json_schema::json::redact_op has cognitive complexity 26 (threshold 15). Drivers by points: match/switch 6 (11 pts), loops 3 (9 pts), if/else 2 (5 pts), boolean chains 1 (nesting depth added 14). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/encoding/json_schema.rs"},"region":{"startLine":1791}}}],"partialFingerprints":{"codehealthFindingId/v1":"131ad871dfae21f569808e742426ee418a637334bb363d1ecd776aaf644098f0"}},{"ruleId":"D2","level":"warning","message":{"text":"loro_internal::encoding::outdated_encode_reordered::decode_op (cognitive 26): loro_internal::encoding::outdated_encode_reordered::decode_op has cognitive complexity 26 (threshold 15). Drivers by points: if/else 6 (13 pts), match/switch 7 (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":"crates/loro-internal/src/encoding/outdated_encode_reordered.rs"},"region":{"startLine":288}}}],"partialFingerprints":{"codehealthFindingId/v1":"2bbb6769f86ebdd69d234913e5c1230a833264a9e5de4bfe2e05f10318e1731b"}},{"ruleId":"D2","level":"warning","message":{"text":"loro_internal::undo::movable_list::complete_anchors (cognitive 26): loro_internal::undo::movable_list::complete_anchors has cognitive complexity 26 (threshold 15). Drivers by points: if/else 5 (15 pts), loops 4 (11 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":"crates/loro-internal/src/undo/movable_list.rs"},"region":{"startLine":278}}}],"partialFingerprints":{"codehealthFindingId/v1":"d2d49f822502963d55ac13e4dee8d4d73e40820dac91032a4ebf32a80a993c09"}},{"ruleId":"D2","level":"warning","message":{"text":"LoroDoc.#applyTreeDiff (cognitive 26): LoroDoc.#applyTreeDiff has cognitive complexity 26 (threshold 15). Drivers by points: if/else 6 (16 pts), ternaries 3 (5 pts), loops 2 (3 pts), boolean chains 2 (nesting depth added 13). Of this number, 23 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. This file is where this pass\u0027s cognitive complexity CONCENTRATES: loro-js/src/runtime/document.ts holds 56 of the 301 methods over the threshold \u2014 including the worst \u2014 and 1420 of the 5127 points over it (28%), 4.3\u00D7 the next-largest file (crates/loro-internal/src/loro.rs at 332). No single row can show this, because each is measured only against the threshold: reducing this one file moves this dimension further than any other file in the repository."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/document.ts"},"region":{"startLine":2693}}}],"partialFingerprints":{"codehealthFindingId/v1":"9bcadc43c958be1150cb00d15e761f66b0d351eb016755cc68ebfbfe296c96c9"}},{"ruleId":"D2","level":"warning","message":{"text":"document.containerDiff (cognitive 26): document.containerDiff has cognitive complexity 26 (threshold 15). Drivers by points: if/else 7 (11 pts), ternaries 5 (10 pts), boolean chains 3, loops 1 (2 pts) (nesting depth added 10). Of this number, 25 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body. This file is where this pass\u0027s cognitive complexity CONCENTRATES: loro-js/src/runtime/document.ts holds 56 of the 301 methods over the threshold \u2014 including the worst \u2014 and 1420 of the 5127 points over it (28%), 4.3\u00D7 the next-largest file (crates/loro-internal/src/loro.rs at 332). No single row can show this, because each is measured only against the threshold: reducing this one file moves this dimension further than any other file in the repository."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/document.ts"},"region":{"startLine":10702}}}],"partialFingerprints":{"codehealthFindingId/v1":"007e065468d246c792f36c718ad2c3557036886ff11bbe92423090a1f20d872d"}},{"ruleId":"D2","level":"warning","message":{"text":"Delta::push (cognitive 25): Delta::push has cognitive complexity 25 (threshold 15). Drivers by points: if/else 10 (17 pts), boolean chains 4, match/switch 1 (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":"crates/loro-internal/src/delta/seq.rs"},"region":{"startLine":435}}}],"partialFingerprints":{"codehealthFindingId/v1":"63541a50231836c0ca91e4b8d314da34778be6eba70b8685dba1032e25bbba07"}},{"ruleId":"D2","level":"warning","message":{"text":"AppDag::check_dag_correctness (cognitive 25): AppDag::check_dag_correctness has cognitive complexity 25 (threshold 15). Drivers by points: loops 10 (14 pts), if/else 5 (11 pts) (nesting depth added 10). To reduce it, break up the iteration: give each loop body a named function, and split a multi-phase loop into one function per phase so no single body carries the whole pipeline."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/oplog/loro_dag.rs"},"region":{"startLine":659}}}],"partialFingerprints":{"codehealthFindingId/v1":"3df7b025ab7923f250045d8bb71bb4fd02ebf4f11e29849d9d29766136b6bed7"}},{"ruleId":"D2","level":"warning","message":{"text":"ListState::delete_range (cognitive 25): ListState::delete_range has cognitive complexity 25 (threshold 15). Drivers by points: if/else 9 (20 pts), loops 2 (3 pts), match/switch 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":"crates/loro-internal/src/state/list_state.rs"},"region":{"startLine":397}}}],"partialFingerprints":{"codehealthFindingId/v1":"099814981e448e1087c46c081216a41e0836fc37d2b04932aa1f6c4ef0beb624"}},{"ruleId":"D2","level":"warning","message":{"text":"loro_internal::dag::_find_meet_and_mode::new_region_after_all_left_heads (cognitive 25): loro_internal::dag::_find_meet_and_mode::new_region_after_all_left_heads has cognitive complexity 25 (threshold 15). Drivers by points: if/else 10 (21 pts), loops 3 (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. This shape REPEATS in the file: 2 other methods here (loro_internal::dag::_find_meet_and_mode, loro_internal::dag::_find_meet_and_mode::all_tips_covered_by_ancestors) 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":"crates/loro-internal/src/dag.rs"},"region":{"startLine":942}}}],"partialFingerprints":{"codehealthFindingId/v1":"ef2a048f4b78591c6fdf7ff722e49cceb1c45911f712738a54a36a3f5a7c5e90"}},{"ruleId":"D2","level":"warning","message":{"text":"loro_internal::undo::movable_list::scopes (cognitive 25): loro_internal::undo::movable_list::scopes has cognitive complexity 25 (threshold 15). Drivers by points: if/else 3 (11 pts), loops 4 (8 pts), match/switch 2 (6 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":"crates/loro-internal/src/undo/movable_list.rs"},"region":{"startLine":56}}}],"partialFingerprints":{"codehealthFindingId/v1":"5431eaa23d18245fe2a026d6fc03983c35125c723e794cf763572f8c892f7547"}},{"ruleId":"D2","level":"warning","message":{"text":"loro_wasm::convert::js_value_to_list_diff (cognitive 25): loro_wasm::convert::js_value_to_list_diff has cognitive complexity 25 (threshold 15). Drivers by points: if/else 7 (20 pts), loops 2 (4 pts), boolean chains 1 (nesting depth added 15). 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":"crates/loro-wasm/src/convert.rs"},"region":{"startLine":601}}}],"partialFingerprints":{"codehealthFindingId/v1":"793255e8f087419d82c9ec8c47958d0a46c67c2f3c5eacdb0ffe8fc9e060ab8a"}},{"ruleId":"D2","level":"warning","message":{"text":"document.jsonValueToChangeLoroValue (cognitive 25): document.jsonValueToChangeLoroValue has cognitive complexity 25 (threshold 15). Drivers by points: if/else 12 (21 pts), boolean chains 2, ternaries 1 (2 pts) (nesting depth added 10). Of this number, 23 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. This file is where this pass\u0027s cognitive complexity CONCENTRATES: loro-js/src/runtime/document.ts holds 56 of the 301 methods over the threshold \u2014 including the worst \u2014 and 1420 of the 5127 points over it (28%), 4.3\u00D7 the next-largest file (crates/loro-internal/src/loro.rs at 332). No single row can show this, because each is measured only against the threshold: reducing this one file moves this dimension further than any other file in the repository."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/document.ts"},"region":{"startLine":10439}}}],"partialFingerprints":{"codehealthFindingId/v1":"dcdc205b9e27eec2aae67182134c68b8f5573df67ed55d63ee153237fd4f9dca"}},{"ruleId":"D2","level":"warning","message":{"text":"LoroText.#insertOverrides (cognitive 25): LoroText.#insertOverrides has cognitive complexity 25 (threshold 15). Drivers by points: if/else 5 (12 pts), loops 4 (9 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":"loro-js/src/runtime/containers.ts"},"region":{"startLine":2291}}}],"partialFingerprints":{"codehealthFindingId/v1":"f34d4028156a3e822cfe1055bd4f8e32e4f562f70c134aa60348e7fa347d0d39"}},{"ruleId":"D2","level":"warning","message":{"text":"DagIteratorVV::next (cognitive 24): DagIteratorVV::next has cognitive complexity 24 (threshold 15). Drivers by points: if/else 9 (20 pts), loops 2 (4 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":"crates/loro-internal/src/dag/iter.rs"},"region":{"startLine":111}}}],"partialFingerprints":{"codehealthFindingId/v1":"f5b2ad6bc92a3247cecb4cc1bc5098b4b3211799a61edee02dcdd5ec39267eb3"}},{"ruleId":"D2","level":"warning","message":{"text":"DocState::diffs_to_event (cognitive 24): DocState::diffs_to_event has cognitive complexity 24 (threshold 15). Drivers by points: if/else 9 (18 pts), loops 2 (3 pts), boolean chains 2, match/switch 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":"crates/loro-internal/src/state.rs"},"region":{"startLine":2118}}}],"partialFingerprints":{"codehealthFindingId/v1":"820b40b7ef93834722ffc57597841a4af0737e1172292c2e8a78581a1c4e7e04"}},{"ruleId":"D2","level":"warning","message":{"text":"loro_internal::encoding::shallow_snapshot::estimate_ops_content_bytes (cognitive 24): loro_internal::encoding::shallow_snapshot::estimate_ops_content_bytes has cognitive complexity 24 (threshold 15). Drivers by points: if/else 6 (18 pts), loops 3 (6 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":"crates/loro-internal/src/encoding/shallow_snapshot.rs"},"region":{"startLine":72}}}],"partialFingerprints":{"codehealthFindingId/v1":"195f9c20ac4add44ebb307e4e9451dacaa4febbcb70fccdf41f8dce7be38b5b0"}},{"ruleId":"D2","level":"warning","message":{"text":"loro_internal::oplog::change_store::block_encode::decode_block (cognitive 24): loro_internal::oplog::change_store::block_encode::decode_block has cognitive complexity 24 (threshold 15). Drivers by points: if/else 10 (15 pts), loops 4, match/switch 2 (4 pts), boolean chains 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/oplog/change_store/block_encode.rs"},"region":{"startLine":610}}}],"partialFingerprints":{"codehealthFindingId/v1":"f1ff02be6b9f5f9db8aa90676903dbb579340ace0be1dcea85ed88e35962fc4a"}},{"ruleId":"D2","level":"warning","message":{"text":"index.LoroDoc.toJsonWithReplacer::m (cognitive 24): index.LoroDoc.toJsonWithReplacer::m has cognitive complexity 24 (threshold 15). Drivers by points: if/else 9 (21 pts), boolean chains 3 (nesting depth added 12). 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":"crates/loro-wasm/index.ts"},"region":{"startLine":345}}}],"partialFingerprints":{"codehealthFindingId/v1":"ead8a50399df9de0c8a5c61fe79e04ad1dba719b7a88ca78eff551b6e8ffd408"}},{"ruleId":"D2","level":"warning","message":{"text":"leb128.readSleb128 (cognitive 24): leb128.readSleb128 has cognitive complexity 24 (threshold 15). Drivers by points: if/else 6 (17 pts), ternaries 1 (3 pts), boolean chains 2, loops 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":"loro-js/src/codec/leb128.ts"},"region":{"startLine":56}}}],"partialFingerprints":{"codehealthFindingId/v1":"d1b942ffa90a2f331cfcec4f298c31324b39aa5cc7cd933a0f225d1d4683892a"}},{"ruleId":"D2","level":"warning","message":{"text":"LoroDoc.#attachedChildren (cognitive 24): LoroDoc.#attachedChildren has cognitive complexity 24 (threshold 15). Drivers by points: if/else 7 (13 pts), loops 4 (9 pts), boolean chains 1, ternaries 1 (nesting depth added 11). Of this number, 22 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. This file is where this pass\u0027s cognitive complexity CONCENTRATES: loro-js/src/runtime/document.ts holds 56 of the 301 methods over the threshold \u2014 including the worst \u2014 and 1420 of the 5127 points over it (28%), 4.3\u00D7 the next-largest file (crates/loro-internal/src/loro.rs at 332). No single row can show this, because each is measured only against the threshold: reducing this one file moves this dimension further than any other file in the repository."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/document.ts"},"region":{"startLine":2372}}}],"partialFingerprints":{"codehealthFindingId/v1":"c00a7cf7ddef9dee2b708360ab265510684e8a89ebef5aeed0d9e065d2ae6982"}},{"ruleId":"D2","level":"warning","message":{"text":"LoroDoc.#prepareSnapshotImport (cognitive 24): LoroDoc.#prepareSnapshotImport has cognitive complexity 24 (threshold 15). Drivers by points: if/else 5 (13 pts), boolean chains 7, 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. This file is where this pass\u0027s cognitive complexity CONCENTRATES: loro-js/src/runtime/document.ts holds 56 of the 301 methods over the threshold \u2014 including the worst \u2014 and 1420 of the 5127 points over it (28%), 4.3\u00D7 the next-largest file (crates/loro-internal/src/loro.rs at 332). No single row can show this, because each is measured only against the threshold: reducing this one file moves this dimension further than any other file in the repository."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/document.ts"},"region":{"startLine":6459}}}],"partialFingerprints":{"codehealthFindingId/v1":"8528dadb679403821d6c87c50f5d699bde8a163b51459977f33e51b942f7eeda"}},{"ruleId":"D2","level":"warning","message":{"text":"document.recoverParentBinding (cognitive 24): document.recoverParentBinding has cognitive complexity 24 (threshold 15). Drivers by points: if/else 8 (16 pts), loops 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. This file is where this pass\u0027s cognitive complexity CONCENTRATES: loro-js/src/runtime/document.ts holds 56 of the 301 methods over the threshold \u2014 including the worst \u2014 and 1420 of the 5127 points over it (28%), 4.3\u00D7 the next-largest file (crates/loro-internal/src/loro.rs at 332). No single row can show this, because each is measured only against the threshold: reducing this one file moves this dimension further than any other file in the repository."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/document.ts"},"region":{"startLine":11419}}}],"partialFingerprints":{"codehealthFindingId/v1":"25167690d6104c5f26cf089978738b1c1738782968939ba42c53955536edf4f9"}},{"ruleId":"D2","level":"warning","message":{"text":"LoroText.iter (cognitive 24): LoroText.iter has cognitive complexity 24 (threshold 15). Drivers by points: if/else 8 (16 pts), boolean chains 5, loops 2 (3 pts) (nesting depth added 9). Most of this is not in the body itself: 2 of the 24 points are its own statements and the rest belongs to 3 function items inside it that branch (a function literal at line 1497, append, a function literal at line 1537). 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":"loro-js/src/runtime/containers.ts"},"region":{"startLine":1466}}}],"partialFingerprints":{"codehealthFindingId/v1":"47c5479c92c98c5343841d28d8f4c081f3ec15e65b6642f947166a932d4931b8"}},{"ruleId":"D2","level":"warning","message":{"text":"containers.scannedFugueInsertion (cognitive 24): containers.scannedFugueInsertion has cognitive complexity 24 (threshold 15). Drivers by points: if/else 9 (20 pts), boolean chains 3, 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":"loro-js/src/runtime/containers.ts"},"region":{"startLine":3672}}}],"partialFingerprints":{"codehealthFindingId/v1":"6ab1e010bcd45ae4b94e7daae731dffe7bf787356eaab40e8768b200dd06fc94"}},{"ruleId":"D2","level":"warning","message":{"text":"UndoManager.#record (cognitive 24): UndoManager.#record has cognitive complexity 24 (threshold 15). Drivers by points: if/else 9 (10 pts), loops 4 (8 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":"loro-js/src/runtime/undo.ts"},"region":{"startLine":239}}}],"partialFingerprints":{"codehealthFindingId/v1":"93bd59f58e140b6d583969b7219a0fdbedb3de15b3c8f78c2f2075eca184c3fb"}},{"ruleId":"D2","level":"warning","message":{"text":"BTree::update_dirty_cache_map (cognitive 23): BTree::update_dirty_cache_map has cognitive complexity 23 (threshold 15). Drivers by points: if/else 4 (13 pts), loops 3 (7 pts), match/switch 1 (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":"crates/generic-btree/src/lib.rs"},"region":{"startLine":1520}}}],"partialFingerprints":{"codehealthFindingId/v1":"f9a4c7dd305c1fbc339f7d7f6d45c4f283177e1cdb00311f4677c37f9df79aa4"}},{"ruleId":"D2","level":"warning","message":{"text":"MemStoreIterator::next (cognitive 23): MemStoreIterator::next has cognitive complexity 23 (threshold 15). Drivers by points: if/else 6 (16 pts), match/switch 2 (5 pts), boolean chains 1, 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":"crates/kv-store/src/mem_store.rs"},"region":{"startLine":442}}}],"partialFingerprints":{"codehealthFindingId/v1":"9f03c6ab69ec2dfb8943fbdcf07d16561fcf0de7bf0f893d22daf6125d31300e"}},{"ruleId":"D2","level":"warning","message":{"text":"TextChunk::_slice (cognitive 23): TextChunk::_slice has cognitive complexity 23 (threshold 15). Drivers by points: if/else 10 (17 pts), loops 3 (5 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":"crates/loro-internal/src/container/richtext/richtext_state.rs"},"region":{"startLine":583}}}],"partialFingerprints":{"codehealthFindingId/v1":"f782b7452d0e0169658cbecf4389d1b5e47bedebe65db86cfe44f7d7bc23d2d2"}},{"ruleId":"D2","level":"warning","message":{"text":"DagCausalIter::try_new (cognitive 23): DagCausalIter::try_new has cognitive complexity 23 (threshold 15). Drivers by points: if/else 8 (16 pts), loops 5 (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":"crates/loro-internal/src/dag/iter.rs"},"region":{"startLine":205}}}],"partialFingerprints":{"codehealthFindingId/v1":"7b3df9e30eef5f32e6205a39fb8b1897edb309de065e4837533269827f745a31"}},{"ruleId":"D2","level":"warning","message":{"text":"ListDiffCalculator::calculate_diff (cognitive 23): ListDiffCalculator::calculate_diff has cognitive complexity 23 (threshold 15). Drivers by points: if/else 9 (22 pts), loops 5 (13 pts), match/switch 3 (8 pts), boolean chains 6 (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. This shape REPEATS in the file: one other method here (ListDiffCalculator::calculate_diff::handle_unknown) 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":"crates/loro-internal/src/diff_calc.rs"},"region":{"startLine":945}}}],"partialFingerprints":{"codehealthFindingId/v1":"0d8d90c2d94130d9a3634a05c2e99ed0d9273e081fc80b766f3b9eb6fa0e6d35"}},{"ruleId":"D2","level":"warning","message":{"text":"SequenceIndex.compact (cognitive 23): SequenceIndex.compact has cognitive complexity 23 (threshold 15). Drivers by points: if/else 10 (12 pts), ternaries 2 (6 pts), boolean chains 3, loops 2 (nesting depth added 6). Most of this is not in the body itself: 9 of the 23 points are its own statements and the rest belongs to 3 function items inside it that branch (flushElements, a function literal at line 1768, appendSpan). 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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":1734}}}],"partialFingerprints":{"codehealthFindingId/v1":"f1124a59ad926f9fb9ef081f7c5e3505da8422eac3dacb8152dd1410030ebd1e"}},{"ruleId":"D2","level":"warning","message":{"text":"SequenceIndex.#finishSpanAppend (cognitive 23): SequenceIndex.#finishSpanAppend has cognitive complexity 23 (threshold 15). Drivers by points: if/else 9 (16 pts), ternaries 3 (5 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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":2237}}}],"partialFingerprints":{"codehealthFindingId/v1":"2568b4e453f06b2c8522c4065a2ae0c754cdc7438c5a6b1423e6e4bb3488ff47"}},{"ruleId":"D2","level":"warning","message":{"text":"LoroDoc.#deleteInsertedElements (cognitive 23): LoroDoc.#deleteInsertedElements has cognitive complexity 23 (threshold 15). Drivers by points: if/else 9 (17 pts), boolean chains 3, loops 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. This file is where this pass\u0027s cognitive complexity CONCENTRATES: loro-js/src/runtime/document.ts holds 56 of the 301 methods over the threshold \u2014 including the worst \u2014 and 1420 of the 5127 points over it (28%), 4.3\u00D7 the next-largest file (crates/loro-internal/src/loro.rs at 332). No single row can show this, because each is measured only against the threshold: reducing this one file moves this dimension further than any other file in the repository."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/document.ts"},"region":{"startLine":3854}}}],"partialFingerprints":{"codehealthFindingId/v1":"e31e53c258ed373ec917a8b84afd1fc231b0ec8473293519fba3c1612a601fd0"}},{"ruleId":"D2","level":"warning","message":{"text":"LoroDoc.#restoreDeletedElements (cognitive 23): LoroDoc.#restoreDeletedElements has cognitive complexity 23 (threshold 15). Drivers by points: if/else 7 (14 pts), loops 3 (5 pts), boolean chains 4 (nesting depth added 9). Of this number, 17 points are the body\u0027s own statements and 6 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. This file is where this pass\u0027s cognitive complexity CONCENTRATES: loro-js/src/runtime/document.ts holds 56 of the 301 methods over the threshold \u2014 including the worst \u2014 and 1420 of the 5127 points over it (28%), 4.3\u00D7 the next-largest file (crates/loro-internal/src/loro.rs at 332). No single row can show this, because each is measured only against the threshold: reducing this one file moves this dimension further than any other file in the repository."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/document.ts"},"region":{"startLine":3896}}}],"partialFingerprints":{"codehealthFindingId/v1":"82de3112d8d140ed4e7f5b66db7552d4478dcb9c2463aacf1e7b526b671fe30c"}},{"ruleId":"D2","level":"warning","message":{"text":"document.alignText (cognitive 23): document.alignText has cognitive complexity 23 (threshold 15). Drivers by points: if/else 7 (12 pts), loops 5 (6 pts), boolean chains 3, ternaries 2 (nesting depth added 6). Of this number, 21 points are the body\u0027s own statements and 2 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. This file is where this pass\u0027s cognitive complexity CONCENTRATES: loro-js/src/runtime/document.ts holds 56 of the 301 methods over the threshold \u2014 including the worst \u2014 and 1420 of the 5127 points over it (28%), 4.3\u00D7 the next-largest file (crates/loro-internal/src/loro.rs at 332). No single row can show this, because each is measured only against the threshold: reducing this one file moves this dimension further than any other file in the repository."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/document.ts"},"region":{"startLine":11328}}}],"partialFingerprints":{"codehealthFindingId/v1":"0941ac9ca157c3e6ea7dc3917fc1f21ca719156cc1fa167900f4759151761386"}},{"ruleId":"D2","level":"warning","message":{"text":"DeltaItem::update_with_split (cognitive 22): DeltaItem::update_with_split has cognitive complexity 22 (threshold 15). Drivers by points: if/else 12 (19 pts), match/switch 3 (nesting depth added 7). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/delta/src/delta_item.rs"},"region":{"startLine":213}}}],"partialFingerprints":{"codehealthFindingId/v1":"3750ef61b4da9c13c2e1b1bdb2d93ec0401dee3abacfe17db510115583ac8603"}},{"ruleId":"D2","level":"warning","message":{"text":"TextHandler::apply_delta_with_txn (cognitive 22): TextHandler::apply_delta_with_txn has cognitive complexity 22 (threshold 15). Drivers by points: loops 5 (11 pts), match/switch 3 (6 pts), if/else 2 (5 pts) (nesting depth added 12). To reduce it, break up the iteration: give each loop body a named function, and split a multi-phase loop into one function per phase so no single body carries the whole pipeline."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/handler.rs"},"region":{"startLine":2692}}}],"partialFingerprints":{"codehealthFindingId/v1":"9d2502119464e04543926c1c304a71b89d455ac569a6113c758ea6d39bbb5cc5"}},{"ruleId":"D2","level":"warning","message":{"text":"PendingChangesRollback::rollback (cognitive 22): PendingChangesRollback::rollback has cognitive complexity 22 (threshold 15). Drivers by points: if/else 4 (13 pts), match/switch 3 (7 pts), loops 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":"crates/loro-internal/src/oplog/pending_changes.rs"},"region":{"startLine":441}}}],"partialFingerprints":{"codehealthFindingId/v1":"1ed9895296e0679f3afbdb280f6f989e8f02424af09f4d3dacd192dd76c7d809"}},{"ruleId":"D2","level":"warning","message":{"text":"OpLog::check_known_text_in_cold_block (cognitive 22): OpLog::check_known_text_in_cold_block has cognitive complexity 22 (threshold 15). Drivers by points: if/else 12 (19 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":"crates/loro-internal/src/oplog/known_history.rs"},"region":{"startLine":519}}}],"partialFingerprints":{"codehealthFindingId/v1":"45e8edf85a57c2905c59f982710e37b4d8ad287e08759cf40dd9a98dc8fa4b8d"}},{"ruleId":"D2","level":"warning","message":{"text":"loro_internal::encoding::json_schema::validate_json_op_created_container_ids (cognitive 22): loro_internal::encoding::json_schema::validate_json_op_created_container_ids has cognitive complexity 22 (threshold 15). Drivers by points: if/else 7 (16 pts), loops 1 (3 pts), match/switch 2 (3 pts) (nesting depth added 12). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/encoding/json_schema.rs"},"region":{"startLine":672}}}],"partialFingerprints":{"codehealthFindingId/v1":"4447c0651db52bb7315953e938817c0eaafe22849c93b529ae0eb8814633f001"}},{"ruleId":"D2","level":"warning","message":{"text":"lz4.decodeLz4Frame (cognitive 22): lz4.decodeLz4Frame has cognitive complexity 22 (threshold 15). Drivers by points: if/else 12 (18 pts), ternaries 1 (3 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":"loro-js/src/codec/lz4.ts"},"region":{"startLine":20}}}],"partialFingerprints":{"codehealthFindingId/v1":"8584551069411f9fa32b506cd22d8ba57839e5c118e77ff1b9b5e6f429d8feb6"}},{"ruleId":"D2","level":"warning","message":{"text":"SequenceDeletionIndex.hasDeletionAt (cognitive 22): SequenceDeletionIndex.hasDeletionAt has cognitive complexity 22 (threshold 15). Drivers by points: if/else 4 (12 pts), loops 3 (6 pts), 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":"loro-js/src/runtime/sequence-deletion-index.ts"},"region":{"startLine":132}}}],"partialFingerprints":{"codehealthFindingId/v1":"b987f1168a306ac9028ed8f0c907d18a047f9600e792503d1708744a4622ecf3"}},{"ruleId":"D2","level":"warning","message":{"text":"SequenceIndex.zeroWidthBeforeVisibleIndex (cognitive 22): SequenceIndex.zeroWidthBeforeVisibleIndex has cognitive complexity 22 (threshold 15). Drivers by points: if/else 6 (16 pts), loops 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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":764}}}],"partialFingerprints":{"codehealthFindingId/v1":"0928e86dd2994f5a135234fa8e3c3174ecf68e86001be5c4a349ad9e15c2fd78"}},{"ruleId":"D2","level":"warning","message":{"text":"SequenceIndex.visibleIndexAfterLineBreaks (cognitive 22): SequenceIndex.visibleIndexAfterLineBreaks has cognitive complexity 22 (threshold 15). Drivers by points: if/else 7 (17 pts), loops 2 (4 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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":936}}}],"partialFingerprints":{"codehealthFindingId/v1":"a9d16d3094d95f935799ad7d675684095f38c5d04fdba145ec752188a9ce2b85"}},{"ruleId":"D2","level":"warning","message":{"text":"TextStyleIndex.replacedRuns (cognitive 22): TextStyleIndex.replacedRuns has cognitive complexity 22 (threshold 15). Drivers by points: if/else 7 (18 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":"loro-js/src/runtime/text-style-index.ts"},"region":{"startLine":183}}}],"partialFingerprints":{"codehealthFindingId/v1":"19cba271f00eb577e81cd5c3116b655ee39af78ee41490b28ca1d0fc47611c43"}},{"ruleId":"D2","level":"warning","message":{"text":"DeltaRope::eq (cognitive 21): DeltaRope::eq has cognitive complexity 21 (threshold 15). Drivers by points: if/else 6 (16 pts), boolean chains 2, match/switch 1 (2 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":"crates/delta/src/delta_rope.rs"},"region":{"startLine":346}}}],"partialFingerprints":{"codehealthFindingId/v1":"cc85587e89d0b6a81a3c0c32a98869709f203e0f2ec6b58d3703107d8b2b0696"}},{"ruleId":"D2","level":"warning","message":{"text":"IdToCursor::update_insert_batch (cognitive 21): IdToCursor::update_insert_batch has cognitive complexity 21 (threshold 15). Drivers by points: loops 5 (9 pts), if/else 4 (8 pts), match/switch 1 (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":"crates/loro-internal/src/container/richtext/tracker/id_to_cursor.rs"},"region":{"startLine":112}}}],"partialFingerprints":{"codehealthFindingId/v1":"402afcc7902c9bbb17e9fe6c54b77d8f222982132ef1e4fdebfaaf108e4badc7"}},{"ruleId":"D2","level":"warning","message":{"text":"SmallInsertSet::update (cognitive 21): SmallInsertSet::update has cognitive complexity 21 (threshold 15). Drivers by points: if/else 10 (20 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":"crates/loro-internal/src/container/richtext/tracker/id_to_cursor.rs"},"region":{"startLine":691}}}],"partialFingerprints":{"codehealthFindingId/v1":"1976a28156f55f473a4ad7b1dd8d3681e7bec003303feb520510ae62b6f55c9a"}},{"ruleId":"D2","level":"warning","message":{"text":"OpLog::try_apply_pending (cognitive 21): OpLog::try_apply_pending has cognitive complexity 21 (threshold 15). Drivers by points: loops 5 (10 pts), if/else 3 (7 pts), match/switch 1 (4 pts) (nesting depth added 12). To reduce it, break up the iteration: give each loop body a named function, and split a multi-phase loop into one function per phase so no single body carries the whole pipeline."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/oplog/pending_changes.rs"},"region":{"startLine":594}}}],"partialFingerprints":{"codehealthFindingId/v1":"7571b78e7096b00dbded44c5f2b07f05d18f984d795d4afd80457cb27263437e"}},{"ruleId":"D2","level":"warning","message":{"text":"UndoManager::perform (cognitive 21): UndoManager::perform has cognitive complexity 21 (threshold 15). Drivers by points: if/else 8 (15 pts), loops 1 (3 pts), match/switch 1 (2 pts), boolean chains 1 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/undo.rs"},"region":{"startLine":937}}}],"partialFingerprints":{"codehealthFindingId/v1":"3212a009ca7ea77857d2bbfb9fcbd89b370db132bb1be4121bab3cd41818c454"}},{"ruleId":"D2","level":"warning","message":{"text":"loro_internal::dag::mermaid::to_str (cognitive 21): loro_internal::dag::mermaid::to_str has cognitive complexity 21 (threshold 15). Drivers by points: loops 10 (18 pts), if/else 1 (3 pts) (nesting depth added 10). To reduce it, break up the iteration: give each loop body a named function, and split a multi-phase loop into one function per phase so no single body carries the whole pipeline."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/dag/mermaid.rs"},"region":{"startLine":21}}}],"partialFingerprints":{"codehealthFindingId/v1":"6f0b7d3eb34052b2db463820c2c2e3ee305f019fd5d3fb1abb1c8ba6095bd3cd"}},{"ruleId":"D2","level":"warning","message":{"text":"loro_internal::jsonpath::jsonpath_impl::eval_function (cognitive 21): loro_internal::jsonpath::jsonpath_impl::eval_function has cognitive complexity 21 (threshold 15). Drivers by points: if/else 8 (13 pts), match/switch 3 (8 pts) (nesting depth added 10). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/jsonpath/jsonpath_impl.rs"},"region":{"startLine":295}}}],"partialFingerprints":{"codehealthFindingId/v1":"ecea887f5e2e769a5c806bcac970f87280e3098b0eb4d24fac54e7dd17fd2de7"}},{"ruleId":"D2","level":"warning","message":{"text":"SequenceIndex.visibleIndexOfMetricUnit (cognitive 21): SequenceIndex.visibleIndexOfMetricUnit has cognitive complexity 21 (threshold 15). Drivers by points: if/else 6 (13 pts), loops 2 (4 pts), ternaries 1 (3 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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":839}}}],"partialFingerprints":{"codehealthFindingId/v1":"ad3efd8a960e2f687e213ad95b284f1fee8cb7cc57a28fedb06d7f7a61be42e0"}},{"ruleId":"D2","level":"warning","message":{"text":"SequenceIndex.visibleAtMetricOffset (cognitive 21): SequenceIndex.visibleAtMetricOffset has cognitive complexity 21 (threshold 15). Drivers by points: if/else 6 (13 pts), loops 2 (4 pts), ternaries 1 (3 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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":898}}}],"partialFingerprints":{"codehealthFindingId/v1":"7df619086758c0920ad93c05f3363cde103e23c47df96234a6ea7d711e0b2aa8"}},{"ruleId":"D2","level":"warning","message":{"text":"MovableListState.canTransition (cognitive 21): MovableListState.canTransition has cognitive complexity 21 (threshold 15). Drivers by points: if/else 5 (13 pts), loops 2 (4 pts), boolean chains 2, match/switch 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":"loro-js/src/runtime/movable-list.ts"},"region":{"startLine":670}}}],"partialFingerprints":{"codehealthFindingId/v1":"d12d58fb2e41ecc75cd82ccadbec1e8b2e4a30e6bbe887764ae8678ee8aef40b"}},{"ruleId":"D2","level":"warning","message":{"text":"MovableListState.hydrate (cognitive 21): MovableListState.hydrate has cognitive complexity 21 (threshold 15). Drivers by points: if/else 7 (11 pts), ternaries 2 (6 pts), loops 3 (4 pts) (nesting depth added 9). Of this number, 19 points are the body\u0027s own statements and 2 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":"loro-js/src/runtime/movable-list.ts"},"region":{"startLine":799}}}],"partialFingerprints":{"codehealthFindingId/v1":"69df729aa7fea201c199fb25744955ea1a43a5aec68c03447f5a3d36f2e6c85f"}},{"ruleId":"D2","level":"warning","message":{"text":"jsonpath.compileJsonPathEventMatcher (cognitive 21): jsonpath.compileJsonPathEventMatcher has cognitive complexity 21 (threshold 15). Drivers by points: if/else 4 (11 pts), ternaries 3 (6 pts), loops 2 (3 pts), boolean chains 1 (nesting depth added 11). None of this is in the body itself: all 21 points belong to 4 function items inside it that branch (positionsAfter, a function literal at line 69, a function literal at line 75, \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":"loro-js/src/runtime/jsonpath.ts"},"region":{"startLine":66}}}],"partialFingerprints":{"codehealthFindingId/v1":"5b5c4247a2d581bf7c2a38cda1efccde58ec7dc941fb5153312cc8e83f0f10a7"}},{"ruleId":"D2","level":"warning","message":{"text":"LoroDoc.#installTreeMoves (cognitive 21): LoroDoc.#installTreeMoves has cognitive complexity 21 (threshold 15). Drivers by points: if/else 6 (12 pts), ternaries 2 (4 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. This file is where this pass\u0027s cognitive complexity CONCENTRATES: loro-js/src/runtime/document.ts holds 56 of the 301 methods over the threshold \u2014 including the worst \u2014 and 1420 of the 5127 points over it (28%), 4.3\u00D7 the next-largest file (crates/loro-internal/src/loro.rs at 332). No single row can show this, because each is measured only against the threshold: reducing this one file moves this dimension further than any other file in the repository."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/document.ts"},"region":{"startLine":6400}}}],"partialFingerprints":{"codehealthFindingId/v1":"ee37fea66a83c8c197ef379caa2af1e14366e417ff50981099acdba85b53b064"}},{"ruleId":"D2","level":"warning","message":{"text":"document.collectJsonPeers (cognitive 21): document.collectJsonPeers has cognitive complexity 21 (threshold 15). Drivers by points: if/else 6 (10 pts), loops 3 (5 pts), boolean chains 3, ternaries 2 (3 pts) (nesting depth added 7). Of this number, 17 points are the body\u0027s own statements and 4 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. This file is where this pass\u0027s cognitive complexity CONCENTRATES: loro-js/src/runtime/document.ts holds 56 of the 301 methods over the threshold \u2014 including the worst \u2014 and 1420 of the 5127 points over it (28%), 4.3\u00D7 the next-largest file (crates/loro-internal/src/loro.rs at 332). No single row can show this, because each is measured only against the threshold: reducing this one file moves this dimension further than any other file in the repository."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/document.ts"},"region":{"startLine":9881}}}],"partialFingerprints":{"codehealthFindingId/v1":"dc28d2d9c4f3491ac81c4cd9de2027b8ddf20e320446d752e1584c994aa10d4c"}},{"ruleId":"D2","level":"warning","message":{"text":"document.validateListDelta (cognitive 21): document.validateListDelta has cognitive complexity 21 (threshold 15). Drivers by points: if/else 9 (16 pts), boolean chains 3, loops 1, ternaries 1 (nesting depth added 7). Of this number, 19 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. This file is where this pass\u0027s cognitive complexity CONCENTRATES: loro-js/src/runtime/document.ts holds 56 of the 301 methods over the threshold \u2014 including the worst \u2014 and 1420 of the 5127 points over it (28%), 4.3\u00D7 the next-largest file (crates/loro-internal/src/loro.rs at 332). No single row can show this, because each is measured only against the threshold: reducing this one file moves this dimension further than any other file in the repository."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/document.ts"},"region":{"startLine":11267}}}],"partialFingerprints":{"codehealthFindingId/v1":"de8f0bf3b3f013052d6e75dd2a337cbe7ae084933736577caa1d9ba64421245f"}},{"ruleId":"D2","level":"warning","message":{"text":"document.redactDeadStyleValues (cognitive 21): document.redactDeadStyleValues has cognitive complexity 21 (threshold 15). Drivers by points: if/else 8 (19 pts), boolean chains 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. This file is where this pass\u0027s cognitive complexity CONCENTRATES: loro-js/src/runtime/document.ts holds 56 of the 301 methods over the threshold \u2014 including the worst \u2014 and 1420 of the 5127 points over it (28%), 4.3\u00D7 the next-largest file (crates/loro-internal/src/loro.rs at 332). No single row can show this, because each is measured only against the threshold: reducing this one file moves this dimension further than any other file in the repository."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/document.ts"},"region":{"startLine":11546}}}],"partialFingerprints":{"codehealthFindingId/v1":"90b2913497f3ad2e1924ad3647b1a5020b0ab5a9580e67c53ed16a0ef9b0c12e"}},{"ruleId":"D2","level":"warning","message":{"text":"containers.fugueInsertion (cognitive 21): containers.fugueInsertion has cognitive complexity 21 (threshold 15). Drivers by points: ternaries 10 (15 pts), if/else 3 (4 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":"loro-js/src/runtime/containers.ts"},"region":{"startLine":3598}}}],"partialFingerprints":{"codehealthFindingId/v1":"80ba817a35659503724bb09bf42081d00e5c8e548ce0fbf40518c33002807ea4"}},{"ruleId":"D2","level":"warning","message":{"text":"Rope::delete_range (cognitive 20): Rope::delete_range has cognitive complexity 20 (threshold 15). Drivers by points: if/else 9 (16 pts), match/switch 3, 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":"crates/generic-btree/src/generic_impl/rope.rs"},"region":{"startLine":121}}}],"partialFingerprints":{"codehealthFindingId/v1":"139cc8c0dda9c3f7020f6effe34a0749b076fa00611323a38a5329d2fe65547e"}},{"ruleId":"D2","level":"warning","message":{"text":"NormalBlock::validate_decoded_data (cognitive 20): NormalBlock::validate_decoded_data has cognitive complexity 20 (threshold 15). Drivers by points: if/else 8 (17 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":"crates/kv-store/src/block.rs"},"region":{"startLine":166}}}],"partialFingerprints":{"codehealthFindingId/v1":"9ed06d8cd8f431e84e1c618865be361d615f7842709e5881baabe3a8665ef78f"}},{"ruleId":"D2","level":"warning","message":{"text":"IdToCursor::iter (cognitive 20): IdToCursor::iter has cognitive complexity 20 (threshold 15). Drivers by points: if/else 7 (15 pts), match/switch 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":"crates/loro-internal/src/container/richtext/tracker/id_to_cursor.rs"},"region":{"startLine":202}}}],"partialFingerprints":{"codehealthFindingId/v1":"6566b882ec2fe4c3858edda9481aeb9ecca694cca37c60f4f0407cbe13b09c07"}},{"ruleId":"D2","level":"warning","message":{"text":"RichtextDiffCalculator::apply_change (cognitive 20): RichtextDiffCalculator::apply_change has cognitive complexity 20 (threshold 15). Drivers by points: match/switch 4 (10 pts), if/else 3 (9 pts), boolean chains 1 (nesting depth added 12). To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/diff_calc.rs"},"region":{"startLine":1724}}}],"partialFingerprints":{"codehealthFindingId/v1":"a57595da9e3f979f98eeb462bb92b51d337477698bb2a1ece7ad57e42a89edef"}},{"ruleId":"D2","level":"warning","message":{"text":"ChangeStore::iter_blocks_inner (cognitive 20): ChangeStore::iter_blocks_inner has cognitive complexity 20 (threshold 15). Drivers by points: if/else 9 (15 pts), match/switch 1 (3 pts), boolean chains 1, 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":"crates/loro-internal/src/oplog/change_store.rs"},"region":{"startLine":1002}}}],"partialFingerprints":{"codehealthFindingId/v1":"990e27f77cdb3902a5b12afc8824315af1ab9b209dfeef39eef252981e1fac8a"}},{"ruleId":"D2","level":"warning","message":{"text":"OpLog::insert_new_change (cognitive 20): OpLog::insert_new_change has cognitive complexity 20 (threshold 15). Drivers by points: if/else 7 (16 pts), boolean chains 2, loops 1 (2 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":"crates/loro-internal/src/oplog.rs"},"region":{"startLine":323}}}],"partialFingerprints":{"codehealthFindingId/v1":"71da72aa78a273915babbfc6e448f9cf9c710d9e656ddf3dd651b9f0d989e9a5"}},{"ruleId":"D2","level":"warning","message":{"text":"TreeState::apply_diff (cognitive 20): TreeState::apply_diff has cognitive complexity 20 (threshold 15). Drivers by points: if/else 5 (15 pts), match/switch 1 (3 pts), loops 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":"crates/loro-internal/src/state/tree_state.rs"},"region":{"startLine":1345}}}],"partialFingerprints":{"codehealthFindingId/v1":"547dbfbb9f8031bb09577aef9dc54c33ddc41f585541a5e906799d12e71508af"}},{"ruleId":"D2","level":"warning","message":{"text":"loro_internal::fuzz::minify_error (cognitive 20): loro_internal::fuzz::minify_error has cognitive complexity 20 (threshold 15). Drivers by points: if/else 7 (14 pts), loops 3 (5 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":"crates/loro-internal/src/fuzz.rs"},"region":{"startLine":3}}}],"partialFingerprints":{"codehealthFindingId/v1":"e11d4de053100fa820ad6333fdbe3fbc1e4f7012ecf26874e43a20489b352a32"}},{"ruleId":"D2","level":"warning","message":{"text":"build.build (cognitive 20): build.build has cognitive complexity 20 (threshold 15). Drivers by points: if/else 8 (15 pts), error handling 1 (3 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":"crates/loro-wasm/scripts/build.ts"},"region":{"startLine":59}}}],"partialFingerprints":{"codehealthFindingId/v1":"aa9c1251585ad02fa1eeb90fa3989ecdca345cab0666c571332e932539c8e9c0"}},{"ruleId":"D2","level":"warning","message":{"text":"change-block-tables.encodeChangesHeader (cognitive 20): change-block-tables.encodeChangesHeader has cognitive complexity 20 (threshold 15). Drivers by points: if/else 5 (13 pts), loops 4 (5 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":"loro-js/src/codec/change-block-tables.ts"},"region":{"startLine":181}}}],"partialFingerprints":{"codehealthFindingId/v1":"6882e15d0be97e0f7e0239263e7319a24dfede54964cba3bed4c78496d8bc7d1"}},{"ruleId":"D2","level":"warning","message":{"text":"SequenceIndex.nextVisible (cognitive 20): SequenceIndex.nextVisible has cognitive complexity 20 (threshold 15). Drivers by points: if/else 7 (14 pts), loops 3 (5 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. This shape REPEATS in the file: one other method here (SequenceIndex.previousVisible) 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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":1530}}}],"partialFingerprints":{"codehealthFindingId/v1":"2a74d4b7e94df01960a94923cfbb92cdefee544b5dfbb7da452258cff1586fc8"}},{"ruleId":"D2","level":"warning","message":{"text":"SequenceIndex.previousVisible (cognitive 20): SequenceIndex.previousVisible has cognitive complexity 20 (threshold 15). Drivers by points: if/else 7 (14 pts), loops 3 (5 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. This shape REPEATS in the file: one other method here (SequenceIndex.nextVisible) 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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":1557}}}],"partialFingerprints":{"codehealthFindingId/v1":"be42f30ae0a651d4b8b90676d948ac29a068bd7d0959f5504eefd541c5558694"}},{"ruleId":"D2","level":"warning","message":{"text":"jsonpath.readFilterPath (cognitive 20): jsonpath.readFilterPath has cognitive complexity 20 (threshold 15). Drivers by points: if/else 8 (15 pts), boolean chains 4, 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":"loro-js/src/runtime/jsonpath.ts"},"region":{"startLine":683}}}],"partialFingerprints":{"codehealthFindingId/v1":"d9cdba7bba3e92352a30cac3efb690a39a6c99451a704ac0c5e7348ca81435aa"}},{"ruleId":"D2","level":"warning","message":{"text":"LoroDoc.toJsonWithReplacer (cognitive 20): LoroDoc.toJsonWithReplacer has cognitive complexity 20 (threshold 15). Drivers by points: if/else 8 (11 pts), ternaries 3 (6 pts), boolean chains 3 (nesting depth added 6). None of this is in the body itself: all 20 points belong to 4 function items inside it that branch (visit, run, a function literal at line 1216, \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. This file is where this pass\u0027s cognitive complexity CONCENTRATES: loro-js/src/runtime/document.ts holds 56 of the 301 methods over the threshold \u2014 including the worst \u2014 and 1420 of the 5127 points over it (28%), 4.3\u00D7 the next-largest file (crates/loro-internal/src/loro.rs at 332). No single row can show this, because each is measured only against the threshold: reducing this one file moves this dimension further than any other file in the repository."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/document.ts"},"region":{"startLine":1207}}}],"partialFingerprints":{"codehealthFindingId/v1":"6a901b964828dbbd14c03683c9ca10db5141f73e1b856a3e7dd464918bc3e0be"}},{"ruleId":"D2","level":"warning","message":{"text":"LoroText.applyDelta (cognitive 20): LoroText.applyDelta has cognitive complexity 20 (threshold 15). Drivers by points: if/else 7 (16 pts), loops 3 (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":"loro-js/src/runtime/containers.ts"},"region":{"startLine":1652}}}],"partialFingerprints":{"codehealthFindingId/v1":"78c54146906586fe9048650c8a767f6fbdafb0a71f5d3edada2a1388d6025e5b"}},{"ruleId":"D2","level":"warning","message":{"text":"loro_fractional_index::new_between (cognitive 19): loro_fractional_index::new_between has cognitive complexity 19 (threshold 15). Drivers by points: if/else 9 (17 pts), loops 1, match/switch 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/fractional_index/src/lib.rs"},"region":{"startLine":80}}}],"partialFingerprints":{"codehealthFindingId/v1":"207482c62287fdab205a033cc6851a92e3d0a7a089ddeb0dd3985901ecc97c13"}},{"ruleId":"D2","level":"warning","message":{"text":"BTree::check (cognitive 19): BTree::check has cognitive complexity 19 (threshold 15). Drivers by points: if/else 5 (11 pts), loops 4 (6 pts), match/switch 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":"crates/generic-btree/src/lib.rs"},"region":{"startLine":2778}}}],"partialFingerprints":{"codehealthFindingId/v1":"25917742796a08c10ed2cfee7f2d55b82ee27cf885bc76c764a2425292954466"}},{"ruleId":"D2","level":"warning","message":{"text":"LoroValue::from (cognitive 19): LoroValue::from has cognitive complexity 19 (threshold 15). Drivers by points: if/else 10 (11 pts), loops 3 (6 pts), boolean chains 2 (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":"crates/loro-common/src/value.rs"},"region":{"startLine":792}}}],"partialFingerprints":{"codehealthFindingId/v1":"d8201890e8787f2ac33d8633375fd40541c3c324a241023d4d207d7219fc2574"}},{"ruleId":"D2","level":"warning","message":{"text":"MovableListDiffCalculator::apply_change (cognitive 19): MovableListDiffCalculator::apply_change has cognitive complexity 19 (threshold 15). Drivers by points: if/else 6 (10 pts), match/switch 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":"crates/loro-internal/src/diff_calc.rs"},"region":{"startLine":2100}}}],"partialFingerprints":{"codehealthFindingId/v1":"0eceae86ff9ab68c1be4607626378ca127e4efc0c4196da18f5c161c676be26f"}},{"ruleId":"D2","level":"warning","message":{"text":"ListHandler::apply_delta (cognitive 19): ListHandler::apply_delta has cognitive complexity 19 (threshold 15). Drivers by points: match/switch 3 (9 pts), loops 2 (6 pts), if/else 1 (4 pts) (nesting depth added 13). To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/handler.rs"},"region":{"startLine":3623}}}],"partialFingerprints":{"codehealthFindingId/v1":"565d3db70eed91217975a39fbc76f9def94d42b9f102f06dd14296b030bbb492"}},{"ruleId":"D2","level":"warning","message":{"text":"LoroDoc::update_oplog_and_apply_delta_to_state_if_needed (cognitive 19): LoroDoc::update_oplog_and_apply_delta_to_state_if_needed has cognitive complexity 19 (threshold 15). Drivers by points: if/else 7 (12 pts), match/switch 3 (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":"crates/loro-internal/src/loro.rs"},"region":{"startLine":888}}}],"partialFingerprints":{"codehealthFindingId/v1":"be70772c27ddaf66054b97b264f4444038baa42480654cfc6185dab5cf51c33a"}},{"ruleId":"D2","level":"warning","message":{"text":"InnerContent::visit_created_children (cognitive 19): InnerContent::visit_created_children has cognitive complexity 19 (threshold 15). Drivers by points: if/else 4 (11 pts), match/switch 3 (5 pts), loops 1 (3 pts) (nesting depth added 11). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/op/content.rs"},"region":{"startLine":28}}}],"partialFingerprints":{"codehealthFindingId/v1":"2123a4869c98b82a825f69b03e55e2fc38bf39c28cfe79ddc1ef0a84241e7244"}},{"ruleId":"D2","level":"warning","message":{"text":"DocState::read_container_tree (cognitive 19): DocState::read_container_tree has cognitive complexity 19 (threshold 15). Drivers by points: if/else 7 (13 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":"crates/loro-internal/src/state/container_tree.rs"},"region":{"startLine":29}}}],"partialFingerprints":{"codehealthFindingId/v1":"14a22cfc9529c70189e0d357e48cc3d992c9658d141b4c2c425f8b90a0e29eb0"}},{"ruleId":"D2","level":"warning","message":{"text":"loro_internal::loro::find_last_delete_op (cognitive 19): loro_internal::loro::find_last_delete_op has cognitive complexity 19 (threshold 15). Drivers by points: if/else 4 (15 pts), loops 2 (3 pts), match/switch 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":"crates/loro-internal/src/loro.rs"},"region":{"startLine":4415}}}],"partialFingerprints":{"codehealthFindingId/v1":"bb649e8859b0317657768f2d2e057127ba0ee02753c5a0b7a7059ea4a34d4d20"}},{"ruleId":"D2","level":"warning","message":{"text":"sstable.encodeBlocks (cognitive 19): sstable.encodeBlocks has cognitive complexity 19 (threshold 15). Drivers by points: if/else 4 (11 pts), loops 3 (5 pts), boolean chains 3 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/codec/sstable.ts"},"region":{"startLine":308}}}],"partialFingerprints":{"codehealthFindingId/v1":"9843380c8bdf15dcd80bd3c3a00eb5c3b4e3e35fd135ba39de183533f2c5810c"}},{"ruleId":"D2","level":"warning","message":{"text":"SequenceIndex.#appendToPreviousNodeWithLineBreaks (cognitive 19): SequenceIndex.#appendToPreviousNodeWithLineBreaks has cognitive complexity 19 (threshold 15). Drivers by points: if/else 9 (13 pts), ternaries 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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":2143}}}],"partialFingerprints":{"codehealthFindingId/v1":"ccc7c513339866a4127e4168b52415f9260b02ac0cd0f20d264a3b58ad80426d"}},{"ruleId":"D2","level":"warning","message":{"text":"sequence-index.findNextIncludedPhysical (cognitive 19): sequence-index.findNextIncludedPhysical has cognitive complexity 19 (threshold 15). Drivers by points: if/else 8 (14 pts), loops 1 (3 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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":2476}}}],"partialFingerprints":{"codehealthFindingId/v1":"ca3b2c82123b8c0f4efac846f8432b1a01567c134a179f28d12d8e94160df19e"}},{"ruleId":"D2","level":"warning","message":{"text":"FilterParser.#parsePrimary (cognitive 19): FilterParser.#parsePrimary has cognitive complexity 19 (threshold 15). Drivers by points: if/else 7 (9 pts), loops 2 (6 pts), ternaries 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":"loro-js/src/runtime/jsonpath.ts"},"region":{"startLine":552}}}],"partialFingerprints":{"codehealthFindingId/v1":"4ad3349f555098d3852e920ca1a79e4f1f2d58b147b7256f37bda63c715cd7cd"}},{"ruleId":"D2","level":"warning","message":{"text":"LoroDoc.#commit (cognitive 19): LoroDoc.#commit has cognitive complexity 19 (threshold 15). Drivers by points: if/else 10 (12 pts), loops 3 (5 pts), boolean chains 1, error handling 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. This file is where this pass\u0027s cognitive complexity CONCENTRATES: loro-js/src/runtime/document.ts holds 56 of the 301 methods over the threshold \u2014 including the worst \u2014 and 1420 of the 5127 points over it (28%), 4.3\u00D7 the next-largest file (crates/loro-internal/src/loro.rs at 332). No single row can show this, because each is measured only against the threshold: reducing this one file moves this dimension further than any other file in the repository."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/document.ts"},"region":{"startLine":506}}}],"partialFingerprints":{"codehealthFindingId/v1":"b1ebfdfb291a9defbd3534d7e723718076e458487c4fae23589f2702d113c6f1"}},{"ruleId":"D2","level":"warning","message":{"text":"LoroDoc.getCursorPos (cognitive 19): LoroDoc.getCursorPos has cognitive complexity 19 (threshold 15). Drivers by points: if/else 11 (13 pts), boolean chains 3, ternaries 2 (3 pts) (nesting depth added 3). Of this number, 18 points are the body\u0027s own statements and 1 belongs to one function item inside it that branches. 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 file is where this pass\u0027s cognitive complexity CONCENTRATES: loro-js/src/runtime/document.ts holds 56 of the 301 methods over the threshold \u2014 including the worst \u2014 and 1420 of the 5127 points over it (28%), 4.3\u00D7 the next-largest file (crates/loro-internal/src/loro.rs at 332). No single row can show this, because each is measured only against the threshold: reducing this one file moves this dimension further than any other file in the repository."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/document.ts"},"region":{"startLine":3371}}}],"partialFingerprints":{"codehealthFindingId/v1":"95734d076300cedc911174d9ebc1530316ba2f8eb95110d01eac301add500f69"}},{"ruleId":"D2","level":"warning","message":{"text":"LoroDoc.#applyChange (cognitive 19): LoroDoc.#applyChange has cognitive complexity 19 (threshold 15). Drivers by points: if/else 3 (8 pts), ternaries 2 (6 pts), boolean chains 4, 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. This file is where this pass\u0027s cognitive complexity CONCENTRATES: loro-js/src/runtime/document.ts holds 56 of the 301 methods over the threshold \u2014 including the worst \u2014 and 1420 of the 5127 points over it (28%), 4.3\u00D7 the next-largest file (crates/loro-internal/src/loro.rs at 332). No single row can show this, because each is measured only against the threshold: reducing this one file moves this dimension further than any other file in the repository."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/document.ts"},"region":{"startLine":5672}}}],"partialFingerprints":{"codehealthFindingId/v1":"3201776b99510a236dd146c1c7ca736bce2d7803557217926b0f8bfd23c3f2ef"}},{"ruleId":"D2","level":"warning","message":{"text":"Iter::next_with (cognitive 18): Iter::next_with has cognitive complexity 18 (threshold 15). Drivers by points: if/else 7 (14 pts), match/switch 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":"crates/delta/src/iter.rs"},"region":{"startLine":62}}}],"partialFingerprints":{"codehealthFindingId/v1":"e4feafefd96deb7250689d032ec33fdf5b5519d749423aa270d4e20ee6f227af"}},{"ruleId":"D2","level":"warning","message":{"text":"TreeDiffCalculator::checkout_diff (cognitive 18): TreeDiffCalculator::checkout_diff has cognitive complexity 18 (threshold 15). Drivers by points: if/else 8 (16 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":"crates/loro-internal/src/diff_calc/tree.rs"},"region":{"startLine":205}}}],"partialFingerprints":{"codehealthFindingId/v1":"cc3ba37942309fe944fe13b048e29874eb9eedfb2e0ec054b6243047384b9bef"}},{"ruleId":"D2","level":"warning","message":{"text":"TextDelta::from_text_diff (cognitive 18): TextDelta::from_text_diff has cognitive complexity 18 (threshold 15). Drivers by points: if/else 6 (15 pts), match/switch 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":"crates/loro-internal/src/handler.rs"},"region":{"startLine":574}}}],"partialFingerprints":{"codehealthFindingId/v1":"683cb1a8ff1ccd7bb16cfcfe4f084324ccc5adfc987b2e4b8b681b07466ad832"}},{"ruleId":"D2","level":"warning","message":{"text":"LoroDoc::travel_change_ancestors (cognitive 18): LoroDoc::travel_change_ancestors has cognitive complexity 18 (threshold 15). Drivers by points: if/else 5 (12 pts), loops 4 (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":"crates/loro-internal/src/loro.rs"},"region":{"startLine":4250}}}],"partialFingerprints":{"codehealthFindingId/v1":"e3bb4f7d1c46a4083925f48fcd03f62cffc37d5276e95bd648d983b980509a7b"}},{"ruleId":"D2","level":"warning","message":{"text":"ChangeStore::insert_change_inner (cognitive 18): ChangeStore::insert_change_inner has cognitive complexity 18 (threshold 15). Drivers by points: if/else 7 (14 pts), match/switch 1 (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":"crates/loro-internal/src/oplog/change_store.rs"},"region":{"startLine":1475}}}],"partialFingerprints":{"codehealthFindingId/v1":"592c36416208c33ee8a3e6c687ace0ad60aff1921cf65c2f786dd360a81a855b"}},{"ruleId":"D2","level":"warning","message":{"text":"ChangeStore::load_blocks_in_range (cognitive 18): ChangeStore::load_blocks_in_range has cognitive complexity 18 (threshold 15). Drivers by points: if/else 7 (14 pts), match/switch 2 (3 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":"crates/loro-internal/src/oplog/change_store.rs"},"region":{"startLine":2009}}}],"partialFingerprints":{"codehealthFindingId/v1":"2bedf548f6cd4dfe51d427908d1afb1f80d1dbc5877cf7f862381019fd6518ea"}},{"ruleId":"D2","level":"warning","message":{"text":"MovableListState::decode_snapshot_fast (cognitive 18): MovableListState::decode_snapshot_fast has cognitive complexity 18 (threshold 15). Drivers by points: if/else 10 (15 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":"crates/loro-internal/src/state/movable_list_state.rs"},"region":{"startLine":1626}}}],"partialFingerprints":{"codehealthFindingId/v1":"97c39ebda836f463ede13ce72e19577eafab7dd052e5c2a012606518b0eebcb6"}},{"ruleId":"D2","level":"warning","message":{"text":"RichtextState::get_text_index_of_id (cognitive 18): RichtextState::get_text_index_of_id has cognitive complexity 18 (threshold 15). Drivers by points: if/else 5 (11 pts), match/switch 3 (6 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":"crates/loro-internal/src/state/richtext_state.rs"},"region":{"startLine":227}}}],"partialFingerprints":{"codehealthFindingId/v1":"d0f965d0cc35923089e6571697158bfc25fd89e222c711ff401b66aa7301b660"}},{"ruleId":"D2","level":"warning","message":{"text":"RichtextStateLoader::try_apply_append_delta (cognitive 18): RichtextStateLoader::try_apply_append_delta has cognitive complexity 18 (threshold 15). Drivers by points: if/else 7 (13 pts), loops 2, match/switch 1 (2 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":"crates/loro-internal/src/state/richtext_state.rs"},"region":{"startLine":1209}}}],"partialFingerprints":{"codehealthFindingId/v1":"c891864adab61d38db5848c1331b7b0b9fdf46a9e33228ca36b67f3e2724ca48"}},{"ruleId":"D2","level":"warning","message":{"text":"VersionVector::partial_cmp (cognitive 18): VersionVector::partial_cmp has cognitive complexity 18 (threshold 15). Drivers by points: if/else 10 (16 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. This shape REPEATS in the file: one other method here (ImVersionVector::partial_cmp) 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":"crates/loro-internal/src/version.rs"},"region":{"startLine":406}}}],"partialFingerprints":{"codehealthFindingId/v1":"45cb83701e050bd5214e3432174853f26d28329415ddaa8ccb66e76e164628f0"}},{"ruleId":"D2","level":"warning","message":{"text":"ImVersionVector::partial_cmp (cognitive 18): ImVersionVector::partial_cmp has cognitive complexity 18 (threshold 15). Drivers by points: if/else 10 (16 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. This shape REPEATS in the file: one other method here (VersionVector::partial_cmp) 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":"crates/loro-internal/src/version.rs"},"region":{"startLine":450}}}],"partialFingerprints":{"codehealthFindingId/v1":"7a3d7f5765c732cdca553c5875303fd5ccff40923475d131e73616d93bd45efe"}},{"ruleId":"D2","level":"warning","message":{"text":"loro_internal::dag::_find_meet_and_mode::all_tips_covered_by_ancestors (cognitive 18): loro_internal::dag::_find_meet_and_mode::all_tips_covered_by_ancestors has cognitive complexity 18 (threshold 15). Drivers by points: if/else 8 (12 pts), loops 4 (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. This shape REPEATS in the file: 2 other methods here (loro_internal::dag::_find_meet_and_mode, loro_internal::dag::_find_meet_and_mode::new_region_after_all_left_heads) 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":"crates/loro-internal/src/dag.rs"},"region":{"startLine":861}}}],"partialFingerprints":{"codehealthFindingId/v1":"3194e834431b0566173d4455ac86317e51fe8daa27b30a7556fb15312fa12586"}},{"ruleId":"D2","level":"warning","message":{"text":"loro_internal::encoding::shallow_snapshot::rich_op_content_bytes (cognitive 18): loro_internal::encoding::shallow_snapshot::rich_op_content_bytes has cognitive complexity 18 (threshold 15). Drivers by points: match/switch 5 (8 pts), if/else 3 (7 pts), loops 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":"crates/loro-internal/src/encoding/shallow_snapshot.rs"},"region":{"startLine":120}}}],"partialFingerprints":{"codehealthFindingId/v1":"d8d63742e84b79db86eaf8ab1943cef2b221a3fa26a160f4257de274feb0f234"}},{"ruleId":"D2","level":"warning","message":{"text":"SequenceEventDiff.#textDelta (cognitive 18): SequenceEventDiff.#textDelta has cognitive complexity 18 (threshold 15). Drivers by points: if/else 7 (12 pts), ternaries 2 (3 pts), loops 2, boolean chains 1 (nesting depth added 6). Of this number, 12 points are the body\u0027s own statements and 6 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":"loro-js/src/runtime/event-diff.ts"},"region":{"startLine":105}}}],"partialFingerprints":{"codehealthFindingId/v1":"d0852c610c836458b6a0b269acea7eb146437d09362fda145b37f6ffa575d033"}},{"ruleId":"D2","level":"warning","message":{"text":"SequenceIndex.#appendToPreviousNode (cognitive 18): SequenceIndex.#appendToPreviousNode has cognitive complexity 18 (threshold 15). Drivers by points: if/else 9 (13 pts), ternaries 2 (3 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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":2079}}}],"partialFingerprints":{"codehealthFindingId/v1":"bdc880d4079ae5da76a959c527efbdf7a7236b26c0920dbe228d0451a5095633"}},{"ruleId":"D2","level":"warning","message":{"text":"movable-list.runtimeValuesEqual (cognitive 18): movable-list.runtimeValuesEqual has cognitive complexity 18 (threshold 15). Drivers by points: boolean chains 9, if/else 7 (9 pts) (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":"loro-js/src/runtime/movable-list.ts"},"region":{"startLine":146}}}],"partialFingerprints":{"codehealthFindingId/v1":"3f4c5aad50d1b7c6cc9faf313e4137a9e18e67508b8059fdcbff2f803dfeb46d"}},{"ruleId":"D2","level":"warning","message":{"text":"jsonpath.parseBracketSelector (cognitive 18): jsonpath.parseBracketSelector has cognitive complexity 18 (threshold 15). Drivers by points: if/else 10 (14 pts), boolean chains 2, ternaries 1 (2 pts) (nesting depth added 5). 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":"loro-js/src/runtime/jsonpath.ts"},"region":{"startLine":210}}}],"partialFingerprints":{"codehealthFindingId/v1":"d2df40c321948aee544505d613e7ae9864d6c9fb8e63efbff8f3c32ef73da827"}},{"ruleId":"D2","level":"warning","message":{"text":"document.eventValuesEqual (cognitive 18): document.eventValuesEqual has cognitive complexity 18 (threshold 15). Drivers by points: boolean chains 11, if/else 7. 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. This file is where this pass\u0027s cognitive complexity CONCENTRATES: loro-js/src/runtime/document.ts holds 56 of the 301 methods over the threshold \u2014 including the worst \u2014 and 1420 of the 5127 points over it (28%), 4.3\u00D7 the next-largest file (crates/loro-internal/src/loro.rs at 332). No single row can show this, because each is measured only against the threshold: reducing this one file moves this dimension further than any other file in the repository."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/document.ts"},"region":{"startLine":10924}}}],"partialFingerprints":{"codehealthFindingId/v1":"398198ff0627b65c614874657facb5ced3ba506b42ab102e1f3f50862d55ea7f"}},{"ruleId":"D2","level":"warning","message":{"text":"TextStyleIndex.everyWinner (cognitive 18): TextStyleIndex.everyWinner has cognitive complexity 18 (threshold 15). Drivers by points: if/else 5 (13 pts), loops 2 (3 pts), boolean chains 2 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/text-style-index.ts"},"region":{"startLine":111}}}],"partialFingerprints":{"codehealthFindingId/v1":"1ea7c0f9e45db68c373cf8036a917194d49a3bd985eb9b8e6f77325b1decc64e"}},{"ruleId":"D2","level":"warning","message":{"text":"index.newBetweenBytes (cognitive 18): index.newBetweenBytes 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":"packages/fractional-index/src/index.ts"},"region":{"startLine":482}}}],"partialFingerprints":{"codehealthFindingId/v1":"d3e5802370f840b0f9265c6f16d71673e5248c38f24a3313d8d8e2d7248fff26"}},{"ruleId":"D2","level":"warning","message":{"text":"BTree::insert_many_by_cursor (cognitive 17): BTree::insert_many_by_cursor has cognitive complexity 17 (threshold 15). Drivers by points: if/else 9 (11 pts), loops 3 (4 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":"crates/generic-btree/src/lib.rs"},"region":{"startLine":681}}}],"partialFingerprints":{"codehealthFindingId/v1":"3b45b75e4da409b6591ac13da38e68c52732e3ba7696b2c4f684ca27e51e4d9e"}},{"ruleId":"D2","level":"warning","message":{"text":"LoroValue::apply (cognitive 17): LoroValue::apply has cognitive complexity 17 (threshold 15). Drivers by points: match/switch 4 (8 pts), if/else 3 (7 pts), loops 2 (nesting depth added 8). To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/value.rs"},"region":{"startLine":444}}}],"partialFingerprints":{"codehealthFindingId/v1":"b4604a1e4581fb14627dc4c3128471415958a12de305c760e4fe8483355e33eb"}},{"ruleId":"D2","level":"warning","message":{"text":"Change::slice (cognitive 17): Change::slice has cognitive complexity 17 (threshold 15). Drivers by points: if/else 7 (12 pts), match/switch 1 (3 pts), loops 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":"crates/loro-internal/src/change.rs"},"region":{"startLine":203}}}],"partialFingerprints":{"codehealthFindingId/v1":"55d0fb9566423d70fa22ef47c0601ea700bb910e8b42a354dbabb97675351ade"}},{"ruleId":"D2","level":"warning","message":{"text":"RichtextState::try_get_cache_or_clean (cognitive 17): RichtextState::try_get_cache_or_clean has cognitive complexity 17 (threshold 15). Drivers by points: if/else 7 (14 pts), match/switch 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":"crates/loro-internal/src/container/richtext/richtext_state.rs"},"region":{"startLine":125}}}],"partialFingerprints":{"codehealthFindingId/v1":"0377a5ad12ed974a90502fc856f0ec1726a3060df708771b0b8188807e9086b5"}},{"ruleId":"D2","level":"warning","message":{"text":"Tracker::forward (cognitive 17): Tracker::forward has cognitive complexity 17 (threshold 15). Drivers by points: match/switch 3 (10 pts), loops 3 (7 pts) (nesting depth added 11). To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/container/richtext/tracker.rs"},"region":{"startLine":507}}}],"partialFingerprints":{"codehealthFindingId/v1":"f36001acc560027d69e941d28333478e8aa7b74da92f71ded5366c01ddc1ac02"}},{"ruleId":"D2","level":"warning","message":{"text":"ImportedValues::eq (cognitive 17): ImportedValues::eq has cognitive complexity 17 (threshold 15). Drivers by points: match/switch 3 (8 pts), boolean chains 5, if/else 2 (3 pts), loops 1 (nesting depth added 6). To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/oplog/known_history.rs"},"region":{"startLine":43}}}],"partialFingerprints":{"codehealthFindingId/v1":"b835bead04dfc43730939282def972ae00efc8397fed216207e0ddd32acb7af0"}},{"ruleId":"D2","level":"warning","message":{"text":"DocState::set_container_parent_by_raw_op (cognitive 17): DocState::set_container_parent_by_raw_op has cognitive complexity 17 (threshold 15). Drivers by points: if/else 4 (10 pts), match/switch 2 (4 pts), loops 1 (3 pts) (nesting depth added 10). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/parent.rs"},"region":{"startLine":62}}}],"partialFingerprints":{"codehealthFindingId/v1":"0bd28366a61a99b38f0e4b7e97b60650585b95c6a0eaea6c7dfd7816a178d373"}},{"ruleId":"D2","level":"warning","message":{"text":"DocState::get_reachable (cognitive 17): DocState::get_reachable has cognitive complexity 17 (threshold 15). Drivers by points: if/else 7 (13 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":"crates/loro-internal/src/state.rs"},"region":{"startLine":2233}}}],"partialFingerprints":{"codehealthFindingId/v1":"37b2d6e34bfc9b4383f0bca49819ae076be5bead0b1e93d449af9f9ac085ebc1"}},{"ruleId":"D2","level":"warning","message":{"text":"loro_internal::encoding::json_schema::export_json_in_id_span (cognitive 17): loro_internal::encoding::json_schema::export_json_in_id_span has cognitive complexity 17 (threshold 15). Drivers by points: if/else 9 (15 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":"crates/loro-internal/src/encoding/json_schema.rs"},"region":{"startLine":78}}}],"partialFingerprints":{"codehealthFindingId/v1":"86f0f10fc35f21d4a2c706e23f95735164276a02fdc5b04cc63b2ad14841b4fe"}},{"ruleId":"D2","level":"warning","message":{"text":"loro_internal::jsonpath::jsonpath_impl::evaluate_segment (cognitive 17): loro_internal::jsonpath::jsonpath_impl::evaluate_segment has cognitive complexity 17 (threshold 15). Drivers by points: if/else 5 (8 pts), loops 2 (6 pts), boolean chains 2, match/switch 1 (nesting depth added 7). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/jsonpath/jsonpath_impl.rs"},"region":{"startLine":81}}}],"partialFingerprints":{"codehealthFindingId/v1":"d7eb6d20c538b6e375a831380ce65edefe8952accad62ccb25c4b00933770266"}},{"ruleId":"D2","level":"warning","message":{"text":"loro_internal::oplog::change_store::block_encode::encode_block (cognitive 17): loro_internal::oplog::change_store::block_encode::encode_block has cognitive complexity 17 (threshold 15). Drivers by points: loops 5 (7 pts), if/else 4 (6 pts), match/switch 1 (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":"crates/loro-internal/src/oplog/change_store/block_encode.rs"},"region":{"startLine":137}}}],"partialFingerprints":{"codehealthFindingId/v1":"dd368cda4f30978bd44a54d4003db12caf762241253eab4fa33e13a2639a79ef"}},{"ruleId":"D2","level":"warning","message":{"text":"loro_internal::oplog::change_store::block_meta_encode::decode_delta_of_delta (cognitive 17): loro_internal::oplog::change_store::block_meta_encode::decode_delta_of_delta has cognitive complexity 17 (threshold 15). Drivers by points: if/else 11 (14 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, 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":"crates/loro-internal/src/oplog/change_store/block_meta_encode.rs"},"region":{"startLine":264}}}],"partialFingerprints":{"codehealthFindingId/v1":"1b97b0500624d40d112acbd646f4edcce9c204ff4b2ebf1bab201e3322dd2be6"}},{"ruleId":"D2","level":"warning","message":{"text":"measure-snapshot-round-memory.runCoordinator (cognitive 17): measure-snapshot-round-memory.runCoordinator has cognitive complexity 17 (threshold 15). Drivers by points: if/else 8 (10 pts), boolean chains 3, error handling 1 (2 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":"crates/loro-wasm/scripts/measure-snapshot-round-memory.cjs"},"region":{"startLine":313}}}],"partialFingerprints":{"codehealthFindingId/v1":"a528c07ba9b5fa4adbbd12eda098d9abac3a52aed1a54f62d28f5d772deaf8d5"}},{"ruleId":"D2","level":"warning","message":{"text":"sequence-index.markIdRunsDeleted (cognitive 17): sequence-index.markIdRunsDeleted has cognitive complexity 17 (threshold 15). Drivers by points: if/else 9 (14 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. This shape REPEATS in the file: one other method here (sequence-index.markIdRunsVisible) 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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":3658}}}],"partialFingerprints":{"codehealthFindingId/v1":"0193a3c6b2254c0a58a897a8be981c1e920fd4a6c954ebb3d23326f4616223d9"}},{"ruleId":"D2","level":"warning","message":{"text":"sequence-index.markIdRunsVisible (cognitive 17): sequence-index.markIdRunsVisible has cognitive complexity 17 (threshold 15). Drivers by points: if/else 9 (14 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. This shape REPEATS in the file: one other method here (sequence-index.markIdRunsDeleted) 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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":3714}}}],"partialFingerprints":{"codehealthFindingId/v1":"d2261e62f44fccc9622e3d41e637e149e9faf436996431338c6453ff726dcd99"}},{"ruleId":"D2","level":"warning","message":{"text":"jsonpath.readBracket (cognitive 17): jsonpath.readBracket has cognitive complexity 17 (threshold 15). Drivers by points: if/else 8 (15 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":"loro-js/src/runtime/jsonpath.ts"},"region":{"startLine":180}}}],"partialFingerprints":{"codehealthFindingId/v1":"ed0ea027d610cd7af595ed4fd24d2426e5418e27d22dda34db10b3939db0f989"}},{"ruleId":"D2","level":"warning","message":{"text":"jsonpath.sliceIndexedValues (cognitive 17): jsonpath.sliceIndexedValues has cognitive complexity 17 (threshold 15). Drivers by points: ternaries 7 (9 pts), if/else 4, loops 2 (4 pts) (nesting depth added 4). Of this number, 14 points are the body\u0027s own statements and 3 belong to one function item inside it that branches. 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":"loro-js/src/runtime/jsonpath.ts"},"region":{"startLine":459}}}],"partialFingerprints":{"codehealthFindingId/v1":"e299a71383877c3fa1cbceaead83e7237214d622421537e8f85e6ea8c16d3afa"}},{"ruleId":"D2","level":"warning","message":{"text":"jsonpath.splitTopLevel (cognitive 17): jsonpath.splitTopLevel has cognitive complexity 17 (threshold 15). Drivers by points: if/else 10 (14 pts), boolean chains 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":"loro-js/src/runtime/jsonpath.ts"},"region":{"startLine":863}}}],"partialFingerprints":{"codehealthFindingId/v1":"1d6026ccdf1c2f9643ac4af68ac981943bfe6388c0b7cb5e480b747148fd842c"}},{"ruleId":"D2","level":"warning","message":{"text":"LoroDoc.#atomically (cognitive 17): LoroDoc.#atomically has cognitive complexity 17 (threshold 15). Drivers by points: if/else 4 (6 pts), ternaries 4 (6 pts), loops 1 (3 pts), boolean chains 1, 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. This file is where this pass\u0027s cognitive complexity CONCENTRATES: loro-js/src/runtime/document.ts holds 56 of the 301 methods over the threshold \u2014 including the worst \u2014 and 1420 of the 5127 points over it (28%), 4.3\u00D7 the next-largest file (crates/loro-internal/src/loro.rs at 332). No single row can show this, because each is measured only against the threshold: reducing this one file moves this dimension further than any other file in the repository."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/document.ts"},"region":{"startLine":5365}}}],"partialFingerprints":{"codehealthFindingId/v1":"8dfb7dee1cd15d749ed2094151c78ddc2f24aa3f57dbe2cf52ee7b68c2714177"}},{"ruleId":"D2","level":"warning","message":{"text":"LoroDoc.#indexHistoryOperations (cognitive 17): LoroDoc.#indexHistoryOperations has cognitive complexity 17 (threshold 15). Drivers by points: if/else 6 (13 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. This file is where this pass\u0027s cognitive complexity CONCENTRATES: loro-js/src/runtime/document.ts holds 56 of the 301 methods over the threshold \u2014 including the worst \u2014 and 1420 of the 5127 points over it (28%), 4.3\u00D7 the next-largest file (crates/loro-internal/src/loro.rs at 332). No single row can show this, because each is measured only against the threshold: reducing this one file moves this dimension further than any other file in the repository."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/document.ts"},"region":{"startLine":7059}}}],"partialFingerprints":{"codehealthFindingId/v1":"f58cb867637a216b28acdabe80948eb15ce139d53bcbd16c7e97c12989f35888"}},{"ruleId":"D2","level":"warning","message":{"text":"fractional-index.newBetween (cognitive 17): fractional-index.newBetween has cognitive complexity 17 (threshold 15). Drivers by points: if/else 7 (11 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":"loro-js/src/runtime/fractional-index.ts"},"region":{"startLine":88}}}],"partialFingerprints":{"codehealthFindingId/v1":"9072830a77303025bf15a5325d7b6e99b89b472617842241b937936525521672"}},{"ruleId":"D2","level":"warning","message":{"text":"containers.recordFugueOriginEntry (cognitive 17): containers.recordFugueOriginEntry has cognitive complexity 17 (threshold 15). Drivers by points: if/else 9 (12 pts), loops 1 (2 pts), ternaries 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, 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":"loro-js/src/runtime/containers.ts"},"region":{"startLine":3925}}}],"partialFingerprints":{"codehealthFindingId/v1":"56982494fc5ae142cf2c048985aca72c6f8060d8f9e39a37ba59b798ebd17254"}},{"ruleId":"D2","level":"warning","message":{"text":"ephemeral.valueToEncoded (cognitive 17): ephemeral.valueToEncoded has cognitive complexity 17 (threshold 15). Drivers by points: if/else 10 (11 pts), ternaries 2 (4 pts), boolean chains 2 (nesting depth added 3). Of this number, 15 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. 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":"loro-js/src/runtime/ephemeral.ts"},"region":{"startLine":539}}}],"partialFingerprints":{"codehealthFindingId/v1":"d49f9c050c413982c8a73e5ba0b31a5fc7149d783e5d8ecd8a2dbafffcd7256e"}},{"ruleId":"D2","level":"warning","message":{"text":"DeltaRope::transform (cognitive 16): DeltaRope::transform has cognitive complexity 16 (threshold 15). Drivers by points: if/else 6 (9 pts), boolean chains 3, match/switch 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":"crates/delta/src/delta_rope.rs"},"region":{"startLine":237}}}],"partialFingerprints":{"codehealthFindingId/v1":"aee3ab8da0c37e2de0b3001530e306c9eb6fc92111970361d526ba4fd0fa3a76"}},{"ruleId":"D2","level":"warning","message":{"text":"generic_btree::iter::handle_lack_on_path_to_leaf (cognitive 16): generic_btree::iter::handle_lack_on_path_to_leaf has cognitive complexity 16 (threshold 15). Drivers by points: if/else 4 (12 pts), loops 2 (3 pts), boolean chains 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/generic-btree/src/iter.rs"},"region":{"startLine":263}}}],"partialFingerprints":{"codehealthFindingId/v1":"a45435c1b090023978769c92c938c7fc51ec07abd08bd0624aac705f47f49ef2"}},{"ruleId":"D2","level":"warning","message":{"text":"CrdtRope::get_diff (cognitive 16): CrdtRope::get_diff has cognitive complexity 16 (threshold 15). Drivers by points: if/else 7 (13 pts), match/switch 1 (2 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":"crates/loro-internal/src/container/richtext/tracker/crdt_rope.rs"},"region":{"startLine":421}}}],"partialFingerprints":{"codehealthFindingId/v1":"3697b583c64f9012823e0f0117cf17135b2d7da57939421face969da6867d7f4"}},{"ruleId":"D2","level":"warning","message":{"text":"MapDiff::compose (cognitive 16): MapDiff::compose has cognitive complexity 16 (threshold 15). Drivers by points: if/else 10 (13 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":"crates/loro-internal/src/delta/map.rs"},"region":{"startLine":43}}}],"partialFingerprints":{"codehealthFindingId/v1":"4f764b82512d8ae1a0760b086672719ece723c25ea157c279edb1e399b639920"}},{"ruleId":"D2","level":"warning","message":{"text":"ChangeStore::import_all (cognitive 16): ChangeStore::import_all has cognitive complexity 16 (threshold 15). Drivers by points: if/else 10 (14 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":"crates/loro-internal/src/oplog/change_store.rs"},"region":{"startLine":1313}}}],"partialFingerprints":{"codehealthFindingId/v1":"6fa3a0553f675f32bef3c51ee506aad16b36e05780bab87ec58a72694ddeab53"}},{"ruleId":"D2","level":"warning","message":{"text":"ListState::validate_diff (cognitive 16): ListState::validate_diff has cognitive complexity 16 (threshold 15). Drivers by points: if/else 4 (10 pts), match/switch 2 (5 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":"crates/loro-internal/src/state/list_state.rs"},"region":{"startLine":585}}}],"partialFingerprints":{"codehealthFindingId/v1":"4c2981e70fd599abb266a863b704f3445249ee8359354328c0a7865ef901c7f0"}},{"ruleId":"D2","level":"warning","message":{"text":"DocState::is_deleted (cognitive 16): DocState::is_deleted has cognitive complexity 16 (threshold 15). Drivers by points: if/else 6 (10 pts), boolean chains 2, loops 2, match/switch 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":"crates/loro-internal/src/state/dead_containers_cache.rs"},"region":{"startLine":47}}}],"partialFingerprints":{"codehealthFindingId/v1":"c49108ef1a2262eeafa0acc2e93b07d3775ff7cf654b5ab5a9983b67c90cce77"}},{"ruleId":"D2","level":"warning","message":{"text":"DocState::does_container_exist (cognitive 16): DocState::does_container_exist has cognitive complexity 16 (threshold 15). Drivers by points: if/else 9 (13 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":"crates/loro-internal/src/state.rs"},"region":{"startLine":1163}}}],"partialFingerprints":{"codehealthFindingId/v1":"2f32d13b4fccbd2c9fe9a398c37f611a01c80e69757fc7f8bea7d1bac2546807"}},{"ruleId":"D2","level":"warning","message":{"text":"SubscriberSet::retain (cognitive 16): SubscriberSet::retain has cognitive complexity 16 (threshold 15). Drivers by points: if/else 8 (12 pts), loops 2, match/switch 1 (2 pts) (nesting depth added 5). This file\u0027s own header attributes it to another copyright holder, so it is code this repository carries rather than code it wrote: restructuring the body in place forks it from upstream and turns every future re-sync into a manual merge. The performable moves are to leave the body as close to its upstream form as possible and keep it behind a narrow interface of your own, and to re-sync it when upstream changes \u2014 or, if it has already diverged far enough that you maintain it here, adopt it deliberately and then split the body into named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/utils/subscription.rs"},"region":{"startLine":409}}}],"partialFingerprints":{"codehealthFindingId/v1":"2b9867c8df3834545dfc3fda4265ef4217ae99753e8ab0344a512f3491478076"}},{"ruleId":"D2","level":"warning","message":{"text":"loro_internal::encoding::fast_snapshot::decode_updates_blob_meta (cognitive 16): loro_internal::encoding::fast_snapshot::decode_updates_blob_meta has cognitive complexity 16 (threshold 15). Drivers by points: if/else 3 (8 pts), loops 3 (4 pts), match/switch 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":"crates/loro-internal/src/encoding/fast_snapshot.rs"},"region":{"startLine":600}}}],"partialFingerprints":{"codehealthFindingId/v1":"3a2a464777e4d507f581b0777ce804853481a95045a5d8eaf5ebae554ac324fa"}},{"ruleId":"D2","level":"warning","message":{"text":"loro_internal::encoding::json_schema::json::redact (cognitive 16): loro_internal::encoding::json_schema::json::redact has cognitive complexity 16 (threshold 15). Drivers by points: if/else 5 (10 pts), loops 2 (3 pts), match/switch 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":"crates/loro-internal/src/encoding/json_schema.rs"},"region":{"startLine":1745}}}],"partialFingerprints":{"codehealthFindingId/v1":"940ac2dd500e5f3d8f1f85d58eac063922192750f23b1975c2dd02fe96e5af03"}},{"ruleId":"D2","level":"warning","message":{"text":"loro_internal::oplog::known_history::op_eq (cognitive 16): loro_internal::oplog::known_history::op_eq has cognitive complexity 16 (threshold 15). Drivers by points: match/switch 4 (8 pts), boolean chains 5, if/else 3 (nesting depth added 4). To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/oplog/known_history.rs"},"region":{"startLine":745}}}],"partialFingerprints":{"codehealthFindingId/v1":"2d51dbfba752f03492c070473ddf8de48740c8d83cb93b8e51b502906d5ac715"}},{"ruleId":"D2","level":"warning","message":{"text":"loro_internal::state::value_decode::decode (cognitive 16): loro_internal::state::value_decode::decode has cognitive complexity 16 (threshold 15). Drivers by points: if/else 6 (13 pts), match/switch 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":"crates/loro-internal/src/state/value_decode.rs"},"region":{"startLine":120}}}],"partialFingerprints":{"codehealthFindingId/v1":"bbe55da6d55cdd40f27ecacc1053661a8ed15c6c1068540784c3d9fb2cbaa48d"}},{"ruleId":"D2","level":"warning","message":{"text":"loro_internal::undo::undo (cognitive 16): loro_internal::undo::undo has cognitive complexity 16 (threshold 15). Drivers by points: if/else 7 (12 pts), match/switch 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":"crates/loro-internal/src/undo.rs"},"region":{"startLine":1243}}}],"partialFingerprints":{"codehealthFindingId/v1":"d9028d0668b1a987357f658a51a3597c4de19a8e545e57cee7356652d9cfcfcb"}},{"ruleId":"D2","level":"warning","message":{"text":"loro_wasm::convert::delta_item_to_js (cognitive 16): loro_wasm::convert::delta_item_to_js has cognitive complexity 16 (threshold 15). Drivers by points: if/else 4 (8 pts), match/switch 2 (5 pts), loops 1 (3 pts) (nesting depth added 9). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-wasm/src/convert.rs"},"region":{"startLine":277}}}],"partialFingerprints":{"codehealthFindingId/v1":"367eb2e60a850f306c283c9dc07344148ae691d3faba7a6b50198863b92772b2"}},{"ruleId":"D2","level":"warning","message":{"text":"loro_wasm_tools::strip_custom (cognitive 16): loro_wasm_tools::strip_custom has cognitive complexity 16 (threshold 15). Drivers by points: if/else 6 (12 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":"crates/loro-wasm-tools/src/main.rs"},"region":{"startLine":182}}}],"partialFingerprints":{"codehealthFindingId/v1":"caee04979ec90a3989fc4dd6033bb8e2d1afe5d3aaff083b8796125fac6a0535"}},{"ruleId":"D2","level":"warning","message":{"text":"SstableReader.get (cognitive 16): SstableReader.get has cognitive complexity 16 (threshold 15). Drivers by points: if/else 7 (9 pts), ternaries 2 (3 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":"loro-js/src/codec/sstable.ts"},"region":{"startLine":130}}}],"partialFingerprints":{"codehealthFindingId/v1":"14029bce652b286a1f5403479f8c75840a7e4526f37ed6504d9aefefb0dcf7cc"}},{"ruleId":"D2","level":"warning","message":{"text":"jsonpath.parseJsonPath (cognitive 16): jsonpath.parseJsonPath has cognitive complexity 16 (threshold 15). Drivers by points: if/else 7 (11 pts), loops 2 (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":"loro-js/src/runtime/jsonpath.ts"},"region":{"startLine":142}}}],"partialFingerprints":{"codehealthFindingId/v1":"fb739693bb69d664ba2bf14d09bde00de3097f209fd91a6e816f479a828d9b92"}},{"ruleId":"D2","level":"warning","message":{"text":"jsonpath.sliceValues (cognitive 16): jsonpath.sliceValues has cognitive complexity 16 (threshold 15). Drivers by points: ternaries 7 (9 pts), loops 2 (4 pts), if/else 3 (nesting depth added 4). Of this number, 13 points are the body\u0027s own statements and 3 belong to one function item inside it that branches. 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":"loro-js/src/runtime/jsonpath.ts"},"region":{"startLine":431}}}],"partialFingerprints":{"codehealthFindingId/v1":"5edc18870438efb73f29e388c5490fc9a1cf22ae043b6b3da48e85efd7956d46"}},{"ruleId":"D2","level":"warning","message":{"text":"LoroDoc._isContainerDeleted (cognitive 16): LoroDoc._isContainerDeleted has cognitive complexity 16 (threshold 15). Drivers by points: boolean chains 10, if/else 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. This file is where this pass\u0027s cognitive complexity CONCENTRATES: loro-js/src/runtime/document.ts holds 56 of the 301 methods over the threshold \u2014 including the worst \u2014 and 1420 of the 5127 points over it (28%), 4.3\u00D7 the next-largest file (crates/loro-internal/src/loro.rs at 332). No single row can show this, because each is measured only against the threshold: reducing this one file moves this dimension further than any other file in the repository."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/document.ts"},"region":{"startLine":3532}}}],"partialFingerprints":{"codehealthFindingId/v1":"59d2617a72199b3c8879cf655cca78c7e9f2f919404c8967a2eb1915e32a848c"}},{"ruleId":"D2","level":"warning","message":{"text":"LoroDoc._undoIdSpan (cognitive 16): LoroDoc._undoIdSpan has cognitive complexity 16 (threshold 15). Drivers by points: if/else 5 (10 pts), loops 3 (4 pts), boolean chains 2 (nesting depth added 6). 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. This file is where this pass\u0027s cognitive complexity CONCENTRATES: loro-js/src/runtime/document.ts holds 56 of the 301 methods over the threshold \u2014 including the worst \u2014 and 1420 of the 5127 points over it (28%), 4.3\u00D7 the next-largest file (crates/loro-internal/src/loro.rs at 332). No single row can show this, because each is measured only against the threshold: reducing this one file moves this dimension further than any other file in the repository."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/document.ts"},"region":{"startLine":3576}}}],"partialFingerprints":{"codehealthFindingId/v1":"45bf027241ee1e8496dc24366fcc17cf6577a8b569600efa05510b1fd6558087"}},{"ruleId":"D2","level":"warning","message":{"text":"document.restoreBlueprint (cognitive 16): document.restoreBlueprint has cognitive complexity 16 (threshold 15). Drivers by points: if/else 8 (12 pts), 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. This file is where this pass\u0027s cognitive complexity CONCENTRATES: loro-js/src/runtime/document.ts holds 56 of the 301 methods over the threshold \u2014 including the worst \u2014 and 1420 of the 5127 points over it (28%), 4.3\u00D7 the next-largest file (crates/loro-internal/src/loro.rs at 332). No single row can show this, because each is measured only against the threshold: reducing this one file moves this dimension further than any other file in the repository."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/document.ts"},"region":{"startLine":10544}}}],"partialFingerprints":{"codehealthFindingId/v1":"6d8ffe69597cbbc95be35cd979737cdd327697b564974bf0c7e9a86586ca28b3"}},{"ruleId":"D2","level":"warning","message":{"text":"TextStyleIndex.transitions (cognitive 16): TextStyleIndex.transitions 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). Of this number, 11 points are the body\u0027s own statements and 5 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":"loro-js/src/runtime/text-style-index.ts"},"region":{"startLine":271}}}],"partialFingerprints":{"codehealthFindingId/v1":"a073118600d3dfbb768cb38b46f772e6f514a1623445b09ea3ac1761063cd2ee"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: runtime/document.ts: FileTooLong \u2014 8450 significant lines (blank, comment-only and punctuation-only lines excluded), about 74% of them inside a single declaration: LoroDoc (278-8852). The bar is 500 significant lines; this is 7950 over it, 16.90\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":"loro-js/src/runtime/document.ts"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"372c640df7d54c7e3dfc8fa4f5b8e54a2ca1c9c03ec8d01ea1edc33e45677971"}},{"ruleId":"D3","level":"warning","message":{"text":"ClassTooLong: LoroDoc: ClassTooLong \u2014 6230 significant lines (blank, comment-only and punctuation-only lines excluded), 249 methods. The bar is 400 significant lines; this is 5830 over it, 15.58\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":"loro-js/src/runtime/document.ts"},"region":{"startLine":278}}}],"partialFingerprints":{"codehealthFindingId/v1":"a511584313705202bccdcfbe99fd0d33cbaed90cfc0df3d20bfd28655675cdc2"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: LoroDoc: TooManyMethods \u2014 249 methods. The bar is 30 methods; this is 219 over it, 8.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":"loro-js/src/runtime/document.ts"},"region":{"startLine":278}}}],"partialFingerprints":{"codehealthFindingId/v1":"a7a14e7d028d528e049cfb9a3ea7fc4e152a1b54b1cbf316c87286b9bf19cb6b"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: runtime/sequence-index.ts: FileTooLong \u2014 3364 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 2864 over it, 6.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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"7325ff119ad0211e1a90853570db333f8e2f0e5b12a9a5988d48a38a1c447d76"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: src/handler.rs: FileTooLong \u2014 3358 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted). The bar is 500 significant lines; this is 2858 over it, 6.72\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":"crates/loro-internal/src/handler.rs"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"696b9e1fd0e1342fd60566c9e6bf3d1c999cd45af831a2f6c92eae79f57f6032"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: src/lib.rs: FileTooLong \u2014 3247 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted), declaring 43 free functions. The bar is 500 significant lines; this is 2747 over it, 6.49\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":"crates/loro-wasm/src/lib.rs"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"bc15a90b1ffe4b7820dda919120a5ff5394d7ffa70bfb5fc320dee87cd3f738c"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: LoroDoc: TooManyMethods \u2014 173 methods, declared across 9 files: src/loro.rs (155), src/txn.rs (9), src/fork.rs (2), jsonpath/jsonpath_impl.rs (2), \u002B5 more file(s). The bar is 30 methods; this is 143 over it, 5.77\u00D7 the bar. That list is where to read them, not a suggestion to split the file: the members belong to the type wherever they are declared, so moving them between files leaves the count unchanged. 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":"crates/loro-internal/src/lib.rs"},"region":{"startLine":126}}}],"partialFingerprints":{"codehealthFindingId/v1":"972ff20f6eae825cc2e600a9966c2aff4a40e90a10e35830368ef7c8bfcb6231"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: runtime/containers.ts: FileTooLong \u2014 2845 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 2345 over it, 5.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":"loro-js/src/runtime/containers.ts"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"b98e72da9f7fdcb4711dc235326c3516dea08a7bba0f6f1aaae2c299e1101b6e"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: src/loro.rs: FileTooLong \u2014 2801 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted), about 88% of them inside a single declaration: LoroDoc (3 blocks, 97-4396). The bar is 500 significant lines; this is 2301 over it, 5.60\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":"crates/loro-internal/src/loro.rs"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"f964d8a8a11787979ed3e2e823bd6356be50ee34e7bf45fa204957afea35b9fa"}},{"ruleId":"D3","level":"warning","message":{"text":"ClassTooLong: SequenceIndex: ClassTooLong \u2014 1692 significant lines (blank, comment-only and punctuation-only lines excluded), 81 methods. The bar is 400 significant lines; this is 1292 over it, 4.23\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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":166}}}],"partialFingerprints":{"codehealthFindingId/v1":"5ad7d58681f90971f718a64c6c65988e7a607348d2d857c012e7bc5e93fd6bce"}},{"ruleId":"D3","level":"warning","message":{"text":"ClassTooLong: BTree: ClassTooLong \u2014 1664 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted), 77 methods, 7 blocks, lines 62-2993. The bar is 400 significant lines; this is 1264 over it, 4.16\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":"crates/generic-btree/src/lib.rs"},"region":{"startLine":62}}}],"partialFingerprints":{"codehealthFindingId/v1":"ed14405cc704c65753b06a9753e529a9d84343c9a0aefb12237a7b6ce401e244"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: richtext/richtext_state.rs: FileTooLong \u2014 2017 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted). The bar is 500 significant lines; this is 1517 over it, 4.03\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":"crates/loro-internal/src/container/richtext/richtext_state.rs"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"c5eff7b8cd456b4faa6714abda8402559654a567dc9b8047529cebbfc2493657"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: LoroDoc: TooManyMethods \u2014 117 methods. The bar is 30 methods; this is 87 over it, 3.90\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":"crates/loro/src/lib.rs"},"region":{"startLine":122}}}],"partialFingerprints":{"codehealthFindingId/v1":"7c608186d281a9375edbdd7d59f15976f6fb9d38b1d7df973360add042e0d8a9"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: src/lib.rs: FileTooLong \u2014 1945 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted), about 86% of them inside a single declaration: BTree (7 blocks, 62-2993). The bar is 500 significant lines; this is 1445 over it, 3.89\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":"crates/generic-btree/src/lib.rs"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"579f7798a17b596c7652c779485e99529cab0f3f92e73b107f67471f39bfcb4a"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: DocState: TooManyMethods \u2014 102 methods, declared across 6 files: src/state.rs (87), state/container_tree.rs (5), state/mergeable.rs (4), src/parent.rs (2), \u002B2 more file(s). The bar is 30 methods; this is 72 over it, 3.40\u00D7 the bar. That list is where to read them, not a suggestion to split the file: the members belong to the type wherever they are declared, so moving them between files leaves the count unchanged. 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":"crates/loro-internal/src/state.rs"},"region":{"startLine":159}}}],"partialFingerprints":{"codehealthFindingId/v1":"1c68f73a6818e4ddb70b080b0eaf1c988a7382e98e9bbfb2decc5108323a2b3b"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: OpLog: TooManyMethods \u2014 101 methods, declared across 5 files: src/oplog.rs (86), oplog/known_history.rs (9), oplog/pending_changes.rs (4), encoding/fast_snapshot.rs (1), \u002B1 more file(s). The bar is 30 methods; this is 71 over it, 3.37\u00D7 the bar. That list is where to read them, not a suggestion to split the file: the members belong to the type wherever they are declared, so moving them between files leaves the count unchanged. 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":"crates/loro-internal/src/oplog.rs"},"region":{"startLine":52}}}],"partialFingerprints":{"codehealthFindingId/v1":"e1b655e264ab3de54a50aa3862ebacbcca98395f75807afd5e2b3d0735dc88f6"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: LoroDoc.#applyVersionTransition: MethodTooLong \u2014 #applyVersionTransition runs 334 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 234 over it, 3.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":"loro-js/src/runtime/document.ts"},"region":{"startLine":5836}}}],"partialFingerprints":{"codehealthFindingId/v1":"6848e81434c340ca69a148d990bf40a5fc66db3e87c8d9f352779c8ae9d703cb"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: src/state.rs: FileTooLong \u2014 1660 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted), about 80% of them inside a single declaration: DocState (3 blocks, 159-2655). The bar is 500 significant lines; this is 1160 over it, 3.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":"crates/loro-internal/src/state.rs"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"b2a65a8859de2a95ae0396d92466ab750c4b7a0e18f6c73ea8264997602b8923"}},{"ruleId":"D3","level":"warning","message":{"text":"ClassTooLong: DocState: ClassTooLong \u2014 1327 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted), 102 methods, 3 blocks, lines 159-2655. The bar is 400 significant lines; this is 927 over it, 3.32\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":"crates/loro-internal/src/state.rs"},"region":{"startLine":159}}}],"partialFingerprints":{"codehealthFindingId/v1":"779d41622bb24b10062ccee5fb8c39ec3e988245615e7d3e71a102b5575ede32"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: oplog/change_store.rs: FileTooLong \u2014 1620 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted). The bar is 500 significant lines; this is 1120 over it, 3.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":"crates/loro-internal/src/oplog/change_store.rs"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"bf594db3c86762a66d9d95fef2340e1b9f234526aeb68e598a633aa20264e0ab"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: src/diff_calc.rs: FileTooLong \u2014 1515 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted). The bar is 500 significant lines; this is 1015 over it, 3.03\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":"crates/loro-internal/src/diff_calc.rs"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"759ce13cb2132061ba2bc48c580eb3973835903bec610bf23b5220fb7fe4e8ad"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: LoroDoc: TooManyMethods \u2014 85 methods, declared across 2 files: src/lib.rs (83), src/container_tree.rs (2). The bar is 30 methods; this is 55 over it, 2.83\u00D7 the bar. That list is where to read them, not a suggestion to split the file: the members belong to the type wherever they are declared, so moving them between files leaves the count unchanged. 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":"crates/loro-wasm/src/lib.rs"},"region":{"startLine":306}}}],"partialFingerprints":{"codehealthFindingId/v1":"58d9e64758fce6fb62cccd6aca175529ae533ec9d41ab1ceaffc0be3efc6a833"}},{"ruleId":"D3","level":"warning","message":{"text":"FunctionTooLong: loro_internal::dag::_find_meet_and_mode: FunctionTooLong \u2014 loro_internal::dag::_find_meet_and_mode runs 271 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted) in one body. The bar is 100 significant lines; this is 171 over it, 2.71\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":"crates/loro-internal/src/dag.rs"},"region":{"startLine":740}}}],"partialFingerprints":{"codehealthFindingId/v1":"a65abdd559afa41ccab59a7f1b2d2d2a23dc7444fe2f1598e323d96702663bec"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: src/lib.rs: FileTooLong \u2014 1354 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted). The bar is 500 significant lines; this is 854 over it, 2.71\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":"crates/loro/src/lib.rs"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"a4a7103286aeab073fdb3cca56e5f163a4d75ad7c697ec3e1bcc99ca940b745f"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: SequenceIndex: TooManyMethods \u2014 81 methods. The bar is 30 methods; this is 51 over it, 2.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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":166}}}],"partialFingerprints":{"codehealthFindingId/v1":"a7a7fd450d99dd55acbfa470b1aa0a40b2bf1703c02d779bb0159723df5fa1ee"}},{"ruleId":"D3","level":"warning","message":{"text":"ClassTooLong: TextHandler: ClassTooLong \u2014 1034 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted), 53 methods, 4 blocks, lines 451-3076. The bar is 400 significant lines; this is 634 over it, 2.59\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":"crates/loro-internal/src/handler.rs"},"region":{"startLine":451}}}],"partialFingerprints":{"codehealthFindingId/v1":"646429fd7be70e77ee52062bad72e5c364ad1426e79a6486dee29bd2fbd98b4e"}},{"ruleId":"D3","level":"warning","message":{"text":"ClassTooLong: RichtextState: ClassTooLong \u2014 1033 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted), 54 methods, 3 blocks, lines 41-2968. The bar is 400 significant lines; this is 633 over it, 2.58\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":"crates/loro-internal/src/container/richtext/richtext_state.rs"},"region":{"startLine":41}}}],"partialFingerprints":{"codehealthFindingId/v1":"40684439937141fd4edfb31b1c9c09cec60a0e4e4e629c77310aba22a719204d"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: encoding/json_schema.rs: FileTooLong \u2014 1288 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted). The bar is 500 significant lines; this is 788 over it, 2.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":"crates/loro-internal/src/encoding/json_schema.rs"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"c555ed3bf9dceef821765830bffebf8ba02be24b0d322bd15a4cf3b20095f1af"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: BTree: TooManyMethods \u2014 77 methods. The bar is 30 methods; this is 47 over it, 2.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":"crates/generic-btree/src/lib.rs"},"region":{"startLine":62}}}],"partialFingerprints":{"codehealthFindingId/v1":"28c6e589429012925c4e8064ecc3a0392f6de9db6a94fae3b19fe53e1cae92e9"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: state/tree_state.rs: FileTooLong \u2014 1283 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted). The bar is 500 significant lines; this is 783 over it, 2.57\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":"crates/loro-internal/src/state/tree_state.rs"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"853792042d5fdd2c05f4d2337625f597918498f44821625629e713a08c3b94ef"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: state/movable_list_state.rs: FileTooLong \u2014 1171 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted). The bar is 500 significant lines; this is 671 over it, 2.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":"crates/loro-internal/src/state/movable_list_state.rs"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"a90e71b1ee9d3c3a4c5efef1c381c9a2fac45ca288a52f8dd724eb098598cf38"}},{"ruleId":"D3","level":"warning","message":{"text":"ClassTooLong: AppDag: ClassTooLong \u2014 924 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted), 59 methods, 4 blocks, lines 30-1721. The bar is 400 significant lines; this is 524 over it, 2.31\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":"crates/loro-internal/src/oplog/loro_dag.rs"},"region":{"startLine":30}}}],"partialFingerprints":{"codehealthFindingId/v1":"955b216e8a60d1c3feeaeed2f79791f7940786cff32a29dc6241b9b163a0fedf"}},{"ruleId":"D3","level":"warning","message":{"text":"ClassTooLong: OpLog: ClassTooLong \u2014 918 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted), 101 methods, 3 blocks, lines 52-1806. The bar is 400 significant lines; this is 518 over it, 2.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":"crates/loro-internal/src/oplog.rs"},"region":{"startLine":52}}}],"partialFingerprints":{"codehealthFindingId/v1":"fd474063cdeed99a271fddb8f5c87e9e08c9a037c62c9f171e16227f757b825d"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: LoroText: TooManyMethods \u2014 68 methods. The bar is 30 methods; this is 38 over it, 2.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":"loro-js/src/runtime/containers.ts"},"region":{"startLine":1359}}}],"partialFingerprints":{"codehealthFindingId/v1":"32529f67fb4e4b4db3bd078460ee381892292c4d33b418667bc826b4c7f0d8e2"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: LoroDoc.#importBlob: MethodTooLong \u2014 #importBlob runs 224 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 124 over it, 2.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":"loro-js/src/runtime/document.ts"},"region":{"startLine":792}}}],"partialFingerprints":{"codehealthFindingId/v1":"2771022a220f3c29eeb128fd16c5c9b50d77de50e7f419a4358be45ef4564e7b"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: src/oplog.rs: FileTooLong \u2014 1110 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted), about 83% of them inside a single declaration: OpLog (3 blocks, 52-1806). The bar is 500 significant lines; this is 610 over it, 2.22\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":"crates/loro-internal/src/oplog.rs"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"f1fb58b36f2b9eee8a43b2f14e464c9e1dab46907aa2dccaab54486102de294f"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: oplog/loro_dag.rs: FileTooLong \u2014 1079 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted), about 86% of them inside a single declaration: AppDag (4 blocks, 30-1721). The bar is 500 significant lines; this is 579 over it, 2.16\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":"crates/loro-internal/src/oplog/loro_dag.rs"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"00ec1bbe112ea501943ddf75637d46c6497a84fe1bc1cc42c91fb0089a39662d"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: state/richtext_state.rs: FileTooLong \u2014 1067 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted), about 61% of them inside a single declaration: RichtextState (5 blocks, 42-1136). The bar is 500 significant lines; this is 567 over it, 2.13\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":"crates/loro-internal/src/state/richtext_state.rs"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"2db9d64454afff888058ae1cd6bd8eef4ea7413a1bc7f184fe2856e7d1bfac8c"}},{"ruleId":"D3","level":"warning","message":{"text":"FunctionTooLong: loro_internal::encoding::outdated_encode_reordered::decode_op: FunctionTooLong \u2014 loro_internal::encoding::outdated_encode_reordered::decode_op runs 205 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted) 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":"crates/loro-internal/src/encoding/outdated_encode_reordered.rs"},"region":{"startLine":288}}}],"partialFingerprints":{"codehealthFindingId/v1":"ee6e5c22de2de72d9c0f59ee0bea93b67cf7fe9e64027e6d08ffab71886185c7"}},{"ruleId":"D3","level":"warning","message":{"text":"FunctionTooLong: loro_internal::encoding::json_schema::decode_op: FunctionTooLong \u2014 loro_internal::encoding::json_schema::decode_op runs 199 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted) in one body. The bar is 100 significant lines; this is 99 over it, 1.99\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":"crates/loro-internal/src/encoding/json_schema.rs"},"region":{"startLine":780}}}],"partialFingerprints":{"codehealthFindingId/v1":"b730e2c1cf1dac882b05df98cecab153259e8d3df6c51f3f445dba81ab97fe88"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: AppDag: TooManyMethods \u2014 59 methods. The bar is 30 methods; this is 29 over it, 1.97\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":"crates/loro-internal/src/oplog/loro_dag.rs"},"region":{"startLine":30}}}],"partialFingerprints":{"codehealthFindingId/v1":"b81a61daac323d0456c49fecb8e71929d80404ce724b9afcbaaa579d7fff3ed9"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: ChangeStore: TooManyMethods \u2014 58 methods. The bar is 30 methods; this is 28 over it, 1.93\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":"crates/loro-internal/src/oplog/change_store.rs"},"region":{"startLine":77}}}],"partialFingerprints":{"codehealthFindingId/v1":"c2c92268554569f5b5ff7b6525a6001effdeec55a31b17bdbb39c532f207c18a"}},{"ruleId":"D3","level":"warning","message":{"text":"ClassTooLong: LoroDoc: ClassTooLong \u2014 765 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted), 85 methods, 4 blocks, lines 306-2850. The bar is 400 significant lines; this is 365 over it, 1.91\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":"crates/loro-wasm/src/lib.rs"},"region":{"startLine":306}}}],"partialFingerprints":{"codehealthFindingId/v1":"2cfa6b5810aa40a38657d495c5e5079c1e2910eb902dcfa2c5839e9fce6efa3c"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: LoroDoc.undo_internal_with: MethodTooLong \u2014 undo_internal_with runs 191 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted) in one body. The bar is 100 significant lines; this is 91 over it, 1.91\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":"crates/loro-internal/src/loro.rs"},"region":{"startLine":1565}}}],"partialFingerprints":{"codehealthFindingId/v1":"4a55b6431be94ffab949040b97fa60313cbd3778c8c6d89ed997e396331ba64c"}},{"ruleId":"D3","level":"warning","message":{"text":"ClassTooLong: LoroText: ClassTooLong \u2014 756 significant lines (blank, comment-only and punctuation-only lines excluded), 68 methods. The bar is 400 significant lines; this is 356 over it, 1.89\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":"loro-js/src/runtime/containers.ts"},"region":{"startLine":1359}}}],"partialFingerprints":{"codehealthFindingId/v1":"cf81cfb916c236cf186c01cf9642b4723bdbd5fab1bbf46a0ba0843457138219"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: LoroDoc.#containerState: MethodTooLong \u2014 #containerState runs 186 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 86 over it, 1.86\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":"loro-js/src/runtime/document.ts"},"region":{"startLine":8234}}}],"partialFingerprints":{"codehealthFindingId/v1":"08b0be135d7db3026d8e6656a2af02459fabca1c2796e8596f4efca4aaccda06"}},{"ruleId":"D3","level":"warning","message":{"text":"FunctionTooLong: loro_internal::encoding::json_schema::encode_change: FunctionTooLong \u2014 loro_internal::encoding::json_schema::encode_change runs 185 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted) in one body. The bar is 100 significant lines; this is 85 over it, 1.85\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":"crates/loro-internal/src/encoding/json_schema.rs"},"region":{"startLine":291}}}],"partialFingerprints":{"codehealthFindingId/v1":"17724f2f89956b65e2b952335f2254fb6b4e08b8b7fa5f8a5d149283a4baacf2"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: RichtextState: 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":"crates/loro-internal/src/container/richtext/richtext_state.rs"},"region":{"startLine":41}}}],"partialFingerprints":{"codehealthFindingId/v1":"0d2a2bc16680546b4db20abad2d877d266b885249a90a886cef4af8144e2e2e5"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: encoding/value.rs: FileTooLong \u2014 895 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted). The bar is 500 significant lines; this is 395 over it, 1.79\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":"crates/loro-internal/src/encoding/value.rs"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"ad5f9731cdd32a5f1dd05e98e30470c4f3d17f650baad2c7a047735a9f917942"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: TextHandler: TooManyMethods \u2014 53 methods. The bar is 30 methods; this is 23 over it, 1.77\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":"crates/loro-internal/src/handler.rs"},"region":{"startLine":451}}}],"partialFingerprints":{"codehealthFindingId/v1":"478b09400ecb2addf07a51d0c48e7f4073333e2224e6c7c72e4daa96841a2300"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: DiffCalculator.try_calc_diff_internal: MethodTooLong \u2014 try_calc_diff_internal runs 176 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted) in one body. The bar is 100 significant lines; this is 76 over it, 1.76\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":"crates/loro-internal/src/diff_calc.rs"},"region":{"startLine":186}}}],"partialFingerprints":{"codehealthFindingId/v1":"d0806aeadf009604a95f1210038296f49a072435a7cca18f36cf67992df4eb67"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: MovableListState.decode_snapshot_fast: MethodTooLong \u2014 decode_snapshot_fast runs 176 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted) in one body. The bar is 100 significant lines; this is 76 over it, 1.76\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":"crates/loro-internal/src/state/movable_list_state.rs"},"region":{"startLine":1626}}}],"partialFingerprints":{"codehealthFindingId/v1":"4f343e79e2f2b98f486c6afe133f90e68ac75fa77622f60b40239b15f4d7c43b"}},{"ruleId":"D3","level":"warning","message":{"text":"FunctionTooLong: document.jsonOperationToDecoded: FunctionTooLong \u2014 jsonOperationToDecoded runs 173 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 73 over it, 1.73\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":"loro-js/src/runtime/document.ts"},"region":{"startLine":10197}}}],"partialFingerprints":{"codehealthFindingId/v1":"d49d022e3cd3ad1997938488830d33d8358b6889c9ee7fbf4412d0f1d8533c49"}},{"ruleId":"D3","level":"warning","message":{"text":"FunctionTooLong: loro_internal::txn::change_to_diff: FunctionTooLong \u2014 loro_internal::txn::change_to_diff runs 168 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted) in one body. The bar is 100 significant lines; this is 68 over it, 1.68\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":"crates/loro-internal/src/txn.rs"},"region":{"startLine":968}}}],"partialFingerprints":{"codehealthFindingId/v1":"b10de72e9df186ca293137aea86d1146e640a9600338ece5a83b7073730d1cfe"}},{"ruleId":"D3","level":"warning","message":{"text":"FunctionTooLong: loro_internal::encoding::shallow_snapshot::export_shallow_snapshot_inner: FunctionTooLong \u2014 loro_internal::encoding::shallow_snapshot::export_shallow_snapshot_inner runs 167 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted) in one body. The bar is 100 significant lines; this is 67 over it, 1.67\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":"crates/loro-internal/src/encoding/shallow_snapshot.rs"},"region":{"startLine":301}}}],"partialFingerprints":{"codehealthFindingId/v1":"2caea660d4e171225cb3c98f7b7245710f4bfd0f23a1feba28f1663a7a67cf75"}},{"ruleId":"D3","level":"warning","message":{"text":"ClassTooLong: RichtextState: ClassTooLong \u2014 655 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted), 36 methods, 5 blocks, lines 42-1136. The bar is 400 significant lines; this is 255 over it, 1.64\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":"crates/loro-internal/src/state/richtext_state.rs"},"region":{"startLine":42}}}],"partialFingerprints":{"codehealthFindingId/v1":"19a02668f4545fe0de90a55cd2b80aba34a0fc76e6494f6444dfbe801a141086"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: src/lib.rs: FileTooLong \u2014 808 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted). The bar is 500 significant lines; this is 308 over it, 1.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":"crates/loro-common/src/lib.rs"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"69fa2040e149d17b01d84d4297d607fe1c5c1f0429a297aaac078816be6d6a32"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: codec/state-snapshot.ts: FileTooLong \u2014 806 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 306 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":"loro-js/src/codec/state-snapshot.ts"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"bdf04578f0bc0f713b0614d15c2aff4c0f87b82ebdaf1d3f1c32461cf9e2a84f"}},{"ruleId":"D3","level":"warning","message":{"text":"ClassTooLong: TreeHandler: ClassTooLong \u2014 644 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted), 44 methods, 4 blocks, lines 25-1197. The bar is 400 significant lines; this is 244 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":"crates/loro-internal/src/handler/tree.rs"},"region":{"startLine":25}}}],"partialFingerprints":{"codehealthFindingId/v1":"76388c0624877e89890e855716478ca3ab4909815d8e297d03f2f394e37b9b3d"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: src/txn.rs: FileTooLong \u2014 803 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted). The bar is 500 significant lines; this is 303 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":"crates/loro-internal/src/txn.rs"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"8eddd75b558015750e060f34eedb27c5357c9e26d3da8c84d03f2b04723926fb"}},{"ruleId":"D3","level":"warning","message":{"text":"FunctionTooLong: loro_internal::oplog::change_store::block_encode::decode_block: FunctionTooLong \u2014 loro_internal::oplog::change_store::block_encode::decode_block runs 159 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted) 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":"crates/loro-internal/src/oplog/change_store/block_encode.rs"},"region":{"startLine":610}}}],"partialFingerprints":{"codehealthFindingId/v1":"ff62b53c4e5e7376ee083211233f2f843580d08f9c7e0e5174649d16f247c030"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: MovableListHandler: TooManyMethods \u2014 47 methods, declared across 2 files: src/handler.rs (40), handler/movable_list_apply_delta.rs (7). The bar is 30 methods; this is 17 over it, 1.57\u00D7 the bar. That list is where to read them, not a suggestion to split the file: the members belong to the type wherever they are declared, so moving them between files leaves the count unchanged. 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":"crates/loro-internal/src/handler.rs"},"region":{"startLine":788}}}],"partialFingerprints":{"codehealthFindingId/v1":"b55311dae2ddd5039c73e0645dff03eb336ff0a793cf8f5846cf13e55c76dd68"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: LoroDoc.diff: MethodTooLong \u2014 diff runs 156 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 56 over it, 1.56\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":"loro-js/src/runtime/document.ts"},"region":{"startLine":1263}}}],"partialFingerprints":{"codehealthFindingId/v1":"37269f8107052c07d28aa55b6d98cc0ab1d1a00eec95ff5e3be4f463bc6e95f0"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: LoroDoc.#applyOperation: MethodTooLong \u2014 #applyOperation runs 156 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 56 over it, 1.56\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":"loro-js/src/runtime/document.ts"},"region":{"startLine":5167}}}],"partialFingerprints":{"codehealthFindingId/v1":"6f70e25ef6679505891ba1ba5783596f5cb7ba82f50db23a3e575fec866f75ff"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: handler/tree.rs: FileTooLong \u2014 779 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted), about 83% of them inside a single declaration: TreeHandler (4 blocks, 25-1197). The bar is 500 significant lines; this is 279 over it, 1.56\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":"crates/loro-internal/src/handler/tree.rs"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"8b896c7138bd8ecf7c1a8b1abb1ffdbbb567252390f3f3ba02b69984357dd8ce"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: LoroDoc.import_changes_and_apply_delta_to_state_if_needed: MethodTooLong \u2014 import_changes_and_apply_delta_to_state_if_needed runs 152 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted) in one body. The bar is 100 significant lines; this is 52 over it, 1.52\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":"crates/loro-internal/src/loro.rs"},"region":{"startLine":973}}}],"partialFingerprints":{"codehealthFindingId/v1":"acd615c31ed103b03313a9965607474dba6131e1df5bedbdb249486fbd7adb1d"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: src/value.rs: FileTooLong \u2014 751 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted). The bar is 500 significant lines; this is 251 over it, 1.50\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":"crates/loro-common/src/value.rs"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"bf46a069bd74a63d41a34c7c14a05c692948bea8932302a26b4e289a7537e2d0"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: ContainerStore: TooManyMethods \u2014 45 methods. The bar is 30 methods; this is 15 over it, 1.50\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":"crates/loro-internal/src/state/container_store.rs"},"region":{"startLine":41}}}],"partialFingerprints":{"codehealthFindingId/v1":"30a932799e67e2cebb7a3679dc880101a7782b05e349c2e5230991545a484cee"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: TextSequenceSpan: TooManyMethods \u2014 45 methods. The bar is 30 methods; this is 15 over it, 1.50\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":"loro-js/src/runtime/containers.ts"},"region":{"startLine":705}}}],"partialFingerprints":{"codehealthFindingId/v1":"e2d517bdc6f1fdd361ebf11d0802885ddacef1a4a03820a96f14914c5ee68d46"}},{"ruleId":"D3","level":"warning","message":{"text":"ClassTooLong: RichtextDiffCalculator: ClassTooLong \u2014 591 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted), 9 methods, 3 blocks, lines 1115-2073. The bar is 400 significant lines; this is 191 over it, 1.48\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":"crates/loro-internal/src/diff_calc.rs"},"region":{"startLine":1115}}}],"partialFingerprints":{"codehealthFindingId/v1":"10d44688b2de1611c5316fd1787b324e4da3e3422d8b49e05afeca52c2e99715"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: RichtextState.apply_diff: MethodTooLong \u2014 apply_diff runs 147 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted) 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":"crates/loro-internal/src/state/richtext_state.rs"},"region":{"startLine":627}}}],"partialFingerprints":{"codehealthFindingId/v1":"e112fc2e8a9015ce91ae4775aa5d9c073ed83ba94304d6e3269cc9d0af27f6c5"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: TreeHandler: TooManyMethods \u2014 44 methods. The bar is 30 methods; this is 14 over it, 1.47\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":"crates/loro-internal/src/handler/tree.rs"},"region":{"startLine":25}}}],"partialFingerprints":{"codehealthFindingId/v1":"5d1b7fbd7741db200bc803134b9c31d6a88f13baeb7ec49d6fcd96f7ef09cce0"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: ContainerWrapper: TooManyMethods \u2014 44 methods. The bar is 30 methods; this is 14 over it, 1.47\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":"crates/loro-internal/src/state/container_store/container_wrapper.rs"},"region":{"startLine":21}}}],"partialFingerprints":{"codehealthFindingId/v1":"ed09df1b27bc09fa16a78507a8178ae58eeb53167951c5d87866e350e4ee11a3"}},{"ruleId":"D3","level":"warning","message":{"text":"ClassTooLong: MovableListHandler: ClassTooLong \u2014 581 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted), 47 methods, 4 blocks, lines 788-4501. The bar is 400 significant lines; this is 181 over it, 1.45\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":"crates/loro-internal/src/handler.rs"},"region":{"startLine":788}}}],"partialFingerprints":{"codehealthFindingId/v1":"cd58fc558b4fea849178ce66364f2a693ab214e3590d9e69e5d0d6dfc4c7dfec"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: runtime/movable-list.ts: FileTooLong \u2014 726 significant lines (blank, comment-only and punctuation-only lines excluded), about 80% of them inside a single declaration: MovableListState (184-1008). The bar is 500 significant lines; this is 226 over it, 1.45\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":"loro-js/src/runtime/movable-list.ts"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"069e924a74dd56573b6cf4912e8d6a5f912a8b780d8f704e1e13b8be220685f3"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: oplog/known_history.rs: FileTooLong \u2014 724 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted). The bar is 500 significant lines; this is 224 over it, 1.45\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":"crates/loro-internal/src/oplog/known_history.rs"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"840f27ca67ce3c0060de4d6d93f646f8d848c6fb70dadddbd58cb0fcbbfe9184"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: src/undo.rs: FileTooLong \u2014 723 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted). The bar is 500 significant lines; this is 223 over it, 1.45\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":"crates/loro-internal/src/undo.rs"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"ab377b330304a8549c09e2cd501e793937fd37deec8d6bb8b66dc3e9466c2ded"}},{"ruleId":"D3","level":"warning","message":{"text":"ClassTooLong: MovableListState: ClassTooLong \u2014 578 significant lines (blank, comment-only and punctuation-only lines excluded), 32 methods. The bar is 400 significant lines; this is 178 over it, 1.45\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":"loro-js/src/runtime/movable-list.ts"},"region":{"startLine":184}}}],"partialFingerprints":{"codehealthFindingId/v1":"5db6b4589f37ed6de3937e1b378e065d6b3df72a1338286dd62e517d31ec0e70"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: src/version.rs: FileTooLong \u2014 714 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted). The bar is 500 significant lines; this is 214 over it, 1.43\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":"crates/loro-internal/src/version.rs"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"fd92f1a0cdb35c86baa9f7d60efd52e743470a7359a3275882c1fcc5e478f3c4"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: src/history_cache.rs: FileTooLong \u2014 709 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted). The bar is 500 significant lines; this is 209 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":"crates/loro-internal/src/history_cache.rs"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"4a5f11f4834d2cd482ddbd8ce5f717961accf859888f6dded94e239403f97e6c"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: TextHandler.insert_with_txn_and_attr: MethodTooLong \u2014 insert_with_txn_and_attr runs 141 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted) 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":"crates/loro-internal/src/handler.rs"},"region":{"startLine":2148}}}],"partialFingerprints":{"codehealthFindingId/v1":"2c4edbf9c5a443b996a242004fa0b034b5891f613af23df59ae4ee5fa6843120"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: DocState.get_value_by_path: MethodTooLong \u2014 get_value_by_path runs 141 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted) 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":"crates/loro-internal/src/state.rs"},"region":{"startLine":2456}}}],"partialFingerprints":{"codehealthFindingId/v1":"89d0cca33dd1d53cdf758ecc258019684d891b3d674521999d77edfe7454f41b"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: OpLog.try_iter_from_replay_base_causally_filtered: MethodTooLong \u2014 try_iter_from_replay_base_causally_filtered runs 140 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted) in one body. The bar is 100 significant lines; this is 40 over it, 1.40\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":"crates/loro-internal/src/oplog.rs"},"region":{"startLine":1269}}}],"partialFingerprints":{"codehealthFindingId/v1":"6a4c53a45c1c6dc93f72b78efebfc224d2b64287186eadde1688f4155970e0dc"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: runtime/jsonpath.ts: FileTooLong \u2014 693 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 193 over it, 1.39\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":"loro-js/src/runtime/jsonpath.ts"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"ef5bf891cbc3cfb64ed27db41a656741833e62c5609b54d7ce0f25e1913976bd"}},{"ruleId":"D3","level":"warning","message":{"text":"ClassTooLong: TreeState: ClassTooLong \u2014 553 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted), 33 methods, 4 blocks, lines 45-1505. The bar is 400 significant lines; this is 153 over it, 1.38\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":"crates/loro-internal/src/state/tree_state.rs"},"region":{"startLine":45}}}],"partialFingerprints":{"codehealthFindingId/v1":"54e3ea7d5557683605225d120659efb65ef82029711f979b586ae7dd6e9758e5"}},{"ruleId":"D3","level":"warning","message":{"text":"FunctionTooLong: loro_internal::diff::diff_impl::dj_diff: FunctionTooLong \u2014 loro_internal::diff::diff_impl::dj_diff runs 138 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted) 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":"crates/loro-internal/src/diff/diff_impl.rs"},"region":{"startLine":364}}}],"partialFingerprints":{"codehealthFindingId/v1":"4838583de72ff16ca7135bee79c4aa4f9c51373cac28d2faacb99b929e44509f"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: src/dag.rs: FileTooLong \u2014 689 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted). The bar is 500 significant lines; this is 189 over it, 1.38\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":"crates/loro-internal/src/dag.rs"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"6f2f01b7881a9a59315905f1988ea9a817297f32dbcce1ebde7cb708516c5778"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: src/value.rs: FileTooLong \u2014 687 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted). The bar is 500 significant lines; this is 187 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":"crates/loro-internal/src/value.rs"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"f6b6f65addec1f2450c62c2a211adfbefc87ced15087d5b9b84dfd9454420ac5"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: ValueReader.recursive_read_value_type_and_content: MethodTooLong \u2014 recursive_read_value_type_and_content runs 134 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted) 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":"crates/loro-internal/src/encoding/value.rs"},"region":{"startLine":691}}}],"partialFingerprints":{"codehealthFindingId/v1":"e90363715040c80b822e2067932c05fddccbb8a4502ec1af17c47e018f766414"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: src/sstable.rs: FileTooLong \u2014 667 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted). The bar is 500 significant lines; this is 167 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":"crates/kv-store/src/sstable.rs"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"990dcd5bacfac3586ae95a1fc2dc7dc9e38660ecb375c0bac34a8eb3252ab951"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: encoding/shallow_snapshot.rs: FileTooLong \u2014 667 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted). The bar is 500 significant lines; this is 167 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":"crates/loro-internal/src/encoding/shallow_snapshot.rs"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"82eb6e7993f1ce7ad3743aa5507549428bdf05db58e7c87bffffdc126cb0618b"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: SharedArena: TooManyMethods \u2014 40 methods. The bar is 30 methods; this is 10 over it, 1.33\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":"crates/loro-internal/src/arena.rs"},"region":{"startLine":103}}}],"partialFingerprints":{"codehealthFindingId/v1":"f41b4e8a6ab48a4efa16441efb2f4efded6bccec44efd75a05245942710d9043"}},{"ruleId":"D3","level":"warning","message":{"text":"FunctionTooLong: measure-snapshot-round-memory.runWorker: FunctionTooLong \u2014 runWorker runs 133 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 33 over it, 1.33\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":"crates/loro-wasm/scripts/measure-snapshot-round-memory.cjs"},"region":{"startLine":130}}}],"partialFingerprints":{"codehealthFindingId/v1":"93fb9016e0f38466ed91becf7c8f002d0713f26d85f73f597df01e464bbde9f0"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: RichtextDiffCalculator.calculate_diff: MethodTooLong \u2014 calculate_diff runs 132 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted) 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":"crates/loro-internal/src/diff_calc.rs"},"region":{"startLine":1829}}}],"partialFingerprints":{"codehealthFindingId/v1":"3576c194ffdb6d7c47db6ea0557f457889353cfefacc2e9d2abfee5b700765b9"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: Handler.apply_diff: MethodTooLong \u2014 apply_diff runs 132 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted) 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":"crates/loro-internal/src/handler.rs"},"region":{"startLine":1368}}}],"partialFingerprints":{"codehealthFindingId/v1":"6f8ad1009614c2ef4b2a6db39144921ae5ccb5a8b4c1a9aad3fb56382dd43141"}},{"ruleId":"D3","level":"warning","message":{"text":"FunctionTooLong: change-block-codec.decodeOperationContent: FunctionTooLong \u2014 decodeOperationContent 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":"loro-js/src/codec/change-block-codec.ts"},"region":{"startLine":358}}}],"partialFingerprints":{"codehealthFindingId/v1":"0f28912f3dc28928e13ba4711f8d91f00c6aca1f2dda4654b179cc4b93af2903"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: RichtextState.apply_diff_and_convert: MethodTooLong \u2014 apply_diff_and_convert runs 131 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted) in one body. The bar is 100 significant lines; this is 31 over it, 1.31\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":"crates/loro-internal/src/state/richtext_state.rs"},"region":{"startLine":391}}}],"partialFingerprints":{"codehealthFindingId/v1":"1cf2f365456c8c01f29dbae1a97809593081b7178622422fba01c4415b11f44e"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: codec/change-block-codec.ts: 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":"loro-js/src/codec/change-block-codec.ts"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"ced3b8ab9a710a402c8739606bb2af08691a509b948a3b206eb40f578f719038"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: LoroDoc.check_apply_diff_creates_no_unknown_container: MethodTooLong \u2014 check_apply_diff_creates_no_unknown_container runs 129 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted) in one body. The bar is 100 significant lines; this is 29 over it, 1.29\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":"crates/loro-internal/src/loro.rs"},"region":{"startLine":2592}}}],"partialFingerprints":{"codehealthFindingId/v1":"ec27db8d0b21a084c7486473946d2daab81909f571479f93ee52d45501b11d7b"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: DocState.apply_diff: MethodTooLong \u2014 apply_diff runs 129 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted) in one body. The bar is 100 significant lines; this is 29 over it, 1.29\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":"crates/loro-internal/src/state.rs"},"region":{"startLine":664}}}],"partialFingerprints":{"codehealthFindingId/v1":"48967ba592bc60bef744d8d65bbfb1033f4413fa700bb5cae9fd723d497bddb4"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: LoroDoc.#applyMovableListMoves: MethodTooLong \u2014 #applyMovableListMoves runs 128 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 28 over it, 1.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":"loro-js/src/runtime/document.ts"},"region":{"startLine":1476}}}],"partialFingerprints":{"codehealthFindingId/v1":"b37aeccc395cd1c10849f52fed07adb65a00b2eb64c4c96cb53d695bdca0f267"}},{"ruleId":"D3","level":"warning","message":{"text":"FunctionTooLong: loro_internal::oplog::change_store::block_meta_encode::decode_changes_header: FunctionTooLong \u2014 loro_internal::oplog::change_store::block_meta_encode::decode_changes_header runs 126 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted) 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":"crates/loro-internal/src/oplog/change_store/block_meta_encode.rs"},"region":{"startLine":89}}}],"partialFingerprints":{"codehealthFindingId/v1":"7ebc4c8d5b295f2e2f3f122c3efa14fd8362d5d4b3655b48950392064cbe8fc5"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: tracker/id_to_cursor.rs: FileTooLong \u2014 625 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted). The bar is 500 significant lines; this is 125 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":"crates/loro-internal/src/container/richtext/tracker/id_to_cursor.rs"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"06d6562ae89264f7a533d01ad4a71603e2e8f420f4654bc9b53f54e7e0041de5"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: LoroDoc.query_pos_internal: MethodTooLong \u2014 query_pos_internal runs 125 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted) in one body. The bar is 100 significant lines; this is 25 over it, 1.25\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":"crates/loro-internal/src/loro.rs"},"region":{"startLine":3698}}}],"partialFingerprints":{"codehealthFindingId/v1":"87d9f078f1173e3a368fe1080c46a5596cd25a9b9377645631199223ad54fdda"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: LoroDoc.#hydrateContainerState: MethodTooLong \u2014 #hydrateContainerState 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":"loro-js/src/runtime/document.ts"},"region":{"startLine":8545}}}],"partialFingerprints":{"codehealthFindingId/v1":"6ac3301d27966c3959f0368aae5d493426785ad77e8257b579b2656539e98bc7"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: LoroTree: TooManyMethods \u2014 37 methods. The bar is 30 methods; this is 7 over it, 1.23\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":"loro-js/src/runtime/containers.ts"},"region":{"startLine":2829}}}],"partialFingerprints":{"codehealthFindingId/v1":"851af707a2c3b978ca39466aadd009ef47de610cad9bfb79216dcd73e25396e0"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: src/convert.rs: FileTooLong \u2014 613 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted). The bar is 500 significant lines; this is 113 over it, 1.23\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":"crates/loro-wasm/src/convert.rs"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"6fb2b62468714ddb2c4b9c136ee2874d5fe9b5a48f12227230d58fa480d07691"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: RichtextDiffCalculator.apply_crdt_op_to_tracker: MethodTooLong \u2014 apply_crdt_op_to_tracker runs 122 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted) in one body. The bar is 100 significant lines; this is 22 over it, 1.22\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":"crates/loro-internal/src/diff_calc.rs"},"region":{"startLine":1276}}}],"partialFingerprints":{"codehealthFindingId/v1":"8b2c796768b3303878c0ba7a33527489af6d139dd47e6be1d65ac08d5c426ef8"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: InnerStore: TooManyMethods \u2014 36 methods. The bar is 30 methods; this is 6 over it, 1.20\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":"crates/loro-internal/src/state/container_store/inner_store.rs"},"region":{"startLine":29}}}],"partialFingerprints":{"codehealthFindingId/v1":"00bbce078aa09baf10ab05b28497f636a144114eadfe2ea290a6bc2dc9a0a867"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: RichtextState: TooManyMethods \u2014 36 methods. The bar is 30 methods; this is 6 over it, 1.20\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":"crates/loro-internal/src/state/richtext_state.rs"},"region":{"startLine":42}}}],"partialFingerprints":{"codehealthFindingId/v1":"ddb9b11372393ed8deaf07c2cf885f72673ce56d100064492506eacc0bf7393c"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: LoroDoc.#completeTreeRevivals: MethodTooLong \u2014 #completeTreeRevivals 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":"loro-js/src/runtime/document.ts"},"region":{"startLine":1650}}}],"partialFingerprints":{"codehealthFindingId/v1":"563441faaf9bba07aadf7956956cf8e7175d4b0f9d3b1de5730311b162876dde"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: undo/movable_list.rs: FileTooLong \u2014 587 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted). The bar is 500 significant lines; this is 87 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":"crates/loro-internal/src/undo/movable_list.rs"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"f72e70ba61121e57f946c7f9318b10d6f9d443a5d276d134763ce2fba3621dda"}},{"ruleId":"D3","level":"warning","message":{"text":"ClassTooLong: ContainerWrapper: ClassTooLong \u2014 468 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted), 44 methods, 2 blocks, lines 21-856. The bar is 400 significant lines; this is 68 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":"crates/loro-internal/src/state/container_store/container_wrapper.rs"},"region":{"startLine":21}}}],"partialFingerprints":{"codehealthFindingId/v1":"7449bf9f9f580300930e506e8246b65cc03420d360545eff60777bdcde510fcf"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: LoroMovableList: TooManyMethods \u2014 35 methods, declared across 2 files: src/lib.rs (33), src/container_tree.rs (2). The bar is 30 methods; this is 5 over it, 1.17\u00D7 the bar. That list is where to read them, not a suggestion to split the file: the members belong to the type wherever they are declared, so moving them between files leaves the count unchanged. 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":"crates/loro-wasm/src/lib.rs"},"region":{"startLine":4506}}}],"partialFingerprints":{"codehealthFindingId/v1":"302d87e634271f1db340b4d0ee6f3806961403f49cc18763eb85aa6633a6a227"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: LoroText: 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":"crates/loro/src/lib.rs"},"region":{"startLine":2842}}}],"partialFingerprints":{"codehealthFindingId/v1":"6613057e976a8c54fb23b73e2325ec00f1ea773c078bd59a7542ad002b0c65cb"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: src/block.rs: FileTooLong \u2014 582 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted). The bar is 500 significant lines; this is 82 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":"crates/kv-store/src/block.rs"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"b28be50aff5b0b81235dbf0b8070f3f0824d3a90d84c4da083d214dc97166656"}},{"ruleId":"D3","level":"warning","message":{"text":"ClassTooLong: Tracker: ClassTooLong \u2014 460 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted), 29 methods, 3 blocks, lines 32-749. The bar is 400 significant lines; this is 60 over it, 1.15\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":"crates/loro-internal/src/container/richtext/tracker.rs"},"region":{"startLine":32}}}],"partialFingerprints":{"codehealthFindingId/v1":"b7d7bf67520eaa34ba7641162b9f723cad50e110a069fe4d3fa41abd33c521ff"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: RichtextState.slice_delta: MethodTooLong \u2014 slice_delta runs 114 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted) in one body. The bar is 100 significant lines; this is 14 over it, 1.14\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":"crates/loro-internal/src/container/richtext/richtext_state.rs"},"region":{"startLine":2149}}}],"partialFingerprints":{"codehealthFindingId/v1":"d8ce580ee6d2d06cded8debe13c3d76599969a32dff04fdc4c7ea5e3b5f33fdb"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: Transaction: TooManyMethods \u2014 34 methods. The bar is 30 methods; this is 4 over it, 1.13\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":"crates/loro-internal/src/txn.rs"},"region":{"startLine":200}}}],"partialFingerprints":{"codehealthFindingId/v1":"ab2cde0acc7d70ac0912c2a13cea9776193e8531c4e69ad8c83790ff8748a161"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: LoroText: TooManyMethods \u2014 34 methods, declared across 2 files: src/lib.rs (33), src/container_tree.rs (1). The bar is 30 methods; this is 4 over it, 1.13\u00D7 the bar. That list is where to read them, not a suggestion to split the file: the members belong to the type wherever they are declared, so moving them between files leaves the count unchanged. 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":"crates/loro-wasm/src/lib.rs"},"region":{"startLine":2962}}}],"partialFingerprints":{"codehealthFindingId/v1":"929bfe58f22e58f44d3d354f4bd213ee2cfbe9ef334c29993ab19e709b5135a7"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: LoroDoc.apply_diff_with_movable_undo: MethodTooLong \u2014 apply_diff_with_movable_undo runs 112 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted) in one body. The bar is 100 significant lines; this is 12 over it, 1.12\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":"crates/loro-internal/src/loro.rs"},"region":{"startLine":2182}}}],"partialFingerprints":{"codehealthFindingId/v1":"5755c04a70e4752a3219ea2f5847069f8794e0d5ee23eb7bb7b595addc78afef"}},{"ruleId":"D3","level":"warning","message":{"text":"ClassTooLong: LoroDoc: ClassTooLong \u2014 444 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted), 117 methods, 4 blocks, lines 122-2161. The bar is 400 significant lines; this is 44 over it, 1.11\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":"crates/loro/src/lib.rs"},"region":{"startLine":122}}}],"partialFingerprints":{"codehealthFindingId/v1":"1c21b60f95e049051e8eba6bce02a000adb7aaa9edbd2397dfb60819d3c3a17f"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: RichtextState.drain_by_entity_index: MethodTooLong \u2014 drain_by_entity_index runs 111 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted) in one body. The bar is 100 significant lines; this is 11 over it, 1.11\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":"crates/loro-internal/src/container/richtext/richtext_state.rs"},"region":{"startLine":2317}}}],"partialFingerprints":{"codehealthFindingId/v1":"8e4f9e615d8b50b99b3fd92f9e09190f7bca2fc0c7caf384f008d639dc9d22cf"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: TreeDiff.try_from: MethodTooLong \u2014 try_from runs 111 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted) in one body. The bar is 100 significant lines; this is 11 over it, 1.11\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":"crates/loro-internal/src/value.rs"},"region":{"startLine":871}}}],"partialFingerprints":{"codehealthFindingId/v1":"d1169923ef8ec32f5d55c06ac3697a2c1754679dda161d16c69d1b463461513c"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: LoroDoc.#alignFullState: MethodTooLong \u2014 #alignFullState runs 111 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 11 over it, 1.11\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":"loro-js/src/runtime/document.ts"},"region":{"startLine":2127}}}],"partialFingerprints":{"codehealthFindingId/v1":"896277a18b62b22b5f873a616a52312c280df0c3cef272dd1443fbd1531460d5"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: jsonpath/jsonpath_impl.rs: FileTooLong \u2014 554 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted). 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":"crates/loro-internal/src/jsonpath/jsonpath_impl.rs"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"9299a5deda04ce7079ed20bedd550aee7f7123b75be36bfdc135e6aece557148"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: container_store/container_wrapper.rs: FileTooLong \u2014 553 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted), about 85% of them inside a single declaration: ContainerWrapper (2 blocks, 21-856). The bar is 500 significant lines; this is 53 over it, 1.11\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":"crates/loro-internal/src/state/container_store/container_wrapper.rs"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"e40f03b48045ed70f4028471bc39f9507a4ed96fa4dfee9a8b1c6b7f5c7c9dbb"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: TreeState: TooManyMethods \u2014 33 methods. The bar is 30 methods; this is 3 over it, 1.10\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":"crates/loro-internal/src/state/tree_state.rs"},"region":{"startLine":45}}}],"partialFingerprints":{"codehealthFindingId/v1":"360b2bfbb31070886aaa51e4d3eb15ddc7d4f9cfcd084f877c3d4e9749246751"}},{"ruleId":"D3","level":"warning","message":{"text":"FunctionTooLong: document.decodedOperationToJson: FunctionTooLong \u2014 decodedOperationToJson 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":"loro-js/src/runtime/document.ts"},"region":{"startLine":9917}}}],"partialFingerprints":{"codehealthFindingId/v1":"924823531ca817a6bfd1bc1819897c2d9945299ffeba409b983551fe66e078c3"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: ListDiffCalculator.calculate_diff: MethodTooLong \u2014 calculate_diff runs 109 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted) 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":"crates/loro-internal/src/diff_calc.rs"},"region":{"startLine":945}}}],"partialFingerprints":{"codehealthFindingId/v1":"21a7b6679b765c02bb6b9182188dd9e150f1ab24dc0ed41bb8fdcb5135b9d095"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: RichtextDiffCalculator.seed_tracker_from_shallow_root: MethodTooLong \u2014 seed_tracker_from_shallow_root runs 109 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted) 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":"crates/loro-internal/src/diff_calc.rs"},"region":{"startLine":1451}}}],"partialFingerprints":{"codehealthFindingId/v1":"ef15cb5e2a06972cf20377448283c23bd32e63d96eeefbb4da07dd72cb791f87"}},{"ruleId":"D3","level":"warning","message":{"text":"ClassTooLong: MovableListState: ClassTooLong \u2014 434 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted), 26 methods, 4 blocks, lines 32-1475. The bar is 400 significant lines; this is 34 over it, 1.09\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":"crates/loro-internal/src/state/movable_list_state.rs"},"region":{"startLine":32}}}],"partialFingerprints":{"codehealthFindingId/v1":"059c31d7b75e3d109efb1eb2cd002012ea16290f6ab2cf60b09ebcda9f24d07e"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: codec/serde-columnar.ts: 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":"loro-js/src/codec/serde-columnar.ts"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"8d0fa5ddbaaa31f8756fa3f79c2975b48b7e47703cd92ef3607fbe29bc11dcb7"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: state/list_state.rs: FileTooLong \u2014 540 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted), about 67% of them inside a single declaration: ListState (4 blocks, 26-731). The bar is 500 significant lines; this is 40 over it, 1.08\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":"crates/loro-internal/src/state/list_state.rs"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"30ad01f1cd3042098e72e04a816790f1236f76cc061737dd6bfd301abaee233a"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: BTree.handle_lack_single_layer: MethodTooLong \u2014 handle_lack_single_layer runs 108 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted) in one body. The bar is 100 significant lines; this is 8 over it, 1.08\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":"crates/generic-btree/src/lib.rs"},"region":{"startLine":2004}}}],"partialFingerprints":{"codehealthFindingId/v1":"a62813ed81aeeb4b8ef474d3e2cf85f9b19ba9311642d22a9a7fba6c8949ce38"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: change_store/block_encode.rs: FileTooLong \u2014 536 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted). The bar is 500 significant lines; this is 36 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":"crates/loro-internal/src/oplog/change_store/block_encode.rs"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"e4cd114f41d32c57afb90cc2435473f3f28d137ac61e1da2c9bfa92fe3662b95"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: CrdtRope.insert: MethodTooLong \u2014 insert runs 107 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted) in one body. The bar is 100 significant lines; this is 7 over it, 1.07\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":"crates/loro-internal/src/container/richtext/tracker/crdt_rope.rs"},"region":{"startLine":63}}}],"partialFingerprints":{"codehealthFindingId/v1":"7baf3dbae6c85b97affa666b6ccf29b4554e2bc6266df11be047502129ea0162"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: src/arena.rs: FileTooLong \u2014 534 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted), about 64% of them inside a single declaration: SharedArena (3 blocks, 103-945). The bar is 500 significant lines; this is 34 over it, 1.07\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":"crates/loro-internal/src/arena.rs"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"80566136adab6e1fc0b2976e5d3a74b7a1a85e9986c497205495d1171a1d7640"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: VersionVector: 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":"crates/loro-internal/src/version.rs"},"region":{"startLine":29}}}],"partialFingerprints":{"codehealthFindingId/v1":"fd7d416cdad92a5c9e020a9942e40bb6249707c43f29c2a2bfeacbea5e0d8a7e"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: MovableListState: 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":"loro-js/src/runtime/movable-list.ts"},"region":{"startLine":184}}}],"partialFingerprints":{"codehealthFindingId/v1":"dc3c7bbfa1340877e96fa2513d6b8b7e4003aba05f35fc59e1ee34932419a08e"}},{"ruleId":"D3","level":"warning","message":{"text":"FunctionTooLong: change-value.decodeChangeValueContent: FunctionTooLong \u2014 decodeChangeValueContent 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":"loro-js/src/codec/change-value.ts"},"region":{"startLine":86}}}],"partialFingerprints":{"codehealthFindingId/v1":"cb97e7ebc2db365a516c6e1d106ecd52d971deaa7f02fed8c3c4235d55c2bb60"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: LoroDoc.#prepareEvent: MethodTooLong \u2014 #prepareEvent 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":"loro-js/src/runtime/document.ts"},"region":{"startLine":4686}}}],"partialFingerprints":{"codehealthFindingId/v1":"442220b9d5e05ac6df73029b72e24f034d4d20e1e49398189d7a744fd891915c"}},{"ruleId":"D3","level":"warning","message":{"text":"FunctionTooLong: loro_internal::dag::_walk_to_meet: FunctionTooLong \u2014 loro_internal::dag::_walk_to_meet runs 104 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted) in one body. The bar is 100 significant lines; this is 4 over it, 1.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":"crates/loro-internal/src/dag.rs"},"region":{"startLine":442}}}],"partialFingerprints":{"codehealthFindingId/v1":"02e03cc105c520916442594bd49cbc4fbca02fc82a6cfc2d4c0a948d6dc697ef"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: MapHandler: 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":"crates/loro-internal/src/handler.rs"},"region":{"startLine":656}}}],"partialFingerprints":{"codehealthFindingId/v1":"460bde2bef1affad050c8831fa285eea899d5844751021ed93fa2848e6d8229d"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: UndoManager: 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":"crates/loro-internal/src/undo.rs"},"region":{"startLine":257}}}],"partialFingerprints":{"codehealthFindingId/v1":"0068f85357f9393ecf62b07a68676b8dc1d2cfe8799f77c93560e80fea217189"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: UndoManager: 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":"loro-js/src/runtime/undo.ts"},"region":{"startLine":75}}}],"partialFingerprints":{"codehealthFindingId/v1":"fe9a6c8660a2e15a18265b2eb9868f2b37996c691715f64ccd62cbefbec65a3e"}},{"ruleId":"D3","level":"warning","message":{"text":"ClassTooLong: InnerStore: ClassTooLong \u2014 402 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code \u2014 #[cfg(test)] modules and bare #[test] functions \u2014 not counted), 36 methods, 4 blocks, lines 29-709. The bar is 400 significant lines; this is 2 over it, 1.01\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":"crates/loro-internal/src/state/container_store/inner_store.rs"},"region":{"startLine":29}}}],"partialFingerprints":{"codehealthFindingId/v1":"7f7d5751f67f49165669cc87f9704f834c4b5581055b243a482e9859c8649499"}},{"ruleId":"D4","level":"warning","message":{"text":"Near-duplicate member pair (49 shared lines): crates/loro-internal/src/value.rs:253-352 | crates/loro-internal/src/value.rs:354-442 \u2014 These two members are variants of one another: 49 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":"crates/loro-internal/src/value.rs"},"region":{"startLine":253}}}],"partialFingerprints":{"codehealthFindingId/v1":"57b859686971015708da3f2539443ce0fea8357e0d114d5e31eab415a8602f8f"}},{"ruleId":"D4","level":"warning","message":{"text":"Near-duplicate member pair (34 shared lines): crates/loro-internal/src/jsonpath/parser.rs:306-346 | crates/loro-internal/src/jsonpath/parser.rs:432-473 \u2014 These two members are variants of one another: 34 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":"crates/loro-internal/src/jsonpath/parser.rs"},"region":{"startLine":306}}}],"partialFingerprints":{"codehealthFindingId/v1":"55a052f7ad34de8ac196ec140e94ab83b5f5095354ef23b484dad17c6f6cf15c"}},{"ruleId":"D4","level":"warning","message":{"text":"Members sharing a duplicated core (6 members, 50\u002B identical tokens): crates/loro-wasm/src/counter.rs:71-84 | crates/loro-wasm/src/lib.rs:3379-3393 | crates/loro-wasm/src/lib.rs:3940-3954 | crates/loro-wasm/src/lib.rs:4350-4363 | crates/loro-wasm/src/lib.rs:4793-4806 | crates/loro-wasm/src/lib.rs:5636-5649 \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":"crates/loro-wasm/src/counter.rs"},"region":{"startLine":71}}}],"partialFingerprints":{"codehealthFindingId/v1":"32807cc4d5644aa320719ace72599344650c1be6eb8e5992a774a898d55b0222"}},{"ruleId":"D4","level":"warning","message":{"text":"Members sharing a duplicated core (5 members, 50\u002B identical tokens): crates/loro-internal/src/handler.rs:520-527 | crates/loro-internal/src/handler.rs:749-756 | crates/loro-internal/src/handler.rs:880-887 | crates/loro-internal/src/handler.rs:990-997 | crates/loro-internal/src/handler/tree.rs:303-310 \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":"crates/loro-internal/src/handler.rs"},"region":{"startLine":520}}}],"partialFingerprints":{"codehealthFindingId/v1":"43302da7833425a50cc4055e4d74f0a42aa38fe5dfde4f45e81f8a17ab83eea6"}},{"ruleId":"D4","level":"warning","message":{"text":"Members sharing a duplicated core (4 members, 50\u002B identical tokens): crates/fuzz/src/crdt_fuzzer.rs:962-1082 | crates/fuzz/src/crdt_fuzzer.rs:1089-1154 | crates/fuzz/src/mem_kv_fuzzer.rs:280-344 | crates/loro-internal/src/fuzz.rs:8-89 \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":"crates/fuzz/src/crdt_fuzzer.rs"},"region":{"startLine":962}}}],"partialFingerprints":{"codehealthFindingId/v1":"02f9799f8c0db891ab3b44cb9a6f64123b06a07ae5d6fad5e710782c57bc05c8"}},{"ruleId":"D4","level":"warning","message":{"text":"Members sharing a duplicated core (4 members, 50\u002B identical tokens): crates/generic-btree/src/generic_impl/gap_buffer.rs:191-206 | crates/generic-btree/src/lib.rs:2998-3022 | crates/generic-btree/src/rle.rs:11-25 | crates/generic-btree/src/rle.rs:52-91 \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":"crates/generic-btree/src/generic_impl/gap_buffer.rs"},"region":{"startLine":191}}}],"partialFingerprints":{"codehealthFindingId/v1":"8c26898b3f3118ccad3cc4b1a763fc08a32f910004c4edc56b1410b8cfa14f57"}},{"ruleId":"D4","level":"warning","message":{"text":"Members sharing a duplicated core (4 members, 50\u002B identical tokens): crates/loro-internal/src/encoding/shallow_snapshot.rs:72-112 | crates/loro-internal/src/oplog/change_store.rs:385-410 | crates/loro-internal/src/oplog/change_store.rs:412-469 | crates/loro-internal/src/oplog/change_store.rs:1228-1256 \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":"crates/loro-internal/src/encoding/shallow_snapshot.rs"},"region":{"startLine":72}}}],"partialFingerprints":{"codehealthFindingId/v1":"262fcdc8e73cb6d4b97c95419cf1d196112c27a91a3938f9959444fc72abfbaa"}},{"ruleId":"D4","level":"warning","message":{"text":"Members sharing a duplicated core (4 members, 50\u002B identical tokens): crates/loro-internal/src/state/richtext_state.rs:142-160 | crates/loro-internal/src/state/richtext_state.rs:199-225 | crates/loro-internal/src/state/richtext_state.rs:227-276 | crates/loro-internal/src/state/richtext_state.rs:1523-1599 \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":"crates/loro-internal/src/state/richtext_state.rs"},"region":{"startLine":142}}}],"partialFingerprints":{"codehealthFindingId/v1":"ae72a59becb46bf8f6e7d12b9e0c15808cbd2d41ec49fe00278dbd3b47994714"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (79 corresponding lines): crates/loro-internal/src/container/richtext/tracker.rs:393-500 | crates/loro-internal/src/container/richtext/tracker.rs:507-585 \u2014 These two members are one piece of code written twice and then edited apart: 79 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":"crates/loro-internal/src/container/richtext/tracker.rs"},"region":{"startLine":393}}}],"partialFingerprints":{"codehealthFindingId/v1":"befef7e92afa5f258dc5fd62dd52675b323d8db848ee1f7bccb89b59cd15511f"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (59 corresponding lines): crates/loro-internal/src/state/tree_state.rs:170-228 | crates/loro-internal/src/state/tree_state.rs:1716-1782 \u2014 These two members are one piece of code written twice and then edited apart: 59 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":"crates/loro-internal/src/state/tree_state.rs"},"region":{"startLine":170}}}],"partialFingerprints":{"codehealthFindingId/v1":"b692383a73345f073a295541a7f95a1ca5f9eccb7e4b01c1ef2ea424c1efd810"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (50 corresponding lines): crates/loro/src/event.rs:138-187 | crates/loro/src/event.rs:191-240 \u2014 These two members are one piece of code written twice and then edited apart: 50 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":"crates/loro/src/event.rs"},"region":{"startLine":138}}}],"partialFingerprints":{"codehealthFindingId/v1":"8bf0bbca8e5d698782afbaddc5a70703259afdcfdefcfbc8eb27e69c84e1c06a"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (39 corresponding lines): crates/kv-store/src/mem_store.rs:442-483 | crates/kv-store/src/mem_store.rs:491-529 \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":"crates/kv-store/src/mem_store.rs"},"region":{"startLine":442}}}],"partialFingerprints":{"codehealthFindingId/v1":"c05643bc085b36f98db80bd2aa6207b7e7970a0e7791098084a6fe300c3d303d"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 35\u002B corresponding lines): crates/loro-internal/src/handler.rs:713-747 | crates/loro-internal/src/handler.rs:844-878 | crates/loro-internal/src/handler.rs:954-988 \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":"crates/loro-internal/src/handler.rs"},"region":{"startLine":713}}}],"partialFingerprints":{"codehealthFindingId/v1":"685f7ef2f77a8ff78c3b12f838741e53fa88a2047f5ddbcf9235a9f9e8d92db1"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (41 corresponding lines): crates/generic-btree/src/lib.rs:2472-2526 | crates/generic-btree/src/lib.rs:2528-2568 \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":"crates/generic-btree/src/lib.rs"},"region":{"startLine":2472}}}],"partialFingerprints":{"codehealthFindingId/v1":"de8c9a29af7fa11fa2bfdfdfd9a14d2da57feab705ba0aca4d516a799536c4ab"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (31 corresponding lines): crates/generic-btree/src/lib.rs:2344-2374 | crates/generic-btree/src/lib.rs:2376-2407 \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":"crates/generic-btree/src/lib.rs"},"region":{"startLine":2344}}}],"partialFingerprints":{"codehealthFindingId/v1":"f9f507b170aa63c9fe5efe9ffdf7d77e43c93e2f0816695fcea78b8ee05f5362"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (26 corresponding lines): crates/loro-common/src/value.rs:1136-1161 | crates/loro-internal/src/awareness.rs:498-527 \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":"crates/loro-common/src/value.rs"},"region":{"startLine":1136}}}],"partialFingerprints":{"codehealthFindingId/v1":"076ff7e7b2cd0791af379c06faad1190ce66f7c887dfe07bec72a50be13baf4a"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (34 corresponding lines): crates/loro-internal/src/value.rs:79-112 | crates/loro-internal/src/value.rs:159-192 \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":"crates/loro-internal/src/value.rs"},"region":{"startLine":79}}}],"partialFingerprints":{"codehealthFindingId/v1":"b5df73f1238cd9317680d128a6570c4c5b7fd7e3714213eb509a0200ba0b1f7d"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (29 corresponding lines): crates/loro-internal/src/state/container_store/container_wrapper.rs:336-364 | crates/loro-internal/src/state/container_store/container_wrapper.rs:370-402 \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":"crates/loro-internal/src/state/container_store/container_wrapper.rs"},"region":{"startLine":336}}}],"partialFingerprints":{"codehealthFindingId/v1":"6720b037d6bcc162038962c242e997695de55c8a720bdc7920758f887ee98661"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 41\u002B corresponding lines): crates/loro-internal/src/handler.rs:2845-2897 | crates/loro-internal/src/handler.rs:3581-3621 | crates/loro-internal/src/handler.rs:4317-4357 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 41 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":"crates/loro-internal/src/handler.rs"},"region":{"startLine":2845}}}],"partialFingerprints":{"codehealthFindingId/v1":"b83f96bbe932dd7761d2c3ebb0720727a152da8a0554acecf54c5212136d0ce2"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (37 corresponding lines): crates/kv-store/src/iter.rs:38-75 | crates/kv-store/src/iter.rs:79-115 \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":"crates/kv-store/src/iter.rs"},"region":{"startLine":38}}}],"partialFingerprints":{"codehealthFindingId/v1":"2f11afcdd119dfac89d81e77e2a19f48006fdab00ffb1db8c9e21a617f816aed"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (31 corresponding lines): crates/loro-internal/src/handler.rs:383-418 | crates/loro-internal/src/handler.rs:1269-1299 \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":"crates/loro-internal/src/handler.rs"},"region":{"startLine":383}}}],"partialFingerprints":{"codehealthFindingId/v1":"6ae9067efe9c352d7adfcef6f24cf4e9462d97292fe2f2a2f907a2dbd1d9b2c1"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (26 corresponding lines): crates/delta/src/delta_rope/rle_tree.rs:168-193 | crates/generic-btree/src/generic_impl/len_finder.rs:56-81 \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":"crates/delta/src/delta_rope/rle_tree.rs"},"region":{"startLine":168}}}],"partialFingerprints":{"codehealthFindingId/v1":"545bcd3e03f59a5f17e50eaf4935eec06bba2b2cd3e175cda93187a04896a18e"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (33 corresponding lines): crates/kv-store/src/block.rs:683-715 | crates/kv-store/src/block.rs:717-749 \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":"crates/kv-store/src/block.rs"},"region":{"startLine":683}}}],"partialFingerprints":{"codehealthFindingId/v1":"4a99606e63c50cfdf480dc359e29058f126f7426120989b87fee9d450ca9aa87"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (19 corresponding lines): crates/loro-internal/src/event.rs:456-474 | crates/loro-internal/src/event.rs:505-528 \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":"crates/loro-internal/src/event.rs"},"region":{"startLine":456}}}],"partialFingerprints":{"codehealthFindingId/v1":"fb585153f099ac8a83e25b63ffbc121af26962f61b17a0c25fca9e20e13a446c"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (25 corresponding lines): crates/loro-wasm/src/lib.rs:2253-2277 | crates/loro-wasm/src/lib.rs:2285-2313 \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":"crates/loro-wasm/src/lib.rs"},"region":{"startLine":2253}}}],"partialFingerprints":{"codehealthFindingId/v1":"dc3846884fa258fd063b195f49b0f64a843d833172052ca476e6cb3354b40eb9"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (25 corresponding lines): crates/loro-wasm/src/lib.rs:3048-3072 | crates/loro-wasm/src/lib.rs:3078-3102 \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":"crates/loro-wasm/src/lib.rs"},"region":{"startLine":3048}}}],"partialFingerprints":{"codehealthFindingId/v1":"77a80f6565bfc7755a80306cbee685fe039db89924ac704e81451710240f61f7"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (23 corresponding lines): crates/kv-store/src/block.rs:751-773 | crates/kv-store/src/block.rs:775-797 \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":"crates/kv-store/src/block.rs"},"region":{"startLine":751}}}],"partialFingerprints":{"codehealthFindingId/v1":"ed18bbce65cb36e6a2fa075fdacbd3cc25cd42f5e0b99aaddd0f7ff5666fbd42"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 26\u002B corresponding lines): crates/loro-internal/src/handler.rs:3372-3397 | crates/loro-internal/src/handler.rs:3745-3773 | crates/loro-internal/src/handler.rs:3942-3973 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 26 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":"crates/loro-internal/src/handler.rs"},"region":{"startLine":3372}}}],"partialFingerprints":{"codehealthFindingId/v1":"15981a261bf9442c286e0af6eecab24a19b9e1a9bb883b75cb49ad0b1c306639"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (30 corresponding lines): crates/rle/src/rle_vec.rs:289-318 | crates/rle/src/rle_vec.rs:380-413 \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":"crates/rle/src/rle_vec.rs"},"region":{"startLine":289}}}],"partialFingerprints":{"codehealthFindingId/v1":"0606fc73aebfbf5e869584acdbc7e2a8b104afae089152c2e3584559c4578366"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (19 corresponding lines): crates/loro-internal/src/state/container_store/inner_store.rs:357-376 | crates/loro-internal/src/state/container_store/inner_store.rs:384-402 \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":"crates/loro-internal/src/state/container_store/inner_store.rs"},"region":{"startLine":357}}}],"partialFingerprints":{"codehealthFindingId/v1":"5d225d8ef71f358340ee0faa4cbc3313166a60008d1634f133a35a4a378475f0"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (16 corresponding lines): crates/loro-internal/src/handler/text_update.rs:145-161 | crates/loro-internal/src/handler/text_update.rs:163-178 \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":"crates/loro-internal/src/handler/text_update.rs"},"region":{"startLine":145}}}],"partialFingerprints":{"codehealthFindingId/v1":"84b06c03363ae3c6ac03caf3e6448a2e56fa20a3e84a3c0be38d79fd90bcca6a"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (26 corresponding lines): crates/loro-internal/src/encoding/json_schema.rs:727-752 | crates/loro-internal/src/handler.rs:43-82 \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":"crates/loro-internal/src/encoding/json_schema.rs"},"region":{"startLine":727}}}],"partialFingerprints":{"codehealthFindingId/v1":"51b4f94d26fd3cd49cc6cad90d60e9188f1538fdd4bd8af699305b90b39fb062"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (24 corresponding lines): crates/loro-internal/src/state/map_state.rs:94-118 | crates/loro-internal/src/state/map_state.rs:177-200 \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":"crates/loro-internal/src/state/map_state.rs"},"region":{"startLine":94}}}],"partialFingerprints":{"codehealthFindingId/v1":"30d2e2388cec87690c4628b4ec79583135f167d7a28145715d294100cbc98e22"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (30 corresponding lines): crates/loro-internal/src/container/richtext/style_range_map.rs:191-220 | crates/loro-internal/src/container/richtext/style_range_map.rs:233-262 \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":"crates/loro-internal/src/container/richtext/style_range_map.rs"},"region":{"startLine":191}}}],"partialFingerprints":{"codehealthFindingId/v1":"42c865093822e6e7a6ce99ae980cc37557b08017cf1c616f8e80d17241530895"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (12 corresponding lines): crates/loro/src/lib.rs:4245-4256 | crates/loro/src/lib.rs:4354-4365 \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":"crates/loro/src/lib.rs"},"region":{"startLine":4245}}}],"partialFingerprints":{"codehealthFindingId/v1":"97c4a4b606e739584c248cce7f830d8df4688bebbc73c5a93b9ebe41a14fc94e"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (21 corresponding lines): crates/loro-internal/src/handler.rs:3252-3273 | crates/loro-internal/src/handler.rs:3975-3995 \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":"crates/loro-internal/src/handler.rs"},"region":{"startLine":3252}}}],"partialFingerprints":{"codehealthFindingId/v1":"66f96be122788363817be5c918b996267aeff60a62282bfac564b7880b32b6b4"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (20 corresponding lines): crates/loro-internal/src/handler.rs:3342-3361 | crates/loro-internal/src/handler.rs:3912-3931 \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":"crates/loro-internal/src/handler.rs"},"region":{"startLine":3342}}}],"partialFingerprints":{"codehealthFindingId/v1":"5338146e13600430dcd054b97bf915fc57170af358089e405098665946da427c"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (30 corresponding lines): crates/loro-internal/src/state/list_state.rs:300-341 | crates/loro-internal/src/state/list_state.rs:343-372 \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":"crates/loro-internal/src/state/list_state.rs"},"region":{"startLine":300}}}],"partialFingerprints":{"codehealthFindingId/v1":"f8a382e675cd90d14504c7fddc0b953a4ed93d3f61dff184c7731cf6a57aebf4"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (27 corresponding lines): crates/loro-internal/src/handler.rs:4659-4691 | crates/loro-internal/src/handler.rs:4699-4725 \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":"crates/loro-internal/src/handler.rs"},"region":{"startLine":4659}}}],"partialFingerprints":{"codehealthFindingId/v1":"12d654659184864d7f5c0bcb679b623d83ebfa4041a59fdf764da0561da5ca4f"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (25 corresponding lines): crates/generic-btree/src/lib.rs:1630-1654 | crates/generic-btree/src/lib.rs:1656-1682 \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":"crates/generic-btree/src/lib.rs"},"region":{"startLine":1630}}}],"partialFingerprints":{"codehealthFindingId/v1":"78f25eab254e6501e5991fe4dcfea4dc15255f2ccbc9eb77beb8414c4ecebb35"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (19 corresponding lines): crates/generic-btree/src/generic_impl/ord.rs:273-291 | crates/loro-internal/src/state/tree_state.rs:575-594 \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":"crates/generic-btree/src/generic_impl/ord.rs"},"region":{"startLine":273}}}],"partialFingerprints":{"codehealthFindingId/v1":"f339e04eaab96d45a932834695ccb2f7840b001e2d0267588b198df988703349"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (29 corresponding lines): crates/kv-store/src/block.rs:621-649 | crates/kv-store/src/block.rs:652-681 \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":"crates/kv-store/src/block.rs"},"region":{"startLine":621}}}],"partialFingerprints":{"codehealthFindingId/v1":"661f00135d7b362f6a16106f015bb3232a92cabf7a71800a0a4eb6150a3563da"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (18 corresponding lines): crates/loro-internal/src/handler/tree.rs:401-418 | crates/loro-internal/src/handler/tree.rs:420-444 \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":"crates/loro-internal/src/handler/tree.rs"},"region":{"startLine":401}}}],"partialFingerprints":{"codehealthFindingId/v1":"e01cbf222c928b211be72ad6b37ac0d4b8141a8bf327360ba71fadafb8299bb8"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (22 corresponding lines): crates/loro-internal/src/handler.rs:3558-3579 | crates/loro-internal/src/handler.rs:4274-4296 \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":"crates/loro-internal/src/handler.rs"},"region":{"startLine":3558}}}],"partialFingerprints":{"codehealthFindingId/v1":"0a605a535b2e773b7c535166ccbe1674c059452b40c5d76a8754b23ef11cb32f"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (22 corresponding lines): crates/loro-internal/src/container/richtext/tracker/crdt_rope.rs:605-626 | crates/loro-internal/src/container/richtext/tracker/crdt_rope.rs:663-684 \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":"crates/loro-internal/src/container/richtext/tracker/crdt_rope.rs"},"region":{"startLine":605}}}],"partialFingerprints":{"codehealthFindingId/v1":"1adcbca2efee074f45b15881e4b1a0d8e08b2d46a494da4f1742810f6e38a907"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (23 corresponding lines): crates/bench-utils/src/lib.rs:208-230 | crates/bench-utils/src/lib.rs:236-267 \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":"crates/bench-utils/src/lib.rs"},"region":{"startLine":208}}}],"partialFingerprints":{"codehealthFindingId/v1":"6663a53fe6eef7b2efd97a4da9fe77f84f9a22ddcbc0133326f52e4337530842"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (34 corresponding lines): crates/loro-internal/src/delta/seq.rs:165-199 | crates/loro-internal/src/delta/seq.rs:201-234 \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":"crates/loro-internal/src/delta/seq.rs"},"region":{"startLine":165}}}],"partialFingerprints":{"codehealthFindingId/v1":"a9d941a51f6d8b3b20c5aee104f107d58ab6644c8f124bb3a491903e796752a5"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (21 corresponding lines): crates/loro-internal/src/utils/string_slice.rs:160-184 | crates/loro-internal/src/utils/string_slice.rs:294-314 \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":"crates/loro-internal/src/utils/string_slice.rs"},"region":{"startLine":160}}}],"partialFingerprints":{"codehealthFindingId/v1":"826cf4ffd9a843d4e69f4ee5e596d9831606eeb22bbaeb8cfe40ab14e0d89dbc"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (17 corresponding lines): crates/loro-internal/src/undo.rs:46-62 | crates/loro-internal/src/undo.rs:67-88 \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":"crates/loro-internal/src/undo.rs"},"region":{"startLine":46}}}],"partialFingerprints":{"codehealthFindingId/v1":"11cc99bc1b8586475ac9889167812139de1c6fb53f47151d3db593348d58135e"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (19 corresponding lines): crates/loro-internal/src/jsonpath/parser.rs:214-232 | crates/loro-internal/src/jsonpath/parser.rs:238-256 \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":"crates/loro-internal/src/jsonpath/parser.rs"},"region":{"startLine":214}}}],"partialFingerprints":{"codehealthFindingId/v1":"828c4c8f6cb3edc435599ebd5e17fa0865c0fcd79f2edc548ffda7dc86cd5fae"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (18 corresponding lines): crates/loro-internal/src/version.rs:735-756 | crates/loro-internal/src/version.rs:889-906 \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":"crates/loro-internal/src/version.rs"},"region":{"startLine":735}}}],"partialFingerprints":{"codehealthFindingId/v1":"d1e2a07d27fd86f552daecbac693620e221b11bb67e4a5f2e6c14520984a14a9"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (14 corresponding lines): crates/loro-internal/src/op.rs:256-269 | crates/loro-internal/src/op.rs:271-286 \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":"crates/loro-internal/src/op.rs"},"region":{"startLine":256}}}],"partialFingerprints":{"codehealthFindingId/v1":"cd40d1fc8662d4bac08ab41d1a59a6c53069edc5a6b03146f5864a85ddfeb6a1"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (16 corresponding lines): crates/loro-internal/src/state/map_state.rs:120-138 | crates/loro-internal/src/state/map_state.rs:202-217 \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":"crates/loro-internal/src/state/map_state.rs"},"region":{"startLine":120}}}],"partialFingerprints":{"codehealthFindingId/v1":"3fe96554a06caa2c20eac65d13bac84609a5ac37bbb887ebcfef371042f87a03"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (12 corresponding lines): crates/loro-internal/src/handler.rs:1138-1149 | crates/loro-internal/src/handler.rs:1355-1366 \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":"crates/loro-internal/src/handler.rs"},"region":{"startLine":1138}}}],"partialFingerprints":{"codehealthFindingId/v1":"eb256bdbc4831da34557344a7a08ed50ebf5eeb7d07151851603488f1a485ce0"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (15 corresponding lines): crates/loro-internal/src/loro.rs:584-598 | crates/loro-internal/src/loro.rs:604-619 \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":"crates/loro-internal/src/loro.rs"},"region":{"startLine":584}}}],"partialFingerprints":{"codehealthFindingId/v1":"f52dc7d73ba6cff458f34e56c350a468066274ec888b67c1ba04a2e427e8716b"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (19 corresponding lines): crates/loro-internal/src/container/list/list_op.rs:475-493 | crates/loro-internal/src/container/list/list_op.rs:498-519 \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":"crates/loro-internal/src/container/list/list_op.rs"},"region":{"startLine":475}}}],"partialFingerprints":{"codehealthFindingId/v1":"adf283973e8f06835a35b86cdc2bab1bef7e49675cb20b832f633a1494c7caf3"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (21 corresponding lines): crates/loro-internal/src/version/frontiers.rs:148-168 | crates/loro-internal/src/version/frontiers.rs:170-191 \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":"crates/loro-internal/src/version/frontiers.rs"},"region":{"startLine":148}}}],"partialFingerprints":{"codehealthFindingId/v1":"38867951b4ce83e08404638c7fe29fbae45e3c79c51f782defd53edfc03a01db"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (4 members, 12\u002B corresponding lines): crates/loro/src/lib.rs:4215-4226 | crates/loro/src/lib.rs:4258-4269 | crates/loro/src/lib.rs:4291-4302 | crates/loro/src/lib.rs:4303-4314 \u2014 These 4 members are one piece of code written 4 times and then edited apart: every two of them correspond over at least 12 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\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":"crates/loro/src/lib.rs"},"region":{"startLine":4215}}}],"partialFingerprints":{"codehealthFindingId/v1":"2d050b7e0ff54a77075f78739c358150c53ea77123c0e594d27b11f8f26a2000"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (9 corresponding lines): crates/dev-utils/src/lib.rs:78-86 | crates/dev-utils/src/lib.rs: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":"crates/dev-utils/src/lib.rs"},"region":{"startLine":78}}}],"partialFingerprints":{"codehealthFindingId/v1":"064366ac76f347fcb05fe1177acf757bc4211d974a43acce5b9b71ed9f210ffe"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (16 corresponding lines): crates/loro-internal/src/handler/tree.rs:663-679 | crates/loro-internal/src/handler/tree.rs:681-696 \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":"crates/loro-internal/src/handler/tree.rs"},"region":{"startLine":663}}}],"partialFingerprints":{"codehealthFindingId/v1":"0f7c9928714974e05349f94c85e2968ad0ecb386655646b70901316015998f8c"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 13\u002B corresponding lines): crates/loro-internal/src/state/container_store/container_wrapper.rs:468-484 | crates/loro-internal/src/state/container_store/container_wrapper.rs:486-498 | crates/loro-internal/src/state/container_store/container_wrapper.rs:504-521 \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":"crates/loro-internal/src/state/container_store/container_wrapper.rs"},"region":{"startLine":468}}}],"partialFingerprints":{"codehealthFindingId/v1":"60636ca42664d6e31614214978c3816b6f033d61f30fb2d85baec472d0fc5aad"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (10 corresponding lines): crates/loro-common/src/span.rs:214-223 | crates/loro-internal/src/container/list/list_op.rs:420-429 \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":"crates/loro-common/src/span.rs"},"region":{"startLine":214}}}],"partialFingerprints":{"codehealthFindingId/v1":"ba7c062d33c3e1b1b9b067d5322c6fe5839b159bc6d9fc4c7b5e775298533d76"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (22 corresponding lines): crates/loro-internal/src/container/richtext/richtext_state.rs:1030-1051 | crates/loro-internal/src/container/richtext/richtext_state.rs:1053-1080 \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":"crates/loro-internal/src/container/richtext/richtext_state.rs"},"region":{"startLine":1030}}}],"partialFingerprints":{"codehealthFindingId/v1":"0e3eaad67e1e336e22721b4f181b691b2e69b68636ed8e4a9d3f23c784e72ca4"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (23 corresponding lines): crates/loro-internal/src/diff_calc/tree.rs:497-519 | crates/loro-internal/src/state/tree_state.rs:739-761 \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":"crates/loro-internal/src/diff_calc/tree.rs"},"region":{"startLine":497}}}],"partialFingerprints":{"codehealthFindingId/v1":"5ba3d3982d3bd0ad9158e8f27aaa12ba721e642b478c9f0905d0e970d166961f"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (9 corresponding lines): crates/loro-internal/src/container/richtext/tracker/id_to_cursor.rs:987-995 | crates/loro-internal/src/container/richtext/tracker/id_to_cursor.rs:997-1009 \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":"crates/loro-internal/src/container/richtext/tracker/id_to_cursor.rs"},"region":{"startLine":987}}}],"partialFingerprints":{"codehealthFindingId/v1":"dd6f7a7f065925f5d217e19d410d0db720af25433fc522050b4c192dab0d87d7"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 16\u002B corresponding lines): crates/loro-internal/src/utils/query_by_len.rs:73-91 | crates/loro-internal/src/utils/query_by_len.rs:117-132 | crates/loro-internal/src/utils/query_by_len.rs:159-177 \u2014 These 3 members are one piece of code written 3 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 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/utils/query_by_len.rs"},"region":{"startLine":73}}}],"partialFingerprints":{"codehealthFindingId/v1":"87e976138e05b563b9a5df6c07f88333fe9bea3d05cc4344cc767ac59e6aee55"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (13 corresponding lines): crates/loro-internal/src/handler.rs:672-684 | crates/loro-internal/src/handler.rs:686-698 \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":"crates/loro-internal/src/handler.rs"},"region":{"startLine":672}}}],"partialFingerprints":{"codehealthFindingId/v1":"0eb2ea430feed5b5c87323f33ff5d4c8f0e92052eb2b25b7f0dad8a4522375ef"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (13 corresponding lines): crates/loro-internal/src/state/container_store/container_wrapper.rs:84-98 | crates/loro-internal/src/state/container_store/container_wrapper.rs:100-112 \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":"crates/loro-internal/src/state/container_store/container_wrapper.rs"},"region":{"startLine":84}}}],"partialFingerprints":{"codehealthFindingId/v1":"f4a366724acf2162d1129c6260aae75b04a74cd52d8e834d532171c6ba806071"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (14 corresponding lines): crates/loro-internal/src/state/container_store/inner_store.rs:297-310 | crates/loro-internal/src/state/container_store/inner_store.rs:332-345 \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":"crates/loro-internal/src/state/container_store/inner_store.rs"},"region":{"startLine":297}}}],"partialFingerprints":{"codehealthFindingId/v1":"5503295dea1e2bde33d2d915dc5ad61c56b40bd28b40af1feb027704e21e907f"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (5 members, 12\u002B corresponding lines): crates/loro-internal/src/state/container_store/container_wrapper.rs:302-313 | crates/loro-internal/src/state/container_store/container_wrapper.rs:315-330 | crates/loro-internal/src/state/container_store/container_wrapper.rs:408-423 | crates/loro-internal/src/state/container_store/container_wrapper.rs:429-442 | crates/loro-internal/src/state/container_store/container_wrapper.rs:448-461 \u2014 These 5 members are one piece of code written 5 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 5 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/state/container_store/container_wrapper.rs"},"region":{"startLine":302}}}],"partialFingerprints":{"codehealthFindingId/v1":"ed56c7d2c9119f209519c59e0e5067a4dbdc2ff2ae6c0dba51a4486423bc9390"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (24 corresponding lines): crates/delta/src/utf16.rs:20-43 | crates/delta/src/utf16.rs:46-69 \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":"crates/delta/src/utf16.rs"},"region":{"startLine":20}}}],"partialFingerprints":{"codehealthFindingId/v1":"67893106dd976474d13aa908f8fd45e2a1e19e24f54cb8e002325313cbc27eb2"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 18\u002B corresponding lines): crates/loro-internal/src/awareness.rs:71-90 | crates/loro-internal/src/awareness.rs:640-658 | crates/loro-internal/src/awareness.rs:660-677 \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":"crates/loro-internal/src/awareness.rs"},"region":{"startLine":71}}}],"partialFingerprints":{"codehealthFindingId/v1":"71910cddd070cd145034ff37c69951267935b1518429073bc7c2fb74dd0c173e"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (14 corresponding lines): crates/loro-internal/src/handler.rs:4766-4780 | crates/loro-internal/src/handler.rs:4783-4796 \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":"crates/loro-internal/src/handler.rs"},"region":{"startLine":4766}}}],"partialFingerprints":{"codehealthFindingId/v1":"ab50557867b057291622972f517fd8a4854363e7f85d17f42b65530ca4d1f392"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (13 corresponding lines): crates/loro-internal/src/state/list_state.rs:486-498 | crates/loro-internal/src/state/list_state.rs:500-512 \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":"crates/loro-internal/src/state/list_state.rs"},"region":{"startLine":486}}}],"partialFingerprints":{"codehealthFindingId/v1":"7203bab4f0bcbef53b869bfdbc272e5af4ddfda995b6719737616a81f6268e57"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (7 corresponding lines): crates/loro-internal/src/version.rs:306-312 | crates/loro-internal/src/version.rs:318-326 \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":"crates/loro-internal/src/version.rs"},"region":{"startLine":306}}}],"partialFingerprints":{"codehealthFindingId/v1":"d764c2983829c93a72084a58dafb68cc609c8dfe4d70e6daa5a7e76cf8822708"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 15\u002B corresponding lines): crates/generic-btree/src/lib.rs:1684-1698 | crates/generic-btree/src/lib.rs:1700-1714 | crates/generic-btree/src/lib.rs:2715-2729 \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":"crates/generic-btree/src/lib.rs"},"region":{"startLine":1684}}}],"partialFingerprints":{"codehealthFindingId/v1":"fa02b81a1e4cb8334c5760a014b1abf4ee6d29fcc5d085ccedd7220aadc6224e"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (20 corresponding lines): crates/loro-internal/src/handler/tree.rs:776-795 | crates/loro-internal/src/handler/tree.rs:807-829 \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":"crates/loro-internal/src/handler/tree.rs"},"region":{"startLine":776}}}],"partialFingerprints":{"codehealthFindingId/v1":"336f64873caebe6abdacebc3ba00c118768d5b46d422824bce39889b551563f5"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (11 corresponding lines): crates/loro-wasm/src/container_tree.rs:266-276 | crates/loro-wasm/src/container_tree.rs:286-296 \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":"crates/loro-wasm/src/container_tree.rs"},"region":{"startLine":266}}}],"partialFingerprints":{"codehealthFindingId/v1":"b4042a7828d4ed6d4bed121d222f2479972629da6d2b611746c9d4f13ea26f39"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 16\u002B corresponding lines): crates/kv-store/src/block.rs:483-498 | crates/kv-store/src/block.rs:500-515 | crates/kv-store/src/block.rs:517-532 \u2014 These 3 members are one piece of code written 3 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 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/kv-store/src/block.rs"},"region":{"startLine":483}}}],"partialFingerprints":{"codehealthFindingId/v1":"e779a3501d1f4168ea3468b5ffdb0ed8dc8d98c26d98e6a457400f9e32fd9b77"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (17 corresponding lines): crates/loro-internal/src/delta/seq.rs:260-277 | crates/loro-internal/src/delta/seq.rs:279-295 \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":"crates/loro-internal/src/delta/seq.rs"},"region":{"startLine":260}}}],"partialFingerprints":{"codehealthFindingId/v1":"7c056705131d9de49785855574a3766a21a090c11d79459a71db7e298e9f10f8"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 12\u002B corresponding lines): crates/loro-wasm/src/awareness.rs:217-228 | crates/loro-wasm/src/lib.rs:2160-2171 | crates/loro-wasm/src/lib.rs:2661-2674 \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":"crates/loro-wasm/src/awareness.rs"},"region":{"startLine":217}}}],"partialFingerprints":{"codehealthFindingId/v1":"50ed79078583ad22de423e39637ce81cd055804e86f3357a6bd38ff208b58eab"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (14 corresponding lines): crates/loro-internal/src/handler.rs:4410-4424 | crates/loro-internal/src/handler.rs:4454-4467 \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":"crates/loro-internal/src/handler.rs"},"region":{"startLine":4410}}}],"partialFingerprints":{"codehealthFindingId/v1":"4d03184a1f623b1f6683c260dfd6c0f8a0f202808254a5cc320dced28436d68b"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 12\u002B corresponding lines): crates/loro-internal/src/handler/tree.rs:902-913 | crates/loro-internal/src/handler/tree.rs:915-926 | crates/loro-internal/src/handler/tree.rs:955-966 \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":"crates/loro-internal/src/handler/tree.rs"},"region":{"startLine":902}}}],"partialFingerprints":{"codehealthFindingId/v1":"714e563ba40cdb9fb45ea19be1d0937c7e083c058996b30ad390eaad10c14fba"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 12\u002B corresponding lines): crates/loro-internal/src/handler.rs:3303-3314 | crates/loro-internal/src/handler.rs:4513-4526 | crates/loro-internal/src/handler.rs:4588-4601 \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":"crates/loro-internal/src/handler.rs"},"region":{"startLine":3303}}}],"partialFingerprints":{"codehealthFindingId/v1":"094e6d8f425746a8f72cd74a6e89d8b88909e38c23ba9509e0b41829a02c003b"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (9 corresponding lines): crates/loro-internal/src/handler.rs:3321-3329 | crates/loro-internal/src/handler.rs:3891-3899 \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":"crates/loro-internal/src/handler.rs"},"region":{"startLine":3321}}}],"partialFingerprints":{"codehealthFindingId/v1":"b6c198be61fec0c3009fa13b3803c2f060fa18b8271de98dcfcad068aeec6e8c"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (10 corresponding lines): crates/loro-internal/src/jsonpath/parser.rs:267-277 | crates/loro-internal/src/jsonpath/parser.rs:374-383 \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":"crates/loro-internal/src/jsonpath/parser.rs"},"region":{"startLine":267}}}],"partialFingerprints":{"codehealthFindingId/v1":"a92ebdde5374c25aa27062a141df21133ac116600a50cdfb771c600f36d42452"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (7 corresponding lines): crates/loro-internal/src/utils/string_slice.rs:251-257 | crates/loro-internal/src/utils/string_slice.rs:259-271 \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":"crates/loro-internal/src/utils/string_slice.rs"},"region":{"startLine":251}}}],"partialFingerprints":{"codehealthFindingId/v1":"2a9e24fdf02532452f0a9f24943558e5c7912b2ce8aec14c27e694ce071d90ee"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (11 corresponding lines): crates/loro-internal/src/encoding/value.rs:1135-1145 | crates/loro-internal/src/encoding/value.rs:1151-1163 \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":"crates/loro-internal/src/encoding/value.rs"},"region":{"startLine":1135}}}],"partialFingerprints":{"codehealthFindingId/v1":"cefd68a52b6f9d921b857eb8e369ab1b9e9cf69e19034a5c806209aeffdaccd3"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (6 corresponding lines): crates/loro-wasm/src/lib.rs:549-554 | crates/loro-wasm/src/lib.rs:556-561 \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":"crates/loro-wasm/src/lib.rs"},"region":{"startLine":549}}}],"partialFingerprints":{"codehealthFindingId/v1":"05804335a258e917426588ed01d82635d45e0fd703e9e63cc98868b08ad6fbd6"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (15 corresponding lines): crates/loro-common/src/lib.rs:335-355 | crates/loro-common/src/lib.rs:364-378 \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":"crates/loro-common/src/lib.rs"},"region":{"startLine":335}}}],"partialFingerprints":{"codehealthFindingId/v1":"2533be35274da0c61e44d79dcf6f48bce4322363e2bf29999858cbe2c149d5ae"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (4 members, 12\u002B corresponding lines): crates/loro-internal/src/handler/tree.rs:856-867 | crates/loro-internal/src/handler/tree.rs:929-940 | crates/loro-internal/src/handler/tree.rs:942-953 | crates/loro-internal/src/handler/tree.rs:1039-1050 \u2014 These 4 members are one piece of code written 4 times and then edited apart: every two of them correspond over at least 12 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\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":"crates/loro-internal/src/handler/tree.rs"},"region":{"startLine":856}}}],"partialFingerprints":{"codehealthFindingId/v1":"15c8f2956146a4f8521d6841f699078b56a1a962bf65de205ec90aa93af348e1"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (12 corresponding lines): crates/loro-internal/src/handler/tree.rs:969-980 | crates/loro-internal/src/handler/tree.rs:1156-1167 \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":"crates/loro-internal/src/handler/tree.rs"},"region":{"startLine":969}}}],"partialFingerprints":{"codehealthFindingId/v1":"e9b492341705a5f3f8b9775402fb9f110bad9fe772af9f285278dbd0cad7c03f"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (12 corresponding lines): crates/loro-internal/src/oplog.rs:528-541 | crates/loro-internal/src/oplog.rs:547-558 \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":"crates/loro-internal/src/oplog.rs"},"region":{"startLine":528}}}],"partialFingerprints":{"codehealthFindingId/v1":"81be0f74b7628358ecc77fc9b42bfc4de50057a655c0594bbc81f54763ed6b37"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (9 corresponding lines): crates/loro-internal/src/encoding/json_schema.rs:1528-1536 | crates/loro-internal/src/encoding/json_schema.rs:1556-1568 \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":"crates/loro-internal/src/encoding/json_schema.rs"},"region":{"startLine":1528}}}],"partialFingerprints":{"codehealthFindingId/v1":"99892b0d5dfd1e0f798a40b4f3fa49c159368b73abf540d58d0dd9c3530bf157"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (11 corresponding lines): crates/loro-internal/src/handler/tree.rs:57-68 | crates/loro-internal/src/handler/tree.rs:70-80 \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":"crates/loro-internal/src/handler/tree.rs"},"region":{"startLine":57}}}],"partialFingerprints":{"codehealthFindingId/v1":"f3f71de4095414f60f16cf5294af576f459b585da3a7abf7adf9429f24789508"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (8 corresponding lines): crates/loro-internal/src/handler.rs:3531-3538 | crates/loro-internal/src/handler.rs:4244-4254 \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":"crates/loro-internal/src/handler.rs"},"region":{"startLine":3531}}}],"partialFingerprints":{"codehealthFindingId/v1":"e73317fdbfed572e8b1bd5176a721dcecd534c6e14bd10da8a64db879f470fe1"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (5 members, 15\u002B corresponding lines): crates/loro-internal/src/version.rs:280-294 | crates/loro-internal/src/version.rs:778-794 | crates/loro-internal/src/version.rs:839-855 | crates/loro-internal/src/version.rs:857-871 | crates/loro-internal/src/version.rs:873-887 \u2014 These 5 members are one piece of code written 5 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 5 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/version.rs"},"region":{"startLine":280}}}],"partialFingerprints":{"codehealthFindingId/v1":"520724cb57149e657c450cb17ef0f789e8492e3be94672085ce22d5de43266be"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (6 members, 11\u002B corresponding lines): crates/loro-wasm/src/counter.rs:111-122 | crates/loro-wasm/src/lib.rs:3451-3462 | crates/loro-wasm/src/lib.rs:3997-4007 | crates/loro-wasm/src/lib.rs:4408-4419 | crates/loro-wasm/src/lib.rs:4851-4862 | crates/loro-wasm/src/lib.rs:5676-5687 \u2014 These 6 members are one piece of code written 6 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 6 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-wasm/src/counter.rs"},"region":{"startLine":111}}}],"partialFingerprints":{"codehealthFindingId/v1":"37e0d542513e4ac759bbeed5aeb3862479034e4bf918c77052c0b846bbaedf1f"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (4 members, 9\u002B corresponding lines): crates/loro-internal/src/handler.rs:804-812 | crates/loro-internal/src/handler.rs:814-822 | crates/loro-internal/src/handler.rs:921-929 | crates/loro-internal/src/handler.rs:931-939 \u2014 These 4 members are one piece of code written 4 times and then edited apart: every two of them correspond over at least 9 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\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":"crates/loro-internal/src/handler.rs"},"region":{"startLine":804}}}],"partialFingerprints":{"codehealthFindingId/v1":"7778b36e5e7557d2c6c23c7548627e642c41cc93058230c9d67fc7ce0a5b72b3"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (17 corresponding lines): crates/loro-internal/src/handler.rs:3144-3160 | crates/loro-internal/src/handler.rs:3162-3182 \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":"crates/loro-internal/src/handler.rs"},"region":{"startLine":3144}}}],"partialFingerprints":{"codehealthFindingId/v1":"a435379e0c720dac5aa81e7caefefe7d4f6ac550fed0d27676c0eba6adc0cbd8"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (9 corresponding lines): crates/loro-common/src/value.rs:1047-1055 | crates/loro-common/src/value.rs:1060-1069 \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":"crates/loro-common/src/value.rs"},"region":{"startLine":1047}}}],"partialFingerprints":{"codehealthFindingId/v1":"cb214bfe954290f2488a73b865ef766b1e2a5b932c861612b38929032cc71f18"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (10 corresponding lines): crates/loro-internal/src/handler.rs:5115-5124 | crates/loro-internal/src/handler.rs:5126-5135 \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":"crates/loro-internal/src/handler.rs"},"region":{"startLine":5115}}}],"partialFingerprints":{"codehealthFindingId/v1":"b9e37d1ad64257ff20887a3c1330f7be6eebd1a80fea70b696e12b6afccfde42"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (16 corresponding lines): crates/loro-internal/src/container/richtext/richtext_state.rs:1310-1325 | crates/loro-internal/src/container/richtext/richtext_state.rs:1390-1405 \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":"crates/loro-internal/src/container/richtext/richtext_state.rs"},"region":{"startLine":1310}}}],"partialFingerprints":{"codehealthFindingId/v1":"770c2b207d4431ca353682a4b0194c871b7b7a2ef82e6791cf19bcee046de63d"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (6 members, 10\u002B corresponding lines): crates/loro-wasm/src/lib.rs:1300-1309 | crates/loro-wasm/src/lib.rs:1326-1335 | crates/loro-wasm/src/lib.rs:1352-1361 | crates/loro-wasm/src/lib.rs:1378-1387 | crates/loro-wasm/src/lib.rs:1394-1403 | crates/loro-wasm/src/lib.rs:1420-1429 \u2014 These 6 members are one piece of code written 6 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 6 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-wasm/src/lib.rs"},"region":{"startLine":1300}}}],"partialFingerprints":{"codehealthFindingId/v1":"8107e1d9ad00833527dc6fa63fa967f86be031397d0d324608a1c15ed26d1545"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (12 corresponding lines): crates/loro-internal/src/delta/map_delta.rs:76-87 | crates/loro-internal/src/delta/map_delta.rs:104-117 \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":"crates/loro-internal/src/delta/map_delta.rs"},"region":{"startLine":76}}}],"partialFingerprints":{"codehealthFindingId/v1":"18939636e4b34421fb46595b81f623c048f98728b6ec716327a5abfd1458a0f6"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (11 corresponding lines): crates/loro-internal/src/handler.rs:1646-1656 | crates/loro-internal/src/handler.rs:1765-1775 \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":"crates/loro-internal/src/handler.rs"},"region":{"startLine":1646}}}],"partialFingerprints":{"codehealthFindingId/v1":"0e4cf8c4866ac4e69527f0f936dbec5779cd660814c31b837d35a6ff7609ab3c"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 9\u002B corresponding lines): crates/loro-internal/src/handler.rs:2899-2911 | crates/loro-internal/src/handler/tree.rs:982-990 | crates/loro-internal/src/handler/tree.rs:1052-1065 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 9 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\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":"crates/loro-internal/src/handler.rs"},"region":{"startLine":2899}}}],"partialFingerprints":{"codehealthFindingId/v1":"64ec28fafd49636c2755e618e77425b2d6bc126f5cffe59863455631f50bd9e6"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (7 corresponding lines): crates/kv-store/src/utils.rs:3-9 | crates/kv-store/src/utils.rs:18-24 \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":"crates/kv-store/src/utils.rs"},"region":{"startLine":3}}}],"partialFingerprints":{"codehealthFindingId/v1":"ca539ee06c41b1b50e490f41a18a9512eea2a65a4a1ede497917b5119f9734df"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 9\u002B corresponding lines): crates/loro-internal/src/encoding/value.rs:898-908 | crates/loro-internal/src/encoding/value.rs:911-919 | crates/loro-internal/src/encoding/value.rs:931-940 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 9 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\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":"crates/loro-internal/src/encoding/value.rs"},"region":{"startLine":898}}}],"partialFingerprints":{"codehealthFindingId/v1":"8ccae83e69f19c97770339516ee789cb9920f1b3b03ab6dfb2eb40fc9a363cd5"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 11\u002B corresponding lines): crates/loro-internal/src/handler.rs:1668-1678 | crates/loro-internal/src/handler.rs:1680-1690 | crates/loro-internal/src/handler.rs:1692-1702 \u2014 These 3 members are one piece of code written 3 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 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/handler.rs"},"region":{"startLine":1668}}}],"partialFingerprints":{"codehealthFindingId/v1":"54700f02d1853686f97bd06bfa800c0603e7764f3c0604cc307c0c556a04ee87"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (9 corresponding lines): crates/loro-wasm/src/lib.rs:2406-2414 | crates/loro-wasm/src/lib.rs:3636-3644 \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":"crates/loro-wasm/src/lib.rs"},"region":{"startLine":2406}}}],"partialFingerprints":{"codehealthFindingId/v1":"ae262542fbf8ddb7c31825fb0ec9456a778f6165eda49e80cbf6bdaeb49ea4ff"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (4 members, 10\u002B corresponding lines): crates/loro-internal/src/handler.rs:3857-3866 | crates/loro-internal/src/handler.rs:4629-4638 | crates/loro-internal/src/handler/tree.rs:366-375 | crates/loro-internal/src/handler/tree.rs:698-708 \u2014 These 4 members are one piece of code written 4 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 4 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/handler.rs"},"region":{"startLine":3857}}}],"partialFingerprints":{"codehealthFindingId/v1":"2c1f3d5d11f2939b53233bb4c546583cf14cee366dd4bf6eedd2208ab9360d45"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 7\u002B corresponding lines): crates/loro-internal/src/history_cache.rs:652-658 | crates/loro-internal/src/history_cache.rs:862-868 | crates/loro-internal/src/history_cache.rs:884-890 \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":"crates/loro-internal/src/history_cache.rs"},"region":{"startLine":652}}}],"partialFingerprints":{"codehealthFindingId/v1":"b18e5c6e7b09b495d9471fb2da9c9d595382e4989005d9a46d0a08d1d1de08de"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (8 corresponding lines): crates/loro-wasm/src/awareness.rs:103-111 | crates/loro-wasm/src/awareness.rs:207-214 \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":"crates/loro-wasm/src/awareness.rs"},"region":{"startLine":103}}}],"partialFingerprints":{"codehealthFindingId/v1":"8e623ab02688529759f9fe2a3a900b80ea78340ef924caed5376c70a5f408776"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (9 corresponding lines): crates/kv-store/src/sstable.rs:582-590 | crates/kv-store/src/sstable.rs:593-607 \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":"crates/kv-store/src/sstable.rs"},"region":{"startLine":582}}}],"partialFingerprints":{"codehealthFindingId/v1":"1f1d1c17a2be53d4c0ac55dfad99d06704a7a5ff5d2a8e4afd316365f3aa063c"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (7 corresponding lines): crates/loro-internal/src/container/richtext/fugue_span.rs:137-143 | crates/loro-internal/src/container/richtext/fugue_span.rs:145-151 \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":"crates/loro-internal/src/container/richtext/fugue_span.rs"},"region":{"startLine":137}}}],"partialFingerprints":{"codehealthFindingId/v1":"1fdc59fb2db6eca0586524ec76b9d7549986228cf49a19557921dc42412d1bd0"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (6 members, 8\u002B corresponding lines): crates/loro-internal/src/loro.rs:1396-1403 | crates/loro-internal/src/loro.rs:1416-1423 | crates/loro-internal/src/loro.rs:1436-1445 | crates/loro-internal/src/loro.rs:1458-1465 | crates/loro-internal/src/loro.rs:1478-1485 | crates/loro-internal/src/loro.rs:1499-1506 \u2014 These 6 members are one piece of code written 6 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 6 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/loro.rs"},"region":{"startLine":1396}}}],"partialFingerprints":{"codehealthFindingId/v1":"6c0b9b79ff7b5d665f510940d42d9bfc2b7027a6d327263865c4fe83c5bcfd9b"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 11\u002B corresponding lines): crates/loro-internal/src/state/container_store.rs:344-355 | crates/loro-internal/src/state/container_store.rs:357-367 | crates/loro-internal/src/state/container_store.rs:369-380 \u2014 These 3 members are one piece of code written 3 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 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/state/container_store.rs"},"region":{"startLine":344}}}],"partialFingerprints":{"codehealthFindingId/v1":"a0855735c4f4440d80f0efac81f65c6a41f378def4344f6e049feaeacf6145ad"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (11 corresponding lines): crates/loro-internal/src/jsonpath/jsonpath_impl.rs:447-457 | crates/loro-internal/src/jsonpath/jsonpath_impl.rs:460-471 \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":"crates/loro-internal/src/jsonpath/jsonpath_impl.rs"},"region":{"startLine":447}}}],"partialFingerprints":{"codehealthFindingId/v1":"466422d0c99956d025ef2e68325a28880f0f3ea33802ff3f788b7c1c0a29246b"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (12 corresponding lines): crates/loro-common/src/lib.rs:844-855 | crates/loro-common/src/lib.rs:886-897 \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":"crates/loro-common/src/lib.rs"},"region":{"startLine":844}}}],"partialFingerprints":{"codehealthFindingId/v1":"8815df45a00c635f0a396de488417d139be3b8afb0779dc7f2f73bab066d1e78"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (4 corresponding lines): crates/loro-common/src/value.rs:118-121 | crates/loro-common/src/value.rs:123-128 \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":"crates/loro-common/src/value.rs"},"region":{"startLine":118}}}],"partialFingerprints":{"codehealthFindingId/v1":"6dfbbb8d136b1f3d12b9cfbb920686f4cc7488837472a9baf270a8bb399f2897"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (11 corresponding lines): crates/loro-internal/src/handler/tree.rs:1082-1092 | crates/loro-internal/src/handler/tree.rs:1120-1131 \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":"crates/loro-internal/src/handler/tree.rs"},"region":{"startLine":1082}}}],"partialFingerprints":{"codehealthFindingId/v1":"a1897f9d1bd69b7ed72091e2ecbe08e61b6375536b31db1739b45c644a8b0ca7"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (9 corresponding lines): crates/kv-store/src/block.rs:860-868 | crates/kv-store/src/sstable.rs:920-928 \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":"crates/kv-store/src/block.rs"},"region":{"startLine":860}}}],"partialFingerprints":{"codehealthFindingId/v1":"bf8b8314f63a5383c26e7dca8f23a67f380c3d51c07f962b8770be7f542684c0"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (10 corresponding lines): crates/loro-internal/src/txn.rs:119-128 | crates/loro-internal/src/txn.rs:132-141 \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":"crates/loro-internal/src/txn.rs"},"region":{"startLine":119}}}],"partialFingerprints":{"codehealthFindingId/v1":"15c1f94dd15fda63a72b4371faedb9dd9775d3ef8efebf86a27db6e693b703fa"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (8 corresponding lines): crates/loro-internal/src/state/movable_list_state.rs:1426-1438 | crates/loro-internal/src/state/list_state.rs:696-703 \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":"crates/loro-internal/src/state/movable_list_state.rs"},"region":{"startLine":1426}}}],"partialFingerprints":{"codehealthFindingId/v1":"45020f225eb771db38ecd41f37ed907ab0786f4c5e4f3609cf92bb6a3c1063d5"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (6 corresponding lines): crates/loro-internal/src/container/richtext/tracker/id_to_cursor.rs:821-826 | crates/loro-internal/src/state/movable_list_state.rs:183-188 \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":"crates/loro-internal/src/container/richtext/tracker/id_to_cursor.rs"},"region":{"startLine":821}}}],"partialFingerprints":{"codehealthFindingId/v1":"d090c1e28c508805d2755dd3ba71edc60133912ba5bc378cec09afecb1c939ca"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (7 corresponding lines): crates/generic-btree/src/generic_impl/ord.rs:298-304 | crates/loro-internal/src/state/tree_state.rs:601-607 \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":"crates/generic-btree/src/generic_impl/ord.rs"},"region":{"startLine":298}}}],"partialFingerprints":{"codehealthFindingId/v1":"4a19441f000b84bbf06f3bd2dfffb3f8d30450d24e1bb4ae1552b618233e5200"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (7 corresponding lines): crates/loro-common/src/value.rs:633-640 | crates/loro-internal/src/version.rs:1179-1185 \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":"crates/loro-common/src/value.rs"},"region":{"startLine":633}}}],"partialFingerprints":{"codehealthFindingId/v1":"7286b348e00c87ab93473ddd0f5234672c9af7f9272850ca95bac41695bd5b75"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (5 corresponding lines): crates/loro-wasm/src/lib.rs:3485-3489 | crates/loro/src/lib.rs:3339-3343 \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":"crates/loro-wasm/src/lib.rs"},"region":{"startLine":3485}}}],"partialFingerprints":{"codehealthFindingId/v1":"7982b2a9314f2410635da3ecfa71b625706dfb30f2239a2160fb64e7b1a367c0"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (10 corresponding lines): crates/loro-internal/src/container/richtext/richtext_state.rs:1183-1192 | crates/loro-internal/src/state/list_state.rs:101-110 \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":"crates/loro-internal/src/container/richtext/richtext_state.rs"},"region":{"startLine":1183}}}],"partialFingerprints":{"codehealthFindingId/v1":"061aaf0b9a79079957bee61c0c01f862c39b636f973576d4c27da46a6c93b79b"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (7 corresponding lines): crates/loro-internal/src/encoding/outdated_encode_reordered.rs:98-104 | crates/loro-internal/src/op/content.rs:91-97 \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":"crates/loro-internal/src/encoding/outdated_encode_reordered.rs"},"region":{"startLine":98}}}],"partialFingerprints":{"codehealthFindingId/v1":"e4938e1e917cce60586d77229769630978f9d07d4605e134cd3f9947ae2997ba"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (6 corresponding lines): crates/loro-internal/src/jsonpath/jsonpath_impl.rs:483-488 | crates/loro-internal/src/value.rs:514-519 \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":"crates/loro-internal/src/jsonpath/jsonpath_impl.rs"},"region":{"startLine":483}}}],"partialFingerprints":{"codehealthFindingId/v1":"142f04438d57e4706a2f4ae38e6b312f4b6d2d0ee98ca5a02b583be542412a3b"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (6 corresponding lines): crates/loro-internal/src/subscription.rs:38-43 | crates/loro-internal/src/utils/subscription.rs:683-688 \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":"crates/loro-internal/src/subscription.rs"},"region":{"startLine":38}}}],"partialFingerprints":{"codehealthFindingId/v1":"6d246a122ef6188f7deeb2e177acc7bf2737bb63455c9f27720e0f4f20287c55"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (7 corresponding lines): crates/loro-internal/src/handler.rs:3078-3084 | crates/loro-internal/src/handler/full_state.rs:108-114 \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":"crates/loro-internal/src/handler.rs"},"region":{"startLine":3078}}}],"partialFingerprints":{"codehealthFindingId/v1":"83c95cf39b6246fce931ba4f27881dcceea97d5fb3a80f23933752db446d679b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (40 lines \u00D7 2): crates/loro-internal/src/handler.rs:3446-3485 | crates/loro-internal/src/handler.rs:4156-4195 \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. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any \u0060return\u0060 inside it is the body\u0027s own exit and keeps its meaning in the moved unit."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/handler.rs"},"region":{"startLine":3446}}}],"partialFingerprints":{"codehealthFindingId/v1":"a0df60c8d24085ef85e85359a999452db12f0ce5f299f1ec3b4c89713a178600"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (40 lines \u00D7 2): crates/loro-internal/src/version.rs:407-446 | crates/loro-internal/src/version.rs:451-490 \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. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any \u0060return\u0060 inside it is the body\u0027s own exit and keeps its meaning in the moved unit."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/version.rs"},"region":{"startLine":407}}}],"partialFingerprints":{"codehealthFindingId/v1":"b440dd51c6c5a98bca711a7a01b2feb763b7a0612be764c06cd2ba25aad0be5e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (34 lines \u00D7 2): crates/loro-internal/src/handler.rs:3588-3621 | crates/loro-internal/src/handler.rs:4324-4357 \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 \u0060crates/loro-internal/src/handler.rs:3588\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":"crates/loro-internal/src/handler.rs"},"region":{"startLine":3588}}}],"partialFingerprints":{"codehealthFindingId/v1":"86cbb5c2dcfd0c4fdd7304a9b1b1e53132e20e084c8ca194e4891761abaa23a8"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (31 lines \u00D7 2): crates/loro/src/event.rs:139-169 | crates/loro/src/event.rs:192-222 \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 \u0060crates/loro/src/event.rs:139\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 first that the copies are not typed on the same thing: the declarations holding them bind \u0060value\u0060 to \u0060\u0026\u0027a DiffInner\u0060 in one and \u0060DiffInner\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":"crates/loro/src/event.rs"},"region":{"startLine":139}}}],"partialFingerprints":{"codehealthFindingId/v1":"3d854db148c5e01d762c1d6806413266f843d997be65bb71f41c88e2650bca24"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (27\u201328 lines \u00D7 2): crates/loro-internal/src/history_cache.rs:95-122 | crates/loro-internal/src/history_cache.rs:173-199 \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 \u0060crates/loro-internal/src/history_cache.rs:95\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, 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, \u0060crates/loro-internal/src/history_cache.rs:172\u0060 calls \u0060visit_all_changes\u0060 and \u0060crates/loro-internal/src/history_cache.rs:93\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":"crates/loro-internal/src/history_cache.rs"},"region":{"startLine":95}}}],"partialFingerprints":{"codehealthFindingId/v1":"30fb8661ded7a606b56d0909ff0959c1f9d3569d59b98dd8a0f3e25e0ea8d7ba"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (28 lines \u00D7 2): crates/loro-internal/src/version.rs:569-596 | crates/loro-internal/src/version.rs:603-630 \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. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any \u0060return\u0060 inside it is the body\u0027s own exit and keeps its meaning in the moved unit."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/version.rs"},"region":{"startLine":569}}}],"partialFingerprints":{"codehealthFindingId/v1":"85ee59a0c83fbf9052f2bda19a05464f9042812ace9cad3f3c9597837d74fd98"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (24\u201325 lines \u00D7 2): crates/loro-internal/src/value.rs:899-922 | crates/loro-internal/src/value.rs:931-955 \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":"crates/loro-internal/src/value.rs"},"region":{"startLine":899}}}],"partialFingerprints":{"codehealthFindingId/v1":"d6da397ae5fa2dfae19b6e7cb00d6223495c96cf9944e8772479fe57e08b0707"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (24 lines \u00D7 2): crates/loro-internal/src/jsonpath/parser.rs:390-413 | crates/loro-internal/src/jsonpath/parser.rs:445-468 \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 after the matched lines, \u0060crates/loro-internal/src/jsonpath/parser.rs:469\u0060 calls \u0060parse_logical_or_expression\u0060 and \u0060crates/loro-internal/src/jsonpath/parser.rs:414\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":"crates/loro-internal/src/jsonpath/parser.rs"},"region":{"startLine":390}}}],"partialFingerprints":{"codehealthFindingId/v1":"8a27e11baa0673cb99ebe04593695096ceec7a5b68d30ca34e947b51ac644648"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (22\u201324 lines \u00D7 2): crates/loro-internal/src/value.rs:316-337 | crates/loro-internal/src/value.rs:403-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. Read the line range as the matched WINDOW rather than a finished unit: at \u0060crates/loro-internal/src/value.rs: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. 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":"crates/loro-internal/src/value.rs"},"region":{"startLine":316}}}],"partialFingerprints":{"codehealthFindingId/v1":"6206b39f990e9b732ab1de83bc058e8415cfec3886fbe9904a7df9bd0952f54a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (22 lines \u00D7 2): crates/loro-wasm/src/lib.rs:4179-4200 | crates/loro-wasm/src/lib.rs:4621-4642 \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. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any \u0060return\u0060 inside it is the body\u0027s own exit and keeps its meaning in the moved unit."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-wasm/src/lib.rs"},"region":{"startLine":4179}}}],"partialFingerprints":{"codehealthFindingId/v1":"1a1db4e96469db057f28d1b0505ea9eef1da16a852b9082cce9c2d7c1695ea75"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (20\u201321 lines \u00D7 3): crates/loro-internal/src/encoding/outdated_encode_reordered.rs:307-326 | crates/loro-internal/src/encoding/outdated_encode_reordered.rs:382-402 | crates/loro-internal/src/encoding/outdated_encode_reordered.rs:477-497 \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 \u0060crates/loro-internal/src/encoding/outdated_encode_reordered.rs:307\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":"crates/loro-internal/src/encoding/outdated_encode_reordered.rs"},"region":{"startLine":307}}}],"partialFingerprints":{"codehealthFindingId/v1":"2ba314ad97bac3b708bfa25240496b7b7a8d0d6916d494ece063f557599a7aec"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (21 lines \u00D7 2): crates/loro-wasm/src/convert.rs:67-87 | crates/loro-wasm/src/convert.rs:332-352 \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":"crates/loro-wasm/src/convert.rs"},"region":{"startLine":67}}}],"partialFingerprints":{"codehealthFindingId/v1":"8ce972a2009e0ff417c8d29daa29b4ea5a66ec0a581b073c5b5a75e0ec1a2c21"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (21 lines \u00D7 2): crates/loro-wasm/src/lib.rs:3049-3069 | crates/loro-wasm/src/lib.rs:3079-3099 \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":"crates/loro-wasm/src/lib.rs"},"region":{"startLine":3049}}}],"partialFingerprints":{"codehealthFindingId/v1":"27fd60917fee1b3b210aff980e1c00463204b8e5205af6f971c30f941b8ff6f9"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (19 lines \u00D7 2): crates/loro-internal/src/encoding/json_schema.rs:734-752 | crates/loro-internal/src/handler.rs:64-82 \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 \u0060crates/loro-internal/src/encoding/json_schema.rs:734\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":"crates/loro-internal/src/encoding/json_schema.rs"},"region":{"startLine":734}}}],"partialFingerprints":{"codehealthFindingId/v1":"1b5f99cc6fd1c4cfad60e0b190f63ae1d477b2ee46d25f90a369bbd0f73043ef"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (15\u201318 lines \u00D7 3): crates/loro-internal/src/history_cache.rs:390-406 | crates/loro-internal/src/history_cache.rs:448-465 | crates/loro-internal/src/history_cache.rs:528-542 \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 \u0060crates/loro-internal/src/history_cache.rs:448\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":"crates/loro-internal/src/history_cache.rs"},"region":{"startLine":390}}}],"partialFingerprints":{"codehealthFindingId/v1":"1643a4ff9b8a0137af6cdbd760e065c87558060d191b7a038fe7be4f9f58cf56"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (15\u201318 lines \u00D7 2): crates/loro-internal/src/handler.rs:2923-2940 | crates/loro-internal/src/state/richtext_state.rs:282-296 \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 \u0060crates/loro-internal/src/handler.rs:2923\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, 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":"crates/loro-internal/src/handler.rs"},"region":{"startLine":2923}}}],"partialFingerprints":{"codehealthFindingId/v1":"2dea7d3205aa0ea9be5faa53de7a28562d63d50c71136b24430bae1c9eb55790"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (16\u201318 lines \u00D7 2): crates/loro-internal/src/state/tree_state.rs:181-196 | crates/loro-internal/src/state/tree_state.rs:1726-1743 \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 \u0060crates/loro-internal/src/state/tree_state.rs:181\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":"crates/loro-internal/src/state/tree_state.rs"},"region":{"startLine":181}}}],"partialFingerprints":{"codehealthFindingId/v1":"8bc2a8fe5a828fb45b3591962d9740ee04835a014bdafc8a32f36922ea67dff0"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (18 lines \u00D7 2): crates/loro-internal/src/value.rs:957-974 | crates/loro-internal/src/value.rs:985-1002 \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":"crates/loro-internal/src/value.rs"},"region":{"startLine":957}}}],"partialFingerprints":{"codehealthFindingId/v1":"ea5b5cb2e8d0e1d53d7a3fae85dea03a82f71f531f341177bfa189a488249e9f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (18 lines \u00D7 2): crates/rle/src/rle_vec.rs:301-318 | crates/rle/src/rle_vec.rs:396-413 \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 \u0060crates/rle/src/rle_vec.rs:301\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, 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":"crates/rle/src/rle_vec.rs"},"region":{"startLine":301}}}],"partialFingerprints":{"codehealthFindingId/v1":"592dea4e6f1ea9d2cd1f0f85b146a4d49652a7da11dce569a172fef663e0b3f5"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (16 lines \u00D7 2): crates/loro-internal/src/container/richtext/tracker/crdt_rope.rs:611-626 | crates/loro-internal/src/container/richtext/tracker/crdt_rope.rs:669-684 \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 \u0060crates/loro-internal/src/container/richtext/tracker/crdt_rope.rs:611\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, 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":"crates/loro-internal/src/container/richtext/tracker/crdt_rope.rs"},"region":{"startLine":611}}}],"partialFingerprints":{"codehealthFindingId/v1":"1c22b25a04159717b9a7b5288dc4e9ff68f5237d395cb3845cbe0323e68085a2"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (16 lines \u00D7 2): crates/loro-internal/src/handler.rs:3346-3361 | crates/loro-internal/src/handler.rs:3916-3931 \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 \u0060crates/loro-internal/src/handler.rs:3346\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, 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":"crates/loro-internal/src/handler.rs"},"region":{"startLine":3346}}}],"partialFingerprints":{"codehealthFindingId/v1":"474a57ea29ece61f07eb310213d7c4b4a7eea16a02433afa6f5bc08ce9bdff59"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (16 lines \u00D7 2): crates/loro-internal/src/state/tree_state.rs:1866-1881 | crates/loro-internal/src/state/tree_state.rs:1883-1898 \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":"crates/loro-internal/src/state/tree_state.rs"},"region":{"startLine":1866}}}],"partialFingerprints":{"codehealthFindingId/v1":"06b30e3fd03a87959bac637d8701d53540e23efa347433a73475414af0a973ff"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (15\u201316 lines \u00D7 2): crates/loro-wasm-tools/src/main.rs:206-220 | crates/loro-wasm-tools/src/main.rs:260-275 \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":"crates/loro-wasm-tools/src/main.rs"},"region":{"startLine":206}}}],"partialFingerprints":{"codehealthFindingId/v1":"cd013dd55586d5949edb6cf2c716b14695d76c6cd696f1278a2f592a19b5801e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (15 lines \u00D7 2): crates/generic-btree/src/lib.rs:2886-2900 | crates/generic-btree/src/lib.rs:2936-2950 \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":"crates/generic-btree/src/lib.rs"},"region":{"startLine":2886}}}],"partialFingerprints":{"codehealthFindingId/v1":"ab5bb4e4a290af9b6e464221bb63b42b4a80495b5f60ecd5f852c35f14db3b74"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (15 lines \u00D7 2): crates/loro-internal/src/encoding/json_schema.rs:839-853 | crates/loro-internal/src/encoding/json_schema.rs:875-889 \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 \u0060crates/loro-internal/src/encoding/json_schema.rs:839\u0060 it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows \u2014 the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members\u0027 bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run \u2014 a one-line delegation has no helper inside it to lift \u2014 so generate the run from the set it enumerates, or accept it and keep each member\u0027s own documentation with it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/encoding/json_schema.rs"},"region":{"startLine":839}}}],"partialFingerprints":{"codehealthFindingId/v1":"34366fcf76c0a31e698aa58832a0d03617a9cedc18d42238022a29484fb8dde1"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14\u201315 lines \u00D7 2): crates/loro-internal/src/handler.rs:3566-3579 | crates/loro-internal/src/handler.rs:4282-4296 \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 \u0060crates/loro-internal/src/handler.rs:3566\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, 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":"crates/loro-internal/src/handler.rs"},"region":{"startLine":3566}}}],"partialFingerprints":{"codehealthFindingId/v1":"f00968ae1fb4ec444bfbec815a10b610aeacb881937feafb32d448e83d3ffde2"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (15 lines \u00D7 2): crates/loro-internal/src/jsonpath/parser.rs:332-346 | crates/loro-internal/src/jsonpath/parser.rs:403-417 \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 \u0060crates/loro-internal/src/jsonpath/parser.rs:332\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, 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":"crates/loro-internal/src/jsonpath/parser.rs"},"region":{"startLine":332}}}],"partialFingerprints":{"codehealthFindingId/v1":"7f121fc835479e36afd73fdf9c6c9a7885923d737a3bc827d615ac900383d8c1"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (15 lines \u00D7 2): crates/loro-internal/src/state/movable_list_state.rs:1274-1288 | crates/loro-internal/src/state/movable_list_state.rs:1324-1338 \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 \u0060crates/loro-internal/src/state/movable_list_state.rs:1274\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, 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":"crates/loro-internal/src/state/movable_list_state.rs"},"region":{"startLine":1274}}}],"partialFingerprints":{"codehealthFindingId/v1":"f4a27548d645414ff585990405f2f883fb29e21e47fbe204c51094cf3ab382bb"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (15 lines \u00D7 2): crates/loro-internal/src/value.rs:254-268 | crates/loro-internal/src/value.rs:355-369 \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 \u0060crates/loro-internal/src/value.rs:254\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":"crates/loro-internal/src/value.rs"},"region":{"startLine":254}}}],"partialFingerprints":{"codehealthFindingId/v1":"92853f654be0f9ca2af7b6fc9d374bfe6da0ba892d02cefefd6b64fa9fce1348"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (15 lines \u00D7 2): crates/loro-internal/src/version.rs:780-794 | crates/loro-internal/src/version.rs:841-855 \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 \u0060crates/loro-internal/src/version.rs:780\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, 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":"crates/loro-internal/src/version.rs"},"region":{"startLine":780}}}],"partialFingerprints":{"codehealthFindingId/v1":"4d2056bd87ae85d1c1e1c912774c269d77ea12a27f465b4aa901dc16c37540b2"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13\u201314 lines \u00D7 6): crates/loro-wasm/src/counter.rs:72-84 | crates/loro-wasm/src/lib.rs:3380-3393 | crates/loro-wasm/src/lib.rs:3941-3954 | crates/loro-wasm/src/lib.rs:4351-4363 | crates/loro-wasm/src/lib.rs:4794-4806 | crates/loro-wasm/src/lib.rs:5637-5649 \u2014 there are 6 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 6 sites; resolving a subset leaves the remainder to drift apart. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any \u0060return\u0060 inside it is the body\u0027s own exit and keeps its meaning in the moved unit."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-wasm/src/counter.rs"},"region":{"startLine":72}}}],"partialFingerprints":{"codehealthFindingId/v1":"09eb1a485978f87276128ca71525d5b1d8d49921ce077c93677d2488fa599343"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 3): crates/loro-internal/src/handler.rs:720-733 | crates/loro-internal/src/handler.rs:851-864 | crates/loro-internal/src/handler.rs:961-974 \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 \u0060crates/loro-internal/src/handler.rs:720\u0060 it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows \u2014 the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members\u0027 bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run \u2014 a one-line delegation has no helper inside it to lift \u2014 so generate the run from the set it enumerates, or accept it and keep each member\u0027s own documentation with it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/handler.rs"},"region":{"startLine":720}}}],"partialFingerprints":{"codehealthFindingId/v1":"87a5096e75df3038bf4898731b85af2fe211600e44191b844a756f507694ab14"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 3): crates/loro-wasm/src/lib.rs:2221-2234 | crates/loro-wasm/src/lib.rs:2262-2275 | crates/loro-wasm/src/lib.rs:2298-2311 \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 \u0060crates/loro-wasm/src/lib.rs:2221\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, 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":"crates/loro-wasm/src/lib.rs"},"region":{"startLine":2221}}}],"partialFingerprints":{"codehealthFindingId/v1":"8730cfadd50728249bd212777364c30b0080b0279d8b7a762711cb6130f12781"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13\u201314 lines \u00D7 2): crates/generic-btree/src/generic_impl/ord.rs:279-291 | crates/loro-internal/src/state/tree_state.rs:581-594 \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 \u0060crates/generic-btree/src/generic_impl/ord.rs:279\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, 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":"crates/generic-btree/src/generic_impl/ord.rs"},"region":{"startLine":279}}}],"partialFingerprints":{"codehealthFindingId/v1":"7bfd95a9f8cf5c22442d4c45587e72b0ac015d961d1282880c101a18acb49ebe"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 2): crates/loro-internal/src/container/richtext/style_range_map.rs:421-434 | crates/loro-internal/src/container/richtext/style_range_map.rs:442-455 \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":"crates/loro-internal/src/container/richtext/style_range_map.rs"},"region":{"startLine":421}}}],"partialFingerprints":{"codehealthFindingId/v1":"93e76e07ab7f1b61aaa61835774ba4f00e65266b1aa122812d9e49f77d6dbaae"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 2): crates/loro-internal/src/oplog/loro_dag.rs:1588-1601 | crates/loro-internal/src/oplog/loro_dag.rs:1641-1654 \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 \u0060crates/loro-internal/src/oplog/loro_dag.rs:1588\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":"crates/loro-internal/src/oplog/loro_dag.rs"},"region":{"startLine":1588}}}],"partialFingerprints":{"codehealthFindingId/v1":"c002890fc9526fac7b930172d89d55a8658ec00cc6c58bd58d35c0a409e8a5d9"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 2): crates/loro-internal/src/state/tree_state.rs:1324-1337 | crates/loro-internal/src/state/tree_state.rs:1373-1386 \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 \u0060crates/loro-internal/src/state/tree_state.rs:1324\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, 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":"crates/loro-internal/src/state/tree_state.rs"},"region":{"startLine":1324}}}],"partialFingerprints":{"codehealthFindingId/v1":"f64f43fda9d72f659ab7fb16b9761c61e917884ba0173a495fc5ae43a3282af6"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 4): crates/loro-internal/src/state/richtext_state.rs:143-155 | crates/loro-internal/src/state/richtext_state.rs:200-212 | crates/loro-internal/src/state/richtext_state.rs:228-240 | crates/loro-internal/src/state/richtext_state.rs:1530-1542 \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":"crates/loro-internal/src/state/richtext_state.rs"},"region":{"startLine":143}}}],"partialFingerprints":{"codehealthFindingId/v1":"07722b663deda92bbaaf52e02a0c3b43b881c54353b48f01fcd7c6ce956c2541"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): crates/loro-internal/src/container/richtext/tracker/id_to_cursor.rs:530-542 | crates/loro-internal/src/container/richtext/tracker/id_to_cursor.rs:546-558 \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 \u0060crates/loro-internal/src/container/richtext/tracker/id_to_cursor.rs:530\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, 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":"crates/loro-internal/src/container/richtext/tracker/id_to_cursor.rs"},"region":{"startLine":530}}}],"partialFingerprints":{"codehealthFindingId/v1":"1ca801000431f710cf6ad4a04e020b9b310aa95199ceaea86f7588d954890387"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12\u201313 lines \u00D7 2): crates/loro-internal/src/handler.rs:4544-4555 | crates/loro-internal/src/handler.rs:4574-4586 \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 \u0060crates/loro-internal/src/handler.rs:4574\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, 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":"crates/loro-internal/src/handler.rs"},"region":{"startLine":4544}}}],"partialFingerprints":{"codehealthFindingId/v1":"bf3044f522fbb96b88492a6e2801cc3556622d3b16cfea86c6acaa0bbeb07ee3"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): crates/loro-internal/src/loro.rs:3846-3858 | crates/loro-internal/src/loro.rs:3861-3873 \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 \u0060crates/loro-internal/src/loro.rs:3846\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, 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":"crates/loro-internal/src/loro.rs"},"region":{"startLine":3846}}}],"partialFingerprints":{"codehealthFindingId/v1":"88903bef5c330d316d7a4fd5bf1b1a1fdc6f2ef8cc38b2c4f809e0eb72f7ab31"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12\u201313 lines \u00D7 2): crates/loro-internal/src/oplog/change_store.rs:284-295 | crates/loro-internal/src/oplog/change_store.rs:2415-2427 \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 \u0060crates/loro-internal/src/oplog/change_store.rs:284\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":"crates/loro-internal/src/oplog/change_store.rs"},"region":{"startLine":284}}}],"partialFingerprints":{"codehealthFindingId/v1":"e6acfc027d6e1ab6eb52468150dbb1b73cf334b65db75ed2e227c0e1df7874fe"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): crates/loro-internal/src/oplog/change_store.rs:885-897 | crates/loro-internal/src/oplog/change_store.rs:917-929 \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 \u0060crates/loro-internal/src/oplog/change_store.rs:885\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, 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":"crates/loro-internal/src/oplog/change_store.rs"},"region":{"startLine":885}}}],"partialFingerprints":{"codehealthFindingId/v1":"6d2fcf8d866d3e56d66e9faa8f5e622f2211356fa6a6e49cc9d5ebc48290a943"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): crates/loro-internal/src/version.rs:859-871 | crates/loro-internal/src/version.rs:875-887 \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 \u0060crates/loro-internal/src/version.rs:859\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, 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":"crates/loro-internal/src/version.rs"},"region":{"startLine":859}}}],"partialFingerprints":{"codehealthFindingId/v1":"3f0ce3639c4809dfb1687b3d560d12207170996a463522dd5ea644606f2d15e5"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): crates/loro-wasm/src/convert.rs:516-528 | crates/loro-wasm/src/convert.rs:602-614 \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 \u0060crates/loro-wasm/src/convert.rs:516\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":"crates/loro-wasm/src/convert.rs"},"region":{"startLine":516}}}],"partialFingerprints":{"codehealthFindingId/v1":"ac50c58612fe59bd6b25c2dd8bf5df260025b4a7d4c9237d7695d2ab9aa259dd"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): crates/loro-wasm/src/lib.rs:6064-6076 | crates/loro-wasm/src/lib.rs:6192-6204 \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":"crates/loro-wasm/src/lib.rs"},"region":{"startLine":6064}}}],"partialFingerprints":{"codehealthFindingId/v1":"6fc902aeaa6c9ecc14667fb46b801997f22c3cd8444a39a5e16adabbb76bd7cf"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 3): crates/fuzz/src/crdt_fuzzer.rs:976-987 | crates/fuzz/src/crdt_fuzzer.rs:1100-1111 | crates/loro-internal/src/fuzz.rs:20-31 \u2014 before extracting anything, compare \u0060crates/fuzz/src/crdt_fuzzer.rs\u0060 and \u0060crates/loro-internal/src/fuzz.rs\u0060 as WHOLE FILES: this scan already matched 6 separate duplicated blocks between them, totalling at least 59 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. The two sit in different directories, so one cannot simply be deleted in favour of the other while both are reached separately: hoist the shared part into a location both already depend on and have each file call it, and retire whichever file turns out to have no caller of its own left. Extracting one helper per block leaves the fork in place. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/fuzz/src/crdt_fuzzer.rs"},"region":{"startLine":976}}}],"partialFingerprints":{"codehealthFindingId/v1":"482da66272220eb00a207b01ebedb592a3ee46e3485aff6ae3bd3452a67808c4"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11\u201312 lines \u00D7 3): crates/fuzz/src/crdt_fuzzer.rs:1090-1100 | crates/fuzz/src/mem_kv_fuzzer.rs:281-291 | crates/loro-internal/src/fuzz.rs:9-20 \u2014 before extracting anything, compare \u0060crates/fuzz/src/crdt_fuzzer.rs\u0060 and \u0060crates/fuzz/src/mem_kv_fuzzer.rs\u0060 as WHOLE FILES: this scan already matched 4 separate duplicated blocks between them, totalling at least 51 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 \u0060crates/fuzz/src/crdt_fuzzer.rs:1090\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":"crates/fuzz/src/crdt_fuzzer.rs"},"region":{"startLine":1090}}}],"partialFingerprints":{"codehealthFindingId/v1":"4e48ebe539ec59336b582971615a6e5a9596122db68be1f1f00eb377f233cb55"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): crates/loro-internal/src/encoding/json_schema.rs:310-321 | crates/loro-internal/src/encoding/json_schema.rs:341-352 \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 \u0060crates/loro-internal/src/encoding/json_schema.rs:310\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":"crates/loro-internal/src/encoding/json_schema.rs"},"region":{"startLine":310}}}],"partialFingerprints":{"codehealthFindingId/v1":"18fb6d71273b4565749ea468eb9806f767c69b11008bbe7cfc41909ff4463782"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): crates/loro-internal/src/encoding/json_schema.rs:376-387 | crates/loro-internal/src/encoding/json_schema.rs:436-447 \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":"crates/loro-internal/src/encoding/json_schema.rs"},"region":{"startLine":376}}}],"partialFingerprints":{"codehealthFindingId/v1":"e67501f5ed3b508f940e84734e8c94a0bc40f3b2b46f20f3f20ef87a41073769"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): crates/loro-internal/src/handler.rs:3542-3553 | crates/loro-internal/src/handler.rs:4258-4269 \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. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any \u0060return\u0060 inside it is the body\u0027s own exit and keeps its meaning in the moved unit."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/handler.rs"},"region":{"startLine":3542}}}],"partialFingerprints":{"codehealthFindingId/v1":"b6e9d4d1deace02e2148e901a3dac3df131fcfb1009e459402296f8696a20a97"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): crates/loro-internal/src/jsonpath/parser.rs:307-318 | crates/loro-internal/src/jsonpath/parser.rs:433-444 \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 \u0060crates/loro-internal/src/jsonpath/parser.rs:307\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":"crates/loro-internal/src/jsonpath/parser.rs"},"region":{"startLine":307}}}],"partialFingerprints":{"codehealthFindingId/v1":"6e245b688ea65cf54b05b39093286308b759acab7cf21a42e538ca8eb8c8d3d1"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11\u201312 lines \u00D7 2): crates/loro-internal/src/loro.rs:4264-4275 | crates/loro-internal/src/oplog/loro_dag.rs:847-857 \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 \u0060crates/loro-internal/src/loro.rs:4264\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":"crates/loro-internal/src/loro.rs"},"region":{"startLine":4264}}}],"partialFingerprints":{"codehealthFindingId/v1":"24cfc1ac11f2fbf43f4017f3e6bfbfbd6a6e85a4d47c40f1a3f3e09ea6abe389"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11\u201312 lines \u00D7 2): crates/loro-wasm-tools/src/main.rs:157-168 | crates/loro-wasm-tools/src/main.rs:225-235 \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, \u0060crates/loro-wasm-tools/src/main.rs:237\u0060 calls \u0060sort_by_key\u0060 and \u0060crates/loro-wasm-tools/src/main.rs:170\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":"crates/loro-wasm-tools/src/main.rs"},"region":{"startLine":157}}}],"partialFingerprints":{"codehealthFindingId/v1":"eb371453899c2d078f7f202ad700facd9d47bd7ec9046e9c718c2214e0c2bb61"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 3): crates/kv-store/src/block.rs:484-494 | crates/kv-store/src/block.rs:501-511 | crates/kv-store/src/block.rs:518-528 \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":"crates/kv-store/src/block.rs"},"region":{"startLine":484}}}],"partialFingerprints":{"codehealthFindingId/v1":"4af72b32d027b58afbb23563700211a2999f29ab7e98783a6428dfcfc1e077d0"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 3): crates/loro-internal/src/handler.rs:737-747 | crates/loro-internal/src/handler.rs:868-878 | crates/loro-internal/src/handler.rs:978-988 \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 \u0060crates/loro-internal/src/handler.rs:737\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, 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":"crates/loro-internal/src/handler.rs"},"region":{"startLine":737}}}],"partialFingerprints":{"codehealthFindingId/v1":"7310c3da0e4409975d46063323f9834aac2df7ea5658777016ff876438f7ad0f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 3): crates/loro-internal/src/jsonpath/parser.rs:320-330 | crates/loro-internal/src/jsonpath/parser.rs:391-401 | crates/loro-internal/src/jsonpath/parser.rs:446-456 \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. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any \u0060return\u0060 inside it is the body\u0027s own exit and keeps its meaning in the moved unit."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/jsonpath/parser.rs"},"region":{"startLine":320}}}],"partialFingerprints":{"codehealthFindingId/v1":"f0c5567fd3d5e4f384bfe5b7f851eab343d5ebbd8a0a2ee2197ff0e6adab12fa"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 3): crates/loro-internal/src/jsonpath/parser.rs:332-342 | crates/loro-internal/src/jsonpath/parser.rs:403-413 | crates/loro-internal/src/jsonpath/parser.rs:458-468 \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. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any \u0060return\u0060 inside it is the body\u0027s own exit and keeps its meaning in the moved unit. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, \u0060crates/loro-internal/src/jsonpath/parser.rs:469\u0060 calls \u0060parse_logical_or_expression\u0060 and \u0060crates/loro-internal/src/jsonpath/parser.rs:343\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":"crates/loro-internal/src/jsonpath/parser.rs"},"region":{"startLine":332}}}],"partialFingerprints":{"codehealthFindingId/v1":"1079250c6ba078bc5d6b2ab74f9706059f59b7493c8a070fbd8da14dba29fc79"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 3): crates/loro-internal/src/value.rs:259-269 | crates/loro-internal/src/value.rs:295-305 | crates/loro-internal/src/value.rs:360-370 \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 \u0060crates/loro-internal/src/value.rs:259\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":"crates/loro-internal/src/value.rs"},"region":{"startLine":259}}}],"partialFingerprints":{"codehealthFindingId/v1":"9eb26ebb8eed5102d4c18ccde57a224e536f03645c2fc8095fea1331c9e958a6"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): crates/kv-store/src/sstable.rs:935-945 | crates/loro-internal/src/kv_store.rs:38-48 \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. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any \u0060return\u0060 inside it is the body\u0027s own exit and keeps its meaning in the moved unit."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/kv-store/src/sstable.rs"},"region":{"startLine":935}}}],"partialFingerprints":{"codehealthFindingId/v1":"541f8569ddfa18e2f497bb40e823467a0a2c75fac020ae36ba4763785148098e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): crates/loro-internal/src/container/richtext/tracker.rs:165-175 | crates/loro-internal/src/container/richtext/tracker.rs:365-375 \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 \u0060crates/loro-internal/src/container/richtext/tracker.rs:165\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, 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 first that the copies are not typed on the same thing: the declarations holding them bind \u0060op_id\u0060 to \u0060IdFull\u0060 in one and \u0060ID\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. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, \u0060crates/loro-internal/src/container/richtext/tracker.rs:376\u0060 calls \u0060update_insert_by_split\u0060 and \u0060crates/loro-internal/src/container/richtext/tracker.rs:176\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":"crates/loro-internal/src/container/richtext/tracker.rs"},"region":{"startLine":165}}}],"partialFingerprints":{"codehealthFindingId/v1":"6761e22ad37f616e99a8576296f4ac712eb17169efa871d6cbf7d28e5a8e7bde"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): crates/loro-internal/src/container/richtext/tracker.rs:410-420 | crates/loro-internal/src/container/richtext/tracker.rs:515-525 \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 \u0060crates/loro-internal/src/container/richtext/tracker.rs:410\u0060 it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows \u2014 the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members\u0027 bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run \u2014 a one-line delegation has no helper inside it to lift \u2014 so generate the run from the set it enumerates, or accept it and keep each member\u0027s own documentation with it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/container/richtext/tracker.rs"},"region":{"startLine":410}}}],"partialFingerprints":{"codehealthFindingId/v1":"4a5ad351df132ae1b52b359179bc57d99dfbfba7f91043c1fdf23e9982ab1809"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10\u201311 lines \u00D7 2): crates/loro-internal/src/container/richtext/tracker/id_to_cursor.rs:89-98 | crates/loro-internal/src/container/richtext/tracker/id_to_cursor.rs:141-151 \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 \u0060crates/loro-internal/src/container/richtext/tracker/id_to_cursor.rs:89\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":"crates/loro-internal/src/container/richtext/tracker/id_to_cursor.rs"},"region":{"startLine":89}}}],"partialFingerprints":{"codehealthFindingId/v1":"662f4c5e94e909f889dda2ade9ea776fc69e9add1b2ae9b74037bebf9d850107"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): crates/loro-internal/src/encoding/shallow_snapshot.rs:537-547 | crates/loro-internal/src/encoding/shallow_snapshot.rs:841-851 \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":"crates/loro-internal/src/encoding/shallow_snapshot.rs"},"region":{"startLine":537}}}],"partialFingerprints":{"codehealthFindingId/v1":"0e6bb2f86fd4b5fb2f01da6b942dc24735ac8f3ed20af422377e30b4e2fec6b6"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): crates/loro-internal/src/handler.rs:4667-4677 | crates/loro-internal/src/handler.rs:4703-4713 \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 \u0060crates/loro-internal/src/handler.rs:4667\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":"crates/loro-internal/src/handler.rs"},"region":{"startLine":4667}}}],"partialFingerprints":{"codehealthFindingId/v1":"71f42ee55d26adf80e0dd96adaef2a5ef96dc6112bf3e9c71ce3066744d65aca"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): crates/loro-internal/src/handler.rs:4705-4715 | crates/loro-internal/src/handler.rs:5044-5054 \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":"crates/loro-internal/src/handler.rs"},"region":{"startLine":4705}}}],"partialFingerprints":{"codehealthFindingId/v1":"6b0f5557fc928114aa218d53d02f7202c1ccf8bc0ce2410565581b6b6a5db885"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): crates/loro-internal/src/state/tree_state.rs:1230-1240 | crates/loro-internal/src/state/tree_state.rs:1255-1265 \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":"crates/loro-internal/src/state/tree_state.rs"},"region":{"startLine":1230}}}],"partialFingerprints":{"codehealthFindingId/v1":"de4856613dafc19492f0749d8dbec596e2751307fbf5f8ca16cfa867c1c7f9aa"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): crates/loro-wasm-tools/src/main.rs:170-180 | crates/loro-wasm-tools/src/main.rs:238-248 \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 \u0060crates/loro-wasm-tools/src/main.rs:170\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, 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, \u0060crates/loro-wasm-tools/src/main.rs:237\u0060 calls \u0060sort_by_key\u0060 and \u0060crates/loro-wasm-tools/src/main.rs:168\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":"crates/loro-wasm-tools/src/main.rs"},"region":{"startLine":170}}}],"partialFingerprints":{"codehealthFindingId/v1":"e0d9091b8bf4dba2abe26adb5edd4e4d9957ddc260dc2602e415135f7566b906"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9\u201310 lines \u00D7 4): crates/fuzz/src/crdt_fuzzer.rs:964-973 | crates/fuzz/src/crdt_fuzzer.rs:1090-1098 | crates/fuzz/src/mem_kv_fuzzer.rs:281-289 | crates/loro-internal/src/fuzz.rs:9-18 \u2014 before extracting anything, compare \u0060crates/fuzz/src/crdt_fuzzer.rs\u0060 and \u0060crates/fuzz/src/mem_kv_fuzzer.rs\u0060 as WHOLE FILES: this scan already matched 4 separate duplicated blocks between them, totalling at least 51 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":"crates/fuzz/src/crdt_fuzzer.rs"},"region":{"startLine":964}}}],"partialFingerprints":{"codehealthFindingId/v1":"0271baf107d938b401b71fe5678a5c8028fe0fd5ba573dd7c1829d63a5c1708b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 3): crates/loro-internal/src/handler.rs:3343-3352 | crates/loro-internal/src/handler.rs:3718-3727 | crates/loro-internal/src/handler.rs:3913-3922 \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 \u0060crates/loro-internal/src/handler.rs:3343\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":"crates/loro-internal/src/handler.rs"},"region":{"startLine":3343}}}],"partialFingerprints":{"codehealthFindingId/v1":"8e4880823235f99c8d693e8d1aa2ae10c549e4e1a0994077a6b898f802b6c434"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): crates/loro-internal/src/diff_calc.rs:285-294 | crates/loro-internal/src/diff_calc.rs:635-644 \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":"crates/loro-internal/src/diff_calc.rs"},"region":{"startLine":285}}}],"partialFingerprints":{"codehealthFindingId/v1":"157e6eddda3d206ff15a4947a0a191d155963ea9497a79aaaf299edbaf0e4268"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): crates/loro-internal/src/handler.rs:3264-3273 | crates/loro-internal/src/handler.rs:3728-3737 \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 \u0060crates/loro-internal/src/handler.rs:3264\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, 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":"crates/loro-internal/src/handler.rs"},"region":{"startLine":3264}}}],"partialFingerprints":{"codehealthFindingId/v1":"829f92dde6d4f78d152be8e5f9b7bc3e5ca1285c64f481a876786f374395ad44"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10\u201317 lines \u00D7 2): crates/loro-internal/src/handler.rs:3777-3793 | crates/loro-internal/src/handler.rs:3976-3985 \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 \u0060crates/loro-internal/src/handler.rs:3777\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":"crates/loro-internal/src/handler.rs"},"region":{"startLine":3777}}}],"partialFingerprints":{"codehealthFindingId/v1":"49fb751d29d7aa8d912d4c32f599ca00d85c3efd3ab6bb8e3c662b5a54a1e697"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7\u201315 lines \u00D7 4): crates/loro-internal/src/encoding/shallow_snapshot.rs:88-94 | crates/loro-internal/src/oplog/change_store.rs:392-402 | crates/loro-internal/src/oplog/change_store.rs:451-465 | crates/loro-internal/src/oplog/change_store.rs:1240-1246 \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. Read the line range as the matched WINDOW rather than a finished unit: at \u0060crates/loro-internal/src/oplog/change_store.rs:392\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":"crates/loro-internal/src/encoding/shallow_snapshot.rs"},"region":{"startLine":88}}}],"partialFingerprints":{"codehealthFindingId/v1":"8e81f1e37e649923c1c4cc9237011d46c86724ee647fed8f45e1aefd97a55f39"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): crates/loro-wasm/src/lib.rs:4144-4153 | crates/loro-wasm/src/lib.rs:4586-4595 \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. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any \u0060return\u0060 inside it is the body\u0027s own exit and keeps its meaning in the moved unit."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-wasm/src/lib.rs"},"region":{"startLine":4144}}}],"partialFingerprints":{"codehealthFindingId/v1":"b5762a21d16223acefc0eacd4869fab17cce56b5e11083fe2635e14df44f2744"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8\u20139 lines \u00D7 4): crates/generic-btree/src/generic_impl/gap_buffer.rs:192-199 | crates/generic-btree/src/lib.rs:2999-3006 | crates/generic-btree/src/rle.rs:12-20 | crates/generic-btree/src/rle.rs:53-61 \u2014 there are 4 copies across 3 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. Read the line range as the matched WINDOW rather than a finished unit: at \u0060crates/generic-btree/src/generic_impl/gap_buffer.rs:192\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":"crates/generic-btree/src/generic_impl/gap_buffer.rs"},"region":{"startLine":192}}}],"partialFingerprints":{"codehealthFindingId/v1":"8c6ef6cc6876c6abd2bcf0af3012c96460bb34c14d7e03f73e65000596e31dcc"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 3): crates/fuzz/src/crdt_fuzzer.rs:1024-1032 | crates/fuzz/src/crdt_fuzzer.rs:1122-1130 | crates/loro-internal/src/fuzz.rs:49-57 \u2014 before extracting anything, compare \u0060crates/fuzz/src/crdt_fuzzer.rs\u0060 and \u0060crates/loro-internal/src/fuzz.rs\u0060 as WHOLE FILES: this scan already matched 6 separate duplicated blocks between them, totalling at least 59 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. The two sit in different directories, so one cannot simply be deleted in favour of the other while both are reached separately: hoist the shared part into a location both already depend on and have each file call it, and retire whichever file turns out to have no caller of its own left. Extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at \u0060crates/fuzz/src/crdt_fuzzer.rs:1024\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 after the matched lines, \u0060crates/fuzz/src/crdt_fuzzer.rs:1033\u0060 calls \u0060unwrap\u0060 and \u0060crates/loro-internal/src/fuzz.rs:58\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":"crates/fuzz/src/crdt_fuzzer.rs"},"region":{"startLine":1024}}}],"partialFingerprints":{"codehealthFindingId/v1":"5dfcadf144f358dfac901641e63cf610074f3ac4811cc9fe404e58f6e77e950f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 3): crates/loro-internal/src/handler.rs:3688-3696 | crates/loro-internal/src/handler.rs:4383-4391 | crates/loro-internal/src/handler.rs:4993-5001 \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. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any \u0060return\u0060 inside it is the body\u0027s own exit and keeps its meaning in the moved unit."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/handler.rs"},"region":{"startLine":3688}}}],"partialFingerprints":{"codehealthFindingId/v1":"fcde1b83878b4c85caf8e80ac838286ff740c15cdcdd734ecee80b36d29b8010"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): crates/generic-btree/src/lib.rs:765-773 | crates/generic-btree/src/lib.rs:797-805 \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 \u0060crates/generic-btree/src/lib.rs:765\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":"crates/generic-btree/src/lib.rs"},"region":{"startLine":765}}}],"partialFingerprints":{"codehealthFindingId/v1":"7ded0854bf619ffa0bbc555b89ad3caf6bf0b042b6b892667198de53c05bd8c3"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): crates/loro-internal/src/diff_calc.rs:1071-1079 | crates/loro-internal/src/diff_calc.rs:1892-1900 \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 \u0060crates/loro-internal/src/diff_calc.rs:1071\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":"crates/loro-internal/src/diff_calc.rs"},"region":{"startLine":1071}}}],"partialFingerprints":{"codehealthFindingId/v1":"292ec5347e2a91e79e5e5ef66cd77508ab2120ec2bada307b22eeac68b94402e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): crates/loro-internal/src/encoding/shallow_snapshot.rs:1080-1088 | crates/loro-internal/src/encoding/shallow_snapshot.rs:1104-1112 \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 \u0060crates/loro-internal/src/encoding/shallow_snapshot.rs:1080\u0060 it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows \u2014 the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members\u0027 bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run \u2014 a one-line delegation has no helper inside it to lift \u2014 so generate the run from the set it enumerates, or accept it and keep each member\u0027s own documentation with it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/encoding/shallow_snapshot.rs"},"region":{"startLine":1080}}}],"partialFingerprints":{"codehealthFindingId/v1":"10f3f799ec03847857d82ac3f920bbacf7d9fa5cdfea326d6174595368b61540"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): crates/loro-internal/src/handler.rs:2029-2037 | crates/loro-internal/src/handler.rs:2053-2061 \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":"crates/loro-internal/src/handler.rs"},"region":{"startLine":2029}}}],"partialFingerprints":{"codehealthFindingId/v1":"f9c201128818f36d57315020fc9b83ee35f9cb4c8c7dcbb67924720886939b49"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): crates/loro-internal/src/handler.rs:3281-3289 | crates/loro-internal/src/handler.rs:3373-3381 \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":"crates/loro-internal/src/handler.rs"},"region":{"startLine":3281}}}],"partialFingerprints":{"codehealthFindingId/v1":"feea31a0c7c268c86df1b73844c0216fadb59fc9ecb4de117a68281b8e5ffc65"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): crates/loro-internal/src/handler.rs:3400-3411 | crates/loro-internal/src/handler.rs:4094-4105 \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. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any \u0060return\u0060 inside it is the body\u0027s own exit and keeps its meaning in the moved unit."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/handler.rs"},"region":{"startLine":3400}}}],"partialFingerprints":{"codehealthFindingId/v1":"5564f8294743f1e64c784255ff7c8e461f46787b0dcde6757794a5eb74d32564"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8\u20139 lines \u00D7 2): crates/loro-internal/src/loro.rs:917-925 | crates/loro-internal/src/loro.rs:1146-1153 \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 \u0060crates/loro-internal/src/loro.rs:917\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":"crates/loro-internal/src/loro.rs"},"region":{"startLine":917}}}],"partialFingerprints":{"codehealthFindingId/v1":"80555ccc82bcd319fe5d5d4044430225d1745572e84bc2738dc7e55606d56a8a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): crates/loro-internal/src/state.rs:2548-2556 | crates/loro-internal/src/state.rs:2614-2622 \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 \u0060crates/loro-internal/src/state.rs:2548\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":"crates/loro-internal/src/state.rs"},"region":{"startLine":2548}}}],"partialFingerprints":{"codehealthFindingId/v1":"2b651b89ee6f8b4e11d3f6418e506e61bf8c2162c68c4e8e2079771cad1066f2"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): crates/loro-internal/src/value.rs:289-297 | crates/loro-internal/src/value.rs:379-387 \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 \u0060crates/loro-internal/src/value.rs:289\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":"crates/loro-internal/src/value.rs"},"region":{"startLine":289}}}],"partialFingerprints":{"codehealthFindingId/v1":"0429b49798753b1a43f1ef3081b68e46381673d2dfe65b4b5e9afaf7fe574542"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): crates/loro-wasm-tools/src/main.rs:100-108 | crates/loro-wasm-tools/src/main.rs:148-156 \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":"crates/loro-wasm-tools/src/main.rs"},"region":{"startLine":100}}}],"partialFingerprints":{"codehealthFindingId/v1":"902ebd42a7eec05ddd864b8f68c431c6216872e9ee0c9db382a2b48f892f5ef2"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): crates/loro-wasm/src/awareness.rs:220-228 | crates/loro-wasm/src/lib.rs:2163-2171 \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 \u0060crates/loro-wasm/src/awareness.rs:220\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, 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":"crates/loro-wasm/src/awareness.rs"},"region":{"startLine":220}}}],"partialFingerprints":{"codehealthFindingId/v1":"7a0e3693eaa63f14dd733256148fb3c768e00ef71e55f35eed14d19f4ba750b2"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 6): crates/fuzz/src/crdt_fuzzer.rs:975-982 | crates/fuzz/src/crdt_fuzzer.rs:1023-1030 | crates/fuzz/src/crdt_fuzzer.rs:1099-1106 | crates/fuzz/src/crdt_fuzzer.rs:1121-1128 | crates/loro-internal/src/fuzz.rs:19-26 | crates/loro-internal/src/fuzz.rs:48-55 \u2014 before extracting anything, compare \u0060crates/fuzz/src/crdt_fuzzer.rs\u0060 and \u0060crates/loro-internal/src/fuzz.rs\u0060 as WHOLE FILES: this scan already matched 6 separate duplicated blocks between them, totalling at least 59 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. The two sit in different directories, so one cannot simply be deleted in favour of the other while both are reached separately: hoist the shared part into a location both already depend on and have each file call it, and retire whichever file turns out to have no caller of its own left. Extracting one helper per block leaves the fork in place."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/fuzz/src/crdt_fuzzer.rs"},"region":{"startLine":975}}}],"partialFingerprints":{"codehealthFindingId/v1":"d43242be3b63a013102eab748d14f8c16dc093c126ae67915d77cb95de718034"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 3): crates/loro-internal/src/encoding/shallow_snapshot.rs:509-516 | crates/loro-internal/src/encoding/shallow_snapshot.rs:540-547 | crates/loro-internal/src/encoding/shallow_snapshot.rs:844-851 \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 after the matched lines, \u0060crates/loro-internal/src/encoding/shallow_snapshot.rs:548\u0060 calls \u0060_checkout_without_emitting\u0060, \u0060map_err\u0060 and \u0060crates/loro-internal/src/encoding/shallow_snapshot.rs:518\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":"crates/loro-internal/src/encoding/shallow_snapshot.rs"},"region":{"startLine":509}}}],"partialFingerprints":{"codehealthFindingId/v1":"b4314d1d72f98b2a82d1e307fed2d69bd3905e955051762a65a27854c31c28be"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): crates/generic-btree/src/lib.rs:2091-2098 | crates/generic-btree/src/lib.rs:2113-2120 \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, \u0060crates/generic-btree/src/lib.rs:2112\u0060 calls \u0060take\u0060 and \u0060crates/generic-btree/src/lib.rs:2089\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":"crates/generic-btree/src/lib.rs"},"region":{"startLine":2091}}}],"partialFingerprints":{"codehealthFindingId/v1":"fac71ddd71df82a0529f5d992c4639ec9eb20da8d1435b3757b98697d1c33b24"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): crates/loro-internal/src/container/richtext/style_range_map.rs:192-199 | crates/loro-internal/src/container/richtext/style_range_map.rs:234-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. Read the line range as the matched WINDOW rather than a finished unit: at \u0060crates/loro-internal/src/container/richtext/style_range_map.rs:192\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":"crates/loro-internal/src/container/richtext/style_range_map.rs"},"region":{"startLine":192}}}],"partialFingerprints":{"codehealthFindingId/v1":"912f35f4510b5a63ddccc762bc2a6f1ff0636090c6c94a3cf5e236b024ded53b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): crates/loro-internal/src/container/richtext/style_range_map.rs:311-320 | crates/loro-internal/src/container/richtext/style_range_map.rs:342-351 \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":"crates/loro-internal/src/container/richtext/style_range_map.rs"},"region":{"startLine":311}}}],"partialFingerprints":{"codehealthFindingId/v1":"d8654f235a28f8f16dd849eb745246d10acac1c529a418ba5165c197f85c7199"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): crates/loro-internal/src/dag/iter.rs:80-87 | crates/loro-internal/src/dag/iter.rs:161-168 \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":"crates/loro-internal/src/dag/iter.rs"},"region":{"startLine":80}}}],"partialFingerprints":{"codehealthFindingId/v1":"c6a5eae6c2e73cb54964e59907c6ed31bafac6ece5c2fcc48161cd04f47255a2"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): crates/loro-internal/src/handler.rs:805-812 | crates/loro-internal/src/handler.rs:922-929 \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. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any \u0060return\u0060 inside it is the body\u0027s own exit and keeps its meaning in the moved unit."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/handler.rs"},"region":{"startLine":805}}}],"partialFingerprints":{"codehealthFindingId/v1":"e77faf4d525b5e0ef8581d747de3680748c4ead59c7ad298be8c0b66fb76126a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): crates/loro-internal/src/handler.rs:815-822 | crates/loro-internal/src/handler.rs:932-939 \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. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any \u0060return\u0060 inside it is the body\u0027s own exit and keeps its meaning in the moved unit."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/handler.rs"},"region":{"startLine":815}}}],"partialFingerprints":{"codehealthFindingId/v1":"04b98612d9527b41cf89c4292e730900fe304f155523d2013cd7a6479a0e18dc"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): crates/loro-internal/src/handler.rs:3322-3329 | crates/loro-internal/src/handler.rs:3892-3899 \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. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any \u0060return\u0060 inside it is the body\u0027s own exit and keeps its meaning in the moved unit."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/handler.rs"},"region":{"startLine":3322}}}],"partialFingerprints":{"codehealthFindingId/v1":"927109c0d09616f5699df5a1246e8410c290cdcd696ba2d01df00bbbe8b3a58b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): crates/loro-internal/src/handler.rs:3414-3421 | crates/loro-internal/src/handler.rs:4109-4116 \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":"crates/loro-internal/src/handler.rs"},"region":{"startLine":3414}}}],"partialFingerprints":{"codehealthFindingId/v1":"4ee5ea00135431808665754be14828abd7c0c5ac97c00f9b2a1ebd6ec12e8be4"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): crates/loro-internal/src/handler.rs:3756-3763 | crates/loro-internal/src/handler.rs:3951-3958 \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, \u0060crates/loro-internal/src/handler.rs:3754\u0060 calls \u0060ensure_no_regular_container_value\u0060 and \u0060crates/loro-internal/src/handler.rs:3949\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":"crates/loro-internal/src/handler.rs"},"region":{"startLine":3756}}}],"partialFingerprints":{"codehealthFindingId/v1":"176f643b43849d634881f37c33780e18ec1d8101fb106375dd7918d8de8bbb8c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): crates/loro-internal/src/handler.rs:4514-4521 | crates/loro-internal/src/handler.rs:4530-4537 \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 \u0060crates/loro-internal/src/handler.rs:4514\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":"crates/loro-internal/src/handler.rs"},"region":{"startLine":4514}}}],"partialFingerprints":{"codehealthFindingId/v1":"b1198b8a9070160ce46c2d835aba61d93de373d99189cd9afed3c4dbc60a9b13"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): crates/loro-internal/src/state/container_store/container_wrapper.rs:344-351 | crates/loro-internal/src/state/container_store/container_wrapper.rs:377-384 \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 \u0060crates/loro-internal/src/state/container_store/container_wrapper.rs:344\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":"crates/loro-internal/src/state/container_store/container_wrapper.rs"},"region":{"startLine":344}}}],"partialFingerprints":{"codehealthFindingId/v1":"d6a3c8fce76158c226f2557eebdefbdb4dbbd260f1146360b463aa268cfc5ebb"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 5): crates/fuzz/src/crdt_fuzzer.rs:1021-1028 | crates/fuzz/src/crdt_fuzzer.rs:1097-1104 | crates/fuzz/src/mem_kv_fuzzer.rs:288-295 | crates/loro-internal/src/fuzz.rs:17-24 | crates/loro-internal/src/fuzz.rs:46-53 \u2014 before extracting anything, compare \u0060crates/fuzz/src/crdt_fuzzer.rs\u0060 and \u0060crates/fuzz/src/mem_kv_fuzzer.rs\u0060 as WHOLE FILES: this scan already matched 4 separate duplicated blocks between them, totalling at least 51 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 \u0060crates/fuzz/src/crdt_fuzzer.rs:1021\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":"crates/fuzz/src/crdt_fuzzer.rs"},"region":{"startLine":1021}}}],"partialFingerprints":{"codehealthFindingId/v1":"50bd2c5efacccf087ea343047b60a995b21245432379f4b2b096985dcbf95964"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 5): crates/loro-internal/src/handler.rs:521-527 | crates/loro-internal/src/handler.rs:750-756 | crates/loro-internal/src/handler.rs:881-887 | crates/loro-internal/src/handler.rs:991-997 | crates/loro-internal/src/handler/tree.rs:304-310 \u2014 before extracting anything, compare \u0060crates/loro-internal/src/handler.rs\u0060 and \u0060crates/loro-internal/src/handler/tree.rs\u0060 as WHOLE FILES: this scan already matched 5 separate duplicated blocks between them, totalling at least 34 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. The two sit in different directories, so one cannot simply be deleted in favour of the other while both are reached separately: hoist the shared part into a location both already depend on and have each file call it, and retire whichever file turns out to have no caller of its own left. Extracting one helper per block leaves the fork in place. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any \u0060return\u0060 inside it is the body\u0027s own exit and keeps its meaning in the moved unit."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/handler.rs"},"region":{"startLine":521}}}],"partialFingerprints":{"codehealthFindingId/v1":"60bef037f33f7286d155efef8a394ae9acb801cfdf5e0034d3f8745ae571f9ed"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (4\u20137 lines \u00D7 3): crates/loro-internal/src/handler.rs:3382-3388 | crates/loro-internal/src/handler.rs:3959-3965 | crates/loro-internal/src/handler.rs:4056-4059 \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 \u0060crates/loro-internal/src/handler.rs:3382\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":"crates/loro-internal/src/handler.rs"},"region":{"startLine":3382}}}],"partialFingerprints":{"codehealthFindingId/v1":"678aa3e68c358a016c9b776f1391bd14f82bb629b4b6f6197d4f98b181170aba"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): crates/loro-internal/src/oplog/change_store/block_encode.rs:328-334 | crates/loro-internal/src/oplog/change_store/block_encode.rs:340-346 \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 \u0060crates/loro-internal/src/oplog/change_store/block_encode.rs:328\u0060 it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows \u2014 the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members\u0027 bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run \u2014 a one-line delegation has no helper inside it to lift \u2014 so generate the run from the set it enumerates, or accept it and keep each member\u0027s own documentation with it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/oplog/change_store/block_encode.rs"},"region":{"startLine":328}}}],"partialFingerprints":{"codehealthFindingId/v1":"2e0997b69e3336701a881f783238d356e51e7a4c22c9227b0c5ebfbcb0cfed19"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): crates/loro-internal/src/state.rs:76-82 | crates/loro-internal/src/state/container_store/container_wrapper.rs:819-825 \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 \u0060crates/loro-internal/src/state.rs:76\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":"crates/loro-internal/src/state.rs"},"region":{"startLine":76}}}],"partialFingerprints":{"codehealthFindingId/v1":"7c897023389ba0ff6677d49136aebdfe01bb451d5b6fe84c400b31fdc6b62670"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): crates/loro-internal/src/value.rs:81-87 | crates/loro-internal/src/value.rs:163-169 \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 \u0060crates/loro-internal/src/value.rs:81\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":"crates/loro-internal/src/value.rs"},"region":{"startLine":81}}}],"partialFingerprints":{"codehealthFindingId/v1":"ebe9e58dd85f528afcef680fa3d1a19cbd29a15fb98e813c829ddf07ca8fdccd"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 3): crates/loro-wasm-tools/src/main.rs:126-131 | crates/loro-wasm-tools/src/main.rs:172-177 | crates/loro-wasm-tools/src/main.rs:240-245 \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, \u0060crates/loro-wasm-tools/src/main.rs:237\u0060 calls \u0060sort_by_key\u0060 and \u0060crates/loro-wasm-tools/src/main.rs:168\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":"crates/loro-wasm-tools/src/main.rs"},"region":{"startLine":126}}}],"partialFingerprints":{"codehealthFindingId/v1":"e0217619c8f3143d8ebaaa69e4a5faa5c076433d5afa40dba19b0d2371806628"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): crates/kv-store/src/block.rs:757-764 | crates/kv-store/src/block.rs:781-788 \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 \u0060crates/kv-store/src/block.rs:757\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":"crates/kv-store/src/block.rs"},"region":{"startLine":757}}}],"partialFingerprints":{"codehealthFindingId/v1":"8d8a10bf4df6c6d52a8530e668fbd26f8e0b7876268741f5dd0caf02122dc285"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): crates/loro-internal/src/diff_calc.rs:1048-1053 | crates/loro-internal/src/diff_calc.rs:1877-1882 \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 \u0060crates/loro-internal/src/diff_calc.rs:1048\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":"crates/loro-internal/src/diff_calc.rs"},"region":{"startLine":1048}}}],"partialFingerprints":{"codehealthFindingId/v1":"cddd6ab31810d3a0bf8658fd7d40791f4a4ae67f4396f60fa87883599e5bd9ea"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): crates/loro-internal/src/handler.rs:1144-1149 | crates/loro-internal/src/handler.rs:1361-1366 \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 \u0060crates/loro-internal/src/handler.rs:1144\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, 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, \u0060crates/loro-internal/src/handler.rs:1360\u0060 calls \u0060Text\u0060, \u0060get_deep_value\u0060 and \u0060crates/loro-internal/src/handler.rs:1143\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":"crates/loro-internal/src/handler.rs"},"region":{"startLine":1144}}}],"partialFingerprints":{"codehealthFindingId/v1":"c2e9f6447897352c8775dc4c5a9a96a7a55193adef0625a6d81460074a6e6eca"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): crates/loro-internal/src/handler.rs:3292-3297 | crates/loro-internal/src/handler.rs:3386-3391 \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 \u0060crates/loro-internal/src/handler.rs:3292\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":"crates/loro-internal/src/handler.rs"},"region":{"startLine":3292}}}],"partialFingerprints":{"codehealthFindingId/v1":"c951c24c301b231e44af5cd0ec7f42458e2f6404ed2673622208dac746f6107e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): crates/loro-internal/src/handler.rs:3764-3769 | crates/loro-internal/src/handler.rs:3963-3968 \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 \u0060crates/loro-internal/src/handler.rs:3764\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":"crates/loro-internal/src/handler.rs"},"region":{"startLine":3764}}}],"partialFingerprints":{"codehealthFindingId/v1":"3c14abfa3fe83fdeef51bff0a21cb07191bcdf4abe78477b4ae6ce2d9bad1378"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): crates/loro-internal/src/handler/tree.rs:409-414 | crates/loro-internal/src/handler/tree.rs:435-440 \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 \u0060crates/loro-internal/src/handler/tree.rs:409\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":"crates/loro-internal/src/handler/tree.rs"},"region":{"startLine":409}}}],"partialFingerprints":{"codehealthFindingId/v1":"6f794dbaced35a7b4a7d8223934384b3eacf2753de736cbe4963b67fb7a825b3"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): crates/loro-internal/src/state/container_store/inner_store.rs:361-368 | crates/loro-internal/src/state/container_store/inner_store.rs:388-395 \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 \u0060crates/loro-internal/src/state/container_store/inner_store.rs:361\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 first that the copies are not typed on the same thing: the declarations holding them bind \u0060self\u0060 to \u0060crate) fn try_get_parent_and_value_ephemeral( \u0026mut\u0060 in one and \u0060crate) fn try_get_parent_and_tree_meta_ids_ephemeral( \u0026mut\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":"crates/loro-internal/src/state/container_store/inner_store.rs"},"region":{"startLine":361}}}],"partialFingerprints":{"codehealthFindingId/v1":"d97a3491e80642e892308d5bd0d7b42aaf2b03d09f7b7d52553538306f91e9c4"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): crates/loro/src/event.rs:175-180 | crates/loro/src/event.rs:228-233 \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 \u0060crates/loro/src/event.rs:175\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":"crates/loro/src/event.rs"},"region":{"startLine":175}}}],"partialFingerprints":{"codehealthFindingId/v1":"7b5eab65a16631df91f360f146a9170c304d061bb101eb43686c3f4ca9dcae06"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 3): crates/loro-internal/src/state/list_state.rs:786-790 | crates/loro-internal/src/state/movable_list_state.rs:1606-1610 | crates/loro-internal/src/state/tree_state.rs:1960-1964 \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":"crates/loro-internal/src/state/list_state.rs"},"region":{"startLine":786}}}],"partialFingerprints":{"codehealthFindingId/v1":"c22277c77afe295eb80766e79d902935d997f3a57690b9280d100df7b8ecab67"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): crates/dev-utils/src/lib.rs:79-86 | crates/dev-utils/src/lib.rs:91-98 \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. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any \u0060return\u0060 inside it is the body\u0027s own exit and keeps its meaning in the moved unit."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/dev-utils/src/lib.rs"},"region":{"startLine":79}}}],"partialFingerprints":{"codehealthFindingId/v1":"4c09774d458330e11752b041f6d8f319f30e8d4f4fc6f77fe20737888c82cf32"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): crates/loro-internal/src/diff/diff_impl.rs:208-213 | crates/loro-internal/src/diff/diff_impl.rs:237-242 \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 \u0060crates/loro-internal/src/diff/diff_impl.rs:208\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":"crates/loro-internal/src/diff/diff_impl.rs"},"region":{"startLine":208}}}],"partialFingerprints":{"codehealthFindingId/v1":"73e04e556de0546bf9ef4cd21a6d7a5e1d257e71f2402fdcebcde168e2edb5e3"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): crates/loro-internal/src/handler.rs:673-677 | crates/loro-internal/src/handler.rs:687-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. Read the line range as the matched WINDOW rather than a finished unit: at \u0060crates/loro-internal/src/handler.rs:673\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":"crates/loro-internal/src/handler.rs"},"region":{"startLine":673}}}],"partialFingerprints":{"codehealthFindingId/v1":"e5a695b2ab660947645cad295ce6253a2fb676c0fcd0cdbfae12aaa63fd5ba29"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): crates/loro-internal/src/history_cache.rs:864-868 | crates/loro-internal/src/history_cache.rs:886-890 \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 \u0060crates/loro-internal/src/history_cache.rs:864\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":"crates/loro-internal/src/history_cache.rs"},"region":{"startLine":864}}}],"partialFingerprints":{"codehealthFindingId/v1":"9b25f3036983cc24d8e3df28efb648a4d33c9f4940088df928893d91010893c1"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): crates/loro-internal/src/oplog/change_store.rs:1231-1236 | crates/loro-internal/src/oplog/change_store.rs:1266-1271 \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":"crates/loro-internal/src/oplog/change_store.rs"},"region":{"startLine":1231}}}],"partialFingerprints":{"codehealthFindingId/v1":"f702e1ffa50ffab48a54bc90e081bf21d1f7881d7c6b568c92ba1eff36c79f3e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): crates/loro-internal/src/value.rs:50-54 | crates/loro-internal/src/value.rs:118-122 \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":"crates/loro-internal/src/value.rs"},"region":{"startLine":50}}}],"partialFingerprints":{"codehealthFindingId/v1":"64e7d61c8208bad9572eea9d2416b4e137f4f4c7d22f5a4bfe322e7701427019"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): crates/loro-internal/src/value.rs:61-65 | crates/loro-internal/src/value.rs:133-137 \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":"crates/loro-internal/src/value.rs"},"region":{"startLine":61}}}],"partialFingerprints":{"codehealthFindingId/v1":"dbbc8cf7cbb6b9a1b7e6f67623f319e0082c17fa9b36e9b68bc6484070128e1e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): crates/loro-internal/src/value.rs:92-98 | crates/loro-internal/src/value.rs:174-180 \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 \u0060crates/loro-internal/src/value.rs:92\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":"crates/loro-internal/src/value.rs"},"region":{"startLine":92}}}],"partialFingerprints":{"codehealthFindingId/v1":"3bda9c63c2e296d3ae9ec5c3aa656ecb7ffd6b819050938d145b85c345862371"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): crates/delta/src/delta_rope/rle_tree.rs:83-88 | crates/loro-internal/src/container/richtext/style_range_map.rs:584-589 \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 \u0060crates/delta/src/delta_rope/rle_tree.rs:83\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":"crates/delta/src/delta_rope/rle_tree.rs"},"region":{"startLine":83}}}],"partialFingerprints":{"codehealthFindingId/v1":"03b2a13b6348e2844444a7b7d3ae701e7f64ea6a105de47eef2cdcfa5427ed0f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): crates/loro-internal/src/delta/text.rs:91-95 | crates/loro-internal/src/event.rs:359-363 \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":"crates/loro-internal/src/delta/text.rs"},"region":{"startLine":91}}}],"partialFingerprints":{"codehealthFindingId/v1":"df9d3fe0179d4aa8b2f1192bed90d17204ed57d8ef89686dc59f4e0ab9361a2f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 6): crates/loro-internal/src/handler.rs:536-541 | crates/loro-internal/src/handler.rs:765-770 | crates/loro-internal/src/handler.rs:889-894 | crates/loro-internal/src/handler.rs:1006-1011 | crates/loro-internal/src/handler.rs:5244-5249 | crates/loro-internal/src/handler/tree.rs:319-324 \u2014 before extracting anything, compare \u0060crates/loro-internal/src/handler.rs\u0060 and \u0060crates/loro-internal/src/handler/tree.rs\u0060 as WHOLE FILES: this scan already matched 5 separate duplicated blocks between them, totalling at least 34 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. The two sit in different directories, so one cannot simply be deleted in favour of the other while both are reached separately: hoist the shared part into a location both already depend on and have each file call it, and retire whichever file turns out to have no caller of its own left. Extracting one helper per block leaves the fork in place."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/handler.rs"},"region":{"startLine":536}}}],"partialFingerprints":{"codehealthFindingId/v1":"6ceacc57ebb937ba508d385197282780eac7364d3005deb687f9072e542b20ba"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 4): crates/loro-internal/src/handler.rs:2828-2833 | crates/loro-internal/src/handler.rs:3500-3505 | crates/loro-internal/src/handler.rs:4213-4218 | crates/loro-internal/src/handler/tree.rs:359-364 \u2014 before extracting anything, compare \u0060crates/loro-internal/src/handler.rs\u0060 and \u0060crates/loro-internal/src/handler/tree.rs\u0060 as WHOLE FILES: this scan already matched 5 separate duplicated blocks between them, totalling at least 34 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. The two sit in different directories, so one cannot simply be deleted in favour of the other while both are reached separately: hoist the shared part into a location both already depend on and have each file call it, and retire whichever file turns out to have no caller of its own left. Extracting one helper per block leaves the fork in place."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/handler.rs"},"region":{"startLine":2828}}}],"partialFingerprints":{"codehealthFindingId/v1":"63e2bc84ee139773248cc9ea6009064d8d109204de60f8ebe357401759872860"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 6): crates/loro-internal/src/handler.rs:2950-2955 | crates/loro-internal/src/handler.rs:3680-3685 | crates/loro-internal/src/handler.rs:4375-4380 | crates/loro-internal/src/handler.rs:4985-4990 | crates/loro-internal/src/handler.rs:5147-5152 | crates/loro-internal/src/handler/tree.rs:1149-1154 \u2014 before extracting anything, compare \u0060crates/loro-internal/src/handler.rs\u0060 and \u0060crates/loro-internal/src/handler/tree.rs\u0060 as WHOLE FILES: this scan already matched 5 separate duplicated blocks between them, totalling at least 34 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. The two sit in different directories, so one cannot simply be deleted in favour of the other while both are reached separately: hoist the shared part into a location both already depend on and have each file call it, and retire whichever file turns out to have no caller of its own left. Extracting one helper per block leaves the fork in place. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, \u0060crates/loro-internal/src/handler.rs:2957\u0060 calls \u0060push_str\u0060, \u0060insert_utf8\u0060, \u0060len_utf8\u0060 and \u0060crates/loro-internal/src/handler.rs:3687\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":"crates/loro-internal/src/handler.rs"},"region":{"startLine":2950}}}],"partialFingerprints":{"codehealthFindingId/v1":"03d30f0568de14877775927db13d2639dd6d3b70598ce0368c6397856adf4456"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): crates/loro-internal/src/handler/movable_list_apply_delta.rs:355-361 | crates/loro-internal/src/loro.rs:5465-5471 \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":"crates/loro-internal/src/handler/movable_list_apply_delta.rs"},"region":{"startLine":355}}}],"partialFingerprints":{"codehealthFindingId/v1":"e8b5083702e6d4343a177362a1c89b4d25d7d12ff44b2c5d6f3ffc6afe665727"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): crates/loro-wasm/src/counter.rs:91-97 | crates/loro-wasm/src/lib.rs:5656-5662 \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":"crates/loro-wasm/src/counter.rs"},"region":{"startLine":91}}}],"partialFingerprints":{"codehealthFindingId/v1":"cca18fef41cfd4d0b233ccfc7ecb836a1056adc98c0e93f10bdc56f683c9ed8c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): crates/kv-store/src/block.rs:848-856 | crates/kv-store/src/sstable.rs:908-916 \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":"crates/kv-store/src/block.rs"},"region":{"startLine":848}}}],"partialFingerprints":{"codehealthFindingId/v1":"0a2d26b9ffa60525b9345384aede0d96287d016a432275e0876fd6acba7039c6"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 5): crates/loro-internal/src/awareness.rs:814-818 | crates/loro-internal/src/loro.rs:2877-2881 | crates/loro-internal/src/loro.rs:4066-4073 | crates/loro-internal/src/loro.rs:4079-4083 | crates/loro-internal/src/subscription.rs:25-29 \u2014 there are 5 copies across 3 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 5 sites; resolving a subset leaves the remainder to drift apart. Read the line range as the matched WINDOW rather than a finished unit: at \u0060crates/loro-internal/src/loro.rs:4066\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 first that the copies are not typed on the same thing: the declarations holding them bind \u0060callback\u0060 to \u0060LocalEphemeralCallback\u0060 in one and \u0060LocalUpdateCallback\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":"crates/loro-internal/src/awareness.rs"},"region":{"startLine":814}}}],"partialFingerprints":{"codehealthFindingId/v1":"c05ee4ac618bcc8ac43aa535604c7fc10c6c59549388df98e710cfbea4539c54"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): crates/loro-internal/src/container/richtext/style_range_map.rs:559-566 | crates/loro-internal/src/container/richtext/tracker/id_to_cursor.rs:801-808 \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":"crates/loro-internal/src/container/richtext/style_range_map.rs"},"region":{"startLine":559}}}],"partialFingerprints":{"codehealthFindingId/v1":"566bb8b9ab0d4aef511e338098eb96a89b8873d25a368930a987c263cc2e6e65"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): crates/loro-internal/src/delta/map_delta.rs:27-31 | crates/loro-internal/src/history_cache.rs:618-622 \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":"crates/loro-internal/src/delta/map_delta.rs"},"region":{"startLine":27}}}],"partialFingerprints":{"codehealthFindingId/v1":"039df72a9993bddfacf8a26d24593c1eced4c5b54ba871355126f7f66c430b7a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): crates/loro-internal/src/handler.rs:5062-5070 | crates/loro-internal/src/handler/tree.rs:1169-1177 \u2014 before extracting anything, compare \u0060crates/loro-internal/src/handler.rs\u0060 and \u0060crates/loro-internal/src/handler/tree.rs\u0060 as WHOLE FILES: this scan already matched 5 separate duplicated blocks between them, totalling at least 34 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. The two sit in different directories, so one cannot simply be deleted in favour of the other while both are reached separately: hoist the shared part into a location both already depend on and have each file call it, and retire whichever file turns out to have no caller of its own left. Extracting one helper per block leaves the fork in place."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/handler.rs"},"region":{"startLine":5062}}}],"partialFingerprints":{"codehealthFindingId/v1":"2bee13965b523e9d145e1719877a7c89e6dd08136ba8d06bb73b41ede77312be"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (20 lines \u00D7 2): crates/loro-internal/src/state/movable_list_state.rs:1675-1694 | crates/loro-internal/src/state/movable_list_state.rs:1770-1789 \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 \u0060crates/loro-internal/src/state/movable_list_state.rs:1675\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":"crates/loro-internal/src/state/movable_list_state.rs"},"region":{"startLine":1675}}}],"partialFingerprints":{"codehealthFindingId/v1":"1cd82218d4a71525e7ef4a71fe876a23b4a7f0e9c741de153a588e604114c8fe"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): crates/loro-wasm/src/awareness.rs:241-252 | crates/loro-wasm/src/awareness.rs:261-272 \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 \u0060crates/loro-wasm/src/awareness.rs:241\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":"crates/loro-wasm/src/awareness.rs"},"region":{"startLine":241}}}],"partialFingerprints":{"codehealthFindingId/v1":"0ab42ea24e602538140c790ff08dc77f929b68a53cbe9bea3365aca7bec62aa1"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): crates/loro-internal/src/state/richtext_state.rs:709-718 | crates/loro-internal/src/state/richtext_state.rs:735-744 \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 \u0060crates/loro-internal/src/state/richtext_state.rs:709\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":"crates/loro-internal/src/state/richtext_state.rs"},"region":{"startLine":709}}}],"partialFingerprints":{"codehealthFindingId/v1":"75f445256fab3d5943b07952d77420c056696675e29c413b115a33d09cbccec6"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): crates/loro-internal/src/encoding/json_schema.rs:855-864 | crates/loro-internal/src/encoding/json_schema.rs:891-900 \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. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any \u0060return\u0060 inside it is the body\u0027s own exit and keeps its meaning in the moved unit."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/encoding/json_schema.rs"},"region":{"startLine":855}}}],"partialFingerprints":{"codehealthFindingId/v1":"3bcd2eb815cefcfb0d005009abcb85f62a901a44cb560621f53e436b7f7b3904"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): crates/loro-internal/src/encoding/json_schema.rs:952-960 | crates/loro-internal/src/encoding/json_schema.rs:973-981 \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 \u0060crates/loro-internal/src/encoding/json_schema.rs:952\u0060 it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows \u2014 the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members\u0027 bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run \u2014 a one-line delegation has no helper inside it to lift \u2014 so generate the run from the set it enumerates, or accept it and keep each member\u0027s own documentation with it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/encoding/json_schema.rs"},"region":{"startLine":952}}}],"partialFingerprints":{"codehealthFindingId/v1":"0b712f5553492a6691b31a4a755786250a4ee35727e45bd04da2e14dd962b574"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 3): crates/loro-internal/src/encoding/fast_snapshot.rs:73-80 | crates/loro-internal/src/encoding/fast_snapshot.rs:82-89 | crates/loro-internal/src/encoding/fast_snapshot.rs:96-103 \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":"crates/loro-internal/src/encoding/fast_snapshot.rs"},"region":{"startLine":73}}}],"partialFingerprints":{"codehealthFindingId/v1":"04fe9c8eb721753ad12a35e22ea0de2a2a639dd4d301bc715c28df3b1df2784b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): crates/loro-wasm/src/convert.rs:696-703 | crates/loro-wasm/src/convert.rs:720-727 \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 \u0060crates/loro-wasm/src/convert.rs:696\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":"crates/loro-wasm/src/convert.rs"},"region":{"startLine":696}}}],"partialFingerprints":{"codehealthFindingId/v1":"c6ac2f3a97086a011603130145e5a4697bc74fbf887cfd8aa2e712e5eeba7f1f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): crates/loro-wasm/src/convert.rs:571-575 | crates/loro-wasm/src/convert.rs:628-632 \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 \u0060crates/loro-wasm/src/convert.rs:571\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":"crates/loro-wasm/src/convert.rs"},"region":{"startLine":571}}}],"partialFingerprints":{"codehealthFindingId/v1":"283954814c26083a7dc0a7afe88281deee73d10773dcc78bb15b08762a35e45d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): crates/loro-internal/src/oplog/change_store/block_encode.rs:472-476 | crates/loro-internal/src/oplog/change_store/block_encode.rs:477-481 \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":"crates/loro-internal/src/oplog/change_store/block_encode.rs"},"region":{"startLine":472}}}],"partialFingerprints":{"codehealthFindingId/v1":"7a16fd5eef071e3d2e627cf98fe36ebebd7159cc598756e2cab65202eb378c1b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): crates/loro-internal/src/oplog/change_store/block_encode.rs:482-486 | crates/loro-internal/src/oplog/change_store/block_encode.rs:487-491 \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":"crates/loro-internal/src/oplog/change_store/block_encode.rs"},"region":{"startLine":482}}}],"partialFingerprints":{"codehealthFindingId/v1":"74e741887acaed46866493846cec67f89c3af875a02a3b40828faccd2f1ca338"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): crates/loro-internal/src/container/richtext/style_range_map.rs:58-62 | crates/loro-internal/src/container/richtext/style_range_map.rs:66-70 \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 \u0060crates/loro-internal/src/container/richtext/style_range_map.rs:58\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":"crates/loro-internal/src/container/richtext/style_range_map.rs"},"region":{"startLine":58}}}],"partialFingerprints":{"codehealthFindingId/v1":"af09e4db751909ca9e03ae3d28e4e55cb2ae2a9f82ec629c8fb2892cfaf61f9f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): crates/loro-internal/src/encoding/value.rs:646-653 | crates/loro-internal/src/encoding/value.rs:750-757 \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 \u0060crates/loro-internal/src/encoding/value.rs:646\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":"crates/loro-internal/src/encoding/value.rs"},"region":{"startLine":646}}}],"partialFingerprints":{"codehealthFindingId/v1":"a801347ac1ac031ba7d5c64cc0590b82f9a3c4bc0dbdad195b01bbc0d0e1b197"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): crates/loro-internal/src/state/container_store/inner_store.rs:144-148 | crates/loro-internal/src/state/container_store/inner_store.rs:187-191 \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 \u0060crates/loro-internal/src/state/container_store/inner_store.rs:144\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 first that the copies are not typed on the same thing: the declarations holding them bind \u0060self\u0060 to \u0060super) fn ensure_container( \u0026mut\u0060 in one and \u0060crate) fn get_mut(\u0026mut\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":"crates/loro-internal/src/state/container_store/inner_store.rs"},"region":{"startLine":144}}}],"partialFingerprints":{"codehealthFindingId/v1":"7fc0e7ea0366047c411ebc6eb539239e82438051f0b8474e2485e66d3d1a3ec1"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): crates/loro-internal/src/state/value_decode.rs:106-113 | crates/loro-internal/src/state/value_decode.rs:137-144 \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 \u0060crates/loro-internal/src/state/value_decode.rs:106\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":"crates/loro-internal/src/state/value_decode.rs"},"region":{"startLine":106}}}],"partialFingerprints":{"codehealthFindingId/v1":"fd81c77042ceace422d83ea240ed288cfa9f9509e88b38c230332324bc393423"}},{"ruleId":"D4","level":"warning","message":{"text":"Near-duplicate member pair (112 shared lines): crates/fuzz/src/crdt_fuzzer.rs:143-465 | crates/fuzz/src/one_doc_fuzzer.rs:436-902 \u2014 These two members are variants of one another: 112 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":"crates/fuzz/src/crdt_fuzzer.rs"},"region":{"startLine":143}}}],"partialFingerprints":{"codehealthFindingId/v1":"6cd5715ef42d7df737fc6f8148772d4af4cbc173203a8099655fb30917aa3a48"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (6 members, 25\u002B corresponding lines): crates/fuzz/src/container/counter.rs:28-58 | crates/fuzz/src/container/list.rs:29-59 | crates/fuzz/src/container/map.rs:24-50 | crates/fuzz/src/container/movable_list.rs:30-57 | crates/fuzz/src/container/text.rs:40-64 | crates/fuzz/src/container/tree.rs:117-149 \u2014 These 6 members are one piece of code written 6 times and then edited apart: every two of them correspond over at least 25 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":"crates/fuzz/src/container/counter.rs"},"region":{"startLine":28}}}],"partialFingerprints":{"codehealthFindingId/v1":"af0897b7752760266ac1a030fbbd298461882d6818b0a8a86d7b2dc1ffaaed1b"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (14 corresponding lines): crates/fuzz/src/actor.rs:113-128 | crates/fuzz/src/actor.rs:130-143 \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":"crates/fuzz/src/actor.rs"},"region":{"startLine":113}}}],"partialFingerprints":{"codehealthFindingId/v1":"0a7b666c9295c4ab709bb41e5a56f84e87bde5b503ac0ea5ba6dbd131ff388a8"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (19 corresponding lines): crates/fuzz/src/crdt_fuzzer.rs:678-701 | crates/fuzz/src/one_doc_fuzzer.rs:938-956 \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":"crates/fuzz/src/crdt_fuzzer.rs"},"region":{"startLine":678}}}],"partialFingerprints":{"codehealthFindingId/v1":"6ddad2d2340c1b8c5b1e939a32a6719fb518b0bbc349d157a0f785a6ac8e614b"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (17 corresponding lines): crates/fuzz/src/actor.rs:145-162 | crates/fuzz/src/actor.rs:164-180 \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":"crates/fuzz/src/actor.rs"},"region":{"startLine":145}}}],"partialFingerprints":{"codehealthFindingId/v1":"2df65ed03f8371307d8e6fa185a56c91c9e6921416828f8be8f95ecd10541f37"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 6\u002B corresponding lines): crates/fuzz/src/container/list.rs:77-82 | crates/fuzz/src/container/map.rs:73-82 | crates/fuzz/src/container/tree.rs:157-167 \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":"crates/fuzz/src/container/list.rs"},"region":{"startLine":77}}}],"partialFingerprints":{"codehealthFindingId/v1":"9ae06c40579f3b9c3c201a59066e606c2215673cb77d580d9f7146b74962eb24"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (11 corresponding lines): crates/fuzz/src/container/tree.rs:482-492 | crates/fuzz/src/container/tree.rs:494-504 \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":"crates/fuzz/src/container/tree.rs"},"region":{"startLine":482}}}],"partialFingerprints":{"codehealthFindingId/v1":"5adb01e28da4682e3caa219e668884378e2c3fde58e8dd3a765e8d98fa7d935d"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 9\u002B corresponding lines): crates/fuzz/src/container/list.rs:61-69 | crates/fuzz/src/container/map.rs:52-60 | crates/fuzz/src/container/movable_list.rs:59-67 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 9 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\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":"crates/fuzz/src/container/list.rs"},"region":{"startLine":61}}}],"partialFingerprints":{"codehealthFindingId/v1":"12a92b78a0c43ae883b8f082cff061bd330a13d0981281b23b5976ec31b08ff5"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (33 lines \u00D7 2): crates/fuzz/src/crdt_fuzzer.rs:288-320 | crates/fuzz/src/one_doc_fuzzer.rs:719-751 \u2014 before extracting anything, compare \u0060crates/fuzz/src/crdt_fuzzer.rs\u0060 and \u0060crates/fuzz/src/one_doc_fuzzer.rs\u0060 as WHOLE FILES: this scan already matched 11 separate duplicated blocks between them, totalling at least 190 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 \u0060crates/fuzz/src/crdt_fuzzer.rs:288\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, 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":"crates/fuzz/src/crdt_fuzzer.rs"},"region":{"startLine":288}}}],"partialFingerprints":{"codehealthFindingId/v1":"c429dc63f07d059cc8600f2fb8118e6d886f274272f448ccd021fb31fcbd0a1c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (25\u201329 lines \u00D7 2): crates/fuzz/src/container/counter.rs:98-126 | crates/fuzz/src/container/counter.rs:128-152 \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 \u0060crates/fuzz/src/container/counter.rs:98\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":"crates/fuzz/src/container/counter.rs"},"region":{"startLine":98}}}],"partialFingerprints":{"codehealthFindingId/v1":"0fa0bc539cfe304f4c8dc4b32ef403df4aef095b43d574e25faa0397e76d6167"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (25 lines \u00D7 2): crates/fuzz/src/crdt_fuzzer.rs:360-384 | crates/fuzz/src/one_doc_fuzzer.rs:791-815 \u2014 before extracting anything, compare \u0060crates/fuzz/src/crdt_fuzzer.rs\u0060 and \u0060crates/fuzz/src/one_doc_fuzzer.rs\u0060 as WHOLE FILES: this scan already matched 11 separate duplicated blocks between them, totalling at least 190 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 \u0060crates/fuzz/src/crdt_fuzzer.rs:360\u0060 it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows \u2014 the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members\u0027 bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run \u2014 a one-line delegation has no helper inside it to lift \u2014 so generate the run from the set it enumerates, or accept it and keep each member\u0027s own documentation with it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/fuzz/src/crdt_fuzzer.rs"},"region":{"startLine":360}}}],"partialFingerprints":{"codehealthFindingId/v1":"fa079875e3f57e11d2723d62458f5ce1493ccc896418e4854beba6aad6ca8f60"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (20\u201323 lines \u00D7 2): crates/fuzz/src/crdt_fuzzer.rs:760-782 | crates/fuzz/src/crdt_fuzzer.rs:846-865 \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 \u0060crates/fuzz/src/crdt_fuzzer.rs:846\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, 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":"crates/fuzz/src/crdt_fuzzer.rs"},"region":{"startLine":760}}}],"partialFingerprints":{"codehealthFindingId/v1":"da7aa5bc70aed7f36e0b622e87a5c07bcc6089b3955ac4438e359d771d06be0e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (21 lines \u00D7 2): crates/fuzz/src/crdt_fuzzer.rs:121-141 | crates/fuzz/src/one_doc_fuzzer.rs:414-434 \u2014 before extracting anything, compare \u0060crates/fuzz/src/crdt_fuzzer.rs\u0060 and \u0060crates/fuzz/src/one_doc_fuzzer.rs\u0060 as WHOLE FILES: this scan already matched 11 separate duplicated blocks between them, totalling at least 190 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 \u0060crates/fuzz/src/crdt_fuzzer.rs:121\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, 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":"crates/fuzz/src/crdt_fuzzer.rs"},"region":{"startLine":121}}}],"partialFingerprints":{"codehealthFindingId/v1":"59396ddce60c85865cc1795b8125a7b21cd31d3c8a16db5a5517baeeda32b0c0"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (21 lines \u00D7 2): crates/fuzz/src/crdt_fuzzer.rs:1106-1126 | crates/fuzz/src/mem_kv_fuzzer.rs:297-317 \u2014 before extracting anything, compare \u0060crates/fuzz/src/crdt_fuzzer.rs\u0060 and \u0060crates/fuzz/src/mem_kv_fuzzer.rs\u0060 as WHOLE FILES: this scan already matched 4 separate duplicated blocks between them, totalling at least 51 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 \u0060crates/fuzz/src/crdt_fuzzer.rs:1106\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":"crates/fuzz/src/crdt_fuzzer.rs"},"region":{"startLine":1106}}}],"partialFingerprints":{"codehealthFindingId/v1":"95e323d5a79871d399d1458018a9ee8c946c2b56b094132f5468170752eac7b0"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (20 lines \u00D7 2): crates/fuzz/src/crdt_fuzzer.rs:146-165 | crates/fuzz/src/crdt_fuzzer.rs:224-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. Read the line range as the matched WINDOW rather than a finished unit: at \u0060crates/fuzz/src/crdt_fuzzer.rs:146\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":"crates/fuzz/src/crdt_fuzzer.rs"},"region":{"startLine":146}}}],"partialFingerprints":{"codehealthFindingId/v1":"5867dba1645fe79b124d38ed6114e8d2192b01ae84f983533f8d99a231548372"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (19 lines \u00D7 2): crates/fuzz/src/crdt_fuzzer.rs:323-341 | crates/fuzz/src/one_doc_fuzzer.rs:754-772 \u2014 before extracting anything, compare \u0060crates/fuzz/src/crdt_fuzzer.rs\u0060 and \u0060crates/fuzz/src/one_doc_fuzzer.rs\u0060 as WHOLE FILES: this scan already matched 11 separate duplicated blocks between them, totalling at least 190 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 \u0060crates/fuzz/src/crdt_fuzzer.rs:323\u0060 it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows \u2014 the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members\u0027 bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run \u2014 a one-line delegation has no helper inside it to lift \u2014 so generate the run from the set it enumerates, or accept it and keep each member\u0027s own documentation with it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/fuzz/src/crdt_fuzzer.rs"},"region":{"startLine":323}}}],"partialFingerprints":{"codehealthFindingId/v1":"c2f197c1bcf5c7a470982f4d96c63a0847d75474730fe1adb03709e62c640013"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (19 lines \u00D7 2): crates/fuzz/src/crdt_fuzzer.rs:386-404 | crates/fuzz/src/one_doc_fuzzer.rs:817-835 \u2014 before extracting anything, compare \u0060crates/fuzz/src/crdt_fuzzer.rs\u0060 and \u0060crates/fuzz/src/one_doc_fuzzer.rs\u0060 as WHOLE FILES: this scan already matched 11 separate duplicated blocks between them, totalling at least 190 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 \u0060crates/fuzz/src/crdt_fuzzer.rs:386\u0060 it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows \u2014 the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members\u0027 bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run \u2014 a one-line delegation has no helper inside it to lift \u2014 so generate the run from the set it enumerates, or accept it and keep each member\u0027s own documentation with it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/fuzz/src/crdt_fuzzer.rs"},"region":{"startLine":386}}}],"partialFingerprints":{"codehealthFindingId/v1":"f269a0f4338caf52741105b1c87b5b1f30df1ebfaa846dd9ef8ff42c89536b63"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (18 lines \u00D7 4): crates/fuzz/src/crdt_fuzzer.rs:323-340 | crates/fuzz/src/crdt_fuzzer.rs:386-403 | crates/fuzz/src/one_doc_fuzzer.rs:754-771 | crates/fuzz/src/one_doc_fuzzer.rs:817-834 \u2014 before extracting anything, compare \u0060crates/fuzz/src/crdt_fuzzer.rs\u0060 and \u0060crates/fuzz/src/one_doc_fuzzer.rs\u0060 as WHOLE FILES: this scan already matched 11 separate duplicated blocks between them, totalling at least 190 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 \u0060crates/fuzz/src/crdt_fuzzer.rs:323\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, 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":"crates/fuzz/src/crdt_fuzzer.rs"},"region":{"startLine":323}}}],"partialFingerprints":{"codehealthFindingId/v1":"0e5531c37304dd678fa60dbc7dacd0970f222f5812d301fd02b10ca22b11aaa6"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (17 lines \u00D7 2): crates/fuzz/src/actor.rs:607-623 | crates/fuzz/src/actor.rs:624-640 \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":"crates/fuzz/src/actor.rs"},"region":{"startLine":607}}}],"partialFingerprints":{"codehealthFindingId/v1":"086004d260e75ea56ceae1f01a35bebd8efbc2e78623f65d5cfadb5313dbfd6c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (16 lines \u00D7 2): crates/fuzz/src/crdt_fuzzer.rs:343-358 | crates/fuzz/src/one_doc_fuzzer.rs:774-789 \u2014 before extracting anything, compare \u0060crates/fuzz/src/crdt_fuzzer.rs\u0060 and \u0060crates/fuzz/src/one_doc_fuzzer.rs\u0060 as WHOLE FILES: this scan already matched 11 separate duplicated blocks between them, totalling at least 190 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 \u0060crates/fuzz/src/crdt_fuzzer.rs:343\u0060 it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows \u2014 the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members\u0027 bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run \u2014 a one-line delegation has no helper inside it to lift \u2014 so generate the run from the set it enumerates, or accept it and keep each member\u0027s own documentation with it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/fuzz/src/crdt_fuzzer.rs"},"region":{"startLine":343}}}],"partialFingerprints":{"codehealthFindingId/v1":"10fdec6fb665cb3507e7f37bcce6c1aa6b1d885e88dc523658592180ec76d724"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (15 lines \u00D7 2): crates/fuzz/src/actor.rs:469-483 | crates/fuzz/src/actor.rs:485-499 \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":"crates/fuzz/src/actor.rs"},"region":{"startLine":469}}}],"partialFingerprints":{"codehealthFindingId/v1":"3929c4c30ac074c023ce036a16b1629dd47758b52673e285111dfb4ec81552c3"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 2): crates/fuzz/src/actor.rs:149-162 | crates/fuzz/src/actor.rs:167-180 \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 \u0060crates/fuzz/src/actor.rs:149\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, 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, \u0060crates/fuzz/src/actor.rs:148\u0060 calls \u0060attach\u0060 and \u0060crates/fuzz/src/actor.rs:166\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":"crates/fuzz/src/actor.rs"},"region":{"startLine":149}}}],"partialFingerprints":{"codehealthFindingId/v1":"b46db826aed9a24f094935579d1bd37b04c1d224c6c666504933cf145dfcfbf8"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): crates/fuzz/src/container/tree.rs:214-226 | crates/fuzz/src/one_doc_fuzzer.rs:307-319 \u2014 before extracting anything, compare \u0060crates/fuzz/src/container/tree.rs\u0060 and \u0060crates/fuzz/src/one_doc_fuzzer.rs\u0060 as WHOLE FILES: this scan already matched 6 separate duplicated blocks between them, totalling at least 64 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. The two sit in different directories, so one cannot simply be deleted in favour of the other while both are reached separately: hoist the shared part into a location both already depend on and have each file call it, and retire whichever file turns out to have no caller of its own left. Extracting one helper per block leaves the fork in place."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/fuzz/src/container/tree.rs"},"region":{"startLine":214}}}],"partialFingerprints":{"codehealthFindingId/v1":"3b952ccae34b1000354eed3d9092752dabd2671ce3f29ccc9c966b75ef1c0f6d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12\u201313 lines \u00D7 2): crates/fuzz/src/container/tree.rs:232-243 | crates/fuzz/src/one_doc_fuzzer.rs:325-337 \u2014 before extracting anything, compare \u0060crates/fuzz/src/container/tree.rs\u0060 and \u0060crates/fuzz/src/one_doc_fuzzer.rs\u0060 as WHOLE FILES: this scan already matched 6 separate duplicated blocks between them, totalling at least 64 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. The two sit in different directories, so one cannot simply be deleted in favour of the other while both are reached separately: hoist the shared part into a location both already depend on and have each file call it, and retire whichever file turns out to have no caller of its own left. Extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at \u0060crates/fuzz/src/container/tree.rs:232\u0060 it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows \u2014 the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members\u0027 bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run \u2014 a one-line delegation has no helper inside it to lift \u2014 so generate the run from the set it enumerates, or accept it and keep each member\u0027s own documentation with it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/fuzz/src/container/tree.rs"},"region":{"startLine":232}}}],"partialFingerprints":{"codehealthFindingId/v1":"a5eda8b166d2cec1c45fbc4aaf870ec076ecdbcf59e9c635cc253a54b2c6f844"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): crates/fuzz/src/crdt_fuzzer.rs:680-692 | crates/fuzz/src/one_doc_fuzzer.rs:941-953 \u2014 before extracting anything, compare \u0060crates/fuzz/src/crdt_fuzzer.rs\u0060 and \u0060crates/fuzz/src/one_doc_fuzzer.rs\u0060 as WHOLE FILES: this scan already matched 11 separate duplicated blocks between them, totalling at least 190 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 \u0060crates/fuzz/src/crdt_fuzzer.rs:680\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":"crates/fuzz/src/crdt_fuzzer.rs"},"region":{"startLine":680}}}],"partialFingerprints":{"codehealthFindingId/v1":"09983838bb55f0e12da45d6188749fad200bef52cadd70ddc37c1e46a1e3ab3b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): crates/fuzz/src/one_doc_fuzzer.rs:120-132 | crates/fuzz/src/one_doc_fuzzer.rs:153-165 \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 \u0060crates/fuzz/src/one_doc_fuzzer.rs:120\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":"crates/fuzz/src/one_doc_fuzzer.rs"},"region":{"startLine":120}}}],"partialFingerprints":{"codehealthFindingId/v1":"422caea2ee9c62e39e38f0273649679bf94f5f3507ca577fa6805eb49c232f81"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): crates/fuzz/src/one_doc_fuzzer.rs:212-224 | crates/fuzz/src/one_doc_fuzzer.rs:251-263 \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":"crates/fuzz/src/one_doc_fuzzer.rs"},"region":{"startLine":212}}}],"partialFingerprints":{"codehealthFindingId/v1":"5c1cb1e495629dc2a3d55b1aa2bda7f9d5424244e5a0e992539bbfd4bbaa3721"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): crates/fuzz/src/container/list.rs:133-143 | crates/fuzz/src/container/movable_list.rs:163-173 \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. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any \u0060return\u0060 inside it is the body\u0027s own exit and keeps its meaning in the moved unit."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/fuzz/src/container/list.rs"},"region":{"startLine":133}}}],"partialFingerprints":{"codehealthFindingId/v1":"f5c86fe7c4738c345cec99518ff3c3eacc26041deb66dc8b1b9483da975380da"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9\u201311 lines \u00D7 2): crates/fuzz/src/container/tree.rs:263-271 | crates/fuzz/src/one_doc_fuzzer.rs:361-371 \u2014 before extracting anything, compare \u0060crates/fuzz/src/container/tree.rs\u0060 and \u0060crates/fuzz/src/one_doc_fuzzer.rs\u0060 as WHOLE FILES: this scan already matched 6 separate duplicated blocks between them, totalling at least 64 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. The two sit in different directories, so one cannot simply be deleted in favour of the other while both are reached separately: hoist the shared part into a location both already depend on and have each file call it, and retire whichever file turns out to have no caller of its own left. Extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at \u0060crates/fuzz/src/one_doc_fuzzer.rs:361\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":"crates/fuzz/src/container/tree.rs"},"region":{"startLine":263}}}],"partialFingerprints":{"codehealthFindingId/v1":"e539bccb829613360eeaaae178666a537b2419578e728b2b7e3444165ebd3ffb"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 3): crates/fuzz/src/one_doc_fuzzer.rs:217-226 | crates/fuzz/src/one_doc_fuzzer.rs:239-248 | crates/fuzz/src/one_doc_fuzzer.rs:256-265 \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 \u0060crates/fuzz/src/one_doc_fuzzer.rs:217\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, 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":"crates/fuzz/src/one_doc_fuzzer.rs"},"region":{"startLine":217}}}],"partialFingerprints":{"codehealthFindingId/v1":"a0a6dc233cf46092695fa220fb9c9b0eec9801a007a498d6525c25da19d730db"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): crates/fuzz/src/container/tree.rs:277-286 | crates/fuzz/src/one_doc_fuzzer.rs:379-389 \u2014 before extracting anything, compare \u0060crates/fuzz/src/container/tree.rs\u0060 and \u0060crates/fuzz/src/one_doc_fuzzer.rs\u0060 as WHOLE FILES: this scan already matched 6 separate duplicated blocks between them, totalling at least 64 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. The two sit in different directories, so one cannot simply be deleted in favour of the other while both are reached separately: hoist the shared part into a location both already depend on and have each file call it, and retire whichever file turns out to have no caller of its own left. Extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at \u0060crates/fuzz/src/container/tree.rs:277\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":"crates/fuzz/src/container/tree.rs"},"region":{"startLine":277}}}],"partialFingerprints":{"codehealthFindingId/v1":"af7491516c1d00d03c7a38b94734bb295aed00afb22d2befca95fdc1eb15b52c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): crates/fuzz/src/crdt_fuzzer.rs:66-75 | crates/fuzz/src/one_doc_fuzzer.rs:82-91 \u2014 before extracting anything, compare \u0060crates/fuzz/src/crdt_fuzzer.rs\u0060 and \u0060crates/fuzz/src/one_doc_fuzzer.rs\u0060 as WHOLE FILES: this scan already matched 11 separate duplicated blocks between them, totalling at least 190 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 \u0060crates/fuzz/src/crdt_fuzzer.rs:66\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":"crates/fuzz/src/crdt_fuzzer.rs"},"region":{"startLine":66}}}],"partialFingerprints":{"codehealthFindingId/v1":"c306d2addb563989f56c0f35d492925d270fa99a64e386cbb591fe822469584f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): crates/fuzz/src/actor.rs:114-123 | crates/fuzz/src/actor.rs:131-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. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, \u0060crates/fuzz/src/actor.rs:125\u0060 calls \u0060attach\u0060 and \u0060crates/fuzz/src/actor.rs:141\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":"crates/fuzz/src/actor.rs"},"region":{"startLine":114}}}],"partialFingerprints":{"codehealthFindingId/v1":"5e3570dd6214519b0bf317e86d29bfc55a790812b362c64dbd1ee3a8a825fb16"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8\u20139 lines \u00D7 2): crates/fuzz/src/container/tree.rs:391-399 | crates/fuzz/src/one_doc_fuzzer.rs:636-643 \u2014 before extracting anything, compare \u0060crates/fuzz/src/container/tree.rs\u0060 and \u0060crates/fuzz/src/one_doc_fuzzer.rs\u0060 as WHOLE FILES: this scan already matched 6 separate duplicated blocks between them, totalling at least 64 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. The two sit in different directories, so one cannot simply be deleted in favour of the other while both are reached separately: hoist the shared part into a location both already depend on and have each file call it, and retire whichever file turns out to have no caller of its own left. Extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at \u0060crates/fuzz/src/container/tree.rs:391\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":"crates/fuzz/src/container/tree.rs"},"region":{"startLine":391}}}],"partialFingerprints":{"codehealthFindingId/v1":"5ce5d2d3d62a95dd0ab01878625475c6b291e1373cdb971ea0763c2b853905fd"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): crates/fuzz/src/crdt_fuzzer.rs:110-118 | crates/fuzz/src/one_doc_fuzzer.rs:402-410 \u2014 before extracting anything, compare \u0060crates/fuzz/src/crdt_fuzzer.rs\u0060 and \u0060crates/fuzz/src/one_doc_fuzzer.rs\u0060 as WHOLE FILES: this scan already matched 11 separate duplicated blocks between them, totalling at least 190 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 \u0060crates/fuzz/src/crdt_fuzzer.rs:110\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":"crates/fuzz/src/crdt_fuzzer.rs"},"region":{"startLine":110}}}],"partialFingerprints":{"codehealthFindingId/v1":"d2a4640c2158f5cf8db835f4b180a801a21e287c497fcead7dd53703f7dd67c6"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): crates/fuzz/src/one_doc_fuzzer.rs:664-675 | crates/fuzz/src/one_doc_fuzzer.rs:681-692 \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 \u0060crates/fuzz/src/one_doc_fuzzer.rs:681\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":"crates/fuzz/src/one_doc_fuzzer.rs"},"region":{"startLine":664}}}],"partialFingerprints":{"codehealthFindingId/v1":"912e1d2430aa87afa0892a40072df5b8bafe38f9b4720d74676810854b5c96b1"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7\u20138 lines \u00D7 2): crates/fuzz/src/crdt_fuzzer.rs:819-825 | crates/fuzz/src/crdt_fuzzer.rs:827-834 \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":"crates/fuzz/src/crdt_fuzzer.rs"},"region":{"startLine":819}}}],"partialFingerprints":{"codehealthFindingId/v1":"d6e5427f3312363ad8d0529e3b293bdfdf24b2eff4c7cdee1b24d208417f4318"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): crates/fuzz/src/value.rs:202-209 | crates/fuzz/src/value.rs:283-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 \u0060crates/fuzz/src/value.rs:202\u0060 it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows \u2014 the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members\u0027 bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run \u2014 a one-line delegation has no helper inside it to lift \u2014 so generate the run from the set it enumerates, or accept it and keep each member\u0027s own documentation with it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/fuzz/src/value.rs"},"region":{"startLine":202}}}],"partialFingerprints":{"codehealthFindingId/v1":"5c030652debcff7ef9bf72a00db654f4a0cd47b07857055b7975c39d1eb75068"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 3): crates/fuzz/src/crdt_fuzzer.rs:682-688 | crates/fuzz/src/crdt_fuzzer.rs:717-723 | crates/fuzz/src/one_doc_fuzzer.rs:943-949 \u2014 before extracting anything, compare \u0060crates/fuzz/src/crdt_fuzzer.rs\u0060 and \u0060crates/fuzz/src/one_doc_fuzzer.rs\u0060 as WHOLE FILES: this scan already matched 11 separate duplicated blocks between them, totalling at least 190 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":"crates/fuzz/src/crdt_fuzzer.rs"},"region":{"startLine":682}}}],"partialFingerprints":{"codehealthFindingId/v1":"1e74f5b2fbedc178c619420b224f531cc376800ce8d0f094162b04571156c978"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): crates/fuzz/src/container/tree.rs:245-250 | crates/fuzz/src/one_doc_fuzzer.rs:339-345 \u2014 before extracting anything, compare \u0060crates/fuzz/src/container/tree.rs\u0060 and \u0060crates/fuzz/src/one_doc_fuzzer.rs\u0060 as WHOLE FILES: this scan already matched 6 separate duplicated blocks between them, totalling at least 64 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. The two sit in different directories, so one cannot simply be deleted in favour of the other while both are reached separately: hoist the shared part into a location both already depend on and have each file call it, and retire whichever file turns out to have no caller of its own left. Extracting one helper per block leaves the fork in place. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any \u0060return\u0060 inside it is the body\u0027s own exit and keeps its meaning in the moved unit."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/fuzz/src/container/tree.rs"},"region":{"startLine":245}}}],"partialFingerprints":{"codehealthFindingId/v1":"815560b818a04e26c568cd8e58a7cc58c801ed5b52d1961ce749af80730c70e7"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 6): crates/fuzz/src/container/counter.rs:155-162 | crates/fuzz/src/container/list.rs:84-91 | crates/fuzz/src/container/map.rs:64-71 | crates/fuzz/src/container/movable_list.rs:94-101 | crates/fuzz/src/container/text.rs:89-96 | crates/fuzz/src/container/tree.rs:169-176 \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."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/fuzz/src/container/counter.rs"},"region":{"startLine":155}}}],"partialFingerprints":{"codehealthFindingId/v1":"6af8651835805a403387cd24f42342bfcad90bac8f47b213f6a5c6e222e5f085"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): crates/fuzz/src/value.rs:406-416 | crates/fuzz/src/value.rs:425-435 \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 \u0060crates/fuzz/src/value.rs:406\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":"crates/fuzz/src/value.rs"},"region":{"startLine":406}}}],"partialFingerprints":{"codehealthFindingId/v1":"384a47c80db26021c9aacda87cf7f65c9e388403c1f8a8860a352f282edfe526"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): crates/fuzz/src/container/counter.rs:44-50 | crates/fuzz/src/container/list.rs:45-51 \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 \u0060crates/fuzz/src/container/counter.rs:44\u0060 it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows \u2014 the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members\u0027 bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run \u2014 a one-line delegation has no helper inside it to lift \u2014 so generate the run from the set it enumerates, or accept it and keep each member\u0027s own documentation with it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/fuzz/src/container/counter.rs"},"region":{"startLine":44}}}],"partialFingerprints":{"codehealthFindingId/v1":"731bd6ca0d377624cfb62935c5d5f6669ece26e71bf2ebd24829aa0bebc89eac"}},{"ruleId":"D5","level":"warning","message":{"text":"Unstable project loro (Cargo): loro (Cargo) has instability 0.83 with 1 dependents."},"locations":[],"partialFingerprints":{"codehealthFindingId/v1":"0f10eea1daf9e08c68dcf80ff54777559b438931175081c0edc2823e2ba1a2ee"}},{"ruleId":"D5","level":"warning","message":{"text":"Off the main sequence: loro_fractional_index: loro_fractional_index: abstractness 0.00, instability 0.00, distance 1.00 \u2014 zone of pain \u2014 concrete and depended on by 1 project(s), so it\u0027s rigid to change."},"locations":[],"partialFingerprints":{"codehealthFindingId/v1":"bded28049fb09172a692b43bae199a5d6bb62c0706855c0fa15526661cf8cfac"}},{"ruleId":"D5","level":"warning","message":{"text":"Off the main sequence: generic-btree: generic-btree: abstractness 0.24, instability 0.00, distance 0.76 \u2014 zone of pain \u2014 concrete and depended on by 3 project(s), so it\u0027s rigid to change."},"locations":[],"partialFingerprints":{"codehealthFindingId/v1":"b3bf776353196369240503c67a699e1c8d5bc467e3d888e9646018f5055b7c06"}},{"ruleId":"D6","level":"warning","message":{"text":"Low cohesion: LoroDoc (LCOM4 27): LoroDoc\u0027s methods fall into 27 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 27 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":"crates/loro-internal/src/lib.rs"},"region":{"startLine":126}}}],"partialFingerprints":{"codehealthFindingId/v1":"ad03a5bf781ba2a7c53198fa5dbe40a7e340c56d7b9fc3438582f913bdaacbe3"}},{"ruleId":"D6","level":"warning","message":{"text":"Low cohesion: VersionVector (LCOM4 15): VersionVector\u0027s methods fall into 15 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 15 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":"crates/loro-internal/src/version.rs"},"region":{"startLine":29}}}],"partialFingerprints":{"codehealthFindingId/v1":"d657650369851630467985014f349d635d189080e902e372ada3b046cd8b7971"}},{"ruleId":"D6","level":"warning","message":{"text":"Low cohesion: LoroValueVisitor (LCOM4 5): LoroValueVisitor\u0027s methods fall into 5 groups that share no field and call none of each other, against a bar of more than 3 for this run (LCOM4, configurable \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 5 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":"crates/loro-common/src/value.rs"},"region":{"startLine":977}}}],"partialFingerprints":{"codehealthFindingId/v1":"ad3247bb3a190392cfc1d6109f37f4cc0d4819576b5c442d0665f46c906642d8"}},{"ruleId":"D8","level":"warning","message":{"text":"Coverage not measured \u2014 JavaScript/TypeScript suite: Coverage NOT MEASURED: the JavaScript/TypeScript half could not be measured \u2014 crates/loro-wasm/ runs vitest but declares no coverage provider, so the suite can run and still produce no lcov \u2014 add \u0060@vitest/coverage-v8\u0060 (or \u0060@vitest/coverage-istanbul\u0060) as a devDependency. Coverage is excluded from the score rather than counted as a near-zero. The named suite step is one the repository\u0027s maintainers can perform; once it passes, the real number is measured on the next scan."},"locations":[],"partialFingerprints":{"codehealthFindingId/v1":"62e63e619c28f057e129f2997c965d32a457366a9ce18ca019ffb6bdfba85c99"}},{"ruleId":"D10","level":"warning","message":{"text":"Skipped test: subscription works after timeout: Skipped \u2014 switched off by it.skip"},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-wasm/tests/event.test.ts"},"region":{"startLine":631}}}],"partialFingerprints":{"codehealthFindingId/v1":"47fb2ce22ead8ccbe83138a354f5bf0e906889ae34ade6422c3017f595b09893"}},{"ruleId":"D10","level":"warning","message":{"text":"Skipped test: subscribe_lock: Skipped \u2014 switched off by it.skip"},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-wasm/tests/misc.test.ts"},"region":{"startLine":70}}}],"partialFingerprints":{"codehealthFindingId/v1":"5cf4af6430415256440ecc770168117b3ee46ea7b35be64f5bc04e7bd82468fb"}},{"ruleId":"D10","level":"warning","message":{"text":"No assertions: importBatch Error #181: This method\u0027s body runs code, and no assertion call was recognised in it. Recognised by name: Assert*, *Should*/ShouldBe*, Verify, Expect, Throws, Record, Received/DidNotReceive, MustHaveHappened/MustNotHaveHappened, EnsureSuccessStatusCode and *AndEnsure*, in the test body and in the helpers it calls in the test and test-support code (a helper there that throws when its check fails counts as an assertion) \u2014 so verification routed through a callback object whose members hold the assertions, or through a harness in production code that fails by throwing, is not visible to this check and is not counted here. Read it as \u0027no assertion this check knows how to see\u0027, and if that is right, add one."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-wasm/tests/basic.test.ts"},"region":{"startLine":261}}}],"partialFingerprints":{"codehealthFindingId/v1":"1df716ed199d1b473854cf6ad23b1eb739ddea763a7ec2140f9d902c48faf819"}},{"ruleId":"D10","level":"warning","message":{"text":"No assertions: can use version vector multiple times: This method\u0027s body runs code, and no assertion call was recognised in it. Recognised by name: Assert*, *Should*/ShouldBe*, Verify, Expect, Throws, Record, Received/DidNotReceive, MustHaveHappened/MustNotHaveHappened, EnsureSuccessStatusCode and *AndEnsure*, in the test body and in the helpers it calls in the test and test-support code (a helper there that throws when its check fails counts as an assertion) \u2014 so verification routed through a callback object whose members hold the assertions, or through a harness in production code that fails by throwing, is not visible to this check and is not counted here. Read it as \u0027no assertion this check knows how to see\u0027, and if that is right, add one."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-wasm/tests/basic.test.ts"},"region":{"startLine":1179}}}],"partialFingerprints":{"codehealthFindingId/v1":"db6a47d15655eeb4f2f63a1518e66fd729f81dafe87f558c0e70bbf9d2a852b8"}},{"ruleId":"D10","level":"warning","message":{"text":"No assertions: insert counter container: This method\u0027s body runs code, and no assertion call was recognised in it. Recognised by name: Assert*, *Should*/ShouldBe*, Verify, Expect, Throws, Record, Received/DidNotReceive, MustHaveHappened/MustNotHaveHappened, EnsureSuccessStatusCode and *AndEnsure*, in the test body and in the helpers it calls in the test and test-support code (a helper there that throws when its check fails counts as an assertion) \u2014 so verification routed through a callback object whose members hold the assertions, or through a harness in production code that fails by throwing, is not visible to this check and is not counted here. Read it as \u0027no assertion this check knows how to see\u0027, and if that is right, add one."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-wasm/tests/basic.test.ts"},"region":{"startLine":1610}}}],"partialFingerprints":{"codehealthFindingId/v1":"d97a3eab48254912ee9ffd8fd31382efbdc7f97e724ae020d56962bb35309b45"}},{"ruleId":"D10","level":"warning","message":{"text":"No assertions: move tree nodes within the same parent: This method\u0027s body runs code, and no assertion call was recognised in it. Recognised by name: Assert*, *Should*/ShouldBe*, Verify, Expect, Throws, Record, Received/DidNotReceive, MustHaveHappened/MustNotHaveHappened, EnsureSuccessStatusCode and *AndEnsure*, in the test body and in the helpers it calls in the test and test-support code (a helper there that throws when its check fails counts as an assertion) \u2014 so verification routed through a callback object whose members hold the assertions, or through a harness in production code that fails by throwing, is not visible to this check and is not counted here. Read it as \u0027no assertion this check knows how to see\u0027, and if that is right, add one."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-wasm/tests/basic.test.ts"},"region":{"startLine":1632}}}],"partialFingerprints":{"codehealthFindingId/v1":"04d5bed0e0d8aa25731ac784ddbc930e96942661ce9fe4e960c743a9f8ec74e3"}},{"ruleId":"D10","level":"warning","message":{"text":"No assertions: text mark on LoroText: This method\u0027s body runs code, and no assertion call was recognised in it. Recognised by name: Assert*, *Should*/ShouldBe*, Verify, Expect, Throws, Record, Received/DidNotReceive, MustHaveHappened/MustNotHaveHappened, EnsureSuccessStatusCode and *AndEnsure*, in the test body and in the helpers it calls in the test and test-support code (a helper there that throws when its check fails counts as an assertion) \u2014 so verification routed through a callback object whose members hold the assertions, or through a harness in production code that fails by throwing, is not visible to this check and is not counted here. Read it as \u0027no assertion this check knows how to see\u0027, and if that is right, add one."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-wasm/tests/basic.test.ts"},"region":{"startLine":1751}}}],"partialFingerprints":{"codehealthFindingId/v1":"0fcfbcf4e2475ff39fc4f0bd5b0f7471418e4d0213b893cc62aaf3b8902db39f"}},{"ruleId":"D10","level":"warning","message":{"text":"No assertions: update text after switching to a version: This method\u0027s body runs code, and no assertion call was recognised in it. Recognised by name: Assert*, *Should*/ShouldBe*, Verify, Expect, Throws, Record, Received/DidNotReceive, MustHaveHappened/MustNotHaveHappened, EnsureSuccessStatusCode and *AndEnsure*, in the test body and in the helpers it calls in the test and test-support code (a helper there that throws when its check fails counts as an assertion) \u2014 so verification routed through a callback object whose members hold the assertions, or through a harness in production code that fails by throwing, is not visible to this check and is not counted here. Read it as \u0027no assertion this check knows how to see\u0027, and if that is right, add one."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-wasm/tests/basic.test.ts"},"region":{"startLine":1870}}}],"partialFingerprints":{"codehealthFindingId/v1":"a03c213a81bbd9331d7a231ed2dc5e758f0fa9d9e687f04c4dcaee265dd3b221"}},{"ruleId":"D10","level":"warning","message":{"text":"No assertions: #211: This method\u0027s body runs code, and no assertion call was recognised in it. Recognised by name: Assert*, *Should*/ShouldBe*, Verify, Expect, Throws, Record, Received/DidNotReceive, MustHaveHappened/MustNotHaveHappened, EnsureSuccessStatusCode and *AndEnsure*, in the test body and in the helpers it calls in the test and test-support code (a helper there that throws when its check fails counts as an assertion) \u2014 so verification routed through a callback object whose members hold the assertions, or through a harness in production code that fails by throwing, is not visible to this check and is not counted here. Read it as \u0027no assertion this check knows how to see\u0027, and if that is right, add one."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-wasm/tests/issue.test.ts"},"region":{"startLine":5}}}],"partialFingerprints":{"codehealthFindingId/v1":"a3bf16d8bc9a95c1f00289db99c87c59866b009601723f9d6493933cad8b8e25"}},{"ruleId":"D10","level":"warning","message":{"text":"No assertions: json encoding: This method\u0027s body runs code, and no assertion call was recognised in it. Recognised by name: Assert*, *Should*/ShouldBe*, Verify, Expect, Throws, Record, Received/DidNotReceive, MustHaveHappened/MustNotHaveHappened, EnsureSuccessStatusCode and *AndEnsure*, in the test body and in the helpers it calls in the test and test-support code (a helper there that throws when its check fails counts as an assertion) \u2014 so verification routed through a callback object whose members hold the assertions, or through a harness in production code that fails by throwing, is not visible to this check and is not counted here. Read it as \u0027no assertion this check knows how to see\u0027, and if that is right, add one."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-wasm/tests/json.test.ts"},"region":{"startLine":16}}}],"partialFingerprints":{"codehealthFindingId/v1":"e33a1d92a35ff1f3d5550c554070f612edf5f004987132d001604de1a3fd1423"}},{"ruleId":"D10","level":"warning","message":{"text":"No assertions: json decoding: This method\u0027s body runs code, and no assertion call was recognised in it. Recognised by name: Assert*, *Should*/ShouldBe*, Verify, Expect, Throws, Record, Received/DidNotReceive, MustHaveHappened/MustNotHaveHappened, EnsureSuccessStatusCode and *AndEnsure*, in the test body and in the helpers it calls in the test and test-support code (a helper there that throws when its check fails counts as an assertion) \u2014 so verification routed through a callback object whose members hold the assertions, or through a harness in production code that fails by throwing, is not visible to this check and is not counted here. Read it as \u0027no assertion this check knows how to see\u0027, and if that is right, add one."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-wasm/tests/json.test.ts"},"region":{"startLine":41}}}],"partialFingerprints":{"codehealthFindingId/v1":"d8ec6308e97b330fa53344213f3a7ff678a56d6955e05fa9f3900d02c2585df8"}},{"ruleId":"D10","level":"warning","message":{"text":"No assertions: test map type: This method\u0027s body runs code, and no assertion call was recognised in it. Recognised by name: Assert*, *Should*/ShouldBe*, Verify, Expect, Throws, Record, Received/DidNotReceive, MustHaveHappened/MustNotHaveHappened, EnsureSuccessStatusCode and *AndEnsure*, in the test body and in the helpers it calls in the test and test-support code (a helper there that throws when its check fails counts as an assertion) \u2014 so verification routed through a callback object whose members hold the assertions, or through a harness in production code that fails by throwing, is not visible to this check and is not counted here. Read it as \u0027no assertion this check knows how to see\u0027, and if that is right, add one."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-wasm/tests/misc.test.ts"},"region":{"startLine":291}}}],"partialFingerprints":{"codehealthFindingId/v1":"8040bb9a8154ca3b3f72989e607b0f95968593ee32fa38b3d667a5887f90cab2"}},{"ruleId":"D10","level":"warning","message":{"text":"No assertions: test recursive map type: This method\u0027s body runs code, and no assertion call was recognised in it. Recognised by name: Assert*, *Should*/ShouldBe*, Verify, Expect, Throws, Record, Received/DidNotReceive, MustHaveHappened/MustNotHaveHappened, EnsureSuccessStatusCode and *AndEnsure*, in the test body and in the helpers it calls in the test and test-support code (a helper there that throws when its check fails counts as an assertion) \u2014 so verification routed through a callback object whose members hold the assertions, or through a harness in production code that fails by throwing, is not visible to this check and is not counted here. Read it as \u0027no assertion this check knows how to see\u0027, and if that is right, add one."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-wasm/tests/misc.test.ts"},"region":{"startLine":298}}}],"partialFingerprints":{"codehealthFindingId/v1":"95b42ae8e76d9ec887e11794eddab2920f24405c473d652c5bf64bafbe9f5ab6"}},{"ruleId":"D10","level":"warning","message":{"text":"No assertions: works for list type: This method\u0027s body runs code, and no assertion call was recognised in it. Recognised by name: Assert*, *Should*/ShouldBe*, Verify, Expect, Throws, Record, Received/DidNotReceive, MustHaveHappened/MustNotHaveHappened, EnsureSuccessStatusCode and *AndEnsure*, in the test body and in the helpers it calls in the test and test-support code (a helper there that throws when its check fails counts as an assertion) \u2014 so verification routed through a callback object whose members hold the assertions, or through a harness in production code that fails by throwing, is not visible to this check and is not counted here. Read it as \u0027no assertion this check knows how to see\u0027, and if that is right, add one."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-wasm/tests/misc.test.ts"},"region":{"startLine":310}}}],"partialFingerprints":{"codehealthFindingId/v1":"18569c5ce556d847dd7b7e49a10c10bdd33e4446fa4ce6e31bbc3b342afcac50"}},{"ruleId":"D10","level":"warning","message":{"text":"No assertions: test binary type: This method\u0027s body runs code, and no assertion call was recognised in it. Recognised by name: Assert*, *Should*/ShouldBe*, Verify, Expect, Throws, Record, Received/DidNotReceive, MustHaveHappened/MustNotHaveHappened, EnsureSuccessStatusCode and *AndEnsure*, in the test body and in the helpers it calls in the test and test-support code (a helper there that throws when its check fails counts as an assertion) \u2014 so verification routed through a callback object whose members hold the assertions, or through a harness in production code that fails by throwing, is not visible to this check and is not counted here. Read it as \u0027no assertion this check knows how to see\u0027, and if that is right, add one."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-wasm/tests/misc.test.ts"},"region":{"startLine":318}}}],"partialFingerprints":{"codehealthFindingId/v1":"5adb13623e5af703b869d20b7fb6b63c8b4c349b825c22f876e04480ea3c1e5e"}},{"ruleId":"D10","level":"warning","message":{"text":"No assertions: Insert cursed str: This method\u0027s body runs code, and no assertion call was recognised in it. Recognised by name: Assert*, *Should*/ShouldBe*, Verify, Expect, Throws, Record, Received/DidNotReceive, MustHaveHappened/MustNotHaveHappened, EnsureSuccessStatusCode and *AndEnsure*, in the test body and in the helpers it calls in the test and test-support code (a helper there that throws when its check fails counts as an assertion) \u2014 so verification routed through a callback object whose members hold the assertions, or through a harness in production code that fails by throwing, is not visible to this check and is not counted here. Read it as \u0027no assertion this check knows how to see\u0027, and if that is right, add one."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-wasm/tests/richtext.test.ts"},"region":{"startLine":400}}}],"partialFingerprints":{"codehealthFindingId/v1":"5ed909cbe87c9c042295c80c6103d41d9c98b068f52ef306a37999b6136a8504"}},{"ruleId":"D10","level":"warning","message":{"text":"No assertions: Container should not match Value: This method\u0027s body runs code, and no assertion call was recognised in it. Recognised by name: Assert*, *Should*/ShouldBe*, Verify, Expect, Throws, Record, Received/DidNotReceive, MustHaveHappened/MustNotHaveHappened, EnsureSuccessStatusCode and *AndEnsure*, in the test body and in the helpers it calls in the test and test-support code (a helper there that throws when its check fails counts as an assertion) \u2014 so verification routed through a callback object whose members hold the assertions, or through a harness in production code that fails by throwing, is not visible to this check and is not counted here. Read it as \u0027no assertion this check knows how to see\u0027, and if that is right, add one."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-wasm/tests/type.test.ts"},"region":{"startLine":13}}}],"partialFingerprints":{"codehealthFindingId/v1":"1d4722c90cd308174a64f310254b40202fcd13258c0039e1cf5548a75c6a3a72"}},{"ruleId":"D10","level":"warning","message":{"text":"No assertions: A non-numeric string is not a valid peer id: This method\u0027s body runs code, and no assertion call was recognised in it. Recognised by name: Assert*, *Should*/ShouldBe*, Verify, Expect, Throws, Record, Received/DidNotReceive, MustHaveHappened/MustNotHaveHappened, EnsureSuccessStatusCode and *AndEnsure*, in the test body and in the helpers it calls in the test and test-support code (a helper there that throws when its check fails counts as an assertion) \u2014 so verification routed through a callback object whose members hold the assertions, or through a harness in production code that fails by throwing, is not visible to this check and is not counted here. Read it as \u0027no assertion this check knows how to see\u0027, and if that is right, add one."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-wasm/tests/type.test.ts"},"region":{"startLine":18}}}],"partialFingerprints":{"codehealthFindingId/v1":"0f1ab79a51188238281d55225d790a64747f6b464f193e6949ab6d0b56862405"}},{"ruleId":"D10","level":"warning","message":{"text":"No assertions: Expect container type: This method\u0027s body runs code, and no assertion call was recognised in it. Recognised by name: Assert*, *Should*/ShouldBe*, Verify, Expect, Throws, Record, Received/DidNotReceive, MustHaveHappened/MustNotHaveHappened, EnsureSuccessStatusCode and *AndEnsure*, in the test body and in the helpers it calls in the test and test-support code (a helper there that throws when its check fails counts as an assertion) \u2014 so verification routed through a callback object whose members hold the assertions, or through a harness in production code that fails by throwing, is not visible to this check and is not counted here. Read it as \u0027no assertion this check knows how to see\u0027, and if that is right, add one."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-wasm/tests/type.test.ts"},"region":{"startLine":25}}}],"partialFingerprints":{"codehealthFindingId/v1":"70fecc7bd0dbc5f55351ee11d6a17f3f810c496a2f80ec88ec49b421b5b452a8"}},{"ruleId":"D10","level":"warning","message":{"text":"No assertions: doc type and container type: This method\u0027s body runs code, and no assertion call was recognised in it. Recognised by name: Assert*, *Should*/ShouldBe*, Verify, Expect, Throws, Record, Received/DidNotReceive, MustHaveHappened/MustNotHaveHappened, EnsureSuccessStatusCode and *AndEnsure*, in the test body and in the helpers it calls in the test and test-support code (a helper there that throws when its check fails counts as an assertion) \u2014 so verification routed through a callback object whose members hold the assertions, or through a harness in production code that fails by throwing, is not visible to this check and is not counted here. Read it as \u0027no assertion this check knows how to see\u0027, and if that is right, add one."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-wasm/tests/type.test.ts"},"region":{"startLine":36}}}],"partialFingerprints":{"codehealthFindingId/v1":"e88076bc12c68db0b2e97c3b8d364ef9c330b65b70aa29dd1d59ab5425419f08"}},{"ruleId":"D10","level":"warning","message":{"text":"No assertions: fail on set/insert container: This method\u0027s body runs code, and no assertion call was recognised in it. Recognised by name: Assert*, *Should*/ShouldBe*, Verify, Expect, Throws, Record, Received/DidNotReceive, MustHaveHappened/MustNotHaveHappened, EnsureSuccessStatusCode and *AndEnsure*, in the test body and in the helpers it calls in the test and test-support code (a helper there that throws when its check fails counts as an assertion) \u2014 so verification routed through a callback object whose members hold the assertions, or through a harness in production code that fails by throwing, is not visible to this check and is not counted here. Read it as \u0027no assertion this check knows how to see\u0027, and if that is right, add one."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-wasm/tests/type.test.ts"},"region":{"startLine":68}}}],"partialFingerprints":{"codehealthFindingId/v1":"fedb9419eacd99436f1cf0a87e83de460fddf3b88282768f9dec0967956a1349"}},{"ruleId":"D10","level":"warning","message":{"text":"No assertions: batchImport type: This method\u0027s body runs code, and no assertion call was recognised in it. Recognised by name: Assert*, *Should*/ShouldBe*, Verify, Expect, Throws, Record, Received/DidNotReceive, MustHaveHappened/MustNotHaveHappened, EnsureSuccessStatusCode and *AndEnsure*, in the test body and in the helpers it calls in the test and test-support code (a helper there that throws when its check fails counts as an assertion) \u2014 so verification routed through a callback object whose members hold the assertions, or through a harness in production code that fails by throwing, is not visible to this check and is not counted here. Read it as \u0027no assertion this check knows how to see\u0027, and if that is right, add one."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-wasm/tests/type.test.ts"},"region":{"startLine":81}}}],"partialFingerprints":{"codehealthFindingId/v1":"06b0e78fc6c6b6d7dbfdfac4e522291ece12126d3c20bfdd42e270c45829fc7a"}},{"ruleId":"D10","level":"warning","message":{"text":"No assertions: avoid rust recursive use error: This method\u0027s body runs code, and no assertion call was recognised in it. Recognised by name: Assert*, *Should*/ShouldBe*, Verify, Expect, Throws, Record, Received/DidNotReceive, MustHaveHappened/MustNotHaveHappened, EnsureSuccessStatusCode and *AndEnsure*, in the test body and in the helpers it calls in the test and test-support code (a helper there that throws when its check fails counts as an assertion) \u2014 so verification routed through a callback object whose members hold the assertions, or through a harness in production code that fails by throwing, is not visible to this check and is not counted here. Read it as \u0027no assertion this check knows how to see\u0027, and if that is right, add one."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-wasm/tests/undo.test.ts"},"region":{"startLine":676}}}],"partialFingerprints":{"codehealthFindingId/v1":"1db0409cb20b07144b354699563a1a996a7287995d3e172692acfe96ca32a658"}},{"ruleId":"D10","level":"warning","message":{"text":"No assertions: fork when detached: This method\u0027s body runs code, and no assertion call was recognised in it. Recognised by name: Assert*, *Should*/ShouldBe*, Verify, Expect, Throws, Record, Received/DidNotReceive, MustHaveHappened/MustNotHaveHappened, EnsureSuccessStatusCode and *AndEnsure*, in the test body and in the helpers it calls in the test and test-support code (a helper there that throws when its check fails counts as an assertion) \u2014 so verification routed through a callback object whose members hold the assertions, or through a harness in production code that fails by throwing, is not visible to this check and is not counted here. Read it as \u0027no assertion this check knows how to see\u0027, and if that is right, add one."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-wasm/bun_tests/bun.test.ts"},"region":{"startLine":10}}}],"partialFingerprints":{"codehealthFindingId/v1":"fa924c77c86b0434949c81a048c41501b2beb2d351bfc108b66f6eb273bf4506"}},{"ruleId":"D10","level":"warning","message":{"text":"No assertions: toJsonWithReplacer: This method\u0027s body runs code, and no assertion call was recognised in it. Recognised by name: Assert*, *Should*/ShouldBe*, Verify, Expect, Throws, Record, Received/DidNotReceive, MustHaveHappened/MustNotHaveHappened, EnsureSuccessStatusCode and *AndEnsure*, in the test body and in the helpers it calls in the test and test-support code (a helper there that throws when its check fails counts as an assertion) \u2014 so verification routed through a callback object whose members hold the assertions, or through a harness in production code that fails by throwing, is not visible to this check and is not counted here. Read it as \u0027no assertion this check knows how to see\u0027, and if that is right, add one."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-wasm/bun_tests/bun.test.ts"},"region":{"startLine":43}}}],"partialFingerprints":{"codehealthFindingId/v1":"9cf7a5eb41ee9b335f73889218601dac73404cea532837c7cf160b31a042d188"}},{"ruleId":"D11","level":"error","message":{"text":"Flaky test: loro-js/tests/import-atomicity.test.ts:: import is atomic an import costs the same however many texts a snapshot hydrated: Passed 2\u00D7, failed 1\u00D7 across repeated runs."},"locations":[],"partialFingerprints":{"codehealthFindingId/v1":"ef3db08e30948cb1e36f6b95a92435f9883d70aa30aab401de22ed03ae1c34b6"}},{"ruleId":"D11","level":"error","message":{"text":"Flaky test: loro-js/tests/movable-list.test.ts:: MovableList versions, undo and diffs checkout and diff stay linear in the number of inserts: Passed 2\u00D7, failed 1\u00D7 across repeated runs."},"locations":[],"partialFingerprints":{"codehealthFindingId/v1":"9f34cda49abb12deeff035da17e69cee5eaefe3e8bdc5f48adac8aa60bae7e78"}},{"ruleId":"D12","level":"warning","message":{"text":"Yanked release: lz4_flex: \u0060lz4_flex\u0060 resolves to 0.11.5 in the committed Cargo.lock, and crates.io reports that release as YANKED. A yanked release is one the publisher has withdrawn and asked you to stop using; it keeps resolving only so existing locks do not break. The current stable release is 0.14.1. Run \u0060cargo update -p lz4_flex\u0060 and commit the updated lock."},"locations":[],"partialFingerprints":{"codehealthFindingId/v1":"93718cb2f60a145f6aaf089dfc0e74676d71f415e1fb4ee95980e1dbe4eca0f5"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: loro-js/src/runtime/document.ts: loro-js/src/runtime/document.ts changed 23 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 100 in LoroDoc.#applyVersionTransition at line 5836. 22 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-15..2026-11-13, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-15 00:57:59 -08:00\u0027 --until=\u00272026-11-13 00:57:59 -08:00\u0027 --full-history --no-merges -- loro-js/src/runtime/document.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":"loro-js/src/runtime/document.ts"},"region":{"startLine":5836}}}],"partialFingerprints":{"codehealthFindingId/v1":"0411067482d7ef0ccf3850a57723ad4b851aa8a4ec9e28ceed984f0dea7e9a15"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: crates/loro-internal/src/loro.rs: crates/loro-internal/src/loro.rs changed 26 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 48 in LoroDoc::check_apply_diff_creates_no_unknown_container at line 2592. 20 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-15..2026-11-13, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-15 00:57:59 -08:00\u0027 --until=\u00272026-11-13 00:57:59 -08:00\u0027 --full-history --no-merges -- crates/loro-internal/src/loro.rs\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":"crates/loro-internal/src/loro.rs"},"region":{"startLine":2592}}}],"partialFingerprints":{"codehealthFindingId/v1":"699b48c0942e271f6b8ac41cab2b3562fe0f9884aefcd01ac6c67a56c1dbe9a6"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: crates/loro-internal/src/oplog.rs: crates/loro-internal/src/oplog.rs changed 23 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 26 in OpLog::try_iter_from_replay_base_causally_filtered at line 1269. 16 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-15..2026-11-13, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-15 00:57:59 -08:00\u0027 --until=\u00272026-11-13 00:57:59 -08:00\u0027 --full-history --no-merges -- crates/loro-internal/src/oplog.rs\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":"crates/loro-internal/src/oplog.rs"},"region":{"startLine":1269}}}],"partialFingerprints":{"codehealthFindingId/v1":"97192b60bf3c7b7e7500ff00faf85f9253ea0599d99bbea8b93812f7bfadee96"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: crates/loro-internal/src/state.rs: crates/loro-internal/src/state.rs changed 16 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 37 in DocState::apply_diff at line 664. 12 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-15..2026-11-13, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-15 00:57:59 -08:00\u0027 --until=\u00272026-11-13 00:57:59 -08:00\u0027 --full-history --no-merges -- crates/loro-internal/src/state.rs\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":"crates/loro-internal/src/state.rs"},"region":{"startLine":664}}}],"partialFingerprints":{"codehealthFindingId/v1":"fffd2c9ad4218c25539cdfed4e71b82809cb2eec2ffdd1531c18c97a06453aec"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: crates/loro-internal/src/dag.rs: crates/loro-internal/src/dag.rs changed 6 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 92 in loro_internal::dag::_find_meet_and_mode at line 740. 5 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-15..2026-11-13, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-15 00:57:59 -08:00\u0027 --until=\u00272026-11-13 00:57:59 -08:00\u0027 --full-history --no-merges -- crates/loro-internal/src/dag.rs\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":"crates/loro-internal/src/dag.rs"},"region":{"startLine":740}}}],"partialFingerprints":{"codehealthFindingId/v1":"403ec414123fdaf6bf07a66c5b19a1b9221fa6695a955d95b47ec4522ede93a6"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: crates/loro-internal/src/diff_calc.rs: crates/loro-internal/src/diff_calc.rs changed 14 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 33 in DiffCalculator::try_calc_diff_internal at line 186. 8 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-15..2026-11-13, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-15 00:57:59 -08:00\u0027 --until=\u00272026-11-13 00:57:59 -08:00\u0027 --full-history --no-merges -- crates/loro-internal/src/diff_calc.rs\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":"crates/loro-internal/src/diff_calc.rs"},"region":{"startLine":186}}}],"partialFingerprints":{"codehealthFindingId/v1":"045227fcd0f4cf20fe4a98200995ea9f442cf84957065731f7982bee645b79ed"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: crates/loro-internal/src/oplog/change_store.rs: crates/loro-internal/src/oplog/change_store.rs changed 11 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 26 in ChangeStore::get_change_by_lamport_lte at line 1554. 9 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-15..2026-11-13, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-15 00:57:59 -08:00\u0027 --until=\u00272026-11-13 00:57:59 -08:00\u0027 --full-history --no-merges -- crates/loro-internal/src/oplog/change_store.rs\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":"crates/loro-internal/src/oplog/change_store.rs"},"region":{"startLine":1554}}}],"partialFingerprints":{"codehealthFindingId/v1":"a6b591613fd2c8bf68a9099dc53cc4481f547bb2f5921ba700aacc65f1145713"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: crates/loro-internal/src/state/movable_list_state.rs: crates/loro-internal/src/state/movable_list_state.rs changed 6 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 37 in MovableListState::apply_diff_and_convert at line 1092. 5 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-15..2026-11-13, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-15 00:57:59 -08:00\u0027 --until=\u00272026-11-13 00:57:59 -08:00\u0027 --full-history --no-merges -- crates/loro-internal/src/state/movable_list_state.rs\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":"crates/loro-internal/src/state/movable_list_state.rs"},"region":{"startLine":1092}}}],"partialFingerprints":{"codehealthFindingId/v1":"611a730d2552146e746645ef0d63dc543841b4abc5cad6e26bc0d124ad3d0a2b"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: crates/loro-internal/src/encoding/shallow_snapshot.rs: crates/loro-internal/src/encoding/shallow_snapshot.rs changed 10 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 20 in loro_internal::encoding::shallow_snapshot::export_shallow_snapshot_inner at line 301. 9 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-15..2026-11-13, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-15 00:57:59 -08:00\u0027 --until=\u00272026-11-13 00:57:59 -08:00\u0027 --full-history --no-merges -- crates/loro-internal/src/encoding/shallow_snapshot.rs\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":"crates/loro-internal/src/encoding/shallow_snapshot.rs"},"region":{"startLine":301}}}],"partialFingerprints":{"codehealthFindingId/v1":"56c80f386abbc4032ecaae834b29a6e58325c52cbfbc2960effcc692f3ab5960"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: crates/loro-internal/src/history_cache.rs: crates/loro-internal/src/history_cache.rs changed 7 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 27 in ContainerHistoryCache::init_cache_by_visit_all_change_slow at line 163. 5 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-15..2026-11-13, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-15 00:57:59 -08:00\u0027 --until=\u00272026-11-13 00:57:59 -08:00\u0027 --full-history --no-merges -- crates/loro-internal/src/history_cache.rs\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":"crates/loro-internal/src/history_cache.rs"},"region":{"startLine":163}}}],"partialFingerprints":{"codehealthFindingId/v1":"635b3058fc50c559282e46bbd627a5ed3f1ab76db480695bc398c46f445cd1a4"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: crates/loro-internal/src/encoding/outdated_encode_reordered.rs: crates/loro-internal/src/encoding/outdated_encode_reordered.rs changed 5 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 27 in loro_internal::encoding::outdated_encode_reordered::decode_op at line 288. 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-15..2026-11-13, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-15 00:57:59 -08:00\u0027 --until=\u00272026-11-13 00:57:59 -08:00\u0027 --full-history --no-merges -- crates/loro-internal/src/encoding/outdated_encode_reordered.rs\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":"crates/loro-internal/src/encoding/outdated_encode_reordered.rs"},"region":{"startLine":288}}}],"partialFingerprints":{"codehealthFindingId/v1":"7dd01d5a36bbb40d8f4871f0e94d062111b5ba850bfc5b90ecdef018033a7f13"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: crates/loro-internal/src/oplog/known_history.rs: crates/loro-internal/src/oplog/known_history.rs changed 7 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 19 in ImportedValues::eq at line 43. 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-15..2026-11-13, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-15 00:57:59 -08:00\u0027 --until=\u00272026-11-13 00:57:59 -08:00\u0027 --full-history --no-merges -- crates/loro-internal/src/oplog/known_history.rs\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":"crates/loro-internal/src/oplog/known_history.rs"},"region":{"startLine":43}}}],"partialFingerprints":{"codehealthFindingId/v1":"c5d11dd546c9a68802bedac82a4d253a1ba72bf07f756f0e5532e1c542bd272c"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: crates/loro-internal/src/version.rs: crates/loro-internal/src/version.rs changed 7 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 17 in loro_internal::version::try_shrink_frontiers at line 1009. 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-15..2026-11-13, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-15 00:57:59 -08:00\u0027 --until=\u00272026-11-13 00:57:59 -08:00\u0027 --full-history --no-merges -- crates/loro-internal/src/version.rs\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":"crates/loro-internal/src/version.rs"},"region":{"startLine":1009}}}],"partialFingerprints":{"codehealthFindingId/v1":"c66ecb6080f39db21562cf36aa7578c7d973f3575c5134e78988369708e2142d"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: crates/loro-internal/src/txn.rs: crates/loro-internal/src/txn.rs changed 5 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 23 in loro_internal::txn::change_to_diff at line 968. 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-15..2026-11-13, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-15 00:57:59 -08:00\u0027 --until=\u00272026-11-13 00:57:59 -08:00\u0027 --full-history --no-merges -- crates/loro-internal/src/txn.rs\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":"crates/loro-internal/src/txn.rs"},"region":{"startLine":968}}}],"partialFingerprints":{"codehealthFindingId/v1":"cc1aa0b6fb68675e45e3dcdcb04d2c8ac7c746428858728e7d5a0935b8cadbe4"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: crates/loro-internal/src/state/richtext_state.rs: crates/loro-internal/src/state/richtext_state.rs changed 7 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 16 in loro_internal::state::richtext_state::snapshot::redact_dead_style_values at line 1403. 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-15..2026-11-13, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-15 00:57:59 -08:00\u0027 --until=\u00272026-11-13 00:57:59 -08:00\u0027 --full-history --no-merges -- crates/loro-internal/src/state/richtext_state.rs\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":"crates/loro-internal/src/state/richtext_state.rs"},"region":{"startLine":1403}}}],"partialFingerprints":{"codehealthFindingId/v1":"b92de170846167a3a1d9fd24768cbbdd5fe30c2bd385ecdac93a0a78a2aa4968"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: crates/loro-internal/src/encoding/json_schema.rs: crates/loro-internal/src/encoding/json_schema.rs changed 3 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 37 in loro_internal::encoding::json_schema::decode_op at line 780. 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-15..2026-11-13, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-15 00:57:59 -08:00\u0027 --until=\u00272026-11-13 00:57:59 -08:00\u0027 --full-history --no-merges -- crates/loro-internal/src/encoding/json_schema.rs\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":"crates/loro-internal/src/encoding/json_schema.rs"},"region":{"startLine":780}}}],"partialFingerprints":{"codehealthFindingId/v1":"884b214f6ed8d34881535e112271e356eee41bf953b863833c8f7b14c03fb781"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: loro-js/src/runtime/undo.ts: loro-js/src/runtime/undo.ts changed 4 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 23 in UndoManager.#record at line 239. 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-15..2026-11-13, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-15 00:57:59 -08:00\u0027 --until=\u00272026-11-13 00:57:59 -08:00\u0027 --full-history --no-merges -- loro-js/src/runtime/undo.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":"loro-js/src/runtime/undo.ts"},"region":{"startLine":239}}}],"partialFingerprints":{"codehealthFindingId/v1":"affaaadd4961f1dbea67a8993b76753b194dd1b62f7ce1278f737bd3a8f05c1d"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: crates/loro-common/src/value.rs: crates/loro-common/src/value.rs changed 4 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 20 in loro_common::value::values_eq at line 46. 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-15..2026-11-13, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-15 00:57:59 -08:00\u0027 --until=\u00272026-11-13 00:57:59 -08:00\u0027 --full-history --no-merges -- crates/loro-common/src/value.rs\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":"crates/loro-common/src/value.rs"},"region":{"startLine":46}}}],"partialFingerprints":{"codehealthFindingId/v1":"21c3d995dd0bb9fc579bc3cc584dd342322309ebb6d7a437939332a9f870bd0a"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: crates/loro-internal/src/undo.rs: crates/loro-internal/src/undo.rs changed 14 times in last 90 days and 13 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 loro_internal::undo::transform_cursor at line 189), 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 grouped undo across split history spans (#1278)\u201D; \u201Cfix: reset undo merge timer when a new item is created (#1276)\u201D; \u201Cfix: enforce undo stack limit on resize and redo (#1272)\u201D; \u201Cfix: transform selection delta when undoing the last item (#1102)\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-15..2026-11-13, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-15 00:57:59 -08:00\u0027 --until=\u00272026-11-13 00:57:59 -08:00\u0027 --full-history --no-merges -- crates/loro-internal/src/undo.rs\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":"crates/loro-internal/src/undo.rs"},"region":{"startLine":189}}}],"partialFingerprints":{"codehealthFindingId/v1":"c4f90d7d4367efb238b8338cbd098e637ecdbce5ca6043c406b726f22c01df1f"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: crates/loro-wasm/src/lib.rs: crates/loro-wasm/src/lib.rs changed 15 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 14 (its worst body is UndoManager::setOnPush at line 6055), 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(wasm): keep onPush metadata at the undo limit (#1253)\u201D; \u201Cfix: reject caller input that panicked or silently lost ops (#1258)\u201D; \u201Cfix: preserve undo and redo history boundaries on no-ops (#1202)\u201D; \u201Cfix: traverse deep trees without overflowing the stack (#1206)\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-15..2026-11-13, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-15 00:57:59 -08:00\u0027 --until=\u00272026-11-13 00:57:59 -08:00\u0027 --full-history --no-merges -- crates/loro-wasm/src/lib.rs\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":"crates/loro-wasm/src/lib.rs"},"region":{"startLine":6055}}}],"partialFingerprints":{"codehealthFindingId/v1":"12908e1f907fbcdbc597836bca368765cf82777555955ef41b7c38e67f487f2f"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: crates/loro-internal/src/oplog/pending_changes.rs: crates/loro-internal/src/oplog/pending_changes.rs changed 9 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 12 (its worst body is PendingChangesRollback::rollback at line 441), 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: replay pending changes after snapshot bootstrap (#1281)\u201D; \u201Cfix: reject trimmed dependencies during shallow import (#1280)\u201D; \u201Cfix: reject imports missing a causal peer predecessor (#1274)\u201D; \u201Cfix: reject caller input that panicked or silently lost ops (#1258)\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-15..2026-11-13, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-15 00:57:59 -08:00\u0027 --until=\u00272026-11-13 00:57:59 -08:00\u0027 --full-history --no-merges -- crates/loro-internal/src/oplog/pending_changes.rs\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":"crates/loro-internal/src/oplog/pending_changes.rs"},"region":{"startLine":441}}}],"partialFingerprints":{"codehealthFindingId/v1":"bf0e2a601a40f6216b622485f56d27fca30b0ba79d04fb10b99450867e643f3e"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: crates/loro-internal/src/encoding/fast_snapshot.rs: crates/loro-internal/src/encoding/fast_snapshot.rs 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 10 (its worst body is loro_internal::encoding::fast_snapshot::decode_snapshot_inner at line 172), 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: reject caller input that panicked or silently lost ops (#1258)\u201D; \u201Cfix: keep binary import exact when JSON drops value bits\u201D; \u201Cfix: Return decode errors from lazy history reads (#1177)\u201D; \u201Cfix: reduce overlapping import costs (#1176)\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-15..2026-11-13, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-15 00:57:59 -08:00\u0027 --until=\u00272026-11-13 00:57:59 -08:00\u0027 --full-history --no-merges -- crates/loro-internal/src/encoding/fast_snapshot.rs\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":"crates/loro-internal/src/encoding/fast_snapshot.rs"},"region":{"startLine":172}}}],"partialFingerprints":{"codehealthFindingId/v1":"71c59506eabe9fe910f6fb45fbdd476e823fa99b29b7f4d875060c76f55cea12"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: crates/loro-internal/src/arena.rs: crates/loro-internal/src/arena.rs 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 SharedArena::inner_convert_op at line 702), 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: keep untrusted deep nesting from aborting the process (#1249)\u201D; \u201Cfix: keep parsed blocks out of doc-wide arenas and contain callback panics (#1197)\u201D; \u201Cfix: keep binary import exact when JSON drops value bits\u201D; \u201Cfix: reduce overlapping import costs (#1176)\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-15..2026-11-13, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-15 00:57:59 -08:00\u0027 --until=\u00272026-11-13 00:57:59 -08:00\u0027 --full-history --no-merges -- crates/loro-internal/src/arena.rs\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":"crates/loro-internal/src/arena.rs"},"region":{"startLine":702}}}],"partialFingerprints":{"codehealthFindingId/v1":"f770f151ca317c7f8ca79f1d7bf53cbfd9f734764f06f4a3ef7989cc08dec0ec"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: crates/loro-internal/src/encoding.rs: crates/loro-internal/src/encoding.rs 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 6 (its worst body is EncodeMode::from_i64 at line 175), 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: reject trimmed dependencies during shallow import (#1280)\u201D; \u201Cfix: reject caller input that panicked or silently lost ops (#1258)\u201D; \u201Cfix: keep parsed blocks out of doc-wide arenas and contain callback panics (#1197)\u201D; \u201Cfix: keep binary import exact when JSON drops value bits\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-15..2026-11-13, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-15 00:57:59 -08:00\u0027 --until=\u00272026-11-13 00:57:59 -08:00\u0027 --full-history --no-merges -- crates/loro-internal/src/encoding.rs\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":"crates/loro-internal/src/encoding.rs"},"region":{"startLine":175}}}],"partialFingerprints":{"codehealthFindingId/v1":"7397a6e7b1e1532d7bcae096559b1a40aabe066ffd27c6bf4939042f2f36e46a"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: crates/loro-internal/src/oplog/change_store/block_encode.rs: crates/loro-internal/src/oplog/change_store/block_encode.rs 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 15 (its worst body is loro_internal::oplog::change_store::block_encode::decode_block at line 610), 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: bound change-header allocations during import (#1275)\u201D; \u201Cfix: keep parsed blocks out of doc-wide arenas and contain callback panics (#1197)\u201D; \u201Cfix: Return decode errors from lazy history reads (#1177)\u201D; \u201Cfix: reduce overlapping import costs (#1176)\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-15..2026-11-13, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-15 00:57:59 -08:00\u0027 --until=\u00272026-11-13 00:57:59 -08:00\u0027 --full-history --no-merges -- crates/loro-internal/src/oplog/change_store/block_encode.rs\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":"crates/loro-internal/src/oplog/change_store/block_encode.rs"},"region":{"startLine":610}}}],"partialFingerprints":{"codehealthFindingId/v1":"b7f6d2283e9a2721370141f590699ca562e3be759aec8d47bef6b61a71e7fb3d"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: crates/loro-internal/src/state/container_store.rs: crates/loro-internal/src/state/container_store.rs 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 4 (its worst body is ContainerStore::check_eq_after_parsing at line 398), 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: issue sweep (#1118, #1162, #1155, #1165, #1156, #1164, #1157, #1154, #1151; #1149 documented) (#1171)\u201D; \u201Cfix: drop dead containers when re-exporting a shallow doc at its cached root (#1123)\u201D; \u201Cfix: drop containers deleted before the shallow root from shallow and state-only snapshots (#1119)\u201D; \u201Cfix: bound the decoded container value cache to stop wasm memory growth on handle reads (#1093)\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-15..2026-11-13, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-15 00:57:59 -08:00\u0027 --until=\u00272026-11-13 00:57:59 -08:00\u0027 --full-history --no-merges -- crates/loro-internal/src/state/container_store.rs\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":"crates/loro-internal/src/state/container_store.rs"},"region":{"startLine":398}}}],"partialFingerprints":{"codehealthFindingId/v1":"8ec0e76c1f4e285a6f8f91fad44d425decd1b86a894c69c932183edd7c661563"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: crates/loro-internal/src/state/container_store/container_wrapper.rs: crates/loro-internal/src/state/container_store/container_wrapper.rs 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 ContainerWrapper::decode_state at line 760), 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: resolve a container\u0027s parent from the change that created it (#1159)\u201D; \u201Cfix: drop dead containers when re-exporting a shallow doc at its cached root (#1123)\u201D; \u201Cfix: drop containers deleted before the shallow root from shallow and state-only snapshots (#1119)\u201D; \u201Cfix: bound the decoded container value cache to stop wasm memory growth on handle reads (#1093)\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-15..2026-11-13, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-15 00:57:59 -08:00\u0027 --until=\u00272026-11-13 00:57:59 -08:00\u0027 --full-history --no-merges -- crates/loro-internal/src/state/container_store/container_wrapper.rs\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":"crates/loro-internal/src/state/container_store/container_wrapper.rs"},"region":{"startLine":760}}}],"partialFingerprints":{"codehealthFindingId/v1":"dc9f6809534542579ae98fde5a0ab8385acc497b56069b2463362e1496513b4f"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: crates/loro-internal/src/diff_calc/tree.rs: crates/loro-internal/src/diff_calc/tree.rs 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 11 (its worst body is TreeDiffCalculator::checkout_diff at line 205), 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: bound tree history parent walks and cover skipped cycle moves (#1273)\u201D; \u201Cfix: take the tree checkout window from the two versions (#1152)\u201D; \u201Cfix: pick shallow roots as critical versions of the retained history (#1104)\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-15..2026-11-13, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-15 00:57:59 -08:00\u0027 --until=\u00272026-11-13 00:57:59 -08:00\u0027 --full-history --no-merges -- crates/loro-internal/src/diff_calc/tree.rs\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":"crates/loro-internal/src/diff_calc/tree.rs"},"region":{"startLine":205}}}],"partialFingerprints":{"codehealthFindingId/v1":"f1fad97f427a0bb3d3644b46bcb7c5c497a32612dd2e36cd07232df19f125f5e"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: crates/loro-internal/src/container/richtext/tracker.rs: crates/loro-internal/src/container/richtext/tracker.rs 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 Tracker::_checkout at line 393), 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: big text insert after a concurrent change imports in linear time (#1236)\u201D; \u201Cfix: keep parsed blocks out of doc-wide arenas and contain callback panics (#1197)\u201D; \u201Cfix: reject malformed movable list move/set ops on import instead of aborting (#1125)\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-15..2026-11-13, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-15 00:57:59 -08:00\u0027 --until=\u00272026-11-13 00:57:59 -08:00\u0027 --full-history --no-merges -- crates/loro-internal/src/container/richtext/tracker.rs\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":"crates/loro-internal/src/container/richtext/tracker.rs"},"region":{"startLine":393}}}],"partialFingerprints":{"codehealthFindingId/v1":"eab20b74392f4855b220bbc6e736c37211db6f6686f6208534b0199a29b72e68"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: crates/loro-internal/src/state/map_state.rs: crates/loro-internal/src/state/map_state.rs 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 MapState::apply_diff_and_convert at line 240), 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: keep untrusted deep nesting from aborting the process (#1249)\u201D; \u201Cfix: prevent stack overflow when reading and dropping deep snapshot values (#1204)\u201D; \u201Cfix: keep root-time map values when checking out a shallow doc (#1124)\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-15..2026-11-13, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-15 00:57:59 -08:00\u0027 --until=\u00272026-11-13 00:57:59 -08:00\u0027 --full-history --no-merges -- crates/loro-internal/src/state/map_state.rs\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":"crates/loro-internal/src/state/map_state.rs"},"region":{"startLine":240}}}],"partialFingerprints":{"codehealthFindingId/v1":"29e01b8e40a9987f5f09ecea5e2b59a4c230682cc0147415909aad2861566d68"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: crates/loro-internal/src/handler/tree.rs: crates/loro-internal/src/handler/tree.rs 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 11 (its worst body is TreeHandler::create_at_with_target_for_apply_diff at line 447), 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: traverse deep trees without overflowing the stack (#1206)\u201D; \u201Cfix: issue sweep (#1118, #1162, #1155, #1165, #1156, #1164, #1157, #1154, #1151; #1149 documented) (#1171)\u201D; \u201Cfix: reject inserting a container attached to another doc (#1111)\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-15..2026-11-13, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-15 00:57:59 -08:00\u0027 --until=\u00272026-11-13 00:57:59 -08:00\u0027 --full-history --no-merges -- crates/loro-internal/src/handler/tree.rs\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":"crates/loro-internal/src/handler/tree.rs"},"region":{"startLine":447}}}],"partialFingerprints":{"codehealthFindingId/v1":"c975b004f6073af20d8df0f9cf75a79b734943fa04f3d3ce23570f8fbc707846"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: crates/loro-internal/src/container/list/list_op.rs: crates/loro-internal/src/container/list/list_op.rs 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 DeleteSpanWithId::is_mergable 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: reject overflowing or inverted text mark ranges on import (#1287)\u201D; \u201Cfix: keep parsed blocks out of doc-wide arenas and contain callback panics (#1197)\u201D; \u201Cfix: reject malformed movable list move/set ops on import instead of aborting (#1125)\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-15..2026-11-13, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-15 00:57:59 -08:00\u0027 --until=\u00272026-11-13 00:57:59 -08:00\u0027 --full-history --no-merges -- crates/loro-internal/src/container/list/list_op.rs\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":"crates/loro-internal/src/container/list/list_op.rs"},"region":{"startLine":228}}}],"partialFingerprints":{"codehealthFindingId/v1":"182637f74a8cda291384dfaac5fc47c4544002cc8e47783d66024a7c4f9ca4f7"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: crates/loro-internal/src/utils/subscription.rs: crates/loro-internal/src/utils/subscription.rs 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 SubscriberSet::retain at line 409), 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: keep parsed blocks out of doc-wide arenas and contain callback panics (#1197)\u201D; \u201Cfix: issue sweep (#1118, #1162, #1155, #1165, #1156, #1164, #1157, #1154, #1151; #1149 documented) (#1171)\u201D; \u201Cfix(subscription): don\u0027t panic when subscribing during an emit (#1105)\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-15..2026-11-13, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-15 00:57:59 -08:00\u0027 --until=\u00272026-11-13 00:57:59 -08:00\u0027 --full-history --no-merges -- crates/loro-internal/src/utils/subscription.rs\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":"crates/loro-internal/src/utils/subscription.rs"},"region":{"startLine":409}}}],"partialFingerprints":{"codehealthFindingId/v1":"d340c971aa4ac1228493dbff6bda8f38d77eed93303af75db6fab5732c46e071"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: crates/loro-internal/src/event.rs: crates/loro-internal/src/event.rs 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 InternalDiff::is_empty at line 400), 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: keep binary import exact when JSON drops value bits\u201D; \u201Cfix: reject creating unknown-type containers instead of panicking (#1142)\u201D; \u201Cfix: restore deleted mergeable children once on revert/apply_diff/undo (#1134)\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-15..2026-11-13, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-15 00:57:59 -08:00\u0027 --until=\u00272026-11-13 00:57:59 -08:00\u0027 --full-history --no-merges -- crates/loro-internal/src/event.rs\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":"crates/loro-internal/src/event.rs"},"region":{"startLine":400}}}],"partialFingerprints":{"codehealthFindingId/v1":"7c6df247052ab09bdbfab8b63d6dc2bc99b759eba808118add3485b9b7f51017"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: crates/loro-internal/src/state/dead_containers_cache.rs: crates/loro-internal/src/state/dead_containers_cache.rs 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 12 (its worst body is DocState::is_deleted 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: prevent quadratic cache clears and preserve fork text styles (#1174)\u201D; \u201Cfix: issue sweep (#1118, #1162, #1155, #1165, #1156, #1164, #1157, #1154, #1151; #1149 documented) (#1171)\u201D; \u201Cfix: drop cached container deletions that a move can undo (#1153)\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-15..2026-11-13, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-15 00:57:59 -08:00\u0027 --until=\u00272026-11-13 00:57:59 -08:00\u0027 --full-history --no-merges -- crates/loro-internal/src/state/dead_containers_cache.rs\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":"crates/loro-internal/src/state/dead_containers_cache.rs"},"region":{"startLine":47}}}],"partialFingerprints":{"codehealthFindingId/v1":"545808566da85589c19cad17794b24d3d44be2b4d4c55e3b2ad491e65d5b8a45"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: loro-js/scripts/rewrite-rust-fixture.mjs: loro-js/scripts/rewrite-rust-fixture.mjs 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 9 (its worst body is rewrite-rust-fixture.normalizeRuntimeJson at line 303), 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(loro.js): model MovableList like Rust (positions and LWW elements) (#1166)\u201D; \u201Cfix(loro.js): keep rich-text style anchors in the text sequence (#1137)\u201D; \u201Cfix: encode loro.js tree state in Rust sibling order and tolerate out-of-order siblings (#1108)\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-15..2026-11-13, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-15 00:57:59 -08:00\u0027 --until=\u00272026-11-13 00:57:59 -08:00\u0027 --full-history --no-merges -- loro-js/scripts/rewrite-rust-fixture.mjs\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":"loro-js/scripts/rewrite-rust-fixture.mjs"},"region":{"startLine":303}}}],"partialFingerprints":{"codehealthFindingId/v1":"eab21b01c4511173f92239966ce419348c643016b6c3474e98cb56213794fe2c"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: loro-js/src/runtime/types.ts: loro-js/src/runtime/types.ts 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 (anonymous) at line 171), 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(loro.js): include reattached child containers\u0027 state in diff() and revertTo() (#1131)\u201D; \u201Cfix(loro.js): write counter and binary JSON values in Rust\u0027s format (#1133)\u201D; \u201Cfix(loro.js): use the Rust \u0060L{lamport}@{peer}\u0060 format for movable-list JSON element IDs (#1129)\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-15..2026-11-13, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-15 00:57:59 -08:00\u0027 --until=\u00272026-11-13 00:57:59 -08:00\u0027 --full-history --no-merges -- loro-js/src/runtime/types.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":"loro-js/src/runtime/types.ts"},"region":{"startLine":171}}}],"partialFingerprints":{"codehealthFindingId/v1":"52e4fd9d90c527add39685b0c2db677a0f881bb7e15d90be6ce3504ba3ff9f2f"}},{"ruleId":"D16","level":"note","message":{"text":"Off-boarding risk: anonymized user #1: If anonymized user #1 becomes unavailable, 25 significant file(s) lose their only recent owner: loro-js/src/runtime/document.ts, loro-js/src/runtime/sequence-index.ts, loro-js/src/runtime/containers.ts, crates/generic-btree/src/lib.rs, crates/generic-btree/src/generic_impl/rope.rs, crates/loro-internal/src/state/movable_list_state.rs, crates/loro-internal/src/container/richtext/tracker/id_to_cursor.rs, loro-js/src/runtime/movable-list.ts (\u002B17 more). Pair on, review, or document these before any departure."},"locations":[],"partialFingerprints":{"codehealthFindingId/v1":"0697e6324be7ad0dca3537fe44de26925342c6c5285e36a9eb510aa89e3d62ce"}},{"ruleId":"D16","level":"note","message":{"text":"Further sole-owners (lower concentration): 1 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 (27 single-owned of 202 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; 202 of the 272 production source files in this repository met that bar). They are anonymized user #2 (1 file(s)) \u2014 spread or document their files in the same way, at lower priority than the named off-boarding risks above. The files folded here: crates/loro-internal/src/utils/query_by_len.rs."},"locations":[],"partialFingerprints":{"codehealthFindingId/v1":"6eac528f2429e724e1a97ed868f79eefbcf1888dab4af9a9e673429369bb5b2f"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: // TODO: unobserve \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":"examples/loro-quill/src/binding.ts"},"region":{"startLine":164}}}],"partialFingerprints":{"codehealthFindingId/v1":"e71a09d95a7e5f29e2a755f60a79fc3a6173304cff0eea737a2bb3a4400e6b8d"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: // TODO: convert event and event sub config \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":"crates/loro-wasm/src/lib.rs"},"region":{"startLine":2120}}}],"partialFingerprints":{"codehealthFindingId/v1":"3fb12f22f1e480fb0fb9112fb9a254cf1bab9a29ca0ddaf823cba33b0e901947"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: // TODO: avoid converting \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":"crates/loro-wasm/src/lib.rs"},"region":{"startLine":5067}}}],"partialFingerprints":{"codehealthFindingId/v1":"220ab1a5bc1dc6c8e7f4d5ed10d4658c0dd35149167ac63d8fe04e40890b44e8"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: // TODO: perf \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":"crates/loro-wasm/src/lib.rs"},"region":{"startLine":5437}}}],"partialFingerprints":{"codehealthFindingId/v1":"622b80b454d6f88af54924a8dde6654dc30aa48d01af30abe73a39c54cbee010"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: // TODO: PERF: avoid this clone \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":"crates/loro-wasm/src/lib.rs"},"region":{"startLine":6470}}}],"partialFingerprints":{"codehealthFindingId/v1":"5b8a5b9b73b649412003e44c2ae04e7a64507ad08480576382b895961de13052"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: // TODO: polyfill FinalizationRegistry \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":"crates/loro-wasm/scripts/build.ts"},"region":{"startLine":228}}}],"partialFingerprints":{"codehealthFindingId/v1":"e057b97f6679a61e6fee59ffae0a37f9d3de36a978ced1ce17724f48792d704a"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: // TODO: PERF: we can speed this up by use a special bit in ContainerIdx to indicate \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":"crates/loro-internal/src/arena.rs"},"region":{"startLine":585}}}],"partialFingerprints":{"codehealthFindingId/v1":"e05125fb10dc271346e806fcf778411632f3f167fa49075264897a47422c701c"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: // TODO: feels slow, need to confirm whether this affects performance \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":"crates/loro-internal/src/change.rs"},"region":{"startLine":202}}}],"partialFingerprints":{"codehealthFindingId/v1":"656d8cf305e5fc48618fbc1b9cec53c08f32b4179c40dc2d5a7ac0a9706bc714"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: /// TODO: make this type private in this crate only \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":"crates/loro-internal/src/container.rs"},"region":{"startLine":22}}}],"partialFingerprints":{"codehealthFindingId/v1":"d1a4f9b2b5bf868cf463ff95ed121a9ef56d6bb1b3964a9f57e01fd022429787"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: // TODO: PERF: use NonZeroU32 to save memory \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":"crates/loro-internal/src/container.rs"},"region":{"startLine":29}}}],"partialFingerprints":{"codehealthFindingId/v1":"4e2ec7e0bd7b2a87ede1ed767ca3d78b77c1e5102894eca40c1a95d3e5a7ce57"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: // TODO: perf: make it also return the spans to reach the replay base \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":"crates/loro-internal/src/dag.rs"},"region":{"startLine":157}}}],"partialFingerprints":{"codehealthFindingId/v1":"d40631e95a3d53ebf5be9189393a4d4d1abba6d508174a13208847af61dbf6aa"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: /// TODO: persist diffCalculator and skip processed version \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":"crates/loro-internal/src/diff_calc.rs"},"region":{"startLine":59}}}],"partialFingerprints":{"codehealthFindingId/v1":"b4cd1d3480cfb1dc763faba29081473488e7ee99912927669ecf629f07c3e06b"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: // TODO: we may remove depth info \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":"crates/loro-internal/src/diff_calc.rs"},"region":{"startLine":470}}}],"partialFingerprints":{"codehealthFindingId/v1":"467fe6828601f168408c228ba074876b799fcc60789c85d4f00bb3e1d48f814f"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: /// TODO: Refactor, this can be simplified \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":"crates/loro-internal/src/diff_calc.rs"},"region":{"startLine":1266}}}],"partialFingerprints":{"codehealthFindingId/v1":"4dbf6fd2bb8d5e6b5dd374514500cde95dad5d01cb5372b3eb01292a0e25a0b3"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: // TODO: PERF: Provide the lamport of to version \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":"crates/loro-internal/src/diff_calc.rs"},"region":{"startLine":2298}}}],"partialFingerprints":{"codehealthFindingId/v1":"f007724b7d3d31c02c56bbfbe2a58d44317a6ad61bb20afb37d96beddea20964"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: // TODO: PERF: Provide the lamport of to version \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":"crates/loro-internal/src/diff_calc.rs"},"region":{"startLine":2303}}}],"partialFingerprints":{"codehealthFindingId/v1":"c42f49ad39f1ce3678ecb106d9dd5abcc7917b436b5fb837fdc26cd6b4d5d876"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: // TODO: PERF: Provide the lamport of to version \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":"crates/loro-internal/src/diff_calc.rs"},"region":{"startLine":2307}}}],"partialFingerprints":{"codehealthFindingId/v1":"e828385fc31ccdd3c08d215e1f47b5a308485d1a400dd5524bc6682002ffd5c3"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: // TODO: PERF: Provide the lamport of to version \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":"crates/loro-internal/src/diff_calc.rs"},"region":{"startLine":2309}}}],"partialFingerprints":{"codehealthFindingId/v1":"b977ddc8b54d3e3549e10e4ac7f8cc49c8ae0201dc805a433add436817d857bc"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: // TODO: PERF: can be filtered based on the list_diff and whether the pos/value are updated \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":"crates/loro-internal/src/diff_calc.rs"},"region":{"startLine":2323}}}],"partialFingerprints":{"codehealthFindingId/v1":"2c922ddefa93f5cc1758c400a8b2efbf3134234eae5b6f2235a7080bc95e4018"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: // TODO: PERF: should we use hashmap to filter latest_ids with the same peer first? \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":"crates/loro-internal/src/encoding.rs"},"region":{"startLine":324}}}],"partialFingerprints":{"codehealthFindingId/v1":"f9cf0213be7aaa20201d2ec276a687fdda31512970e9d9a8b9390d0394fbe5eb"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: // TODO: describe this behavior in the document \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":"crates/loro-internal/src/handler.rs"},"region":{"startLine":2513}}}],"partialFingerprints":{"codehealthFindingId/v1":"a41ec8ddc2881314ddecedaaedcea42321fc4ceff17b6550ddc4710ebc31b5d6"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: // TODO: implement \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":"crates/loro-internal/src/handler.rs"},"region":{"startLine":2683}}}],"partialFingerprints":{"codehealthFindingId/v1":"0aadb7a1cb63b5470215a5cabafb7c4393483b5a41a0107e008c10df0d6d548f"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: // TODO: FIXME: This could be super slow in some cases \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":"crates/loro-internal/src/history_cache.rs"},"region":{"startLine":410}}}],"partialFingerprints":{"codehealthFindingId/v1":"9643e2944ac49723af3a99740d22ec2e6b45eff9513609544f730099a62e502e"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: // TODO: rename as Key? \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":"crates/loro-internal/src/lib.rs"},"region":{"startLine":90}}}],"partialFingerprints":{"codehealthFindingId/v1":"c8c7adc5b3eefc1c7edb02bc63839d0a3f6a5d24834e3667c4a52e475865cfc6"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: // TODO: test when the doc is readonly \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":"crates/loro-internal/src/loro.rs"},"region":{"startLine":1828}}}],"partialFingerprints":{"codehealthFindingId/v1":"95560843d896589da5e24c5038f07ba7730937ce56ad2b51f442f5ae1581a37f"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: // TODO: test when the doc is detached but enabled editing \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":"crates/loro-internal/src/loro.rs"},"region":{"startLine":1829}}}],"partialFingerprints":{"codehealthFindingId/v1":"5635071469828c91323a0139a6c65f994245a7ea81e6fb62ea28e6e0843024ed"}},{"ruleId":"D17","level":"warning","message":{"text":"FixmeComment: // FIXME: This method needs testing (no event should be emitted during processing this) \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":"crates/loro-internal/src/loro.rs"},"region":{"startLine":1845}}}],"partialFingerprints":{"codehealthFindingId/v1":"50b28b36b95eadcf867428bc84522626964a9b50e31f52ff3acc832bc4561636"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: // TODO: assert pos.id is not unknown \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":"crates/loro-internal/src/loro.rs"},"region":{"startLine":3745}}}],"partialFingerprints":{"codehealthFindingId/v1":"7b9727024f33e38d4c92f574a53ad9003f97e37a8626fcc87bbe6f5753ea8a32"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: // TODO: PERF: it doesn\u0027t need to calc the effects here \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":"crates/loro-internal/src/loro.rs"},"region":{"startLine":3770}}}],"partialFingerprints":{"codehealthFindingId/v1":"1857e21a73d14a2e2fcbfbcedf4bc015a83f20b183fefee51051be1ff323b41d"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: // TODO: remove depth info \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":"crates/loro-internal/src/loro.rs"},"region":{"startLine":3779}}}],"partialFingerprints":{"codehealthFindingId/v1":"743f6ddb71d378c5d3cb758b52020b27aa4648520e64d1c3c60c8d3c7a4a6b9f"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: // TODO: use benchmark to get the optimal estimated size for each container type \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":"crates/loro-internal/src/op.rs"},"region":{"startLine":32}}}],"partialFingerprints":{"codehealthFindingId/v1":"7c0b802a4d7dc353eec7573dde650e0ab051f4a7f235986589e14f29def4c453"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: // TODO: maybe we could create map container only when setting metadata \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":"crates/loro-internal/src/parent.rs"},"region":{"startLine":100}}}],"partialFingerprints":{"codehealthFindingId/v1":"2fe0ba7285a66658d1cebc15cf4454888e811e40cb7980f69f117bd849e5b1f6"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: // TODO: maybe we should switch to certain version in oplog? \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":"crates/loro-internal/src/state.rs"},"region":{"startLine":505}}}],"partialFingerprints":{"codehealthFindingId/v1":"106c623022bbb7cdb80860c7fca90e1fb03ce7744cf6ea9e51db72e4de536e73"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: // TODO: use a more efficient data structure \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":"crates/loro-internal/src/txn.rs"},"region":{"startLine":209}}}],"partialFingerprints":{"codehealthFindingId/v1":"29a3907df910db8e316e3b8006d49da381eeaecb13542e8612b561e5d02aab4d"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: // TODO: should we abort here or commit here? \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":"crates/loro-internal/src/txn.rs"},"region":{"startLine":948}}}],"partialFingerprints":{"codehealthFindingId/v1":"860c82513a5913457c2a9fbb05e3189775693a7afa70a5269715267e5a123395"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: // TODO: PERF undo can be significantly faster if we can get \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":"crates/loro-internal/src/undo.rs"},"region":{"startLine":761}}}],"partialFingerprints":{"codehealthFindingId/v1":"a8ba7c2b97452f7809a0e3385047b28a95b174fa2f431b14fcffb80777505169"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: // TODO: rename this trait \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":"crates/loro-internal/src/value.rs"},"region":{"startLine":12}}}],"partialFingerprints":{"codehealthFindingId/v1":"30208169f33cce590d3d1cdc521bdec9ced41f5ca06855820c1f91a32dfc6f49"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: // TODO: refactor: should we extract the common code of ToJson and ToJsValue \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":"crates/loro-internal/src/value.rs"},"region":{"startLine":1173}}}],"partialFingerprints":{"codehealthFindingId/v1":"33fe011fc998fc8c8e0ac86e530e1bd18960650e4dbe7f549747c1cba034f337"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: //         // TODO: Extract magic num \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":"crates/loro-internal/src/utils/string_slice.rs"},"region":{"startLine":231}}}],"partialFingerprints":{"codehealthFindingId/v1":"519018639cc0a974e172ee14efd5998ac9ad83b96749a10f0f1424c4ae04ef2a"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: // TODO: FIXME: Tests \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":"crates/loro-internal/src/utils/utf16.rs"},"region":{"startLine":37}}}],"partialFingerprints":{"codehealthFindingId/v1":"7ff3bfb5025eda935371574720933413f6f3d8a03c7239bae94baf9303f36ed9"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: // TODO: may be better to find a way clean up these invalid elements? \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":"crates/loro-internal/src/state/movable_list_state.rs"},"region":{"startLine":468}}}],"partialFingerprints":{"codehealthFindingId/v1":"05b0088b1b2ff93a2f12e89b4dd2652acfad189c1f3d06c05dc917bfde77e084"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: // TODO: refactor \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":"crates/loro-internal/src/state/richtext_state.rs"},"region":{"startLine":390}}}],"partialFingerprints":{"codehealthFindingId/v1":"f1f0d459a0693896bee05dbd702e1b4c2f5e4cd3bcf96dc6e85ba60eac951200"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: // TODO: the min length between left and right \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":"crates/loro-internal/src/state/tree_state.rs"},"region":{"startLine":193}}}],"partialFingerprints":{"codehealthFindingId/v1":"8a5c3bfb969a1b71e38443ee18e0240ee1170cbc13da94f91f265d76b3e97888"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: // TODO: the min length between left and right \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":"crates/loro-internal/src/state/tree_state.rs"},"region":{"startLine":1741}}}],"partialFingerprints":{"codehealthFindingId/v1":"6b20a56117542e1f51d323c299f4818f8940ec01af6b2b71c058ba3f52854955"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: // TODO: Refactor: you can include the index and parent in the q \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":"crates/loro-internal/src/state/tree_state.rs"},"region":{"startLine":1455}}}],"partialFingerprints":{"codehealthFindingId/v1":"956589a6702063ebed465ee085088db9e4964195de393f6a891725a2485fe026"}},{"ruleId":"D17","level":"warning","message":{"text":"FixmeComment: // FIXME: it\u0027s not very accurate... \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":"crates/loro-internal/src/state/container_store/container_wrapper.rs"},"region":{"startLine":811}}}],"partialFingerprints":{"codehealthFindingId/v1":"f1ecb178e95d4ed56940775028701e105c2f828ac83218a8cfd10471470ce3cd"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: // TODO: add assert that all containers in the store should be empty right now \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":"crates/loro-internal/src/state/container_store/inner_store.rs"},"region":{"startLine":571}}}],"partialFingerprints":{"codehealthFindingId/v1":"1d23adaa764756c20c0157fac0ad15c883dbf8de95d00d2e3183b184470da04f"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: // TODO: PERF avoid alloc \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":"crates/loro-internal/src/oplog/change_store.rs"},"region":{"startLine":1139}}}],"partialFingerprints":{"codehealthFindingId/v1":"e0bcc3ea5d6501049af39a96f3ab1431b5bef05fbe7f887eba21b2ccf3e5f1e9"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: // TODO: makes some assertions here? \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":"crates/loro-internal/src/oplog/change_store.rs"},"region":{"startLine":1440}}}],"partialFingerprints":{"codehealthFindingId/v1":"0ce870e2ad7f28e5a886deeba76e4803e1c1ad295042c92e988f6219f71f0cb8"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: // TODO: PERF: This method feels slow. \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":"crates/loro-internal/src/oplog/change_store.rs"},"region":{"startLine":1996}}}],"partialFingerprints":{"codehealthFindingId/v1":"16df3c62600606da64089a28fa2b6c695d1e1c1ee3a6e54eb89e428b2b83dc3a"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: // TODO: PERF: We can use Iter to replace Vec \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":"crates/loro-internal/src/oplog/change_store.rs"},"region":{"startLine":2409}}}],"partialFingerprints":{"codehealthFindingId/v1":"1f5882687ae6aafa4d0282f303cae41be738042c5679d540f1a776f2b18961e1"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: // TODO: Perf we can calculate header directly without parsing the bytes \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":"crates/loro-internal/src/oplog/change_store.rs"},"region":{"startLine":2532}}}],"partialFingerprints":{"codehealthFindingId/v1":"91a4fbc57c13994988ce116d96b92b71d6121aa2dc48180f643f87e11f6fae12"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: // TODO: Refactor, remove this? \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":"crates/loro-internal/src/oplog/pending_changes.rs"},"region":{"startLine":24}}}],"partialFingerprints":{"codehealthFindingId/v1":"1bb305ce43d79b34139304b0e2c7e66ce977d24420247fa0808620e9dc1df983"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: // TODO: capacity \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":"crates/loro-internal/src/oplog/change_store/block_meta_encode.rs"},"region":{"startLine":67}}}],"partialFingerprints":{"codehealthFindingId/v1":"62513aa46f215a1d5c312bc845836b557a9d8a27b94efe1f3ceba0d2ca70dd0d"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: // TODO: accept span/position for better errors \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":"crates/loro-internal/src/jsonpath/parser.rs"},"region":{"startLine":489}}}],"partialFingerprints":{"codehealthFindingId/v1":"ee85c96004a4f0d5f4a1d0fd80e284811a675315a1b61b99b9fb26edf2487efe"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: // TODO: accept span/position for better errors \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":"crates/loro-internal/src/jsonpath/parser.rs"},"region":{"startLine":544}}}],"partialFingerprints":{"codehealthFindingId/v1":"730a435c69a98e39c568cc693cfb62210f52af1901f3c7e073521d3946473f61"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: // TODO: parent has deleted\uFF1F \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":"crates/loro-internal/src/handler/tree.rs"},"region":{"startLine":498}}}],"partialFingerprints":{"codehealthFindingId/v1":"81a50c157b8ea6d8ffa0aba8e175c144b64738d5a381d725d396f8e0d8789897"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: // TODO: iterator \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":"crates/loro-internal/src/handler/tree.rs"},"region":{"startLine":901}}}],"partialFingerprints":{"codehealthFindingId/v1":"6224733eb7cc204d9a5a352bc9a50bb7e80566a1c57109c7b70ae0ca9d14e7c5"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: // TODO: PERF: this can be optimized by reusing the bytes of gc store \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":"crates/loro-internal/src/encoding/fast_snapshot.rs"},"region":{"startLine":313}}}],"partialFingerprints":{"codehealthFindingId/v1":"9367a262a8fe27b22c669d6f50c0dffcd733b2e0e768457e71ddd2d7aed96777"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: // TODO: PERF use \u0026mut self and \u0026other \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":"crates/loro-internal/src/delta/seq.rs"},"region":{"startLine":521}}}],"partialFingerprints":{"codehealthFindingId/v1":"863e62de3ba10bdc9f83cd03b2941c659d4f611e49fea0b74a2af5daa815592d"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: // TODO: cannot handle this for now \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":"crates/loro-internal/src/delta/tree.rs"},"region":{"startLine":191}}}],"partialFingerprints":{"codehealthFindingId/v1":"4e0acef6b27be6f176c49f21ccf6046854fc71f62556873b8a745dfe5a74b31f"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: // TODO: change visibility back to crate after #116 is done"},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/container/richtext.rs"},"region":{"startLine":48}}}],"partialFingerprints":{"codehealthFindingId/v1":"5b6f76469f74d96306c6db771c4a288422a42fddb64d1cf9a57aaee77289c26f"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: // TODO: change visibility back to crate after #116 is done"},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/container/richtext/richtext_state.rs"},"region":{"startLine":735}}}],"partialFingerprints":{"codehealthFindingId/v1":"f1d87ac5bfb4991f452a8eb3e345a7d0ee08ec0e5fee663c1a063229bcecf88f"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: /// TODO: We can remove this type already \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":"crates/loro-internal/src/container/richtext.rs"},"region":{"startLine":128}}}],"partialFingerprints":{"codehealthFindingId/v1":"122d466f816d7b0bfc55718ec684764b74da9f3cddb1c036288949cef00bb5ea"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: // TODO: use boolrle to encode the has_effects array \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":"crates/loro-internal/src/container/tree/bool_rle_vec.rs"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"2dfaaee9c542d9bedc8ebf70f01d9ca999a2549d664026f175b8bf728ab14531"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: //TODO: start/end can be scanned in one loop, but now it takes twice the time \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":"crates/loro-internal/src/container/richtext/richtext_state.rs"},"region":{"startLine":959}}}],"partialFingerprints":{"codehealthFindingId/v1":"281f9c59c91b838bec42d79bc1d9de05baf3382b577d34574f292bc7069b2858"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: // TODO: if we remove the use of query(pos-1), we won\u0027t need this fallback behavior \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":"crates/loro-internal/src/container/richtext/richtext_state.rs"},"region":{"startLine":1318}}}],"partialFingerprints":{"codehealthFindingId/v1":"2fa75238b78dcec28052b63de68766e347b58d06ff12206c0a4507bd438ead5a"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: // TODO: if we remove the use of query(pos-1), we won\u0027t need this fallback behavior \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":"crates/loro-internal/src/container/richtext/richtext_state.rs"},"region":{"startLine":1398}}}],"partialFingerprints":{"codehealthFindingId/v1":"54ed8a2cdad78135fffeaa1123a84da2f40f5abb49c67611c8cbb7f4c62020b5"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: // TODO: PERF we can avoid this calculation by getting it when inserting new text \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":"crates/loro-internal/src/container/richtext/richtext_state.rs"},"region":{"startLine":1583}}}],"partialFingerprints":{"codehealthFindingId/v1":"cb579b1ae951f10dd14c8c600c3aefeb664b76c58f30de98d53a235c5fba63a3"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: // TODO: assert end cursor is valid \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":"crates/loro-internal/src/container/richtext/richtext_state.rs"},"region":{"startLine":2047}}}],"partialFingerprints":{"codehealthFindingId/v1":"3ea31fc25331f83092adfc637a22349336ef1ac62e240ecf9e17548f26501e9d"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: // TODO: PERF this can be sped up from O(n) to O(log(n)) but I\u0027m not sure if it\u0027s worth it \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":"crates/loro-internal/src/container/richtext/tracker.rs"},"region":{"startLine":651}}}],"partialFingerprints":{"codehealthFindingId/v1":"440e48a7cf446bb230125a9aae3311343ba09e13cd5453ccbc03e4927c171513"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: // TODO: PERF: optimize this \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":"crates/loro-internal/src/container/richtext/tracker/crdt_rope.rs"},"region":{"startLine":269}}}],"partialFingerprints":{"codehealthFindingId/v1":"e280e551d235cd782d7a7c05bfd9928662ffe8da426e8ead7f139ae6adf12509"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: // TODO: this should be impossible \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":"crates/loro-internal/src/container/richtext/tracker/crdt_rope.rs"},"region":{"startLine":623}}}],"partialFingerprints":{"codehealthFindingId/v1":"279f05bba7383a0106bbfeabbaffc52faab2c38e3d482f75ed21fbcb1cd2546b"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: // TODO: this should be impossible \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":"crates/loro-internal/src/container/richtext/tracker/crdt_rope.rs"},"region":{"startLine":681}}}],"partialFingerprints":{"codehealthFindingId/v1":"14ccca32a645490fd70f5be91c29d7f21d50dc2e02594b52eb90fd2d25fc4a37"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: // TODO: this is only used for list now? We should rename it to InsertList \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":"crates/loro-internal/src/container/list/list_op.rs"},"region":{"startLine":48}}}],"partialFingerprints":{"codehealthFindingId/v1":"ae1d35b61bb71b6061f38443284de9d1e8f2275aa387ca4fb819e8318dfc07fe"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: //                     // TODO: use import batch here \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":"crates/loro-internal/examples/mem.rs"},"region":{"startLine":73}}}],"partialFingerprints":{"codehealthFindingId/v1":"93ffe313f79b860f417cd6ac5797bf0230aafef1f61eeac5d861bb0c5d5edfdf"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: // TODO: add non_exhausted \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":"crates/loro-common/src/lib.rs"},"region":{"startLine":798}}}],"partialFingerprints":{"codehealthFindingId/v1":"183945ded51f2656e44c5f1c8e4072578da9750ea4ab7a1acd379952d173ffc9"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: // TODO: can use a NonMax here \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":"crates/loro-common/src/lib.rs"},"region":{"startLine":1238}}}],"partialFingerprints":{"codehealthFindingId/v1":"fe40fff624b81d209bacad911ce2fa7c06195996a774b7eb4dd381b3ca54177e"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: // TODO: should be private. user should not be able to change start from smaller than end to be greater than end \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":"crates/loro-common/src/span.rs"},"region":{"startLine":13}}}],"partialFingerprints":{"codehealthFindingId/v1":"d6261912d52d4816f8682db3e288f85f3023de73794ad732457b42610ca45dc1"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: // TODO: should be private \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":"crates/loro-common/src/span.rs"},"region":{"startLine":15}}}],"partialFingerprints":{"codehealthFindingId/v1":"110c05231bc3e68d9658495d5c28eb2149fd2701f39c8301445c43882c2ebebc"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: // TODO: add checks for too deep value, and return err if users \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":"crates/loro-common/src/value.rs"},"region":{"startLine":429}}}],"partialFingerprints":{"codehealthFindingId/v1":"ebcd2b65678ad511ecd4ca8abc1b112235955f3de4bfa476ce95b8758b697d77"}},{"ruleId":"D17","level":"warning","message":{"text":"FixmeComment: // FIXME: right now redo/undo like this is wasteful \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":"crates/loro/tests/integration_test/undo_test.rs"},"region":{"startLine":800}}}],"partialFingerprints":{"codehealthFindingId/v1":"2e2eeab926a72e16bc534d06070a9722e7b36f65b3cc7f4a15bd305f28768578"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: // TODO: PERF \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":"crates/kv-store/src/mem_store.rs"},"region":{"startLine":188}}}],"partialFingerprints":{"codehealthFindingId/v1":"aed440e210ec3887515bcc02029cbbcd2c6379d70de70ef0b568e54c68afa07c"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: // TODO: bloom filter \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":"crates/kv-store/src/sstable.rs"},"region":{"startLine":162}}}],"partialFingerprints":{"codehealthFindingId/v1":"3ec7c87bdacdb53fcea7b13c15bc17392ae97f641ada00d4e938d44671460505"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: // TODO: mmap? \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":"crates/kv-store/src/sstable.rs"},"region":{"startLine":344}}}],"partialFingerprints":{"codehealthFindingId/v1":"42a887165a303937594f5c86503882adeb53118cf05fae0bd4b2be4bd65bcee0"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: /// TODO: we may use a constant as root index \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":"crates/generic-btree/src/lib.rs"},"region":{"startLine":68}}}],"partialFingerprints":{"codehealthFindingId/v1":"0fefc1f3e3248fc72bab40bc90c31598f92807cc5f4c9239f5ca37ddb7335cb5"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: // TODO: PERF this can be optimized further \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":"crates/generic-btree/src/lib.rs"},"region":{"startLine":753}}}],"partialFingerprints":{"codehealthFindingId/v1":"4935047ee9025067cf55dd299514871b6e9aa5475a434b8ec0967178152e8c77"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: /// TODO: need better test coverage \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":"crates/generic-btree/src/lib.rs"},"region":{"startLine":997}}}],"partialFingerprints":{"codehealthFindingId/v1":"5793499edc74713ae4b287b5c5ba0fa6e9c001f04f33ca8b7cbe73d721fd4e44"}},{"ruleId":"D17","level":"warning","message":{"text":"FixmeComment: // FIXME: make this work \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":"crates/generic-btree/src/lib.rs"},"region":{"startLine":2132}}}],"partialFingerprints":{"codehealthFindingId/v1":"2d223ad238ef9d32546f7430585a3624643a9d65b50875e931e8a1b2a610f800"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: // TODO: move Rope into a separate project \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":"crates/generic-btree/src/generic_impl/rope.rs"},"region":{"startLine":23}}}],"partialFingerprints":{"codehealthFindingId/v1":"501235d10c712e48ea917f7475cb3d539a720829a95e0ef65e505343920c76c4"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: // TODO: need one more test case for binary unknown \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":"crates/fuzz/tests/json.rs"},"region":{"startLine":55}}}],"partialFingerprints":{"codehealthFindingId/v1":"7518585383f51beeb2f22fb7d3fa1c231de160c164b31ff19986450477ba16e4"}},{"ruleId":"D17","level":"warning","message":{"text":"FixmeComment: // FIXME: transform the attributes \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":"crates/delta/src/delta_rope.rs"},"region":{"startLine":280}}}],"partialFingerprints":{"codehealthFindingId/v1":"f42b857f0663fa8406a305086b3eee1b93045b4551cbb9f4d1d61f89271919dc"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: // TODO: Need to implement a slow mode that is guaranteed to be correct, then we can fuzz on it \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":"crates/delta/src/delta_rope/compose.rs"},"region":{"startLine":11}}}],"partialFingerprints":{"codehealthFindingId/v1":"205de036487e982cf4c6699f93b47468bdddf3c60ec9b689d7b8ab3023e59c6f"}},{"ruleId":"D19","level":"note","message":{"text":"Documentation: no build, run or usage example: \u0060loro-wasm-map\u0060 is a published package (\u0060package.json\u0060 without \u0060\u0022private\u0022: true\u0060) and neither \u0060crates/loro-wasm-map/README.md\u0060 nor the documents it links hold a code block or a command. Show the command that builds or runs it, or a usage snippet."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-wasm-map/README.md"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"74f3935249566161a71c4647017d7349e5134b4e61822ae427b67e41f67867c8"}},{"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 \u0060crates/loro-wasm-tools/src/main.rs\u0060 makes this repository a deployable product (line 1)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-wasm-tools/src/main.rs"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"cc13e2630e4ab2e11aa77162ece88e5266ccc2b30dd3a01ab28e29a6ff382ba0"}},{"ruleId":"D24","level":"note","message":{"text":"redundant comment: \u0022Update existing comment\u0022 repeats the code it sits on: 3 of its 3 words (update, existing, comment) are already in \u0060await octokit.rest.issues.updateComment({\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":"crates/loro-wasm/scripts/build.ts"},"region":{"startLine":151}}}],"partialFingerprints":{"codehealthFindingId/v1":"d259598ef706b6668a47f514a93bf210c4d511678ba317db6eb2102351b70907"}},{"ruleId":"D24","level":"note","message":{"text":"redundant comment: \u0022Insert a text container to the list\u0022 repeats the code it sits on: 4 of its 4 words (insert, text, container, list) are already in \u0060const text = list.insertContainer(0, new LoroText());\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":"crates/loro-wasm/tests/basic.test.ts"},"region":{"startLine":48}}}],"partialFingerprints":{"codehealthFindingId/v1":"668b3ef504e30cb50198c7f4a22918a5bcbdc8a80483fd53c75fbc27662cec6d"}},{"ruleId":"D24","level":"note","message":{"text":"redundant comment: \u0022Export JSON updates\u0022 repeats the code it sits on: 3 of its 3 words (export, json, updates) are already in \u0060const jsonUpdates = doc.exportJsonUpdates();\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":"crates/loro-wasm/tests/basic.test.ts"},"region":{"startLine":1715}}}],"partialFingerprints":{"codehealthFindingId/v1":"a61a340811a3ec9b52977bdd642aa1335e302b9b7d80ea9d1770a643d9d6c90f"}},{"ruleId":"D24","level":"note","message":{"text":"redundant comment: \u0022Partial slice by UTF8\u0022 repeats the code it sits on: 3 of its 3 words (partial, slice, utf) are already in \u0060const partialDeltaUtf8 = text.sliceDeltaUtf8(3, 10);\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":"crates/loro-wasm/tests/richtext.test.ts"},"region":{"startLine":548}}}],"partialFingerprints":{"codehealthFindingId/v1":"bccc84fa265686feeaf0f49ab522f8b76f1f177d5141c9e5d316a1c62ded833a"}},{"ruleId":"D24","level":"note","message":{"text":"redundant comment: \u0022Empty slice by UTF8\u0022 repeats the code it sits on: 3 of its 3 words (empty, slice, utf) are already in \u0060const emptyDeltaUtf8 = text.sliceDeltaUtf8(6, 6);\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":"crates/loro-wasm/tests/richtext.test.ts"},"region":{"startLine":556}}}],"partialFingerprints":{"codehealthFindingId/v1":"79c3ea1b3e44362b5382560ad36034880a3370f7971d20cb81ebb9c691d374b2"}},{"ruleId":"D24","level":"note","message":{"text":"redundant comment: \u0022Roots at \u0060from\u0060: [child, sibling].\u0022 repeats the code it sits on: 3 of its 3 words (roots, child, sibling) are already in \u0060expect(tree.roots().map((root) =\u003E root.id)).toEqual([child.id, sibling.id]);\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":"loro-js/tests/diff-attached-children.test.ts"},"region":{"startLine":751}}}],"partialFingerprints":{"codehealthFindingId/v1":"cf01df267597d5e19c4babe295f04bb518c5ff5ca619305d1ce4bbbd134a4c3a"}},{"ruleId":"D26","level":"note","message":{"text":"Projects may be oversized for their cohesion: 2 of 18 project(s) overshoot their size bounds, lowering Project Cohesion to 7.8/10. The most over is \u0060crates/loro-internal\u0060 (84009 LoC, 288 module-visible types across 23 directories). 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":[],"partialFingerprints":{"codehealthFindingId/v1":"d5a94650dc74886a0f1f08eb9fb6775f1fc395279ef7e901c970c9d26f767a72"}},{"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":"188cad5ab433e1af6c1a3c439b513376270008aae4f82e95aa3bd0b39fb61ca1"},"taxa":[{"id":"CWE-1357","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-353","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":"3332afcd7b59a8922b0c13cf74a78dc8473bdda31b146bc7890b3ef77a5add09"},"taxa":[{"id":"CWE-1357","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-353","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":"11ae367c56cb7a557ea925f48356293d7ab8792592692abd6032722e6c842e96"},"taxa":[{"id":"CWE-1357","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-353","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":"f6bbff21075c3290d67469f288691d2255fa696c258e157e5d9717c610b27089"},"taxa":[{"id":"CWE-78","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"A05: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":"5ea1f2f835b186926455638619997fe37bcebd046f1731ccc0262fad69a8409f"},"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":"420f10fac4ee6ba6432e61d19dd40adaa24eec7b111fa51b584218f675256771"},"taxa":[{"id":"CWE-1357","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-353","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":"7cdee743eb72e2fda54823fb5032a9791e54fa023ea538280f25cb3447c45cf4"},"taxa":[{"id":"CWE-522","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-829","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"A06:2025","toolComponent":{"name":"OWASP Top 10","guid":"7d1f0c2e-4b6a-4e39-9a51-0b2e8c3d5f61"}},{"id":"CICD-SEC-6","toolComponent":{"name":"OWASP Top 10 CI/CD Security Risks","guid":"3c9b2a6e-5d14-4f7b-8e02-6a1d9c4b7f35"}}]},{"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":"f263d29037dabe1a01f6022abd054027de70742f9f8a2a179b92c466246cd0d9"},"taxa":[{"id":"CWE-1357","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-353","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":"d89cbecc8bf9064f1b1700b7daea03711c6ba603d4365e2aec3b0b0156291a30"},"taxa":[{"id":"CWE-1357","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-353","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":"49eb12a881b2ed770b5207d59aafd6c2775d1a020977f4e944a98bb615bf6f9f"},"taxa":[{"id":"CWE-1357","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-353","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":"5fd6788dd01b9d3e829c24530743bc30bdb06c56566a24c725364d8572d60344"},"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":"31ebc1634048092e227be84c29baf49f503727791dac234d1e438a34f3cc46d1"},"taxa":[{"id":"CWE-1357","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-353","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":"c0bf2ae84e5c082fc2b4805a42840391c3f2bc9b50a44362f9252a64d8fc876a"},"taxa":[{"id":"CWE-1357","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-353","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":"bfdcfacdfd04c58dfe0fd1f792792c3c7e436e785bd9fd1594ada8f0c54612d5"},"taxa":[{"id":"CWE-1357","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-353","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":"c70d29d752cfee76165dbdf2db854964551c03d3ee76ed411df5a9e78e673ccf"},"taxa":[{"id":"CWE-1357","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-353","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":"b7d94dc4456af1c4ea025ab01939d541f8a8efea15836f61accd5649405c86e1"},"taxa":[{"id":"CWE-1357","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-353","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":"aaacce7dc6ab85c0f210e34cdb1ff9003858193191a649e5ba9d2c56a0c17727"},"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":"6814f65783dd73a586fe2ab1a4563bf85d75b5f4bfb15cc2430d18c337ce2140"},"taxa":[{"id":"CWE-1357","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-353","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":"212aa7790013b0d49bb4c225762bd9387546a630e4266196a98ad6e940c17d47"},"taxa":[{"id":"CWE-1357","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-353","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":"6798c69e6f18b2469ce87f0506811427f7284f1c2d2c46f0db54c1ee351c384a"},"taxa":[{"id":"CWE-1357","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-353","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":"dd9c2cae03161417de7dc0c9eebde105d00d6159209f219d579d424cc5fea972"},"taxa":[{"id":"CWE-1357","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-353","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":"e4045f771f644096ee489d44f5a6b96237899c05339ae6adb4d5d2c880254cfc"},"taxa":[{"id":"CWE-1357","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-353","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":"746d6d6012f6332e7c1136c069b850c87debebd91c7d9a1f4d6a30de6c61178f"},"taxa":[{"id":"CWE-522","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-829","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"A06:2025","toolComponent":{"name":"OWASP Top 10","guid":"7d1f0c2e-4b6a-4e39-9a51-0b2e8c3d5f61"}},{"id":"CICD-SEC-6","toolComponent":{"name":"OWASP Top 10 CI/CD Security Risks","guid":"3c9b2a6e-5d14-4f7b-8e02-6a1d9c4b7f35"}}]},{"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":"9547ffe1fe450c6c27db818620d208444635fcb2b5e8020d78e0fe53a6e209e3"},"taxa":[{"id":"CWE-1357","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-353","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":"4833f287ced3559a7fcc58208d11de3c3deabc7611b258f9a8f81d9afa93c190"},"taxa":[{"id":"CWE-1357","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-353","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":"a44c35afa89528fe46cacd5d2e41b4a961ca64c0efc54ac0c25674756cf62464"},"taxa":[{"id":"CWE-1357","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-353","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":"89bb37b903bc30f61450a2205ec954e925681e960fc56e28dec9f39c9a5a6c25"},"taxa":[{"id":"CWE-1357","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-353","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":"190143f1782993ada0981712880660db711ceeff1b41e0fc00c305b89cdc046e"},"taxa":[{"id":"CWE-1357","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-353","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":"af01e43f45983ffaa0259621bd9a0b24014aff01e659b4fbbbed39eae274eacc"},"taxa":[{"id":"CWE-1357","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-353","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":"82ea95433badd63e2ef7aa6d3bb679d25a28327770bf2320ef5ef45119771bcd"},"taxa":[{"id":"CWE-1357","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-353","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":"c2b215ab8c6976a3c7a564c46eff1cad43ca02b7fc5e4eac03875b19b54de5ec"},"taxa":[{"id":"CWE-1357","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-353","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":"ec93fe9c6b69af12fbfdb736a9ccebc5fdabacd9f7bdd7f32cae6cb88c72dc71"},"taxa":[{"id":"CWE-1357","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-353","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":"2dfc2a4be2e963d49f7e51f5f001fe4c2a4aa942c10bc1de791aa68af613c871"},"taxa":[{"id":"CWE-1357","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-353","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":"48642740cc1fef4ea45b483b7e0715fa69aff40ae8abf7f2a3ddf04e6f7c637d"},"taxa":[{"id":"CWE-1357","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-353","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":"fcfadbdbfb93d405bae15569019fa0c22435a0e2641c75af84494862ddbebdb9"},"taxa":[{"id":"CWE-1357","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-353","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":"8071ad6eeeff81e8ffc1126aa69d896308ba0f1e61b2fa19e8547b5dd94696e9"},"taxa":[{"id":"CWE-214","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"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":"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":"c00805316d7f3bd7860745e99914268460b68faeb8caa7711b7424b04dd0738a"},"taxa":[{"id":"CWE-1357","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-353","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":"7cf8a78c4a993aecafcb4fe2b18ecb6ff3aced137586a07de2812771fcf18756"},"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":"1498825690ee691422757d83c6c8726aaf69040fa62a3b6b71a03075f0880320"},"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":"85f99189d964cdde824a816d83f2290af0a3f7efe42feb1d6495743a90e33e22"},"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":"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":"ba5c804944f79e6291077dbf346747266cb5319338ffebd3be17d4deb5268d2f"},"taxa":[{"id":"CWE-1104","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-1329","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"A03:2025","toolComponent":{"name":"OWASP Top 10","guid":"7d1f0c2e-4b6a-4e39-9a51-0b2e8c3d5f61"}},{"id":"CICD-SEC-8","toolComponent":{"name":"OWASP Top 10 CI/CD Security Risks","guid":"3c9b2a6e-5d14-4f7b-8e02-6a1d9c4b7f35"}}]},{"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":"575c9cb1c5ecc60bbbba2b9c4cb7c6fd6e8c7da95ec859d13c20be5736b53fd6"},"taxa":[{"id":"CWE-209","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"A10: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":"6d891dd12737e6db14d1c06daad1225b55f64215651d42b9e30a5110021370cd"},"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":"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":"56980fd3efb23ea76b66953a577959f5665c3e227430595ec0171d14649f6a95"},"taxa":[{"id":"CWE-1164","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"A06: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":"8f01b2c8089368f2db25cefa98008903ecf1fc6f3f5d521b37f7ccd8a1afd5d2"},"taxa":[{"id":"CWE-1164","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"A06: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":"07f083f7b740d07b7de1af5daa9a9983d18f2344d50e9f61c489cb28a308bf5a"},"taxa":[{"id":"CWE-1164","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"A06:2025","toolComponent":{"name":"OWASP Top 10","guid":"7d1f0c2e-4b6a-4e39-9a51-0b2e8c3d5f61"}}]},{"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":"937dcdefb4bf1a58d81c822b70e4a0f19836d20d17c0ea8b26384434a47a6fe5"},"properties":{"dependency":{"package":"vite-plus","version":"0.1.20","advisory":"[GHSA redacted]","aliases":["[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]"],"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":"603117a00e7425dbcfdb4f52537cacb97cbf563e3ae2e30ce4a9a950467a6be1"},"properties":{"dependency":{"package":"vite-plus","version":"0.1.20","advisory":"[GHSA redacted]","aliases":["[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]"],"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":"162f3e9aff76cd38271bf286b12eebb04e622239377b0934b388b430cee039f1"},"properties":{"dependency":{"package":"tinypool","version":"0.8.4","advisory":"[GHSA redacted]","aliases":["[CVE redacted]","[CVE 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":"6713dd95e568a01a5ea0e367a0aa04a012bdc5db56e8068e98d7f5e96eed3182"},"properties":{"dependency":{"package":"tinypool","version":"2.1.0","advisory":"[GHSA redacted]","aliases":["[CVE redacted]","[CVE 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":"6e73274327a59fde3d7525c32eb900b994ffa4778e21ba83ba71c18747bd32c8"},"properties":{"dependency":{"package":"vitest","version":"1.6.0","advisory":"[GHSA redacted]","aliases":["[CVE redacted]","[CVE redacted]","[GHSA redacted]"],"reachability":{"kind":"production","file":"crates/loro-wasm/tests/apply_diff_atomicity.test.ts","line":1}}}},{"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":"bd96282e5ed93fc9b9bde601a594fe188db4eb1314e071fec5e163ce82ea76dc"},"properties":{"dependency":{"package":"lz4_flex","version":"0.11.5","advisory":"[GHSA redacted]","aliases":["[CVE redacted]","RUSTSEC-2026-0041"],"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":"4b2c94e93764572f4da161447084f0a45049ec62d9c47862eccfc516a5d0e031"},"properties":{"dependency":{"package":"nanoid","version":"3.3.4","advisory":"[GHSA redacted]","aliases":["[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[GHSA 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":"0158efdf5c8f6cef1a886c82edfc08ebe2b26bd83a24f637b032041f64bb4b74"},"properties":{"dependency":{"package":"source-map-js","version":"1.0.2","advisory":"[GHSA redacted]","aliases":["[CVE 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":"bf817e7fadefa16dec82cfb8428d6dd3718adb31b84c9334516a994a6cd34fa4"},"properties":{"dependency":{"package":"postcss","version":"8.4.21","advisory":"[GHSA redacted]","aliases":["[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[GHSA redacted]","[GHSA 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":"e0d2949fd2a6c0985a70ee02b552e9bcae3638873a4a7c2f89f5ce5bc2012cdf"},"properties":{"dependency":{"package":"rollup","version":"3.20.1","advisory":"[GHSA redacted]","aliases":["[CVE redacted]","[CVE 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":"ece7b6ed951a66de0c9f88f372e788c19a28bcfbe83a3995953135138cce1458"},"properties":{"dependency":{"package":"vite","version":"4.2.1","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]","[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":"e5665f710efe609672470dbfd34214cd3acdef38b2b22aa39fb7f06d6d660b64"},"properties":{"dependency":{"package":"@fastify/busboy","version":"2.1.1","advisory":"[GHSA redacted]","aliases":["[CVE redacted]","[CVE 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":"9d7f920c5cbc160da19501942753a062a52ea3c3b7d120d77460f14fd1a74372"},"properties":{"dependency":{"package":"undici","version":"5.29.0","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]","[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":"560b4b1ecd3da009c83d72e8f605f09606cbba047051b0e219f6fca967956ab6"},"properties":{"dependency":{"package":"vite","version":"8.0.10","advisory":"[GHSA redacted]","aliases":["[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]"],"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":"d430c79997da398f7e133bae2565482a2e2241a8a6656ee94cdafcbff0bf1714"},"properties":{"dependency":{"package":"vite","version":"8.0.10","advisory":"[GHSA redacted]","aliases":["[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]"],"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":"d0750c389d9c152bf1d4e31dfc91f23aff8c134e832845da27b3738c33162b18"},"properties":{"dependency":{"package":"@fastify/busboy","version":"2.1.1","advisory":"[GHSA redacted]","aliases":["[CVE redacted]","[CVE 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":"9ac84a30e76f156ffaf8b1a07ba543354f55dce81cdab924e234eb75a6360c4a"},"properties":{"dependency":{"package":"@vue/server-renderer","version":"3.4.27","advisory":"[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":"df21b8127d24aeed9579f3ce44f2f84d2d4f9ae41d6b03d4309b75c4781747cc"},"properties":{"dependency":{"package":"brace-expansion","version":"1.1.11","advisory":"[GHSA redacted]","aliases":["[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]"],"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":"6fde06abe7dac0b6bc6951df4e58a3dd77b634a2402a8ce8ec6bcc39669c05de"},"properties":{"dependency":{"package":"brace-expansion","version":"2.0.1","advisory":"[GHSA redacted]","aliases":["[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]"],"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":"39cbb0308a7d9b6fa91d7dac0f6a062698b816316803fdc894ca2f7374b42485"},"properties":{"dependency":{"package":"braces","version":"3.0.2","advisory":"[GHSA redacted]","aliases":["[CVE 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":"827b7ec075e0175685d5e08c1fe2a0c479c2932b575c7cf5ee6e9a47c1ba4155"},"properties":{"dependency":{"package":"cross-spawn","version":"5.1.0","advisory":"[GHSA redacted]","aliases":["[CVE 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":"11ac6849f9c0699766d0a9bb842820f2b29b1801221266a30cfc0b64716fa66b"},"properties":{"dependency":{"package":"cross-spawn","version":"7.0.3","advisory":"[GHSA redacted]","aliases":["[CVE 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":"f8ed3878fd4990d970372c99df48b5c9ea45601d5792f91c92d67aa62fd6aaa5"},"properties":{"dependency":{"package":"defu","version":"6.1.4","advisory":"[GHSA redacted]","aliases":["[CVE 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":"bc0d4bfbc2dbf13b7b4678c7f750f00c9c46698f61534d37a6a18fd133b243d5"},"properties":{"dependency":{"package":"flatted","version":"3.3.1","advisory":"[GHSA redacted]","aliases":["[CVE redacted]","[CVE 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":"685cba4514570b53bf9bc85812fa54c07fec7b3f62fc67d4712c038e9ec2e605"},"properties":{"dependency":{"package":"js-yaml","version":"3.14.1","advisory":"[GHSA redacted]","aliases":["[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[GHSA redacted]","[GHSA 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":"24ca2b657a002371f47253ffc3d1042d7a3752a5b2076cdfa1568b90732fc738"},"properties":{"dependency":{"package":"js-yaml","version":"4.1.0","advisory":"[GHSA redacted]","aliases":["[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[GHSA redacted]","[GHSA 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":"b6d419d41b948ef329cc1a680dcff4cc08f48b708dc9ff5fe365d3d07c635b37"},"properties":{"dependency":{"package":"minimatch","version":"3.1.2","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":"fea0820263114bf4d921d83e00f96f53f32c2fe0c8dfa289b20917af34d562f0"},"properties":{"dependency":{"package":"minimatch","version":"9.0.3","advisory":"[GHSA redacted]","aliases":["[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[GHSA 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":"7d7864086d9ca01b8f29fa7ad3c2c00d9d57cfd160af03613775d52b60c5c7aa"},"properties":{"dependency":{"package":"minimatch","version":"9.0.4","advisory":"[GHSA redacted]","aliases":["[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[GHSA 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":"c933df06bd2df4e809148d93658cd406bf062d11bf7d66801db63b8fbe013d8c"},"properties":{"dependency":{"package":"nanoid","version":"3.3.12","advisory":"[GHSA redacted]","aliases":["[CVE redacted]","[CVE 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":"310901574a5db1904407aca8420753d94c61fb25457e18614c04cc880951fe52"},"properties":{"dependency":{"package":"nanoid","version":"3.3.7","advisory":"[GHSA redacted]","aliases":["[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[GHSA 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":"98f5b7f1cc7ab72c7ef988be1ab835626c9ba93796c264fb44a05726fc7d8dd6"},"properties":{"dependency":{"package":"picomatch","version":"2.3.1","advisory":"[GHSA redacted]","aliases":["[CVE redacted]","[CVE 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":"94c6ff14ea54b382a61d2f966f77a9032450e908372d7ab5d8acd1b161983573"},"properties":{"dependency":{"package":"postcss","version":"8.4.38","advisory":"[GHSA redacted]","aliases":["[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[GHSA 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":"7bbcf727c11f3451b90e0c4181659fec15555399ba4dd1a967c87b3704c5ad8b"},"properties":{"dependency":{"package":"postcss","version":"8.5.14","advisory":"[GHSA redacted]","aliases":["[CVE redacted]","[CVE 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":"a52941740c6d4d81e829f17d108327f10fc68197cc65d26f78e39171f6bbce8e"},"properties":{"dependency":{"package":"rollup","version":"3.29.4","advisory":"[GHSA redacted]","aliases":["[CVE redacted]","[CVE redacted]","[GHSA redacted]"],"reachability":{"kind":"test-or-tooling","file":"crates/loro-wasm/package.json"}}}},{"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":"1ebdf2a82974cc6127a756161c2baec2929354a83addb1196ffa87a45ee6f32a"},"properties":{"dependency":{"package":"rollup","version":"4.17.2","advisory":"[GHSA redacted]","aliases":["[CVE redacted]","[CVE redacted]","[GHSA redacted]"],"reachability":{"kind":"test-or-tooling","file":"crates/loro-wasm/package.json"}}}},{"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":"5f538739e89f76b0971a5390fa8cddbf706f34980e213deea9c68f7ff3476760"},"properties":{"dependency":{"package":"sharp","version":"0.34.4","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":"0bf997523edcbfd004b0e48079d2d03fc36b5b8058c165442d7b3299bf52fe16"},"properties":{"dependency":{"package":"source-map-js","version":"1.2.0","advisory":"[GHSA redacted]","aliases":["[CVE 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":"e6a538b9f9a5b8022082030c08e25292539594a9af16d6913c88226fea2d9412"},"properties":{"dependency":{"package":"source-map-js","version":"1.2.1","advisory":"[GHSA redacted]","aliases":["[CVE 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":"5fd66fed6cbabf2ebcb54e1348a619847d0bc5632ed65037101ab132a4a74a93"},"properties":{"dependency":{"package":"tmp","version":"0.0.33","advisory":"[GHSA redacted]","aliases":["[CVE redacted]","[CVE 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":"7531eb5fa8b12bbac40121f69038f913c6ef844555a157b58db0a6ce500ba8f1"},"properties":{"dependency":{"package":"undici","version":"5.29.0","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]","[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":"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":"6681f9a8552ca6198c2bbe56dff30e4f4bfe438764abf6258ec4ab25861419e6"},"properties":{"dependency":{"package":"vite","version":"4.5.3","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]","[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":"test-or-tooling","file":"crates/loro-wasm/package.json"}}}},{"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":"4b92b6ead9b9b5862e0f97d24505ed7f021713ffdd3b9ecfacf2f02b4da6f1cc"},"properties":{"dependency":{"package":"vite","version":"5.2.11","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]","[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":"test-or-tooling","file":"crates/loro-wasm/package.json"}}}},{"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":"659b17df3a297d0c761f05e64fbd7a7fec481b8fec3425db0f2590512d5583b5"},"properties":{"dependency":{"package":"ws","version":"8.20.0","advisory":"[GHSA redacted]","aliases":["[CVE redacted]","[CVE 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":"3d49a23180e7d83432f119c392bdd26821e65aeecfeb362ea0682105c5ff434a"},"properties":{"dependency":{"package":"picomatch","version":"2.3.1","advisory":"[GHSA redacted]","aliases":["[CVE redacted]","[CVE redacted]","[GHSA 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":"1a1e503af806e767f14c170c32073931de1d4295405a897beef69c919a99a60d"},"properties":{"dependency":{"package":"adler","version":"1.0.2","advisory":"RUSTSEC-2025-0056","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":"399b641a1002e75c8bff8b9c396c66ba0c165468034e5af1632a4a0b59ea9a3e"},"properties":{"dependency":{"package":"ansi_term","version":"0.12.1","advisory":"RUSTSEC-2021-0139","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":"759d36a63e8483c4a467399ff199fa57fa2e02d89ef311720974588edb9516d4"},"properties":{"dependency":{"package":"anyhow","version":"1.0.99","advisory":"RUSTSEC-2026-0190","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":"9d7e2f5e4e133844171b9412d83e460349b527553e21e4eb5d4f1e038ed6831f"},"properties":{"dependency":{"package":"atomic-polyfill","version":"1.0.3","advisory":"RUSTSEC-2023-0089","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":"b066a2b58ae4db7be6d042309847a8825c9fbea4c10daa49bc531dab4309fb0b"},"properties":{"dependency":{"package":"atty","version":"0.2.14","advisory":"RUSTSEC-2024-0375","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":"fd5c585b8c54c369819773fdb0ddd1383b1d0b3ca7573d38678c34407fbff305"},"properties":{"dependency":{"package":"atty","version":"0.2.14","advisory":"RUSTSEC-2021-0145","aliases":["[GHSA 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":"f9853530121b8c3beac46ca94042f4eb57fc2a1a31607a6497ef8dc48921f756"},"properties":{"dependency":{"package":"bitmaps","version":"2.1.0","advisory":"RUSTSEC-2026-0247","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":"ff138e39c0f4bae5a06111aa2c7a537e1269534ae88349d70780943e94a14f9c"},"properties":{"dependency":{"package":"bitmaps","version":"3.2.1","advisory":"RUSTSEC-2026-0247","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":"ab113f4511e48d081edf02734f13997952fa6a37abe69cb57e9ba1799ef70f7c"},"properties":{"dependency":{"package":"bitmaps","version":"3.2.1","advisory":"RUSTSEC-2025-0167","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":"7cb949b0dfc97628adeb5867f44cfbeefa3a6a1068b707709bf0e421e653ea4f"},"properties":{"dependency":{"package":"bytes","version":"1.10.1","advisory":"[GHSA redacted]","aliases":["[CVE redacted]","RUSTSEC-2026-0007"],"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":"c4a0c58aca13bc848c37d4c3d5bcb90f8e046f8df5b386f5a3743d0625ad8dae"},"properties":{"dependency":{"package":"crossbeam-epoch","version":"0.9.18","advisory":"RUSTSEC-2026-0204","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":"a42ca7416279f52063a649dbc505340ffc7c7a5727193e601ae1de8d6db75e3d"},"properties":{"dependency":{"package":"fxhash","version":"0.2.1","advisory":"RUSTSEC-2025-0057","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":"ac54c3c3979af6f1ba9a0a1777276bf9f8762f36346735696756cef894d796af"},"properties":{"dependency":{"package":"gcc","version":"0.3.55","advisory":"RUSTSEC-2025-0121","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":"61e15d38e7c540c281646479a77ccba05a7cd34449f86efe27bb35af50623a84"},"properties":{"dependency":{"package":"im","version":"15.1.0","advisory":"RUSTSEC-2026-0248","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":"9a41b459c1e1ed3993ae8a36e13d11a514c47b8210ab85628a53cbc8a05532bf"},"properties":{"dependency":{"package":"im","version":"15.1.0","advisory":"RUSTSEC-2023-0126","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":"899d657a460ee3b23a677240291f1b37781f467768f31667811bc348446cd417"},"properties":{"dependency":{"package":"imbl-sized-chunks","version":"0.1.3","advisory":"RUSTSEC-2026-0292","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":"bf9b3890cba73cd3c5d5270d1976bd1bae94596a1c510482b94fe9367ef871f2"},"properties":{"dependency":{"package":"memmap2","version":"0.5.10","advisory":"RUSTSEC-2026-0186","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":"46f49615124997a47ae03424c2b2e05e8f53b2ec644cd091de0dc203d46f11ac"},"properties":{"dependency":{"package":"pin-utils","version":"0.1.0","advisory":"RUSTSEC-2026-0441","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":"95686d8e64236c3c2c566e482859faf67a5bbd9dbeebb6f4df8aab56c3496281"},"properties":{"dependency":{"package":"proc-macro-error","version":"1.0.4","advisory":"RUSTSEC-2024-0370","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":"b140f99f85b9d512ea55048c0e02378a140cf87614f4dd888f6636a966091b87"},"properties":{"dependency":{"package":"rand","version":"0.8.5","advisory":"RUSTSEC-2026-0097","aliases":["[GHSA 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":"0a1401bdba15b420e7151e679c9211830b1514c5a986e192c378cf683fc6c70d"},"properties":{"dependency":{"package":"rand","version":"0.9.2","advisory":"RUSTSEC-2026-0097","aliases":["[GHSA 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":"e9cf74773a6e34d2f2cd5f4cc024a1a57cb07e5917cf84c703df779cadb57013"},"properties":{"dependency":{"package":"rustix","version":"1.1.5","advisory":"RUSTSEC-2026-0486","aliases":["[GHSA 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":"d38736f2611cc8a68dd6d9310c78b5d2d83dfcca00f3553b710b7486c0d08717"},"properties":{"dependency":{"package":"ruzstd","version":"0.3.1","advisory":"RUSTSEC-2026-0344","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":"29657cae34dd8cde614417a5e63194c90262d7543de5763d566a22c44f87c6e9"},"properties":{"dependency":{"package":"scc","version":"2.4.0","advisory":"RUSTSEC-2026-0205","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":"0d5eb3c9e63b1f4e713840f0a870cb4fc4b0eadec98bf720c40fb49b919ccd26"},"properties":{"dependency":{"package":"sized-chunks","version":"0.6.5","advisory":"RUSTSEC-2026-0251","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":"eb0001f1efbeb6758c9328ffac016bb7f7f69b0b96734f2fe260dcc9f13686c9"},"properties":{"dependency":{"package":"sized-chunks","version":"0.6.5","advisory":"RUSTSEC-2026-0255","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":"0897771ffd4e3ceb3419dde32bb5bb1ffcf0f4b413f8009f7ee61b96577e12ed"},"properties":{"dependency":{"package":"smartstring","version":"1.0.1","advisory":"RUSTSEC-2026-0249","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":"f4999ef69e42f46a403f3866a4a634365963f93fdd6e82c0c4a8e528a960ab52"},"properties":{"dependency":{"package":"zstd","version":"0.13.3","advisory":"RUSTSEC-2026-0391","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":"06e8dc8c07565b965cad3fead890e0d682e96e4f994ab4a0654e3f10afe7962d"},"properties":{"dependency":{"package":"zstd-safe","version":"7.2.4","advisory":"RUSTSEC-2026-0395","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":"414bb4a49ee404ddc9dbe92931374dee643d4d3104e067391ed93041a77ff631"},"properties":{"dependency":{"package":"zstd-safe","version":"7.2.4","advisory":"RUSTSEC-2026-0396","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":"d67834474e5564706ab5d6117a7537fa7ddd9f89e1070ff0f40846a68262b203"},"properties":{"dependency":{"package":"zstd-safe","version":"7.2.4","advisory":"RUSTSEC-2026-0397","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":"64bc44f41a35cd29a5d01a7b192ce2cc5f1d458c15d9df1d5239ebb5b7c6fd43"},"properties":{"dependency":{"package":"zstd-safe","version":"7.2.4","advisory":"RUSTSEC-2026-0399","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":"a79bcf37fda3b3cfb40243fa81b1818f80a0fe095c267b68e3c7eee6f042ddc9"},"properties":{"dependency":{"package":"zstd-safe","version":"7.2.4","advisory":"RUSTSEC-2026-0400","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":"21df614167acad094349de8aa7cfc685e485f636d67b1ded35b43230df65a136"},"properties":{"dependency":{"package":"zstd-safe","version":"7.2.4","advisory":"RUSTSEC-2026-0401","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":"fd61c6a1a6d23109e3da0a091cdbb2ecd3102dd1235e0548e2d8ffd7db2a7005"},"properties":{"dependency":{"package":"zstd-safe","version":"7.2.4","advisory":"RUSTSEC-2026-0402","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":"a910032c7367726c7f26107809b36a5b0ab01a6e3af6f2b0cf67b659ecca9e49"},"properties":{"dependency":{"package":"zstd-safe","version":"7.2.4","advisory":"RUSTSEC-2026-0404","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":"d11388e41908d6112e7f61d01d0c0d9062830b07945356073c8069de5b88d627"},"properties":{"dependency":{"package":"zstd-safe","version":"7.2.4","advisory":"RUSTSEC-2026-0405","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":"dbb5f2efe8d9cca6344840981b65d21b774960589fc9976e6690dc84fce97102"},"properties":{"dependency":{"package":"zstd-safe","version":"7.2.4","advisory":"RUSTSEC-2026-0406","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":"d7870b77ea4843334d11fffa265d6d0542e94eec7f4c8e852762d55c28578136"},"properties":{"dependency":{"package":"zstd-safe","version":"7.2.4","advisory":"RUSTSEC-2026-0398","aliases":["RUSTSEC-2026-0403"],"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":"84f9b61ffb7d87f7a0ea344424bcbd7389e2ed41eb01432b04fba9f732cd312c"},"properties":{"dependency":{"package":"zstd-sys","version":"2.0.16\u002Bzstd.1.5.7","advisory":"RUSTSEC-2026-0410","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":"9963a97004e05a111194ef3e9659cda00bd5978519288bfe03bbd6e80bc30d6e"},"properties":{"dependency":{"package":"uuid","version":"9.0.0","advisory":"[GHSA redacted]","aliases":["[CVE redacted]","[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":"4c5fe5f006821084f006cc8d4ef058db5967b66cfdf942b7abfd7566a53f620b"},"properties":{"dependency":{"package":"esbuild","version":"0.17.12","advisory":"[GHSA 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":"1c282906b3911d764c1aad4357961ef8f56cfac25fee67172a1295ab1da90521"},"properties":{"dependency":{"package":"@babel/runtime","version":"7.24.5","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":"b7bda289298f8c7b577c3df21f51a6fc17f92b7e23b2a76b5f7c4731a8327d8c"},"properties":{"dependency":{"package":"ajv","version":"6.12.6","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":"b0626639ffdbc658e7c1d889d41abcccd1682a45cb32c6b8f2e50a6f85a0bc7b"},"properties":{"dependency":{"package":"csv-parse","version":"4.16.3","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":"8fbae7affe33d99a549f4b8a8aa5e5e6d3bf16e68922adf11e518d7f63edd09c"},"properties":{"dependency":{"package":"esbuild","version":"0.18.20","advisory":"[GHSA redacted]","reachability":{"kind":"production","file":"crates/loro-wasm/scripts/nodejs-snippets.cjs","line":5}}}},{"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":"3f8f826c9a93963bcae2c9ed4506b81872b5205abf8341b96de338d52f6ae938"},"properties":{"dependency":{"package":"esbuild","version":"0.20.2","advisory":"[GHSA redacted]","reachability":{"kind":"production","file":"crates/loro-wasm/scripts/nodejs-snippets.cjs","line":5}}}},{"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":"6fb79007bff808f0f9ed82f4d428b3c45193863658dcd9768c0fea9c35128c01"},"properties":{"dependency":{"package":"fflate","version":"0.8.2","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":"6087535468e0c944497d73c54b03c53a336c65787cd998b069c70d3d0253467c"},"properties":{"dependency":{"package":"micromatch","version":"4.0.5","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":"59008872b43a88c3068035f759fef4d3e638f74afebc42575b07aafac271b4c7"},"properties":{"dependency":{"package":"quill","version":"1.3.7","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":"bcaff5d1e287866fb15ab08f33c0744f85cfc07f596d7af736c916f57cc95099"},"properties":{"dependency":{"package":"uuid","version":"9.0.1","advisory":"[GHSA redacted]","aliases":["[CVE redacted]","[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":"2d93c38655ec32f76d456e0b7dac0b047eb2dbcdbeb544b53150bd8b4e342eb9"},"properties":{"dependency":{"package":"vue-template-compiler","version":"2.7.16","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":"880c5a9e3754ff2f8b6ebe629520afecbaa8208a75ab43985dc95bf538bfa60c"},"properties":{"dependency":{"package":"xxhash-rust","version":"0.8.15","advisory":"[GHSA redacted]","reachability":{"kind":"unknown"}}}},{"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":"a861b1ab2fd6ac5a0cbbd2d1eaeca38914dcada77f7a5d62bbdd015efb9e974e"},"properties":{"dependency":{"package":"deepmerge","version":"4.3.1","advisory":"[GHSA redacted]","aliases":["[CVE redacted]"],"reachability":{"kind":"not-imported"}}}},{"ruleId":"D31","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":"f35fbf571b30707dc4dd73872ac8ee0fdb40d53af846154ffa9df406720764ee"}},{"ruleId":"D31","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":"9f8173d22bf4b8f4493dd4629392abd10d887adfbdec41837f11380f8b095ffc"}},{"ruleId":"D31","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":"7bc3556bf1309864e3dcca3c58a2f642dbc3c69d8d7bb5a758a9e60acb78663a"}},{"ruleId":"D31","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":"521c18e0aafe09bc333ce5fd0ac0735b1ad04899e107a247a8bb0f48741c16bd"},"taxa":[{"id":"CWE-494","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"A08:2025","toolComponent":{"name":"OWASP Top 10","guid":"7d1f0c2e-4b6a-4e39-9a51-0b2e8c3d5f61"}},{"id":"CICD-SEC-3","toolComponent":{"name":"OWASP Top 10 CI/CD Security Risks","guid":"3c9b2a6e-5d14-4f7b-8e02-6a1d9c4b7f35"}}]},{"ruleId":"D31","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":"d31c472ce403e8768b0143757edc7e0c2b400870b42b6d228245c182c28ebaf1"},"taxa":[{"id":"CWE-494","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"A08:2025","toolComponent":{"name":"OWASP Top 10","guid":"7d1f0c2e-4b6a-4e39-9a51-0b2e8c3d5f61"}},{"id":"CICD-SEC-3","toolComponent":{"name":"OWASP Top 10 CI/CD Security Risks","guid":"3c9b2a6e-5d14-4f7b-8e02-6a1d9c4b7f35"}}]},{"ruleId":"D31","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":"49e0bc91f0d29c525d5e2bec8ac1defd4c058384feb80f88dcc1d6de512ec200"},"taxa":[{"id":"CWE-494","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"A08:2025","toolComponent":{"name":"OWASP Top 10","guid":"7d1f0c2e-4b6a-4e39-9a51-0b2e8c3d5f61"}},{"id":"CICD-SEC-3","toolComponent":{"name":"OWASP Top 10 CI/CD Security Risks","guid":"3c9b2a6e-5d14-4f7b-8e02-6a1d9c4b7f35"}}]},{"ruleId":"D31","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":"ed61e4880727adcf23ab9f6fe8ca4ec3fe03528a10e35af38ed58e5d972962ea"},"taxa":[{"id":"CWE-494","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"A08:2025","toolComponent":{"name":"OWASP Top 10","guid":"7d1f0c2e-4b6a-4e39-9a51-0b2e8c3d5f61"}},{"id":"CICD-SEC-3","toolComponent":{"name":"OWASP Top 10 CI/CD Security Risks","guid":"3c9b2a6e-5d14-4f7b-8e02-6a1d9c4b7f35"}}]},{"ruleId":"D31","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":"47ed9d24705218eb0da49669ede973aaac8603395c2558cba8f52089ce550fd5"},"taxa":[{"id":"CWE-494","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"A08:2025","toolComponent":{"name":"OWASP Top 10","guid":"7d1f0c2e-4b6a-4e39-9a51-0b2e8c3d5f61"}},{"id":"CICD-SEC-3","toolComponent":{"name":"OWASP Top 10 CI/CD Security Risks","guid":"3c9b2a6e-5d14-4f7b-8e02-6a1d9c4b7f35"}}]},{"ruleId":"D31","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":"8b27471487bdcc674f43b02e7f84bf3d0bca6006144b424c9471a521004c2e1f"},"taxa":[{"id":"CWE-1357","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-353","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"A03:2025","toolComponent":{"name":"OWASP Top 10","guid":"7d1f0c2e-4b6a-4e39-9a51-0b2e8c3d5f61"}}]},{"ruleId":"D31","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":"e6f2ae0a6d6e9cd44cc13b0a4dea55f1f10383be84f057466ca4683d13fbbf1c"},"taxa":[{"id":"CWE-1357","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"A03:2025","toolComponent":{"name":"OWASP Top 10","guid":"7d1f0c2e-4b6a-4e39-9a51-0b2e8c3d5f61"}},{"id":"CICD-SEC-3","toolComponent":{"name":"OWASP Top 10 CI/CD Security Risks","guid":"3c9b2a6e-5d14-4f7b-8e02-6a1d9c4b7f35"}}]},{"ruleId":"D31","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":"ba75c26d8fef44662a123a02b0e04a6d3938cadf07a5b3db22f6724a419eec7c"},"taxa":[{"id":"CWE-1357","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"A03:2025","toolComponent":{"name":"OWASP Top 10","guid":"7d1f0c2e-4b6a-4e39-9a51-0b2e8c3d5f61"}},{"id":"CICD-SEC-3","toolComponent":{"name":"OWASP Top 10 CI/CD Security Risks","guid":"3c9b2a6e-5d14-4f7b-8e02-6a1d9c4b7f35"}}]},{"ruleId":"D31","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":"c9e5ee4464dd377637d25b1e158ed5438709949a29818191ea5c647e6ecbd054"},"taxa":[{"id":"CWE-1357","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"A03:2025","toolComponent":{"name":"OWASP Top 10","guid":"7d1f0c2e-4b6a-4e39-9a51-0b2e8c3d5f61"}},{"id":"CICD-SEC-3","toolComponent":{"name":"OWASP Top 10 CI/CD Security Risks","guid":"3c9b2a6e-5d14-4f7b-8e02-6a1d9c4b7f35"}}]},{"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":"crates/loro-internal/src/jsonpath/parser.rs"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"ad907ab4bb346e117d818d96637461f1bfe2d0e83421a1d64a7224de8646f559"}},{"ruleId":"D34","level":"note","message":{"text":"Further orphaned files (smaller): 11 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: crates/loro-internal/src/jsonpath/ast.rs, crates/loro-internal/src/allocation/dfs.rs, crates/fuzz/src/mem_kv_fuzzer.rs, crates/loro-internal/src/allocation/bfs.rs, crates/kv-store/src/lib.rs, crates/fuzz/src/actions.rs, crates/loro-internal/src/container/richtext/tinyvec.rs, crates/kv-store/src/iter.rs (and 3 more) (12 orphaned of 202 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; 202 of the 272 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":"crates/loro-internal/src/jsonpath/ast.rs"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"8b4897564c75ef180d2982f5a5bd62bcee1adb2b3c29b6a75420d6aa207b1f1d"}},{"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":"crates/loro-internal/src/allocation/dfs.rs"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"9d2111b668e3cc3f094f7662b78a98b58d87634269aa9dea347b88aa20c91746"}},{"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":"crates/fuzz/src/mem_kv_fuzzer.rs"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"ef4c8782b291b1e61b3c71b9fbcb12ebe70ecbb1a4dc4ca456106ee70d7c433b"}},{"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":"crates/loro-internal/src/allocation/bfs.rs"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"43bbc3805a457a8f154213d1a89ebbfcfcbba81b53435185c00a77f1fd6ec5b8"}},{"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":"crates/kv-store/src/lib.rs"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"3e25d1712e7f5331f5145112ac954ea3694c0c2c67737563de052844d2532819"}},{"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":"crates/fuzz/src/actions.rs"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"35b481f390b2d3818f6aa2d2310377e5417de0b9c816d9fe01d0edd74871d662"}},{"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":"crates/loro-internal/src/container/richtext/tinyvec.rs"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"7361d853d2d44a524cc0a411a09cb39356e9200d1373efe3e2ca7ec8d9e7500d"}},{"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":"crates/kv-store/src/iter.rs"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"ca95370cc563238188cdb2d8b3cad2d7295d11ddcd7739d06030a5872fe47a14"}},{"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":"crates/loro-internal/src/delta/map.rs"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"13aabd01dd0e8a007f26695e0420213dd64c7d27e43aae7e2b60f77d8da9823b"}},{"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":"crates/loro-internal/src/state/mergeable.rs"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"eeb7fc8e5a8909de312106999787fec6658162afcf4295825fb75e90569e31b9"}},{"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":"crates/fractional_index/src/jitter.rs"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"403c229e08543c793de2d1d4e1b49031b614b15e565417a03baa386292f01e1c"}},{"ruleId":"D35","level":"warning","message":{"text":"Change coupling: style_range_map.rs \u2194 handler.rs: \u0060crates/loro-internal/src/container/richtext/style_range_map.rs\u0060 and \u0060crates/loro-internal/src/handler.rs\u0060 change together 75% of the time (9 of the 12 commits that touched whichever of the two files changed less often, counting a file under its earlier names as well \u2014 a repo-wide or module-wide sweep is evidence about the sweep rather than about any pair inside it and is left out of BOTH sides of this ratio, while a dependency bump, a formatter/rename sweep, or a commit whose edit to one of the two files was a tool directive such as //go:generate or whitespace only is left out of the shared count ONLY, so the two sides are not taken over identical commit sets) with no explicit dependency \u2014 the edge is real but nothing declares it. Read the pair before acting: if one registers itself into the other through a hook or an initialiser, the missing dependency is DELIBERATE \u2014 the registration is the link, and it is meant not to be an import \u2014 and the thing to add is a comment on each side naming the other, not a merge; if they simply belong together, co-locate them; if neither holds, the coupling is hidden and worth breaking. You can check this without leaving the row: of the 9 shared commits counted here, the most recent 3 are \u00604b5b460a\u0060 fix: skip redundant text marks when the range spans multiple style ra\u2026; \u00602800a4c8\u0060 perf: skip useless unmark op (#878); \u00603a4ed97e\u0060 fix: only send a event for one \u0060import\u0060/\u0060transaction\u0060/\u0060checkout\u0060 (#263) \u2014 run \u0060git show\u0060 on any of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/container/richtext/style_range_map.rs"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"372556336d054fe0b05cd8fe24e3ee910c7d94b77197695340d8142d8a7942af"}},{"ruleId":"D35","level":"warning","message":{"text":"Change coupling: list_state.rs \u2194 map_state.rs: \u0060crates/loro-internal/src/state/list_state.rs\u0060 and \u0060crates/loro-internal/src/state/map_state.rs\u0060 change together 51% of the time (19 of the 37 commits that touched whichever of the two files changed less often, counting a file under its earlier names as well \u2014 a repo-wide or module-wide sweep is evidence about the sweep rather than about any pair inside it and is left out of BOTH sides of this ratio, while a dependency bump, a formatter/rename sweep, or a commit whose edit to one of the two files was a tool directive such as //go:generate or whitespace only is left out of the shared count ONLY, so the two sides are not taken over identical commit sets) with no explicit dependency between them. They sit in the same directory, but in this ecosystem each file is its own module \u2014 a sibling reference still needs an import \u2014 so the missing import edge is real: the coupling runs through shared behaviour, not a declared dependency. If they duplicate structure, extract the common part into one unit; otherwise the coupling is hidden and worth breaking. You can check this without leaving the row: of the 19 shared commits counted here, the most recent 3 are \u00603729deb1\u0060 feat: richtext snapshot; \u0060b8eb57f4\u0060 Refactor ID (#274); \u00609e57ccbc\u0060 Fix avoid rich text apply diff err when time travel (#256) \u2014 run \u0060git show\u0060 on any of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/state/list_state.rs"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"d5701774ca1db6d836fbbac278b0aca5dd4e28a9adba35980ed5b1575587f2ec"}},{"ruleId":"D35","level":"warning","message":{"text":"Change coupling: kv_store.rs \u2194 oplog.rs: \u0060crates/loro-internal/src/kv_store.rs\u0060 and \u0060crates/loro-internal/src/oplog.rs\u0060 change together 50% of the time (5 of the 10 commits that touched whichever of the two files changed less often, counting a file under its earlier names as well \u2014 a repo-wide or module-wide sweep is evidence about the sweep rather than about any pair inside it and is left out of BOTH sides of this ratio, while a dependency bump, a formatter/rename sweep, or a commit whose edit to one of the two files was a tool directive such as //go:generate or whitespace only is left out of the shared count ONLY, so the two sides are not taken over identical commit sets) with no explicit dependency between them. They sit in the same directory, but in this ecosystem each file is its own module \u2014 a sibling reference still needs an import \u2014 so the missing import edge is real: the coupling runs through shared behaviour, not a declared dependency. If they duplicate structure, extract the common part into one unit; otherwise the coupling is hidden and worth breaking. You can check this without leaving the row: of the 5 shared commits counted here, the most recent 3 are \u00609b6330db\u0060 perf: speed up B4 local editing ~2.4x and snapshot import ~45% (#1033); \u0060ca6a7c89\u0060 fix: warnings; \u006023fbae1f\u0060 refactor: make vv in dag optional \u2014 run \u0060git show\u0060 on any of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/kv_store.rs"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"2242d35b4e5eb52c0e93c05dee0c6b33808840bfd8834941e9babce862860063"}},{"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":"90f83b4fa27db32740afe9540c905f3c0499caed87f61049a8a903ecc95b41c3"},"taxa":[{"id":"CICD-SEC-8","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":"1b3856dc48c94a2ef2fb1ec98294eb281aa479096b2de4ad945576786b374c23"},"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":"cfd2028e3e3310f8a33d94196a5fa3028dc024afcf128a2cff9b06dd90b81483"},"taxa":[{"id":"CICD-SEC-5","toolComponent":{"name":"OWASP Top 10 CI/CD Security Risks","guid":"3c9b2a6e-5d14-4f7b-8e02-6a1d9c4b7f35"}}]},{"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":"M4","level":"note","message":{"text":"README/code drift: crates/loro/README.md links to \u0060struct.LoroDoc.html\u0060, but \u0060crates/loro/struct.LoroDoc.html\u0060 does not exist. Checked without a model against the repository: its files and folders, the scripts and dependencies of every package.json, the projects, namespaces, package references and target frameworks of the .NET build, the SDK and Node pins, and the identifiers of every file that is not a document; the documents\u0027 own text never counts. A footprint generated at build time, read only by a platform, or living outside this repository is not seen, and this row is then wrong."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro/README.md"},"region":{"startLine":60}}}],"partialFingerprints":{"codehealthFindingId/v1":"0bbd8ea72b9093b730a2e7c24275e969d784cf682704104fe2175a81a8347712"}},{"ruleId":"M4","level":"note","message":{"text":"README/code drift: crates/loro/README.md links to \u0060trait.ToJson.html\u0060, but \u0060crates/loro/trait.ToJson.html\u0060 does not exist. Checked without a model against the repository: its files and folders, the scripts and dependencies of every package.json, the projects, namespaces, package references and target frameworks of the .NET build, the SDK and Node pins, and the identifiers of every file that is not a document; the documents\u0027 own text never counts. A footprint generated at build time, read only by a platform, or living outside this repository is not seen, and this row is then wrong."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro/README.md"},"region":{"startLine":80}}}],"partialFingerprints":{"codehealthFindingId/v1":"e03e9f09dbce138254edbf3959d52a61812dd71041bd1a761d84c0e7cf35860e"}},{"ruleId":"P2","level":"note","message":{"text":"Logging is not universal: Only 9/11 runnable modules use logging (modules with no entry point or server are excluded \u2014 they are libraries a runnable module hosts). Silent: \u0060.\u0060, \u0060crates/loro-wasm-tools\u0060."},"locations":[],"partialFingerprints":{"codehealthFindingId/v1":"91a94e21d6d4d0e6a2003f94505b0b02b157176f0b24c4820f3f82b4447a97fe"}},{"ruleId":"P3","level":"note","message":{"text":"No dependency-update automation: \u0060package.json\u0060 declares packages, and nothing in the repository keeps them current: no Dependabot or Renovate configuration that schedules updates, and no dependency-review gate on pull requests. A pinned dependency stays at the version it was added at until someone notices \u2014 including after an advisory is published against it. Add a \u0060.github/dependabot.yml\u0060 with one \u0060package-ecosystem\u0060 entry per ecosystem the tree uses (or an enabled \u0060renovate.json\u0060), and gate pull requests with \u0060actions/dependency-review-action\u0060."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"package.json"},"region":{"startLine":36}}}],"partialFingerprints":{"codehealthFindingId/v1":"9b237f7efe841e3a95b381b232502a3a473094adeb069a11eaca8ca533fb1c34"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (55 lines \u00D7 2 locations): loro-js/src/runtime/sequence-index.ts:3658 \u00B7 loro-js/src/runtime/sequence-index.ts:3714 \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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":3658}}}],"partialFingerprints":{"codehealthFindingId/v1":"ad2663b681f2a22e0753aa518eacd2fe9b609253f5972d4a087c66a0ed728353"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (44 lines \u00D7 2 locations): packages/fractional-index/src/index.ts:135 \u00B7 packages/fractional-index/src/index.ts:237 \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":"packages/fractional-index/src/index.ts"},"region":{"startLine":135}}}],"partialFingerprints":{"codehealthFindingId/v1":"772b4f0a541cae42fe72c34b4a37fae4309ecfa7c069a9143c5d3be037197c9d"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (40 lines \u00D7 2 locations): loro-js/src/runtime/sequence-index.ts:2866 \u00B7 loro-js/src/runtime/sequence-index.ts:2981 \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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":2866}}}],"partialFingerprints":{"codehealthFindingId/v1":"d96c2745f08c77311b1da32e016fd59a3e63eafa784a2bb4cd667a16b642a532"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block with local edits (39 matched lines \u00D7 2 locations): loro-js/src/codec/change-value.ts:347 \u00B7 loro-js/src/codec/value.ts:31 \u2014 the two spans are one implementation copied and then locally edited \u2014 220 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":"loro-js/src/codec/change-value.ts"},"region":{"startLine":347}}}],"partialFingerprints":{"codehealthFindingId/v1":"25ddb986f643646c796cae90ab300a74de3af90b6b6fc2b2b4f896300a14788f"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (36 lines \u00D7 2 locations): loro-js/src/codec/container-id.ts:23 \u00B7 loro-js/src/codec/container-id.ts:62 \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":"loro-js/src/codec/container-id.ts"},"region":{"startLine":23}}}],"partialFingerprints":{"codehealthFindingId/v1":"1c9c4b977863b9ed776f2172b34d5a344dcd4a8bac42a4630586578b6774c0db"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (33 lines \u00D7 2 locations): loro-js/src/codec/serde-columnar.ts:398 \u00B7 loro-js/src/codec/serde-columnar.ts:452 \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":"loro-js/src/codec/serde-columnar.ts"},"region":{"startLine":398}}}],"partialFingerprints":{"codehealthFindingId/v1":"2d86c002f13421bfe8fd94971f9bfd2c353f99d0b2e2af342862b35613096790"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (29 lines \u00D7 2 locations): loro-js/src/runtime/sequence-index.ts:1075 \u00B7 loro-js/src/runtime/sequence-index.ts:1163 \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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":1075}}}],"partialFingerprints":{"codehealthFindingId/v1":"067c01bf43607a69b4c9552adde15047b41e70669efebd96080c6c06e35b24c9"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (27 lines \u00D7 2 locations): loro-js/src/runtime/sequence-deletion-index.ts:238 \u00B7 loro-js/src/runtime/sequence-index.ts:3321 \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":"loro-js/src/runtime/sequence-deletion-index.ts"},"region":{"startLine":238}}}],"partialFingerprints":{"codehealthFindingId/v1":"742d8dcbad110e4e97783c75dcc35a097e1ef4f2e8372847bfcc54a7aaf84e6c"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (26 lines \u00D7 2 locations): loro-js/src/codec/value.ts:134 \u00B7 loro-js/src/codec/version.ts:9 \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":"loro-js/src/codec/value.ts"},"region":{"startLine":134}}}],"partialFingerprints":{"codehealthFindingId/v1":"7f043615974a925ffe017011128eda154b8726b5a3596dcd4bdf6d1c456867a1"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block with local edits (26 matched lines \u00D7 2 locations): loro-js/src/runtime/sequence-deletion-index.ts:169 \u00B7 loro-js/src/runtime/text-style-index.ts:332 \u2014 the two spans are one implementation copied and then locally edited \u2014 236 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":"loro-js/src/runtime/sequence-deletion-index.ts"},"region":{"startLine":169}}}],"partialFingerprints":{"codehealthFindingId/v1":"b491a4b07a95018e833154f3f878e1a9c777b25e35b5a3f375fad01e29a42452"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (26 lines \u00D7 2 locations): loro-js/src/runtime/sequence-index.ts:1530 \u00B7 loro-js/src/runtime/sequence-index.ts:1557 \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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":1530}}}],"partialFingerprints":{"codehealthFindingId/v1":"5e15029601bcc04e0af8d479da144725295204cd0241cb06daad8cda6dc1707e"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (24 lines \u00D7 3 locations): loro-js/src/runtime/sequence-index.ts:2281 \u00B7 loro-js/src/runtime/sequence-index.ts:2921 \u00B7 loro-js/src/runtime/sequence-index.ts:3036 \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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":2281}}}],"partialFingerprints":{"codehealthFindingId/v1":"0d39851ea6a97ccbae26c5d246a3b40e167370f01b7788236cc087ab3c4cb1ab"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (21 lines \u00D7 2 locations): loro-js/src/runtime/sequence-index.ts:2128 \u00B7 loro-js/src/runtime/sequence-index.ts:2202 \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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":2128}}}],"partialFingerprints":{"codehealthFindingId/v1":"099b0746bf6b71072f313ce68fcc053bef6f14963ebbf394acc0ce12119d2160"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block with local edits (20 matched lines \u00D7 2 locations): loro-js/src/codec/value.ts:26 \u00B7 loro-js/src/codec/value.ts:131 \u2014 the two spans are one implementation copied and then locally edited \u2014 144 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":"loro-js/src/codec/value.ts"},"region":{"startLine":26}}}],"partialFingerprints":{"codehealthFindingId/v1":"631fed35a629dd2cfe83bdffe8eb69a626aef1787b16da3b8602b8fd8320f1b9"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (20 lines \u00D7 2 locations): loro-js/src/runtime/document.ts:10971 \u00B7 loro-js/src/runtime/sequence-index.ts:3540 \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":"loro-js/src/runtime/document.ts"},"region":{"startLine":10971}}}],"partialFingerprints":{"codehealthFindingId/v1":"7a21a1480202fe5054b6c06c0a603d99afb9e6402daef33ac52ef869051b5244"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (20 lines \u00D7 2 locations): loro-js/src/runtime/ephemeral.ts:379 \u00B7 loro-js/src/runtime/ephemeral.ts:401 \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":"loro-js/src/runtime/ephemeral.ts"},"region":{"startLine":379}}}],"partialFingerprints":{"codehealthFindingId/v1":"66514ab06383e3f2ae1cfa3cfecc29fe13917399882aaa638ff704492c75eb4d"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block with local edits (19 matched lines \u00D7 2 locations): loro-js/src/runtime/ordered-index.ts:241 \u00B7 loro-js/src/runtime/sequence-index.ts:2020 \u2014 the two spans are one implementation copied and then locally edited \u2014 120 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":"loro-js/src/runtime/ordered-index.ts"},"region":{"startLine":241}}}],"partialFingerprints":{"codehealthFindingId/v1":"e6b227e9db63a0565d8e9e21d0f95c96072c4c8b12f606e205135840e7f47ecc"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (19 lines \u00D7 2 locations): loro-js/src/runtime/sequence-index.ts:2084 \u00B7 loro-js/src/runtime/sequence-index.ts:2145 \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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":2084}}}],"partialFingerprints":{"codehealthFindingId/v1":"eb06298c985c114431a23a85a5698327e9dc4b4dd401f39ffae549b37fae7006"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (18 lines \u00D7 2 locations): loro-js/src/runtime/sequence-index.ts:4023 \u00B7 loro-js/src/runtime/sequence-index.ts:4042 \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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":4023}}}],"partialFingerprints":{"codehealthFindingId/v1":"09fbf0c794a2a90078c33a4b400dc2af430c89bfaa9b2d1fac86610de73175b3"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (17 lines \u00D7 3 locations): loro-js/src/codec/container-id.ts:37 \u00B7 loro-js/src/codec/container-id.ts:76 \u00B7 loro-js/src/runtime/ids.ts:77 \u2014 the 3 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":"loro-js/src/codec/container-id.ts"},"region":{"startLine":37}}}],"partialFingerprints":{"codehealthFindingId/v1":"f6c0bd3728fa3e3dd14ed06e65dd56192c856fdb3a58b6d6150e2309518992b7"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (16 lines \u00D7 2 locations): loro-js/src/runtime/document.ts:5949 \u00B7 loro-js/src/runtime/document.ts:5985 \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":"loro-js/src/runtime/document.ts"},"region":{"startLine":5949}}}],"partialFingerprints":{"codehealthFindingId/v1":"84953a27815fa516ca369c582d4e8a9da7b9a4e4fa075b7a451701aa4430d66e"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (16 lines \u00D7 2 locations): loro-js/src/runtime/sequence-index.ts:232 \u00B7 loro-js/src/runtime/sequence-index.ts:525 \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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":232}}}],"partialFingerprints":{"codehealthFindingId/v1":"9d458a183de6625812ddb89a95b9289a3579659c08835596b5720c52234900a0"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (15 lines \u00D7 2 locations): loro-js/src/codec/serde-columnar.ts:370 \u00B7 loro-js/src/codec/serde-columnar.ts:431 \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":"loro-js/src/codec/serde-columnar.ts"},"region":{"startLine":370}}}],"partialFingerprints":{"codehealthFindingId/v1":"7caea34362824ab2ff9e5ada80fbfecb6b55b840dec7741d7bae0428ed4a9045"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (15 lines \u00D7 2 locations): loro-js/src/runtime/document.ts:10816 \u00B7 loro-js/src/runtime/document.ts:11333 \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":"loro-js/src/runtime/document.ts"},"region":{"startLine":10816}}}],"partialFingerprints":{"codehealthFindingId/v1":"79b85d34aa980461b6ed23452cd87105b56f4d990083eb29cd3a76863fc4bda2"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (15 lines \u00D7 2 locations): loro-js/src/runtime/sequence-index.ts:736 \u00B7 loro-js/src/runtime/sequence-index.ts:840 \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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":736}}}],"partialFingerprints":{"codehealthFindingId/v1":"5b829def16a0c9651aef0341da2e105ba3f42eb7e3442a86482dc4088d1061ba"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 2 locations): loro-js/src/codec/sstable.ts:550 \u00B7 loro-js/src/codec/sstable.ts:565 \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":"loro-js/src/codec/sstable.ts"},"region":{"startLine":550}}}],"partialFingerprints":{"codehealthFindingId/v1":"5a6d38d395985a585ffa898f38b3cd1f51d1f690ec2413826b56cd9a6c2848e6"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 2 locations): loro-js/src/runtime/document.ts:4849 \u00B7 loro-js/src/runtime/document.ts:4869 \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":"loro-js/src/runtime/document.ts"},"region":{"startLine":4849}}}],"partialFingerprints":{"codehealthFindingId/v1":"5363c17dce25a9d7d8d1d89c462cc8b7868f11bd93d12525984d1f4f01298e19"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 2 locations): loro-js/src/runtime/document.ts:6622 \u00B7 loro-js/src/runtime/document.ts:6725 \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":"loro-js/src/runtime/document.ts"},"region":{"startLine":6622}}}],"partialFingerprints":{"codehealthFindingId/v1":"faba4ec666bed170e66a92243abb4cf1760b3e79fe79ba681a2001bdc1204b57"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 2 locations): loro-js/src/runtime/document.ts:10609 \u00B7 loro-js/src/runtime/document.ts:10644 \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":"loro-js/src/runtime/document.ts"},"region":{"startLine":10609}}}],"partialFingerprints":{"codehealthFindingId/v1":"1c90f77004249fd394d23c70b482a6619f55e199533858b57326ad0c28aec46d"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 2 locations): loro-js/src/runtime/document.ts:10943 \u00B7 loro-js/src/runtime/movable-list.ts:159 \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":"loro-js/src/runtime/document.ts"},"region":{"startLine":10943}}}],"partialFingerprints":{"codehealthFindingId/v1":"8e32bdb916cd4701697b16a1b08da3b3b87b239c771c5093b088332d88ae4d63"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block with local edits (14 matched lines \u00D7 2 locations): loro-js/src/runtime/movable-list.ts:566 \u00B7 loro-js/src/runtime/movable-list.ts:682 \u2014 the two spans are one implementation copied and then locally edited \u2014 93 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":"loro-js/src/runtime/movable-list.ts"},"region":{"startLine":566}}}],"partialFingerprints":{"codehealthFindingId/v1":"5e5ac1f211304a06528a134f3cb8da87102fef8efb11e02012ea6de681fa9a67"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block with local edits (14 matched lines \u00D7 2 locations): loro-js/src/runtime/undo.ts:261 \u00B7 loro-js/src/runtime/undo.ts:319 \u2014 the two spans are one implementation copied and then locally edited \u2014 129 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":"loro-js/src/runtime/undo.ts"},"region":{"startLine":261}}}],"partialFingerprints":{"codehealthFindingId/v1":"8a993b3fb27f7ca5ea294f059e6dec40fb006084031f551fee58d905b39b514c"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2 locations): loro-js/src/codec/bytes.ts:190 \u00B7 loro-js/src/codec/lz4.ts:314 \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":"loro-js/src/codec/bytes.ts"},"region":{"startLine":190}}}],"partialFingerprints":{"codehealthFindingId/v1":"66442a3f46d8fcf86b35d2d5cf4217a598809d91a39e060c8324d28e8fc8c66a"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2 locations): loro-js/src/codec/change-block-codec.ts:379 \u00B7 loro-js/src/codec/change-block-codec.ts:437 \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":"loro-js/src/codec/change-block-codec.ts"},"region":{"startLine":379}}}],"partialFingerprints":{"codehealthFindingId/v1":"d0456d99125d49bcd0c975c697ade15cee7b9886d6ec8f72087b262fddcb07bd"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block with local edits (13 matched lines \u00D7 2 locations): loro-js/src/codec/leb128.ts:49 \u00B7 loro-js/src/codec/serde-columnar.ts:584 \u2014 the two spans are one implementation copied and then locally edited \u2014 65 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":"loro-js/src/codec/leb128.ts"},"region":{"startLine":49}}}],"partialFingerprints":{"codehealthFindingId/v1":"71405a0b65d5cce32a5af9ce77b74f6284fd0a5f89bb0d339f940586b70723ae"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2 locations): loro-js/src/runtime/document.ts:5143 \u00B7 loro-js/src/runtime/document.ts:10074 \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":"loro-js/src/runtime/document.ts"},"region":{"startLine":5143}}}],"partialFingerprints":{"codehealthFindingId/v1":"23dc545e6fe2079f633e2028b50075b0429b85955f77b72af621c552860bb1b3"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 3 locations): loro-js/src/runtime/document.ts:8238 \u00B7 loro-js/src/runtime/document.ts:8265 \u00B7 loro-js/src/runtime/movable-list.ts:724 \u2014 the 3 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":"loro-js/src/runtime/document.ts"},"region":{"startLine":8238}}}],"partialFingerprints":{"codehealthFindingId/v1":"83b62c8ccf082cbd1badddfa83587c1ceb778c68c870dcd86f77575c61b8868c"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2 locations): loro-js/src/runtime/document.ts:9758 \u00B7 loro-js/src/runtime/document.ts:9772 \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":"loro-js/src/runtime/document.ts"},"region":{"startLine":9758}}}],"partialFingerprints":{"codehealthFindingId/v1":"08a6c361caf5037842ad13bd7f199bb6f4fe25e1494251fbe74658ebe05c52bd"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2 locations): loro-js/src/runtime/event-diff.ts:304 \u00B7 loro-js/src/runtime/sequence-index.ts:3418 \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":"loro-js/src/runtime/event-diff.ts"},"region":{"startLine":304}}}],"partialFingerprints":{"codehealthFindingId/v1":"68d7251f8c6f6a11d40528c453213d6f79fdf2ad7f6c1173838caa07ff00720f"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2 locations): loro-js/src/runtime/sequence-index.ts:709 \u00B7 loro-js/src/runtime/sequence-index.ts:979 \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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":709}}}],"partialFingerprints":{"codehealthFindingId/v1":"c30674f3a3231bdfe9601873289630e17f9b98017ba144f05f485c8e1e6927c1"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2 locations): loro-js/src/runtime/sequence-index.ts:1357 \u00B7 loro-js/src/runtime/sequence-index.ts:1371 \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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":1357}}}],"partialFingerprints":{"codehealthFindingId/v1":"2881e44b4d657c4374c23d5875208fc463d0fbd855091c5192e3c4ebeefc8dac"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2 locations): loro-js/src/runtime/sequence-index.ts:1676 \u00B7 loro-js/src/runtime/sequence-index.ts:1691 \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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":1676}}}],"partialFingerprints":{"codehealthFindingId/v1":"c3dc8e698e5463d858c30ce27655bfc581c89a3c92ffa61ee0847273d211a39d"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2 locations): loro-js/src/runtime/sequence-index.ts:2446 \u00B7 loro-js/src/runtime/sequence-index.ts:2531 \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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":2446}}}],"partialFingerprints":{"codehealthFindingId/v1":"bbf781d615e33299e708d4c33c516a12d0293cb2679389fb8d6352c38b23f4cb"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2 locations): crates/loro-wasm/index.ts:295 \u00B7 loro-js/src/runtime/ephemeral.ts:456 \u2014 the 2 copies are spread across 2 files, and what repeats is a LIST OF ENTRIES rather than behaviour \u2014 the same entries written out more than once. Extract them into one shared, exported constant and spread that constant into each site, rather than into a function the sites call: a list like this often lives in declarative metadata (a decorator\u0027s options object, a static configuration table) that a build step must be able to read statically, where a function call is not allowed. Adding an entry to one copy and not the other is the failure this prevents."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-wasm/index.ts"},"region":{"startLine":295}}}],"partialFingerprints":{"codehealthFindingId/v1":"fc86bdfa50f639d7fe4c0c633291d53feb69b5c856c9ba7a5d031fee090eb144"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2 locations): crates/loro-wasm/scripts/measure-snapshot-round-memory.cjs:203 \u00B7 crates/loro-wasm/scripts/measure-snapshot-round-memory.cjs:215 \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":"crates/loro-wasm/scripts/measure-snapshot-round-memory.cjs"},"region":{"startLine":203}}}],"partialFingerprints":{"codehealthFindingId/v1":"cb5fe901bd3e99578133f9a2f4f3d645e27656c4d826a59527286aeea66eb0e8"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2 locations): loro-js/src/codec/state-snapshot.ts:668 \u00B7 loro-js/src/codec/state-snapshot.ts:699 \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":"loro-js/src/codec/state-snapshot.ts"},"region":{"startLine":668}}}],"partialFingerprints":{"codehealthFindingId/v1":"15cc9f3a15d1a99588c21039f413e365d982d8fd344fd090ef2484acaee59e00"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2 locations): loro-js/src/runtime/containers.ts:553 \u00B7 loro-js/src/runtime/containers.ts:1955 \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":"loro-js/src/runtime/containers.ts"},"region":{"startLine":553}}}],"partialFingerprints":{"codehealthFindingId/v1":"1e5d5c90ff458caa1b84b53068760b0e341d6cbb582119806a9ef317617027c2"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2 locations): loro-js/src/runtime/document.ts:529 \u00B7 loro-js/src/runtime/document.ts:558 \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":"loro-js/src/runtime/document.ts"},"region":{"startLine":529}}}],"partialFingerprints":{"codehealthFindingId/v1":"32d77ce8f952518f0016c1970729bad83d0a74286cc1d9aa916236cc2404ee1c"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2 locations): loro-js/src/runtime/document.ts:1031 \u00B7 loro-js/src/runtime/document.ts:1161 \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":"loro-js/src/runtime/document.ts"},"region":{"startLine":1031}}}],"partialFingerprints":{"codehealthFindingId/v1":"ea03c6b0eebfd272f9854fbc5706d1b97c4d99cef6f644808637a66803ddf051"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2 locations): loro-js/src/runtime/document.ts:5210 \u00B7 loro-js/src/runtime/document.ts:5237 \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":"loro-js/src/runtime/document.ts"},"region":{"startLine":5210}}}],"partialFingerprints":{"codehealthFindingId/v1":"4e2182ee8a8476575f454b69165fb76e67f9428aa70ba76cb84a99bba31c4ec2"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2 locations): loro-js/src/runtime/document.ts:10257 \u00B7 loro-js/src/runtime/document.ts:10318 \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":"loro-js/src/runtime/document.ts"},"region":{"startLine":10257}}}],"partialFingerprints":{"codehealthFindingId/v1":"784d658139afd7b491a069ddeff8e21290a5175af9e278d64e9507710e985608"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2 locations): loro-js/src/runtime/sequence-index.ts:2936 \u00B7 loro-js/src/runtime/sequence-index.ts:3051 \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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":2936}}}],"partialFingerprints":{"codehealthFindingId/v1":"d9a56dc8b1ad01737d71332798f5a9255342df098d344dc3b58950e1b79d499d"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2 locations): loro-js/src/codec/bytes.ts:176 \u00B7 loro-js/src/codec/lz4.ts:326 \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":"loro-js/src/codec/bytes.ts"},"region":{"startLine":176}}}],"partialFingerprints":{"codehealthFindingId/v1":"7341189bcca675a2859ecf21ae53e186631d946eb24106fc175987886450ed93"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2 locations): loro-js/src/codec/change-block-tables.ts:384 \u00B7 loro-js/src/codec/change-block-tables.ts:419 \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":"loro-js/src/codec/change-block-tables.ts"},"region":{"startLine":384}}}],"partialFingerprints":{"codehealthFindingId/v1":"9395aabf20ae48b4c540742e474dce12caca2f95392c19766cdfc397625ca7e3"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block with local edits (11 matched lines \u00D7 2 locations): loro-js/src/codec/container-id.ts:170 \u00B7 loro-js/src/runtime/containers.ts:3370 \u2014 the two spans are one implementation copied and then locally edited \u2014 71 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":"loro-js/src/codec/container-id.ts"},"region":{"startLine":170}}}],"partialFingerprints":{"codehealthFindingId/v1":"9dabd17e658353a236314887965cd3988d3cc4a86f7bdaa253d60f4df02ac8da"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2 locations): loro-js/src/runtime/containers.ts:3120 \u00B7 loro-js/src/runtime/containers.ts:3140 \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":"loro-js/src/runtime/containers.ts"},"region":{"startLine":3120}}}],"partialFingerprints":{"codehealthFindingId/v1":"5333bd4a18e94556f2b7520a6cedabdb495281d492d4a9cac9be01da47b8e5fd"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2 locations): loro-js/src/runtime/jsonpath.ts:439 \u00B7 loro-js/src/runtime/jsonpath.ts:468 \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":"loro-js/src/runtime/jsonpath.ts"},"region":{"startLine":439}}}],"partialFingerprints":{"codehealthFindingId/v1":"d82de034656dccb238b6ab870555a93105e6aeb95c0283c61342b5ee67bf70d9"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2 locations): loro-js/src/runtime/sequence-deletion-index.ts:79 \u00B7 loro-js/src/runtime/sequence-deletion-index.ts:91 \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":"loro-js/src/runtime/sequence-deletion-index.ts"},"region":{"startLine":79}}}],"partialFingerprints":{"codehealthFindingId/v1":"54b0703d51e970566d61b8112a315158df2a7565c900f18dac3bd3282bf13783"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2 locations): loro-js/src/runtime/sequence-index.ts:433 \u00B7 loro-js/src/runtime/sequence-index.ts:880 \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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":433}}}],"partialFingerprints":{"codehealthFindingId/v1":"ef030350603214b166d718b1eb2e584a738b421c74cb62a26b901a39e884bd9c"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2 locations): loro-js/src/runtime/sequence-index.ts:658 \u00B7 loro-js/src/runtime/sequence-index.ts:674 \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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":658}}}],"partialFingerprints":{"codehealthFindingId/v1":"64162cfa8172379e1eefac7fc9acfd13b9e1f717ccb1a8c0f49bb2117618c7e7"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2 locations): loro-js/src/runtime/sequence-index.ts:755 \u00B7 loro-js/src/runtime/sequence-index.ts:967 \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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":755}}}],"partialFingerprints":{"codehealthFindingId/v1":"d2d387b2ded4f2340e6a5fbf1daa13e333993e911abbb46afc9db6267bdc4da1"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2 locations): loro-js/src/runtime/sequence-index.ts:3058 \u00B7 loro-js/src/runtime/sequence-index.ts:3284 \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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":3058}}}],"partialFingerprints":{"codehealthFindingId/v1":"52f42870b205b8521024d188e863762a8b54b7ddc61eb3838e178f4109807ee1"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2 locations): loro-js/src/runtime/sequence-index.ts:3900 \u00B7 loro-js/src/runtime/sequence-index.ts:3951 \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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":3900}}}],"partialFingerprints":{"codehealthFindingId/v1":"9e5d807829749133e713ed845b02f66105e1e42d4e8066e6fe4defd62a2899a6"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 3 locations): loro-js/src/runtime/text-style-index.ts:145 \u00B7 loro-js/src/runtime/text-style-index.ts:192 \u00B7 loro-js/src/runtime/text-style-index.ts:303 \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":"loro-js/src/runtime/text-style-index.ts"},"region":{"startLine":145}}}],"partialFingerprints":{"codehealthFindingId/v1":"d29a3a8a7d9903affac779d5cff352fbcfe944363c2dc3e4bc6994904a38aeee"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2 locations): loro-js/src/codec/document.ts:27 \u00B7 loro-js/src/codec/lz4.ts:15 \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":"loro-js/src/codec/document.ts"},"region":{"startLine":27}}}],"partialFingerprints":{"codehealthFindingId/v1":"b42cb8ca5e72adb80dd19550181e61382a4aaf9885fea3f84764d4eff008ef13"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 3 locations): loro-js/src/codec/serde-columnar.ts:354 \u00B7 loro-js/src/codec/serde-columnar.ts:372 \u00B7 loro-js/src/codec/serde-columnar.ts:433 \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":"loro-js/src/codec/serde-columnar.ts"},"region":{"startLine":354}}}],"partialFingerprints":{"codehealthFindingId/v1":"43704c10c944094161f72af215cc5e287a106170eee0532bda6a9c09ef49ae29"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2 locations): loro-js/src/codec/state-snapshot.ts:465 \u00B7 loro-js/src/codec/state-snapshot.ts:476 \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":"loro-js/src/codec/state-snapshot.ts"},"region":{"startLine":465}}}],"partialFingerprints":{"codehealthFindingId/v1":"21c998c64a5675e4be43bd36b527cce24ec202fb360643090f0c6643d8ecb0a7"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2 locations): loro-js/src/codec/state-snapshot.ts:844 \u00B7 loro-js/src/codec/state-snapshot.ts:855 \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":"loro-js/src/codec/state-snapshot.ts"},"region":{"startLine":844}}}],"partialFingerprints":{"codehealthFindingId/v1":"0fcc6296f8de20b952e21b27ef9fa366d9c27e8e319b61ca0375eb20ebe91f46"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 4 locations): loro-js/src/runtime/containers.ts:3427 \u00B7 loro-js/src/runtime/containers.ts:3439 \u00B7 loro-js/src/runtime/containers.ts:3486 \u00B7 loro-js/src/runtime/json-updates.ts:62 \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":"loro-js/src/runtime/containers.ts"},"region":{"startLine":3427}}}],"partialFingerprints":{"codehealthFindingId/v1":"21d89e8f2ae0bbd04679d516f3606a0e6649d8dab0c4673ee2ddf3d544b48046"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2 locations): loro-js/src/runtime/containers.ts:3696 \u00B7 loro-js/src/runtime/containers.ts:3749 \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":"loro-js/src/runtime/containers.ts"},"region":{"startLine":3696}}}],"partialFingerprints":{"codehealthFindingId/v1":"e579a590ef891dfc42cdc7bd717d3c84961cbff340d7810578a49f041b05000c"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2 locations): loro-js/src/runtime/containers.ts:4042 \u00B7 loro-js/src/runtime/document.ts:9729 \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":"loro-js/src/runtime/containers.ts"},"region":{"startLine":4042}}}],"partialFingerprints":{"codehealthFindingId/v1":"124eb0994eb17e6e7cb2484811d735fd267112736cc37189b0a1423b31a8dc5f"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2 locations): loro-js/src/runtime/document.ts:4699 \u00B7 loro-js/src/runtime/document.ts:4748 \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":"loro-js/src/runtime/document.ts"},"region":{"startLine":4699}}}],"partialFingerprints":{"codehealthFindingId/v1":"3595f4476e095bc8e2f7df428fede6e22df3817ca5910d6a221f1e65654ded84"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 3 locations): loro-js/src/runtime/document.ts:4829 \u00B7 loro-js/src/runtime/document.ts:4854 \u00B7 loro-js/src/runtime/document.ts:4874 \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":"loro-js/src/runtime/document.ts"},"region":{"startLine":4829}}}],"partialFingerprints":{"codehealthFindingId/v1":"0df184060484ec73611d2a4bfc81630ec0e9b142df255d3fa7d4b3dcb226b714"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 3 locations): loro-js/src/runtime/document.ts:7597 \u00B7 loro-js/src/runtime/document.ts:7627 \u00B7 loro-js/src/runtime/document.ts:7782 \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":"loro-js/src/runtime/document.ts"},"region":{"startLine":7597}}}],"partialFingerprints":{"codehealthFindingId/v1":"55f2328e1c74ee899a335c1f3a28f431f974be89cfdf82052de0ffdf89d2cde3"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2 locations): loro-js/src/runtime/event-diff.ts:198 \u00B7 loro-js/src/runtime/ordered-index.ts:164 \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":"loro-js/src/runtime/event-diff.ts"},"region":{"startLine":198}}}],"partialFingerprints":{"codehealthFindingId/v1":"12009112e7604e17f0d9a525a2ab4f51c333471fd6e94586a74b6d772ef06c9c"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2 locations): loro-js/src/runtime/sequence-index.ts:1003 \u00B7 loro-js/src/runtime/sequence-index.ts:1014 \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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":1003}}}],"partialFingerprints":{"codehealthFindingId/v1":"c9b6e855e311123018e96a827c01fc8ec330e704aa0f04e836b7ed466b0c45e4"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2 locations): loro-js/src/runtime/sequence-index.ts:2853 \u00B7 loro-js/src/runtime/sequence-index.ts:2968 \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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":2853}}}],"partialFingerprints":{"codehealthFindingId/v1":"8ec0c850a8cf25b5d66eb3e3301f5fa4b69791cc8e51a0b927f24ce7a4b69b51"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2 locations): loro-js/src/codec/change-block-codec.ts:780 \u00B7 loro-js/src/codec/serde-columnar.ts:755 \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":"loro-js/src/codec/change-block-codec.ts"},"region":{"startLine":780}}}],"partialFingerprints":{"codehealthFindingId/v1":"019e10c4f02951130becda5ec57308d668c0797338d0ef55d986430a65520d6c"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2 locations): loro-js/src/runtime/document.ts:2721 \u00B7 loro-js/src/runtime/document.ts:11215 \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":"loro-js/src/runtime/document.ts"},"region":{"startLine":2721}}}],"partialFingerprints":{"codehealthFindingId/v1":"3089193a937d19bc9e3b6af36ebdc083a74d5a7ac78675ea2df8913b3f72712f"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2 locations): loro-js/src/runtime/document.ts:2739 \u00B7 loro-js/src/runtime/document.ts:11227 \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":"loro-js/src/runtime/document.ts"},"region":{"startLine":2739}}}],"partialFingerprints":{"codehealthFindingId/v1":"eb42892f2e13c6d4f9a662ae23816a46cf60dce650ab0b3cfa214dabf6d1f7ab"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2 locations): loro-js/src/runtime/document.ts:2886 \u00B7 loro-js/src/runtime/document.ts:8079 \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":"loro-js/src/runtime/document.ts"},"region":{"startLine":2886}}}],"partialFingerprints":{"codehealthFindingId/v1":"4ed07f00b8a64623481c5ee51b0884ef366079cde5f70ef3e98bc634e2ab2333"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2 locations): loro-js/src/runtime/document.ts:4709 \u00B7 loro-js/src/runtime/document.ts:6172 \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":"loro-js/src/runtime/document.ts"},"region":{"startLine":4709}}}],"partialFingerprints":{"codehealthFindingId/v1":"540b1c685f073d4d9fc158a2096b776b6346231ef522690c0aa5ed284ab255ba"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2 locations): loro-js/src/runtime/document.ts:5476 \u00B7 loro-js/src/runtime/document.ts:8942 \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":"loro-js/src/runtime/document.ts"},"region":{"startLine":5476}}}],"partialFingerprints":{"codehealthFindingId/v1":"937e0fc9640ba8ba9353006d952d50ab1485b053e239548422f3491d97de31f3"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2 locations): loro-js/src/runtime/document.ts:6865 \u00B7 loro-js/src/runtime/document.ts:6882 \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":"loro-js/src/runtime/document.ts"},"region":{"startLine":6865}}}],"partialFingerprints":{"codehealthFindingId/v1":"6ad0ab2978bd09424d7c49730a1e7a5fdb2fbb61e52f990ae8aea09bba2a915d"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2 locations): loro-js/src/runtime/jsonpath.ts:187 \u00B7 loro-js/src/runtime/jsonpath.ts:870 \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":"loro-js/src/runtime/jsonpath.ts"},"region":{"startLine":187}}}],"partialFingerprints":{"codehealthFindingId/v1":"ca73d3186aa73bbd54da1ee3a7092d473655e89f892d090851e0fb03e328dadc"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block with local edits (9 matched lines \u00D7 2 locations): loro-js/src/runtime/ordered-index.ts:113 \u00B7 loro-js/src/runtime/ordered-index.ts:131 \u2014 the two spans are one implementation copied and then locally edited \u2014 59 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":"loro-js/src/runtime/ordered-index.ts"},"region":{"startLine":113}}}],"partialFingerprints":{"codehealthFindingId/v1":"dd5acc73b66119dafa518d92e707f85c9ee71193cd14a257ca3ab6979dfd5d77"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2 locations): loro-js/src/runtime/sequence-index.ts:254 \u00B7 loro-js/src/runtime/sequence-index.ts:1552 \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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":254}}}],"partialFingerprints":{"codehealthFindingId/v1":"68130af000ecbd6eada9e9ea41d928bb339969f5ca859462d50eb1d6500b7df1"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2 locations): loro-js/src/runtime/sequence-index.ts:857 \u00B7 loro-js/src/runtime/sequence-index.ts:920 \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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":857}}}],"partialFingerprints":{"codehealthFindingId/v1":"35b044ef0d5bb5e568e8d8592aaba2111d4ef17462fa5f9399303bea505b0982"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2 locations): loro-js/src/runtime/sequence-index.ts:1720 \u00B7 loro-js/src/runtime/sequence-index.ts:1781 \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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":1720}}}],"partialFingerprints":{"codehealthFindingId/v1":"4ec330baea29d79e9667b1792f37344702b088a94adb6f4828bfbd97bea3fae8"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2 locations): loro-js/scripts/rewrite-rust-fixture.mjs:110 \u00B7 loro-js/scripts/rewrite-rust-fixture.mjs:118 \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":"loro-js/scripts/rewrite-rust-fixture.mjs"},"region":{"startLine":110}}}],"partialFingerprints":{"codehealthFindingId/v1":"1a327e4249ae5e97ce8a1a477041ddd93d75b991184db40517145d0acc44b7b4"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2 locations): loro-js/src/codec/change-block-codec.ts:410 \u00B7 loro-js/src/codec/change-block-codec.ts:426 \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":"loro-js/src/codec/change-block-codec.ts"},"region":{"startLine":410}}}],"partialFingerprints":{"codehealthFindingId/v1":"5a32b5f1135c120cb8c29cbc802fa4f6e3da106d96e12390f027bd767b5b7815"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2 locations): loro-js/src/codec/change-block-codec.ts:573 \u00B7 loro-js/src/codec/change-block-codec.ts:581 \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":"loro-js/src/codec/change-block-codec.ts"},"region":{"startLine":573}}}],"partialFingerprints":{"codehealthFindingId/v1":"9418feef1b14ebf6f2bfef4a2c1c47f6ee7e449289aaa7f1970969e10d4ec5ad"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block with local edits (8 matched lines \u00D7 2 locations): loro-js/src/codec/change-block-tables.ts:463 \u00B7 loro-js/src/codec/change-value.ts:474 \u2014 the two spans are one implementation copied and then locally edited \u2014 57 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":"loro-js/src/codec/change-block-tables.ts"},"region":{"startLine":463}}}],"partialFingerprints":{"codehealthFindingId/v1":"010ddd77da1096302b3cac6380065c85f549778fead94253d15d08ad0ba8a5f2"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 3 locations): loro-js/src/codec/change-block-tables.ts:387 \u00B7 loro-js/src/codec/change-block-tables.ts:422 \u00B7 loro-js/src/codec/position-arena.ts:11 \u2014 the 3 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":"loro-js/src/codec/change-block-tables.ts"},"region":{"startLine":387}}}],"partialFingerprints":{"codehealthFindingId/v1":"00abfbf888f3cd63e03e873d7c479c0465b4beed690b2aa53b2eee55dcb4c8c8"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 3 locations): loro-js/src/codec/state-snapshot.ts:372 \u00B7 loro-js/src/codec/state-snapshot.ts:485 \u00B7 loro-js/src/codec/state-snapshot.ts:494 \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":"loro-js/src/codec/state-snapshot.ts"},"region":{"startLine":372}}}],"partialFingerprints":{"codehealthFindingId/v1":"137310207adbf2c5e15ab8066318bcadce8b10af40f4a831cde69418aa54e282"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2 locations): loro-js/src/codec/state-snapshot.ts:482 \u00B7 loro-js/src/codec/state-snapshot.ts:491 \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":"loro-js/src/codec/state-snapshot.ts"},"region":{"startLine":482}}}],"partialFingerprints":{"codehealthFindingId/v1":"a9cb4fe5d9b2f89cacb8f029357994e34b7ceb4acb38a432857ccba414d93a94"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2 locations): loro-js/src/codec/state-snapshot.ts:785 \u00B7 loro-js/src/codec/state-snapshot.ts:814 \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":"loro-js/src/codec/state-snapshot.ts"},"region":{"startLine":785}}}],"partialFingerprints":{"codehealthFindingId/v1":"4cfa0f1855a86c9d3d5bed286681fec4c14dd175b9b77e8b0886222ab8a1c76e"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2 locations): loro-js/src/runtime/containers.ts:3501 \u00B7 loro-js/src/runtime/document.ts:11037 \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":"loro-js/src/runtime/containers.ts"},"region":{"startLine":3501}}}],"partialFingerprints":{"codehealthFindingId/v1":"e4c5d2ef1cb9397e55bf78e8b02fee0a5d66aaefe7436bfeffbb16b516ff6093"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2 locations): loro-js/src/runtime/document.ts:1513 \u00B7 loro-js/src/runtime/sequence-index.ts:3571 \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":"loro-js/src/runtime/document.ts"},"region":{"startLine":1513}}}],"partialFingerprints":{"codehealthFindingId/v1":"e06e826e0cfd35c4e6ca7434a236bd35a5fd88377340c17f0e06f7735a30539c"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2 locations): loro-js/src/runtime/ordered-index.ts:122 \u00B7 loro-js/src/runtime/sequence-index.ts:868 \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":"loro-js/src/runtime/ordered-index.ts"},"region":{"startLine":122}}}],"partialFingerprints":{"codehealthFindingId/v1":"2671982d1e0f8254997660241d5c8f238c9a686d4d3ed2280c36ee516e86199d"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2 locations): loro-js/src/runtime/sequence-index.ts:3779 \u00B7 loro-js/src/runtime/sequence-index.ts:3850 \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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":3779}}}],"partialFingerprints":{"codehealthFindingId/v1":"d8864dc0596e3b67250ef7f5cf1da3b7d7edb78da4bb998d8c139dbb9f7ecfc3"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2 locations): loro-js/src/runtime/text-style-index.ts:198 \u00B7 loro-js/src/runtime/text-style-index.ts:309 \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":"loro-js/src/runtime/text-style-index.ts"},"region":{"startLine":198}}}],"partialFingerprints":{"codehealthFindingId/v1":"1ac601133efd5f65bac7dbf8fa0fbd5ab15d8e3d22d4dd8e4c7260f6161d459f"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2 locations): loro-js/scripts/write-legacy-fixtures.mjs:71 \u00B7 loro-js/scripts/write-rust-richtext-fixtures.cjs:24 \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":"loro-js/scripts/write-legacy-fixtures.mjs"},"region":{"startLine":71}}}],"partialFingerprints":{"codehealthFindingId/v1":"28042475be27936ef32d4b34c21d9b5da293161a95bdac36a6ca71dafd6a8e86"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 4 locations): loro-js/src/codec/change-block-tables.ts:426 \u00B7 loro-js/src/codec/state-snapshot.ts:256 \u00B7 loro-js/src/codec/state-snapshot.ts:463 \u00B7 loro-js/src/codec/state-snapshot.ts:474 \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":"loro-js/src/codec/change-block-tables.ts"},"region":{"startLine":426}}}],"partialFingerprints":{"codehealthFindingId/v1":"5b054db8c3fca2ee50a7457a1f8ff0254d877cf9eaf816661c36b4b3c37149e3"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 3 locations): loro-js/src/codec/serde-columnar.ts:333 \u00B7 loro-js/src/codec/serde-columnar.ts:407 \u00B7 loro-js/src/codec/serde-columnar.ts:461 \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":"loro-js/src/codec/serde-columnar.ts"},"region":{"startLine":333}}}],"partialFingerprints":{"codehealthFindingId/v1":"34f5f6ddfba2badbc7792f03e7238bfa199fb04ac26e7e0206c5804e894c3218"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2 locations): loro-js/src/runtime/containers.ts:2517 \u00B7 loro-js/src/runtime/document.ts:10951 \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":"loro-js/src/runtime/containers.ts"},"region":{"startLine":2517}}}],"partialFingerprints":{"codehealthFindingId/v1":"d60e5f162617a5dd61a9b634b9d8085f0e50593c50056e233e4b7449b8c39845"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2 locations): loro-js/src/runtime/containers.ts:3996 \u00B7 loro-js/src/runtime/document.ts:10511 \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":"loro-js/src/runtime/containers.ts"},"region":{"startLine":3996}}}],"partialFingerprints":{"codehealthFindingId/v1":"c407ebc367b62333b1e5c65e30773c4b279ae6c8726caaf98abfa1140b744a1e"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2 locations): loro-js/src/runtime/document.ts:999 \u00B7 loro-js/src/runtime/document.ts:5485 \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":"loro-js/src/runtime/document.ts"},"region":{"startLine":999}}}],"partialFingerprints":{"codehealthFindingId/v1":"a69d37a23f458006ad4ce6637fb4e5b308714a8e463567e034d317c8cd952ef1"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2 locations): loro-js/src/runtime/document.ts:5093 \u00B7 loro-js/src/runtime/document.ts:8482 \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":"loro-js/src/runtime/document.ts"},"region":{"startLine":5093}}}],"partialFingerprints":{"codehealthFindingId/v1":"320bd5750a9b0eb66396c4b622c3ae8ef5a1facd10d0ee4e303ae78952bf9493"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2 locations): loro-js/src/runtime/document.ts:5760 \u00B7 loro-js/src/runtime/document.ts:5919 \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":"loro-js/src/runtime/document.ts"},"region":{"startLine":5760}}}],"partialFingerprints":{"codehealthFindingId/v1":"0f3032cf6ceb0c0bd854bcf50d9ba476ac0326748a7e7a87cbbea4c1341d14e7"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2 locations): loro-js/src/runtime/jsonpath.ts:573 \u00B7 loro-js/src/runtime/jsonpath.ts:587 \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":"loro-js/src/runtime/jsonpath.ts"},"region":{"startLine":573}}}],"partialFingerprints":{"codehealthFindingId/v1":"ffc9a9273b3cbeb73d732f48e5dbcf5ce2d88693dd8b27fe415f90e7fc8de9be"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2 locations): loro-js/src/runtime/sequence-index.ts:1025 \u00B7 loro-js/src/runtime/sequence-index.ts:1104 \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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":1025}}}],"partialFingerprints":{"codehealthFindingId/v1":"7a32eab086de0926cc5377e8f5aa98743b7d3b29d9e4e9b2b66cf539fa8d7f9b"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2 locations): loro-js/src/runtime/sequence-index.ts:1115 \u00B7 loro-js/src/runtime/sequence-index.ts:1123 \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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":1115}}}],"partialFingerprints":{"codehealthFindingId/v1":"d5ff187061768b03426832cd787f370126ed524c0a450505e23377b3c78d25d4"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2 locations): loro-js/src/runtime/sequence-index.ts:3444 \u00B7 loro-js/src/runtime/sequence-index.ts:3491 \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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":3444}}}],"partialFingerprints":{"codehealthFindingId/v1":"51ace71e74ddf8920cd17452cf94b9589b0706f529e474280ca49d01d868c047"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2 locations): loro-js/scripts/write-rust-richtext-fixtures.cjs:23 \u00B7 loro-js/scripts/write-rust-richtext-fixtures.cjs:34 \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":"loro-js/scripts/write-rust-richtext-fixtures.cjs"},"region":{"startLine":23}}}],"partialFingerprints":{"codehealthFindingId/v1":"32e17214b24463a082faa8503fa8c17f5c2bea0b37e9eaea687ba383080b8669"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 3 locations): loro-js/src/codec/state-snapshot.ts:301 \u00B7 loro-js/src/codec/state-snapshot.ts:462 \u00B7 loro-js/src/codec/state-snapshot.ts:472 \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":"loro-js/src/codec/state-snapshot.ts"},"region":{"startLine":301}}}],"partialFingerprints":{"codehealthFindingId/v1":"4b896976953c3bea2de85a57832444ceb49399f751ee5a557700fad4f0282d98"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2 locations): loro-js/src/runtime/document.ts:6983 \u00B7 loro-js/src/runtime/document.ts:7038 \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":"loro-js/src/runtime/document.ts"},"region":{"startLine":6983}}}],"partialFingerprints":{"codehealthFindingId/v1":"3894bdff06613c08774bf66f842fb201fb410e7a1cd1284c568683fac21e8843"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2 locations): loro-js/src/runtime/document.ts:7437 \u00B7 loro-js/src/runtime/document.ts:7470 \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":"loro-js/src/runtime/document.ts"},"region":{"startLine":7437}}}],"partialFingerprints":{"codehealthFindingId/v1":"da1658312fcbad48c8ea7589918e2b923b69e4e647df0aec4bb42e4bb1103ce3"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2 locations): loro-js/src/runtime/fractional-index.ts:106 \u00B7 packages/fractional-index/src/index.ts:515 \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":"loro-js/src/runtime/fractional-index.ts"},"region":{"startLine":106}}}],"partialFingerprints":{"codehealthFindingId/v1":"24f453bd711a2fd9321b5baf8e548a3817878fc224e564fa22b49e9d3da7268d"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block with local edits (6 matched lines \u00D7 2 locations): loro-js/src/runtime/fractional-index.ts:62 \u00B7 loro-js/src/runtime/fractional-index.ts:74 \u2014 the two spans are one implementation copied and then locally edited \u2014 86 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":"loro-js/src/runtime/fractional-index.ts"},"region":{"startLine":62}}}],"partialFingerprints":{"codehealthFindingId/v1":"36158b19f0e8b012fd883f241e2240b0b61eee1a835840adc0ad34753aa888ba"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2 locations): loro-js/src/runtime/jsonpath.ts:379 \u00B7 loro-js/src/runtime/jsonpath.ts:387 \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":"loro-js/src/runtime/jsonpath.ts"},"region":{"startLine":379}}}],"partialFingerprints":{"codehealthFindingId/v1":"15c271d77b7dd86bd17196302b11e8f2fc5c8a065b7f18e6ccf21cef9a8effb4"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 3 locations): loro-js/src/runtime/sequence-deletion-index.ts:110 \u00B7 loro-js/src/runtime/text-style-index.ts:198 \u00B7 loro-js/src/runtime/text-style-index.ts:309 \u2014 the 3 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":"loro-js/src/runtime/sequence-deletion-index.ts"},"region":{"startLine":110}}}],"partialFingerprints":{"codehealthFindingId/v1":"486687975a16ba6df940cdb71613a6e1a35b016751f9de7700d8f666637d802f"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2 locations): loro-js/src/runtime/sequence-index.ts:383 \u00B7 loro-js/src/runtime/sequence-index.ts:398 \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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":383}}}],"partialFingerprints":{"codehealthFindingId/v1":"0c174650efdfb63f76589a13664414dab9b0242bb61922237fc0c48401a5fcfb"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2 locations): loro-js/src/runtime/sequence-index.ts:1229 \u00B7 loro-js/src/runtime/sequence-index.ts:1253 \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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":1229}}}],"partialFingerprints":{"codehealthFindingId/v1":"d63fc24ffbb64d22f76e0b3bd82f571270e35f6c332343b5b29f510f6cd2d563"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2 locations): loro-js/src/runtime/text-style-index.ts:191 \u00B7 loro-js/src/runtime/text-style-index.ts:301 \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":"loro-js/src/runtime/text-style-index.ts"},"region":{"startLine":191}}}],"partialFingerprints":{"codehealthFindingId/v1":"a92caae4902e98db190aafe28ac7969bb98ba83fcfc5369dbe276cce4d1f1c80"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2 locations): loro-js/src/runtime/text-style-index.ts:236 \u00B7 loro-js/src/runtime/text-style-index.ts: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":"loro-js/src/runtime/text-style-index.ts"},"region":{"startLine":236}}}],"partialFingerprints":{"codehealthFindingId/v1":"dd4051aa6645a35b893fbe5c701429bc3dc699abe31b8b411668abe558c43a22"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block with local edits (5 matched lines \u00D7 2 locations): loro-js/src/runtime/containers.ts:2307 \u00B7 loro-js/src/runtime/text-style-index.ts:479 \u2014 the two spans are one implementation copied and then locally edited \u2014 52 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":"loro-js/src/runtime/containers.ts"},"region":{"startLine":2307}}}],"partialFingerprints":{"codehealthFindingId/v1":"29cbe5a3876798e326c307cccaf32ae186c80465c652288bafac8d0854a6995b"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2 locations): loro-js/src/runtime/document.ts:10467 \u00B7 loro-js/src/runtime/ephemeral.ts:551 \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":"loro-js/src/runtime/document.ts"},"region":{"startLine":10467}}}],"partialFingerprints":{"codehealthFindingId/v1":"c6eb0285af4adc1b2635977424f29a3c3715a37788d627a793de2cf76fd90b2d"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2 locations): loro-js/src/runtime/document.ts:10805 \u00B7 loro-js/src/runtime/document.ts:11035 \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":"loro-js/src/runtime/document.ts"},"region":{"startLine":10805}}}],"partialFingerprints":{"codehealthFindingId/v1":"aa730c2860f6271ff8f46d8f394d92fbe4dc169ed7c561c32330b282d2cfef5c"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2 locations): loro-js/src/runtime/sequence-index.ts:2161 \u00B7 loro-js/src/runtime/sequence-index.ts:2243 \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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":2161}}}],"partialFingerprints":{"codehealthFindingId/v1":"3dbce4829e9c7458e8d96b5d890f517826c43c1dea3c6ff073314742fdfed564"}},{"ruleId":"R10","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2 locations): loro-js/src/runtime/sequence-index.ts:2497 \u00B7 loro-js/src/runtime/sequence-index.ts:2507 \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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":2497}}}],"partialFingerprints":{"codehealthFindingId/v1":"7be38a2394fb0d84bdc25d08eb8d57438ad9cc0e68d3a15e4a63fdcba122b2b7"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function (anonymous) (cyclomatic 42, cognitive 87): (anonymous) has cyclomatic complexity 42 and cognitive complexity 87; 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":"loro-js/src/runtime/document.ts"},"region":{"startLine":5891}}}],"partialFingerprints":{"codehealthFindingId/v1":"335a414007ee919a7200e3a1c2a9f9ef968e074a49c162e5d84bfa13dd948429"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function concreteOp (cyclomatic 40, cognitive 56): concreteOp has cyclomatic complexity 40 and cognitive complexity 56; 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":"loro-js/tests/fuzz/differential.ts"},"region":{"startLine":991}}}],"partialFingerprints":{"codehealthFindingId/v1":"ff50400b95bd05e8cf201cb08ae3bded914c8c75ab982361bf7e6c0be5980f63"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function jsonOperationToDecoded (cyclomatic 37, cognitive 64): jsonOperationToDecoded has cyclomatic complexity 37 and cognitive complexity 64; 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":"loro-js/src/runtime/document.ts"},"region":{"startLine":10197}}}],"partialFingerprints":{"codehealthFindingId/v1":"d5d32235504598e8934f4436d8b6ebded21889b184dc9ff7941dbdaf72fc7a1a"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function transition (cyclomatic 34, cognitive 45): transition has cyclomatic complexity 34 and cognitive complexity 45; 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":"loro-js/src/runtime/movable-list.ts"},"region":{"startLine":540}}}],"partialFingerprints":{"codehealthFindingId/v1":"85b0e4368df23d3efe5400eac2b7afa3a44fc037d37c1a6000a2e5396450a37c"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function generateAction (cyclomatic 32, cognitive 26): generateAction has cyclomatic complexity 32 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 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":"loro-js/tests/differential/fuzz.ts"},"region":{"startLine":245}}}],"partialFingerprints":{"codehealthFindingId/v1":"2a078f6355b8a1c11d996b4acf0284ba7bee6e681228b882d4dce5d3344d86ac"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function recomputeOwnElements (cyclomatic 31, cognitive 52): recomputeOwnElements has cyclomatic complexity 31 and cognitive complexity 52; 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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":2947}}}],"partialFingerprints":{"codehealthFindingId/v1":"1fdae40778330b788bc2583cd62d59d0c2e3609b8119fb99cb0b215b12920f0d"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function decodeImportBlobMeta (cyclomatic 31, cognitive 46): decodeImportBlobMeta has cyclomatic complexity 31 and cognitive complexity 46; 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":"loro-js/src/runtime/document.ts"},"region":{"startLine":8895}}}],"partialFingerprints":{"codehealthFindingId/v1":"6ed580f6580f2eba3b62dd1ba6e4b3359857c3bcbae411127da80d090a679b45"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function applySelector (cyclomatic 30, cognitive 77): applySelector has cyclomatic complexity 30 and cognitive complexity 77; 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":"loro-js/src/runtime/jsonpath.ts"},"region":{"startLine":281}}}],"partialFingerprints":{"codehealthFindingId/v1":"2cc0290649095e34b8b5ce5c66cee08c0e256bbb6d6b8c6c0ef36af2160439ad"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function insertSpanAtPhysical (cyclomatic 29, cognitive 46): insertSpanAtPhysical has cyclomatic complexity 29 and cognitive complexity 46; 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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":1104}}}],"partialFingerprints":{"codehealthFindingId/v1":"58345ffe5abe135fb62b7f56009c973d603214c8e607746951d9d19c0a81d652"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function apply (cyclomatic 29, cognitive 21): apply has cyclomatic complexity 29 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":"loro-js/tests/differential/fuzz.ts"},"region":{"startLine":405}}}],"partialFingerprints":{"codehealthFindingId/v1":"2d8e547287a5af3c0408f20194a437ccb365a22006c47a4d591f80e47ef2525b"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function recomputeOwn (cyclomatic 28, cognitive 47): recomputeOwn has cyclomatic complexity 28 and cognitive complexity 47; 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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":2834}}}],"partialFingerprints":{"codehealthFindingId/v1":"cbe0174be1030c23ef7f36365aa5fd8e4383c59888be86db7926c042305d1fe8"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function generateActions (cyclomatic 28, cognitive 35): generateActions has cyclomatic complexity 28 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":"loro-js/tests/support/richtext-differential.ts"},"region":{"startLine":189}}}],"partialFingerprints":{"codehealthFindingId/v1":"a3488c8162f646dadf192a23614fe25d24869ba3aea50e28adb933cfb9f2ccaf"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function encodeChangeValueContent (cyclomatic 28, cognitive 17): encodeChangeValueContent has cyclomatic complexity 28 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":"loro-js/src/codec/change-value.ts"},"region":{"startLine":212}}}],"partialFingerprints":{"codehealthFindingId/v1":"64292b37c3bc8a66ee0a7bed4b42bc3de7d4d8eee76b31e327263a5180e1f305"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function apply (cyclomatic 27, cognitive 47): apply has cyclomatic complexity 27 and cognitive complexity 47; 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":"loro-js/src/runtime/movable-list-undo.ts"},"region":{"startLine":73}}}],"partialFingerprints":{"codehealthFindingId/v1":"40259083d282231656e4b779ecbfe7c401979176e9f3232f0e25a913d692dbe5"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function primitiveCompare (cyclomatic 27, cognitive 29): primitiveCompare has cyclomatic complexity 27 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":"loro-js/src/runtime/jsonpath.ts"},"region":{"startLine":766}}}],"partialFingerprints":{"codehealthFindingId/v1":"fb3c16e299ae907b59217cd4d218d8bc67848e6cae24c9604ad11383923bab80"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function insertAtPhysical (cyclomatic 26, cognitive 40): insertAtPhysical has cyclomatic complexity 26 and cognitive complexity 40; 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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":1025}}}],"partialFingerprints":{"codehealthFindingId/v1":"ecc2c78a4032e60c01618876e68fb35ee5c0e1f26dfb02d3715b29263bd3218c"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function decodeOperationContent (cyclomatic 25, cognitive 40): decodeOperationContent has cyclomatic complexity 25 and cognitive complexity 40; 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":"loro-js/src/codec/change-block-codec.ts"},"region":{"startLine":358}}}],"partialFingerprints":{"codehealthFindingId/v1":"dfa962f3206e18764c944a316e06c2f5992daed4b036d176a75d4d685b2e560c"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function #record (cyclomatic 25, cognitive 27): #record has cyclomatic complexity 25 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 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":"loro-js/src/runtime/undo.ts"},"region":{"startLine":239}}}],"partialFingerprints":{"codehealthFindingId/v1":"878fb79698a74d84b0fd014e386231300f6dc64df4adf5b1ab225c47266a2753"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function #apply (cyclomatic 25, cognitive 24): #apply has cyclomatic complexity 25 and cognitive complexity 24; 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":"loro-js/tests/support/richtext-differential.ts"},"region":{"startLine":349}}}],"partialFingerprints":{"codehealthFindingId/v1":"4c3dbc80be578f7aac9cbfbae1fccc634cff1e56c1599717393038c720c186ff"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function equivalentEvents (cyclomatic 24, cognitive 43): equivalentEvents has cyclomatic complexity 24 and cognitive complexity 43; 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":"loro-js/tests/differential/harness.ts"},"region":{"startLine":484}}}],"partialFingerprints":{"codehealthFindingId/v1":"28fd650ac3319e693039e519f28f1c9b48bbb980ed5ea81181def73212029f4c"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function recomputeVisibility (cyclomatic 24, cognitive 12): recomputeVisibility has cyclomatic complexity 24 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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":3074}}}],"partialFingerprints":{"codehealthFindingId/v1":"f6bdb37d6b080cc3c62e93b736d12c78e225517626974d6c167b9451f5d44b6e"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function lookupChild (cyclomatic 23, cognitive 33): lookupChild has cyclomatic complexity 23 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 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":"loro-js/src/runtime/jsonpath.ts"},"region":{"startLine":369}}}],"partialFingerprints":{"codehealthFindingId/v1":"3888254b89b91d7bb31500e5ecbcbfaebbfdd8811111898b29e61e1590ad46bc"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function fugueInsertion (cyclomatic 23, cognitive 22): fugueInsertion has cyclomatic complexity 23 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 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":"loro-js/src/runtime/containers.ts"},"region":{"startLine":3598}}}],"partialFingerprints":{"codehealthFindingId/v1":"e61113e687cdefaa874d3b01451751a7dc166ce60da7b7d6f0e1705ebabb9b32"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function recompute (cyclomatic 23, cognitive 15): recompute has cyclomatic complexity 23 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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":3131}}}],"partialFingerprints":{"codehealthFindingId/v1":"a080797a8e550b991c77e124781580aa9ab5f1a96ba353450a07742348b413b2"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function decodedOperationToJson (cyclomatic 23, cognitive 13): decodedOperationToJson has cyclomatic complexity 23 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":"loro-js/src/runtime/document.ts"},"region":{"startLine":9917}}}],"partialFingerprints":{"codehealthFindingId/v1":"42740508e9e4c7e4e84e1a0f9810cb48050c357de3ec9e9ae1ea8dff0d8a39af"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function assertTwinAgrees (cyclomatic 22, cognitive 35): assertTwinAgrees has cyclomatic complexity 22 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":"loro-js/tests/differential/harness.ts"},"region":{"startLine":385}}}],"partialFingerprints":{"codehealthFindingId/v1":"b0a988fa13f5f871174126f9376f9089ff9807a39006df1c0515d937ea7d59e1"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function writeSleb128 (cyclomatic 22, cognitive 25): writeSleb128 has cyclomatic complexity 22 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":"loro-js/src/codec/leb128.ts"},"region":{"startLine":94}}}],"partialFingerprints":{"codehealthFindingId/v1":"f75434563fb9a6f327d3fc4da8c6bb2176b0c6d50248b256070e341bc0795d00"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function containerDiff (cyclomatic 21, cognitive 30): containerDiff has cyclomatic complexity 21 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 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":"loro-js/src/runtime/document.ts"},"region":{"startLine":10702}}}],"partialFingerprints":{"codehealthFindingId/v1":"37c9639451521fc1f267d4477c7e6c1c88b7d257620e02dd7e40e4752681d0c1"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function encodeChangeBlock (cyclomatic 21, cognitive 27): encodeChangeBlock has cyclomatic complexity 21 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 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":"loro-js/src/codec/change-block-codec.ts"},"region":{"startLine":234}}}],"partialFingerprints":{"codehealthFindingId/v1":"8ee715a5d971d92da59dba782bda5782f31adcf588bfe4b0b4f27455455107e1"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function styleValuesEqual (cyclomatic 21, cognitive 17): styleValuesEqual has cyclomatic complexity 21 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":"loro-js/src/runtime/containers.ts"},"region":{"startLine":2491}}}],"partialFingerprints":{"codehealthFindingId/v1":"d9c43a74f824a9b1d8870b1e822f90af91109e888a4463e8501da9d77c0d55e2"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function rewrite (cyclomatic 20, cognitive 37): rewrite has cyclomatic complexity 20 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":"loro-js/src/codec/sstable.ts"},"region":{"startLine":162}}}],"partialFingerprints":{"codehealthFindingId/v1":"bd1b957812cd8eba554588b0702166fafedb0379f5e3bfa81b73fe6c2a39367b"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function indexedFugueInsertion (cyclomatic 20, cognitive 37): indexedFugueInsertion has cyclomatic complexity 20 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":"loro-js/src/runtime/containers.ts"},"region":{"startLine":3721}}}],"partialFingerprints":{"codehealthFindingId/v1":"5c8175e217eb31b7169abae81140da4cff32f66bbd754c3fdc99df06a0a04442"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function visitVisibleStorageRange (cyclomatic 20, cognitive 36): visitVisibleStorageRange has cyclomatic complexity 20 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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":3770}}}],"partialFingerprints":{"codehealthFindingId/v1":"4652efb4548f500fffcdbba5bcbb14209466f5b0dfc1fb419ed76b68649f52ca"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function #finishSpanAppend (cyclomatic 20, cognitive 27): #finishSpanAppend has cyclomatic complexity 20 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 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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":2237}}}],"partialFingerprints":{"codehealthFindingId/v1":"036ad848df7bdd003f5a92867956ebf7cb7a359ac1727d55ae8d19b67a432d78"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function alignText (cyclomatic 20, cognitive 24): alignText has cyclomatic complexity 20 and cognitive complexity 24; 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":"loro-js/src/runtime/document.ts"},"region":{"startLine":11328}}}],"partialFingerprints":{"codehealthFindingId/v1":"f0261c3a2cc2c841fa8c2b8f524f70822cec1bfb16680020ae5e7505a81936a4"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function #appendToPreviousNodeWithLineBreaks (cyclomatic 20, cognitive 23): #appendToPreviousNodeWithLineBreaks 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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":2143}}}],"partialFingerprints":{"codehealthFindingId/v1":"9c3a3796c2a7a7ac11520a582b25cbd9719b97274645ea108518e9cc8316e418"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function generateEdit (cyclomatic 20, cognitive 13): generateEdit has cyclomatic complexity 20 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":"loro-js/tests/differential/fuzz.ts"},"region":{"startLine":324}}}],"partialFingerprints":{"codehealthFindingId/v1":"877f74885d05e5d4182129259be94a13b2edb2b45b927d73ecee7119743e1d51"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function containerPath (cyclomatic 19, cognitive 33): containerPath has cyclomatic complexity 19 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 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":"loro-js/src/runtime/document.ts"},"region":{"startLine":11461}}}],"partialFingerprints":{"codehealthFindingId/v1":"fe4b9dcdff911cb700c39195e80824874021e996fb5418a8498287ff710a7f64"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function #markLocatedIdSpanVisibility (cyclomatic 19, cognitive 32): #markLocatedIdSpanVisibility has cyclomatic complexity 19 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 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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":1292}}}],"partialFingerprints":{"codehealthFindingId/v1":"9f692e099c1a1d8791a93cbb8f30e6e3d033109364fd084ba37b2bbf8cfc3cbb"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function visitVisibleIdRuns (cyclomatic 19, cognitive 27): visitVisibleIdRuns has cyclomatic complexity 19 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 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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":3469}}}],"partialFingerprints":{"codehealthFindingId/v1":"548ecd4808cdbb3df81dc4acb7c4b5d31575a22d410e179349bf7183c929e010"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function runtimeValuesEqual (cyclomatic 19, cognitive 19): runtimeValuesEqual has cyclomatic complexity 19 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":"loro-js/src/runtime/movable-list.ts"},"region":{"startLine":146}}}],"partialFingerprints":{"codehealthFindingId/v1":"f2aa2ee96fdf3c66809a07608c385d68d7a102b344332a454ef3986495b622f9"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function eventValuesEqual (cyclomatic 19, cognitive 18): eventValuesEqual 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":"loro-js/src/runtime/document.ts"},"region":{"startLine":10924}}}],"partialFingerprints":{"codehealthFindingId/v1":"a246d6488a43eec5d0c0f759279468673c00258c7ca2b7077c5cb46c917d54a1"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function #appendToPreviousNode (cyclomatic 18, cognitive 21): #appendToPreviousNode has cyclomatic complexity 18 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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":2079}}}],"partialFingerprints":{"codehealthFindingId/v1":"db4e0ebb6a7a6c9c00a8c388f8419bd85f58becf68e6eb4577eb85b6dd49ba27"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function runCoordinator (cyclomatic 18, cognitive 20): runCoordinator has cyclomatic complexity 18 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":"crates/loro-wasm/scripts/measure-snapshot-round-memory.cjs"},"region":{"startLine":313}}}],"partialFingerprints":{"codehealthFindingId/v1":"7946f6c7bfbdccd6b8475d9c8cdc79e091bd821de2682922163ea09d5dc4331f"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function _positionFor (cyclomatic 18, cognitive 15): _positionFor has cyclomatic complexity 18 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":"loro-js/src/runtime/containers.ts"},"region":{"startLine":3023}}}],"partialFingerprints":{"codehealthFindingId/v1":"2fb38dff643a5fdc553be1c82a8625fe64bd7472126d00c71890aedd4be42366"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function subtractSequenceIdRuns (cyclomatic 17, cognitive 34): subtractSequenceIdRuns has cyclomatic complexity 17 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 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":"loro-js/src/runtime/document.ts"},"region":{"startLine":10964}}}],"partialFingerprints":{"codehealthFindingId/v1":"f74dae2905ff4f6b7c67318df65f147ef19065bd615aa10fe27b2bc5f9b1a725"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function #applyList (cyclomatic 17, cognitive 34): #applyList has cyclomatic complexity 17 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 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":"loro-js/tests/fuzz/differential.ts"},"region":{"startLine":517}}}],"partialFingerprints":{"codehealthFindingId/v1":"96f8f036e32b21d6d7bfd51de8e999077c70dac00fa9c6ecb699b5b767052e9b"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function canonicalDelta (cyclomatic 17, cognitive 33): canonicalDelta has cyclomatic complexity 17 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 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":"loro-js/tests/differential/harness.ts"},"region":{"startLine":201}}}],"partialFingerprints":{"codehealthFindingId/v1":"adda65b4ae4a977ab723e531eaefcbc56b3228c77ace074974975fc0fb352367"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function tokenizeFilter (cyclomatic 17, cognitive 27): tokenizeFilter has cyclomatic complexity 17 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 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":"loro-js/src/runtime/jsonpath.ts"},"region":{"startLine":620}}}],"partialFingerprints":{"codehealthFindingId/v1":"5776db2ab6e194903d5c77d2b4b7154d2afb5422d2299dd03241ba1f5456984a"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function callFilterFunction (cyclomatic 17, cognitive 27): callFilterFunction has cyclomatic complexity 17 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 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":"loro-js/src/runtime/jsonpath.ts"},"region":{"startLine":799}}}],"partialFingerprints":{"codehealthFindingId/v1":"a23e29b01fcd8603d6cac992da21e7285e8e860d929016229fba84b54a0edd22"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function finish (cyclomatic 17, cognitive 25): finish has cyclomatic complexity 17 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":"loro-js/tests/fuzz/differential.ts"},"region":{"startLine":1277}}}],"partialFingerprints":{"codehealthFindingId/v1":"4a539288bdf61f947ff92d67456fe86e385bf33e0e56b7ee7f6eae146c83ab71"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function #insertOverrides (cyclomatic 16, cognitive 27): #insertOverrides has cyclomatic complexity 16 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 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":"loro-js/src/runtime/containers.ts"},"region":{"startLine":2291}}}],"partialFingerprints":{"codehealthFindingId/v1":"c8d10646f74b95dd8b55403cbf781a02f3db6e8fc1afe03308b02ab709c573c5"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function applyDelta (cyclomatic 15, cognitive 33): applyDelta has cyclomatic complexity 15 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 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":"loro-js/tests/support/richtext-differential.ts"},"region":{"startLine":1047}}}],"partialFingerprints":{"codehealthFindingId/v1":"1710e7a6e0e637569f7f62630e1b40e3432b1bd2024a2a2c533d7df23a470808"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function fugueDescendsFrom (cyclomatic 15, cognitive 27): fugueDescendsFrom has cyclomatic complexity 15 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 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":"loro-js/src/runtime/containers.ts"},"region":{"startLine":3814}}}],"partialFingerprints":{"codehealthFindingId/v1":"4506b41ba86ddaab540b036f490eaacad9ef6d30be2cc0df8e47c6fea8c0277c"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function jsonValueToChangeLoroValue (cyclomatic 15, cognitive 23): jsonValueToChangeLoroValue has cyclomatic complexity 15 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":"loro-js/src/runtime/document.ts"},"region":{"startLine":10439}}}],"partialFingerprints":{"codehealthFindingId/v1":"d5f64ab99946db8e1d40019c0a99ec5b209fdc79905f22caf063a997fd23103d"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function splitTopLevel (cyclomatic 15, cognitive 17): splitTopLevel has cyclomatic complexity 15 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 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":"loro-js/src/runtime/jsonpath.ts"},"region":{"startLine":863}}}],"partialFingerprints":{"codehealthFindingId/v1":"7c4fa39ecd4c067a485a9a26ae08e96c778024e522761d67614a15a72ebd1147"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function markIdRunsDeleted (cyclomatic 15, cognitive 17): markIdRunsDeleted has cyclomatic complexity 15 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 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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":3658}}}],"partialFingerprints":{"codehealthFindingId/v1":"0910916371c8fdf104eab54576b823edc917967d929b447475e09f5b5de0fd80"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function markIdRunsVisible (cyclomatic 15, cognitive 17): markIdRunsVisible has cyclomatic complexity 15 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 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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":3714}}}],"partialFingerprints":{"codehealthFindingId/v1":"cc7aaca94c8d2ddeff4d1fd29017c548776b85c611b50eb304c4dc162d5c39a0"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function valueToEncoded (cyclomatic 15, cognitive 15): valueToEncoded 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":"loro-js/src/runtime/ephemeral.ts"},"region":{"startLine":539}}}],"partialFingerprints":{"codehealthFindingId/v1":"50f4b8b5304714ad1c7d93604ee35d4898f8e6f9a324698c7ed411c37f0f16a3"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function appendToTrailingListInsert (cyclomatic 15, cognitive 11): appendToTrailingListInsert has cyclomatic complexity 15 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":"loro-js/src/runtime/document.ts"},"region":{"startLine":9242}}}],"partialFingerprints":{"codehealthFindingId/v1":"d6f830770f97834a645f29ac31aeb43c0abfd07f2ecea871bffa7fc1fafd871e"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function validateTreeItems (cyclomatic 14, cognitive 33): validateTreeItems has cyclomatic complexity 14 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 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":"loro-js/src/runtime/document.ts"},"region":{"startLine":11160}}}],"partialFingerprints":{"codehealthFindingId/v1":"b1d6a7995c7f3a35e338a364314553a8f6bc924e7558061b75a890c9f80d4eee"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function (anonymous) (cyclomatic 14, cognitive 31): (anonymous) has cyclomatic complexity 14 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":"loro-js/tests/indexes.test.ts"},"region":{"startLine":16}}}],"partialFingerprints":{"codehealthFindingId/v1":"2a2c4b2e7bd874491d0c6613424fba2ea6b455b93c89e324664fe25dc35e46c4"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function visibleIndexOfWidthElement (cyclomatic 14, cognitive 28): visibleIndexOfWidthElement has cyclomatic complexity 14 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 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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":800}}}],"partialFingerprints":{"codehealthFindingId/v1":"55180b17f9bded771791ec7ab88563e8857b4224309d436a20105217a7ca6db1"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function containers (cyclomatic 14, cognitive 26): containers has cyclomatic complexity 14 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":"loro-js/tests/fuzz/differential.ts"},"region":{"startLine":959}}}],"partialFingerprints":{"codehealthFindingId/v1":"722c914b8228dc7e8cf376f304fdfd628d1ffdf00a7fa0d622f01e885daa5e0b"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function #parsePrimary (cyclomatic 14, cognitive 25): #parsePrimary has cyclomatic complexity 14 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":"loro-js/src/runtime/jsonpath.ts"},"region":{"startLine":552}}}],"partialFingerprints":{"codehealthFindingId/v1":"200c5b334c4fb11b7d25c70fbf42ccfcff8a0401ffddca73fac9f83b707e07c6"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function decodeLz4Frame (cyclomatic 14, cognitive 22): decodeLz4Frame has cyclomatic complexity 14 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":"loro-js/src/codec/lz4.ts"},"region":{"startLine":20}}}],"partialFingerprints":{"codehealthFindingId/v1":"fee210ca33bd469255957a92e01f580c56b0023d0c95bc3a536c23e0c105b142"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function findNextIncludedPhysical (cyclomatic 14, cognitive 22): findNextIncludedPhysical has cyclomatic complexity 14 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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":2476}}}],"partialFingerprints":{"codehealthFindingId/v1":"21402480b9ec2adfcdd26950765c38705641c6a98f27f842c91f4ce2e410bc5d"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function encodeChangesHeader (cyclomatic 14, cognitive 20): encodeChangesHeader has cyclomatic complexity 14 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":"loro-js/src/codec/change-block-tables.ts"},"region":{"startLine":181}}}],"partialFingerprints":{"codehealthFindingId/v1":"b6109f36166949f42fb884c14417f1730b3311556c82ab96a23a3ac83b5bf0e5"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function readFilterPath (cyclomatic 14, cognitive 20): readFilterPath has cyclomatic complexity 14 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":"loro-js/src/runtime/jsonpath.ts"},"region":{"startLine":683}}}],"partialFingerprints":{"codehealthFindingId/v1":"ef8e9ba4dd1305e5c3ec9000e2444003eb08c6d366ad97ab3aadacc1a89dc575"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function collectCausalIdRuns (cyclomatic 14, cognitive 14): collectCausalIdRuns has cyclomatic complexity 14 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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":3927}}}],"partialFingerprints":{"codehealthFindingId/v1":"7f1a5fde1fad668af960aab54eb24d5455862563908a422ceada9d70cae715e2"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function applyMove (cyclomatic 14, cognitive 12): applyMove 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":"loro-js/src/runtime/movable-list.ts"},"region":{"startLine":442}}}],"partialFingerprints":{"codehealthFindingId/v1":"fbd1505af459a47c50c92cd5f14761a25570b848c882aaa0275124ebde34450d"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function (anonymous) (cyclomatic 13, cognitive 26): (anonymous) has cyclomatic complexity 13 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":"loro-js/tests/snapshot-checkout.test.ts"},"region":{"startLine":458}}}],"partialFingerprints":{"codehealthFindingId/v1":"c87903bbde3500bc9fe472822f08bb02a19d074c2e0ae9375f515e0ae7d1e205"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function (anonymous) (cyclomatic 13, cognitive 24): (anonymous) has cyclomatic complexity 13 and cognitive complexity 24; 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":"crates/loro-wasm/index.ts"},"region":{"startLine":345}}}],"partialFingerprints":{"codehealthFindingId/v1":"b89467f5689f08fa7640a7d29eac9c52defba7aa1ec94c216a29d2aa98f80a84"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function recoverParentBinding (cyclomatic 13, cognitive 24): recoverParentBinding has cyclomatic complexity 13 and cognitive complexity 24; 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":"loro-js/src/runtime/document.ts"},"region":{"startLine":11419}}}],"partialFingerprints":{"codehealthFindingId/v1":"a159b49db056b4aa2f68e53d5b3171867c96aaf9c288c72ddc7a23094b073a4c"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function zeroWidthBeforeVisibleIndex (cyclomatic 13, cognitive 23): zeroWidthBeforeVisibleIndex has cyclomatic complexity 13 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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":764}}}],"partialFingerprints":{"codehealthFindingId/v1":"afacbfd04dd5fd6fd7589a8dbbe0afb5ee7b64801693f7698cf9a1c97cdb7b4c"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function visibleIndexAfterLineBreaks (cyclomatic 13, cognitive 23): visibleIndexAfterLineBreaks has cyclomatic complexity 13 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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":936}}}],"partialFingerprints":{"codehealthFindingId/v1":"015b54d666795d1fb868c841bf436c9b9fe12d5e085e6dcb89523fb22890ef45"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function replacedRuns (cyclomatic 13, cognitive 23): replacedRuns has cyclomatic complexity 13 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":"loro-js/src/runtime/text-style-index.ts"},"region":{"startLine":183}}}],"partialFingerprints":{"codehealthFindingId/v1":"ea9ad9f30a2810e403e8d7da208c61cbbfea9f2dcd094c654ffcc1a9ac0d1a63"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function sync (cyclomatic 13, cognitive 21): sync has cyclomatic complexity 13 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":"loro-js/tests/fuzz/differential.ts"},"region":{"startLine":1158}}}],"partialFingerprints":{"codehealthFindingId/v1":"44e009a6af6a39bbc2534772cac5366ccc585b362be43de09c35e38bf33f606a"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function canTransition (cyclomatic 13, cognitive 20): canTransition has cyclomatic complexity 13 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":"loro-js/src/runtime/movable-list.ts"},"region":{"startLine":670}}}],"partialFingerprints":{"codehealthFindingId/v1":"ce560e407709d113cf0d1579d0a38ba9d9f2e621a22322ecaf70adc481e6bf13"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function appendTextDelta (cyclomatic 13, cognitive 19): appendTextDelta has cyclomatic complexity 13 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":"loro-js/src/runtime/event-diff.ts"},"region":{"startLine":323}}}],"partialFingerprints":{"codehealthFindingId/v1":"f7ba12a6ae6a7b69559fde1ca64e9a771b4a42799badf31a79244fde8fe31eb3"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function collectJsonPeers (cyclomatic 13, cognitive 17): collectJsonPeers has cyclomatic complexity 13 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 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":"loro-js/src/runtime/document.ts"},"region":{"startLine":9881}}}],"partialFingerprints":{"codehealthFindingId/v1":"a0664d88ed2b3afe6baf4d2a04a2c512355eb25a2336e78f6a048762a8dcce75"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function parseJsonPath (cyclomatic 13, cognitive 16): parseJsonPath 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":"loro-js/src/runtime/jsonpath.ts"},"region":{"startLine":142}}}],"partialFingerprints":{"codehealthFindingId/v1":"66d0bba5583d7b75a4df7c6192e29b99f50d28f0bc02410153c45bdd6e1819ef"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function #wouldCycle (cyclomatic 13, cognitive 16): #wouldCycle 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":"loro-js/src/runtime/tree-moves.ts"},"region":{"startLine":177}}}],"partialFingerprints":{"codehealthFindingId/v1":"75ad07c8b1c613f7b959877b17793cd444cf76884c03fde4f72493ea6e83df46"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function orderedDiff (cyclomatic 13, cognitive 16): orderedDiff 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":"loro-js/tests/differential/fuzz.ts"},"region":{"startLine":837}}}],"partialFingerprints":{"codehealthFindingId/v1":"097496bec3d72509e3df1a727419e553859304b94922909b068d1d4ef2c45095"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function visitPhysicalIdRuns (cyclomatic 13, cognitive 14): visitPhysicalIdRuns 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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":3431}}}],"partialFingerprints":{"codehealthFindingId/v1":"cce7d8140a5e6a5438d74965674ab1e6ff99d7e552658961e1972e41a4306c55"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function sliceOperation (cyclomatic 13, cognitive 9): sliceOperation 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":"loro-js/src/runtime/document.ts"},"region":{"startLine":9485}}}],"partialFingerprints":{"codehealthFindingId/v1":"8d2e66c0b80cff49f28bd95d5228b83aef74c9918257a716fcab6dd0a36eee58"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function readSleb128 (cyclomatic 12, cognitive 24): readSleb128 has cyclomatic complexity 12 and cognitive complexity 24; 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":"loro-js/src/codec/leb128.ts"},"region":{"startLine":56}}}],"partialFingerprints":{"codehealthFindingId/v1":"0fdff905dc25e6648a178e5330424affc4f5e8548f0183b71b126f42022b8381"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function scannedFugueInsertion (cyclomatic 12, cognitive 24): scannedFugueInsertion has cyclomatic complexity 12 and cognitive complexity 24; 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":"loro-js/src/runtime/containers.ts"},"region":{"startLine":3672}}}],"partialFingerprints":{"codehealthFindingId/v1":"996380d3579da3db2ea4760c5c7074b896c4ea682af1308c90b3fd093cb0dd50"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function applyDelta (cyclomatic 12, cognitive 22): applyDelta has cyclomatic complexity 12 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":"loro-js/src/runtime/containers.ts"},"region":{"startLine":1652}}}],"partialFingerprints":{"codehealthFindingId/v1":"d81e38b23be159896679f0ce783c40a230944825a9db4005fb09ac843c5340f8"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function build (cyclomatic 12, cognitive 20): build 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":"crates/loro-wasm/scripts/build.ts"},"region":{"startLine":59}}}],"partialFingerprints":{"codehealthFindingId/v1":"bf12605535dbeedc14851fc8e4fcfd7a5cf49e72becf20e287b2952ab890c580"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function nextVisible (cyclomatic 12, cognitive 20): nextVisible 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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":1530}}}],"partialFingerprints":{"codehealthFindingId/v1":"b9724400e94ad9bfb58539d0a1d2a5f900a9120b384550283c21fbe89a696bfb"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function previousVisible (cyclomatic 12, cognitive 20): previousVisible 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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":1557}}}],"partialFingerprints":{"codehealthFindingId/v1":"aef4e28f2cda6ed0a4bebcdd4d9e1c37694d4824cc1542bbff33e53bc5b2f9f1"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function validateListDelta (cyclomatic 12, cognitive 19): validateListDelta has cyclomatic complexity 12 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":"loro-js/src/runtime/document.ts"},"region":{"startLine":11267}}}],"partialFingerprints":{"codehealthFindingId/v1":"6e13ce181de7af07e6a0e3e3cea339d6813935172bcfdc0da256fc5506372a1b"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function newBetweenBytes (cyclomatic 12, cognitive 18): newBetweenBytes has cyclomatic complexity 12 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":"packages/fractional-index/src/index.ts"},"region":{"startLine":482}}}],"partialFingerprints":{"codehealthFindingId/v1":"cc8858a97837af29e89bb1fee8197a8de81fbcb2c181a80818ba60c4d5e15888"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function recordFugueOriginEntry (cyclomatic 12, cognitive 17): recordFugueOriginEntry has cyclomatic complexity 12 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 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":"loro-js/src/runtime/containers.ts"},"region":{"startLine":3925}}}],"partialFingerprints":{"codehealthFindingId/v1":"1a2c39e89f912a067c6b73c6f605244c926132f098a19394004e95eb153be9f2"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function #compare (cyclomatic 12, cognitive 17): #compare has cyclomatic complexity 12 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 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":"loro-js/tests/support/richtext-differential.ts"},"region":{"startLine":786}}}],"partialFingerprints":{"codehealthFindingId/v1":"df94585aa3dc9a72212cd4ccd7f39af46ff0568ff50d8939768a974510445354"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function get (cyclomatic 12, cognitive 16): get has cyclomatic complexity 12 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":"loro-js/src/codec/sstable.ts"},"region":{"startLine":130}}}],"partialFingerprints":{"codehealthFindingId/v1":"c0b1656ab0723e38e442f18079a518339283c7c4fd8676bd98dad3153237d046"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function hasMaterializedSequenceInsertions (cyclomatic 12, cognitive 16): hasMaterializedSequenceInsertions has cyclomatic complexity 12 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":"loro-js/src/runtime/document.ts"},"region":{"startLine":9140}}}],"partialFingerprints":{"codehealthFindingId/v1":"d1db179b8335a310a9302d5ed365c3811fc5ce703316f7827d6fd3591874b939"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function (anonymous) (cyclomatic 12, cognitive 14): (anonymous) has cyclomatic complexity 12 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":"loro-js/src/runtime/document.ts"},"region":{"startLine":1231}}}],"partialFingerprints":{"codehealthFindingId/v1":"a5e1ab9fcb80e133b2dc9f8d37fe8bcfa085632e1da935cd01095a8bec9d929f"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function apply (cyclomatic 12, cognitive 14): apply has cyclomatic complexity 12 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":"loro-js/src/runtime/ephemeral.ts"},"region":{"startLine":321}}}],"partialFingerprints":{"codehealthFindingId/v1":"de29f951b79b843062a3d0c804189e08f142628401aabd35cb10926c5264b724"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function parseBracketSelector (cyclomatic 12, cognitive 14): parseBracketSelector has cyclomatic complexity 12 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":"loro-js/src/runtime/jsonpath.ts"},"region":{"startLine":210}}}],"partialFingerprints":{"codehealthFindingId/v1":"004c0acec4d98ac49210179e81d2c290dec36bbfe2a40289678ec3525a913dec"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function visitVisibleRange (cyclomatic 12, cognitive 14): visitVisibleRange has cyclomatic complexity 12 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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":3846}}}],"partialFingerprints":{"codehealthFindingId/v1":"e862dc3468daa478e2944a3348157f4e27ef3a398dfa71fab3edb3176bcc1090"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function #inheritGapStyles (cyclomatic 12, cognitive 13): #inheritGapStyles 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":"loro-js/src/runtime/containers.ts"},"region":{"startLine":2400}}}],"partialFingerprints":{"codehealthFindingId/v1":"4bf4dd1370a035d1ad0114768e8e6e42132d3b486db95b5f4b8d339f44b923e6"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function normalizeDetachedValue (cyclomatic 12, cognitive 13): normalizeDetachedValue 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":"loro-js/src/runtime/containers.ts"},"region":{"startLine":3509}}}],"partialFingerprints":{"codehealthFindingId/v1":"f53f4254f1dfc8298ca5398a0642bc496c87c6d2488a91dd6148b0680d30df51"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function #track (cyclomatic 12, cognitive 13): #track 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":"loro-js/src/runtime/movable-list.ts"},"region":{"startLine":888}}}],"partialFingerprints":{"codehealthFindingId/v1":"f6c2e8454e105d195679806ca33938656bdc1e59e3a885d8a94ab456eb3a33c4"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function sliceChange (cyclomatic 12, cognitive 12): sliceChange 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":"loro-js/src/runtime/document.ts"},"region":{"startLine":9431}}}],"partialFingerprints":{"codehealthFindingId/v1":"f655a291f000dbe3f8c5dc53af16ecd8fa7c4d7864b409fcdf1a59865dcc34e5"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function deleteElement (cyclomatic 12, cognitive 12): deleteElement 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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":1211}}}],"partialFingerprints":{"codehealthFindingId/v1":"23750c2913fcb31c5185827eae9ac655cf2f0559f05e51bb6342922b63439880"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function decodeChangesHeader (cyclomatic 12, cognitive 11): decodeChangesHeader 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":"loro-js/src/codec/change-block-tables.ts"},"region":{"startLine":72}}}],"partialFingerprints":{"codehealthFindingId/v1":"547a9c1538b221e951f70d2834532e00d3c2e8c4414dc8bc1a0aee72f1740bde"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function (anonymous) (cyclomatic 11, cognitive 27): (anonymous) has cyclomatic complexity 11 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 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":"loro-js/tests/shallow-root-critical.test.ts"},"region":{"startLine":137}}}],"partialFingerprints":{"codehealthFindingId/v1":"409e750900abbb8d6ce1c8cf3f53c87193e98c992e743a7bcb3dfb5529c16669"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function visibleAtMetricOffset (cyclomatic 11, cognitive 21): visibleAtMetricOffset has cyclomatic complexity 11 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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":898}}}],"partialFingerprints":{"codehealthFindingId/v1":"bd90337aab4c57b28724db4b1fff1168c7f45dc0f84133e5c1b1d0b0bc94f130"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function withoutNoOpSequenceEvents (cyclomatic 11, cognitive 20): withoutNoOpSequenceEvents 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":"loro-js/tests/differential/harness.ts"},"region":{"startLine":540}}}],"partialFingerprints":{"codehealthFindingId/v1":"da46e00d6a308968f0fb8723f9df0510156b852ed6d5cd96c7f2ed6e748cc465"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function encodeBlocks (cyclomatic 11, cognitive 19): encodeBlocks has cyclomatic complexity 11 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":"loro-js/src/codec/sstable.ts"},"region":{"startLine":308}}}],"partialFingerprints":{"codehealthFindingId/v1":"f9fe4bd937327b801aba39259949457835b5322e4ddb13f855566cbe4f7ec366"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function hydrate (cyclomatic 11, cognitive 19): hydrate has cyclomatic complexity 11 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":"loro-js/src/runtime/movable-list.ts"},"region":{"startLine":799}}}],"partialFingerprints":{"codehealthFindingId/v1":"42b8e073103486cc534024e1a31f3971cef5bf9e9cec4c27325daf6be84e1510"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function newBetween (cyclomatic 11, cognitive 17): newBetween has cyclomatic complexity 11 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 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":"loro-js/src/runtime/fractional-index.ts"},"region":{"startLine":88}}}],"partialFingerprints":{"codehealthFindingId/v1":"44fcd3201235049938b41cfd2c25238b9a76ddb9cdebca967c50933945728a57"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function readBracket (cyclomatic 11, cognitive 17): readBracket has cyclomatic complexity 11 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 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":"loro-js/src/runtime/jsonpath.ts"},"region":{"startLine":180}}}],"partialFingerprints":{"codehealthFindingId/v1":"adae31cf0fbcb33d9bdefb099e3d9f2d369e4dc72826cbcaa0c2f777a0690c90"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function minimizeScenario (cyclomatic 11, cognitive 16): minimizeScenario has cyclomatic complexity 11 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":"loro-js/tests/fuzz/differential.ts"},"region":{"startLine":1593}}}],"partialFingerprints":{"codehealthFindingId/v1":"cee192072942802d3b39849893945cfa595aa6a22211cf00d79286844d9bf842"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function #compareImported (cyclomatic 11, cognitive 16): #compareImported has cyclomatic complexity 11 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":"loro-js/tests/support/richtext-differential.ts"},"region":{"startLine":657}}}],"partialFingerprints":{"codehealthFindingId/v1":"eb46601508fe29e7ed6dc4848f6c3bcfc6ad5a75e243dfd20cfb8a94cdb545a6"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function recordedAsDeleted (cyclomatic 11, cognitive 16): recordedAsDeleted has cyclomatic complexity 11 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":"loro-js/tests/support/richtext-differential.ts"},"region":{"startLine":912}}}],"partialFingerprints":{"codehealthFindingId/v1":"cc3e4e50e3c9576c8406d17a56c86af816cf6e5e09d71f39a242368ffff198d2"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function _deleteRuns (cyclomatic 11, cognitive 15): _deleteRuns has cyclomatic complexity 11 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":"loro-js/src/runtime/containers.ts"},"region":{"startLine":2032}}}],"partialFingerprints":{"codehealthFindingId/v1":"0176f5f56e72681c3814276512c9aca69df8567e626910af141995b19e80fe3b"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function #split (cyclomatic 11, cognitive 14): #split 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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":2019}}}],"partialFingerprints":{"codehealthFindingId/v1":"397aba43e3f15e85f3a9db8fe3631fa9f597f55d914f6395a91c0710064ec3ae"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function resolveSource (cyclomatic 11, cognitive 14): resolveSource 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":"scripts/embed-wasm-sourcemap.mjs"},"region":{"startLine":125}}}],"partialFingerprints":{"codehealthFindingId/v1":"dc799c9d7d89ed325b56b278dae7fbc48cf7be5f662311caf5aa5764b66fb255"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function sliceIndexedValues (cyclomatic 11, cognitive 13): sliceIndexedValues 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":"loro-js/src/runtime/jsonpath.ts"},"region":{"startLine":459}}}],"partialFingerprints":{"codehealthFindingId/v1":"148fc53779a743cbdbae9d6123e2f1c1014d5ece7d0b075f6f26e160472c6646"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function #entityFrom (cyclomatic 11, cognitive 12): #entityFrom 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":"loro-js/src/runtime/containers.ts"},"region":{"startLine":2145}}}],"partialFingerprints":{"codehealthFindingId/v1":"9da80e10af066adcb59e3a3295216757977173c122a9856e0b8b242ae51cd2b4"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function visit (cyclomatic 11, cognitive 11): visit 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":"crates/loro-wasm/scripts/measure-snapshot-round-memory.cjs"},"region":{"startLine":44}}}],"partialFingerprints":{"codehealthFindingId/v1":"0a449ccef4092f4aadbaad543631131cafd6e3da22bb92eeacab44f18f8ed888"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function #revertIsUnspecified (cyclomatic 11, cognitive 11): #revertIsUnspecified 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":"loro-js/tests/differential/fuzz.ts"},"region":{"startLine":541}}}],"partialFingerprints":{"codehealthFindingId/v1":"f9ad0a6ae0764669082b8f5a723ab1d053cc69fdaedcdbf7f0c02e99a81c64b1"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function #compareCursors (cyclomatic 11, cognitive 11): #compareCursors 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":"loro-js/tests/support/richtext-differential.ts"},"region":{"startLine":752}}}],"partialFingerprints":{"codehealthFindingId/v1":"ccc5a5d4a931332beb49686170b2438ccaff15f04513e30d829bdb4b72e297d0"}},{"ruleId":"R2","level":"warning","message":{"text":"Complex function applyInsert (cyclomatic 11, cognitive 9): applyInsert 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":"loro-js/src/runtime/movable-list.ts"},"region":{"startLine":348}}}],"partialFingerprints":{"codehealthFindingId/v1":"eea97b1df7a64c486114bf082c8153656bce859984401ffa46498b731567d9aa"}},{"ruleId":"R3","level":"warning","message":{"text":"loro-js/src/runtime/document.ts: 11099 lines of code: loro-js/src/runtime/document.ts has 11099 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":"loro-js/src/runtime/document.ts"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"ccec8d222f2ee9150c263a4748c4c1fc6c28b3acb67f35355c5e70eaec14f08b"}},{"ruleId":"R3","level":"warning","message":{"text":"loro-js/src/runtime/sequence-index.ts: 4095 lines of code: loro-js/src/runtime/sequence-index.ts has 4095 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":"loro-js/src/runtime/sequence-index.ts"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"1fd8f9e10b395493bffe886a5c5498c0ac06a2f76d1f1137063613fb3068d07e"}},{"ruleId":"R3","level":"warning","message":{"text":"loro-js/src/runtime/containers.ts: 3721 lines of code: loro-js/src/runtime/containers.ts has 3721 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":"loro-js/src/runtime/containers.ts"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"d1d44a454613d5b22d8c04860c887021d4d42fdbb884a364b7d41264bf043350"}},{"ruleId":"R3","level":"warning","message":{"text":"loro-js/src/runtime/movable-list.ts: 997 lines of code: loro-js/src/runtime/movable-list.ts has 997 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":"loro-js/src/runtime/movable-list.ts"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"fe5e62e70016f1d83028cd98b9350b487f083397d0ada23dc4dcf8c6a46a0672"}},{"ruleId":"R3","level":"warning","message":{"text":"loro-js/src/codec/state-snapshot.ts: 979 lines of code: loro-js/src/codec/state-snapshot.ts has 979 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":"loro-js/src/codec/state-snapshot.ts"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"8e6b3a9264e6d0b5e63d37607b446938a0e8655c888d230fff78b5339f2784f6"}},{"ruleId":"R3","level":"warning","message":{"text":"loro-js/src/runtime/jsonpath.ts: 859 lines of code: loro-js/src/runtime/jsonpath.ts has 859 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":"loro-js/src/runtime/jsonpath.ts"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"437dbd47dcb5427c00bbf60f369b5fff98524803e6f106a7a7cbd5256488b597"}},{"ruleId":"R3","level":"warning","message":{"text":"loro-js/src/codec/change-block-codec.ts: 797 lines of code: loro-js/src/codec/change-block-codec.ts has 797 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":"loro-js/src/codec/change-block-codec.ts"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"c556d7fd134d9fa0cd367ee4acca82708d3e7c42e024467bae907aabaf593061"}},{"ruleId":"R3","level":"warning","message":{"text":"loro-js/src/codec/serde-columnar.ts: 700 lines of code: loro-js/src/codec/serde-columnar.ts has 700 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":"loro-js/src/codec/serde-columnar.ts"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"459803967e3af52782a312a30842a048ebd7ae080fa33b145a35966cd60a3002"}},{"ruleId":"R3","level":"warning","message":{"text":"loro-js/src/codec/sstable.ts: 553 lines of code: loro-js/src/codec/sstable.ts has 553 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":"loro-js/src/codec/sstable.ts"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"399f6cbf632a26cb9ff6428618f5067c3bb0f189edb79742f46ea466f5b11240"}},{"ruleId":"R3","level":"warning","message":{"text":"loro-js/src/runtime/ephemeral.ts: 529 lines of code: loro-js/src/runtime/ephemeral.ts has 529 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":"loro-js/src/runtime/ephemeral.ts"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"7a54390f2fc9d3367b0ba67c7303d0aaff5187cecd41f03324dca3815672219c"}},{"ruleId":"R3","level":"warning","message":{"text":"packages/fractional-index/src/index.ts: 507 lines of code: packages/fractional-index/src/index.ts has 507 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":"packages/fractional-index/src/index.ts"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"d8eb8b1f8b402611f9887d8892bc1c772137cc465af26b7d3323ccf819fc0d4d"}},{"ruleId":"R3","level":"warning","message":{"text":"loro-js/src/codec/change-value.ts: 469 lines of code: loro-js/src/codec/change-value.ts has 469 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":"loro-js/src/codec/change-value.ts"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"69d99bb1000aad208a59da3741a98a519e84428edf14738f4c465b356db5321c"}},{"ruleId":"R3","level":"warning","message":{"text":"loro-js/src/runtime/text-style-index.ts: 467 lines of code: loro-js/src/runtime/text-style-index.ts has 467 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":"loro-js/src/runtime/text-style-index.ts"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"fe4923c9cca63a89f124aa0e6d1d503e3e00d23cd16e95048f7b976ebb40788b"}},{"ruleId":"R3","level":"warning","message":{"text":"crates/loro-wasm/index.ts: 462 lines of code: crates/loro-wasm/index.ts has 462 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":"crates/loro-wasm/index.ts"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"60996f3152d220a90169cace0b31b7c640c40df242e4947283c84f60ba4a1a03"}},{"ruleId":"R3","level":"warning","message":{"text":"loro-js/src/codec/change-block-tables.ts: 447 lines of code: loro-js/src/codec/change-block-tables.ts 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":"loro-js/src/codec/change-block-tables.ts"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"bf90a6deee81d70ff89cd7e1345e9d41c1b0656628ded4f4821547004d7915e1"}},{"ruleId":"R3","level":"warning","message":{"text":"crates/loro-wasm/scripts/build.ts: 434 lines of code: crates/loro-wasm/scripts/build.ts has 434 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":"crates/loro-wasm/scripts/build.ts"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"82ca00db2e0abc05141669b015928bf88ad17ff2905646fefbbed745e161ad4d"}},{"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":"crates/loro-wasm/scripts/build.ts"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"0ca6e320b21a58e06820662259780fac8a630705cbf0ed64afde02970c201238"}},{"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":"crates/loro-wasm/scripts/measure-snapshot-round-memory.cjs"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"d4965d8e3359fe90607a33ada91b8368615bb99b25e0a99121c1dd2c24ad3c6e"}},{"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":"loro-js/scripts/rewrite-rust-fixture.mjs"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"7d3ed81ca39d03a09ffd173173128762591e1d5d6ba21709969a3c6dd644d095"}},{"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":"crates/loro-wasm/scripts/measure-container-tree.cjs"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"99d30554ee3409f1fb029e61cc064b0655caf2cf8cc5c6a367c7f23ed96dab9f"}},{"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":"crates/loro-wasm/scripts/measure-container-id.cjs"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"0ce2cf631d387da2a513d08b843389a513d6f9bf0a16ed0abc5312536a87cfad"}},{"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":"crates/loro-wasm/scripts/container_id_cache_patch.js"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"7e505b5ab0d6c852d3b69bd57119952f5d2c10377c580aa42786adc6aa121392"}},{"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":"loro-js/scripts/write-legacy-fixtures.mjs"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"4c71f1ed08edd8509c6337dae25a31b150abc8f07581744934cbbb3a5e528768"}},{"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":"loro-js/scripts/write-rust-richtext-fixtures.cjs"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"577bc2fb3c08fe0d750b56042d2414f303c75f4670f85571e73a0620bf1f3110"}},{"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":"crates/loro-internal/scripts/mem.ts"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"06adfac0b7cd9712a1201945fa69e06322399b38f44ac0807ba199d235cd5262"}},{"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":"crates/loro-internal/scripts/fuzz.ts"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"eb15d990e26db6f056328d52379ea37f9b93e7979bf3e0a22bcffe7cf6856d64"}},{"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":"crates/loro-wasm/scripts/nodejs-snippets.cjs"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"8d96afcb51802d82a52c6bde3234750a69a917564d0c509738883d3b20cd2a4f"}},{"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":"crates/loro-wasm/scripts/nodejs_patch.js"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"c1205fc3e035c4f0d49a9b5de93ef92ead4f77466937a98060400ee673b3c6f1"}},{"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":"crates/loro-internal/scripts/run_mem.ts"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"2851d76cf1b0170d82021170a0d1faf52a0e842da4506b281ceff10b58055063"}},{"ruleId":"R7","level":"warning","message":{"text":"Dead file (~116 LoC): no import path from any entry point (63 application, 10 tooling, 115 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":"scripts/run-js-doc-tests.ts"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"48c568c4447c9ddaa3db768a4cef2229a271d87782d0179de483f069b2095097"}},{"ruleId":"R7","level":"warning","message":{"text":"Dead file (~49 LoC): no import path from any entry point (63 application, 10 tooling, 115 test roots considered), but 1 in-repo import(s) from 1 other file(s) do name it (crates/loro-internal/scripts/run_mem.ts) \u2014 every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it"},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/scripts/mem.ts"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"3c673d5327ad9621ceb39e6f0852bdf5335a391e7378e887deca2e573254546f"}},{"ruleId":"R7","level":"warning","message":{"text":"Dead file (~36 LoC): no import path from any entry point (63 application, 10 tooling, 115 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":"crates/loro-internal/scripts/fuzz.ts"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"8576d43e8ae5f549b64c94f445dbdc7a4332830cde8c6c0a465181b460d55895"}},{"ruleId":"R7","level":"warning","message":{"text":"Dead file (~9 LoC): no import path from any entry point (63 application, 10 tooling, 115 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":"crates/loro-internal/scripts/run_mem.ts"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"af7a4ab4e59a6fa2617f3822e3baab6a50cdac1c53bf94dd4de9fa6d6eae70fd"}},{"ruleId":"R7","level":"note","message":{"text":"Unused module-local declaration \u0027decorateAllPrototypeMethods\u0027: This top-level declaration is not exported and its name occurs nowhere else in its module \u2014 not called, read, typed against, re-exported or named by a string. Nothing outside the module can reach a non-exported binding, so this is the whole search: remove it, or use it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-wasm/index.ts"},"region":{"startLine":467}}}],"partialFingerprints":{"codehealthFindingId/v1":"bb83720f67ebce956a83ab5131c07c0c45ac4f99d9fb4fce99766fc1c1637f58"}},{"ruleId":"R7","level":"note","message":{"text":"Unused module-local declaration \u0027showFrontiers\u0027: This top-level declaration is not exported and its name occurs nowhere else in its module \u2014 not called, read, typed against, re-exported or named by a string. Nothing outside the module can reach a non-exported binding, so this is the whole search: remove it, or use it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-wasm/tests/issue.test.ts"},"region":{"startLine":90}}}],"partialFingerprints":{"codehealthFindingId/v1":"0fb677040307a47b1228dda54af025429301fd8db63a0753926bbc96edc732db"}},{"ruleId":"R8","level":"warning","message":{"text":"Unused dependency \u0027@typescript/native-preview\u0027: Declared in loro-js/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":[],"partialFingerprints":{"codehealthFindingId/v1":"b3af7d828aed03b1acc584bdba33bb577cfbe4d9f3d46549c0057d6ab4d44a55"}},{"ruleId":"R8","level":"warning","message":{"text":"Unused dependency \u0027@typescript/native-preview\u0027: Declared in packages/fractional-index/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":[],"partialFingerprints":{"codehealthFindingId/v1":"ba6a8396abea21380c07a8d4d8966fb040bb7a27ec43c9222cc7455dd1456a55"}},{"ruleId":"R9","level":"error","message":{"text":"Import cycle (2 files): loro-js/src/runtime/containers.ts \u2192 loro-js/src/runtime/movable-list.ts \u2192 loro-js/src/runtime/containers.ts"},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"loro-js/src/runtime/containers.ts"},"region":{"startLine":11}}}],"partialFingerprints":{"codehealthFindingId/v1":"eaa893e2ed87a88d46959875d67c6472e022075343b1c21d833a54f264897f4a"}},{"ruleId":"S1","level":"warning","message":{"text":"Weak hash algorithm: MD5/SHA1 is computed here, and both are collision-broken. If this digest protects anything \u2014 a signature, an integrity or tamper check, a credential, or any value an attacker can influence \u2014 that is a real weakness: use SHA-256\u002B (\u0060sha2::Sha256::digest(\u2026)\u0060) for content integrity, or a KDF (bcrypt/Argon2/scrypt) for password storage. If it only derives a non-security identifier (a cache key, an avatar URL, an ETag), collision resistance carries no security consequence here; make that intent explicit instead \u2014 a non-cryptographic hash such as xxhash or murmurhash says it in code \u2014 since the algorithm alone cannot distinguish the two uses. Where a protocol this code does not own fixes the digest (a k-anonymity range query, a legacy signature format), the protocol decides; say so beside the call."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/encoding.rs"},"region":{"startLine":355}}}],"partialFingerprints":{"codehealthFindingId/v1":"93d13efe3d2259208ed752f6b665df3797834476d133d7766a06c130c0f35183"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060!Number.isSafeInteger(counter) || counter \u003C 0 || counter \u003E 0x7fff_ffff\u0060 appears character-identically in 2 files \u2014 loro-js/src/runtime/ids.ts, loro-js/src/runtime/version-vector.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":"loro-js/src/runtime/ids.ts"},"region":{"startLine":162}}}],"partialFingerprints":{"codehealthFindingId/v1":"d3044d2ec6d316006aed23e10b9329904c1ab5b8678494d5a9c6079ac90cf36e"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060!Number.isSafeInteger(index) || index \u003C 0 || index \u003E= length\u0060 appears character-identically in 2 files \u2014 loro-js/src/runtime/containers.ts, loro-js/src/runtime/sequence-index.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":"loro-js/src/runtime/containers.ts"},"region":{"startLine":4018}}}],"partialFingerprints":{"codehealthFindingId/v1":"d1be98afb7aa66d31d75bade71d162f652051a78cae6d66b62c9acecbe525476"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060!Number.isSafeInteger(length) || length \u003C 0\u0060 appears character-identically in 2 files \u2014 loro-js/src/codec/bytes.ts, loro-js/src/codec/lz4.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":"loro-js/src/codec/bytes.ts"},"region":{"startLine":104}}}],"partialFingerprints":{"codehealthFindingId/v1":"36e9716106f25db1b77b4fd9a119d86ea492137d0939b9031ab94eecb03ccde8"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060!Number.isSafeInteger(position) || position \u003C 0 || position \u003E this.length\u0060 appears character-identically in 2 files \u2014 loro-js/src/runtime/containers.ts, loro-js/src/runtime/event-diff.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":"loro-js/src/runtime/containers.ts"},"region":{"startLine":567}}}],"partialFingerprints":{"codehealthFindingId/v1":"5355cfafbd074abf8a67ac89669d6ec26206f8779ddae4f6f2fe4bd06ac4e991"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060!Number.isSafeInteger(value) || value \u003C -0x8000_0000 || value \u003E 0x7fff_ffff\u0060 appears character-identically in 4 files \u2014 loro-js/src/codec/change-block-codec.ts, loro-js/src/codec/change-value.ts, loro-js/src/codec/postcard.ts, loro-js/src/codec/serde-columnar.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":"loro-js/src/codec/change-block-codec.ts"},"region":{"startLine":784}}}],"partialFingerprints":{"codehealthFindingId/v1":"4f1f985ae0903d49153a056d932b7242f360ba74899b19d66c7d6fa7470e9f8c"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060!Number.isSafeInteger(value) || value \u003C 0 || value \u003E 0x7fff_ffff\u0060 appears character-identically in 2 files \u2014 loro-js/src/codec/change-block-codec.ts, loro-js/src/codec/change-value.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":"loro-js/src/codec/change-block-codec.ts"},"region":{"startLine":763}}}],"partialFingerprints":{"codehealthFindingId/v1":"450d29a263bd4c4a8c3a7442f6b72d95a7787dbba356627020e7a0eb5829dafa"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060!Number.isSafeInteger(value) || value \u003C 0 || value \u003E max\u0060 appears character-identically in 2 files \u2014 loro-js/src/codec/bytes.ts, loro-js/src/codec/postcard.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":"loro-js/src/codec/bytes.ts"},"region":{"startLine":206}}}],"partialFingerprints":{"codehealthFindingId/v1":"acc130f51f7610e0b7fd847d4a2b44821e666f71056a6bd05a73ecf5edc2d800"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060Array.isArray(left) \u0026\u0026 Array.isArray(right)\u0060 appears character-identically in 2 files \u2014 loro-js/src/runtime/containers.ts, loro-js/src/runtime/document.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":"loro-js/src/runtime/containers.ts"},"region":{"startLine":2500}}}],"partialFingerprints":{"codehealthFindingId/v1":"b0ed2c7910c6552943b6485071a4db74b9434e5503e283653d0bec104202e601"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060content.type === \u0022insert\u0022 \u0026\u0026 typeof content.text === \u0022string\u0022\u0060 appears character-identically in 2 files \u2014 loro-js/src/runtime/document.ts, loro-js/src/runtime/json-updates.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":"loro-js/src/runtime/document.ts"},"region":{"startLine":10249}}}],"partialFingerprints":{"codehealthFindingId/v1":"893a7c89401466b0f62578827223f7ffe301ea972b9e6377a8b0c5ac03ba866e"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060left === undefined || right === undefined\u0060 appears character-identically in 4 files \u2014 loro-js/src/runtime/containers.ts, loro-js/src/runtime/document.ts, loro-js/src/runtime/event-diff.ts, loro-js/src/runtime/sequence-index.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":"loro-js/src/runtime/containers.ts"},"region":{"startLine":2412}}}],"partialFingerprints":{"codehealthFindingId/v1":"9cc6b946ff6e10dc5b7328ddefdd64f9ff62cc98a9369499d624bf9928fa8499"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060left instanceof Uint8Array \u0026\u0026 right instanceof Uint8Array\u0060 appears character-identically in 2 files \u2014 loro-js/src/runtime/containers.ts, loro-js/src/runtime/document.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":"loro-js/src/runtime/containers.ts"},"region":{"startLine":2495}}}],"partialFingerprints":{"codehealthFindingId/v1":"4e76e15334e91d6a45c039a3ab1f15909c46bcd128ac4eccd63a3aafe04dc958"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060left instanceof Uint8Array || right instanceof Uint8Array\u0060 appears character-identically in 2 files \u2014 loro-js/src/runtime/document.ts, loro-js/src/runtime/movable-list.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":"loro-js/src/runtime/document.ts"},"region":{"startLine":11315}}}],"partialFingerprints":{"codehealthFindingId/v1":"eedf58c8fb7d9bc03e124335fce05d824fcfb15af098f3c932749d57fbffc0f9"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060left.peer === right.peer \u0026\u0026 left.counter === right.counter\u0060 appears character-identically in 3 files \u2014 loro-js/src/codec/change-block-codec.ts, loro-js/src/runtime/containers.ts, loro-js/src/runtime/ids.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":"loro-js/src/codec/change-block-codec.ts"},"region":{"startLine":791}}}],"partialFingerprints":{"codehealthFindingId/v1":"f2ec1b643fa562fb9d94dac1b80b593d279c15de4a846c38be9d226e56a40bed"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060name != null \u0026\u0026 /^[A-Za-z_$][\\w$]*$/.test(name)\u0060 appears character-identically in 2 files \u2014 crates/loro-wasm/scripts/build.ts, crates/loro-wasm/scripts/post-rollup.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":"crates/loro-wasm/scripts/build.ts"},"region":{"startLine":342}}}],"partialFingerprints":{"codehealthFindingId/v1":"d8036340de133f55ffbd96449055046b76148b95827d66fb96daa8233c14ba69"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060previous !== undefined \u0026\u0026 previous.start.peer === run.start.peer \u0026\u0026 run.start.counter \u003C= previous.start.counter \u002B previous.length\u0060 appears character-identically in 3 files \u2014 loro-js/src/runtime/sequence-deletion-index.ts, loro-js/src/runtime/sequence-index.ts, loro-js/src/runtime/text-style-index.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":"loro-js/src/runtime/sequence-deletion-index.ts"},"region":{"startLine":250}}}],"partialFingerprints":{"codehealthFindingId/v1":"8599c3da294bda14bf509bb16e894d8fd26f06984b545f71c3449d5913b905b4"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060previous !== undefined \u0026\u0026 range.start \u003C= previous.end\u0060 appears character-identically in 2 files \u2014 loro-js/src/runtime/document.ts, loro-js/src/runtime/sequence-index.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":"loro-js/src/runtime/document.ts"},"region":{"startLine":7351}}}],"partialFingerprints":{"codehealthFindingId/v1":"3ff54ca275ffee2d6446aa3ec7abbc8febc69cad3c37851341921e79ec2f182e"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060previous === undefined || counter \u003E= previous.end\u0060 appears character-identically in 2 files \u2014 loro-js/src/runtime/sequence-deletion-index.ts, loro-js/src/runtime/text-style-index.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":"loro-js/src/runtime/sequence-deletion-index.ts"},"region":{"startLine":203}}}],"partialFingerprints":{"codehealthFindingId/v1":"4d91f9aea03f190eba6838d28332da2d1111ddb7874564a3387e78e8693310b2"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060typeof left === \u0022object\u0022 \u0026\u0026 left !== null \u0026\u0026 typeof right === \u0022object\u0022 \u0026\u0026 right !== null\u0060 appears character-identically in 2 files \u2014 loro-js/src/runtime/document.ts, loro-js/src/runtime/movable-list.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":"loro-js/src/runtime/document.ts"},"region":{"startLine":10947}}}],"partialFingerprints":{"codehealthFindingId/v1":"6d239d692f0846e75e4d31812f572a5750c206761d9e79b7545d6b68add6cb08"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060typeof value !== \u0022number\u0022 || !Number.isSafeInteger(value) || value \u003C 0\u0060 appears character-identically in 2 files \u2014 loro-js/src/runtime/document.ts, packages/fractional-index/src/index.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":"loro-js/src/runtime/document.ts"},"region":{"startLine":11273}}}],"partialFingerprints":{"codehealthFindingId/v1":"a936b36e3497192839a847ffaeefc3035942552623155b8e99b50ebf5e4961d9"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060typeof value === \u0022object\u0022 \u0026\u0026 value !== null\u0060 appears character-identically in 4 files \u2014 loro-js/src/runtime/containers.ts, loro-js/src/runtime/document.ts, loro-js/src/runtime/json-updates.ts, loro-js/src/runtime/jsonpath.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":"loro-js/src/runtime/containers.ts"},"region":{"startLine":3429}}}],"partialFingerprints":{"codehealthFindingId/v1":"ccc3243143f473cc58e56e9c2ce23f7ab85f4c5ec4edd4802c090760109daf45"}},{"ruleId":"X4","level":"note","message":{"text":"Interpolated log message defeats structured logging: \u0060info!\u0060 at line 531 is handed a format string with \u0060{\u2026}\u0060 values in it, so tracing records one finished \u0060message\u0060 field \u2014 the values in it cannot be queried, filtered or aggregated as fields, and every occurrence reads as a different message. Record the values as fields beside a constant message instead: \u0060info!(order_id = %order_id, status = ?status, \u0022order status updated\u0022)\u0060 (\u0060%\u0060 records a value by its \u0060Display\u0060, \u0060?\u0060 by its \u0060Debug\u0060, a bare name as itself), which a JSON subscriber, OpenTelemetry or a log store keeps as queryable keys. An error goes in as a field too: \u0060error = %err\u0060."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/arena.rs"},"region":{"startLine":531}}}],"partialFingerprints":{"codehealthFindingId/v1":"b6b8738ee5e90ff23c4d52cf9b9291e4a57f0995a724bd486120b651cb70f616"}},{"ruleId":"X4","level":"note","message":{"text":"Interpolated log message defeats structured logging: \u0060info!\u0060 at line 544 is handed a format string with \u0060{\u2026}\u0060 values in it, so tracing records one finished \u0060message\u0060 field \u2014 the values in it cannot be queried, filtered or aggregated as fields, and every occurrence reads as a different message. Record the values as fields beside a constant message instead: \u0060info!(order_id = %order_id, status = ?status, \u0022order status updated\u0022)\u0060 (\u0060%\u0060 records a value by its \u0060Display\u0060, \u0060?\u0060 by its \u0060Debug\u0060, a bare name as itself), which a JSON subscriber, OpenTelemetry or a log store keeps as queryable keys. An error goes in as a field too: \u0060error = %err\u0060."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/arena.rs"},"region":{"startLine":544}}}],"partialFingerprints":{"codehealthFindingId/v1":"a20b37cd128fbed206b79952eebf902297dc8a21c4db1dfba9ccccf85b6abf16"}},{"ruleId":"X4","level":"note","message":{"text":"Interpolated log message defeats structured logging: \u0060info!\u0060 at line 551 is handed a format string with \u0060{\u2026}\u0060 values in it, so tracing records one finished \u0060message\u0060 field \u2014 the values in it cannot be queried, filtered or aggregated as fields, and every occurrence reads as a different message. Record the values as fields beside a constant message instead: \u0060info!(order_id = %order_id, status = ?status, \u0022order status updated\u0022)\u0060 (\u0060%\u0060 records a value by its \u0060Display\u0060, \u0060?\u0060 by its \u0060Debug\u0060, a bare name as itself), which a JSON subscriber, OpenTelemetry or a log store keeps as queryable keys. An error goes in as a field too: \u0060error = %err\u0060."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/arena.rs"},"region":{"startLine":551}}}],"partialFingerprints":{"codehealthFindingId/v1":"be7de357136acf11d7db2a4bef1f0aad7e503b0b8702a12a4cf6728c4b16d256"}},{"ruleId":"X4","level":"note","message":{"text":"Interpolated log message defeats structured logging: \u0060error!\u0060 at line 2380 is handed a format string with \u0060{\u2026}\u0060 values in it, so tracing records one finished \u0060message\u0060 field \u2014 the values in it cannot be queried, filtered or aggregated as fields, and every occurrence reads as a different message. Record the values as fields beside a constant message instead: \u0060error!(order_id = %order_id, status = ?status, \u0022order status updated\u0022)\u0060 (\u0060%\u0060 records a value by its \u0060Display\u0060, \u0060?\u0060 by its \u0060Debug\u0060, a bare name as itself), which a JSON subscriber, OpenTelemetry or a log store keeps as queryable keys. An error goes in as a field too: \u0060error = %err\u0060."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/handler.rs"},"region":{"startLine":2380}}}],"partialFingerprints":{"codehealthFindingId/v1":"3ec5870e3a892db81da32175e0fd18d6b022651efb79ed318d57e4de8c53411c"}},{"ruleId":"X4","level":"note","message":{"text":"Interpolated log message defeats structured logging: \u0060error!\u0060 at line 3763 is handed a format string with \u0060{\u2026}\u0060 values in it, so tracing records one finished \u0060message\u0060 field \u2014 the values in it cannot be queried, filtered or aggregated as fields, and every occurrence reads as a different message. Record the values as fields beside a constant message instead: \u0060error!(order_id = %order_id, status = ?status, \u0022order status updated\u0022)\u0060 (\u0060%\u0060 records a value by its \u0060Display\u0060, \u0060?\u0060 by its \u0060Debug\u0060, a bare name as itself), which a JSON subscriber, OpenTelemetry or a log store keeps as queryable keys. An error goes in as a field too: \u0060error = %err\u0060."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/loro.rs"},"region":{"startLine":3763}}}],"partialFingerprints":{"codehealthFindingId/v1":"61d8fda1645791b52ceff22953f2382a1b14bc14b264d265c3ef91ad7f0a6ae3"}},{"ruleId":"X4","level":"note","message":{"text":"Interpolated log message defeats structured logging: \u0060warn!\u0060 at line 4580 is handed a format string with \u0060{\u2026}\u0060 values in it, so tracing records one finished \u0060message\u0060 field \u2014 the values in it cannot be queried, filtered or aggregated as fields, and every occurrence reads as a different message. Record the values as fields beside a constant message instead: \u0060warn!(order_id = %order_id, status = ?status, \u0022order status updated\u0022)\u0060 (\u0060%\u0060 records a value by its \u0060Display\u0060, \u0060?\u0060 by its \u0060Debug\u0060, a bare name as itself), which a JSON subscriber, OpenTelemetry or a log store keeps as queryable keys. An error goes in as a field too: \u0060error = %err\u0060."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/loro.rs"},"region":{"startLine":4580}}}],"partialFingerprints":{"codehealthFindingId/v1":"a5bfdc4934d1586ab329dd53ba58397902b7d6ef9e5b918ac411f96423a92abb"}},{"ruleId":"X4","level":"note","message":{"text":"Interpolated log message defeats structured logging: \u0060warn!\u0060 at line 758 is handed a format string with \u0060{\u2026}\u0060 values in it, so tracing records one finished \u0060message\u0060 field \u2014 the values in it cannot be queried, filtered or aggregated as fields, and every occurrence reads as a different message. Record the values as fields beside a constant message instead: \u0060warn!(order_id = %order_id, status = ?status, \u0022order status updated\u0022)\u0060 (\u0060%\u0060 records a value by its \u0060Display\u0060, \u0060?\u0060 by its \u0060Debug\u0060, a bare name as itself), which a JSON subscriber, OpenTelemetry or a log store keeps as queryable keys. An error goes in as a field too: \u0060error = %err\u0060."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/state.rs"},"region":{"startLine":758}}}],"partialFingerprints":{"codehealthFindingId/v1":"3b5c2b83671c149368f126191ab7b7f83f378f2cfed8bc664253dc8a7ddb7bf7"}},{"ruleId":"X4","level":"note","message":{"text":"Interpolated log message defeats structured logging: \u0060error!\u0060 at line 369 is handed a format string with \u0060{\u2026}\u0060 values in it, so tracing records one finished \u0060message\u0060 field \u2014 the values in it cannot be queried, filtered or aggregated as fields, and every occurrence reads as a different message. Record the values as fields beside a constant message instead: \u0060error!(order_id = %order_id, status = ?status, \u0022order status updated\u0022)\u0060 (\u0060%\u0060 records a value by its \u0060Display\u0060, \u0060?\u0060 by its \u0060Debug\u0060, a bare name as itself), which a JSON subscriber, OpenTelemetry or a log store keeps as queryable keys. An error goes in as a field too: \u0060error = %err\u0060."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/state/movable_list_state.rs"},"region":{"startLine":369}}}],"partialFingerprints":{"codehealthFindingId/v1":"9defc321049d76d124256ed9791df9ff43cc8375082ba4485929b5840fc7f205"}},{"ruleId":"X4","level":"note","message":{"text":"Interpolated log message defeats structured logging: \u0060error!\u0060 at line 374 is handed a format string with \u0060{\u2026}\u0060 values in it, so tracing records one finished \u0060message\u0060 field \u2014 the values in it cannot be queried, filtered or aggregated as fields, and every occurrence reads as a different message. Record the values as fields beside a constant message instead: \u0060error!(order_id = %order_id, status = ?status, \u0022order status updated\u0022)\u0060 (\u0060%\u0060 records a value by its \u0060Display\u0060, \u0060?\u0060 by its \u0060Debug\u0060, a bare name as itself), which a JSON subscriber, OpenTelemetry or a log store keeps as queryable keys. An error goes in as a field too: \u0060error = %err\u0060."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/state/movable_list_state.rs"},"region":{"startLine":374}}}],"partialFingerprints":{"codehealthFindingId/v1":"659cd93da3c352a93011b526d1f41c31590a188ae78497d819e66918790de9fe"}},{"ruleId":"X4","level":"note","message":{"text":"Interpolated log message defeats structured logging: \u0060info!\u0060 at line 125 is handed a format string with \u0060{\u2026}\u0060 values in it, so tracing records one finished \u0060message\u0060 field \u2014 the values in it cannot be queried, filtered or aggregated as fields, and every occurrence reads as a different message. Record the values as fields beside a constant message instead: \u0060info!(order_id = %order_id, status = ?status, \u0022order status updated\u0022)\u0060 (\u0060%\u0060 records a value by its \u0060Display\u0060, \u0060?\u0060 by its \u0060Debug\u0060, a bare name as itself), which a JSON subscriber, OpenTelemetry or a log store keeps as queryable keys. An error goes in as a field too: \u0060error = %err\u0060."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/oplog/change_store/block_encode.rs"},"region":{"startLine":125}}}],"partialFingerprints":{"codehealthFindingId/v1":"11d444de6b44d2a7d47158ee502b2b4a82c2a5fa167964bf92ad05cd92d82820"}},{"ruleId":"X4","level":"note","message":{"text":"Interpolated log message defeats structured logging: \u0060info!\u0060 at line 126 is handed a format string with \u0060{\u2026}\u0060 values in it, so tracing records one finished \u0060message\u0060 field \u2014 the values in it cannot be queried, filtered or aggregated as fields, and every occurrence reads as a different message. Record the values as fields beside a constant message instead: \u0060info!(order_id = %order_id, status = ?status, \u0022order status updated\u0022)\u0060 (\u0060%\u0060 records a value by its \u0060Display\u0060, \u0060?\u0060 by its \u0060Debug\u0060, a bare name as itself), which a JSON subscriber, OpenTelemetry or a log store keeps as queryable keys. An error goes in as a field too: \u0060error = %err\u0060."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/oplog/change_store/block_encode.rs"},"region":{"startLine":126}}}],"partialFingerprints":{"codehealthFindingId/v1":"52be48bb6e51585060d2856776e0dac9fe33a4e3f3cabf893fd9275ff93f8d27"}},{"ruleId":"X4","level":"note","message":{"text":"Interpolated log message defeats structured logging: \u0060info!\u0060 at line 127 is handed a format string with \u0060{\u2026}\u0060 values in it, so tracing records one finished \u0060message\u0060 field \u2014 the values in it cannot be queried, filtered or aggregated as fields, and every occurrence reads as a different message. Record the values as fields beside a constant message instead: \u0060info!(order_id = %order_id, status = ?status, \u0022order status updated\u0022)\u0060 (\u0060%\u0060 records a value by its \u0060Display\u0060, \u0060?\u0060 by its \u0060Debug\u0060, a bare name as itself), which a JSON subscriber, OpenTelemetry or a log store keeps as queryable keys. An error goes in as a field too: \u0060error = %err\u0060."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/oplog/change_store/block_encode.rs"},"region":{"startLine":127}}}],"partialFingerprints":{"codehealthFindingId/v1":"9b737f791db565493f2789f419cf931a30bc691f439a347be29a22515f5c82d0"}},{"ruleId":"X4","level":"note","message":{"text":"Interpolated log message defeats structured logging: \u0060info!\u0060 at line 128 is handed a format string with \u0060{\u2026}\u0060 values in it, so tracing records one finished \u0060message\u0060 field \u2014 the values in it cannot be queried, filtered or aggregated as fields, and every occurrence reads as a different message. Record the values as fields beside a constant message instead: \u0060info!(order_id = %order_id, status = ?status, \u0022order status updated\u0022)\u0060 (\u0060%\u0060 records a value by its \u0060Display\u0060, \u0060?\u0060 by its \u0060Debug\u0060, a bare name as itself), which a JSON subscriber, OpenTelemetry or a log store keeps as queryable keys. An error goes in as a field too: \u0060error = %err\u0060."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/oplog/change_store/block_encode.rs"},"region":{"startLine":128}}}],"partialFingerprints":{"codehealthFindingId/v1":"aaebbcf58f023c2ebad7b12f57c96fcd4242e93b7b1c5cf8a71646de1e2847c5"}},{"ruleId":"X4","level":"note","message":{"text":"Interpolated log message defeats structured logging: \u0060info!\u0060 at line 129 is handed a format string with \u0060{\u2026}\u0060 values in it, so tracing records one finished \u0060message\u0060 field \u2014 the values in it cannot be queried, filtered or aggregated as fields, and every occurrence reads as a different message. Record the values as fields beside a constant message instead: \u0060info!(order_id = %order_id, status = ?status, \u0022order status updated\u0022)\u0060 (\u0060%\u0060 records a value by its \u0060Display\u0060, \u0060?\u0060 by its \u0060Debug\u0060, a bare name as itself), which a JSON subscriber, OpenTelemetry or a log store keeps as queryable keys. An error goes in as a field too: \u0060error = %err\u0060."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/oplog/change_store/block_encode.rs"},"region":{"startLine":129}}}],"partialFingerprints":{"codehealthFindingId/v1":"8552fc40d85b7108cbc0230cf362e5349fb756a6a36dbef92879afcdd3397bb9"}},{"ruleId":"X4","level":"note","message":{"text":"Interpolated log message defeats structured logging: \u0060info!\u0060 at line 130 is handed a format string with \u0060{\u2026}\u0060 values in it, so tracing records one finished \u0060message\u0060 field \u2014 the values in it cannot be queried, filtered or aggregated as fields, and every occurrence reads as a different message. Record the values as fields beside a constant message instead: \u0060info!(order_id = %order_id, status = ?status, \u0022order status updated\u0022)\u0060 (\u0060%\u0060 records a value by its \u0060Display\u0060, \u0060?\u0060 by its \u0060Debug\u0060, a bare name as itself), which a JSON subscriber, OpenTelemetry or a log store keeps as queryable keys. An error goes in as a field too: \u0060error = %err\u0060."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/oplog/change_store/block_encode.rs"},"region":{"startLine":130}}}],"partialFingerprints":{"codehealthFindingId/v1":"594be6e97205396218f89232562193178077b38b6e62ba18a7f926514d420a73"}},{"ruleId":"X4","level":"note","message":{"text":"Interpolated log message defeats structured logging: \u0060info!\u0060 at line 131 is handed a format string with \u0060{\u2026}\u0060 values in it, so tracing records one finished \u0060message\u0060 field \u2014 the values in it cannot be queried, filtered or aggregated as fields, and every occurrence reads as a different message. Record the values as fields beside a constant message instead: \u0060info!(order_id = %order_id, status = ?status, \u0022order status updated\u0022)\u0060 (\u0060%\u0060 records a value by its \u0060Display\u0060, \u0060?\u0060 by its \u0060Debug\u0060, a bare name as itself), which a JSON subscriber, OpenTelemetry or a log store keeps as queryable keys. An error goes in as a field too: \u0060error = %err\u0060."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/oplog/change_store/block_encode.rs"},"region":{"startLine":131}}}],"partialFingerprints":{"codehealthFindingId/v1":"d249ce1b24f4957704f77da2e3ce43d909f527a7d013e00afcb4af2eff00c80f"}},{"ruleId":"X4","level":"note","message":{"text":"Interpolated log message defeats structured logging: \u0060info!\u0060 at line 132 is handed a format string with \u0060{\u2026}\u0060 values in it, so tracing records one finished \u0060message\u0060 field \u2014 the values in it cannot be queried, filtered or aggregated as fields, and every occurrence reads as a different message. Record the values as fields beside a constant message instead: \u0060info!(order_id = %order_id, status = ?status, \u0022order status updated\u0022)\u0060 (\u0060%\u0060 records a value by its \u0060Display\u0060, \u0060?\u0060 by its \u0060Debug\u0060, a bare name as itself), which a JSON subscriber, OpenTelemetry or a log store keeps as queryable keys. An error goes in as a field too: \u0060error = %err\u0060."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro-internal/src/oplog/change_store/block_encode.rs"},"region":{"startLine":132}}}],"partialFingerprints":{"codehealthFindingId/v1":"21264f9f1177828f385d9914f625aa7ae1111a1f837018d6cc4f9dab49248aa5"}},{"ruleId":"X4","level":"note","message":{"text":"Interpolated log message defeats structured logging: \u0060info!\u0060 at line 3947 is handed a format string with \u0060{\u2026}\u0060 values in it, so tracing records one finished \u0060message\u0060 field \u2014 the values in it cannot be queried, filtered or aggregated as fields, and every occurrence reads as a different message. Record the values as fields beside a constant message instead: \u0060info!(order_id = %order_id, status = ?status, \u0022order status updated\u0022)\u0060 (\u0060%\u0060 records a value by its \u0060Display\u0060, \u0060?\u0060 by its \u0060Debug\u0060, a bare name as itself), which a JSON subscriber, OpenTelemetry or a log store keeps as queryable keys. An error goes in as a field too: \u0060error = %err\u0060."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"crates/loro/src/lib.rs"},"region":{"startLine":3947}}}],"partialFingerprints":{"codehealthFindingId/v1":"b3d3ef60e7239385c1c7d77ed021dc74c7e8a4e4d5e97adb8ef201cd1f42f87e"}},{"ruleId":"X5","level":"note","message":{"text":"Null assertions (\u0060!\u0060) override strict null checking: ~16.5 \u0060!\u0060 null assertions per 1k TypeScript source lines \u2014 565 assertion(s) across the 34145 source line(s) of the 49 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: loro-js/src/runtime/document.ts (168), loro-js/src/runtime/sequence-index.ts (81), loro-js/src/runtime/containers.ts (63). 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"}}],"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-1104","guid":"4c918cb5-b2a6-6c55-9963-a44ee464305e","name":"Use of Unmaintained Third Party Components","shortDescription":{"text":"Use of Unmaintained Third Party Components"},"helpUri":"https://cwe.mitre.org/data/definitions/1104.html"},{"id":"CWE-1164","guid":"793ece19-b164-f952-a8b3-33dc3b591809","name":"CWE-1164","shortDescription":{"text":"CWE-1164"},"helpUri":"https://cwe.mitre.org/data/definitions/1164.html"},{"id":"CWE-1329","guid":"f70f1c3f-4ccf-cb5e-bdd3-03ba4868d36d","name":"Reliance on Component That is Not Updateable","shortDescription":{"text":"Reliance on Component That is Not Updateable"},"helpUri":"https://cwe.mitre.org/data/definitions/1329.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-209","guid":"da28ecd2-f5c1-7852-ac41-a93b2d668c73","name":"Generation of Error Message Containing Sensitive Information","shortDescription":{"text":"Generation of Error Message Containing Sensitive Information"},"helpUri":"https://cwe.mitre.org/data/definitions/209.html"},{"id":"CWE-214","guid":"b10ad120-fb22-1351-9348-aa23b453e815","name":"CWE-214","shortDescription":{"text":"CWE-214"},"helpUri":"https://cwe.mitre.org/data/definitions/214.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-353","guid":"09d7e902-d4ee-f05d-ae6c-0a1554d0c18f","name":"Missing Support for Integrity Check","shortDescription":{"text":"Missing Support for Integrity Check"},"helpUri":"https://cwe.mitre.org/data/definitions/353.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-522","guid":"71fb233e-ce6a-ae57-9419-ef8373540b09","name":"Insufficiently Protected Credentials","shortDescription":{"text":"Insufficiently Protected Credentials"},"helpUri":"https://cwe.mitre.org/data/definitions/522.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-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-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":"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":"A05:2025","guid":"87e86033-3231-8458-8e4a-5cb82743553a","name":"Injection","shortDescription":{"text":"Injection"},"helpUri":"https://top10.owasp.org/2025/A05_2025-Injection/"},{"id":"A06:2025","guid":"491554d7-b8e4-9652-91a9-53700dc92ece","name":"Insecure Design","shortDescription":{"text":"Insecure Design"},"helpUri":"https://top10.owasp.org/2025/A06_2025-Insecure_Design/"},{"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/"},{"id":"A10:2025","guid":"9ca3ab55-ca61-fd5e-b9ab-3dad2efa59d0","name":"Mishandling of Exceptional Conditions","shortDescription":{"text":"Mishandling of Exceptional Conditions"},"helpUri":"https://top10.owasp.org/2025/A10_2025-Mishandling_of_Exceptional_Conditions/"}]},{"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-3","guid":"458c83a6-ebf7-cf55-8cc3-b4d949bbf271","name":"Dependency Chain Abuse","shortDescription":{"text":"Dependency Chain Abuse"},"helpUri":"https://owasp.github.io/www-project-top-10-ci-cd-security-risks/CICD-SEC-03-Dependency-Chain-Abuse"},{"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-5","guid":"cc7f4610-8859-e654-9029-d5f97d992220","name":"Insufficient PBAC (Pipeline-Based Access Controls)","shortDescription":{"text":"Insufficient PBAC (Pipeline-Based Access Controls)"},"helpUri":"https://owasp.github.io/www-project-top-10-ci-cd-security-risks/CICD-SEC-05-Insufficient-PBAC"},{"id":"CICD-SEC-6","guid":"f2ee2486-b260-2952-a41f-6b67fa713940","name":"Insufficient Credential Hygiene","shortDescription":{"text":"Insufficient Credential Hygiene"},"helpUri":"https://owasp.github.io/www-project-top-10-ci-cd-security-risks/CICD-SEC-06-Insufficient-Credential-Hygiene"},{"id":"CICD-SEC-8","guid":"b6b2dacf-a168-4957-876e-a8c73ee00eb0","name":"Ungoverned Usage of 3rd Party Services","shortDescription":{"text":"Ungoverned Usage of 3rd Party Services"},"helpUri":"https://owasp.github.io/www-project-top-10-ci-cd-security-risks/CICD-SEC-08-Ungoverned-Usage-of-3rd-Party-Services"},{"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":163,"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."]}]}