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

Untru/ibcmd-rs

Measured 16 November 2026, 18:20 UTC, at code version 54b796f

First survey, so nothing to compare with yet
CAI score 48.0out of 100 Weak
CriticalWeakAdequateStrongExemplary

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

A very large codebase: 695,441 lines of product code in 39 projects, tests not counted · Estimated rebuild effort: about 5.0 person-years · Weakest lens: Security and Compliance, 35.9

Findings by how serious they are

117 critical 3769 serious 92 minor

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

This survey was produced by

Assert small markCanine Code Analyzer
Producer
Canine Development
Analyzer
Canine Code Analyzer engine 1.0.0
Measured
16 November 2026, 18:20 UTC

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

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

71of 71 dimensions measured by tools.
3936of 3978 findings point to an exact file and line, so you can open each one in the code. The other 42 concern the repository as a whole, such as missing documentation.
71dimensions across 6 lenses, read from 695,441 lines of product code in 39 projects.
Chapters

Executive summary

Untru/ibcmd-rs falls short of our standard for a preview release because its Security & compliance dimensions are rated Critical, and we found no encryption of stored data, no key vault and no enforced HTTPS. It scores 48.0 out of 100, which alone would earn Adequate, but it is rated Weak: a rating can't sit more than one step above its weakest group.

Security and Compliance, at 35.9, is the weakest lens and counts most in the score. The best first step is replacing the four exposed passwords or keys and switching the old ones off, worth about 6.3 points. Replacing the nine passwords or keys found in the code's history would lift Security and Compliance itself, worth about 5.7 points. Raising Security and Compliance to 68 would lift the score to about 57.3.

Fifty-five weaknesses in the code could be used by an attacker. Forty-four pipeline tools are referenced by a changeable name, so the build pipeline can be tampered with, and ten passwords or keys in the code's history and four in the code are open to anyone who can read the repository. Fixing the weaknesses the scanner points to, pinning each tool to an exact version and replacing each exposed password or key would close these risks. Updating the vulnerable packages would fix the package with a known security hole, and passing outside input through environment variables would deal with the pipeline step that puts outside input straight into a shell command. The two pieces of product code that depend on test code need their reference to the test project removed.

The product code is 695,441 lines, about €720,000 to rebuild.

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

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

If Security and Compliance rose from 35.9 to 68, the lowest score rated Strong, the score would rise from 48.0 to about 57.3.

Code composition: what the lines of code are
Product code 88%Tests 12%
Rebuild cost: about €720,000 · Estimate
Cost to rebuild€240,000 to €1,200,000, for 3,987 to 12,650 hours of work, about 5.0 person-years for 2 to 10 engineers
Difficulty of the problemStandard, judged from the kind of software and how it is built. Code that solves a harder problem, such as payments or medical bookings, costs more per line to write.
Quality factor×0.7 at a score of 48. Better code takes more work to write, so the factor is ×1.0 at a score of 70, lower below it and higher above it.
SizeVery large: 695,441 lines of product code
What it is notNot a quotation: nobody has offered to build it for that. Not a valuation: it says nothing about what the business is worth. Not a certified figure: no professional has signed it as one.

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

Top priorities

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

1
Resolve the 4 Leaked secret finding(s) in REDACTED Scanning — start with REDACTED (2), REDACTED, REDACTED.
Raises the score by about 6.3 points · Low effort · REDACTED Scanning
2
Resolve the 54 REDACTED finding(s) in Static Analysis (SAST) — start with REDACTED (9), REDACTED (6), REDACTED (6).
Raises the score by about 6.0 points · Medium effort · Static Analysis (SAST)
3
Resolve the 9 High secret finding(s) in Secrets (history) — start with REDACTED, REDACTED, REDACTED.
Raises the score by about 5.7 points · Low effort · Secrets (history)

Diagnosis: what the measurements show together

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

Where the investment is most exposed · Value at risk
This code would cost about €720,000 to build again, about 5.0 person-years of work. Its weakest lens is Security and Compliance, at 35.9 (Weak). Security and Compliance is about how well the product is protected, and how it handles personal data. Because the weakest lens counts most in the score, work on Security and Compliance also moves the score most.
Based on: the rebuild estimate · the Security and Compliance grade · how much each lens counts
What to do: Start with the Security and Compliance actions in Top priorities.
If you do one thing first · First action
Resolve the 4 Leaked secret finding(s) in REDACTED Scanning. Of all the actions in this report, it raises the score most for the work it takes: about 6.3 points for low effort, because it clears the 4 REDACTED Scanning findings. The next survey will show the change in the score.
Based on: the ranked actions in Top priorities, by score gain and effort
What hard-to-read code costs each year · Cost
Four dimensions measure how easy the code is to work in: two measure how tangled its logic is, one how much of it is copied, and one how well each part sticks to a single job. In this codebase they average 5.4 out of 10. Code at that level is slower to change than clean code, and we estimate the extra work at 7% to 15% on every change. The history of the code shows how much it changes: about 1,137,754 lines over the last 90 days, which is about 4,614,225 lines a year. At that pace, the extra work comes to an estimated 755.3 to 4531.8 engineer-days a year, and it grows as more code changes.
How this is estimated: The number of changed lines is measured from the history of the code. The rest rests on two assumptions of our own: code scoring 8 out of 10 or more adds no extra work, and each point below 8 adds 2.5% to 5.6% to every change, never less than 2% to 5% and never more than 40% to 60% in all; and an engineer changes 150 to 400 lines in a day. The result is a range for planning, not a measurement.
Based on: Cyclomatic Complexity · Cognitive Complexity · Code Duplication · Cohesion (LCOM4) · the code's change history
What to do: Start with the files listed under Churn × Complexity Hotspots, which change often and are hard to read, because that is where the extra work is paid most often.

Architecture — module dependency graph

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

arch ibcmd-1c-text ibcmd-1c-text ibcmd-1c-vocab ibcmd-1c-vocab ibcmd-1c-vocab->ibcmd-1c-text ibcmd-module-blob ibcmd-module-blob ibcmd-1c-vocab->ibcmd-module-blob ibcmd-schema ibcmd-schema ibcmd-1c-vocab->ibcmd-schema ibcmd-xml ibcmd-xml ibcmd-1c-vocab->ibcmd-xml ibcmd-apply-check ibcmd-apply-check ibcmd-apply-check->ibcmd-1c-text ibcmd-metadata-model ibcmd-metadata-model ibcmd-apply-check->ibcmd-metadata-model ibcmd-apply-check->ibcmd-module-blob ibcmd-sql ibcmd-sql ibcmd-apply-check->ibcmd-sql ibcmd-compiler ibcmd-compiler ibcmd-compiler->ibcmd-1c-text ibcmd-compiler-families ibcmd-compiler-families ibcmd-compiler->ibcmd-compiler-families ibcmd-core ibcmd-core ibcmd-compiler->ibcmd-core ibcmd-form-body ibcmd-form-body ibcmd-compiler->ibcmd-form-body ibcmd-form-writer ibcmd-form-writer ibcmd-compiler->ibcmd-form-writer ibcmd-metadata-blob ibcmd-metadata-blob ibcmd-compiler->ibcmd-metadata-blob ibcmd-compiler->ibcmd-module-blob ibcmd-compiler->ibcmd-schema ibcmd-compiler->ibcmd-xml ibcmd-compiler-families->ibcmd-1c-text ibcmd-compiler-families->ibcmd-core ibcmd-compiler-families->ibcmd-module-blob ibcmd-compiler-families->ibcmd-schema ibcmd-compiler-families->ibcmd-xml ibcmd-config-apply ibcmd-config-apply ibcmd-config-apply->ibcmd-apply-check ibcmd-config-apply->ibcmd-compiler ibcmd-config-apply->ibcmd-compiler-families ibcmd-config-apply->ibcmd-form-body ibcmd-config-apply->ibcmd-metadata-blob ibcmd-config-apply->ibcmd-metadata-model ibcmd-config-apply->ibcmd-module-blob ibcmd-mssql-live ibcmd-mssql-live ibcmd-config-apply->ibcmd-mssql-live ibcmd-config-apply->ibcmd-sql ibcmd-dump ibcmd-dump ibcmd-dump->ibcmd-1c-text ibcmd-dump->ibcmd-1c-vocab ibcmd-dump->ibcmd-compiler ibcmd-dump->ibcmd-compiler-families ibcmd-dump->ibcmd-config-apply ibcmd-dump->ibcmd-core ibcmd-dump->ibcmd-form-body ibcmd-form-native ibcmd-form-native ibcmd-dump->ibcmd-form-native ibcmd-dump->ibcmd-form-writer ibcmd-dump->ibcmd-metadata-blob ibcmd-dump->ibcmd-metadata-model ibcmd-dump->ibcmd-module-blob ibcmd-dump->ibcmd-mssql-live ibcmd-restructure ibcmd-restructure ibcmd-dump->ibcmd-restructure ibcmd-dump->ibcmd-schema ibcmd-dump->ibcmd-sql ibcmd-dump->ibcmd-xml ibcmd-form-body->ibcmd-1c-text ibcmd-form-body->ibcmd-1c-vocab ibcmd-form-body->ibcmd-core ibcmd-form-body->ibcmd-schema ibcmd-form-body->ibcmd-xml ibcmd-form-native->ibcmd-1c-text ibcmd-form-writer->ibcmd-1c-text ibcmd-form-writer->ibcmd-1c-vocab ibcmd-form-writer->ibcmd-core ibcmd-form-writer->ibcmd-form-body ibcmd-form-writer->ibcmd-form-native ibcmd-form-writer->ibcmd-module-blob ibcmd-form-writer->ibcmd-schema ibcmd-form-writer->ibcmd-xml ibcmd-metadata-blob->ibcmd-1c-text ibcmd-metadata-blob->ibcmd-1c-vocab ibcmd-metadata-blob->ibcmd-compiler-families ibcmd-metadata-blob->ibcmd-core ibcmd-metadata-blob->ibcmd-form-body ibcmd-metadata-blob->ibcmd-form-native ibcmd-metadata-blob->ibcmd-form-writer ibcmd-metadata-blob->ibcmd-module-blob ibcmd-metadata-blob->ibcmd-restructure ibcmd-metadata-blob->ibcmd-schema ibcmd-metadata-model->ibcmd-1c-text ibcmd-metadata-model->ibcmd-1c-vocab ibcmd-metadata-model->ibcmd-compiler-families ibcmd-metadata-model->ibcmd-core ibcmd-metadata-model->ibcmd-form-native ibcmd-metadata-model->ibcmd-metadata-blob ibcmd-metadata-model->ibcmd-module-blob ibcmd-metadata-model->ibcmd-restructure ibcmd-metadata-model->ibcmd-schema ibcmd-metadata-model->ibcmd-xml ibcmd-module-blob->ibcmd-1c-text ibcmd-mssql-live->ibcmd-1c-text ibcmd-mssql-live->ibcmd-compiler-families ibcmd-mssql-live->ibcmd-core ibcmd-mssql-live->ibcmd-sql ibcmd-restructure->ibcmd-schema ibcmd-rs ibcmd-rs ibcmd-rs->ibcmd-1c-text ibcmd-rs->ibcmd-1c-vocab ibcmd-rs->ibcmd-apply-check ibcmd-rs->ibcmd-compiler ibcmd-rs->ibcmd-compiler-families ibcmd-rs->ibcmd-config-apply ibcmd-rs->ibcmd-core ibcmd-rs->ibcmd-dump ibcmd-rs->ibcmd-form-body ibcmd-rs->ibcmd-form-native ibcmd-rs->ibcmd-form-writer ibcmd-rs->ibcmd-metadata-blob ibcmd-rs->ibcmd-metadata-model ibcmd-rs->ibcmd-module-blob ibcmd-rs->ibcmd-mssql-live ibcmd-rs->ibcmd-restructure ibcmd-rs->ibcmd-schema ibcmd-rs->ibcmd-sql ibcmd-rs->ibcmd-xml ibcmd-xml->ibcmd-core ibcmd-xml->ibcmd-schema __more__ +19 more projects

Architecture: which parts of the code depend on which

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

925 modules, with 2520 dependencies between them. 15 loops run through 59 of the modules, marked above the diagonal.

The table shows the 40 modules with the most connections; 885 more are left out to keep it readable.

Which modules use which. The module on each row uses the module in each column, and the number counts the pairs of types that connect them. A cell above the diagonal is part of a loop.
uses →1 formats_xml.descriptor2 formats_xml.emit3 formats_xml.registry4 ibcmd_core.artifact5 ibcmd_filedb.error6 ibcmd_metadata_blob.xml7 ibcmd_restructure.brace8 ibcmd_sql.sql9 ibcmd_xml.node10 morph1c_core.ir.value11 morph1c_core.version12 ibcmd_compiler_families.compiler.axes13 ibcmd_core.diagnostic14 ibcmd_core.profile15 ibcmd_core.storage16 ibcmd_form_body.form_body17 ibcmd_metadata_model.metadata_model.export18 morph1c_core.ir.form.data_attributes19 morph1c_core.ir.form.items20 ibcmd_core.family21 ibcmd_core.identity22 ibcmd_metadata_model.metadata_model.external_data_source_children23 morph1c_core.ir.form.body24 ibcmd_compiler_families.compiler.graph25 ibcmd_core.model26 ibcmd_dump.mssql_dump27 ibcmd_metadata_model.metadata_model28 morph1c_core.ir29 formats_xml.form.fields30 ibcmd_core.validate31 ibcmd_rs.cli32 ibcmd_xml.metadata.common33 morph1c_core.engine34 formats_xml.form35 formats_xml.locus36 ibcmd_compiler.compiler.bootstrap37 ibcmd_compiler_families.compiler.families.business_object38 ibcmd_rs.mssql39 ibcmd_xml.metadata.registry40 formats_xml.projection
1 formats_xml.descriptor
2 formats_xml.emit
3 formats_xml.registry
4 ibcmd_core.artifact
5 ibcmd_filedb.error
6 ibcmd_metadata_blob.xml
7 ibcmd_restructure.brace
8 ibcmd_sql.sql
9 ibcmd_xml.node
10 morph1c_core.ir.value
11 morph1c_core.version
12 ibcmd_compiler_families.compiler.axes1
13 ibcmd_core.diagnostic2
14 ibcmd_core.profile10
15 ibcmd_core.storage3
16 ibcmd_form_body.form_body2
17 ibcmd_metadata_model.metadata_model.export211
18 morph1c_core.ir.form.data_attributes2
19 morph1c_core.ir.form.items212
20 ibcmd_core.family21
21 ibcmd_core.identity1
22 ibcmd_metadata_model.metadata_model.external_data_source_children122
23 morph1c_core.ir.form.body3144
24 ibcmd_compiler_families.compiler.graph232
25 ibcmd_core.model8
26 ibcmd_dump.mssql_dump4212
27 ibcmd_metadata_model.metadata_model213
28 morph1c_core.ir1111
29 formats_xml.form.fields112
30 ibcmd_core.validate33
31 ibcmd_rs.cli4
32 ibcmd_xml.metadata.common37224
33 morph1c_core.engine211
34 formats_xml.form121
35 formats_xml.locus1
36 ibcmd_compiler.compiler.bootstrap3211124221
37 ibcmd_compiler_families.compiler.families.business_object21125112
38 ibcmd_rs.mssql1211264
39 ibcmd_xml.metadata.registry22222
40 formats_xml.projection3133523
Uses a module listed above itPart of a loopThe module itself
1 formats_xml.descriptor2 formats_xml.emit3 formats_xml.registry4 ibcmd_core.artifact5 ibcmd_filedb.error6 ibcmd_metadata_blob.xml7 ibcmd_restructure.brace8 ibcmd_sql.sql9 ibcmd_xml.node10 morph1c_core.ir.value11 morph1c_core.version12 ibcmd_compiler_families.compiler.axes13 ibcmd_core.diagnostic14 ibcmd_core.profile15 ibcmd_core.storage16 ibcmd_form_body.form_body17 ibcmd_metadata_model.metadata_model.export18 morph1c_core.ir.form.data_attributes19 morph1c_core.ir.form.items20 ibcmd_core.family21 ibcmd_core.identity22 ibcmd_metadata_model.metadata_model.external_data_source_children23 morph1c_core.ir.form.body24 ibcmd_compiler_families.compiler.graph25 ibcmd_core.model26 ibcmd_dump.mssql_dump27 ibcmd_metadata_model.metadata_model28 morph1c_core.ir29 formats_xml.form.fields30 ibcmd_core.validate31 ibcmd_rs.cli32 ibcmd_xml.metadata.common33 morph1c_core.engine34 formats_xml.form35 formats_xml.locus36 ibcmd_compiler.compiler.bootstrap37 ibcmd_compiler_families.compiler.families.business_object38 ibcmd_rs.mssql39 ibcmd_xml.metadata.registry40 formats_xml.projectionformats_xml.descriptor1formats_xml.emit2formats_xml.registry3ibcmd_core.artifact4ibcmd_filedb.error5ibcmd_metadata_blob.xml6ibcmd_restructure.brace7ibcmd_sql.sql8ibcmd_xml.node9morph1c_core.ir.value10morph1c_core.version11ibcmd_compiler_families.compiler.axes12ibcmd_core.diagnostic13ibcmd_core.profile14ibcmd_core.storage15ibcmd_form_body.form_body16ibcmd_metadata_model.metadata_model.export17morph1c_core.ir.form.data_attributes18morph1c_core.ir.form.items19ibcmd_core.family20ibcmd_core.identity21ibcmd_metadata_model.metadata_model.external_data_source_children22morph1c_core.ir.form.body23ibcmd_compiler_families.compiler.graph24ibcmd_core.model25ibcmd_dump.mssql_dump26ibcmd_metadata_model.metadata_model27morph1c_core.ir28formats_xml.form.fields29ibcmd_core.validate30ibcmd_rs.cli31ibcmd_xml.metadata.common32morph1c_core.engine33formats_xml.form34formats_xml.locus35ibcmd_compiler.compiler.bootstrap36ibcmd_compiler_families.compiler.families.business_object37ibcmd_rs.mssql38ibcmd_xml.metadata.registry39formats_xml.projection40121032211221221112231442328421221311111123343722421112113211124221211251121211264222223133523+885 more modules (most-connected shown)

At a glance — Code Health · 58.2 · Adequate · gated by D1, D2, R1 ·

At a glance — Architecture · 80.2 · Strong ·

At a glance — Maturity · 73.6 · Strong ·

At a glance — Readiness · 46.5 · Adequate · gated by D13, P2 ·

At a glance — Security · 35.9 · Weak · gated by D28, D29, D36, C1 ·

At a glance — Performance · 100.0 · Exemplary ·

Security & Compliance — OWASP Top-10 mapping

Findings mapped to OWASP categories; the specific CVEs/secrets are in the Security dimension cards below and findings.md (redacted only on the public version of this report).

OWASP categoryFindingsSeverity
A05:2025 — Injection104High / Critical
A03:2025 — Software Supply Chain Failures17High / Critical
A07:2025 — Authentication Failures15High / Critical

Roadmap

Top priorities: Encrypt sensitive data at rest (encrypt the fields with aes-gcm or chacha20poly1305 before they are written, or open the store encrypted — SQLCipher for rusqlite/sqlx, MongoDB CSFLE) and manage keys in a vault (AWS KMS / Secrets Manager through aws-sdk-kms, GCP KMS / REDACTED Manager, Azure Key Vault, HashiCorp Vault through vaultrs). Skip if delegated to infra (Postgres TDE, KMS, etc.); Resolve the 4 Leaked secret finding(s) in REDACTED Scanning — start with REDACTED (2), REDACTED, REDACTED; Resolve the 54 REDACTED finding(s) in Static Analysis (SAST) — start with REDACTED (9), REDACTED (6), REDACTED (6).

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

Do thisHelpsEffortDimension
Resolve the 4 Leaked secret finding(s) in REDACTED Scanning — start with REDACTED (2), REDACTED, REDACTED.+6.3 ptsLowREDACTED Scanning
Resolve the 54 REDACTED finding(s) in Static Analysis (SAST) — start with REDACTED (9), REDACTED (6), REDACTED (6).+6.0 ptsMediumStatic Analysis (SAST)
Resolve the 9 High secret finding(s) in Secrets (history) — start with REDACTED, REDACTED, REDACTED.+5.7 ptsLowSecrets (history)
Encrypt sensitive data at rest (encrypt the fields with aes-gcm or chacha20poly1305 before they are written, or open the store encrypted — SQLCipher for rusqlite/sqlx, MongoDB CSFLE) and manage keys in a vault (AWS KMS / Secrets Manager through aws-sdk-kms, GCP KMS / REDACTED Manager, Azure Key Vault, HashiCorp Vault through vaultrs). Skip if delegated to infra (Postgres TDE, KMS, etc.).+7.9 ptsMediumData Protection
Resolve the 1 End-of-life runtime finding(s) in Platform End-of-Life — start with rust-toolchain.toml.+3.1 ptsLowPlatform End-of-Life
Resolve the 1 No ADRs found finding(s) in ADR Quality — start with main.rs.+1.3 ptsLowADR Quality
Adopt `tracing` with `tracing-subscriber` (JSON output) and log at meaningful points in the binaries you run.+3.6 ptsMediumObservability
Resolve the 1 REDACTED finding(s) in Secrets (history) — start with REDACTED.+1.5 ptsLowSecrets (history)

File quality

Per-file score 0–10 — a quality signature. Of 435 files carrying findings, judged against the Preview bar: 2% slop · 7% mixed · 91% near-clean.

FileScoreBandWorst signal
REDACTED0.0SlopStatic Analysis (SAST): High: REDACTED
REDACTED1.5SlopStatic Analysis (SAST): High: REDACTED
REDACTED2.1SlopStatic Analysis (SAST): High: REDACTED
REDACTED2.1SlopStatic Analysis (SAST): High: REDACTED
REDACTED2.3SlopStatic Analysis (SAST): High: REDACTED
REDACTED2.5SlopStatic Analysis (SAST): High: REDACTED
REDACTED2.8SlopStatic Analysis (SAST): High: REDACTED
REDACTED2.8SlopStatic Analysis (SAST): High: REDACTED
REDACTED2.9SlopStatic Analysis (SAST): High: REDACTED
REDACTED2.9SlopStatic Analysis (SAST): High: REDACTED
REDACTED3.0MixedREDACTED Scanning: Leaked secret: REDACTED
REDACTED3.1MixedStatic Analysis (SAST): High: REDACTED
REDACTED3.6MixedStatic Analysis (SAST): High: REDACTED
REDACTED4.2MixedStatic Analysis (SAST): High: REDACTED
REDACTED4.2MixedStatic Analysis (SAST): High: REDACTED
REDACTED4.2MixedStatic Analysis (SAST): High: REDACTED
REDACTED4.2MixedStatic Analysis (SAST): High: REDACTED
REDACTED4.3MixedStatic Analysis (SAST): High: REDACTED
REDACTED4.3MixedStatic Analysis (SAST): High: REDACTED
REDACTED4.4MixedREDACTED Scanning: Leaked secret: REDACTED

How the grades work

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

Critical — 117

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

Serious — 3769

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

Minor — 92

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

Could not be resolved — 8

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

Methodology & how to trust this report

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

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

What we checked — 71 dimensions across the health lenses
D1D2D3D4D5D6D10D12D13D14D15D17D19D20D24D26D28D29D30D34D35D36D43D44AX10AX3AX4AX8AX9C1C3C4GD1IC1M1M2M3M4P1P10P2P3P4P5P6PF3R1R10R2R3R4R5R6R7R8R9S1X1X12X13X16X17X18X2X21X25X27X28X29X30X5

Each chip is a dimension scored from real signals across architecture, testing, dependencies, security & compliance, documentation, git-history and code quality — in one coherent pass. A surface report typically covers a handful.

How to trust any code-health report — three questions
  1. Can you open the finding? Real findings cite a repo-relative file and line you can open at the cited line — never an absolute scratch path. Here, 3936 of 3978 do; the remainder are repo-wide signals — a dimension-level measurement, not a single line. (Every path in this report is repo-relative by construction: paths are normalized at the producer and the report is rejected if any rooted path leaks through.)
  2. Is there a tool behind the number? Every score below names the method that produced it: Roslyn, git or a scanner, not a narrative.
  3. Does re-running give the same result? Run it again on the same commit and the score — and this report, byte for byte — is identical. A report whose numbers move between runs is describing the run, not the code.

This report answers yes to all three. That's the bar to hold any assessment to.

Tools & methods

The actual versions used this run (captured at analysis time) — re-run on the same commit for the identical score.

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

Every finding is locatable in findings.md. Run 01a1e596-7597-7557-be1e-276258e6724d.

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

Run transparency — what happened this run

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

  • D8 Code Coverage — not measured this run — We could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. Coverage NOT MEASURED: this repository's production source spans .ts, .rs, and our analyzer cannot run the .rs test suite(s) — so no coverage was collected for the repository as a whole. The JavaScript/TypeScript half did build and run, and its own line coverage came back at 95.6% — but that is a figure for one half of the product, and we do not publish a partial one as if it were complete. This is OUR limitation, not a defect in the repo — coverage is excluded from the score rather than counted as a near-zero.
  • D10 Test Quality — measured, with a gap in what it reached — We measured this, but not all of it. What we did not reach is a gap on our side — a collector, parser or image we have not built yet — so the numbers on that dimension cover less than the repository, and the part left out is not evidence that it would have passed. The 130 test(s) behind this row are the ones the JavaScript/TypeScript census could read, and this repository also carries at least 267 test source file(s) (.py, .rs, .ps1) that it cannot: it reads JavaScript/TypeScript test declarations off disk, so a JUnit/pytest-style suite is invisible to it. Skipped tests, zero-assertion tests and the other quality signals on this row are UNMEASURED in that suite — their absence from the counts above is a gap in this analyzer's language coverage, not a finding that those tests are sound.
  • D11 Test Reliability — not measured this run — We could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. Test reliability NOT SCORED: this repository's production source includes .rs, and the rust executor ran against the .rs half and did not finish re-running within its tier budget — so reliability was not measured for the repository as a whole. The JavaScript/TypeScript (node:test via `npm ci --ignore-scripts` in editors/vscode/ (120 tests)): measured (0 flaky) suite(s) did re-run, and came back with 0 flaky across 1 measured tier(s) — but that is a figure for one half of the product, and we do not publish a partial one as if it were complete. This is OUR limitation, not a defect in the repo — test reliability is excluded from the score rather than counted. The half was driven by a runner we ship, so this is not a missing-runner gap.
  • D16 Bus Factor — not measured this run — This is a true statement about the repository that carries nothing for its owner to act on, so it is reported here rather than as a defect in their code. Single-maintainer repository — bus factor is not applicable (9 contributor(s) across 4619 commit(s) sampled, automation and bot accounts excluded). One of them holds 87% of the history; the other 8 hold 1.6% each on average, below the 5% at which there is somebody to hand the work to. That is a single maintainer with drive-by contributors, not a team whose knowledge has concentrated — so the bus factor is not applicable and there is nothing here for the owner to act on.
  • D19 Documentation Quality — measured, with a gap in what it reached — We measured this, but not all of it. What we did not reach is a gap on our side — a collector, parser or image we have not built yet — so the numbers on that dimension cover less than the repository, and the part left out is not evidence that it would have passed. Each ecosystem's manifests (what makes a folder runnable or a published package) need their own proof before D19 judges its units. Until then those folders' READMEs are judged only as documents (boilerplate, structure), never counted as complete.
  • D19 Documentation Quality — measured, with a gap in what it reached — We measured this, but not all of it. What we did not reach is a gap on our side — a collector, parser or image we have not built yet — so the numbers on that dimension cover less than the repository, and the part left out is not evidence that it would have passed. This kind did not reach the 95 % precision gate in three adjudicated runs (docs/plans/deterministic-engine/adjudication/D19-sample3-v3.md), so by the pre-registered fallback it publishes no row until a re-measurement shows it does. The candidates are counted here, not reported as findings, and the score does not include them.
  • D21 Naming Consistency — not measured this run — We could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. PREREGISTRATION version 20's fallback (adjudication D21-sample3-v3): this rule kind was adjudicated below the 95 % precision gate, so its candidates are counted here and not published, and the score covers only the acronym-spelling and awaitable-suffix rules. The kind returns as rows only after it shows a measured precision; this says nothing about whether these names are consistent.
  • D22 Internal API Consistency — not measured this run — We could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. D22's deterministic call-shape rules are gated per language (docs/plans/deterministic-engine.md, P5; C# and each NeutralApiArms arm pass): each other language is switched on only after its own concept suite and A/B gate pass. This says nothing about whether that surface is consistent.
  • D24 Comment Value — measured, with a gap in what it reached — We measured this, but not all of it. What we did not reach is a gap on our side — a collector, parser or image we have not built yet — so the numbers on that dimension cover less than the repository, and the part left out is not evidence that it would have passed. Each source language's comment syntax, and the code a comment annotates in it, needs its own proof before D24 judges it. Until then those comments are left unread, not counted as clean.
  • D27 Navigability — not measured this run — We could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. Navigability is taken over call sites whose callee resolved. For C# that population includes calls into referenced assemblies; for this language only calls declared inside the repository count, so the abstention threshold reads the repository's use of its standard library as a resolution failure. That is a limit of this analyzer, not a build problem in this repository.
  • D28 Secrets (history) — measured, with a gap in what it reached — We measured this, but not all of it. What we did not reach is a gap on our side — a collector, parser or image we have not built yet — so the numbers on that dimension cover less than the repository, and the part left out is not evidence that it would have passed. D28's config-credential rule (REDACTED) parses each committed `.json` config as a document and reads credential-named values; `docs/extensions/evidence/extension-version-20261001/own_load_version2_after_noop.json` did not parse (JSON5, a template, several concatenated documents), so a credential bound there is UNMEASURED by that rule. gitleaks still scanned the same files as text.
  • AX6 Interface segregation — not measured this run — We could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check's reader does not cover most of the languages this repository's product is written in. What it read is kept, but it is too small a share to grade the product by. That is a gap in this analyzer's language reach — not a finding about this repository.
  • M4 Documentation accuracy — measured, with a gap in what it reached — We measured this, but not all of it. What we did not reach is a gap on our side — a collector, parser or image we have not built yet — so the numbers on that dimension cover less than the repository, and the part left out is not evidence that it would have passed. M4 checks only the claim kinds adjudicated at or above 95 % precision: links and versions (PREREGISTRATION version 9), and artefact counts an order of magnitude off. Paths, command arguments, installs, environment variables, settings, projects, packages, routes, cd targets, infrastructure products and removed modules are read but not checked, and none of them is reported or counted.
  • X10 Duplicated predicate — not measured this run — We could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. 28 further occurrence(s) are not listed individually; the score already reflects all 68.
  • X24 Document value interpolated into markup unescaped — not measured this run — We could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check's reader does not cover most of the languages this repository's product is written in. What it read is kept, but it is too small a share to grade the product by. That is a gap in this analyzer's language reach — not a finding about this repository.
  • X25 Inert configuration knob — measured, with a gap in what it reached — We measured this, but not all of it. What we did not reach is a gap on our side — a collector, parser or image we have not built yet — so the numbers on that dimension cover less than the repository, and the part left out is not evidence that it would have passed. 57 further occurrence(s) are not listed individually; the score already reflects all 97.
  • X3 Exception handling — not measured this run — We could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check's reader does not cover most of the languages this repository's product is written in. What it read is kept, but it is too small a share to grade the product by. That is a gap in this analyzer's language reach — not a finding about this repository.
  • X5 Nullable reference types — measured, with a gap in what it reached — We measured this, but not all of it. What we did not reach is a gap on our side — a collector, parser or image we have not built yet — so the numbers on that dimension cover less than the repository, and the part left out is not evidence that it would have passed. 767 further occurrence(s) are not listed individually; the score already reflects all 807.

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

Limitations & what we did not check

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

Per-dimension blind spots

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

  • D1 Cyclomatic Complexity: Cyclomatic complexity counts branches statically — it cannot tell an essential decision tree from accidental tangle, nor see complexity that lives in data or configuration (large switch-case token tables, DSL lexers/parsers, data-as-code rule tables) rather than control flow: a tokenizer's many single-character cases read as high complexity though each branch is trivial.
  • D2 Cognitive Complexity: Cognitive-complexity heuristics approximate how hard code is to follow; genuine domain difficulty and well-named intent that eases reading are not captured.
  • D3 God Classes: "God class" is sized by members and responsibilities visible in the type — a deliberately broad facade over a coherent subsystem can read the same as an accidental grab-bag. For front-end JS the file-length check is cohesion-aware (a single-responsibility module — one class/IIFE — earns a 3× threshold), but cohesion is approximated from top-level declarations, not true dependency structure.
  • D4 Code Duplication: Duplication is token-similarity — an in-process token-stream comparison over sliding windows, with type-aware normalization — so it finds copy-paste, not semantic duplication expressed differently. Committed machine-written code (scaffolded migrations, designer/codegen output, protobuf/OpenAPI stubs, model snapshots) is EXCLUDED — its repetition is the tool's, not the team's — so the score reflects hand-written duplication only.
  • D5 Coupling: Coupling is measured between projects/assemblies — runtime coupling through DI, reflection, messaging or shared databases is invisible to a static reference graph.
  • D6 Cohesion (LCOM4): LCOM4 cohesion is syntactic — it infers connectivity from which methods touch which fields/methods by name, not from real runtime behaviour or intent.
  • D10 Test Quality: Assertion density is structural — it cannot tell a meaningful behavioural assertion from a trivial one, only that an assertion is present.
  • D12 Dependency Hygiene: Dependency health reads manifests and lockfiles — a vulnerability in a vendored/copied dependency, or risk from how a dependency is actually used, is outside this view.
  • D13 REDACTED Scanning: REDACTED detection is signature- and entropy-based on the current tree — a secret that does not match a known pattern, or one already rotated, will not be flagged (a clean scan is "nothing matched", not "no secrets exist").
  • D14 License Compliance: License compatibility is checked against declared package metadata and a policy — mislabelled or missing license metadata, and obligations that depend on how you distribute, are not resolved here.
  • D15 Churn × Complexity Hotspots: Churn hotspots come from git history — a freshly imported or squashed repository has no churn signal, and recent rewrites can mask a historically risky file.
  • D17 Explicit Debt: Acknowledged-debt signals (TODO/FIXME, suppressions, dead code) are textual — undocumented debt that nobody marked, and debt that lives in design rather than annotations, is invisible. Committed machine-written code (scaffolded migrations, designer/codegen output, generated stubs) is excluded — it is never the team's dead code to delete.
  • D19 Documentation Quality: Documentation quality publishes two things only: a runnable or packaged unit with no example, and a multi-project root README that maps none of its parts. It does not judge clarity, and its other checks (overview, licence, boilerplate, structure, empty sections, XML-doc coverage) are withheld after adjudication: their candidates are counted in the card's gaps, not shown as rows. A false statement in a document is M4's; units are .NET projects only.
  • D20 ADR Quality: ADR quality checks the structure of the decision records present: it cannot know about decisions made and never recorded, and it does not judge how well a record argues its case. Records in a language the section lexicon does not cover are not evaluated.
  • D24 Comment Value: Comment value is measured as redundancy only: a comment that repeats its code's words is found, but a paraphrase in other words, a vague comment, or one the code contradicts is not, and whether a comment is valuable is not claimed. Comments in other scripts or languages, and outside C#, are not judged.
  • D26 Project Cohesion: Project focus is sized from members/namespaces per project — a project that is broad by deliberate design reads the same as one that has sprawled.
  • D28 Secrets (history): Secret-history scanning sweeps the git log for known patterns — a secret that predates the available history, or never matched a signature, is not found (clean means "nothing matched in the history we can see").
  • D29 Static Analysis (SAST): SAST findings are pattern-based (semgrep) — it finds classes of bug it has rules for; logic flaws, auth/authorization gaps and issues needing runtime context are out of reach (and clean means "no rule matched").
  • D30 Dependency Vulnerabilities: CVE matching depends on accurate package/version metadata and on the advisory databases — a vulnerability with no published advisory, or in code not declared as a dependency, is not seen. Coverage needs a RESOLVED graph: an unpinned requirements.txt, or a pom without a resolved build, yields partial coverage rather than a clean verdict. An ecosystem the analyzer cannot scan is reported as unmeasured, never as clean.
  • D34 Knowledge Freshness: Freshness is decayed commit RECENCY, not comprehension — code read often but rarely committed reads as orphaned, and stable code that genuinely needs no changes is penalised the same as forgotten code; bot/squash commits distort it like the bus factor.
  • D35 Change Coupling: Change coupling is co-change in COMMITS — files split across separate commits, or coupled only through a shared config/build step, read as uncoupled, and a sweeping commit (rename/format) is excluded so it doesn't couple everything. It shows that files change together, not WHY: a high coupling can be a healthy cohesive pair as readily as a hidden leak.
  • D43 Malicious Dependencies: Only packages some vulnerability database has already NAMED as malicious are seen — a compromise published in the last hours, or never reported at all, is invisible here, and this dimension reading 10 is not evidence that a dependency is trustworthy. There is no typosquat or dependency-confusion analysis: a package nobody has reported is simply absent from the feeds. Coverage is the dependency scan's: an ecosystem that could not be scanned is disclosed as unmeasured, never as clean.
  • D44 Platform End-of-Life: The support table is FROZEN, so it goes out of date by losing RECALL: a release that ended support after the table was written is missed until the table is refreshed, and this dimension reading 10 is not evidence that a platform is current. Only platforms the repository DECLARES in a place this pass reads are seen — a runtime named only in a Dockerfile (D31's subject), in a CI workflow (D29's), or in a file this pass does not parse (go.mod, a Gemfile ruby directive) is invisible here, which is why a repository declaring none of them abstains rather than scoring. Only frameworks with a PUBLISHED support policy are tracked: React, Flask and Express publish none, so their age cannot be judged and their absence from a report is not a statement that they are supported.
  • AX10 Code composition: Role is inferred from namespace/folder convention, not semantics — a domain concept living in a folder named "Services" reads as application, and the split is lines-of-code, not business value. The business-logic-share score is a SOFT, FLOORED signal: it contributes to the Architecture lens but is floored at the Critical gate, so an infrastructure-heavy design (a gateway, an ETL, a driver) is legitimately low without being nuked to zero.
  • AX9 CQS / query purity: Handlers are found by interface/name convention — a query handler using neither is not seen. Mutation is a resolved write/publish invocation (SaveChanges/repository/bus), so a write hidden behind a hand-rolled wrapper, reflection, or a string-keyed service locator resolves to a non-persistence type and isn't flagged; it detects that a query writes state, not whether the write is a legitimate read-side cache update. Clean means "no resolved write/publish in a query body", not a proof of CQS purity.
  • C3 Audit Trail: This control is scored from in-repo evidence only — a working control configured outside the repository leaves no signal a static scan can credit.
  • C4 Data Retention: This control is scored from in-repo evidence only — its real-world effectiveness, exercised only at runtime, is outside a static scan.
  • M4 Documentation accuracy: Documentation accuracy checks links, versions and artefact counts against the tree: other claims (paths, commands, settings, routes) are read but not checked, and it cannot run the onboarding or measure how long a real new joiner takes.
  • P4 Deployment & Rollback: Approval/branch-protection rules live in repository settings the scan cannot see — only their in-repo evidence (config files, workflows) is checked, so a control enforced purely in the host's settings reads as "not evidenced".
  • P5 DR & Backup: Backup/restore and disaster-recovery readiness is judged from in-repo evidence — a config that exists is not a tested restore, so the absence of positive evidence is reported as "not evidenced", never scored as present.
  • P6 Release Hygiene: Rollback/observability controls are inferred from repo artefacts (pipelines, dashboards-as-code) — controls configured in external tooling, with no in-repo trace, cannot be credited.

Dimensions

D1 · Cyclomatic Complexity2.4 / 10Critical✓ Tool-verified

What it measures: How tangled the control flow is — methods with many branches are hard to test and change.

Method: Cyclomatic complexity per method (1 + decision points), computed exhaustively across production source; test projects separated by convention. Deterministic.

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

462 method(s) exceeded the cyclomatic complexity threshold of 15; the worst was ibcmd_form_writer::parse_form_xml_body_properties at 919. A further 95 method(s) were over the threshold but excluded as flat dispatchers (a long switch/match over independent cases: many branches, almost no nesting), the largest being ibcmd_form_body::form_body::form_event_name_from_identifier at 112 — they are counted neither in the figure above nor in this dimension's score. 20 files carry no cyclomatic complexity row at all for this reason — every one of their over-threshold methods was excluded, so the exclusion is disclosed nowhere in the file itself: crates/ibcmd-1c-vocab/src/style.rs (ibcmd_1c_vocab::style::style_web_color_name at 67), crates/ibcmd-dump/src/mssql_dump/extension/properties.rs (ibcmd_dump::mssql_dump::extension::properties::meaning at 64), crates/ibcmd-apply-check/src/apply_check/rule_id.rs (RuleId::id at 62), crates/ibcmd-restructure-engine/src/restructure/caches/root.rs (ibcmd_restructure_engine::restructure::caches::root::kind_of_class at 49), crates/ibcmd-1c-vocab/src/types.rs (ibcmd_1c_vocab::types::builtin_type_reference at 47), and 15 more not listed here. They are named here because the per-file figures other dimensions report are taken BEFORE this exclusion, so such a file can show a high maximum complexity elsewhere in this report and nothing here, with nothing to reconcile the two.

ibcmd_xml::dcs_schema::rewrite_tokens (cyclomatic 133) · ×65crates/ibcmd-xml/src/dcs_schema.rs:4004
ibcmd_dump::mssql_dump::dump_table_rows_streamed (cyclomatic 211) · ×64crates/ibcmd-dump/src/mssql_dump/mod.rs:4807
ibcmd_rs::run (cyclomatic 182) · ×50src/main.rs:29
ibcmd_form_body::form_body::format_form_child_item_xml (cyclomatic 441) · ×42crates/ibcmd-form-body/src/form_body.rs:33250
ibcmd_form_writer::parse_form_xml_body_properties (cyclomatic 919) · ×37crates/ibcmd-form-writer/src/lib.rs:7984

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

What to do

  1. Bring the 3 bodies over 240 down to 240 or less in Cyclomatic Complexity — start with ibcmd_form_writer::parse_form_xml_body_properties (cyclomatic 919), ibcmd_form_body::form_body::format_form_child_item_xml (cyclomatic 441), ibcmd_form_body::form_body::parse_form_child_item_with_metadata_owners (cyclomatic 403). — This score is capped by its worst body, so a finding fixed alone moves it by almost nothing — the next one down takes its place. Refactoring these 3 together lifts Cyclomatic Complexity from 2.4 to about 4.2/10, projected with the scoring formula itself and assuming each lands exactly at 240; a cleaner split scores higher.

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

D2 · Cognitive Complexity2.0 / 10Critical✓ Tool-verified

What it measures: How hard the code is for a person to follow, beyond raw branching.

Method: Cognitive complexity per method (Sonar-style nesting-penalized score), computed exhaustively over production code, excluding test projects. Deterministic.

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

743 method(s) exceeded the cognitive complexity threshold of 15; the worst was ibcmd_form_writer::parse_form_xml_body_properties at 1688.

ibcmd_dump::mssql_dump::dump_table_rows_streamed (cognitive 324) · ×109crates/ibcmd-dump/src/mssql_dump/mod.rs:4807
ibcmd_rs::run (cognitive 135) · ×100src/main.rs:29
ibcmd_xml::dcs_schema::rewrite_tokens (cognitive 353) · ×94crates/ibcmd-xml/src/dcs_schema.rs:4004
ibcmd_form_body::form_body::format_form_child_item_xml (cognitive 535) · ×62crates/ibcmd-form-body/src/form_body.rs:33250
ibcmd_form_writer::parse_form_xml_body_properties (cognitive 1688) · ×49crates/ibcmd-form-writer/src/lib.rs:7984

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

What to do

  1. Bring the 14 bodies over 120 down to 120 or less in Cognitive Complexity — start with ibcmd_form_writer::parse_form_xml_body_properties (cognitive 1688), ibcmd_form_body::form_body::format_form_child_item_xml (cognitive 535), ibcmd_form_body::form_body::parse_form_child_item_with_metadata_owners (cognitive 505). — This score is capped by its worst body, so a finding fixed alone moves it by almost nothing — the next one down takes its place. Refactoring these 14 together lifts Cognitive Complexity from 2.0 to about 3.5/10, projected with the scoring formula itself and assuming each lands exactly at 120; a cleaner split scores higher.

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

D3 · God Classes8.8 / 10Strong✓ Tool-verified

What it measures: Over-large classes that try to do too much ("god classes").

Method: God-class detection by line and method-count thresholds per logical type (partial classes unified), filtered for generated code and registration/contract false positives. Deterministic.

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

361 god class(es) detected.

FunctionTooLong: ibcmd_dump::mssql_dump::source_assets::write_source_asset_inner · ×154crates/ibcmd-dump/src/mssql_dump/source_assets.rs:2323
FileTooLong: mssql_dump/mod.rs · ×131crates/ibcmd-dump/src/mssql_dump/mod.rs
MethodTooLong: MigrationExecutor.execute · ×38crates/ibcmd-core/src/migration/executor.rs:104
TooManyFields: FormChildItem · ×25crates/ibcmd-form-body/src/form_body.rs:1861
ClassTooLong: BodyWriter · ×8crates/ibcmd-compiler/src/compiler/bodies/mxl_native.rs:714

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

What to do

  1. Resolve the 154 FunctionTooLong finding(s) in God Classes — start with lib.rs (8), business_object.rs (8), REDACTED (7). — One of this dimension's main actionable groups (154 warning-level).
  2. Resolve the 131 FileTooLong finding(s) in God Classes — start with lib.rs (7), mod.rs (6), dcs.rs (4). — One of this dimension's main actionable groups (131 warning-level).
  3. Resolve the 38 MethodTooLong finding(s) in God Classes — start with lib.rs (10), mxl_native.rs (4), dcs.rs (3). — One of this dimension's main actionable groups (38 warning-level).

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

D4 · Code Duplication7.2 / 10Strong✓ Tool-verified

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

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

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

1243 duplicated block group(s) detected. 7.0 % of the production lines (48,407 of 695,441) are in a reported copy. A further 619 rows report members as variants of one another; the share counts each copied line once, however many rows cite it. 51 of the 1862 are in trees this repository does not ship — vendored, example/demo, project-template, fixture and benchmark code — and are ranked below the shipped groups rather than excluded from them: the duplication there is real and is still counted in this dimension's score. The dimensions that publish a production-file census leave those trees out of theirs, so this count is deliberately drawn over the wider population.

Duplicated block (6 lines × 2) · ×110crates/ibcmd-1c-text/src/xml.rs:9
Duplicated block (7 lines × 2) · ×96crates/ibcmd-1c-vocab/src/commands.rs:259
Duplicated block (8 lines × 2) · ×93crates/ibcmd-1c-text/src/braced.rs:373
Duplicated block (5 lines × 2) · ×78crates/ibcmd-1c-text/src/braced.rs:302
Duplicated block (9 lines × 2) · ×73crates/ibcmd-compiler-families/src/compiler/families/services.rs:2474

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

What to do

  1. Resolve the 110 Duplicated block (6 lines × 2) finding(s) in Code Duplication — start with mod.rs (15), lib.rs (14), form_body.rs (9). — One of this dimension's main actionable groups (110 warning-level).
  2. Resolve the 96 Duplicated block (7 lines × 2) finding(s) in Code Duplication — start with mod.rs (14), lib.rs (9), services.rs (6). — One of this dimension's main actionable groups (96 warning-level).
  3. Resolve the 93 Duplicated block (8 lines × 2) finding(s) in Code Duplication — start with mod.rs (13), lib.rs (13), services.rs (8). — One of this dimension's main actionable groups (93 warning-level).

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

D5 · Coupling6.4 / 10Adequate✓ Tool-verified

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

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

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

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

39 production modules (Cargo+npm), 0 dependency cycle(s), 2 unstable depended-on module(s). Read from the build's own module declarations; 15 module(s) off the main sequence, with abstractness counted on 36 of the 39 (the rest declare no modelled class or interface, export only macros, declare types in source no model reads, or have no source directory of their own).

Off the main sequence: ibcmd-1c-text · ×15
Unstable project ibcmd-config-apply
Unstable project ibcmd-dump

What to do

  1. Resolve the 15 Off the main sequence finding(s) in Coupling. — One of this dimension's main actionable groups (15 warning-level).
  2. Resolve the 1 Unstable project ibcmd-config-apply finding(s) in Coupling. — One of this dimension's main actionable groups (1 warning-level).
  3. Resolve the 1 Unstable project ibcmd-dump finding(s) in Coupling. — One of this dimension's main actionable groups (1 warning-level).

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

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

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

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

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

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

3 of 392 classes have LCOM4 above 3.

Low cohesion: CanonicalValue (LCOM4 6) · ×3crates/ibcmd-core/src/value.rs:565

What to do

  1. Resolve the 3 Low cohesion finding(s) in Cohesion (LCOM4) — start with value.rs, lib.rs, REDACTED. — One of this dimension's main actionable groups (3 warning-level).

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

D10 · Test Quality10.0 / 10Exemplary✓ Tool-verified

What it measures: Whether the tests truly assert behaviour rather than just running the code.

Method: Per-test assertions, skips, and mock references analyzed via Roslyn; structured skip-reason tags (BUG:/ENV:) separate documented deferrals from debt. Deterministic.

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

2 skipped (2 with a documented reason), 0 zero-assertion, no mocking-framework packages referenced (hand-written doubles or no mocking) across 130 tests. Measured on the JavaScript/TypeScript suite only — at least 267 test source file(s) (.py, .rs, .ps1) went unread, so its test quality is unmeasured and is not in these counts.

Skipped (documented): dirty casing aliases are refused on case insensitive source filesystems · ×2editors/vscode/test/export.test.js:296

✓ On the Gold path — maintain.

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

D12 · Dependency Hygiene9.4 8.1 / 10Strong✓ Tool-verified

What it measures: Whether dependencies are current, not deprecated, and not bloated. Known vulnerabilities are D30's.

Method: Manifest scan via dotnet list package across all projects; worst-signal-per-package deduction (capped-linear for deprecation, prerelease and outdated) per KLoC. Known-vulnerable packages are D30's and are not charged here (rubric-2026.11.2). Exhaustive.

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

12 outdated, 0 yanked direct Cargo dependencies. 26 of 30 direct crates were graded against crates.io (0 not published there, 4 not resolved by a committed REDACTED). Only DIRECT edges are graded: a transitive crate cannot be moved past what its parent's requirement admits, so reporting one would be advice its owner cannot take. A newer release is reported only where this repository's OWN requirement already admits it, so the remedy is `cargo update` and never a manifest edit — which means a release outside the declared range is deliberately NOT charged, because a written-down constraint is a decision rather than a defect. Note that a bare requirement is a CARET, and for a 0.x crate its ceiling is the minor. Whether any crate is UNMAINTAINED is not graded — crates.io publishes no maintenance status, and release age does not stand in for one. Known CVEs in this dependency graph are D30's question, read from REDACTED there.

Outdated: anyhow · ×12

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

D13 · REDACTED Scanning0.0 / 10Critical✓ Tool-verified

What it measures: Whether any secrets (keys, tokens, passwords) have leaked into the code.

Method: In-process native secret scanner (entropy plus signature patterns) across all tracked files; no external tool. A clean result is a measured 10, not no-data zero. Deterministic.

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

3 secret(s) detected.

REDACTED

What to do

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

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

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

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

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

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

0 of 217 shipped crate(s) use a banned license. Licences were resolved from crates.io over the crates a consumer compiles — this repository's REDACTED closed over its manifests' `[dependencies]` and `[build-dependencies]`. Crates it asks for ONLY under `[dev-dependencies]` are excluded: they are not compiled by anything that depends on this repository. This repository publishes itself under MIT, which is its own choice and is not judged here.

✓ On the Gold path — maintain.

Detailed fixes: d14_recommendation.md.

D15 · Churn × Complexity Hotspots4.7 / 10Weak✓ Tool-verified

What it measures: Files that change often and are also complex — the riskiest hotspots.

Method: Per production file churn times cyclomatic complexity over a rolling window, computed from git and Roslyn/JS/Razor analysis. Exhaustive, deterministic per commit date.

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

Top hotspots: crates/ibcmd-form-body/src/form_body.rs (351×441=154791); crates/ibcmd-dump/src/mssql_dump/mod.rs (355×211=74905); crates/ibcmd-moxel/src/lib.rs (117×82=9594) Repeated repair below the complexity floor: crates/ibcmd-filedb/src/lib.rs (13 of 18 changes were fixes); crates/ibcmd-filedb/src/config.rs (7 of 12 changes were fixes); src/mcp.rs (7 of 11 changes were fixes)

Hotspot: crates/ibcmd-form-body/src/form_body.rs · ×87crates/ibcmd-form-body/src/form_body.rs:33250
Repeated repair: crates/ibcmd-filedb/src/lib.rs · ×17crates/ibcmd-filedb/src/lib.rs:647

What to do

  1. Resolve the 87 Hotspot finding(s) in Churn × Complexity Hotspots — start with lib.rs (4), mod.rs (3), main.rs (2). — One of this dimension's main actionable groups (87 warning-level).
  2. Resolve the 17 Repeated repair finding(s) in Churn × Complexity Hotspots — start with lib.rs, config.rs, mcp.rs. — One of this dimension's main actionable groups (17 warning-level).

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

D17 · Explicit Debt10.0 / 10Exemplary○ Nothing flagged

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

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

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

0 deducted task-comment markers across 695441 LoC (0.0/KLoC) → score 10.0. Task comments only: this repository's language is read without a compiler, so D17's suppression, dead-code and commented-out-code arms did not run and this score counts fewer marker kinds than a .NET repository's would.

✓ On the Gold path — maintain.

Detailed fixes: d17_recommendation.md.

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

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

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

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

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

✓ On the Gold path — maintain.

Detailed fixes: d19_recommendation.md.

D20 · ADR Quality0.0 / 10Critical✓ Tool-verified

What it measures: Whether architecture decisions are recorded well (context, decision, consequences).

Method: Every ADR read by its section structure: nine located rules (a missing Decision, Context or Consequences section, a stale status, two records deciding the same question, a dangling supersede link, a number-only title, a single option, no named cost, no status where the log uses one, no enforcement field where the log adopted one), each a fixed deduction from 10; the score is the mean over evaluated records. Deterministic, no model. Advisory.

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

No architecture decision records were found.

No ADRs foundsrc/main.rs:1

What to do

  1. Resolve the 1 No ADRs found finding(s) in ADR Quality — start with main.rs. — One of this dimension's main actionable groups (1 recommendation-level).

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

D24 · Comment Value10.0 9.9 / 10Exemplary○ Nothing flagged

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

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

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

0 of 68 judged comments only repeat the code they sit on (0.0 %). 1 comment(s) in another language or script were not judged.

✓ On the Gold path — maintain.

Detailed fixes: d24_recommendation.md.

D26 · Project Cohesion6.0 / 10Adequate✓ Tool-verified

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

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

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

8 of 39 build units (Cargo, npm) flagged as possibly oversized/incoherent.

Projects may be oversized for their cohesion · ×8Cargo.toml:1

What to do

  1. Resolve the 8 Projects may be oversized for their cohesion finding(s) in Project Cohesion — start with Cargo.toml (8). — One of this dimension's main actionable groups (8 recommendation-level).

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

D28 · Secrets (history)0.0 / 10Critical✓ Tool-verified

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

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

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

10 finding(s): 0 critical, 10 high, 0 medium, 0 low. Remediation for historically-committed secrets is credential rotation — they remain in history regardless of later deletion.

REDACTED
REDACTED
REDACTED

What to do

  1. Resolve the 9 High secret finding(s) in Secrets (history) — start with REDACTED, REDACTED, REDACTED. — One of this dimension's main actionable groups (9 issue-level).
  2. Resolve the 1 REDACTED finding(s) in Secrets (history) — start with REDACTED. — One of this dimension's main actionable groups (1 issue-level).
  3. Resolve the 1 Rotate the exposed credentials finding(s) in Secrets (history). — One of this dimension's main actionable groups (1 recommendation-level).

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

D29 · Static Analysis (SAST)0.0 / 10Critical✓ Tool-verified

What it measures: Real static-analysis (SAST) findings — likely security bugs in the code, any language.

Method: Polyglot static analysis via semgrep across the repo using the pinned, image-baked p/security-audit + p/owasp-top-ten rulesets (no scan-time registry fetch); severity rules (ERROR/WARNING/INFO) map to a full-band severity-weighted score. Exhaustive, deterministic; degrades on parse failure.

Coverage: semgrep pattern rules over all files — exhaustive for the rule set, blind to classes of bug without a rule (clean = no rule matched).

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

104 finding(s): 0 critical, 100 high, 4 medium, 0 low. 44 unpinned-GitHub-Actions row(s) are reported here but scored by D36 (supply-chain provenance), which measures that posture as `pinned_actions` — one pinning decision is charged once, not once per lens. semgrep hit a parse error in 5 file(s) — `crates/ibcmd-filedb/src/windows_security.rs` (line 40, line 72, line 74, …), `docs/extensions/evidence/extension-version-20261001/own_load_version2_after_noop.json`, `src/server/mod.rs` (lines 643–654, line 678, line 696, …), `src/server/rpc.rs` (line 81), `src/source_audit.rs` (line 1711) — so no absence of findings in the named regions is evidence of anything; rows reported elsewhere in those files are real. Fix the syntax error (or exclude the file deliberately) and re-scan to cover them. Separately, one or more rules could not re-parse an embedded snippet in 3 file(s) (e.g. a workflow `run:` block read as shell). Those files WERE scanned and their other rows are unaffected; only those rules' view of those snippets is missing.

REDACTED
REDACTED
REDACTED
REDACTED
REDACTED

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

What to do

  1. Resolve the 54 REDACTED finding(s) in Static Analysis (SAST) — start with REDACTED (9), REDACTED (6), REDACTED (6). — One of this dimension's main actionable groups (54 issue-level).
  2. Resolve the 1 REDACTED finding(s) in Static Analysis (SAST) — start with REDACTED. — One of this dimension's main actionable groups (1 issue-level).
  3. No action in Static Analysis (SAST) — all 44 REDACTED finding(s) are reported here at file:line but scored by D36 (supply-chain provenance), so none is charged to this dimension. — One of this dimension's main actionable groups (44 issue-level, 0 of them charged here).

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

D30 · Dependency Vulnerabilities7.3 / 10Adequategated by 1 critical finding✓ Tool-verified

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

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

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

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

REDACTED
REDACTED
REDACTED
REDACTED

What to do

  1. Resolve the 1 High CVE finding(s) in Dependency Vulnerabilities — start with REDACTED. — One of this dimension's main actionable groups (1 issue-level).
  2. Resolve the 4 Medium advisory (unsound) finding(s) in Dependency Vulnerabilities — start with REDACTED (4). — One of this dimension's main actionable groups (4 warning-level).
  3. Resolve the 4 Medium vulnerability finding(s) in Dependency Vulnerabilities — start with REDACTED (4). — One of this dimension's main actionable groups (4 warning-level).

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

D34 · Knowledge Freshness10.0 / 10Exemplary✓ Tool-verified

What it measures: Whether anyone still has living knowledge of each file, or it has been orphaned — last understood long ago by someone now gone quiet. The sibling of the bus factor: D16 asks who owns it, D34 asks whether anyone still knows it.

Method: File orphaning as total living-knowledge decay below one focused-commit's worth within a year, computed per-file from the D16 decay model. Exhaustive, deterministic over fixed history.

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

Every significant source file has living knowledge — recently and meaningfully worked. Counted over 669 of the 854 production source files in this repository: the rest are under the ~2,400-byte size floor this dimension measures over.

✓ On the Gold path — maintain.

Detailed fixes: d34_recommendation.md.

D35 · Change Coupling9.8 / 10Stronggated by 7 serious findings✓ Tool-verified

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

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

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

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

Strongest change-coupling: config.ts↔rpc.ts 80%; infobase_oracle.rs↔mssql_apply.rs 64%; parse.rs↔infobase_oracle.rs 57%

Change coupling: config.ts ↔ rpc.ts · ×6editors/vscode/src/config.ts:1
Change-coupling hub: help.rs → cli.rs, infobase.rs, infobase_oracle.rssrc/dropin/help.rs

What to do

  1. Resolve the 6 Change coupling finding(s) in Change Coupling — start with dcs.rs (2), config.ts, infobase_oracle.rs. — One of this dimension's main actionable groups (6 warning-level).
  2. Resolve the 1 Change-coupling hub finding(s) in Change Coupling — start with help.rs. — One of this dimension's main actionable groups (1 warning-level).

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

D36 · Supply-chain Provenance & Signing2.5 / 10Weak✓ Tool-verified

What it measures: Whether the build pipeline provides supply-chain integrity — generated provenance/attestation, signed artifacts (cosign/sigstore), an SBOM, and pinned build actions. Presence of the configuration, not a runtime guarantee.

Method: Supply-chain provenance/signing read deterministically from CI/build config (.github/workflows, .gitlab-ci.yml, azure-pipelines, Jenkinsfile, .circleci) + the release surface: four signals — generated provenance/attestation (SLSA/in-toto/actions-attest), artifact signing (cosign/sigstore/gitsign), an SBOM (syft/sbom-action/*.spdx.json/*.cdx.json), and SHA-pinned build actions — scored 10·present/denom. NotApplicable without a build pipeline. Detects configuration presence, not runtime enforcement.

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

1/4 supply-chain integrity signals present (provenance, signing, SBOM, pinned actions).

REDACTED
REDACTED
REDACTED
REDACTED
REDACTED

What to do

  1. Resolve the 1 REDACTED finding(s) in Supply-chain Provenance & Signing. — One of this dimension's main actionable groups (1 warning-level).
  2. Resolve the 1 REDACTED finding(s) in Supply-chain Provenance & Signing — start with REDACTED. — One of this dimension's main actionable groups (1 warning-level).
  3. Resolve the 1 REDACTED finding(s) in Supply-chain Provenance & Signing. — One of this dimension's main actionable groups (1 recommendation-level).

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

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

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

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

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

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

✓ On the Gold path — maintain.

Detailed fixes: d43_recommendation.md.

D44 · Platform End-of-Life6.0 / 10Adequate✓ Tool-verified

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

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

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

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

End-of-life runtime: Rust 1.95rust-toolchain.toml:1

What to do

  1. Resolve the 1 End-of-life runtime finding(s) in Platform End-of-Life — start with rust-toolchain.toml. — One of this dimension's main actionable groups (1 warning-level).

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

Frontend & cross-cutting dimensions

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

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

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

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

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

AX3 · Project dependency cycles10.0 / 10Exemplary✓ Tool-verified

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

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

AX4 · Dependency direction10.0 / 10Exemplary✓ Tool-verified

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

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

AX8 · Test isolation5.0 / 10Adequate✓ Tool-verified

Other · Architecture — Whether production projects stay free of references to test projects — tests may depend on production, never the reverse.

Method: Csproj graph: each production project checked for references to test projects (identified by test-framework presence, not name). Zero violations is clean. Deterministic.

  • `ibcmd-dump` (production) references the test project `ibcmd-platform-spec`. Production must never depend on test code — it pulls a unit-test framework and test fixtures into the shipped product and inverts the only correct direction (tests depend on production, never the reverse). Move any shared helper into a production support library, or invert the reference.
  • `ibcmd-rs` (production) references the test project `ibcmd-platform-spec`. Production must never depend on test code — it pulls a unit-test framework and test fixtures into the shipped product and inverts the only correct direction (tests depend on production, never the reverse). Move any shared helper into a production support library, or invert the reference.

What to do

  • Remove every production → test project reference: extract any shared test helper into a production support library (which the tests reference), or invert the dependency so the test project depends on production — not the reverse.
AX9 · CQS / query purity10.0 / 10Exemplary✓ Tool-verified

Other · Architecture — Whether read (query) handlers stay side-effect-free — a query that writes persistent state or raises events breaks CQS and makes reads unsafe to retry, cache, or route to a read replica.

Method: Roslyn scan: CQRS handlers classified query-vs-command by interface (IQueryHandler/ICommandHandler/IRequestHandler<TQuery,TResult>) and name convention (*Query/Get*/Find* vs *Command); each query handler's body checked for persistent-state writes (SaveChanges/repository Add-Update) or event publishes by resolved invocation. Deterministic, type-level, exhaustive over the detected handlers.

Coverage: Population: CQRS handlers identified by IQueryHandler/ICommandHandler/IRequestHandler interface + *Query/Get*/Find*/*Command NAME convention; query purity then checked exhaustively within that set — a query handler using neither convention is invisible, and mutation is a resolved persistence/publish CALL, not full dataflow.

C1 · Data Protection0.0 / 10Critical✓ Tool-verified

Other · Security — Whether sensitive data is encrypted at rest and in transit and keys are vaulted.

Method: Roslyn plus filesystem scan: encryption presence (EF ColumnEncryption, key-vault references, HTTPS enforcement) and key-derivation KDF detection. Deterministic.

  • No encryption usage (RustCrypto's aes-gcm/chacha20poly1305 encrypting, ring or aws-lc-rs aead sealing, orion, libsodium's secretbox, openssl symm, age, SQLCipher keyed by PRAGMA key, pgcrypto, MongoDB client-side field-level encryption, the OS keyring) was found, and this repository persists personal data in the model cited here — sensitive data at rest may be unprotected. If TDE/KMS/vault is delegated to infrastructure, ignore. — docs/apply/evidence/restructuring/a2-structure-statements.sql:249

What to do

  • Encrypt sensitive data at rest (encrypt the fields with aes-gcm or chacha20poly1305 before they are written, or open the store encrypted — SQLCipher for rusqlite/sqlx, MongoDB CSFLE) and manage keys in a vault (AWS KMS / Secrets Manager through aws-sdk-kms, GCP KMS / REDACTED Manager, Azure Key Vault, HashiCorp Vault through vaultrs). Skip if delegated to infra (Postgres TDE, KMS, etc.).
  • Enforce HTTPS on the server that receives this data: terminate TLS in it (axum-server/actix bind_rustls, tonic ServerTlsConfig, a tokio-rustls acceptor) and send Strict-Transport-Security, or run it behind a TLS-terminating proxy, so data in transit is always encrypted.
C3 · Audit Trail7.5 / 10Strong✓ Tool-verified

Other · Security — Whether changes to sensitive data are recorded (who, what, when) for compliance + incident response.

Method: Roslyn scan: audit-trail mechanism graded (SaveChanges interceptor/immutable AuditLog/[Audited] strong; bare IAuditable/AddAuditing weak). Deterministic.

  • An audit mechanism is present, but the trail is not yet complete — missing: a write-side hook every change flows through (a SeaORM ActiveModelBehavior hook or a database trigger recording each change, or an event-sourced store), per-entity coverage (an event-sourced aggregate, or a hook on each entity that needs a who-changed-what trail).

What to do

  • Back the audit convention with a structural mechanism: a SeaORM ActiveModelBehavior before_save/after_save hook or a database trigger writing each sensitive change to an audit-log table, with the acting user and time on every entry.
C4 · Data Retention6.5 / 10Adequate✓ Tool-verified

Other · Security — Whether data has a defined lifetime — retention periods, TTLs, cleanup jobs (storage limitation).

Method: Roslyn scan: retention/TTL configuration presence in schema; CascadeDelete detected but not scored as retention control. Deterministic, gated by PII presence.

  • A retention mechanism is present, but the data-lifecycle is not yet complete — missing: a scheduled purge / cleanup job (a scheduled task that deletes rows past their retention — diesel::delete(….filter(created_at.lt(cutoff))), purge_expired… / delete_old…), a documented retention period / data-expiry.

What to do

  • Complete the data-lifecycle story: an expiry limit (a declared maximum age for the stored data — a retention-age setting, or a store-level TTL where your storage offers one), a scheduled purge/cleanup job that enforces it, and a documented retention period covering the personal data.
GD1 · Unfinished & placeholder code10.0 / 10Exemplary○ Nothing flagged

Other · Code Health — Unreviewed-generation residue in this repository's Rust: functions whose whole body is still `todo!()`/`unimplemented!()` or only panics with a "not implemented" message, and placeholder text (lorem ipsum, changeme/replace_me…) left in strings of non-test, non-generated code. Scored as a quality signature, never as a claim about authorship.

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

IC1 · Incompleteness & stubs6.5 / 10Adequate✓ Tool-verified

Other · Code Health — Unfinished work detected by code SHAPE, not keywords, in this repository's Rust: functions whose body is `todo!()`/`unimplemented!()` or only panics with a "not implemented" message, match arms and branches left as `todo!()`, functions that take inputs and return a constant (`Ok(())`, `None`, `Default::default()`, an empty `Vec`) or do nothing, and impls most of whose methods are holes.

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

  • `require_no_unfinished_operation` does real work, but one of its branches is `Err` with a "not implemented" message — a case that was never written, and a panic the first time it is reached. Implement the case, or return an error that says why it is not handled. — crates/ibcmd-config-apply/src/mssql_config_apply/mod.rs:564
  • `note_compatibility` takes parameters but its body is empty — it accepts inputs and does nothing. Either implement it or remove it. — crates/ibcmd-dump/src/mssql_dump/extension/mod.rs:477
  • `note_indexes` takes parameters but its body is empty — it accepts inputs and does nothing. Either implement it or remove it. — crates/ibcmd-dump/src/mssql_dump/extension/mod.rs:486
  • `parse_metadata_type_pattern_element` does real work, but one of its branches is `anyhow!` with a "not implemented" message — a case that was never written, and a panic the first time it is reached. Implement the case, or return an error that says why it is not handled. (×2) — crates/ibcmd-form-writer/src/lib.rs:23530, crates/ibcmd-form-writer/src/lib.rs:23541
  • `parse_metadata_type_pattern_element` does real work, but one of its branches is `Err` with a "not implemented" message — a case that was never written, and a panic the first time it is reached. Implement the case, or return an error that says why it is not handled. — crates/ibcmd-form-writer/src/lib.rs:23559
  • `set_always_used_constants_source` takes parameters but its body is empty — it accepts inputs and does nothing. Either implement it or remove it. — crates/ibcmd-metadata-blob/src/lib.rs:2297
  • `parse_common_command_picture` does real work, but one of its branches is `Err` with a "not implemented" message — a case that was never written, and a panic the first time it is reached. Implement the case, or return an error that says why it is not handled. — crates/ibcmd-metadata-blob/src/lib.rs:6942
  • `function_element` does real work, but one of its branches is `bail!` with a "not implemented" message — a case that was never written, and a panic the first time it is reached. Implement the case, or return an error that says why it is not handled. — crates/ibcmd-metadata-model/src/metadata_model/external_data_source.rs:326
  • `push_xml_element_text` takes parameters but its body is empty — it accepts inputs and does nothing. Either implement it or remove it. — crates/ibcmd-moxel/src/lib.rs:90
  • `encode_business_object` does real work, but one of its branches is `Err` with a "not implemented" message — a case that was never written, and a panic the first time it is reached. Implement the case, or return an error that says why it is not handled. — crates/ibcmd-xml/src/metadata/business_objects.rs:1240
  • `encode_common_object` does real work, but one of its branches is `Err` with a "not implemented" message — a case that was never written, and a panic the first time it is reached. Implement the case, or return an error that says why it is not handled. — crates/ibcmd-xml/src/metadata/common_objects.rs:422
  • `encode_functional_option` does real work, but one of its branches is `Err` with a "not implemented" message — a case that was never written, and a panic the first time it is reached. Implement the case, or return an error that says why it is not handled. — crates/ibcmd-xml/src/metadata/functional_option.rs:352
  • `encode_functional_options_parameter` does real work, but one of its branches is `Err` with a "not implemented" message — a case that was never written, and a panic the first time it is reached. Implement the case, or return an error that says why it is not handled. — crates/ibcmd-xml/src/metadata/functional_options_parameter.rs:338
  • `encode_hierarchical_object` does real work, but one of its branches is `Err` with a "not implemented" message — a case that was never written, and a panic the first time it is reached. Implement the case, or return an error that says why it is not handled. — crates/ibcmd-xml/src/metadata/hierarchical_objects.rs:840
  • `encode_register_object` does real work, but one of its branches is `Err` with a "not implemented" message — a case that was never written, and a panic the first time it is reached. Implement the case, or return an error that says why it is not handled. — crates/ibcmd-xml/src/metadata/register_objects.rs:1027
  • `encode_scheduled_job` does real work, but one of its branches is `Err` with a "not implemented" message — a case that was never written, and a panic the first time it is reached. Implement the case, or return an error that says why it is not handled. — crates/ibcmd-xml/src/metadata/services.rs:2537
  • `encode_event_subscription` does real work, but one of its branches is `Err` with a "not implemented" message — a case that was never written, and a panic the first time it is reached. Implement the case, or return an error that says why it is not handled. — crates/ibcmd-xml/src/metadata/services.rs:2581
  • `encode_xdto_package` does real work, but one of its branches is `Err` with a "not implemented" message — a case that was never written, and a panic the first time it is reached. Implement the case, or return an error that says why it is not handled. — crates/ibcmd-xml/src/metadata/services.rs:2624
  • `encode_http_service` does real work, but one of its branches is `Err` with a "not implemented" message — a case that was never written, and a panic the first time it is reached. Implement the case, or return an error that says why it is not handled. — crates/ibcmd-xml/src/metadata/services.rs:2667
  • `encode_web_service` does real work, but one of its branches is `Err` with a "not implemented" message — a case that was never written, and a panic the first time it is reached. Implement the case, or return an error that says why it is not handled. — crates/ibcmd-xml/src/metadata/services.rs:2710
  • `encode_ws_reference` does real work, but one of its branches is `Err` with a "not implemented" message — a case that was never written, and a panic the first time it is reached. Implement the case, or return an error that says why it is not handled. — crates/ibcmd-xml/src/metadata/services.rs:2753
  • `encode_integration_service` does real work, but one of its branches is `Err` with a "not implemented" message — a case that was never written, and a panic the first time it is reached. Implement the case, or return an error that says why it is not handled. — crates/ibcmd-xml/src/metadata/services.rs:2797
  • `encode_type_pattern_family` does real work, but one of its branches is `Err` with a "not implemented" message — a case that was never written, and a panic the first time it is reached. Implement the case, or return an error that says why it is not handled. — crates/ibcmd-xml/src/metadata/session_parameter.rs:738
  • `encode_utility_object` does real work, but one of its branches is `Err` with a "not implemented" message — a case that was never written, and a panic the first time it is reached. Implement the case, or return an error that says why it is not handled. — crates/ibcmd-xml/src/metadata/utility_objects.rs:714
  • `rollback_extraction_output` takes parameters but its body is empty — it accepts inputs and does nothing. Either implement it or remove it. — src/commands/cf.rs:641
  • `export_config_policy` does real work, but one of its branches is `bail!` with a "not implemented" message — a case that was never written, and a panic the first time it is reached. Implement the case, or return an error that says why it is not handled. — src/infobase.rs:364
  • `info` does real work, but one of its branches is `bail!` with a "not implemented" message — a case that was never written, and a panic the first time it is reached. Implement the case, or return an error that says why it is not handled. — src/infobase/export_commands.rs:25
  • `objects` does real work, but one of its branches is `bail!` with a "not implemented" message — a case that was never written, and a panic the first time it is reached. Implement the case, or return an error that says why it is not handled. — src/infobase/export_commands.rs:218
  • `load_config_command` does real work, but one of its branches is `bail!` with a "not implemented" message — a case that was never written, and a panic the first time it is reached. Implement the case, or return an error that says why it is not handled. — src/mssql/cf_load_stage.rs:75

What to do

  • Finish or delete the unfinished stubs (functions that throw "not implemented", or whose body is empty or a bare constant) — they are dead surface that looks live.
M1 · Documentation (README)8.1 / 10Strong✓ Tool-verified

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

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

M2 · Architecture documentation5.0 / 10Adequate✓ Tool-verified

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

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

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

What to do

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

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

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

M4 · Documentation accuracy10.0 / 10Exemplary○ Nothing flagged

Maturity · Maturity — Whether the project's current-state documentation describes the code that exists.

Method: Every current-state document's checkable claims looked up in the tree (links, versions, and artefact counts an order of magnitude off), plus two README checks: an advertised infrastructure product with no footprint, and a module the CHANGELOG records as removed. Deterministic, no model. Advisory.

P1 · CI/CD gates10.0 / 10Exemplary○ Nothing flagged

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

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

P10 · Library API & versioning10.0 / 10Exemplary○ Nothing flagged

Readiness · Readiness — For a library: a deliberate (small) public API surface and explicit semantic versioning so consumers can depend on it safely.

Method: Roslyn scan: public API surface area and semantic-versioning markers (SemVer attributes, changelog entries) for libraries; off .NET, a library is the ecosystem's publication act (an npm package that is not private and names an entry point, a PyPI distribution with a build system, a Rust library crate, a Maven/Gradle module that publishes, a Go module with no package main, a gemspec, a Composer library, a SwiftPM library product, a pub.dev or Hex package), its surface is the share of types the language's code model records as public (Rust, Swift, Java, Kotlin, Go, Dart; not measured where the model records no type visibility or, as in TypeScript, only module-level export), and its version is read from the manifest, a semver CHANGELOG, release tooling or semver git tags. Exhaustive, deterministic.

P2 · Observability0.0 / 10Critical✓ Tool-verified

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

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

  • No logging call was found in the 736 Python, Rust, JavaScript/TypeScript production file(s) this check read across 42 module(s). Each was searched for its ecosystem's logging libraries (Python: logging, structlog, loguru; JavaScript/TypeScript: pino, winston, bunyan, log4js, loglevel, consola, the NestJS Logger; Rust: the log and tracing crates (info!/warn!/error!, #[instrument]), slog, env_logger) and for a call on a receiver named `log`/`logger` (or ending in `Logger`/`_logger`) with a level verb. It cannot see logging through a repo-local wrapper named otherwise, or in source it did not read — this is 'no logging found by this walk', not a verdict that nothing here logs. If it is right, production issues will be hard to diagnose.

What to do

  • Adopt `tracing` with `tracing-subscriber` (JSON output) and log at meaningful points in the binaries you run.
  • Add a health-check endpoint (a /health route on your axum/actix router) so orchestrators and load balancers can probe liveness/readiness.
P3 · Security & performance tooling5.0 / 10Adequate✓ Tool-verified

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

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

  • `editors/vscode/package.json` declares packages, and nothing in the repository keeps them current: no Dependabot or Renovate configuration that schedules updates, and no dependency-review gate on pull requests. A pinned dependency stays at the version it was added at until someone notices — including after an advisory is published against it. Add a `.github/dependabot.yml` with one `package-ecosystem` entry per ecosystem the tree uses (or an enabled `renovate.json`), and gate pull requests with `actions/dependency-review-action`. — editors/vscode/package.json:332

What to do

  • Enable Dependabot/Renovate or a dependency-review gate.
  • Add gitleaks/trufflehog in CI to block PRs that introduce committed secrets.
P4 · Deployment & Rollback7.0 / 10Strong✓ Tool-verified

Readiness · Readiness — Whether releases are automated and safely reversible (probes, rolling updates, approval gates) — from manifests/pipeline files, not the live environment.

Method: Filesystem scan: deployment manifests/IaC (K8s YAML, Helm, Terraform) for rolling updates, probes, approval gates, migration hooks. Exhaustive, deterministic.

P5 · DR & Backup4.0 / 10Weak✓ Tool-verified

Readiness · Readiness — Whether disaster recovery is planned and codified — backups, geo-recovery, RTO/RPO, persistence guarantees — from IaC + container manifests + docs, never the live cloud.

Method: Filesystem scan: disaster recovery, backup, geo-recovery, RTO/RPO, persistence guarantees from IaC, manifests, and docs. Exhaustive, deterministic, never a live environment.

What to do

  • Document RTO/RPO and a tested restore procedure (a backup config alone isn't disaster recovery).
P6 · Release Hygiene10.0 / 10Exemplary✓ Tool-verified

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

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

PF3 · Async & latency hygiene10.0 / 10Exemplary✓ Tool-verified

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

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

R1 · Type Safety3.4 / 10Weak✓ Tool-verified

React / JS · Code Health — How much of the frontend is typed TypeScript vs untyped JavaScript.

Method: Frontend file inventory: the share of typed TypeScript vs untyped JavaScript across the source tree. Deterministic, exhaustive over frontend files.

  • 15 typed · 29 plain JS — the untyped files are editors/vscode/scripts/build.cjs, editors/vscode/scripts/python.cjs, editors/vscode/test/apply.test.js, editors/vscode/test/configuration-tree.test.js, editors/vscode/test/connection.test.js, editors/vscode/test/core.test.js (+23 more).
R10 · Code Duplication8.0 / 10Strong✓ Tool-verified

React / JS · Code Health — The share of the scored frontend lines inside a near-exact copy-pasted block of substantial extent (the D4 clone algorithm over JS/TS tokens, D-386; each line once, 10 at none and 0 at a quarter of the lines, as D4): a block is reported only where its copies still agree on most of their own identifiers and literals, or were renamed as they were pasted but kept most of their constants, and where the copies carry enough code to stand on their own or the copied extent reaches 30 lines — so a re-implementation sharing neither names nor values, and a small pasted declaration, are both found and deliberately not reported, and a clean R10 is not a claim that nothing was copied.

Method: Near-exact copy-pasted blocks of substantial extent across the frontend (the D4 clone algorithm run over JS/TS tokens). Masking finds the candidates; a block is reported when its copies still agree on most of their own identifiers and literals, or when a renamed copy still agrees on most of its constants, AND the copies carry enough code to stand on their own — or when the copied extent reaches 30 lines. So a re-implementation sharing neither names nor values, and a small pasted declaration, are deliberately not counted. Scored on the share of the scored frontend lines inside a reported copy, on the same curve as D4. Deterministic.

  • editors/vscode/src/extension.ts:257 · editors/vscode/src/extension.ts:493 — the two spans are one implementation copied and then locally edited — 110 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's 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 — 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. — editors/vscode/src/extension.ts:257
  • editors/vscode/src/configuration-view.ts:32 · editors/vscode/src/database-commands.ts:28 — the two spans are one implementation copied and then locally edited — 77 tokens are still identical, in the same order in both files, with only local edits between them. The copies have already begun to drift, which is this row's 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 — 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. — editors/vscode/src/configuration-view.ts:32
  • editors/vscode/src/git-baseline.ts:10 · editors/vscode/src/object-export.ts:91 — the two spans are one implementation copied and then locally edited — 55 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's 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 — 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. — editors/vscode/src/git-baseline.ts:10
  • editors/vscode/src/configuration-view.ts:83 · editors/vscode/src/database-commands.ts:95 · editors/vscode/src/object-export.ts:203 — the 3 copies are spread across 3 files, and the CITED SPAN is not a self-contained block — it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead — the whole function, component or branch these lines sit in — and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported. — editors/vscode/src/configuration-view.ts:83
  • editors/vscode/src/extension.ts:362 · editors/vscode/src/extension.ts:517 — all 2 copies are in the same file, and the CITED SPAN is not a self-contained block — it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead — the whole function, component or branch these lines sit in — and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported. — editors/vscode/src/extension.ts:362
  • editors/vscode/src/object-export.ts:173 · editors/vscode/src/object-view.ts:164 — the two spans are one implementation copied and then locally edited — 67 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's 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 — 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. — editors/vscode/src/object-export.ts:173
  • editors/vscode/src/extension.ts:178 · editors/vscode/src/object-view.ts:190 — the two spans are one implementation copied and then locally edited — 59 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's 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 — 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. — editors/vscode/src/extension.ts:178

What to do

  • Act on each finding's own remediation rather than one rule: the move depends on what recurs. Where the copies are executable blocks, give the shared part one home and call it from each site; where they are declarations, a listing, a specialisation already delegating to its base, or one shape repeated per entity, there is no call site and the move is a shared type, a generated set or a factory — sometimes there is nothing to extract.
R2 · Cyclomatic Complexity7.2 / 10Strong✓ Tool-verified

React / JS · Code Health — Per-function cyclomatic/cognitive complexity from the token-level function scanner (D-386) — real branching, not a regex heuristic.

Method: Per-function cyclomatic/cognitive complexity from a token-level function scanner (real branching, not a regex heuristic), computed over every frontend function. Deterministic.

  • edit has cyclomatic complexity 43 and cognitive complexity 41; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth — arms side by side rather than stacked — and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes. — editors/vscode/src/extension.ts:697
  • (anonymous) has cyclomatic complexity 34 and cognitive complexity 44; 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 — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes. — editors/vscode/src/object-view.ts:196
  • (anonymous) has cyclomatic complexity 30 and cognitive complexity 72; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes. — editors/vscode/test/fake-host-server.js:18
  • importFiles has cyclomatic complexity 28 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 — arms side by side rather than stacked — and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes. — editors/vscode/src/extension.ts:253
  • editConfig has cyclomatic complexity 25 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 — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes. — editors/vscode/src/config.ts:24
  • run has cyclomatic complexity 21 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 — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes. — editors/vscode/test/host-suite.js:6
  • (anonymous) has cyclomatic complexity 21 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 — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes. — editors/vscode/src/object-export.ts:209
  • classifyVersioned has cyclomatic complexity 21 and cognitive complexity 10; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth — arms side by side rather than stacked — and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes. — editors/vscode/src/object-status.ts:48
  • runExport has cyclomatic complexity 19 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 — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes. — editors/vscode/src/extension.ts:426
  • switchTo has cyclomatic complexity 17 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 — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes. — editors/vscode/src/extension.ts:113
  • children has cyclomatic complexity 17 and cognitive complexity 16; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth — arms side by side rather than stacked — and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes. — editors/vscode/src/configuration-tree.ts:505
  • gitBaseline has cyclomatic complexity 16 and cognitive complexity 22; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes. — editors/vscode/src/git-baseline.ts:7
  • getTreeItem has cyclomatic complexity 15 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 — arms side by side rather than stacked — and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes. — editors/vscode/src/configuration-view.ts:207
  • differences has cyclomatic complexity 12 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 — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes. — editors/vscode/src/database-files.ts:134
  • ibcmd.refresh 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 — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes. — editors/vscode/src/extension.ts:652
  • (anonymous) has cyclomatic complexity 12 and cognitive complexity 15; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes. — editors/vscode/src/extension.ts:369
  • validatePlan 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 — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes. — editors/vscode/src/object-export.ts:143
  • contained has cyclomatic complexity 11 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 — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes. — editors/vscode/src/configuration-tree.ts:298
  • receive has cyclomatic complexity 11 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 — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes. — editors/vscode/src/rpc.ts:114
  • (anonymous) 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 — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes. — editors/vscode/test/fake-server.js:13
  • (anonymous) 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 — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes. — editors/vscode/src/extension.ts:184
  • walk 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 — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes. — editors/vscode/src/configuration-tree.ts:431
  • (anonymous) 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 — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes. — editors/vscode/src/object-view.ts:271
  • (anonymous) has cyclomatic complexity 11 and cognitive complexity 10; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth — arms side by side rather than stacked — and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes. (×2) — editors/vscode/src/configuration-tree.ts:670, editors/vscode/src/database-commands.ts:101
  • require has cyclomatic complexity 11 and cognitive complexity 10; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth — arms side by side rather than stacked — and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes. — editors/vscode/test/connection.test.js:154
R3 · Large Files5.3 / 10Adequate✓ Tool-verified

React / JS · Code Health — How many source files exceed the large-file threshold.

Method: Components/modules exceeding the large-file threshold, counted exhaustively across the frontend source tree. Deterministic.

  • editors/vscode/src/extension.ts has 928 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — editors/vscode/src/extension.ts:1
  • editors/vscode/src/configuration-tree.ts has 679 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — editors/vscode/src/configuration-tree.ts:1

What to do

  • Split each oversized file along the responsibilities already in it, into smaller focused modules in the same package.
R4 · Test Coverage10.0 / 10Exemplary✓ Tool-verified

React / JS · Readiness — Static test reachability (D-386): the share of production files reachable from any test via the import graph — measured without running anything.

Method: Static test reachability: the share of production files reachable from any test via the import graph — measured without running anything. Deterministic.

R5 · Dependency Freshness9.2 / 10Exemplary✓ Tool-verified

React / JS · Readiness — How outdated the npm dependencies are (a maturity signal). JS/npm CVEs are scored separately in D30 (JS/npm Dependency Vulnerabilities).

Method: npm dependency staleness from manifest/registry metadata (a maturity signal; JS/npm CVEs are scored separately in D30, which answers dependency vulnerabilities for every ecosystem). Deterministic.

R6 · Tooling10.0 / 10Exemplary✓ Tool-verified

React / JS · Readiness — Whether the project wires up test, lint and typecheck — detected from each package.json script's COMMAND (eslint / tsc / vitest / jest / playwright), not just its name, and corroborated against CI-workflow invocations so a tool run only in CI still counts.

Method: package.json scanned for test/lint/typecheck script wiring. Deterministic presence check.

R7 · Dead Code10.0 / 10Exemplary✓ Tool-verified

React / JS · Code Health — Files unreachable from every application/tooling/test entry point, and exports nothing imports (module-graph reachability, D-386).

Method: Dead code: files unreachable from every application/tooling/test entry point plus exports nothing imports, via module-graph reachability. Deterministic, exhaustive over the import graph.

R8 · Dependency Hygiene9.5 / 10Exemplary✓ Tool-verified

React / JS · Readiness — npm dependency truthfulness (D-386): unused dependencies, imports not declared anywhere, and type-/test-only packages shipped as production deps.

Method: npm dependency truthfulness: unused dependencies, imports declared nowhere, and type-/test-only packages shipped as production deps — from the manifest + import graph. Deterministic.

  • Declared in editors/vscode/package.json but never imported anywhere in that package or its workspace members — 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. — editors/vscode/package.json:342

What to do

  • Remove unused dependencies, declare unlisted imports explicitly, and demote type-/test-only packages to devDependencies.
R9 · Circular Imports10.0 / 10Exemplary✓ Tool-verified

React / JS · Architecture — Import cycles in the module graph (D-386) — files that can only be understood and changed together.

Method: Import cycles in the module graph, detected exhaustively over JS/TS imports (the same cycle detection as the .NET coupling dimension). Deterministic.

S1 · Web-Security Posture8.0 / 10Strong✓ Tool-verified

Other · Security — Read from this repository's Rust source: cryptographic hygiene (weak hash or cipher, key material fixed in the source) and outbound TLS (certificate validation, protocol version) — facts about code that hold whether or not it serves anything itself. This repository serves no HTTP of its own — no HTTP-server crate (actix-web, axum, Rocket, warp, poem, tide, salvo, tonic, a hyper server, …) among its Cargo manifests' run-time dependencies, and no server started in its production source — so HTTPS enforcement, HSTS, cookie flags and input validation are N/A here, as they are for a C# library or worker.

Method: Roslyn plus filesystem scan: HSTS/security headers, secure cookies, input validation, middleware order, weak crypto (MD5/SHA1/DES); HTTPS-metadata context-aware. On a repository with no .NET source it reads JavaScript/TypeScript, Dart, Ruby, Scala, Rust or Elixir source itself (test, vendored, generated and minified paths not) for the arms that hold whether or not the code serves HTTP: a weak hash or cipher, key material fixed in the source, a TLS client that accepts any certificate, and (JavaScript/TypeScript, Ruby, Scala, Rust and Elixir) an obsolete TLS version; the server controls are not assessed there, and a Dart, Ruby, Scala, Rust or Elixir repository that serves no HTTP of its own is N/A on them. Deterministic.

  • MD5/SHA1 is computed here, and both are collision-broken. If this digest protects anything — a signature, an integrity or tamper check, a credential, or any value an attacker can influence — that is a real weakness: use SHA-256+ (`sha2::Sha256::digest(…)`) 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 — a non-cryptographic hash such as xxhash or murmurhash says it in code — 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. (×15) — crates/ibcmd-dump/src/mssql_dump/cas.rs:95, crates/ibcmd-dump/src/mssql_dump/extension/mod.rs:671, crates/ibcmd-dump/src/mssql_dump/extension/mod.rs:761, …

What to do

  • Review each MD5/SHA1 use by what it protects: replace it with SHA-256+ (or a KDF for passwords) where the digest is security-relevant, and switch it to a non-cryptographic hash (xxhash, murmurhash) where it only derives an identifier such as a cache key. This repository constructs a collision-broken hash (MD5/SHA1) at 15 sites, not one: `crates/ibcmd-dump/src/mssql_dump/cas.rs:95` (`Sha1::digest`), `crates/ibcmd-dump/src/mssql_dump/extension/mod.rs:671` (`Sha1::digest`), `crates/ibcmd-dump/src/mssql_dump/extension/mod.rs:761` (`Sha1::digest`), `crates/ibcmd-dump/src/mssql_dump/refs.rs:4853` (`Sha1::digest`), `REDACTED:262` (`Sha1::digest`), `REDACTED:631` (`Sha1::digest`), `crates/ibcmd-postgres/src/lib.rs:150` (`md5::compute`), `crates/ibcmd-postgres/src/lib.rs:154` (`md5::compute`), and 7 further site(s). Each is a separate decision — fixing only the line this row cites leaves the others in place.
X1 · Async correctness10.0 / 10Exemplary○ Nothing flagged

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

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

X12 · Unreachable branch8.0 / 10Strong✓ Tool-verified

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

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

  • `Err(anyhow !("<{}> has no writer yet", item.tag))` follows `{ let record = native_table_addition(item, kind, data_paths, command_ids, ite…` (line 2562) in the same block, and control never passes that statement — it returns, breaks, continues, panics, exits or calls a function that never returns. This code cannot run for any input; rustc warns `unreachable_code` on it. Delete it, or move it before the statement that leaves if it was meant to run. — crates/ibcmd-form-writer/src/lib.rs:2579
  • `if let Some(reference) = object_refs.get(& uuid) && let Some(command_name) = …` follows `{ return Some(format !("Form.Item.{}.StandardCommand.{standard}", owner.name)…` (line 28890) in the same block, and control never passes that statement — it returns, breaks, continues, panics, exits or calls a function that never returns. This code cannot run for any input; rustc warns `unreachable_code` on it. Delete it, or move it before the statement that leaves if it was meant to run. — crates/ibcmd-form-body/src/form_body.rs:28896
  • `let record = split_1c_braced_fields(outer.get(1) ?.trim(), 0) ?;` follows `{ return None; }` (line 39494) in the same block, and control never passes that statement — it returns, breaks, continues, panics, exits or calls a function that never returns. This code cannot run for any input; rustc warns `unreachable_code` on it. Delete it, or move it before the statement that leaves if it was meant to run. — crates/ibcmd-form-body/src/form_body.rs:39497
  • `let result = Self { allocation : allocation.0, owner, group, };` follows `{ return Err(Error::Refused("invalid file owner/group/DACL descriptor".into()…` (line 147) in the same block, and control never passes that statement — it returns, breaks, continues, panics, exits or calls a function that never returns. This code cannot run for any input; rustc warns `unreachable_code` on it. Delete it, or move it before the statement that leaves if it was meant to run. — crates/ibcmd-filedb/src/windows_security.rs:152
  • `let path_end = index.checked_add(path_count) ?;` follows `{ return None; }` (line 24102) in the same block, and control never passes that statement — it returns, breaks, continues, panics, exits or calls a function that never returns. This code cannot run for any input; rustc warns `unreachable_code` on it. Delete it, or move it before the statement that leaves if it was meant to run. — crates/ibcmd-dump/src/mssql_dump/mod.rs:24105

What to do

  • Each finding names the span that makes the branch dead and the span it is dead because of. Confirm from the two, then delete the dead arm or fix the predicate that was meant to be reachable.
X13 · Undrained process stream10.0 / 10Exemplary○ Nothing flagged

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

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

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

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

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

X17 · Uncapped recursion over a caller-supplied document1.4 / 10Critical✓ Tool-verified

Other · Security — Whether a walk that recurses through a JSON/XML tree handed in by its caller bounds how deep it will go — an uncapped walk lets the document's nesting choose the stack depth, and the resulting StackOverflowException cannot be caught.

Method: Roslyn syntax + semantics: methods that take a JSON/XML document node and call themselves with a child of it, reachable from an externally-callable member of the same type that accepts a document, checked for any depth parameter, descent counter or threaded arithmetic anywhere in the walk. On a repository with no .NET source it reads TypeScript off the engine’s own token stream (test, vendored, generated and minified paths and `.d.ts` not) with the same rule: a function or method with a parameter typed as a document value — `unknown`, `any`, `object`, `Record<string, unknown|any>`, a JSON alias (`JsonValue`, `JSONObject`, …) or a DOM node global the file does not rebind — that calls itself (bare, or through `this` for a method, or hands itself to a call over the value as in `value.map(walk)`) with something it took out of that value and never through an ancestor accessor such as `closest()` or `parentElement`, that is exported or reached from an exported function (a public method of the same exported class) taking such a value, and that names no depth, level, nesting, recursion, remaining or budget anywhere and threads no `+`/`-` arithmetic through a self-call. Plain JavaScript is not read: with no annotation nothing tells a parsed document from a tree the code built itself. Deterministic, provable per finding. Advisory.

  • `children` is public and takes a `StoredConfiguration` as its receiver from its caller, and it calls itself at line 1072 with a piece of the document — and nowhere in the walk is a depth or nesting counter compared with a bound. The walk therefore spends one stack frame per LEVEL of the value it is handed, so the nesting of the caller's document — not this code — decides how deep the stack goes. When a Rust thread runs out of stack it is not unwound: the runtime reports the overflow and aborts the process, so `catch_unwind` does not stop it and every other request the process serves dies with it (spawned threads, a Tokio worker included, get 2 MiB by default). serde_json and serde_yaml stop parsing at 128 levels only on their default path; a value from `disable_recursion_limit`, from another format or parser, or built in code carries whatever nesting it was given. Thread a depth argument through `children` and reject the value past a fixed maximum, or rewrite the descent with an explicit stack. — src/stored_objects.rs:1072
  • `resolve` is public and takes a `StoredConfiguration` as its receiver from its caller, and it calls itself at line 1081 with a piece of the document — and nowhere in the walk is a depth or nesting counter compared with a bound. The walk therefore spends one stack frame per LEVEL of the value it is handed, so the nesting of the caller's document — not this code — decides how deep the stack goes. When a Rust thread runs out of stack it is not unwound: the runtime reports the overflow and aborts the process, so `catch_unwind` does not stop it and every other request the process serves dies with it (spawned threads, a Tokio worker included, get 2 MiB by default). serde_json and serde_yaml stop parsing at 128 levels only on their default path; a value from `disable_recursion_limit`, from another format or parser, or built in code carries whatever nesting it was given. Thread a depth argument through `resolve` and reject the value past a fixed maximum, or rewrite the descent with an explicit stack. — src/stored_objects.rs:1081
  • `status_with_versions` is public and takes a `StoredConfiguration` as its receiver from its caller, and it calls itself at line 1327 with a piece of the document — and nowhere in the walk is a depth or nesting counter compared with a bound. The walk therefore spends one stack frame per LEVEL of the value it is handed, so the nesting of the caller's document — not this code — decides how deep the stack goes. When a Rust thread runs out of stack it is not unwound: the runtime reports the overflow and aborts the process, so `catch_unwind` does not stop it and every other request the process serves dies with it (spawned threads, a Tokio worker included, get 2 MiB by default). serde_json and serde_yaml stop parsing at 128 levels only on their default path; a value from `disable_recursion_limit`, from another format or parser, or built in code carries whatever nesting it was given. Thread a depth argument through `status_with_versions` and reject the value past a fixed maximum, or rewrite the descent with an explicit stack. — src/stored_objects.rs:1327
  • `clone` is public and takes a `XmlElement` as its receiver from its caller, and it calls itself at line 186 with a piece of the document — and nowhere in the walk is a depth or nesting counter compared with a bound. The walk therefore spends one stack frame per LEVEL of the value it is handed, so the nesting of the caller's document — not this code — decides how deep the stack goes. When a Rust thread runs out of stack it is not unwound: the runtime reports the overflow and aborts the process, so `catch_unwind` does not stop it and every other request the process serves dies with it (spawned threads, a Tokio worker included, get 2 MiB by default). serde_json and serde_yaml stop parsing at 128 levels only on their default path; a value from `disable_recursion_limit`, from another format or parser, or built in code carries whatever nesting it was given. Thread a depth argument through `clone` and reject the value past a fixed maximum, or rewrite the descent with an explicit stack. — crates/ibcmd-xml/src/node.rs:186
  • `node_output_len` is public and takes `node: &XmlNode` from its caller, and it recurses at line 375 through `element_output_len` and back with a piece of the document (and at line 440) — and nowhere in the walk is a depth or nesting counter compared with a bound. The walk therefore spends one stack frame per LEVEL of the value it is handed, so the nesting of the caller's document — not this code — decides how deep the stack goes. When a Rust thread runs out of stack it is not unwound: the runtime reports the overflow and aborts the process, so `catch_unwind` does not stop it and every other request the process serves dies with it (spawned threads, a Tokio worker included, get 2 MiB by default). serde_json and serde_yaml stop parsing at 128 levels only on their default path; a value from `disable_recursion_limit`, from another format or parser, or built in code carries whatever nesting it was given. Thread a depth argument through `node_output_len` and reject the value past a fixed maximum, or rewrite the descent with an explicit stack. — crates/ibcmd-xml/src/writer.rs:375
  • `node_to_vec_with_policy` is public, takes a document from its caller (line 103) and hands it to `element_out`, which recurses at line 665 through `node_out` and back with a piece of the document (and at line 745) — and nowhere in the walk is a depth or nesting counter compared with a bound. The walk therefore spends one stack frame per LEVEL of the value it is handed, so the nesting of the caller's document — not this code — decides how deep the stack goes. When a Rust thread runs out of stack it is not unwound: the runtime reports the overflow and aborts the process, so `catch_unwind` does not stop it and every other request the process serves dies with it (spawned threads, a Tokio worker included, get 2 MiB by default). serde_json and serde_yaml stop parsing at 128 levels only on their default path; a value from `disable_recursion_limit`, from another format or parser, or built in code carries whatever nesting it was given. Thread a depth argument through `element_out` and reject the value past a fixed maximum, or rewrite the descent with an explicit stack. — crates/ibcmd-xml/src/writer.rs:665
  • `collect_embedded_elements` is public, takes a document from its caller (line 697) and hands it to `visit`, which calls itself at line 726 with a piece of the document — and nowhere in the walk is a depth or nesting counter compared with a bound. The walk therefore spends one stack frame per LEVEL of the value it is handed, so the nesting of the caller's document — not this code — decides how deep the stack goes. When a Rust thread runs out of stack it is not unwound: the runtime reports the overflow and aborts the process, so `catch_unwind` does not stop it and every other request the process serves dies with it (spawned threads, a Tokio worker included, get 2 MiB by default). serde_json and serde_yaml stop parsing at 128 levels only on their default path; a value from `disable_recursion_limit`, from another format or parser, or built in code carries whatever nesting it was given. Thread a depth argument through `visit` and reject the value past a fixed maximum, or rewrite the descent with an explicit stack. — crates/ibcmd-xml/src/metadata/business_objects.rs:726
  • `serialize_row` is public, takes a document from its caller (line 90) and hands it to `write_node`, which calls itself at line 126 with a piece of the document — and nowhere in the walk is a depth or nesting counter compared with a bound. The walk therefore spends one stack frame per LEVEL of the value it is handed, so the nesting of the caller's document — not this code — decides how deep the stack goes. When a Rust thread runs out of stack it is not unwound: the runtime reports the overflow and aborts the process, so `catch_unwind` does not stop it and every other request the process serves dies with it (spawned threads, a Tokio worker included, get 2 MiB by default). serde_json and serde_yaml stop parsing at 128 levels only on their default path; a value from `disable_recursion_limit`, from another format or parser, or built in code carries whatever nesting it was given. Thread a depth argument through `write_node` and reject the value past a fixed maximum, or rewrite the descent with an explicit stack. — crates/ibcmd-restructure/src/brace.rs:126
  • `without_usual_group_behavior` is public and takes `items: &mut[FormChildItem]` from its caller, and it calls itself at line 1109 with a piece of the document — and nowhere in the walk is a depth or nesting counter compared with a bound. The walk therefore spends one stack frame per LEVEL of the value it is handed, so the nesting of the caller's document — not this code — decides how deep the stack goes. When a Rust thread runs out of stack it is not unwound: the runtime reports the overflow and aborts the process, so `catch_unwind` does not stop it and every other request the process serves dies with it (spawned threads, a Tokio worker included, get 2 MiB by default). serde_json and serde_yaml stop parsing at 128 levels only on their default path; a value from `disable_recursion_limit`, from another format or parser, or built in code carries whatever nesting it was given. Thread a depth argument through `without_usual_group_behavior` and reject the value past a fixed maximum, or rewrite the descent with an explicit stack. — crates/ibcmd-form-body/src/form_body.rs:1109
  • `collect_opaque_choice_list_diagnostics` is public and takes `items: &[FormChildItem]` from its caller, and it calls itself at line 1236 with a piece of the document — and nowhere in the walk is a depth or nesting counter compared with a bound. The walk therefore spends one stack frame per LEVEL of the value it is handed, so the nesting of the caller's document — not this code — decides how deep the stack goes. When a Rust thread runs out of stack it is not unwound: the runtime reports the overflow and aborts the process, so `catch_unwind` does not stop it and every other request the process serves dies with it (spawned threads, a Tokio worker included, get 2 MiB by default). serde_json and serde_yaml stop parsing at 128 levels only on their default path; a value from `disable_recursion_limit`, from another format or parser, or built in code carries whatever nesting it was given. Thread a depth argument through `collect_opaque_choice_list_diagnostics` and reject the value past a fixed maximum, or rewrite the descent with an explicit stack. — crates/ibcmd-form-body/src/form_body.rs:1236
  • `collect_opaque_choice_parameters_diagnostics` is public and takes `items: &[FormChildItem]` from its caller, and it calls itself at line 1302 with a piece of the document — and nowhere in the walk is a depth or nesting counter compared with a bound. The walk therefore spends one stack frame per LEVEL of the value it is handed, so the nesting of the caller's document — not this code — decides how deep the stack goes. When a Rust thread runs out of stack it is not unwound: the runtime reports the overflow and aborts the process, so `catch_unwind` does not stop it and every other request the process serves dies with it (spawned threads, a Tokio worker included, get 2 MiB by default). serde_json and serde_yaml stop parsing at 128 levels only on their default path; a value from `disable_recursion_limit`, from another format or parser, or built in code carries whatever nesting it was given. Thread a depth argument through `collect_opaque_choice_parameters_diagnostics` and reject the value past a fixed maximum, or rewrite the descent with an explicit stack. — crates/ibcmd-form-body/src/form_body.rs:1302
  • `record_complete_table_schema_events` is public, takes a document from its caller (line 10753) and hands it to `visit`, which calls itself at line 2412 with a piece of the document (and at line 2434, line 10845) — and nowhere in the walk is a depth or nesting counter compared with a bound. The walk therefore spends one stack frame per LEVEL of the value it is handed, so the nesting of the caller's document — not this code — decides how deep the stack goes. When a Rust thread runs out of stack it is not unwound: the runtime reports the overflow and aborts the process, so `catch_unwind` does not stop it and every other request the process serves dies with it (spawned threads, a Tokio worker included, get 2 MiB by default). serde_json and serde_yaml stop parsing at 128 levels only on their default path; a value from `disable_recursion_limit`, from another format or parser, or built in code carries whatever nesting it was given. Thread a depth argument through `visit` and reject the value past a fixed maximum, or rewrite the descent with an explicit stack. — crates/ibcmd-form-body/src/form_body.rs:2412
  • `record_complete_table_schema_events` is public, takes a document from its caller (line 10753) and hands it to `count_tables`, which calls itself at line 10774 with a piece of the document — and nowhere in the walk is a depth or nesting counter compared with a bound. The walk therefore spends one stack frame per LEVEL of the value it is handed, so the nesting of the caller's document — not this code — decides how deep the stack goes. When a Rust thread runs out of stack it is not unwound: the runtime reports the overflow and aborts the process, so `catch_unwind` does not stop it and every other request the process serves dies with it (spawned threads, a Tokio worker included, get 2 MiB by default). serde_json and serde_yaml stop parsing at 128 levels only on their default path; a value from `disable_recursion_limit`, from another format or parser, or built in code carries whatever nesting it was given. Thread a depth argument through `count_tables` and reject the value past a fixed maximum, or rewrite the descent with an explicit stack. — crates/ibcmd-form-body/src/form_body.rs:10774
  • `apply_form_table_user_settings_groups` is public and takes `items: &mut[FormChildItem]` from its caller, and it calls itself at line 21557 with a piece of the document — and nowhere in the walk is a depth or nesting counter compared with a bound. The walk therefore spends one stack frame per LEVEL of the value it is handed, so the nesting of the caller's document — not this code — decides how deep the stack goes. When a Rust thread runs out of stack it is not unwound: the runtime reports the overflow and aborts the process, so `catch_unwind` does not stop it and every other request the process serves dies with it (spawned threads, a Tokio worker included, get 2 MiB by default). serde_json and serde_yaml stop parsing at 128 levels only on their default path; a value from `disable_recursion_limit`, from another format or parser, or built in code carries whatever nesting it was given. Thread a depth argument through `apply_form_table_user_settings_groups` and reject the value past a fixed maximum, or rewrite the descent with an explicit stack. — crates/ibcmd-form-body/src/form_body.rs:21557
  • `format_form_child_items_xml` is public and takes `items: &[FormChildItem]` from its caller, and it recurses at line 32246 through `format_form_context_menu_xml`, `format_form_child_item_xml` and back with a piece of the document (and at line 33256, line 33314, line 36158, line 36219, line 36222, line 36231, line 36248, line 36259, line 36271, line 37489) — and nowhere in the walk is a depth or nesting counter compared with a bound. The walk therefore spends one stack frame per LEVEL of the value it is handed, so the nesting of the caller's document — not this code — decides how deep the stack goes. When a Rust thread runs out of stack it is not unwound: the runtime reports the overflow and aborts the process, so `catch_unwind` does not stop it and every other request the process serves dies with it (spawned threads, a Tokio worker included, get 2 MiB by default). serde_json and serde_yaml stop parsing at 128 levels only on their default path; a value from `disable_recursion_limit`, from another format or parser, or built in code carries whatever nesting it was given. Thread a depth argument through `format_form_child_items_xml` and reject the value past a fixed maximum, or rewrite the descent with an explicit stack. — crates/ibcmd-form-body/src/form_body.rs:32246
  • `mark` is public, takes a document from its caller (line 207) and hands it to `mark_items`, which calls itself at line 238 with a piece of the document — and nowhere in the walk is a depth or nesting counter compared with a bound. The walk therefore spends one stack frame per LEVEL of the value it is handed, so the nesting of the caller's document — not this code — decides how deep the stack goes. When a Rust thread runs out of stack it is not unwound: the runtime reports the overflow and aborts the process, so `catch_unwind` does not stop it and every other request the process serves dies with it (spawned threads, a Tokio worker included, get 2 MiB by default). serde_json and serde_yaml stop parsing at 128 levels only on their default path; a value from `disable_recursion_limit`, from another format or parser, or built in code carries whatever nesting it was given. Thread a depth argument through `mark_items` and reject the value past a fixed maximum, or rewrite the descent with an explicit stack. — crates/ibcmd-form-body/src/form_extension.rs:238
  • `to_text` is public, takes a document from its caller (line 64) and hands it to `emit`, which calls itself at line 79 with a piece of the document — and nowhere in the walk is a depth or nesting counter compared with a bound. The walk therefore spends one stack frame per LEVEL of the value it is handed, so the nesting of the caller's document — not this code — decides how deep the stack goes. When a Rust thread runs out of stack it is not unwound: the runtime reports the overflow and aborts the process, so `catch_unwind` does not stop it and every other request the process serves dies with it (spawned threads, a Tokio worker included, get 2 MiB by default). serde_json and serde_yaml stop parsing at 128 levels only on their default path; a value from `disable_recursion_limit`, from another format or parser, or built in code carries whatever nesting it was given. Thread a depth argument through `emit` and reject the value past a fixed maximum, or rewrite the descent with an explicit stack. — crates/ibcmd-form-body/src/layout_8_5_1.rs:79
  • `push_client_application_interface_group_xml` is public and takes `group: &ClientApplicationInterfaceGroup` from its caller, and it recurses at line 1114 through `push_client_application_interface_node_xml` and back with a piece of the document (and at line 1087) — and nowhere in the walk is a depth or nesting counter compared with a bound. The walk therefore spends one stack frame per LEVEL of the value it is handed, so the nesting of the caller's document — not this code — decides how deep the stack goes. When a Rust thread runs out of stack it is not unwound: the runtime reports the overflow and aborts the process, so `catch_unwind` does not stop it and every other request the process serves dies with it (spawned threads, a Tokio worker included, get 2 MiB by default). serde_json and serde_yaml stop parsing at 128 levels only on their default path; a value from `disable_recursion_limit`, from another format or parser, or built in code carries whatever nesting it was given. Thread a depth argument through `push_client_application_interface_group_xml` and reject the value past a fixed maximum, or rewrite the descent with an explicit stack. — crates/ibcmd-dump/src/mssql_dump/command_interface.rs:1114
  • `insert_predefined_item_references` is public and takes `items: &[PredefinedItem]` from its caller, and it calls itself at line 4203 with a piece of the document — and nowhere in the walk is a depth or nesting counter compared with a bound. The walk therefore spends one stack frame per LEVEL of the value it is handed, so the nesting of the caller's document — not this code — decides how deep the stack goes. When a Rust thread runs out of stack it is not unwound: the runtime reports the overflow and aborts the process, so `catch_unwind` does not stop it and every other request the process serves dies with it (spawned threads, a Tokio worker included, get 2 MiB by default). serde_json and serde_yaml stop parsing at 128 levels only on their default path; a value from `disable_recursion_limit`, from another format or parser, or built in code carries whatever nesting it was given. Thread a depth argument through `insert_predefined_item_references` and reject the value past a fixed maximum, or rewrite the descent with an explicit stack. — crates/ibcmd-dump/src/mssql_dump/source_assets.rs:4203
  • `push_predefined_item_xml` is public and takes `item: &PredefinedItem` from its caller, and it calls itself at line 5258 with a piece of the document — and nowhere in the walk is a depth or nesting counter compared with a bound. The walk therefore spends one stack frame per LEVEL of the value it is handed, so the nesting of the caller's document — not this code — decides how deep the stack goes. When a Rust thread runs out of stack it is not unwound: the runtime reports the overflow and aborts the process, so `catch_unwind` does not stop it and every other request the process serves dies with it (spawned threads, a Tokio worker included, get 2 MiB by default). serde_json and serde_yaml stop parsing at 128 levels only on their default path; a value from `disable_recursion_limit`, from another format or parser, or built in code carries whatever nesting it was given. Thread a depth argument through `push_predefined_item_xml` and reject the value past a fixed maximum, or rewrite the descent with an explicit stack. — crates/ibcmd-dump/src/mssql_dump/source_assets.rs:5258
  • `clone` is public and takes a `CanonicalValue` as its receiver from its caller, and it calls itself at line 595 with a piece of the document (and at line 596, line 597, line 598, line 599, line 600, line 602, line 611) — and nowhere in the walk is a depth or nesting counter compared with a bound. The walk therefore spends one stack frame per LEVEL of the value it is handed, so the nesting of the caller's document — not this code — decides how deep the stack goes. When a Rust thread runs out of stack it is not unwound: the runtime reports the overflow and aborts the process, so `catch_unwind` does not stop it and every other request the process serves dies with it (spawned threads, a Tokio worker included, get 2 MiB by default). serde_json and serde_yaml stop parsing at 128 levels only on their default path; a value from `disable_recursion_limit`, from another format or parser, or built in code carries whatever nesting it was given. Thread a depth argument through `clone` and reject the value past a fixed maximum, or rewrite the descent with an explicit stack. — crates/ibcmd-core/src/value.rs:595

What to do

  • Each finding names the externally-callable member that accepts the document and the self-call that descends, and states that no depth parameter or counter exists anywhere in the walk. Confirm from the two, then thread a depth argument through the walk and reject documents past a fixed maximum, or rewrite it with an explicit stack.
X18 · Disposal-pattern correctness6.5 / 10Adequate✓ Tool-verified

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

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

  • `writer` (line 38) is a `BufWriter` this function owns and never releases: no `flush()` (or `into_inner()`) on any path, and it is not handed on. Rust drops it at the end of the scope, and a buffered writer that is dropped flushes and throws the error away, so a failed write reports success. Release it where the work ends. — crates/ibcmd-edt/src/provenance.rs:38

What to do

  • Each finding names the value and the span that decides who owns it — the `new` that created it, or the constructor parameter that handed it over. Confirm ownership from that span, then make the disposal match it: release what this type created, leave what it was injected with to whoever created THAT, and drop a finalizer whose type holds nothing unmanaged to release.
X2 · Cancellation propagation8.8 / 10Exemplary✓ Tool-verified

Other · Code Health — Whether async functions that make a cancellable request accept or pass on an AbortSignal (adoption curve).

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

  • Only 4/5 async functions that make a cancellable request (fetch, axios, ky, ofetch, got, undici, node:http) accept an AbortSignal or pass one on, so a request keeps running after whatever wanted it has given up — a page navigated away from, an unmounted component, a timed-out job. Take a `signal` (or an options object that carries one) and hand it to the request; where nothing could ever cancel the call, omitting it is a deliberate choice — judge against how the function is used.
  • `nativeApply` holds an AbortSignal but calls `spawn(…)` without it, so its caller's cancellation never reaches that call and it runs to its end after whatever wanted it has given up. Hand the signal on: `spawn(…, { signal })`. — editors/vscode/src/apply.ts:75

What to do

  • Thread an AbortSignal through async functions that make requests, so the work stops when its caller gives up.
X21 · Side-effecting pattern guard10.0 / 10Exemplary○ Nothing flagged

Other · Code Health — Whether a `when` guard is free of side effects — a guard that increments a counter or assigns while deciding whether its arm matches applies that change during PATTERN MATCHING, on an arm that may not be selected, and skips it entirely when a short-circuit to its left answers first.

Method: Roslyn syntax: `when` guards on case labels and switch-expression arms, read for a mutation (`++`/`--`/assignment) sitting in a position the guard's own `&&`/`||`/`??`/`?:`/`?.` can skip. Deterministic, provable per finding. Advisory.

X25 · Inert configuration knob7.0 / 10Strong✓ Tool-verified

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

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

  • `IncrementalExportSummary.changed_entries` is offered as a configuration-file option, so whoever configures the program can set it — but no production code reads it. Every value supplied for it is silently ignored. Consult it where it was meant to take effect — or, if it genuinely does nothing, remove it (or mark it deprecated and say so in its documentation) so the configuration stops advertising a setting that changes nothing. — crates/ibcmd-dump/src/mssql_dump/incremental.rs:157
  • `IncrementalExportSummary.unchanged_entries` is offered as a configuration-file option, so whoever configures the program can set it — but no production code reads it. Every value supplied for it is silently ignored. Consult it where it was meant to take effect — or, if it genuinely does nothing, remove it (or mark it deprecated and say so in its documentation) so the configuration stops advertising a setting that changes nothing. — crates/ibcmd-dump/src/mssql_dump/incremental.rs:159
  • `IncrementalExportSummary.removed_entries` is offered as a configuration-file option, so whoever configures the program can set it — but no production code reads it. Every value supplied for it is silently ignored. Consult it where it was meant to take effect — or, if it genuinely does nothing, remove it (or mark it deprecated and say so in its documentation) so the configuration stops advertising a setting that changes nothing. — crates/ibcmd-dump/src/mssql_dump/incremental.rs:161
  • `IncrementalExportSummary.written_files` is offered as a configuration-file option, so whoever configures the program can set it — but no production code reads it. Every value supplied for it is silently ignored. Consult it where it was meant to take effect — or, if it genuinely does nothing, remove it (or mark it deprecated and say so in its documentation) so the configuration stops advertising a setting that changes nothing. — crates/ibcmd-dump/src/mssql_dump/incremental.rs:163
  • `SourceAssetCompletenessReport.diagnostic_clusters` is offered as a configuration-file option, so whoever configures the program can set it — but no production code reads it. A test asserts that it parses, which proves the key is read from the input, not that it does anything. Every value supplied for it is silently ignored. Consult it where it was meant to take effect — or, if it genuinely does nothing, remove it (or mark it deprecated and say so in its documentation) so the configuration stops advertising a setting that changes nothing. — crates/ibcmd-dump/src/mssql_dump/mod.rs:1457
  • `RootMetadataInventoryReport.misses_by_reason` is offered as a configuration-file option, so whoever configures the program can set it — but no production code reads it. Every value supplied for it is silently ignored. Consult it where it was meant to take effect — or, if it genuinely does nothing, remove it (or mark it deprecated and say so in its documentation) so the configuration stops advertising a setting that changes nothing. — crates/ibcmd-dump/src/mssql_dump/mod.rs:1771
  • `SourceAssetDiagnosticClusterReport.total_clusters` is offered as a configuration-file option, so whoever configures the program can set it — but no production code reads it. A test asserts that it parses, which proves the key is read from the input, not that it does anything. Every value supplied for it is silently ignored. Consult it where it was meant to take effect — or, if it genuinely does nothing, remove it (or mark it deprecated and say so in its documentation) so the configuration stops advertising a setting that changes nothing. — crates/ibcmd-dump/src/mssql_dump/source_asset_diagnostics.rs:12
  • `SourceAssetDiagnosticClusterReport.omitted_clusters` is offered as a configuration-file option, so whoever configures the program can set it — but no production code reads it. A test asserts that it parses, which proves the key is read from the input, not that it does anything. Every value supplied for it is silently ignored. Consult it where it was meant to take effect — or, if it genuinely does nothing, remove it (or mark it deprecated and say so in its documentation) so the configuration stops advertising a setting that changes nothing. — crates/ibcmd-dump/src/mssql_dump/source_asset_diagnostics.rs:13
  • `SourceAssetDiagnosticClusterReport.omitted_entries` is offered as a configuration-file option, so whoever configures the program can set it — but no production code reads it. A test asserts that it parses, which proves the key is read from the input, not that it does anything. Every value supplied for it is silently ignored. Consult it where it was meant to take effect — or, if it genuinely does nothing, remove it (or mark it deprecated and say so in its documentation) so the configuration stops advertising a setting that changes nothing. — crates/ibcmd-dump/src/mssql_dump/source_asset_diagnostics.rs:14
  • `SourceAssetDiagnosticClusterReport.clusters` is offered as a configuration-file option, so whoever configures the program can set it — but no production code reads it. A test asserts that it parses, which proves the key is read from the input, not that it does anything. Every value supplied for it is silently ignored. Consult it where it was meant to take effect — or, if it genuinely does nothing, remove it (or mark it deprecated and say so in its documentation) so the configuration stops advertising a setting that changes nothing. — crates/ibcmd-dump/src/mssql_dump/source_asset_diagnostics.rs:15
  • `DcsSchemaTemplateEnvelopeEvidenceFixture.extractor_identity` is offered as a configuration-file option, so whoever configures the program can set it — but no production code reads it. Every value supplied for it is silently ignored. Consult it where it was meant to take effect — or, if it genuinely does nothing, remove it (or mark it deprecated and say so in its documentation) so the configuration stops advertising a setting that changes nothing. — crates/ibcmd-schema/src/lib.rs:7121
  • `DcsSchemaTemplateEnvelopeEvidenceFixture.extractor_sha256` is offered as a configuration-file option, so whoever configures the program can set it — but no production code reads it. Every value supplied for it is silently ignored. Consult it where it was meant to take effect — or, if it genuinely does nothing, remove it (or mark it deprecated and say so in its documentation) so the configuration stops advertising a setting that changes nothing. — crates/ibcmd-schema/src/lib.rs:7122
  • `DcsSchemaTemplateEnvelopeEvidenceFixture.seed_sha256` is offered as a configuration-file option, so whoever configures the program can set it — but no production code reads it. Every value supplied for it is silently ignored. Consult it where it was meant to take effect — or, if it genuinely does nothing, remove it (or mark it deprecated and say so in its documentation) so the configuration stops advertising a setting that changes nothing. — crates/ibcmd-schema/src/lib.rs:7123
  • `DcsSchemaTemplateEnvelopeEvidenceFixture.round1_cf_sha256` is offered as a configuration-file option, so whoever configures the program can set it — but no production code reads it. Every value supplied for it is silently ignored. Consult it where it was meant to take effect — or, if it genuinely does nothing, remove it (or mark it deprecated and say so in its documentation) so the configuration stops advertising a setting that changes nothing. — crates/ibcmd-schema/src/lib.rs:7124
  • `DcsSchemaTemplateEnvelopeEvidenceFixture.round2_cf_sha256` is offered as a configuration-file option, so whoever configures the program can set it — but no production code reads it. Every value supplied for it is silently ignored. Consult it where it was meant to take effect — or, if it genuinely does nothing, remove it (or mark it deprecated and say so in its documentation) so the configuration stops advertising a setting that changes nothing. — crates/ibcmd-schema/src/lib.rs:7125
  • `DcsSchemaTemplateEnvelopeEvidenceFixture.round1_template_sha256` is offered as a configuration-file option, so whoever configures the program can set it — but no production code reads it. Every value supplied for it is silently ignored. Consult it where it was meant to take effect — or, if it genuinely does nothing, remove it (or mark it deprecated and say so in its documentation) so the configuration stops advertising a setting that changes nothing. — crates/ibcmd-schema/src/lib.rs:7126
  • `DcsSchemaTemplateEnvelopeEvidenceFixture.round2_template_sha256` is offered as a configuration-file option, so whoever configures the program can set it — but no production code reads it. Every value supplied for it is silently ignored. Consult it where it was meant to take effect — or, if it genuinely does nothing, remove it (or mark it deprecated and say so in its documentation) so the configuration stops advertising a setting that changes nothing. — crates/ibcmd-schema/src/lib.rs:7127
  • `DcsSchemaTemplateEnvelopeEvidenceFixture.round1_packed_sha256` is offered as a configuration-file option, so whoever configures the program can set it — but no production code reads it. Every value supplied for it is silently ignored. Consult it where it was meant to take effect — or, if it genuinely does nothing, remove it (or mark it deprecated and say so in its documentation) so the configuration stops advertising a setting that changes nothing. — crates/ibcmd-schema/src/lib.rs:7128
  • `DcsSchemaTemplateEnvelopeEvidenceFixture.round2_packed_sha256` is offered as a configuration-file option, so whoever configures the program can set it — but no production code reads it. Every value supplied for it is silently ignored. Consult it where it was meant to take effect — or, if it genuinely does nothing, remove it (or mark it deprecated and say so in its documentation) so the configuration stops advertising a setting that changes nothing. — crates/ibcmd-schema/src/lib.rs:7129
  • `DcsSchemaTemplateEnvelopeEvidenceFixture.round1_unpacked_sha256` is offered as a configuration-file option, so whoever configures the program can set it — but no production code reads it. Every value supplied for it is silently ignored. Consult it where it was meant to take effect — or, if it genuinely does nothing, remove it (or mark it deprecated and say so in its documentation) so the configuration stops advertising a setting that changes nothing. — crates/ibcmd-schema/src/lib.rs:7130
  • `DcsSchemaTemplateEnvelopeEvidenceFixture.round2_unpacked_sha256` is offered as a configuration-file option, so whoever configures the program can set it — but no production code reads it. Every value supplied for it is silently ignored. Consult it where it was meant to take effect — or, if it genuinely does nothing, remove it (or mark it deprecated and say so in its documentation) so the configuration stops advertising a setting that changes nothing. — crates/ibcmd-schema/src/lib.rs:7131
  • `DcsSchemaTemplateEnvelopeEvidenceFixture.configuration_encoded_sha256` is offered as a configuration-file option, so whoever configures the program can set it — but no production code reads it. Every value supplied for it is silently ignored. Consult it where it was meant to take effect — or, if it genuinely does nothing, remove it (or mark it deprecated and say so in its documentation) so the configuration stops advertising a setting that changes nothing. — crates/ibcmd-schema/src/lib.rs:7132
  • `DcsSchemaTemplateEnvelopeEvidenceFixture.configuration_decoded_sha256` is offered as a configuration-file option, so whoever configures the program can set it — but no production code reads it. Every value supplied for it is silently ignored. Consult it where it was meant to take effect — or, if it genuinely does nothing, remove it (or mark it deprecated and say so in its documentation) so the configuration stops advertising a setting that changes nothing. — crates/ibcmd-schema/src/lib.rs:7133
  • `DcsSchemaTemplateEnvelopeEvidenceFixture.raw_packed_encoded_sha256` is offered as a configuration-file option, so whoever configures the program can set it — but no production code reads it. Every value supplied for it is silently ignored. Consult it where it was meant to take effect — or, if it genuinely does nothing, remove it (or mark it deprecated and say so in its documentation) so the configuration stops advertising a setting that changes nothing. — crates/ibcmd-schema/src/lib.rs:7134
  • `DcsSchemaTemplateEnvelopeEvidenceFixture.raw_packed_decoded_sha256` is offered as a configuration-file option, so whoever configures the program can set it — but no production code reads it. Every value supplied for it is silently ignored. Consult it where it was meant to take effect — or, if it genuinely does nothing, remove it (or mark it deprecated and say so in its documentation) so the configuration stops advertising a setting that changes nothing. — crates/ibcmd-schema/src/lib.rs:7135
  • `DcsSchemaTemplateEnvelopeEvidenceFixture.raw_unpacked_encoded_sha256` is offered as a configuration-file option, so whoever configures the program can set it — but no production code reads it. Every value supplied for it is silently ignored. Consult it where it was meant to take effect — or, if it genuinely does nothing, remove it (or mark it deprecated and say so in its documentation) so the configuration stops advertising a setting that changes nothing. — crates/ibcmd-schema/src/lib.rs:7136
  • `DcsSchemaTemplateEnvelopeEvidenceFixture.raw_unpacked_decoded_sha256` is offered as a configuration-file option, so whoever configures the program can set it — but no production code reads it. Every value supplied for it is silently ignored. Consult it where it was meant to take effect — or, if it genuinely does nothing, remove it (or mark it deprecated and say so in its documentation) so the configuration stops advertising a setting that changes nothing. — crates/ibcmd-schema/src/lib.rs:7137
  • `DcsSchemaTemplateEnvelopeEvidenceFixture.native_xml_encoded_sha256` is offered as a configuration-file option, so whoever configures the program can set it — but no production code reads it. Every value supplied for it is silently ignored. Consult it where it was meant to take effect — or, if it genuinely does nothing, remove it (or mark it deprecated and say so in its documentation) so the configuration stops advertising a setting that changes nothing. — crates/ibcmd-schema/src/lib.rs:7138
  • `DcsSchemaTemplateEnvelopeEvidenceFixture.native_xml_decoded_sha256` is offered as a configuration-file option, so whoever configures the program can set it — but no production code reads it. Every value supplied for it is silently ignored. Consult it where it was meant to take effect — or, if it genuinely does nothing, remove it (or mark it deprecated and say so in its documentation) so the configuration stops advertising a setting that changes nothing. — crates/ibcmd-schema/src/lib.rs:7139
  • `DcsSchemaTemplateEnvelopeEvidencePolicy.settings_count_encoding` is offered as a configuration-file option, so whoever configures the program can set it — but no production code reads it. Every value supplied for it is silently ignored. Consult it where it was meant to take effect — or, if it genuinely does nothing, remove it (or mark it deprecated and say so in its documentation) so the configuration stops advertising a setting that changes nothing. — crates/ibcmd-schema/src/lib.rs:7156
  • `DcsSchemaTemplateEnvelopeEvidencePolicy.stored_length_encoding` is offered as a configuration-file option, so whoever configures the program can set it — but no production code reads it. Every value supplied for it is silently ignored. Consult it where it was meant to take effect — or, if it genuinely does nothing, remove it (or mark it deprecated and say so in its documentation) so the configuration stops advertising a setting that changes nothing. — crates/ibcmd-schema/src/lib.rs:7159
  • `DcsSchemaTemplateEnvelopeEvidencePolicy.stored_length_roles` is offered as a configuration-file option, so whoever configures the program can set it — but no production code reads it. Every value supplied for it is silently ignored. Consult it where it was meant to take effect — or, if it genuinely does nothing, remove it (or mark it deprecated and say so in its documentation) so the configuration stops advertising a setting that changes nothing. — crates/ibcmd-schema/src/lib.rs:7160
  • `DcsSchemaTemplateEnvelopeEvidencePolicy.stored_lengths_cover` is offered as a configuration-file option, so whoever configures the program can set it — but no production code reads it. Every value supplied for it is silently ignored. Consult it where it was meant to take effect — or, if it genuinely does nothing, remove it (or mark it deprecated and say so in its documentation) so the configuration stops advertising a setting that changes nothing. — crates/ibcmd-schema/src/lib.rs:7164
  • `DcsSchemaTemplateEnvelopeEvidencePolicy.terminal_document_framing` is offered as a configuration-file option, so whoever configures the program can set it — but no production code reads it. Every value supplied for it is silently ignored. Consult it where it was meant to take effect — or, if it genuinely does nothing, remove it (or mark it deprecated and say so in its documentation) so the configuration stops advertising a setting that changes nothing. — crates/ibcmd-schema/src/lib.rs:7165
  • `DcsSchemaTemplateEnvelopeEvidencePolicy.document_encoding` is offered as a configuration-file option, so whoever configures the program can set it — but no production code reads it. Every value supplied for it is silently ignored. Consult it where it was meant to take effect — or, if it genuinely does nothing, remove it (or mark it deprecated and say so in its documentation) so the configuration stops advertising a setting that changes nothing. — crates/ibcmd-schema/src/lib.rs:7166
  • `DcsSchemaTemplateEnvelopeEvidencePolicy.settings_binding` is offered as a configuration-file option, so whoever configures the program can set it — but no production code reads it. Every value supplied for it is silently ignored. Consult it where it was meant to take effect — or, if it genuinely does nothing, remove it (or mark it deprecated and say so in its documentation) so the configuration stops advertising a setting that changes nothing. — crates/ibcmd-schema/src/lib.rs:7167
  • `DcsSchemaTemplateEnvelopeEvidencePolicy.source_variant_placement` is offered as a configuration-file option, so whoever configures the program can set it — but no production code reads it. Every value supplied for it is silently ignored. Consult it where it was meant to take effect — or, if it genuinely does nothing, remove it (or mark it deprecated and say so in its documentation) so the configuration stops advertising a setting that changes nothing. — crates/ibcmd-schema/src/lib.rs:7168
  • `DcsSchemaTemplateEnvelopeEvidencePolicy.terminal_schema_file_shape` is offered as a configuration-file option, so whoever configures the program can set it — but no production code reads it. Every value supplied for it is silently ignored. Consult it where it was meant to take effect — or, if it genuinely does nothing, remove it (or mark it deprecated and say so in its documentation) so the configuration stops advertising a setting that changes nothing. — crates/ibcmd-schema/src/lib.rs:7169
  • `DcsSchemaTemplateEnvelopeTwoVariantShape.trailing_document_length` is offered as a configuration-file option, so whoever configures the program can set it — but no production code reads it. Every value supplied for it is silently ignored. Consult it where it was meant to take effect — or, if it genuinely does nothing, remove it (or mark it deprecated and say so in its documentation) so the configuration stops advertising a setting that changes nothing. — crates/ibcmd-schema/src/lib.rs:7178
  • `DcsSchemaTemplateEnvelopeTwoVariantShape.variant_names` is offered as a configuration-file option, so whoever configures the program can set it — but no production code reads it. Every value supplied for it is silently ignored. Consult it where it was meant to take effect — or, if it genuinely does nothing, remove it (or mark it deprecated and say so in its documentation) so the configuration stops advertising a setting that changes nothing. — crates/ibcmd-schema/src/lib.rs:7181

What to do

  • Each finding names the spans that disagree — the knob the caller supplies and the site that ignores it, whether by re-spelling its default, by falling back under the wrong key, by parsing with no format provider at all, or by printing under whatever culture the host supplies. Confirm from those spans, then decide which of the two the type meant: read the knob at the named site, or drop the knob so the signature stops advertising something the type cannot feel. Leaving both is the one option that cannot be right.
X27 · Collection changed while being enumerated10.0 / 10Exemplary○ Nothing flagged

Other · Code Health — Whether a `for` loop leaves the `RefCell` it is walking alone — safe Rust rejects a body that changes the collection its loop borrows at compile time, except through interior mutability: a `RefCell` borrowed in the loop's header stays borrowed until the loop ends, so a `borrow_mut()` of it inside the body panics with `already borrowed: BorrowMutError` and the remaining elements are never seen. Whether a `for` loop leaves the `dict`, `set` or `deque` it is walking alone — CPython's iterators over those check that the collection has not changed size since the loop began, so a body that removes from (or empties) the very collection the loop is walking makes the next step raise `RuntimeError: dictionary changed size during iteration` and the remaining items are never seen.

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

X28 · Index access outside its own emptiness guard10.0 / 10Exemplary○ Nothing flagged

Other · Code Health — Whether a condition that tests a value for emptiness indexes that same value only where the test holds — an `||` written one parenthesis too far to the left leaves an index access outside the guard beside it, so the empty case the guard exists to anticipate reaches the index and throws.

Method: Roslyn syntax only, no semantic model: the OUTERMOST `&&`/`||` of every boolean condition, read for a symbol the condition tests for emptiness (`string.IsNullOrEmpty`/`IsNullOrWhiteSpace`, a `Length`/`Count` comparison against a literal, `Any()`, a `Length`/`Count` pattern, or a comparison against `""`) and ALSO indexes. Each `symbol[...]` access is placed by a boolean-reachability walk from the access up to the outermost connective: an access is COVERED when some enclosing step has it in the right operand and the left operand, under the truth value that step forces, proves the symbol non-empty — a recursion over `&&`/`||` whose true- and false-directions are asymmetric. A finding needs BOTH an uncovered access and a covered one on the same symbol in the same condition, which is the agreeing twin that separates a misplaced parenthesis from an unrelated length test. Bare index accesses with no emptiness test in the condition are neither counted nor reported; a non-identifier receiver and a lambda nested inside the condition are outside the population. Deterministic, provable per finding. Advisory.

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

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

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

X30 · Support guard that admits what it rejects10.0 / 10Exemplary○ Nothing flagged

Other · Code Health — Whether a guard written as a NEGATED `||` says what its author meant — `!(a || b || x != k)` is `!a && !b && x == k` by De Morgan, so a bail-out that mixes capabilities the code needs with a fault it refuses turns inside out: it fires only where the capabilities are ABSENT, and lets every value the fault term names walk straight into the body that cannot handle it.

Method: Roslyn syntax only, no semantic model: every logical-not whose operand is a parenthesised `||` chain of two or more disjuncts, flattened (a left-nested `a || b || c` read once would see `(a || b)` as one disjunct). A site enters the population on that shape alone. A finding additionally needs the disjuncts to DISAGREE in polarity: at least one bare boolean read — an identifier or member access, never an invocation, which is a predicate rather than a capability flag — and at least one `x != <constant>`, the only form that negates into an exact-value pin (`== null` negates into a looser requirement and is outside the fault set). Consistently-polarised disjunctions, all-fault or all-capability, are counted and never reported; a negated `&&` is outside the population entirely. No same-receiver gate: it was measured to cost a real defect and remove no false positive. Deterministic, provable per finding. Advisory.

X5 · Nullable reference types9.5 / 10Exemplary✓ Tool-verified

Other · Code Health — Whether Rust's absent values are handled rather than forced — `Option` and `Result` make absence a value the caller must handle in every crate, and each `.unwrap()` or `.expect()` that no guard on its path proves present is a panic the first time the value is `None` or `Err`.

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

  • `Path::new(env!("CARGO_MANIFEST_DIR")).parent()` can be absent — it is an `Option` or `Result`, which is why it is forced — and `.expect()` in `repository_root` forces it with nothing on this path excluding `None`/`Err`: no `if let` or `match` arm that matched it present, no `let … else`, no `is_some()`/`is_ok()` test (or `is_none()`/`is_err()` test that leaves), no `assert!` of it, and for a lookup no proof the key or index exists. This line panics the first time the value is not there. Handle the absent case where it arises: propagate it with `?`, branch on it with `if let` / `match` / `let … else`, or give it a default (`unwrap_or`, `unwrap_or_default`, `unwrap_or_else`). — xtask/src/main.rs:110
  • `self.phases.iter_mut().find(|entry|entry.phase==phase)` can be absent — it is an `Option` or `Result`, which is why it is forced — and `.expect()` in `mark` forces it with nothing on this path excluding `None`/`Err`: no `if let` or `match` arm that matched it present, no `let … else`, no `is_some()`/`is_ok()` test (or `is_none()`/`is_err()` test that leaves), no `assert!` of it, and for a lookup no proof the key or index exists. This line panics the first time the value is not there. Handle the absent case where it arises: propagate it with `?`, branch on it with `if let` / `match` / `let … else`, or give it a default (`unwrap_or`, `unwrap_or_default`, `unwrap_or_else`). — src/conversion.rs:230
  • `PathSegment::name("source")` can be absent — it is an `Option` or `Result`, which is why it is forced — and `.expect()` in `decode_xml_tree` forces it with nothing on this path excluding `None`/`Err`: no `if let` or `match` arm that matched it present, no `let … else`, no `is_some()`/`is_ok()` test (or `is_none()`/`is_err()` test that leaves), no `assert!` of it, and for a lookup no proof the key or index exists. This line panics the first time the value is not there. Handle the absent case where it arises: propagate it with `?`, branch on it with `if let` / `match` / `let … else`, or give it a default (`unwrap_or`, `unwrap_or_default`, `unwrap_or_else`). — src/conversion.rs:506
  • `ObjectPath::new(vec![PathSegment::name("source").expect("static object path is valid"),PathSegment::index(index),])` can be absent — it is an `Option` or `Result`, which is why it is forced — and `.expect()` in `decode_xml_tree` forces it with nothing on this path excluding `None`/`Err`: no `if let` or `match` arm that matched it present, no `let … else`, no `is_some()`/`is_ok()` test (or `is_none()`/`is_err()` test that leaves), no `assert!` of it, and for a lookup no proof the key or index exists. This line panics the first time the value is not there. Handle the absent case where it arises: propagate it with `?`, branch on it with `if let` / `match` / `let … else`, or give it a default (`unwrap_or`, `unwrap_or_default`, `unwrap_or_else`). — src/conversion.rs:509
  • `source_profile.xml_dialect.as_ref()` can be absent — it is an `Option` or `Result`, which is why it is forced — and `.expect()` in `convert_xml_to_cf` forces it with nothing on this path excluding `None`/`Err`: no `if let` or `match` arm that matched it present, no `let … else`, no `is_some()`/`is_ok()` test (or `is_none()`/`is_err()` test that leaves), no `assert!` of it, and for a lookup no proof the key or index exists. This line panics the first time the value is not there. Handle the absent case where it arises: propagate it with `?`, branch on it with `if let` / `match` / `let … else`, or give it a default (`unwrap_or`, `unwrap_or_default`, `unwrap_or_else`). — src/conversion.rs:883
  • `target_profile.storage_profile.as_ref()` can be absent — it is an `Option` or `Result`, which is why it is forced — and `.expect()` in `convert_xml_to_cf` forces it with nothing on this path excluding `None`/`Err`: no `if let` or `match` arm that matched it present, no `let … else`, no `is_some()`/`is_ok()` test (or `is_none()`/`is_err()` test that leaves), no `assert!` of it, and for a lookup no proof the key or index exists. This line panics the first time the value is not there. Handle the absent case where it arises: propagate it with `?`, branch on it with `if let` / `match` / `let … else`, or give it a default (`unwrap_or`, `unwrap_or_default`, `unwrap_or_else`). — src/conversion.rs:907
  • `source_profile.storage_profile.as_ref()` can be absent — it is an `Option` or `Result`, which is why it is forced — and `.expect()` in `decode_cf` forces it with nothing on this path excluding `None`/`Err`: no `if let` or `match` arm that matched it present, no `let … else`, no `is_some()`/`is_ok()` test (or `is_none()`/`is_err()` test that leaves), no `assert!` of it, and for a lookup no proof the key or index exists. This line panics the first time the value is not there. Handle the absent case where it arises: propagate it with `?`, branch on it with `if let` / `match` / `let … else`, or give it a default (`unwrap_or`, `unwrap_or_default`, `unwrap_or_else`). — src/conversion.rs:1373
  • `StorageProvenance::new("offline conversion service")` can be absent — it is an `Option` or `Result`, which is why it is forced — and `.expect()` in `decode_cf` forces it with nothing on this path excluding `None`/`Err`: no `if let` or `match` arm that matched it present, no `let … else`, no `is_some()`/`is_ok()` test (or `is_none()`/`is_err()` test that leaves), no `assert!` of it, and for a lookup no proof the key or index exists. This line panics the first time the value is not there. Handle the absent case where it arises: propagate it with `?`, branch on it with `if let` / `match` / `let … else`, or give it a default (`unwrap_or`, `unwrap_or_default`, `unwrap_or_else`). — src/conversion.rs:1379
  • `ProfileId::parse("provider:mssql-legacy")` can be absent — it is an `Option` or `Result`, which is why it is forced — and `.expect()` in `audit_dcs_template_writer` forces it with nothing on this path excluding `None`/`Err`: no `if let` or `match` arm that matched it present, no `let … else`, no `is_some()`/`is_ok()` test (or `is_none()`/`is_err()` test that leaves), no `assert!` of it, and for a lookup no proof the key or index exists. This line panics the first time the value is not there. Handle the absent case where it arises: propagate it with `?`, branch on it with `if let` / `match` / `let … else`, or give it a default (`unwrap_or`, `unwrap_or_default`, `unwrap_or_else`). — src/dcs_template_audit.rs:109
  • `ProfileId::parse("xml-2.20")` can be absent — it is an `Option` or `Result`, which is why it is forced — and `.expect()` in `audit_dcs_template_writer` forces it with nothing on this path excluding `None`/`Err`: no `if let` or `match` arm that matched it present, no `let … else`, no `is_some()`/`is_ok()` test (or `is_none()`/`is_err()` test that leaves), no `assert!` of it, and for a lookup no proof the key or index exists. This line panics the first time the value is not there. Handle the absent case where it arises: propagate it with `?`, branch on it with `if let` / `match` / `let … else`, or give it a default (`unwrap_or`, `unwrap_or_default`, `unwrap_or_else`). — src/dcs_template_audit.rs:110
  • `bytes.try_into()` can be absent — it is an `Option` or `Result`, which is why it is forced — and `.expect()` in `split_documents` forces it with nothing on this path excluding `None`/`Err`: no `if let` or `match` arm that matched it present, no `let … else`, no `is_some()`/`is_ok()` test (or `is_none()`/`is_err()` test that leaves), no `assert!` of it, and for a lookup no proof the key or index exists. This line panics the first time the value is not there. Handle the absent case where it arises: propagate it with `?`, branch on it with `if let` / `match` / `let … else`, or give it a default (`unwrap_or`, `unwrap_or_default`, `unwrap_or_else`). (×2) — src/dcs_template_audit.rs:299, src/dcs_template_audit.rs:304
  • `self.loaded.as_ref()` can be absent — it is an `Option` or `Result`, which is why it is forced — and `.expect()` in `get` forces it with nothing on this path excluding `None`/`Err`: no `if let` or `match` arm that matched it present, no `let … else`, no `is_some()`/`is_ok()` test (or `is_none()`/`is_err()` test that leaves), no `assert!` of it, and for a lookup no proof the key or index exists. This line panics the first time the value is not there. Handle the absent case where it arises: propagate it with `?`, branch on it with `if let` / `match` / `let … else`, or give it a default (`unwrap_or`, `unwrap_or_default`, `unwrap_or_else`). — src/infobase.rs:894
  • `entry.path().strip_prefix(root)` can be absent — it is an `Option` or `Result`, which is why it is forced — and `.expect()` in `relative_files` forces it with nothing on this path excluding `None`/`Err`: no `if let` or `match` arm that matched it present, no `let … else`, no `is_some()`/`is_ok()` test (or `is_none()`/`is_err()` test that leaves), no `assert!` of it, and for a lookup no proof the key or index exists. This line panics the first time the value is not there. Handle the absent case where it arises: propagate it with `?`, branch on it with `if let` / `match` / `let … else`, or give it a default (`unwrap_or`, `unwrap_or_default`, `unwrap_or_else`). — src/load.rs:74
  • `StorageProfileId::parse("storage:cf-cli")` can be absent — it is an `Option` or `Result`, which is why it is forced — and `.expect()` in `export_base` forces it with nothing on this path excluding `None`/`Err`: no `if let` or `match` arm that matched it present, no `let … else`, no `is_some()`/`is_ok()` test (or `is_none()`/`is_err()` test that leaves), no `assert!` of it, and for a lookup no proof the key or index exists. This line panics the first time the value is not there. Handle the absent case where it arises: propagate it with `?`, branch on it with `if let` / `match` / `let … else`, or give it a default (`unwrap_or`, `unwrap_or_default`, `unwrap_or_else`). — src/load.rs:372
  • `StorageProfileId::parse(OVERLAY_PROFILE)` can be absent — it is an `Option` or `Result`, which is why it is forced — and `.expect()` in `load_plan` forces it with nothing on this path excluding `None`/`Err`: no `if let` or `match` arm that matched it present, no `let … else`, no `is_some()`/`is_ok()` test (or `is_none()`/`is_err()` test that leaves), no `assert!` of it, and for a lookup no proof the key or index exists. This line panics the first time the value is not there. Handle the absent case where it arises: propagate it with `?`, branch on it with `if let` / `match` / `let … else`, or give it a default (`unwrap_or`, `unwrap_or_default`, `unwrap_or_else`). (×2) — src/load.rs:758, src/load.rs:773
  • `StorageProvenance::new("cf load base")` can be absent — it is an `Option` or `Result`, which is why it is forced — and `.expect()` in `load_plan` forces it with nothing on this path excluding `None`/`Err`: no `if let` or `match` arm that matched it present, no `let … else`, no `is_some()`/`is_ok()` test (or `is_none()`/`is_err()` test that leaves), no `assert!` of it, and for a lookup no proof the key or index exists. This line panics the first time the value is not there. Handle the absent case where it arises: propagate it with `?`, branch on it with `if let` / `match` / `let … else`, or give it a default (`unwrap_or`, `unwrap_or_default`, `unwrap_or_else`). — src/load.rs:774
  • `StorageProfileId::parse(OVERLAY_PROFILE)` can be absent — it is an `Option` or `Result`, which is why it is forced — and `.expect()` in `refresh_configinfo` forces it with nothing on this path excluding `None`/`Err`: no `if let` or `match` arm that matched it present, no `let … else`, no `is_some()`/`is_ok()` test (or `is_none()`/`is_err()` test that leaves), no `assert!` of it, and for a lookup no proof the key or index exists. This line panics the first time the value is not there. Handle the absent case where it arises: propagate it with `?`, branch on it with `if let` / `match` / `let … else`, or give it a default (`unwrap_or`, `unwrap_or_default`, `unwrap_or_else`). — src/load.rs:861
  • `StorageProvenance::new("cf load staged")` can be absent — it is an `Option` or `Result`, which is why it is forced — and `.expect()` in `refresh_configinfo` forces it with nothing on this path excluding `None`/`Err`: no `if let` or `match` arm that matched it present, no `let … else`, no `is_some()`/`is_ok()` test (or `is_none()`/`is_err()` test that leaves), no `assert!` of it, and for a lookup no proof the key or index exists. This line panics the first time the value is not there. Handle the absent case where it arises: propagate it with `?`, branch on it with `if let` / `match` / `let … else`, or give it a default (`unwrap_or`, `unwrap_or_default`, `unwrap_or_else`). — src/load.rs:862
  • `text.find(&marker)` can be absent — it is an `Option` or `Result`, which is why it is forced — and `.expect()` in `with_configinfo_digests` forces it with nothing on this path excluding `None`/`Err`: no `if let` or `match` arm that matched it present, no `let … else`, no `is_some()`/`is_ok()` test (or `is_none()`/`is_err()` test that leaves), no `assert!` of it, and for a lookup no proof the key or index exists. This line panics the first time the value is not there. Handle the absent case where it arises: propagate it with `?`, branch on it with `if let` / `match` / `let … else`, or give it a default (`unwrap_or`, `unwrap_or_default`, `unwrap_or_else`). — src/load.rs:916
  • `settings_path.parent()` can be absent — it is an `Option` or `Result`, which is why it is forced — and `.unwrap()` in `open` forces it with nothing on this path excluding `None`/`Err`: no `if let` or `match` arm that matched it present, no `let … else`, no `is_some()`/`is_ok()` test (or `is_none()`/`is_err()` test that leaves), no `assert!` of it, and for a lookup no proof the key or index exists. This line panics the first time the value is not there. Handle the absent case where it arises: propagate it with `?`, branch on it with `if let` / `match` / `let … else`, or give it a default (`unwrap_or`, `unwrap_or_default`, `unwrap_or_else`). — src/mcp.rs:158
  • `policy_path.parent()` can be absent — it is an `Option` or `Result`, which is why it is forced — and `.unwrap()` in `open` forces it with nothing on this path excluding `None`/`Err`: no `if let` or `match` arm that matched it present, no `let … else`, no `is_some()`/`is_ok()` test (or `is_none()`/`is_err()` test that leaves), no `assert!` of it, and for a lookup no proof the key or index exists. This line panics the first time the value is not there. Handle the absent case where it arises: propagate it with `?`, branch on it with `if let` / `match` / `let … else`, or give it a default (`unwrap_or`, `unwrap_or_default`, `unwrap_or_else`). — src/mcp.rs:176
  • `self.file_path.as_ref()` can be absent — it is an `Option` or `Result`, which is why it is forced — and `.unwrap()` in `prepare_import` forces it with nothing on this path excluding `None`/`Err`: no `if let` or `match` arm that matched it present, no `let … else`, no `is_some()`/`is_ok()` test (or `is_none()`/`is_err()` test that leaves), no `assert!` of it, and for a lookup no proof the key or index exists. This line panics the first time the value is not there. Handle the absent case where it arises: propagate it with `?`, branch on it with `if let` / `match` / `let … else`, or give it a default (`unwrap_or`, `unwrap_or_default`, `unwrap_or_else`). — src/mcp.rs:373
  • `json!({"type":"object","properties":properties,"required":required,"additionalProperties":false}).as_object()` can be absent — it is an `Option` or `Result`, which is why it is forced — and `.unwrap()` in `definitions` forces it with nothing on this path excluding `None`/`Err`: no `if let` or `match` arm that matched it present, no `let … else`, no `is_some()`/`is_ok()` test (or `is_none()`/`is_err()` test that leaves), no `assert!` of it, and for a lookup no proof the key or index exists. This line panics the first time the value is not there. Handle the absent case where it arises: propagate it with `?`, branch on it with `if let` / `match` / `let … else`, or give it a default (`unwrap_or`, `unwrap_or_default`, `unwrap_or_else`). — src/mcp.rs:900
  • `fs::create_dir_all(&db)` can be absent — it is an `Option` or `Result`, which is why it is forced — and `.unwrap()` in `setup` forces it with nothing on this path excluding `None`/`Err`: no `if let` or `match` arm that matched it present, no `let … else`, no `is_some()`/`is_ok()` test (or `is_none()`/`is_err()` test that leaves), no `assert!` of it, and for a lookup no proof the key or index exists. This line panics the first time the value is not there. Handle the absent case where it arises: propagate it with `?`, branch on it with `if let` / `match` / `let … else`, or give it a default (`unwrap_or`, `unwrap_or_default`, `unwrap_or_else`). — src/mcp.rs:1178
  • `fs::create_dir_all(&source)` can be absent — it is an `Option` or `Result`, which is why it is forced — and `.unwrap()` in `setup` forces it with nothing on this path excluding `None`/`Err`: no `if let` or `match` arm that matched it present, no `let … else`, no `is_some()`/`is_ok()` test (or `is_none()`/`is_err()` test that leaves), no `assert!` of it, and for a lookup no proof the key or index exists. This line panics the first time the value is not there. Handle the absent case where it arises: propagate it with `?`, branch on it with `if let` / `match` / `let … else`, or give it a default (`unwrap_or`, `unwrap_or_default`, `unwrap_or_else`). — src/mcp.rs:1179
  • `fs::File::open(fixture.join("tiny.1CD.gz"))` can be absent — it is an `Option` or `Result`, which is why it is forced — and `.unwrap()` in `setup` forces it with nothing on this path excluding `None`/`Err`: no `if let` or `match` arm that matched it present, no `let … else`, no `is_some()`/`is_ok()` test (or `is_none()`/`is_err()` test that leaves), no `assert!` of it, and for a lookup no proof the key or index exists. This line panics the first time the value is not there. Handle the absent case where it arises: propagate it with `?`, branch on it with `if let` / `match` / `let … else`, or give it a default (`unwrap_or`, `unwrap_or_default`, `unwrap_or_else`). — src/mcp.rs:1182
  • `flate2::read::GzDecoder::new(fs::File::open(fixture.join("tiny.1CD.gz")).unwrap()).read_to_end(&mut bytes)` can be absent — it is an `Option` or `Result`, which is why it is forced — and `.unwrap()` in `setup` forces it with nothing on this path excluding `None`/`Err`: no `if let` or `match` arm that matched it present, no `let … else`, no `is_some()`/`is_ok()` test (or `is_none()`/`is_err()` test that leaves), no `assert!` of it, and for a lookup no proof the key or index exists. This line panics the first time the value is not there. Handle the absent case where it arises: propagate it with `?`, branch on it with `if let` / `match` / `let … else`, or give it a default (`unwrap_or`, `unwrap_or_default`, `unwrap_or_else`). — src/mcp.rs:1184
  • `fs::write(db.join("1Cv8.1CD"),bytes)` can be absent — it is an `Option` or `Result`, which is why it is forced — and `.unwrap()` in `setup` forces it with nothing on this path excluding `None`/`Err`: no `if let` or `match` arm that matched it present, no `let … else`, no `is_some()`/`is_ok()` test (or `is_none()`/`is_err()` test that leaves), no `assert!` of it, and for a lookup no proof the key or index exists. This line panics the first time the value is not there. Handle the absent case where it arises: propagate it with `?`, branch on it with `if let` / `match` / `let … else`, or give it a default (`unwrap_or`, `unwrap_or_default`, `unwrap_or_else`). — src/mcp.rs:1185
  • `entry.path().strip_prefix(fixture.join("tiny-xml"))` can be absent — it is an `Option` or `Result`, which is why it is forced — and `.unwrap()` in `setup` forces it with nothing on this path excluding `None`/`Err`: no `if let` or `match` arm that matched it present, no `let … else`, no `is_some()`/`is_ok()` test (or `is_none()`/`is_err()` test that leaves), no `assert!` of it, and for a lookup no proof the key or index exists. This line panics the first time the value is not there. Handle the absent case where it arises: propagate it with `?`, branch on it with `if let` / `match` / `let … else`, or give it a default (`unwrap_or`, `unwrap_or_default`, `unwrap_or_else`). — src/mcp.rs:1191
  • `path.parent()` can be absent — it is an `Option` or `Result`, which is why it is forced — and `.unwrap()` in `setup` forces it with nothing on this path excluding `None`/`Err`: no `if let` or `match` arm that matched it present, no `let … else`, no `is_some()`/`is_ok()` test (or `is_none()`/`is_err()` test that leaves), no `assert!` of it, and for a lookup no proof the key or index exists. This line panics the first time the value is not there. Handle the absent case where it arises: propagate it with `?`, branch on it with `if let` / `match` / `let … else`, or give it a default (`unwrap_or`, `unwrap_or_default`, `unwrap_or_else`). — src/mcp.rs:1193
  • `fs::create_dir_all(path.parent().unwrap())` can be absent — it is an `Option` or `Result`, which is why it is forced — and `.unwrap()` in `setup` forces it with nothing on this path excluding `None`/`Err`: no `if let` or `match` arm that matched it present, no `let … else`, no `is_some()`/`is_ok()` test (or `is_none()`/`is_err()` test that leaves), no `assert!` of it, and for a lookup no proof the key or index exists. This line panics the first time the value is not there. Handle the absent case where it arises: propagate it with `?`, branch on it with `if let` / `match` / `let … else`, or give it a default (`unwrap_or`, `unwrap_or_default`, `unwrap_or_else`). — src/mcp.rs:1193
  • `fs::copy(entry.path(),path)` can be absent — it is an `Option` or `Result`, which is why it is forced — and `.unwrap()` in `setup` forces it with nothing on this path excluding `None`/`Err`: no `if let` or `match` arm that matched it present, no `let … else`, no `is_some()`/`is_ok()` test (or `is_none()`/`is_err()` test that leaves), no `assert!` of it, and for a lookup no proof the key or index exists. This line panics the first time the value is not there. Handle the absent case where it arises: propagate it with `?`, branch on it with `if let` / `match` / `let … else`, or give it a default (`unwrap_or`, `unwrap_or_default`, `unwrap_or_else`). — src/mcp.rs:1194
  • `fs::write(&settings,"[[database]]\nname='demo'\nplatform='8.5.1'\ndb-path='db'\nagent-write=true\n[mcp]\ndatabase='demo'\nsource-root='source'\n")` can be absent — it is an `Option` or `Result`, which is why it is forced — and `.unwrap()` in `setup` forces it with nothing on this path excluding `None`/`Err`: no `if let` or `match` arm that matched it present, no `let … else`, no `is_some()`/`is_ok()` test (or `is_none()`/`is_err()` test that leaves), no `assert!` of it, and for a lookup no proof the key or index exists. This line panics the first time the value is not there. Handle the absent case where it arises: propagate it with `?`, branch on it with `if let` / `match` / `let … else`, or give it a default (`unwrap_or`, `unwrap_or_default`, `unwrap_or_else`). — src/mcp.rs:1197
  • `Bound::open(&settings,&settings)` can be absent — it is an `Option` or `Result`, which is why it is forced — and `.unwrap()` in `setup` forces it with nothing on this path excluding `None`/`Err`: no `if let` or `match` arm that matched it present, no `let … else`, no `is_some()`/`is_ok()` test (or `is_none()`/`is_err()` test that leaves), no `assert!` of it, and for a lookup no proof the key or index exists. This line panics the first time the value is not there. Handle the absent case where it arises: propagate it with `?`, branch on it with `if let` / `match` / `let … else`, or give it a default (`unwrap_or`, `unwrap_or_default`, `unwrap_or_else`). — src/mcp.rs:1198
  • `StorageProfileId::parse(LEGACY_MSSQL_STORAGE_PROFILE_ID)` can be absent — it is an `Option` or `Result`, which is why it is forced — and `.expect()` in `mssql_compile_axes` forces it with nothing on this path excluding `None`/`Err`: no `if let` or `match` arm that matched it present, no `let … else`, no `is_some()`/`is_ok()` test (or `is_none()`/`is_err()` test that leaves), no `assert!` of it, and for a lookup no proof the key or index exists. This line panics the first time the value is not there. Handle the absent case where it arises: propagate it with `?`, branch on it with `if let` / `match` / `let … else`, or give it a default (`unwrap_or`, `unwrap_or_default`, `unwrap_or_else`). — REDACTED:710
  • `XmlDialect::parse("2.20")` can be absent — it is an `Option` or `Result`, which is why it is forced — and `.expect()` in `legacy_non_xml_compile_axes` forces it with nothing on this path excluding `None`/`Err`: no `if let` or `match` arm that matched it present, no `let … else`, no `is_some()`/`is_ok()` test (or `is_none()`/`is_err()` test that leaves), no `assert!` of it, and for a lookup no proof the key or index exists. This line panics the first time the value is not there. Handle the absent case where it arises: propagate it with `?`, branch on it with `if let` / `match` / `let … else`, or give it a default (`unwrap_or`, `unwrap_or_default`, `unwrap_or_else`). — REDACTED:725
  • `tail_log_output` can be absent — it is an `Option` or `Result`, which is why it is forced — and `.unwrap()` in `activate_staged_main_verified_inner` forces it with nothing on this path excluding `None`/`Err`: no `if let` or `match` arm that matched it present, no `let … else`, no `is_some()`/`is_ok()` test (or `is_none()`/`is_err()` test that leaves), no `assert!` of it, and for a lookup no proof the key or index exists. This line panics the first time the value is not there. Handle the absent case where it arises: propagate it with `?`, branch on it with `if let` / `match` / `let … else`, or give it a default (`unwrap_or`, `unwrap_or_default`, `unwrap_or_else`). — REDACTED:1293
  • `SourceAssetRegistry.help_suffix(&properties.kind)` can be absent — it is an `Option` or `Result`, which is why it is forced — and `.expect()` in `metadata_body_bootstrap_rows` forces it with nothing on this path excluding `None`/`Err`: no `if let` or `match` arm that matched it present, no `let … else`, no `is_some()`/`is_ok()` test (or `is_none()`/`is_err()` test that leaves), no `assert!` of it, and for a lookup no proof the key or index exists. This line panics the first time the value is not there. Handle the absent case where it arises: propagate it with `?`, branch on it with `if let` / `match` / `let … else`, or give it a default (`unwrap_or`, `unwrap_or_default`, `unwrap_or_else`). — REDACTED:2256

What to do

  • Each row is a forced `Option`/`Result` no guard on its path proves present. Handle the absent case where it arises rather than forcing it: `?` to hand it to the caller, `if let` / `match` / `let … else` to branch on it, `unwrap_or` / `unwrap_or_default` / `unwrap_or_else` where a default is right. Where the value genuinely cannot be absent, say so in a way a reader can check from the line: test it first (`if x.is_none() { return … }`), look the key up with `contains_key` or the index against `len()`, or construct the value so it cannot be absent.

Reference — by lens

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

LensScoreRatingImpact
Code Health58.2Adequate — gated by D1, D2, R1Capped at Fair by a Critical contributor — resolve it before relying on this lens.
Architecture80.2StrongSolid.
Maturity73.6StrongSolid.
Readiness46.5Adequate — gated by D13, P2Capped at Fair by a Critical contributor — resolve it before relying on this lens.
Security35.9Weak — gated by D28, D29, D36, C1Capped at Fair by a Critical contributor — resolve it before relying on this lens.
Performance100.0ExemplaryStrongest area.
Unscored — 3 check(s) recorded observations but carry no score

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

  • X10 Duplicated predicate — 40 observation(s) recorded · Advisory — this card reports evidence and never carries a score.
  • X7 Silent fallback defaults — 14 observation(s) recorded · Advisory — this card reports evidence and never carries a score.
  • X9 Subsumed condition operand — 6 observation(s) recorded · Advisory — this card reports evidence and never carries a score.
Not evidenced — 1 control(s) we could not find positive evidence for

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

  • C5 Data-Subject Rights — Repo shows no corroborated data-subject-rights mechanism (erasure / export-portability / consent) tied to a subject id or GDPR vocabulary — absence of evidence is not evidence of a working control. A delete/anonymise identifier was seen but did not co-occur with GDPR vocabulary or a subject-id shape, so it was not credited (e.g. a save-slot DeleteAccount()). Implement erasure, data export/portability and consent tracking over the subject's records.
Not included — 53 check(s) not relevant to this codebase

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

  • AC1 Text alternatives — No web markup found — accessibility is not applicable to this repository.
  • AC2 Forms & labels — No web markup found — accessibility is not applicable to this repository.
  • AC3 Page structure — No web markup found — accessibility is not applicable to this repository.
  • AC4 Keyboard semantics — No web markup found — accessibility is not applicable to this repository.
  • AC5 ARIA correctness — No web markup found — accessibility is not applicable to this repository.
  • AC6 Visual & motion safety — No web markup found — accessibility is not applicable to this repository.
  • AX1 Captive dependencies — Not applicable: this repository's Python imports no dependency-injection container and defines no container of its own — nothing that both registers and resolves bindings, and nothing that names two lifetimes — so nothing holds one lifetime's instance while handing out another's; Rust with no dependency-injection crate has no container to hand one lifetime's instance to another — every value is owned by the code that builds it, and the borrow checker rejects a longer-lived value keeping a borrow of a shorter-lived one; this repository's TypeScript imports no dependency-injection container and defines no container of its own — nothing that both registers and resolves bindings, and nothing that names two lifetimes — so nothing holds one lifetime's instance while handing out another's.
  • AX2 Stateful singletons — No container singleton was found, so there is no shared instance for concurrent requests to race on. No function in this Python code is served by a threaded web framework (a Flask, Bottle or FastAPI route, a Django or Pyramid view), so no module is shared between request threads. Rust's compiler refuses unsynchronised shared mutation — a value shared across threads must be Sync — so the race this check looks for cannot be written. TypeScript/JavaScript runs each process's requests on one event loop, so no two requests write a shared object at the same instant (interleaving across an await is a different defect).
  • AX5 Architecture & structure — not assessed — architecture style/structure is computed from a project graph (projects, types, module namespaces) that was not loaded for this repository, because the repository is written in a language this check does not yet model, or because its projects failed to load. This is a gap in the analyzer, not a finding about this repository
  • AX6 Interface segregation — AX6 reached only 4% of this repository's production lines — rust (668,058 lines) was left unread. Not scored: a score over a minority of the product would be published as the whole of it.
  • AX7 Slice cohesion — not applicable — not a vertical-slice architecture
  • AXB1 Runtime evidence locked — no reproducible boot — This repository has nothing the runtime tiers could boot or serve — no markup, no UI framework or web-server dependency, no UI component source, no native UI project and no API definition — nothing here is a surface to boot — so runtime a11y/egress/header evidence has no subject here. Not applicable: this is neither a gap in the scan nor a finding about your code.
  • C2 Access Controls — No access-control surface detected in the analyzed source — this repository starts no server another machine can reach (no actix-web HttpServer, axum::serve, Rocket launch, warp::serve, poem or salvo Server, tonic Server::builder, hyper or tiny_http server outside examples and tests, none bound beyond loopback). Access control is therefore N/A here — a crate is authorized by the application that serves it, not by itself. If this codebase grows request handlers, the dimension reactivates and a default-deny posture is expected then.
  • D11 Test Reliability — Test reliability not scored — polyglot repository, one half's runner produced no measurement
  • D16 Bus Factor — single-maintainer repository — bus factor is not applicable
  • D18 Solution Shape — D18 scores the shape of a .NET solution; this repository has no .NET solution or project files, so the dimension does not apply.
  • D21 Naming Consistency — D21 withholds its case and prefix conventions rows: 6 candidate(s) found and not reported.
  • D22 Internal API Consistency — API consistency is measured on C#, TypeScript, Go only; the exposed Rust surface was not measured.
  • D23 Boundary Type-Coupling — No bounded-context organisation was detected either — neither a context-shaped layout, nor 2+ sibling source directories each declaring an aggregate root, nor 2+ sibling projects each declaring an entity of their own or taking another project's integration events. Declaring this codebase's bounded contexts (≥2) would let cross-boundary type coupling be assessed. Declare them in `.codehealth/config.yaml` at the repository root (create it if absent), mapping each context name to the module-path or namespace prefixes that belong to it — e.g. `architecture:` → `contexts:` → `Billing: ["src/billing", "Acme.Billing"]`, `Catalog: ["src/catalog", "Acme.Catalog"]`.
  • D25 ADR Conformance — no ADRs to check
  • D27 Navigability — D27 counts a call into the standard library or a dependency as unresolved for this repository's language (.rs), so too few call sites counted as resolved to assess navigability. Not scored: this is a gap in the analyzer, not a verdict about this repository.
  • D31 IaC & Container Security — No Infrastructure-as-Code or container manifests found (Dockerfile, Docker Compose, Terraform, Kubernetes/Helm, CloudFormation, ARM, Bicep, Ansible); nothing to scan.
  • D32 Data Compliance (PII/GDPR) — No personal data was found crossing a boundary the PII/GDPR ruleset checks — nothing written to a log or console sink, placed in a URL or query string, or persisted to browser storage. That is a clean result for the LEAK surface only: this ruleset detects personal data escaping, it does not inventory the personal data a repository holds, so it is not evidence that this repository has no personal-data surface. The personal-data map (Appendix C) and the C1-C5 compliance cards are what speak to that.
  • D37 Vulnerability-disclosure Policy — No vulnerability-disclosure policy file found (SECURITY.md/.markdown/.rst/.txt at root or under .github/.forgejo/.gitea/docs, .well-known/security.txt). A coordinated-disclosure policy may live off-repo, so this is not evidenced rather than failed.
  • D40 Network Egress Confinement — No Kubernetes/orchestration workloads found in the repository manifests; network egress policy is a cluster-native control that may live at the platform/firewall layer, so there is nothing to assess here.
  • D41 Kernel & Syscall Confinement — No Kubernetes/orchestration workloads found in the repository manifests; seccomp/AppArmor/SELinux confinement is a workload-level control, so there is nothing to assess here.
  • D42 Runtime Threat Enforcement — No Kubernetes/orchestration workloads found in the repository manifests; runtime threat-detection and admission-control policy are cluster-level controls, so there is nothing to assess here.
  • D7 Architectural Integrity — no checkable ADRs, and no project-reference graph for the cycle pass to read — so this dimension makes no claim about dependency cycles in either direction (where this repository's language has an import-cycle lens, cycles are reported there). Architectural integrity not assessed
  • D8 Code Coverage — Coverage not measured — polyglot repository, one half has no runner
  • DM1 Domain Modelling — not scored — this repository shows only 1 of the 3 signals this lens looks for (491 value object(s))
  • ED2 Event/command shape — not scored — deciding whether a command has more than one competing handler requires resolving the call graph, and a call made through an inferred or generic receiver has no resolvable owner in the source. Reported as guidance rather than measured
  • ED5 Idempotency — no mutating command handlers or message consumers detected — idempotency check not applicable
  • ES1 Event Sourcing — not scored — this repository shows none of the 3 signals this lens looks for
  • P12 CI test-gate honesty — Reported, not scored — and nothing was matched here. The coverage check applies to any stack, and the automatic-re-run check to any GitHub-Actions workflow, but the checks for excluded tests, skipped tests and sleep-based synchronisation currently recognise only some ecosystems' test-runner idioms, so on a repository built with another stack the zeros below mean 'not checked', not 'clean'.
  • P7 Outbound HTTP resilience — not applicable — no HTTP server, API framework or worker entry point was found in the JavaScript/TypeScript, Python, Rust source, so there is no service whose uptime a failing dependency could take down
  • P8 Schema migrations — no ORM, schema-migration tool or schema auto-create was found in this repository's dependency manifests or source, so there is no database schema for this check to judge
  • P9 Domain vs controller coverage — coverage data present for 20 file(s), but no domain-layer files were identified: no covered file's path contains any of the markers this check keys on (/domain/, /aggregates/, /valueobjects/, /domainmodel/, .domain/, /entities/), which are matched case-insensitively anywhere in the path. With no domain partition there is nothing to compare the web/controller layer against — if this repository keeps its business rules under a folder named none of those, that naming is what the check cannot see, not the domain logic.
  • PF1 Benchmark discipline — Not applicable: no benchmark suite was found. This check searched for `#[bench]`, criterion's `bench_function`/`bench_with_input`, `#[divan::bench]` or `#[library_benchmark]` in any `.rs` file, or criterion, divan, iai or a `[[bench]]` target in a Cargo.toml, and for a `*benchmark*` script that this repository's CI runs. Benchmarks are credited as a bonus, so their absence is neither scored nor deducted.
  • PF2 Allocation hygiene — Not scored: this check counted allocation-aware idioms (Span, pools, stackalloc) per line, which describes what kind of code a repository is rather than whether it has an allocation problem, so it was withdrawn. Nothing here is a finding about your code.
  • R11 Import Boundaries — No recognizable feature-sliced/layered src layout — boundary rules not applicable.
  • SC1 Supply-chain hygiene — Advisory — this card reports evidence and never carries a score, so there is nothing missing here.
  • X14 Bypassable address classification — not applicable — the code was read and holds no site of this kind, so there is nothing for this check to judge
  • X15 Unvalidated length from an untrusted reader — not applicable — the code was read and holds no site of this kind, so there is nothing for this check to judge
  • X19 Unrestored process-global state — not applicable — the code was read and holds no site of this kind, so there is nothing for this check to judge
  • X20 Mistyped argument guard — This check asks whether an argument guard reports an EMPTY value as a NULL one, which needs a language that throws a null-specific argument exception — .NET's ArgumentNullException, the JVM's NullPointerException, Dart's ArgumentError.notNull. This repository contains none of those languages: the ones it is written in have a single exception for a bad argument, so there is no pair of exceptions to confuse and nothing here for it to assess. Not a gap in the analyzer and not a finding about your code.
  • X22 Contradicted release guard — not applicable — the code was read and holds no site of this kind, so there is nothing for this check to judge
  • X23 Unguarded diagnostic materialisation — not applicable — the code was read and holds no site of this kind, so there is nothing for this check to judge
  • X24 Document value interpolated into markup unescaped — X24 reached only 4% of this repository's production lines — rust (668,058 lines) was left unread. Not scored: a score over a minority of the product would be published as the whole of it.
  • X26 Unsynchronised callback handoff — not applicable — the code was read and holds no site of this kind, so there is nothing for this check to judge
  • X3 Exception handling — X3 reached only 4% of this repository's production lines — rust (668,058 lines) was left unread. Not scored: a score over a minority of the product would be published as the whole of it.
  • X32 Type resolved by simple name across every loaded assembly — This check is about how a .NET program searches the assemblies loaded into its process for a type, and this repository contains no .NET source, so there is nothing here for it to assess. Not a gap in the analyzer and not a finding about your code.
  • X4 Structured logging — This check asks whether log calls keep a message's values apart from its text, which needs a logger that can carry them as fields. This repository's Rust was read, and it logs through none: the `log` crate's macros take one finished message (as log4net does in C#; its `kv` values are an opt-in its backends mostly drop), `println!`/`eprintln!` are not loggers, or it makes no log call outside its tests and examples at all. Calls through `tracing` (`tracing::info!`, or `info!` imported from it) would be judged.
  • X6 Hand-rolled structured-format parsing — Advisory — this card reports evidence and never carries a score, so there is nothing missing here.

Appendix A — Findings (grouped)

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

Critical — 117 finding(s)
D29 · Static Analysis (SAST) · REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • + 29 more in this group — see findings.md.
D29 · Static Analysis (SAST) · REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • + 19 more in this group — see findings.md.
D28 · Secrets (history) · High secret · ×9
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
D13 · REDACTED Scanning · Leaked secret · ×4
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
AX8 · Test isolation · Production project references a test project · ×2
  • Production project references a test project: ibcmd-dump → ibcmd-platform-spec — `ibcmd-dump` (production) references the test project `ibcmd-platform-spec`. Production must never depend on test code — it pulls a unit-test framework and test fixtures into the shipped product and inverts the only correct direction (tests depend on production, never the reverse). Move any shared helper into a production support library, or invert the reference.
  • Production project references a test project: ibcmd-rs → ibcmd-platform-spec — `ibcmd-rs` (production) references the test project `ibcmd-platform-spec`. Production must never depend on test code — it pulls a unit-test framework and test fixtures into the shipped product and inverts the only correct direction (tests depend on production, never the reverse). Move any shared helper into a production support library, or invert the reference.
D28 · Secrets (history) · REDACTED · ×1
  • REDACTED
D29 · Static Analysis (SAST) · REDACTED · ×1
  • REDACTED
D29 · Static Analysis (SAST) · REDACTED · ×1
  • REDACTED
D30 · Dependency Vulnerabilities · High CVE · ×1
  • REDACTED
Serious — 3769 finding(s)
D3 · God Classes · FunctionTooLong · ×154
  • FunctionTooLong: ibcmd_dump::mssql_dump::source_assets::write_source_asset_inner crates/ibcmd-dump/src/mssql_dump/source_assets.rs:2323 — FunctionTooLong — ibcmd_dump::mssql_dump::source_assets::write_source_asset_inner runs 798 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted) in one body. The bar is 100 significant lines; this is 698 over it, 7.98× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • FunctionTooLong: ibcmd_rs::run src/main.rs:29 — FunctionTooLong — ibcmd_rs::run runs 746 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted) in one body. The bar is 100 significant lines; this is 646 over it, 7.46× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • FunctionTooLong: extension.activate editors/vscode/src/extension.ts:19 — FunctionTooLong — activate runs 720 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 620 over it, 7.20× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • FunctionTooLong: ibcmd_config_apply::mssql_config_apply::plan_with_gate crates/ibcmd-config-apply/src/mssql_config_apply/mod.rs:972 — FunctionTooLong — ibcmd_config_apply::mssql_config_apply::plan_with_gate runs 595 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted) in one body. The bar is 100 significant lines; this is 495 over it, 5.95× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • FunctionTooLong: ibcmd_config_apply::mssql_config_apply::dynamic::plan_dynamic REDACTED:1133 — FunctionTooLong — ibcmd_config_apply::mssql_config_apply::dynamic::plan_dynamic runs 542 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted) in one body. The bar is 100 significant lines; this is 442 over it, 5.42× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • FunctionTooLong: ibcmd_rs::mssql_apply::apply_source_change_inner src/mssql_apply.rs:81 — FunctionTooLong — ibcmd_rs::mssql_apply::apply_source_change_inner runs 532 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted) in one body. The bar is 100 significant lines; this is 432 over it, 5.32× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • FunctionTooLong: ibcmd_xml::dcs_schema::rewrite_tokens crates/ibcmd-xml/src/dcs_schema.rs:4004 — FunctionTooLong — ibcmd_xml::dcs_schema::rewrite_tokens runs 530 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted) in one body. The bar is 100 significant lines; this is 430 over it, 5.30× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • FunctionTooLong: ibcmd_rs::mssql::stage_source_objects_patch REDACTED:3896 — FunctionTooLong — ibcmd_rs::mssql::stage_source_objects_patch runs 442 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted) in one body. The bar is 100 significant lines; this is 342 over it, 4.42× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • FunctionTooLong: ibcmd_form_writer::form_chart::chart_record crates/ibcmd-form-writer/src/form_chart.rs:283 — FunctionTooLong — ibcmd_form_writer::form_chart::chart_record runs 401 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted) in one body. The bar is 100 significant lines; this is 301 over it, 4.01× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • FunctionTooLong: ibcmd_config_apply::mssql_config_apply::removals::analyze REDACTED:112 — FunctionTooLong — ibcmd_config_apply::mssql_config_apply::removals::analyze runs 395 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted) in one body. The bar is 100 significant lines; this is 295 over it, 3.95× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • FunctionTooLong: ibcmd_restructure_engine::restructure::caches::trace_diagnostic::inspect crates/ibcmd-restructure-engine/src/restructure/caches/trace_diagnostic.rs:220 — FunctionTooLong — ibcmd_restructure_engine::restructure::caches::trace_diagnostic::inspect runs 380 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted) in one body. The bar is 100 significant lines; this is 280 over it, 3.80× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • FunctionTooLong: ibcmd_metadata_model::metadata_model::root_export::decode crates/ibcmd-metadata-model/src/metadata_model/root_export.rs:380 — FunctionTooLong — ibcmd_metadata_model::metadata_model::root_export::decode runs 362 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted) in one body. The bar is 100 significant lines; this is 262 over it, 3.62× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • FunctionTooLong: ibcmd_rs::mssql::empty_stage::audit_empty_stage src/mssql/empty_stage.rs:1121 — FunctionTooLong — ibcmd_rs::mssql::empty_stage::audit_empty_stage runs 345 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted) in one body. The bar is 100 significant lines; this is 245 over it, 3.45× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • FunctionTooLong: ibcmd_edt::codec::same_body_bytes crates/ibcmd-edt/src/codec.rs:1063 — FunctionTooLong — ibcmd_edt::codec::same_body_bytes runs 329 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted) in one body. The bar is 100 significant lines; this is 229 over it, 3.29× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • FunctionTooLong: ibcmd_config_apply::mssql_config_apply::recovery::write_recovery crates/ibcmd-config-apply/src/mssql_config_apply/recovery.rs:303 — FunctionTooLong — ibcmd_config_apply::mssql_config_apply::recovery::write_recovery runs 324 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted) in one body. The bar is 100 significant lines; this is 224 over it, 3.24× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • FunctionTooLong: ibcmd_compiler::compiler::bootstrap::compile_source_tree_mode crates/ibcmd-compiler/src/compiler/bootstrap.rs:406 — FunctionTooLong — ibcmd_compiler::compiler::bootstrap::compile_source_tree_mode runs 318 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted) in one body. The bar is 100 significant lines; this is 218 over it, 3.18× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • FunctionTooLong: ibcmd_restructure_engine::restructure::plan::plan_object REDACTED:1359 — FunctionTooLong — ibcmd_restructure_engine::restructure::plan::plan_object runs 315 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted) in one body. The bar is 100 significant lines; this is 215 over it, 3.15× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • FunctionTooLong: ibcmd_config_apply::mssql_config_apply::objects::analyze REDACTED:238 — FunctionTooLong — ibcmd_config_apply::mssql_config_apply::objects::analyze runs 314 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted) in one body. The bar is 100 significant lines; this is 214 over it, 3.14× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • FunctionTooLong: ibcmd_apply_check::apply_check::check::check_planned crates/ibcmd-apply-check/src/apply_check/check.rs:311 — FunctionTooLong — ibcmd_apply_check::apply_check::check::check_planned runs 287 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted) in one body. The bar is 100 significant lines; this is 187 over it, 2.87× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • FunctionTooLong: ibcmd_rs::mssql::activate_staged_main_verified_inner REDACTED:1073 — FunctionTooLong — ibcmd_rs::mssql::activate_staged_main_verified_inner runs 271 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted) in one body. The bar is 100 significant lines; this is 171 over it, 2.71× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • FunctionTooLong: ibcmd_config_apply::mssql_config_apply::sqlgen::render_apply_script REDACTED:377 — FunctionTooLong — ibcmd_config_apply::mssql_config_apply::sqlgen::render_apply_script runs 266 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted) in one body. The bar is 100 significant lines; this is 166 over it, 2.66× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • FunctionTooLong: ibcmd_rs::mssql::metadata_body_bootstrap_rows REDACTED:2022 — FunctionTooLong — ibcmd_rs::mssql::metadata_body_bootstrap_rows runs 258 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted) in one body. The bar is 100 significant lines; this is 158 over it, 2.58× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • FunctionTooLong: ibcmd_rs::mssql_extension_restructure::plan_from_source_trees REDACTED:1056 — FunctionTooLong — ibcmd_rs::mssql_extension_restructure::plan_from_source_trees runs 254 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted) in one body. The bar is 100 significant lines; this is 154 over it, 2.54× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • FunctionTooLong: ibcmd_form_writer::dynamic_list::dynamic_list_bag crates/ibcmd-form-writer/src/dynamic_list.rs:1132 — FunctionTooLong — ibcmd_form_writer::dynamic_list::dynamic_list_bag runs 252 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted) in one body. The bar is 100 significant lines; this is 152 over it, 2.52× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • FunctionTooLong: ibcmd_metadata_blob::parse_role_rights_xml crates/ibcmd-metadata-blob/src/lib.rs:3668 — FunctionTooLong — ibcmd_metadata_blob::parse_role_rights_xml runs 238 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted) in one body. The bar is 100 significant lines; this is 138 over it, 2.38× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • + 129 more in this group — see findings.md.
D3 · God Classes · FileTooLong · ×131
  • FileTooLong: mssql_dump/mod.rs crates/ibcmd-dump/src/mssql_dump/mod.rs — FileTooLong — 32995 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted), declaring 948 free functions. The bar is 500 significant lines; this is 32495 over it, 65.99× the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them.
  • FileTooLong: src/form_body.rs crates/ibcmd-form-body/src/form_body.rs — FileTooLong — 24395 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted), declaring 812 free functions. The bar is 500 significant lines; this is 23895 over it, 48.79× the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them.
  • FileTooLong: src/lib.rs crates/ibcmd-form-writer/src/lib.rs — FileTooLong — 17306 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted), declaring 596 free functions. The bar is 500 significant lines; this is 16806 over it, 34.61× the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them.
  • FileTooLong: src/lib.rs crates/ibcmd-moxel/src/lib.rs — FileTooLong — 9569 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted), declaring 347 free functions. The bar is 500 significant lines; this is 9069 over it, 19.14× the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them.
  • FileTooLong: src/lib.rs crates/ibcmd-schema/src/lib.rs — FileTooLong — 8492 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted), declaring 97 free functions. The bar is 500 significant lines; this is 7992 over it, 16.98× the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them.
  • FileTooLong: REDACTED REDACTED — FileTooLong — 8058 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted), declaring 328 free functions. The bar is 500 significant lines; this is 7558 over it, 16.12× the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them.
  • FileTooLong: src/lib.rs crates/ibcmd-metadata-blob/src/lib.rs — FileTooLong — 6073 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted), declaring 178 free functions. The bar is 500 significant lines; this is 5573 over it, 12.15× the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them.
  • FileTooLong: src/lib.rs crates/ibcmd-form-native/src/lib.rs — FileTooLong — 5370 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted), declaring 101 free functions. The bar is 500 significant lines; this is 4870 over it, 10.74× the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them.
  • FileTooLong: src/lib.rs crates/ibcmd-form-schema/src/lib.rs — FileTooLong — 5136 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted). The bar is 500 significant lines; this is 4636 over it, 10.27× the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them.
  • FileTooLong: mssql_dump/source_assets.rs crates/ibcmd-dump/src/mssql_dump/source_assets.rs — FileTooLong — 4069 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted), declaring 138 free functions. The bar is 500 significant lines; this is 3569 over it, 8.14× the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them.
  • FileTooLong: families/business_object.rs crates/ibcmd-compiler-families/src/compiler/families/business_object.rs — FileTooLong — 3609 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted), declaring 89 free functions. The bar is 500 significant lines; this is 3109 over it, 7.22× the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them.
  • FileTooLong: mssql_dump/refs.rs crates/ibcmd-dump/src/mssql_dump/refs.rs — FileTooLong — 3450 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted), declaring 152 free functions. The bar is 500 significant lines; this is 2950 over it, 6.90× the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them.
  • FileTooLong: src/dcs.rs crates/ibcmd-xml/src/dcs.rs — FileTooLong — 3427 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted), declaring 105 free functions. The bar is 500 significant lines; this is 2927 over it, 6.85× the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them.
  • FileTooLong: families/services.rs crates/ibcmd-compiler-families/src/compiler/families/services.rs — FileTooLong — 3383 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted), declaring 109 free functions. The bar is 500 significant lines; this is 2883 over it, 6.77× the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them.
  • FileTooLong: src/dcs_schema.rs crates/ibcmd-xml/src/dcs_schema.rs — FileTooLong — 3264 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted), declaring 115 free functions. The bar is 500 significant lines; this is 2764 over it, 6.53× the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them.
  • FileTooLong: families/simple.rs crates/ibcmd-compiler-families/src/compiler/families/simple.rs — FileTooLong — 2677 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted), declaring 79 free functions. The bar is 500 significant lines; this is 2177 over it, 5.35× the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them.
  • FileTooLong: src/cli.rs src/cli.rs — FileTooLong — 2590 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted). The bar is 500 significant lines; this is 2090 over it, 5.18× the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them.
  • FileTooLong: src/dcs.rs crates/ibcmd-form-body/src/dcs.rs — FileTooLong — 2415 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted), declaring 58 free functions. The bar is 500 significant lines; this is 1915 over it, 4.83× the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them.
  • FileTooLong: src/source_audit.rs src/source_audit.rs — FileTooLong — 2337 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted), declaring 67 free functions. The bar is 500 significant lines; this is 1837 over it, 4.67× the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them.
  • FileTooLong: bodies/mxl_native.rs crates/ibcmd-compiler/src/compiler/bodies/mxl_native.rs — FileTooLong — 2236 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted), about 67% of them inside a single declaration: BodyWriter (2 blocks, 714-2692), declaring 38 free functions. The bar is 500 significant lines; this is 1736 over it, 4.47× the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body — the parts that share the same inputs and are named together — into its own unit in a sibling file, and have the original call them.
  • FileTooLong: families/utility.rs crates/ibcmd-compiler-families/src/compiler/families/utility.rs — FileTooLong — 2099 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted), declaring 72 free functions. The bar is 500 significant lines; this is 1599 over it, 4.20× the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them.
  • FileTooLong: metadata/services.rs crates/ibcmd-xml/src/metadata/services.rs — FileTooLong — 2056 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted), declaring 62 free functions. The bar is 500 significant lines; this is 1556 over it, 4.11× the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them.
  • FileTooLong: REDACTED REDACTED — FileTooLong — 1946 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted), declaring 36 free functions. The bar is 500 significant lines; this is 1446 over it, 3.89× the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them.
  • FileTooLong: metadata/common.rs crates/ibcmd-xml/src/metadata/common.rs — FileTooLong — 1867 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted), declaring 45 free functions. The bar is 500 significant lines; this is 1367 over it, 3.73× the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them.
  • FileTooLong: commands/cf.rs src/commands/cf.rs — FileTooLong — 1802 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted), declaring 46 free functions. The bar is 500 significant lines; this is 1302 over it, 3.60× 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.
  • + 106 more in this group — see findings.md.
D4 · Code Duplication · Duplicated block (6 lines × 2) · ×110
  • Duplicated block (6 lines × 2) crates/ibcmd-1c-text/src/xml.rs:9 — crates/ibcmd-1c-text/src/xml.rs:9-14 | src/source_oracle.rs:1083-1088 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-1c-text/src/xml.rs:9` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (6 lines × 2) crates/ibcmd-1c-vocab/src/role_rights.rs:252 — crates/ibcmd-1c-vocab/src/role_rights.rs:252-257 | crates/ibcmd-1c-vocab/src/role_rights.rs:281-286 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-1c-vocab/src/role_rights.rs:252` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, `crates/ibcmd-1c-vocab/src/role_rights.rs:251` calls `Some` and `crates/ibcmd-1c-vocab/src/role_rights.rs:276` does not — after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
  • Duplicated block (6 lines × 2) crates/ibcmd-1c-vocab/src/types.rs:249 — crates/ibcmd-1c-vocab/src/types.rs:249-254 | crates/ibcmd-dump/src/mssql_dump/mod.rs:19317-19322 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-1c-vocab/src/types.rs:249` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (6 lines × 2) crates/ibcmd-apply-check/src/apply_check/cli.rs:104 — crates/ibcmd-apply-check/src/apply_check/cli.rs:104-109 | src/commands/objects.rs:142-147 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice. Note first that the copies are not typed on the same thing: the declarations holding them bind `args` to `&MssqlApplyCheckArgs` in one and `&ObjectsSourceArgs` in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH — their common supertype where they have one, or a new abstraction over them where they do not — and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract.
  • Duplicated block (6 lines × 2) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:616 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:616-621 | crates/ibcmd-compiler-families/src/compiler/families/utility.rs:356-361 — before extracting anything, compare `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs` and `crates/ibcmd-compiler-families/src/compiler/families/utility.rs` as WHOLE FILES: this scan already matched 65 separate duplicated blocks between them, totalling at least 934 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:616` it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows — the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members' bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run — a one-line delegation has no helper inside it to lift — so generate the run from the set it enumerates, or accept it and keep each member's own documentation with it.
  • Duplicated block (6 lines × 2) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:1932 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:1932-1937 | crates/ibcmd-compiler-families/src/compiler/families/utility.rs:937-942 — before extracting anything, compare `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs` and `crates/ibcmd-compiler-families/src/compiler/families/utility.rs` as WHOLE FILES: this scan already matched 65 separate duplicated blocks between them, totalling at least 934 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:1932` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (6 lines × 2) crates/ibcmd-compiler-families/src/compiler/families/services.rs:412 — crates/ibcmd-compiler-families/src/compiler/families/services.rs:412-417 | crates/ibcmd-compiler-families/src/compiler/families/services.rs:578-583 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/services.rs:412` it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows — the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members' bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run — a one-line delegation has no helper inside it to lift — so generate the run from the set it enumerates, or accept it and keep each member's own documentation with it.
  • Duplicated block (6 lines × 2) crates/ibcmd-compiler-families/src/compiler/families/services.rs:818 — crates/ibcmd-compiler-families/src/compiler/families/services.rs:818-823 | crates/ibcmd-compiler-families/src/compiler/families/services.rs:981-986 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/services.rs:818` it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows — the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members' bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run — a one-line delegation has no helper inside it to lift — so generate the run from the set it enumerates, or accept it and keep each member's own documentation with it.
  • Duplicated block (6 lines × 2) crates/ibcmd-compiler-families/src/compiler/families/simple.rs:1206 — crates/ibcmd-compiler-families/src/compiler/families/simple.rs:1206-1211 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:1503-1508 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/simple.rs:1206` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (6 lines × 2) REDACTED:541 — REDACTED:541-546 | crates/ibcmd-config-apply/src/mssql_config_apply/dynamic_metadata.rs:393-398 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `REDACTED:541` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (6 lines × 2) REDACTED:802 — REDACTED:802-807 | crates/ibcmd-config-apply/src/mssql_config_apply/synonyms.rs:105-110 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `REDACTED:802` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (6 lines × 2) crates/ibcmd-dump/src/mssql_dump/eds_export.rs:126 — crates/ibcmd-dump/src/mssql_dump/eds_export.rs:126-131 | crates/ibcmd-dump/src/mssql_dump/model_export.rs:602-607 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/eds_export.rs:126` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (6 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:15081 — crates/ibcmd-dump/src/mssql_dump/mod.rs:15081-15087 | crates/ibcmd-dump/src/mssql_dump/mod.rs:27124-27129 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:15081` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
  • Duplicated block (6 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:17014 — crates/ibcmd-dump/src/mssql_dump/mod.rs:17014-17019 | crates/ibcmd-dump/src/mssql_dump/mod.rs:35481-35486 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:17014` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (6 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:18998 — crates/ibcmd-dump/src/mssql_dump/mod.rs:18998-19003 | crates/ibcmd-dump/src/mssql_dump/mod.rs:26436-26441 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. Note first that the copies are not typed on the same thing: the declarations holding them bind `definitions` to `&[]` in one and `&[ChartStandardTabularSectionDefinition]` in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH — their common supertype where they have one, or a new abstraction over them where they do not — and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract.
  • Duplicated block (6 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:22468 — crates/ibcmd-dump/src/mssql_dump/mod.rs:22468-22473 | crates/ibcmd-dump/src/mssql_dump/mod.rs:23075-23080 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:22468` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (6 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:23180 — crates/ibcmd-dump/src/mssql_dump/mod.rs:23180-23185 | crates/ibcmd-dump/src/mssql_dump/mod.rs:23546-23551 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:23180` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (6 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:31897 — crates/ibcmd-dump/src/mssql_dump/mod.rs:31897-31903 | crates/ibcmd-dump/src/mssql_dump/mod.rs:32680-32685 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (6 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:32915 — crates/ibcmd-dump/src/mssql_dump/mod.rs:32915-32920 | crates/ibcmd-dump/src/mssql_dump/mod.rs:33003-33008 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:32915` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, `crates/ibcmd-dump/src/mssql_dump/mod.rs:32914` calls `with_capacity` and `crates/ibcmd-dump/src/mssql_dump/mod.rs:33002` does not — after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
  • Duplicated block (6 lines × 2) crates/ibcmd-dump/src/mssql_dump/refs.rs:4692 — crates/ibcmd-dump/src/mssql_dump/refs.rs:4692-4697 | crates/ibcmd-moxel/src/lib.rs:10594-10599 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/refs.rs:4692` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (6 lines × 2) crates/ibcmd-dump/src/mssql_dump/source_assets.rs:4079 — crates/ibcmd-dump/src/mssql_dump/source_assets.rs:4079-4084 | crates/ibcmd-dump/src/mssql_dump/source_assets.rs:4133-4138 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (6 lines × 2) crates/ibcmd-form-body/src/form_body.rs:3012 — crates/ibcmd-form-body/src/form_body.rs:3012-3017 | crates/ibcmd-form-body/src/form_body.rs:3049-3054 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-form-body/src/form_body.rs:3012` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, `crates/ibcmd-form-body/src/form_body.rs:3018` calls `Some` and `crates/ibcmd-form-body/src/form_body.rs:3055` does not — after which the two agree again for 3 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
  • Duplicated block (6 lines × 2) crates/ibcmd-form-body/src/form_body.rs:8703 — crates/ibcmd-form-body/src/form_body.rs:8703-8708 | crates/ibcmd-form-body/src/form_body.rs:8764-8769 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, `crates/ibcmd-form-body/src/form_body.rs:8758` calls `Some`, `clone`, `form_query_extension_item_name` and `crates/ibcmd-form-body/src/form_body.rs:8702` does not — after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
  • Duplicated block (6 lines × 2) crates/ibcmd-form-body/src/form_body.rs:12265 — crates/ibcmd-form-body/src/form_body.rs:12265-12270 | crates/ibcmd-form-writer/src/lib.rs:18757-18764 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-form-body/src/form_body.rs:12265` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
  • Duplicated block (6 lines × 2) crates/ibcmd-form-body/src/form_body.rs:15868 — crates/ibcmd-form-body/src/form_body.rs:15868-15873 | crates/ibcmd-form-body/src/form_body.rs:16399-16404 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-form-body/src/form_body.rs:15868` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • + 85 more in this group — see findings.md.
D2 · Cognitive Complexity · ibcmd_dump · ×109
  • ibcmd_dump::mssql_dump::dump_table_rows_streamed (cognitive 324) crates/ibcmd-dump/src/mssql_dump/mod.rs:4807 — ibcmd_dump::mssql_dump::dump_table_rows_streamed has cognitive complexity 324 (threshold 15). Drivers by points: if/else 160 (217 pts), boolean chains 83, loops 11 (17 pts), match/switch 6 (7 pts) (nesting depth added 64). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_dump::mssql_dump::dump_table_rows_with_options_mode (cognitive 126) crates/ibcmd-dump/src/mssql_dump/mod.rs:3941 — ibcmd_dump::mssql_dump::dump_table_rows_with_options_mode has cognitive complexity 126 (threshold 15). Drivers by points: if/else 76 (91 pts), boolean chains 15, loops 10 (15 pts), match/switch 2 (5 pts) (nesting depth added 23). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level.
  • ibcmd_dump::mssql_dump::source_assets::write_source_asset_inner (cognitive 123) crates/ibcmd-dump/src/mssql_dump/source_assets.rs:2323 — ibcmd_dump::mssql_dump::source_assets::write_source_asset_inner has cognitive complexity 123 (threshold 15). Drivers by points: if/else 49 (92 pts), match/switch 7 (15 pts), loops 5 (14 pts), boolean chains 2 (nesting depth added 60). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_dump::mssql_dump::extract_metadata_source_xml_from_text_row_with_owner_graph_diagnostic (cognitive 99) crates/ibcmd-dump/src/mssql_dump/mod.rs:13579 — ibcmd_dump::mssql_dump::extract_metadata_source_xml_from_text_row_with_owner_graph_diagnostic has cognitive complexity 99 (threshold 15). Drivers by points: if/else 68 (74 pts), boolean chains 16, match/switch 5 (9 pts) (nesting depth added 10). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level.
  • ibcmd_dump::mssql_dump::dump_table_row_bytes (cognitive 87) crates/ibcmd-dump/src/mssql_dump/mod.rs:7225 — ibcmd_dump::mssql_dump::dump_table_row_bytes has cognitive complexity 87 (threshold 15). Drivers by points: if/else 31 (54 pts), match/switch 12 (28 pts), boolean chains 5 (nesting depth added 39). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_dump::mssql_dump::format_register_source_xml (cognitive 78) crates/ibcmd-dump/src/mssql_dump/mod.rs:38420 — ibcmd_dump::mssql_dump::format_register_source_xml has cognitive complexity 78 (threshold 15). Drivers by points: if/else 24 (63 pts), boolean chains 8, loops 3 (7 pts) (nesting depth added 43). To reduce it, flatten the nesting: this score is depth rather than breadth — most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language's equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function.
  • ibcmd_dump::mssql_dump::parse_attribute_tabular_section_child_objects_with_declared_failure (cognitive 67) crates/ibcmd-dump/src/mssql_dump/mod.rs:20298 — ibcmd_dump::mssql_dump::parse_attribute_tabular_section_child_objects_with_declared_failure has cognitive complexity 67 (threshold 15). Drivers by points: if/else 29 (52 pts), boolean chains 7, match/switch 2 (5 pts), loops 2 (3 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.
  • ibcmd_dump::mssql_dump::refs::standalone_child_reference (cognitive 64) crates/ibcmd-dump/src/mssql_dump/refs.rs:1582 — ibcmd_dump::mssql_dump::refs::standalone_child_reference has cognitive complexity 64 (threshold 15). Drivers by points: if/else 35 (39 pts), boolean chains 25 (nesting depth added 4). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition.
  • ibcmd_dump::mssql_dump::extension::root::extension_root_xml (cognitive 54) crates/ibcmd-dump/src/mssql_dump/extension/root.rs:56 — ibcmd_dump::mssql_dump::extension::root::extension_root_xml has cognitive complexity 54 (threshold 15). Drivers by points: if/else 22 (33 pts), match/switch 8 (13 pts), loops 4 (7 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.
  • ibcmd_dump::mssql_dump::dump_config_inner (cognitive 52) crates/ibcmd-dump/src/mssql_dump/mod.rs:2576 — ibcmd_dump::mssql_dump::dump_config_inner has cognitive complexity 52 (threshold 15). Drivers by points: if/else 28 (41 pts), boolean chains 7, loops 2, match/switch 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.
  • ibcmd_dump::mssql_dump::metadata::without_adoption_headers (cognitive 49) crates/ibcmd-dump/src/mssql_dump/metadata.rs:222 — ibcmd_dump::mssql_dump::metadata::without_adoption_headers has cognitive complexity 49 (threshold 15). Drivers by points: if/else 20 (42 pts), boolean chains 5, loops 2 (nesting depth added 22). To reduce it, flatten the nesting: this score is depth rather than breadth — most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language's equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function.
  • ibcmd_dump::mssql_dump::source_assets::source_assets_from_metadata_text_inner (cognitive 49) crates/ibcmd-dump/src/mssql_dump/source_assets.rs:1582 — ibcmd_dump::mssql_dump::source_assets::source_assets_from_metadata_text_inner has cognitive complexity 49 (threshold 15). Drivers by points: if/else 20 (33 pts), match/switch 4 (10 pts), boolean chains 4, loops 2 (nesting depth added 19). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_dump::mssql_dump::source_assets::normalize_ws_definition_own_namespace_prefixes (cognitive 49) crates/ibcmd-dump/src/mssql_dump/source_assets.rs:1941 — ibcmd_dump::mssql_dump::source_assets::normalize_ws_definition_own_namespace_prefixes has cognitive complexity 49 (threshold 15). Drivers by points: if/else 14 (38 pts), loops 4 (7 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.
  • ibcmd_dump::mssql_dump::parse_register_properties_from_text (cognitive 48) crates/ibcmd-dump/src/mssql_dump/mod.rs:18119 — ibcmd_dump::mssql_dump::parse_register_properties_from_text has cognitive complexity 48 (threshold 15). Drivers by points: if/else 36 (37 pts), boolean chains 7, match/switch 2 (4 pts) (nesting depth added 3). To reduce it, split the body: this score is breadth rather than depth — many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
  • ibcmd_dump::mssql_dump::push_metadata_child_properties_xml_with_tail_order (cognitive 40) crates/ibcmd-dump/src/mssql_dump/mod.rs:41576 — ibcmd_dump::mssql_dump::push_metadata_child_properties_xml_with_tail_order has cognitive complexity 40 (threshold 15). Drivers by points: if/else 31 (36 pts), boolean chains 2, match/switch 1 (2 pts) (nesting depth added 6). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level.
  • ibcmd_dump::mssql_dump::source_assets::source_asset_paths_with_indexes (cognitive 40) crates/ibcmd-dump/src/mssql_dump/source_assets.rs:969 — ibcmd_dump::mssql_dump::source_assets::source_asset_paths_with_indexes has cognitive complexity 40 (threshold 15). Drivers by points: if/else 10 (26 pts), loops 6 (9 pts), boolean chains 5 (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.
  • ibcmd_dump::mssql_dump::parse_cct_tabular_sections_indexed (cognitive 37) crates/ibcmd-dump/src/mssql_dump/mod.rs:27671 — ibcmd_dump::mssql_dump::parse_cct_tabular_sections_indexed has cognitive complexity 37 (threshold 15). Drivers by points: if/else 13 (28 pts), loops 3 (5 pts), boolean chains 4 (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.
  • ibcmd_dump::mssql_dump::validate_catalog_child_objects (cognitive 36) crates/ibcmd-dump/src/mssql_dump/mod.rs:28699 — ibcmd_dump::mssql_dump::validate_catalog_child_objects has cognitive complexity 36 (threshold 15). Drivers by points: if/else 21 (32 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.
  • ibcmd_dump::mssql_dump::refs::build_standalone_object_reference_index_from_texts (cognitive 35) crates/ibcmd-dump/src/mssql_dump/refs.rs:1283 — ibcmd_dump::mssql_dump::refs::build_standalone_object_reference_index_from_texts has cognitive complexity 35 (threshold 15). Drivers by points: if/else 12 (29 pts), loops 3 (6 pts) (nesting depth added 20). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_dump::mssql_dump::refs::extract_configuration_source_xml (cognitive 35) crates/ibcmd-dump/src/mssql_dump/refs.rs:3563 — ibcmd_dump::mssql_dump::refs::extract_configuration_source_xml has cognitive complexity 35 (threshold 15). Drivers by points: if/else 18 (24 pts), loops 2 (4 pts), match/switch 2 (4 pts), boolean chains 3 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_dump::mssql_dump::parse_flowchart_item (cognitive 34) crates/ibcmd-dump/src/mssql_dump/mod.rs:8213 — ibcmd_dump::mssql_dump::parse_flowchart_item has cognitive complexity 34 (threshold 15). Drivers by points: if/else 10 (21 pts), boolean chains 8, match/switch 2 (3 pts), loops 1 (2 pts) (nesting depth added 13). The drivers above price the dispatch low by construction — a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full — so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident.
  • ibcmd_dump::mssql_dump::validate_document_owner_graph_child_objects (cognitive 32) crates/ibcmd-dump/src/mssql_dump/mod.rs:30189 — ibcmd_dump::mssql_dump::validate_document_owner_graph_child_objects has cognitive complexity 32 (threshold 15). Drivers by points: if/else 18 (28 pts), loops 3 (4 pts) (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_dump::mssql_dump::parse_business_process_tabular_sections_indexed (cognitive 32) crates/ibcmd-dump/src/mssql_dump/mod.rs:31327 — ibcmd_dump::mssql_dump::parse_business_process_tabular_sections_indexed has cognitive complexity 32 (threshold 15). Drivers by points: if/else 10 (22 pts), boolean chains 5, loops 3 (5 pts) (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_dump::mssql_dump::format_catalog_source_xml (cognitive 32) crates/ibcmd-dump/src/mssql_dump/mod.rs:39227 — ibcmd_dump::mssql_dump::format_catalog_source_xml has cognitive complexity 32 (threshold 15). Drivers by points: if/else 17 (18 pts), loops 6 (13 pts), boolean chains 1 (nesting depth added 8). To reduce it, split the body: this score is breadth rather than depth — many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
  • ibcmd_dump::mssql_dump::register_child_object_tag (cognitive 31) crates/ibcmd-dump/src/mssql_dump/mod.rs:19857 — ibcmd_dump::mssql_dump::register_child_object_tag has cognitive complexity 31 (threshold 15). Drivers by points: if/else 17 (21 pts), boolean chains 8, loops 1 (2 pts) (nesting depth added 5). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition.
  • + 84 more in this group — see findings.md.
D2 · Cognitive Complexity · ibcmd_rs · ×100
  • ibcmd_rs::run (cognitive 135) src/main.rs:29 — ibcmd_rs::run has cognitive complexity 135 (threshold 15). Drivers by points: if/else 62 (101 pts), loops 8 (19 pts), match/switch 7 (13 pts), boolean chains 2 (nesting depth added 56). The drivers above price the dispatch low by construction — a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full — so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident.
  • ibcmd_rs::mssql::stage_source_objects_patch (cognitive 82) REDACTED:3896 — ibcmd_rs::mssql::stage_source_objects_patch has cognitive complexity 82 (threshold 15). Drivers by points: if/else 36 (57 pts), match/switch 5 (12 pts), boolean chains 7, loops 4 (6 pts) (nesting depth added 30). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_rs::mssql::empty_stage::audit_empty_stage (cognitive 72) src/mssql/empty_stage.rs:1121 — ibcmd_rs::mssql::empty_stage::audit_empty_stage has cognitive complexity 72 (threshold 15). Drivers by points: if/else 29 (49 pts), loops 11 (12 pts), match/switch 4 (9 pts), boolean chains 2 (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.
  • ibcmd_rs::mssql_apply::apply_source_change_inner (cognitive 68) src/mssql_apply.rs:81 — ibcmd_rs::mssql_apply::apply_source_change_inner has cognitive complexity 68 (threshold 15). Drivers by points: if/else 51 (57 pts), boolean chains 7, match/switch 4 (nesting depth added 6). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level.
  • ibcmd_rs::mssql::activate_staged_main_verified_inner (cognitive 59) REDACTED:1073 — ibcmd_rs::mssql::activate_staged_main_verified_inner has cognitive complexity 59 (threshold 15). Drivers by points: if/else 35 (45 pts), boolean chains 9, match/switch 3 (5 pts) (nesting depth added 12). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level.
  • ibcmd_rs::mssql_extension_restructure::classify (cognitive 59) REDACTED:259 — ibcmd_rs::mssql_extension_restructure::classify has cognitive complexity 59 (threshold 15). Drivers by points: if/else 16 (46 pts), boolean chains 9, loops 2 (4 pts) (nesting depth added 32). To reduce it, flatten the nesting: this score is depth rather than breadth — most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language's equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function.
  • ibcmd_rs::source_audit::audit_native_form_writer (cognitive 57) src/source_audit.rs:1536 — ibcmd_rs::source_audit::audit_native_form_writer has cognitive complexity 57 (threshold 15). Drivers by points: if/else 14 (36 pts), match/switch 5 (11 pts), loops 3 (7 pts), boolean chains 3 (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.
  • ibcmd_rs::mssql_extension_restructure::plan_from_source_trees (cognitive 56) REDACTED:1056 — ibcmd_rs::mssql_extension_restructure::plan_from_source_trees has cognitive complexity 56 (threshold 15). Drivers by points: if/else 24 (41 pts), loops 7 (9 pts), boolean chains 6 (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.
  • ibcmd_rs::file_import::prepare_locked (cognitive 49) src/file_import.rs:281 — ibcmd_rs::file_import::prepare_locked has cognitive complexity 49 (threshold 15). Drivers by points: if/else 23 (39 pts), loops 4 (7 pts), boolean chains 3 (nesting depth added 19). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_rs::extension::adopted::rewrite_element (cognitive 45) src/extension/adopted.rs:251 — ibcmd_rs::extension::adopted::rewrite_element has cognitive complexity 45 (threshold 15). Drivers by points: if/else 18 (35 pts), boolean chains 6, loops 2 (4 pts) (nesting depth added 19). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_rs::dropin::export_queries::run (cognitive 44) src/dropin/export_queries.rs:14 — ibcmd_rs::dropin::export_queries::run has cognitive complexity 44 (threshold 15). Drivers by points: if/else 24 (39 pts), match/switch 3, 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.
  • ibcmd_rs::mssql::prepare_form_body_row (cognitive 42) REDACTED:6709 — ibcmd_rs::mssql::prepare_form_body_row has cognitive complexity 42 (threshold 15). Drivers by points: if/else 24 (31 pts), match/switch 3 (6 pts), boolean chains 5 (nesting depth added 10). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level.
  • ibcmd_rs::source_audit::audit_role_rights_writer (cognitive 41) src/source_audit.rs:3037 — ibcmd_rs::source_audit::audit_role_rights_writer has cognitive complexity 41 (threshold 15). Drivers by points: if/else 10 (30 pts), match/switch 3 (8 pts), loops 2, boolean chains 1 (nesting depth added 25). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_rs::dropin::parse::parse_infobase (cognitive 40) src/dropin/parse.rs:927 — ibcmd_rs::dropin::parse::parse_infobase has cognitive complexity 40 (threshold 15). Drivers by points: if/else 16 (23 pts), match/switch 8 (11 pts), loops 3 (4 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.
  • ibcmd_rs::compatibility::validate_compatibility_matrix (cognitive 37) src/compatibility.rs:184 — ibcmd_rs::compatibility::validate_compatibility_matrix has cognitive complexity 37 (threshold 15). Drivers by points: if/else 14 (24 pts), loops 4 (6 pts), boolean chains 5, match/switch 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.
  • ibcmd_rs::infobase_oracle::selected_dump_file_names_for_path (cognitive 37) src/infobase_oracle.rs:720 — ibcmd_rs::infobase_oracle::selected_dump_file_names_for_path has cognitive complexity 37 (threshold 15). Drivers by points: if/else 18 (27 pts), boolean chains 10 (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.
  • ibcmd_rs::commands::cf::export (cognitive 35) src/commands/cf.rs:1180 — ibcmd_rs::commands::cf::export has cognitive complexity 35 (threshold 15). Drivers by points: if/else 18 (24 pts), boolean chains 8, match/switch 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.
  • ibcmd_rs::server::serve (cognitive 35) src/server/mod.rs:125 — ibcmd_rs::server::serve has cognitive complexity 35 (threshold 15). Drivers by points: if/else 10 (23 pts), match/switch 4 (7 pts), boolean chains 3, loops 2 (nesting depth added 16). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_rs::dropin::parse::scan (cognitive 34) src/dropin/parse.rs:751 — ibcmd_rs::dropin::parse::scan has cognitive complexity 34 (threshold 15). Drivers by points: if/else 8 (19 pts), match/switch 3 (12 pts), boolean chains 2, loops 1 (nesting depth added 20). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_rs::file_extension_export::export (cognitive 34) src/file_extension_export.rs:51 — ibcmd_rs::file_extension_export::export has cognitive complexity 34 (threshold 15). Drivers by points: if/else 14 (24 pts), loops 4 (6 pts), boolean chains 3, 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.
  • ibcmd_rs::load::compiled::compile_edit (cognitive 34) src/load/compiled.rs:106 — ibcmd_rs::load::compiled::compile_edit has cognitive complexity 34 (threshold 15). Drivers by points: if/else 11 (16 pts), match/switch 4 (8 pts), loops 5 (6 pts), boolean chains 4 (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.
  • ibcmd_rs::source_audit::moxel_generated_types_from_tree (cognitive 34) src/source_audit.rs:2443 — ibcmd_rs::source_audit::moxel_generated_types_from_tree has cognitive complexity 34 (threshold 15). Drivers by points: if/else 9 (27 pts), loops 3 (6 pts), boolean chains 1 (nesting depth added 21). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_rs::form_provenance::correlate (cognitive 32) src/form_provenance.rs:526 — ibcmd_rs::form_provenance::correlate has cognitive complexity 32 (threshold 15). Drivers by points: if/else 7 (14 pts), loops 8 (14 pts), boolean chains 2, match/switch 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.
  • ibcmd_rs::mssql::files_stage::select_with (cognitive 32) src/mssql/files_stage.rs:505 — ibcmd_rs::mssql::files_stage::select_with has cognitive complexity 32 (threshold 15). Drivers by points: if/else 12 (26 pts), loops 2 (4 pts), boolean chains 2 (nesting depth added 16). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_rs::mssql::offline_compile::compile_source_rows_offline (cognitive 31) src/mssql/offline_compile.rs:36 — ibcmd_rs::mssql::offline_compile::compile_source_rows_offline has cognitive complexity 31 (threshold 15). Drivers by points: if/else 15 (20 pts), loops 6 (8 pts), boolean chains 3 (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.
  • + 75 more in this group — see findings.md.
D4 · Code Duplication · Duplicated block (7 lines × 2) · ×96
  • Duplicated block (7 lines × 2) crates/ibcmd-1c-vocab/src/commands.rs:259 — crates/ibcmd-1c-vocab/src/commands.rs:259-265 | crates/ibcmd-dump/src/mssql_dump/mod.rs:36318-36327 — before extracting anything, compare `crates/ibcmd-1c-vocab/src/commands.rs` and `crates/ibcmd-dump/src/mssql_dump/mod.rs` as WHOLE FILES: this scan already matched 4 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. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-1c-vocab/src/commands.rs:259` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, `crates/ibcmd-1c-vocab/src/commands.rs:266` calls `Some`, `standard_picture_name`, `to_string` and `crates/ibcmd-dump/src/mssql_dump/mod.rs:36328` does not — after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
  • Duplicated block (7 lines × 2) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:707 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:707-713 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:1158-1164 — before extracting anything, compare `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs` and `crates/ibcmd-compiler-families/src/compiler/families/simple.rs` as WHOLE FILES: this scan already matched 12 separate duplicated blocks between them, totalling at least 149 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:707` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note first that the copies are not typed on the same thing: the declarations holding them bind `profile` to `&BusinessObjectMetadataProfile` in one and `&SimpleMetadataProfile` in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH — their common supertype where they have one, or a new abstraction over them where they do not — and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract.
  • Duplicated block (7 lines × 2) crates/ibcmd-compiler-families/src/compiler/families/form.rs:748 — crates/ibcmd-compiler-families/src/compiler/families/form.rs:748-754 | crates/ibcmd-compiler/src/compiler/bootstrap.rs:1847-1853 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/form.rs:748` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (7 lines × 2) crates/ibcmd-compiler-families/src/compiler/families/services.rs:1248 — crates/ibcmd-compiler-families/src/compiler/families/services.rs:1248-1254 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:1014-1020 — before extracting anything, compare `crates/ibcmd-compiler-families/src/compiler/families/services.rs` and `crates/ibcmd-compiler-families/src/compiler/families/simple.rs` as WHOLE FILES: this scan already matched 36 separate duplicated blocks between them, totalling at least 406 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/services.rs:1248` it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows — the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members' bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run — a one-line delegation has no helper inside it to lift — so generate the run from the set it enumerates, or accept it and keep each member's own documentation with it.
  • Duplicated block (7 lines × 2) crates/ibcmd-compiler/src/compiler/bootstrap.rs:894 — crates/ibcmd-compiler/src/compiler/bootstrap.rs:894-900 | src/conversion.rs:1425-1431 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice.
  • Duplicated block (7 lines × 2) REDACTED:470 — REDACTED:470-476 | REDACTED:523-529 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `REDACTED:470` it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows — the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members' bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run — a one-line delegation has no helper inside it to lift — so generate the run from the set it enumerates, or accept it and keep each member's own documentation with it. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, `REDACTED:477` calls `text`, `to_ascii_uppercase` and `REDACTED:530` does not — after which the two agree again for 3 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
  • Duplicated block (7 lines × 2) REDACTED:773 — REDACTED:773-779 | REDACTED:726-732 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `REDACTED:773` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (7 lines × 2) crates/ibcmd-core/src/migration/v2_20_to_v2_21.rs:123 — crates/ibcmd-core/src/migration/v2_20_to_v2_21.rs:123-129 | crates/ibcmd-core/src/migration/v2_21_to_v2_20.rs:135-141 — before extracting anything, compare `crates/ibcmd-core/src/migration/v2_20_to_v2_21.rs` and `crates/ibcmd-core/src/migration/v2_21_to_v2_20.rs` as WHOLE FILES: this scan already matched 6 separate duplicated blocks between them, totalling at least 67 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place.
  • Duplicated block (7 lines × 2) crates/ibcmd-core/src/migration/v2_20_to_v2_21.rs:164 — crates/ibcmd-core/src/migration/v2_20_to_v2_21.rs:164-170 | crates/ibcmd-core/src/migration/v2_21_to_v2_20.rs:189-195 — before extracting anything, compare `crates/ibcmd-core/src/migration/v2_20_to_v2_21.rs` and `crates/ibcmd-core/src/migration/v2_21_to_v2_20.rs` as WHOLE FILES: this scan already matched 6 separate duplicated blocks between them, totalling at least 67 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. 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 `return` inside it is the body's own exit and keeps its meaning in the moved unit.
  • Duplicated block (7 lines × 2) crates/ibcmd-dump-readers/src/extension/predefined.rs:23 — crates/ibcmd-dump-readers/src/extension/predefined.rs:23-29 | crates/ibcmd-dump-readers/src/extension/predefined.rs:71-77 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump-readers/src/extension/predefined.rs:23` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (7 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:5127 — crates/ibcmd-dump/src/mssql_dump/mod.rs:5127-5133 | crates/ibcmd-dump/src/mssql_dump/mod.rs:5240-5246 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:5127` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (7 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:14835 — crates/ibcmd-dump/src/mssql_dump/mod.rs:14835-14841 | crates/ibcmd-dump/src/mssql_dump/mod.rs:34131-34137 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (7 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:17208 — crates/ibcmd-dump/src/mssql_dump/mod.rs:17208-17214 | crates/ibcmd-dump/src/mssql_dump/refs.rs:4617-4623 — before extracting anything, compare `crates/ibcmd-dump/src/mssql_dump/mod.rs` and `crates/ibcmd-dump/src/mssql_dump/refs.rs` as WHOLE FILES: this scan already matched 13 separate duplicated blocks between them, totalling at least 117 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:17208` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (7 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:18992 — crates/ibcmd-dump/src/mssql_dump/mod.rs:18992-18998 | crates/ibcmd-dump/src/mssql_dump/mod.rs:27223-27229 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:18992` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (7 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:23225 — crates/ibcmd-dump/src/mssql_dump/mod.rs:23225-23231 | crates/ibcmd-dump/src/mssql_dump/mod.rs:27548-27554 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:23225` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (7 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:32371 — crates/ibcmd-dump/src/mssql_dump/mod.rs:32371-32377 | crates/ibcmd-dump/src/mssql_dump/mod.rs:33010-33016 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:32371` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (7 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:32652 — crates/ibcmd-dump/src/mssql_dump/mod.rs:32652-32658 | crates/ibcmd-dump/src/mssql_dump/refs.rs:520-526 — before extracting anything, compare `crates/ibcmd-dump/src/mssql_dump/mod.rs` and `crates/ibcmd-dump/src/mssql_dump/refs.rs` as WHOLE FILES: this scan already matched 13 separate duplicated blocks between them, totalling at least 117 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:32652` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (7 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:34138 — crates/ibcmd-dump/src/mssql_dump/mod.rs:34138-34144 | crates/ibcmd-dump/src/mssql_dump/mod.rs:34176-34182 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:34138` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, `crates/ibcmd-dump/src/mssql_dump/mod.rs:34173` calls `Some` and `crates/ibcmd-dump/src/mssql_dump/mod.rs:34137` does not — after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
  • Duplicated block (7 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:34659 — crates/ibcmd-dump/src/mssql_dump/mod.rs:34659-34665 | crates/ibcmd-dump/src/mssql_dump/refs.rs:666-672 — before extracting anything, compare `crates/ibcmd-dump/src/mssql_dump/mod.rs` and `crates/ibcmd-dump/src/mssql_dump/refs.rs` as WHOLE FILES: this scan already matched 13 separate duplicated blocks between them, totalling at least 117 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, `crates/ibcmd-dump/src/mssql_dump/mod.rs:34657` calls `parse_common_attribute_additional_order_tail`, `parse_typed_metadata_properties_from_text` and `crates/ibcmd-dump/src/mssql_dump/refs.rs:665` does not — after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
  • Duplicated block (7 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:38735 — crates/ibcmd-dump/src/mssql_dump/mod.rs:38735-38741 | crates/ibcmd-dump/src/mssql_dump/mod.rs:38917-38923 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:38735` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (7 lines × 2) crates/ibcmd-dump/src/mssql_dump/model_export.rs:677 — crates/ibcmd-dump/src/mssql_dump/model_export.rs:677-683 | crates/ibcmd-dump/src/mssql_dump/model_export.rs:728-734 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/model_export.rs:677` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (7 lines × 2) crates/ibcmd-dump/src/mssql_dump/refs.rs:4645 — crates/ibcmd-dump/src/mssql_dump/refs.rs:4645-4651 | crates/ibcmd-dump/src/mssql_dump/refs.rs:4707-4713 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/refs.rs:4645` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. Note first that the copies are not typed on the same thing: the declarations holding them bind `field` to `&str` in one and `Option<&str>` in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH — their common supertype where they have one, or a new abstraction over them where they do not — and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract.
  • Duplicated block (7 lines × 2) crates/ibcmd-dump/src/mssql_dump/selected.rs:386 — crates/ibcmd-dump/src/mssql_dump/selected.rs:386-392 | crates/ibcmd-dump/src/mssql_dump/selected.rs:410-416 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/selected.rs:386` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, `crates/ibcmd-dump/src/mssql_dump/selected.rs:393` calls `insert_command_interface_command_ref`, `get` and `crates/ibcmd-dump/src/mssql_dump/selected.rs:417` does not — after which the two agree again for 3 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
  • Duplicated block (7 lines × 2) crates/ibcmd-dump/src/mssql_dump/source_assets.rs:69 — crates/ibcmd-dump/src/mssql_dump/source_assets.rs:69-75 | crates/ibcmd-dump/src/mssql_dump/source_assets.rs:1602-1608 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/source_assets.rs:69` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (7 lines × 2) crates/ibcmd-form-body/src/dcs.rs:1957 — crates/ibcmd-form-body/src/dcs.rs:1957-1963 | crates/ibcmd-form-body/src/dcs.rs:1988-1994 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • + 71 more in this group — see findings.md.
D2 · Cognitive Complexity · ibcmd_xml · ×94
  • ibcmd_xml::dcs_schema::rewrite_tokens (cognitive 353) crates/ibcmd-xml/src/dcs_schema.rs:4004 — ibcmd_xml::dcs_schema::rewrite_tokens has cognitive complexity 353 (threshold 15). Drivers by points: if/else 78 (260 pts), boolean chains 38, match/switch 10 (37 pts), loops 6 (18 pts) (nesting depth added 221). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_xml::dcs::parse_dcs_settings_children_root (cognitive 82) crates/ibcmd-xml/src/dcs.rs:1771 — ibcmd_xml::dcs::parse_dcs_settings_children_root has cognitive complexity 82 (threshold 15). Drivers by points: if/else 29 (59 pts), boolean chains 12, match/switch 3 (8 pts), loops 2 (3 pts) (nesting depth added 36). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_xml::dcs_template::direct_inline_settings_ranges (cognitive 69) crates/ibcmd-xml/src/dcs_template.rs:390 — ibcmd_xml::dcs_template::direct_inline_settings_ranges has cognitive complexity 69 (threshold 15). Drivers by points: if/else 18 (52 pts), boolean chains 14, match/switch 1 (2 pts), loops 1 (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.
  • ibcmd_xml::dcs::form_server_state_nil_parameter_names (cognitive 65) crates/ibcmd-xml/src/dcs.rs:6270 — ibcmd_xml::dcs::form_server_state_nil_parameter_names has cognitive complexity 65 (threshold 15). Drivers by points: if/else 13 (43 pts), match/switch 6 (14 pts), boolean chains 7, loops 1 (nesting depth added 38). Of this number, 64 points are the body's 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.
  • ibcmd_xml::dcs_template::direct_variant_closing_offsets (cognitive 62) crates/ibcmd-xml/src/dcs_template.rs:827 — ibcmd_xml::dcs_template::direct_variant_closing_offsets has cognitive complexity 62 (threshold 15). Drivers by points: if/else 16 (46 pts), boolean chains 13, match/switch 1 (2 pts), loops 1 (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.
  • ibcmd_xml::metadata::common::decode_generated_types (cognitive 60) crates/ibcmd-xml/src/metadata/common.rs:1573 — ibcmd_xml::metadata::common::decode_generated_types has cognitive complexity 60 (threshold 15). Drivers by points: if/else 18 (50 pts), loops 3 (5 pts), boolean chains 3, match/switch 1 (2 pts) (nesting depth added 35). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_xml::metadata::package::inspect_package_identity (cognitive 57) crates/ibcmd-xml/src/metadata/package.rs:32 — ibcmd_xml::metadata::package::inspect_package_identity has cognitive complexity 57 (threshold 15). Drivers by points: if/else 15 (44 pts), loops 3 (7 pts), match/switch 2 (5 pts), boolean chains 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.
  • ibcmd_xml::dialect::parse_descriptor (cognitive 53) crates/ibcmd-xml/src/dialect.rs:783 — ibcmd_xml::dialect::parse_descriptor has cognitive complexity 53 (threshold 15). Drivers by points: if/else 20 (42 pts), loops 6 (8 pts), boolean chains 3 (nesting depth added 24). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_xml::source_tree::reader::visit (cognitive 50) crates/ibcmd-xml/src/source_tree/reader.rs:196 — ibcmd_xml::source_tree::reader::visit has cognitive complexity 50 (threshold 15). Drivers by points: if/else 20 (42 pts), boolean chains 6, loops 2 (nesting depth added 22). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_xml::metadata::package::inspect_package_intent (cognitive 47) crates/ibcmd-xml/src/metadata/package.rs:223 — ibcmd_xml::metadata::package::inspect_package_intent has cognitive complexity 47 (threshold 15). Drivers by points: if/else 15 (39 pts), loops 2 (5 pts), match/switch 2, boolean chains 1 (nesting depth added 27). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_xml::dcs_storage::parse_document (cognitive 42) REDACTED:490 — ibcmd_xml::dcs_storage::parse_document has cognitive complexity 42 (threshold 15). Drivers by points: if/else 11 (22 pts), match/switch 5 (15 pts), loops 2 (3 pts), boolean chains 2 (nesting depth added 22). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_xml::dialect::bind_scope (cognitive 41) crates/ibcmd-xml/src/dialect.rs:1156 — ibcmd_xml::dialect::bind_scope has cognitive complexity 41 (threshold 15). Drivers by points: if/else 12 (26 pts), boolean chains 11, loops 2, match/switch 1 (2 pts) (nesting depth added 15). To reduce it, flatten the nesting: this score is depth rather than breadth — most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language's equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function.
  • ibcmd_xml::dcs_template::inspect_terminal_template_schema_file (cognitive 40) crates/ibcmd-xml/src/dcs_template.rs:705 — ibcmd_xml::dcs_template::inspect_terminal_template_schema_file has cognitive complexity 40 (threshold 15). Drivers by points: if/else 15 (33 pts), boolean chains 4, match/switch 1 (2 pts), loops 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.
  • ibcmd_xml::metadata::external_objects::generated_name (cognitive 40) crates/ibcmd-xml/src/metadata/external_objects.rs:267 — ibcmd_xml::metadata::external_objects::generated_name has cognitive complexity 40 (threshold 15). Drivers by points: if/else 9 (25 pts), loops 3 (7 pts), boolean chains 5, match/switch 1 (3 pts) (nesting depth added 22). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_xml::metadata::external_data_source::decode_empty_external_data_source (cognitive 38) crates/ibcmd-xml/src/metadata/external_data_source.rs:79 — ibcmd_xml::metadata::external_data_source::decode_empty_external_data_source has cognitive complexity 38 (threshold 15). Drivers by points: if/else 20 (28 pts), boolean chains 4, loops 3, match/switch 2 (3 pts) (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_xml::palette::declaration_spans (cognitive 38) crates/ibcmd-xml/src/palette.rs:91 — ibcmd_xml::palette::declaration_spans has cognitive complexity 38 (threshold 15). Drivers by points: if/else 9 (16 pts), loops 7 (12 pts), boolean chains 8, match/switch 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.
  • ibcmd_xml::metadata::services::project_http_service (cognitive 37) crates/ibcmd-xml/src/metadata/services.rs:1262 — ibcmd_xml::metadata::services::project_http_service has cognitive complexity 37 (threshold 15). Drivers by points: if/else 15 (32 pts), loops 2 (3 pts), boolean chains 2 (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.
  • ibcmd_xml::source_tree::reader::derive_uuid_from_reader (cognitive 37) crates/ibcmd-xml/src/source_tree/reader.rs:429 — ibcmd_xml::source_tree::reader::derive_uuid_from_reader has cognitive complexity 37 (threshold 15). Drivers by points: if/else 9 (28 pts), loops 2 (5 pts), boolean chains 2, match/switch 1 (2 pts) (nesting depth added 23). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_xml::metadata::configuration_mobile::parse_configuration_mobile_functionalities (cognitive 36) crates/ibcmd-xml/src/metadata/configuration_mobile.rs:64 — ibcmd_xml::metadata::configuration_mobile::parse_configuration_mobile_functionalities has cognitive complexity 36 (threshold 15). Drivers by points: if/else 14 (27 pts), boolean chains 4, loops 3, match/switch 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.
  • ibcmd_xml::metadata::order::order_metadata_features (cognitive 36) crates/ibcmd-xml/src/metadata/order.rs:92 — ibcmd_xml::metadata::order::order_metadata_features has cognitive complexity 36 (threshold 15). Drivers by points: if/else 8 (25 pts), loops 4 (7 pts), match/switch 2 (4 pts) (nesting depth added 22). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_xml::metadata::services::project_integration_service (cognitive 36) crates/ibcmd-xml/src/metadata/services.rs:1689 — ibcmd_xml::metadata::services::project_integration_service has cognitive complexity 36 (threshold 15). Drivers by points: if/else 14 (23 pts), boolean chains 6, match/switch 3 (4 pts), loops 2 (3 pts) (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_xml::dcs_schema::schema_file_children (cognitive 35) crates/ibcmd-xml/src/dcs_schema.rs:3904 — ibcmd_xml::dcs_schema::schema_file_children has cognitive complexity 35 (threshold 15). Drivers by points: if/else 13 (27 pts), boolean chains 4, loops 2 (4 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.
  • ibcmd_xml::metadata::external_named::decode_external_named_owner (cognitive 35) crates/ibcmd-xml/src/metadata/external_named.rs:297 — ibcmd_xml::metadata::external_named::decode_external_named_owner has cognitive complexity 35 (threshold 15). Drivers by points: if/else 9 (15 pts), match/switch 5 (12 pts), boolean chains 5, loops 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.
  • ibcmd_xml::metadata::services::project_web_service (cognitive 35) crates/ibcmd-xml/src/metadata/services.rs:1402 — ibcmd_xml::metadata::services::project_web_service has cognitive complexity 35 (threshold 15). Drivers by points: if/else 16 (32 pts), loops 2 (3 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.
  • ibcmd_xml::reader::inspection::inspect_events (cognitive 35) crates/ibcmd-xml/src/reader/inspection.rs:148 — ibcmd_xml::reader::inspection::inspect_events has cognitive complexity 35 (threshold 15). Drivers by points: if/else 9 (27 pts), boolean chains 5, match/switch 1 (2 pts), loops 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.
  • + 69 more in this group — see findings.md.
D4 · Code Duplication · Duplicated block (8 lines × 2) · ×93
  • Duplicated block (8 lines × 2) crates/ibcmd-1c-text/src/braced.rs:373 — crates/ibcmd-1c-text/src/braced.rs:373-380 | crates/ibcmd-1c-text/src/braced.rs:434-441 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-1c-text/src/braced.rs:373` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (8 lines × 2) crates/ibcmd-1c-vocab/src/style.rs:198 — crates/ibcmd-1c-vocab/src/style.rs:198-205 | crates/ibcmd-form-body/src/form_body.rs:17057-17064 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice.
  • Duplicated block (8 lines × 2) crates/ibcmd-compiler-families/src/compiler/families/services.rs:1820 — crates/ibcmd-compiler-families/src/compiler/families/services.rs:1820-1827 | crates/ibcmd-compiler-families/src/compiler/families/services.rs:2073-2081 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/services.rs:1820` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, `crates/ibcmd-compiler-families/src/compiler/families/services.rs:1828` calls `identity`, `uuid` and `crates/ibcmd-compiler-families/src/compiler/families/services.rs:2082` does not — after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
  • Duplicated block (8 lines × 2) crates/ibcmd-compiler-families/src/compiler/families/services.rs:2465 — crates/ibcmd-compiler-families/src/compiler/families/services.rs:2465-2472 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:2042-2049 — before extracting anything, compare `crates/ibcmd-compiler-families/src/compiler/families/services.rs` and `crates/ibcmd-compiler-families/src/compiler/families/simple.rs` as WHOLE FILES: this scan already matched 36 separate duplicated blocks between them, totalling at least 406 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/services.rs:2465` it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows — the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members' bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run — a one-line delegation has no helper inside it to lift — so generate the run from the set it enumerates, or accept it and keep each member's own documentation with it.
  • Duplicated block (8 lines × 2) crates/ibcmd-compiler-families/src/compiler/families/simple.rs:1697 — crates/ibcmd-compiler-families/src/compiler/families/simple.rs:1697-1704 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:1806-1813 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/simple.rs:1697` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (8 lines × 2) crates/ibcmd-compiler/src/compiler/bodies/mxl_native.rs:2813 — crates/ibcmd-compiler/src/compiler/bodies/mxl_native.rs:2813-2820 | crates/ibcmd-compiler/src/compiler/bodies/mxl_native.rs:2872-2879 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler/src/compiler/bodies/mxl_native.rs:2813` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, `crates/ibcmd-compiler/src/compiler/bodies/mxl_native.rs:2880` calls `strip_formatted_markup`, `text_of`, `unwrap_or_default` and `crates/ibcmd-compiler/src/compiler/bodies/mxl_native.rs:2821` does not — after which the two agree again for 3 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
  • Duplicated block (8 lines × 2) crates/ibcmd-config-apply/src/mssql_config_apply/mod.rs:527 — crates/ibcmd-config-apply/src/mssql_config_apply/mod.rs:527-534 | REDACTED:226-233 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-config-apply/src/mssql_config_apply/mod.rs:527` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (8 lines × 2) crates/ibcmd-config-apply/src/mssql_config_apply/mod.rs:1324 — crates/ibcmd-config-apply/src/mssql_config_apply/mod.rs:1324-1331 | crates/ibcmd-config-apply/src/mssql_config_apply/mod.rs:1346-1353 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-config-apply/src/mssql_config_apply/mod.rs:1324` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (8 lines × 2) crates/ibcmd-config-apply/src/mssql_config_apply/recovery.rs:422 — crates/ibcmd-config-apply/src/mssql_config_apply/recovery.rs:422-429 | crates/ibcmd-config-apply/src/mssql_config_apply/recovery.rs:515-522 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-config-apply/src/mssql_config_apply/recovery.rs:422` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (8 lines × 2) crates/ibcmd-core/src/migration/compatibility.rs:462 — crates/ibcmd-core/src/migration/compatibility.rs:462-469 | crates/ibcmd-core/src/model.rs:634-641 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice.
  • Duplicated block (8 lines × 2) crates/ibcmd-core/src/migration/v2_21_to_v2_20.rs:509 — crates/ibcmd-core/src/migration/v2_21_to_v2_20.rs:509-516 | crates/ibcmd-core/src/migration/v2_21_to_v2_20.rs:530-537 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-core/src/migration/v2_21_to_v2_20.rs:509` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note first that the copies are not typed on the same thing: the declarations holding them bind `error` to `&LossPolicyError` in one and `&DiagnosticBuildError` in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH — their common supertype where they have one, or a new abstraction over them where they do not — and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract.
  • Duplicated block (8 lines × 2) crates/ibcmd-dump/src/mssql_dump/extension/form.rs:282 — crates/ibcmd-dump/src/mssql_dump/extension/form.rs:282-289 | crates/ibcmd-dump/src/mssql_dump/extension/form.rs:379-386 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (8 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:4558 — crates/ibcmd-dump/src/mssql_dump/mod.rs:4558-4565 | crates/ibcmd-dump/src/mssql_dump/mod.rs:6311-6318 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (8 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:9836 — crates/ibcmd-dump/src/mssql_dump/mod.rs:9836-9843 | crates/ibcmd-dump/src/mssql_dump/source_assets.rs:1374-1381 — before extracting anything, compare `crates/ibcmd-dump/src/mssql_dump/mod.rs` and `crates/ibcmd-dump/src/mssql_dump/source_assets.rs` as WHOLE FILES: this scan already matched 5 separate duplicated blocks between them, totalling at least 36 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:9836` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (8 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:14687 — crates/ibcmd-dump/src/mssql_dump/mod.rs:14687-14694 | crates/ibcmd-dump/src/mssql_dump/mod.rs:35596-35603 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (8 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:21282 — crates/ibcmd-dump/src/mssql_dump/mod.rs:21282-21289 | crates/ibcmd-dump/src/mssql_dump/mod.rs:24885-24892 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:21282` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (8 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:32908 — crates/ibcmd-dump/src/mssql_dump/mod.rs:32908-32915 | crates/ibcmd-dump/src/mssql_dump/refs.rs:3983-3990 — before extracting anything, compare `crates/ibcmd-dump/src/mssql_dump/mod.rs` and `crates/ibcmd-dump/src/mssql_dump/refs.rs` as WHOLE FILES: this scan already matched 13 separate duplicated blocks between them, totalling at least 117 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:32908` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (8 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:35600 — crates/ibcmd-dump/src/mssql_dump/mod.rs:35600-35607 | crates/ibcmd-dump/src/mssql_dump/mod.rs:36517-36524 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:35600` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (8 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:40462 — crates/ibcmd-dump/src/mssql_dump/mod.rs:40462-40469 | crates/ibcmd-dump/src/mssql_dump/mod.rs:40584-40591 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:40462` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (8 lines × 2) crates/ibcmd-dump/src/mssql_dump/source_assets.rs:981 — crates/ibcmd-dump/src/mssql_dump/source_assets.rs:981-988 | REDACTED:10219-10226 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice.
  • Duplicated block (8 lines × 2) crates/ibcmd-dump/src/mssql_dump/source_assets.rs:5811 — crates/ibcmd-dump/src/mssql_dump/source_assets.rs:5811-5818 | crates/ibcmd-dump/src/mssql_dump/source_assets.rs:5835-5842 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/source_assets.rs:5811` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (8 lines × 2) crates/ibcmd-edt/src/codec.rs:406 — crates/ibcmd-edt/src/codec.rs:406-413 | crates/ibcmd-edt/src/provenance.rs:30-37 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once. 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 `return` inside it is the body's own exit and keeps its meaning in the moved unit.
  • Duplicated block (8 lines × 2) crates/ibcmd-form-body/src/form_body.rs:8552 — crates/ibcmd-form-body/src/form_body.rs:8552-8559 | crates/ibcmd-form-body/src/form_body.rs:8580-8587 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-form-body/src/form_body.rs:8552` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (8 lines × 2) crates/ibcmd-form-body/src/form_body.rs:9231 — crates/ibcmd-form-body/src/form_body.rs:9231-9238 | crates/ibcmd-form-body/src/form_body.rs:17845-17853 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-form-body/src/form_body.rs:9231` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (8 lines × 2) crates/ibcmd-form-body/src/form_body.rs:15476 — crates/ibcmd-form-body/src/form_body.rs:15476-15483 | crates/ibcmd-form-body/src/form_body.rs:15485-15492 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-form-body/src/form_body.rs:15476` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • + 68 more in this group — see findings.md.
D15 · Churn × Complexity Hotspots · Hotspot · ×87
  • Hotspot: crates/ibcmd-form-body/src/form_body.rs crates/ibcmd-form-body/src/form_body.rs:33250 — crates/ibcmd-form-body/src/form_body.rs changed 351 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 441 in ibcmd_form_body::form_body::format_form_child_item_xml at line 33250. 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-04..2026-11-02, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-04 13:20:30 +03:00' --until='2026-11-02 13:20:30 +03:00' --full-history --no-merges -- crates/ibcmd-form-body/src/form_body.rs`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: crates/ibcmd-dump/src/mssql_dump/mod.rs crates/ibcmd-dump/src/mssql_dump/mod.rs:4807 — crates/ibcmd-dump/src/mssql_dump/mod.rs changed 355 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 211 in ibcmd_dump::mssql_dump::dump_table_rows_streamed at line 4807. 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-04..2026-11-02, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-04 13:20:30 +03:00' --until='2026-11-02 13:20:30 +03:00' --full-history --no-merges -- crates/ibcmd-dump/src/mssql_dump/mod.rs`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: crates/ibcmd-moxel/src/lib.rs crates/ibcmd-moxel/src/lib.rs:2111 — crates/ibcmd-moxel/src/lib.rs changed 117 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 82 in ibcmd_moxel::parse_moxel_spreadsheet_text_with_line_trace at line 2111. 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-04..2026-11-02, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-04 13:20:30 +03:00' --until='2026-11-02 13:20:30 +03:00' --full-history --no-merges -- crates/ibcmd-moxel/src/lib.rs`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: crates/ibcmd-dump/src/mssql_dump/source_assets.rs crates/ibcmd-dump/src/mssql_dump/source_assets.rs:2323 — crates/ibcmd-dump/src/mssql_dump/source_assets.rs changed 93 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 76 in ibcmd_dump::mssql_dump::source_assets::write_source_asset_inner at line 2323. 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-04..2026-11-02, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-04 13:20:30 +03:00' --until='2026-11-02 13:20:30 +03:00' --full-history --no-merges -- crates/ibcmd-dump/src/mssql_dump/source_assets.rs`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: src/main.rs src/main.rs:29 — src/main.rs changed 38 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 182 in ibcmd_rs::run at line 29. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-04..2026-11-02, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-04 13:20:30 +03:00' --until='2026-11-02 13:20:30 +03:00' --full-history --no-merges -- src/main.rs`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: crates/ibcmd-dump/src/mssql_dump/refs.rs crates/ibcmd-dump/src/mssql_dump/refs.rs:1582 — crates/ibcmd-dump/src/mssql_dump/refs.rs changed 89 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 61 in ibcmd_dump::mssql_dump::refs::standalone_child_reference at line 1582. 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-04..2026-11-02, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-04 13:20:30 +03:00' --until='2026-11-02 13:20:30 +03:00' --full-history --no-merges -- crates/ibcmd-dump/src/mssql_dump/refs.rs`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: REDACTED REDACTED:3896 — REDACTED changed 114 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 44 in ibcmd_rs::mssql::stage_source_objects_patch at line 3896. 12 of those changes were fix/bug commits, and the other 102 changed it for other reasons — this file is under both repair and feature pressure. Before the next change lands here, make sure the area it touches is under test, then split that area out of the file so the following change is smaller than this one — a file this often edited pays the complexity back every time. Counted over 2026-08-04..2026-11-02, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-04 13:20:30 +03:00' --until='2026-11-02 13:20:30 +03:00' --full-history --no-merges -- REDACTED`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: crates/ibcmd-xml/src/dcs_schema.rs crates/ibcmd-xml/src/dcs_schema.rs:4004 — crates/ibcmd-xml/src/dcs_schema.rs changed 29 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 133 in ibcmd_xml::dcs_schema::rewrite_tokens at line 4004. 9 of those changes were fix/bug commits, and the other 20 changed it for other reasons — this file is under both repair and feature pressure. Before the next change lands here, make sure the area it touches is under test, then split that area out of the file so the following change is smaller than this one — a file this often edited pays the complexity back every time. Counted over 2026-08-04..2026-11-02, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-04 13:20:30 +03:00' --until='2026-11-02 13:20:30 +03:00' --full-history --no-merges -- crates/ibcmd-xml/src/dcs_schema.rs`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: crates/ibcmd-form-native/src/lib.rs crates/ibcmd-form-native/src/lib.rs:9707 — crates/ibcmd-form-native/src/lib.rs changed 88 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 31 in ibcmd_form_native::resolve_data_path_tokens at line 9707. 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-04..2026-11-02, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-04 13:20:30 +03:00' --until='2026-11-02 13:20:30 +03:00' --full-history --no-merges -- crates/ibcmd-form-native/src/lib.rs`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: crates/ibcmd-edt/src/codec.rs crates/ibcmd-edt/src/codec.rs:1063 — crates/ibcmd-edt/src/codec.rs changed 26 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 103 in ibcmd_edt::codec::same_body_bytes at line 1063. 13 of those changes were fix/bug commits, and the other 13 changed it for other reasons — this file is under both repair and feature pressure. Before the next change lands here, make sure the area it touches is under test, then split that area out of the file so the following change is smaller than this one — a file this often edited pays the complexity back every time. Counted over 2026-08-04..2026-11-02, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-04 13:20:30 +03:00' --until='2026-11-02 13:20:30 +03:00' --full-history --no-merges -- crates/ibcmd-edt/src/codec.rs`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: crates/ibcmd-config-apply/src/mssql_config_apply/mod.rs crates/ibcmd-config-apply/src/mssql_config_apply/mod.rs:972 — crates/ibcmd-config-apply/src/mssql_config_apply/mod.rs changed 34 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 78 in ibcmd_config_apply::mssql_config_apply::plan_with_gate at line 972. 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-04..2026-11-02, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-04 13:20:30 +03:00' --until='2026-11-02 13:20:30 +03:00' --full-history --no-merges -- crates/ibcmd-config-apply/src/mssql_config_apply/mod.rs`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: src/mssql_apply.rs src/mssql_apply.rs:81 — src/mssql_apply.rs changed 52 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 50 in ibcmd_rs::mssql_apply::apply_source_change_inner at line 81. 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-04..2026-11-02, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-04 13:20:30 +03:00' --until='2026-11-02 13:20:30 +03:00' --full-history --no-merges -- src/mssql_apply.rs`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: crates/ibcmd-schema/src/lib.rs crates/ibcmd-schema/src/lib.rs:818 — crates/ibcmd-schema/src/lib.rs changed 79 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 30 in ibcmd_schema::parse_form_choice_list_item_inner at line 818. 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-04..2026-11-02, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-04 13:20:30 +03:00' --until='2026-11-02 13:20:30 +03:00' --full-history --no-merges -- crates/ibcmd-schema/src/lib.rs`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: crates/ibcmd-form-schema/src/lib.rs crates/ibcmd-form-schema/src/lib.rs:1921 — crates/ibcmd-form-schema/src/lib.rs changed 115 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 17 in FormCommandSchema::from_raw_layout at line 1921. 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-04..2026-11-02, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-04 13:20:30 +03:00' --until='2026-11-02 13:20:30 +03:00' --full-history --no-merges -- crates/ibcmd-form-schema/src/lib.rs`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: crates/ibcmd-dump/src/mssql_dump/metadata.rs crates/ibcmd-dump/src/mssql_dump/metadata.rs:433 — crates/ibcmd-dump/src/mssql_dump/metadata.rs changed 21 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 76 in ibcmd_dump::mssql_dump::metadata::metadata_source_for_object_fields at line 433. 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-04..2026-11-02, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-04 13:20:30 +03:00' --until='2026-11-02 13:20:30 +03:00' --full-history --no-merges -- crates/ibcmd-dump/src/mssql_dump/metadata.rs`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: REDACTED REDACTED:1133 — REDACTED changed 15 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 95 in ibcmd_config_apply::mssql_config_apply::dynamic::plan_dynamic at line 1133. 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-04..2026-11-02, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-04 13:20:30 +03:00' --until='2026-11-02 13:20:30 +03:00' --full-history --no-merges -- REDACTED`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: src/mssql/empty_stage.rs src/mssql/empty_stage.rs:1121 — src/mssql/empty_stage.rs changed 32 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 42 in ibcmd_rs::mssql::empty_stage::audit_empty_stage at line 1121. 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-04..2026-11-02, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-04 13:20:30 +03:00' --until='2026-11-02 13:20:30 +03:00' --full-history --no-merges -- src/mssql/empty_stage.rs`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: editors/vscode/src/extension.ts editors/vscode/src/extension.ts:19 — editors/vscode/src/extension.ts changed 20 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 64 in extension.activate at line 19. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-04..2026-11-02, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-04 13:20:30 +03:00' --until='2026-11-02 13:20:30 +03:00' --full-history --no-merges -- editors/vscode/src/extension.ts`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: scripts/edt-lab/oracle.py scripts/edt-lab/oracle.py:809 — scripts/edt-lab/oracle.py changed 17 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 73 in oracle.bind_diagnostic_capture at line 809. 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-04..2026-11-02, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-04 13:20:30 +03:00' --until='2026-11-02 13:20:30 +03:00' --full-history --no-merges -- scripts/edt-lab/oracle.py`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: crates/ibcmd-xml/src/dcs.rs crates/ibcmd-xml/src/dcs.rs:1771 — crates/ibcmd-xml/src/dcs.rs changed 22 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 50 in ibcmd_xml::dcs::parse_dcs_settings_children_root at line 1771. 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-04..2026-11-02, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-04 13:20:30 +03:00' --until='2026-11-02 13:20:30 +03:00' --full-history --no-merges -- crates/ibcmd-xml/src/dcs.rs`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: crates/ibcmd-dump/src/mssql_dump/model_export.rs crates/ibcmd-dump/src/mssql_dump/model_export.rs:332 — crates/ibcmd-dump/src/mssql_dump/model_export.rs changed 34 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 31 in ModelExport::build at line 332. 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-04..2026-11-02, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-04 13:20:30 +03:00' --until='2026-11-02 13:20:30 +03:00' --full-history --no-merges -- crates/ibcmd-dump/src/mssql_dump/model_export.rs`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: crates/ibcmd-edt/src/bounded.rs crates/ibcmd-edt/src/bounded.rs:31 — crates/ibcmd-edt/src/bounded.rs changed 13 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 76 in ibcmd_edt::bounded::validate_xml_with_policy at line 31. 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-04..2026-11-02, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-04 13:20:30 +03:00' --until='2026-11-02 13:20:30 +03:00' --full-history --no-merges -- crates/ibcmd-edt/src/bounded.rs`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: crates/ibcmd-metadata-model/src/metadata_model/root_export.rs crates/ibcmd-metadata-model/src/metadata_model/root_export.rs:380 — crates/ibcmd-metadata-model/src/metadata_model/root_export.rs changed 13 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 63 in ibcmd_metadata_model::metadata_model::root_export::decode at line 380. 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-04..2026-11-02, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-04 13:20:30 +03:00' --until='2026-11-02 13:20:30 +03:00' --full-history --no-merges -- crates/ibcmd-metadata-model/src/metadata_model/root_export.rs`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: src/source_audit.rs src/source_audit.rs:1536 — src/source_audit.rs changed 24 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 29 in ibcmd_rs::source_audit::audit_native_form_writer at line 1536. 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-04..2026-11-02, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-04 13:20:30 +03:00' --until='2026-11-02 13:20:30 +03:00' --full-history --no-merges -- src/source_audit.rs`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: src/dropin/parse.rs src/dropin/parse.rs:927 — src/dropin/parse.rs changed 20 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 34 in ibcmd_rs::dropin::parse::parse_infobase at line 927. 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-04..2026-11-02, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-04 13:20:30 +03:00' --until='2026-11-02 13:20:30 +03:00' --full-history --no-merges -- src/dropin/parse.rs`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • + 62 more in this group — see findings.md.
D4 · Code Duplication · Duplicated block (5 lines × 2) · ×78
  • Duplicated block (5 lines × 2) crates/ibcmd-1c-text/src/braced.rs:302 — crates/ibcmd-1c-text/src/braced.rs:302-306 | crates/ibcmd-1c-text/src/braced.rs:437-441 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, `crates/ibcmd-1c-text/src/braced.rs:435` calls `with`, `borrow` and `crates/ibcmd-1c-text/src/braced.rs:301` does not — after which the two agree again for 3 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
  • Duplicated block (5 lines × 2) crates/ibcmd-1c-vocab/src/values.rs:15 — crates/ibcmd-1c-vocab/src/values.rs:15-19 | crates/ibcmd-schema/src/lib.rs:1206-1210 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-1c-vocab/src/values.rs:15` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (5 lines × 2) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:3127 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:3127-3131 | crates/ibcmd-compiler-families/src/compiler/families/utility.rs:1632-1636 — before extracting anything, compare `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs` and `crates/ibcmd-compiler-families/src/compiler/families/utility.rs` as WHOLE FILES: this scan already matched 65 separate duplicated blocks between them, totalling at least 934 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place.
  • Duplicated block (5 lines × 2) REDACTED:504 — REDACTED:504-508 | REDACTED:276-282 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `REDACTED:276` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (5 lines × 2) crates/ibcmd-dump/src/mssql_dump/extension/mod.rs:1167 — crates/ibcmd-dump/src/mssql_dump/extension/mod.rs:1167-1171 | crates/ibcmd-dump/src/mssql_dump/extension/mod.rs:1221-1225 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/extension/mod.rs:1167` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (5 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:15770 — crates/ibcmd-dump/src/mssql_dump/mod.rs:15770-15774 | crates/ibcmd-dump/src/mssql_dump/mod.rs:15886-15890 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (5 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:17528 — crates/ibcmd-dump/src/mssql_dump/mod.rs:17528-17534 | crates/ibcmd-dump/src/mssql_dump/mod.rs:17624-17628 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:17528` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
  • Duplicated block (5 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:22467 — crates/ibcmd-dump/src/mssql_dump/mod.rs:22467-22471 | crates/ibcmd-dump/src/mssql_dump/refs.rs:4043-4047 — before extracting anything, compare `crates/ibcmd-dump/src/mssql_dump/mod.rs` and `crates/ibcmd-dump/src/mssql_dump/refs.rs` as WHOLE FILES: this scan already matched 13 separate duplicated blocks between them, totalling at least 117 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (5 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:32406 — crates/ibcmd-dump/src/mssql_dump/mod.rs:32406-32410 | crates/ibcmd-dump/src/mssql_dump/mod.rs:33047-33051 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (5 lines × 2) crates/ibcmd-dump/src/mssql_dump/source_assets.rs:4378 — crates/ibcmd-dump/src/mssql_dump/source_assets.rs:4378-4382 | crates/ibcmd-dump/src/mssql_dump/source_assets.rs:4691-4695 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (5 lines × 2) crates/ibcmd-form-body/src/dcs.rs:849 — crates/ibcmd-form-body/src/dcs.rs:849-853 | crates/ibcmd-form-body/src/dcs.rs:3181-3185 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (5 lines × 2) crates/ibcmd-form-body/src/form_body.rs:10719 — crates/ibcmd-form-body/src/form_body.rs:10719-10723 | crates/ibcmd-form-body/src/form_body.rs:11882-11886 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (5 lines × 2) crates/ibcmd-form-writer/src/form/load_8_5_1.rs:2003 — crates/ibcmd-form-writer/src/form/load_8_5_1.rs:2003-2007 | crates/ibcmd-form-writer/src/form/load_8_5_1.rs:2046-2050 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (5 lines × 2) crates/ibcmd-form-writer/src/lib.rs:1003 — crates/ibcmd-form-writer/src/lib.rs:1003-1007 | crates/ibcmd-metadata-blob/src/lib.rs:1607-1611 — before extracting anything, compare `crates/ibcmd-form-writer/src/lib.rs` and `crates/ibcmd-metadata-blob/src/lib.rs` as WHOLE FILES: this scan already matched 5 separate duplicated blocks between them, totalling at least 33 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. The two sit in different directories, so one cannot simply be deleted in favour of the other while both are reached separately: hoist the shared part into a location both already depend on and have each file call it, and retire whichever file turns out to have no caller of its own left. Extracting one helper per block leaves the fork in place.
  • Duplicated block (5 lines × 2) crates/ibcmd-form-writer/src/lib.rs:18710 — crates/ibcmd-form-writer/src/lib.rs:18710-18714 | crates/ibcmd-form-writer/src/lib.rs:18718-18722 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-form-writer/src/lib.rs:18710` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (5 lines × 2) crates/ibcmd-metadata-blob/src/lib.rs:5798 — crates/ibcmd-metadata-blob/src/lib.rs:5798-5802 | crates/ibcmd-metadata-blob/src/lib.rs:6291-6295 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (5 lines × 2) crates/ibcmd-restructure-engine/src/restructure/caches/slots.rs:357 — crates/ibcmd-restructure-engine/src/restructure/caches/slots.rs:357-361 | crates/ibcmd-restructure-engine/src/restructure/catalog.rs:132-136 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice.
  • Duplicated block (5 lines × 2) crates/ibcmd-schema/src/lib.rs:9196 — crates/ibcmd-schema/src/lib.rs:9196-9200 | crates/ibcmd-schema/src/lib.rs:9469-9473 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-schema/src/lib.rs:9196` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (5 lines × 2) crates/ibcmd-v8/src/format15.rs:250 — crates/ibcmd-v8/src/format15.rs:250-254 | crates/ibcmd-v8/src/format16.rs:333-337 — before extracting anything, compare `crates/ibcmd-v8/src/format15.rs` and `crates/ibcmd-v8/src/format16.rs` as WHOLE FILES: this scan already matched 7 separate duplicated blocks between them, totalling at least 82 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-v8/src/format15.rs:250` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (5 lines × 2) crates/ibcmd-xml/src/dcs.rs:2740 — crates/ibcmd-xml/src/dcs.rs:2740-2744 | crates/ibcmd-xml/src/dcs.rs:3284-3288 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-xml/src/dcs.rs:2740` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (5 lines × 2) REDACTED:345 — REDACTED:345-350 | REDACTED:1335-1339 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `REDACTED:345` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (5 lines × 2) src/load/compiled.rs:237 — src/load/compiled.rs:237-241 | REDACTED:8185-8189 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at `src/load/compiled.rs:237` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (5 lines × 2) src/load/seed.rs:181 — src/load/seed.rs:181-185 | REDACTED:2605-2610 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at `src/load/seed.rs:181` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
  • Duplicated block (5 lines × 2) REDACTED:4520 — REDACTED:4520-4524 | src/source_audit.rs:395-399 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `REDACTED:4520` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (5 lines × 2) REDACTED:4518 — REDACTED:4518-4522 | REDACTED:4527-4531 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • + 53 more in this group — see findings.md.
D4 · Code Duplication · Duplicated block (9 lines × 2) · ×73
  • Duplicated block (9 lines × 2) crates/ibcmd-compiler-families/src/compiler/families/services.rs:2474 — crates/ibcmd-compiler-families/src/compiler/families/services.rs:2474-2482 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:2051-2059 — before extracting anything, compare `crates/ibcmd-compiler-families/src/compiler/families/services.rs` and `crates/ibcmd-compiler-families/src/compiler/families/simple.rs` as WHOLE FILES: this scan already matched 36 separate duplicated blocks between them, totalling at least 406 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/services.rs:2474` it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows — the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members' bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run — a one-line delegation has no helper inside it to lift — so generate the run from the set it enumerates, or accept it and keep each member's own documentation with it. The `return` at the foot of the matched lines is the enclosing body's own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that `return` occupied — no decision has to be handed back and re-acted on.
  • Duplicated block (9 lines × 2) crates/ibcmd-compiler/src/compiler/bodies/mxl_native.rs:1539 — crates/ibcmd-compiler/src/compiler/bodies/mxl_native.rs:1539-1547 | crates/ibcmd-form-writer/src/form_chart.rs:207-215 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler/src/compiler/bodies/mxl_native.rs:1539` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (9 lines × 2) crates/ibcmd-config-apply/src/mssql_config_apply/check_gate.rs:59 — crates/ibcmd-config-apply/src/mssql_config_apply/check_gate.rs:59-67 | crates/ibcmd-config-apply/src/restructure/s1.rs:410-418 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice.
  • Duplicated block (9 lines × 2) REDACTED:1861 — REDACTED:1861-1869 | crates/ibcmd-config-apply/src/mssql_config_apply/mod.rs:1856-1864 — before extracting anything, compare `REDACTED` and `crates/ibcmd-config-apply/src/mssql_config_apply/mod.rs` as WHOLE FILES: this scan already matched 5 separate duplicated blocks between them, totalling at least 61 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place.
  • Duplicated block (9 lines × 2) REDACTED:1901 — REDACTED:1901-1909 | crates/ibcmd-config-apply/src/mssql_config_apply/mod.rs:1902-1910 — before extracting anything, compare `REDACTED` and `crates/ibcmd-config-apply/src/mssql_config_apply/mod.rs` as WHOLE FILES: this scan already matched 5 separate duplicated blocks between them, totalling at least 61 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. 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. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, `crates/ibcmd-config-apply/src/mssql_config_apply/mod.rs:1898` calls `check` and `REDACTED:1899` does not — after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
  • Duplicated block (9 lines × 2) REDACTED:272 — REDACTED:272-280 | REDACTED:340-348 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `REDACTED:272` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (9 lines × 2) REDACTED:322 — REDACTED:322-330 | REDACTED:331-339 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (9 lines × 2) REDACTED:293 — REDACTED:293-301 | REDACTED:343-351 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `REDACTED:293` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (9 lines × 2) REDACTED:395 — REDACTED:395-403 | REDACTED:852-860 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (9 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:14922 — crates/ibcmd-dump/src/mssql_dump/mod.rs:14922-14930 | crates/ibcmd-dump/src/mssql_dump/mod.rs:17178-17186 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (9 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:15868 — crates/ibcmd-dump/src/mssql_dump/mod.rs:15868-15876 | crates/ibcmd-moxel/src/lib.rs:10073-10081 — before extracting anything, compare `crates/ibcmd-dump/src/mssql_dump/mod.rs` and `crates/ibcmd-moxel/src/lib.rs` as WHOLE FILES: this scan already matched 5 separate duplicated blocks between them, totalling at least 31 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 `crates/ibcmd-dump/src/mssql_dump/mod.rs:15868` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (9 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:25308 — crates/ibcmd-dump/src/mssql_dump/mod.rs:25308-25316 | crates/ibcmd-dump/src/mssql_dump/mod.rs:25711-25719 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:25308` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The `return` at the foot of the matched lines is the enclosing body's own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that `return` occupied — no decision has to be handed back and re-acted on.
  • Duplicated block (9 lines × 2) crates/ibcmd-dump/src/mssql_dump/refs.rs:829 — crates/ibcmd-dump/src/mssql_dump/refs.rs:829-837 | crates/ibcmd-dump/src/mssql_dump/refs.rs:1306-1314 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (9 lines × 2) crates/ibcmd-dump/src/mssql_dump/source_assets.rs:4431 — crates/ibcmd-dump/src/mssql_dump/source_assets.rs:4431-4439 | crates/ibcmd-dump/src/mssql_dump/source_assets.rs:4761-4769 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (9 lines × 2) crates/ibcmd-dump/src/mssql_dump/timing.rs:120 — crates/ibcmd-dump/src/mssql_dump/timing.rs:120-128 | crates/ibcmd-dump/src/mssql_dump/timing.rs:165-173 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/timing.rs:120` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (9 lines × 2) crates/ibcmd-dump/src/mssql_dump/upgrade.rs:282 — crates/ibcmd-dump/src/mssql_dump/upgrade.rs:282-290 | crates/ibcmd-dump/src/mssql_dump/upgrade.rs:406-414 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/upgrade.rs:282` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (9 lines × 2) crates/ibcmd-form-body/src/form_body.rs:11529 — crates/ibcmd-form-body/src/form_body.rs:11529-11537 | crates/ibcmd-form-body/src/form_body.rs:12144-12152 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-form-body/src/form_body.rs:11529` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (9 lines × 2) crates/ibcmd-form-body/src/form_body.rs:22231 — crates/ibcmd-form-body/src/form_body.rs:22231-22239 | crates/ibcmd-form-body/src/form_body.rs:22276-22284 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-form-body/src/form_body.rs:22231` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (9 lines × 2) crates/ibcmd-form-body/src/form_root_42.rs:379 — crates/ibcmd-form-body/src/form_root_42.rs:379-387 | crates/ibcmd-form-body/src/form_root_42.rs:422-430 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (9 lines × 2) crates/ibcmd-form-writer/src/lib.rs:8576 — crates/ibcmd-form-writer/src/lib.rs:8576-8584 | crates/ibcmd-form-writer/src/lib.rs:8929-8937 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-form-writer/src/lib.rs:8576` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (9 lines × 2) crates/ibcmd-form-writer/src/lib.rs:15617 — crates/ibcmd-form-writer/src/lib.rs:15617-15625 | crates/ibcmd-form-writer/src/lib.rs:15828-15836 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-form-writer/src/lib.rs:15617` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (9 lines × 2) crates/ibcmd-form-writer/src/lib.rs:16488 — crates/ibcmd-form-writer/src/lib.rs:16488-16496 | crates/ibcmd-form-writer/src/lib.rs:19597-19605 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (9 lines × 2) crates/ibcmd-form-writer/src/lib.rs:21443 — crates/ibcmd-form-writer/src/lib.rs:21443-21451 | crates/ibcmd-form-writer/src/lib.rs:21895-21903 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (9 lines × 2) crates/ibcmd-metadata-model/src/metadata_model/audit.rs:213 — crates/ibcmd-metadata-model/src/metadata_model/audit.rs:213-221 | crates/ibcmd-metadata-model/src/metadata_model/export_audit.rs:272-280 — before extracting anything, compare `crates/ibcmd-metadata-model/src/metadata_model/audit.rs` and `crates/ibcmd-metadata-model/src/metadata_model/export_audit.rs` as WHOLE FILES: this scan already matched 4 separate duplicated blocks between them, totalling at least 35 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (9 lines × 2) crates/ibcmd-metadata-model/src/metadata_model/objects_parts.rs:1214 — crates/ibcmd-metadata-model/src/metadata_model/objects_parts.rs:1214-1222 | crates/ibcmd-metadata-model/src/metadata_model/registers_parts.rs:629-637 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-metadata-model/src/metadata_model/objects_parts.rs:1214` it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows — the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members' bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run — a one-line delegation has no helper inside it to lift — so generate the run from the set it enumerates, or accept it and keep each member's own documentation with it.
  • + 48 more in this group — see findings.md.
D4 · Code Duplication · Duplicated block (10 lines × 2) · ×70
  • Duplicated block (10 lines × 2) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:767 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:767-776 | crates/ibcmd-compiler-families/src/compiler/families/utility.rs:452-461 — before extracting anything, compare `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs` and `crates/ibcmd-compiler-families/src/compiler/families/utility.rs` as WHOLE FILES: this scan already matched 65 separate duplicated blocks between them, totalling at least 934 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:767` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (10 lines × 2) crates/ibcmd-compiler-families/src/compiler/families/commands.rs:1086 — crates/ibcmd-compiler-families/src/compiler/families/commands.rs:1086-1095 | crates/ibcmd-metadata-blob/src/lib.rs:6970-6979 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/commands.rs:1086` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (10 lines × 2) REDACTED:1875 — REDACTED:1875-1884 | crates/ibcmd-config-apply/src/mssql_config_apply/mod.rs:1867-1876 — before extracting anything, compare `REDACTED` and `crates/ibcmd-config-apply/src/mssql_config_apply/mod.rs` as WHOLE FILES: this scan already matched 5 separate duplicated blocks between them, totalling at least 61 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `REDACTED:1875` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (10 lines × 2) crates/ibcmd-core/src/migration/v2_20_to_v2_21.rs:268 — crates/ibcmd-core/src/migration/v2_20_to_v2_21.rs:268-277 | crates/ibcmd-core/src/migration/v2_21_to_v2_20.rs:524-533 — before extracting anything, compare `crates/ibcmd-core/src/migration/v2_20_to_v2_21.rs` and `crates/ibcmd-core/src/migration/v2_21_to_v2_20.rs` as WHOLE FILES: this scan already matched 6 separate duplicated blocks between them, totalling at least 67 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-core/src/migration/v2_20_to_v2_21.rs:268` it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows — the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members' bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run — a one-line delegation has no helper inside it to lift — so generate the run from the set it enumerates, or accept it and keep each member's own documentation with it. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, `crates/ibcmd-core/src/migration/v2_20_to_v2_21.rs:265` calls `to_string` and `crates/ibcmd-core/src/migration/v2_21_to_v2_20.rs:521` does not — after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
  • Duplicated block (10 lines × 2) crates/ibcmd-core/src/model.rs:166 — crates/ibcmd-core/src/model.rs:166-175 | crates/ibcmd-core/src/opaque.rs:132-141 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-core/src/model.rs:166` it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows — the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members' bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run — a one-line delegation has no helper inside it to lift — so generate the run from the set it enumerates, or accept it and keep each member's own documentation with it.
  • Duplicated block (10 lines × 2) crates/ibcmd-dump/src/mssql_dump/command_interface.rs:202 — crates/ibcmd-dump/src/mssql_dump/command_interface.rs:202-211 | crates/ibcmd-dump/src/mssql_dump/command_interface.rs:248-266 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/command_interface.rs:202` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (10 lines × 2) REDACTED:384 — REDACTED:384-393 | REDACTED:416-425 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (10 lines × 2) REDACTED:1082 — REDACTED:1082-1091 | REDACTED:1252-1261 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `REDACTED:1082` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (10 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:6978 — crates/ibcmd-dump/src/mssql_dump/mod.rs:6978-6987 | crates/ibcmd-dump/src/mssql_dump/refs.rs:2942-2951 — before extracting anything, compare `crates/ibcmd-dump/src/mssql_dump/mod.rs` and `crates/ibcmd-dump/src/mssql_dump/refs.rs` as WHOLE FILES: this scan already matched 13 separate duplicated blocks between them, totalling at least 117 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:6978` it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows — the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members' bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run — a one-line delegation has no helper inside it to lift — so generate the run from the set it enumerates, or accept it and keep each member's own documentation with it. 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. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, `crates/ibcmd-dump/src/mssql_dump/refs.rs:2952` calls `from`, `join`, `sanitize_source_path_segment` and `crates/ibcmd-dump/src/mssql_dump/mod.rs:6988` does not — after which the two agree again for 3 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
  • Duplicated block (10 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:8633 — crates/ibcmd-dump/src/mssql_dump/mod.rs:8633-8642 | crates/ibcmd-dump/src/mssql_dump/mod.rs:8683-8692 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:8633` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (10 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:9125 — crates/ibcmd-dump/src/mssql_dump/mod.rs:9125-9134 | crates/ibcmd-dump/src/mssql_dump/mod.rs:14836-14845 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:9125` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (10 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:14978 — crates/ibcmd-dump/src/mssql_dump/mod.rs:14978-14987 | crates/ibcmd-dump/src/mssql_dump/mod.rs:17278-17287 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (10 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:15065 — crates/ibcmd-dump/src/mssql_dump/mod.rs:15065-15074 | crates/ibcmd-dump/src/mssql_dump/mod.rs:27107-27116 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:15065` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (10 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:25275 — crates/ibcmd-dump/src/mssql_dump/mod.rs:25275-25284 | crates/ibcmd-dump/src/mssql_dump/mod.rs:25680-25689 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (10 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:26141 — crates/ibcmd-dump/src/mssql_dump/mod.rs:26141-26150 | crates/ibcmd-dump/src/mssql_dump/mod.rs:32250-32259 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:26141` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (10 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:26230 — crates/ibcmd-dump/src/mssql_dump/mod.rs:26230-26239 | crates/ibcmd-dump/src/mssql_dump/mod.rs:27177-27186 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:26230` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (10 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:28804 — crates/ibcmd-dump/src/mssql_dump/mod.rs:28804-28813 | crates/ibcmd-dump/src/mssql_dump/mod.rs:30271-30280 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:28804` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (10 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:28893 — crates/ibcmd-dump/src/mssql_dump/mod.rs:28893-28902 | crates/ibcmd-dump/src/mssql_dump/mod.rs:29925-29934 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:28893` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (10 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:35331 — crates/ibcmd-dump/src/mssql_dump/mod.rs:35331-35340 | crates/ibcmd-dump/src/mssql_dump/mod.rs:35381-35390 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:35331` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (10 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:43103 — crates/ibcmd-dump/src/mssql_dump/mod.rs:43103-43112 | crates/ibcmd-dump/src/mssql_dump/mod.rs:43167-43176 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:43103` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (10 lines × 2) crates/ibcmd-dump/src/mssql_dump/postgres_infobase.rs:99 — crates/ibcmd-dump/src/mssql_dump/postgres_infobase.rs:99-108 | src/postgres_infobase.rs:136-145 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/postgres_infobase.rs:99` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note first that the copies are not typed on the same thing: the declarations holding them bind `connection` to `&mut` in one and `&mut PgConnection` in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH — their common supertype where they have one, or a new abstraction over them where they do not — and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract.
  • Duplicated block (10 lines × 2) crates/ibcmd-dump/src/mssql_dump/selected.rs:486 — crates/ibcmd-dump/src/mssql_dump/selected.rs:486-495 | crates/ibcmd-dump/src/mssql_dump/selected.rs:533-542 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, `crates/ibcmd-dump/src/mssql_dump/selected.rs:543` calls `iter`, `any`, `contains` and `crates/ibcmd-dump/src/mssql_dump/selected.rs:496` does not — after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
  • Duplicated block (10 lines × 2) crates/ibcmd-dump/src/mssql_dump/source_assets.rs:2994 — crates/ibcmd-dump/src/mssql_dump/source_assets.rs:2994-3003 | crates/ibcmd-dump/src/mssql_dump/source_assets.rs:3321-3330 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/source_assets.rs:2994` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (10 lines × 2) crates/ibcmd-edt/src/directory.rs:489 — crates/ibcmd-edt/src/directory.rs:489-499 | crates/ibcmd-edt/src/provenance.rs:109-118 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
  • Duplicated block (10 lines × 2) crates/ibcmd-form-body/src/dcs.rs:2664 — crates/ibcmd-form-body/src/dcs.rs:2664-2673 | crates/ibcmd-form-body/src/dcs.rs:2845-2854 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • + 45 more in this group — see findings.md.
D1 · Cyclomatic Complexity · ibcmd_xml · ×65
  • ibcmd_xml::dcs_schema::rewrite_tokens (cyclomatic 133) crates/ibcmd-xml/src/dcs_schema.rs:4004 — ibcmd_xml::dcs_schema::rewrite_tokens has cyclomatic complexity 133 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
  • ibcmd_xml::dcs::parse_dcs_settings_children_root (cyclomatic 50) crates/ibcmd-xml/src/dcs.rs:1771 — ibcmd_xml::dcs::parse_dcs_settings_children_root has cyclomatic complexity 50 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
  • ibcmd_xml::dcs::form_server_state_nil_parameter_names (cyclomatic 42) crates/ibcmd-xml/src/dcs.rs:6270 — ibcmd_xml::dcs::form_server_state_nil_parameter_names has cyclomatic complexity 42 (threshold 15). Of this number, 41 points are the body's 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.
  • ibcmd_xml::dcs_template::direct_inline_settings_ranges (cyclomatic 37) crates/ibcmd-xml/src/dcs_template.rs:390 — ibcmd_xml::dcs_template::direct_inline_settings_ranges 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.
  • ibcmd_xml::dcs_template::direct_variant_closing_offsets (cyclomatic 35) crates/ibcmd-xml/src/dcs_template.rs:827 — ibcmd_xml::dcs_template::direct_variant_closing_offsets 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.
  • ibcmd_xml::dialect::parse_descriptor (cyclomatic 30) crates/ibcmd-xml/src/dialect.rs:783 — ibcmd_xml::dialect::parse_descriptor 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.
  • ibcmd_xml::metadata::external_data_source::decode_empty_external_data_source (cyclomatic 30) crates/ibcmd-xml/src/metadata/external_data_source.rs:79 — ibcmd_xml::metadata::external_data_source::decode_empty_external_data_source 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.
  • ibcmd_xml::metadata::external_named::decode_external_named_owner (cyclomatic 29) crates/ibcmd-xml/src/metadata/external_named.rs:297 — ibcmd_xml::metadata::external_named::decode_external_named_owner has cyclomatic complexity 29 (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.
  • ibcmd_xml::dialect::bind_scope (cyclomatic 27) crates/ibcmd-xml/src/dialect.rs:1156 — ibcmd_xml::dialect::bind_scope has cyclomatic complexity 27 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
  • ibcmd_xml::metadata::services::project_integration_service (cyclomatic 27) crates/ibcmd-xml/src/metadata/services.rs:1689 — ibcmd_xml::metadata::services::project_integration_service 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.
  • ibcmd_xml::palette::declaration_spans (cyclomatic 27) crates/ibcmd-xml/src/palette.rs:91 — ibcmd_xml::palette::declaration_spans has cyclomatic complexity 27 (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.
  • ibcmd_xml::dcs_storage::parse_document (cyclomatic 26) REDACTED:490 — ibcmd_xml::dcs_storage::parse_document 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.
  • ibcmd_xml::reader::inspection::inspect_events (cyclomatic 26) crates/ibcmd-xml/src/reader/inspection.rs:148 — ibcmd_xml::reader::inspection::inspect_events 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.
  • ibcmd_xml::source_tree::reader::visit (cyclomatic 26) crates/ibcmd-xml/src/source_tree/reader.rs:196 — ibcmd_xml::source_tree::reader::visit 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.
  • ibcmd_xml::dcs::parse_dcs_filter (cyclomatic 25) crates/ibcmd-xml/src/dcs.rs:2384 — ibcmd_xml::dcs::parse_dcs_filter has cyclomatic complexity 25 (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.
  • ibcmd_xml::metadata::common::decode_generated_types (cyclomatic 25) crates/ibcmd-xml/src/metadata/common.rs:1573 — ibcmd_xml::metadata::common::decode_generated_types 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.
  • ibcmd_xml::metadata::configuration_mobile::parse_configuration_mobile_functionalities (cyclomatic 24) crates/ibcmd-xml/src/metadata/configuration_mobile.rs:64 — ibcmd_xml::metadata::configuration_mobile::parse_configuration_mobile_functionalities 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.
  • ibcmd_xml::metadata::functional_option::project (cyclomatic 24) crates/ibcmd-xml/src/metadata/functional_option.rs:133 — ibcmd_xml::metadata::functional_option::project 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.
  • ibcmd_xml::dcs::parse_dcs_conditional_appearance_body (cyclomatic 23) crates/ibcmd-xml/src/dcs.rs:2776 — ibcmd_xml::dcs::parse_dcs_conditional_appearance_body 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.
  • ibcmd_xml::dcs_template::inspect_schema_file (cyclomatic 23) crates/ibcmd-xml/src/dcs_template.rs:599 — ibcmd_xml::dcs_template::inspect_schema_file 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.
  • ibcmd_xml::dcs_template::inspect_terminal_template_schema_file (cyclomatic 23) crates/ibcmd-xml/src/dcs_template.rs:705 — ibcmd_xml::dcs_template::inspect_terminal_template_schema_file 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.
  • ibcmd_xml::metadata::package::inspect_package_identity (cyclomatic 23) crates/ibcmd-xml/src/metadata/package.rs:32 — ibcmd_xml::metadata::package::inspect_package_identity 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.
  • ibcmd_xml::dcs::parse_dcs_order (cyclomatic 22) crates/ibcmd-xml/src/dcs.rs:3648 — ibcmd_xml::dcs::parse_dcs_order has cyclomatic complexity 22 (threshold 15). To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (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 — the same kind of value, with no behaviour of its own — 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.
  • ibcmd_xml::dcs::preflight_dcs_settings_serialization (cyclomatic 22) crates/ibcmd-xml/src/dcs.rs:4377 — ibcmd_xml::dcs::preflight_dcs_settings_serialization 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.
  • ibcmd_xml::dcs_schema::parse_document (cyclomatic 22) crates/ibcmd-xml/src/dcs_schema.rs:2326 — ibcmd_xml::dcs_schema::parse_document has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
  • + 40 more in this group — see findings.md.
D1 · Cyclomatic Complexity · ibcmd_dump · ×64
  • ibcmd_dump::mssql_dump::dump_table_rows_streamed (cyclomatic 211) crates/ibcmd-dump/src/mssql_dump/mod.rs:4807 — ibcmd_dump::mssql_dump::dump_table_rows_streamed has cyclomatic complexity 211 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
  • ibcmd_dump::mssql_dump::extract_metadata_source_xml_from_text_row_with_owner_graph_diagnostic (cyclomatic 87) crates/ibcmd-dump/src/mssql_dump/mod.rs:13579 — ibcmd_dump::mssql_dump::extract_metadata_source_xml_from_text_row_with_owner_graph_diagnostic has cyclomatic complexity 87 (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.
  • ibcmd_dump::mssql_dump::dump_table_rows_with_options_mode (cyclomatic 77) crates/ibcmd-dump/src/mssql_dump/mod.rs:3941 — ibcmd_dump::mssql_dump::dump_table_rows_with_options_mode has cyclomatic complexity 77 (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.
  • ibcmd_dump::mssql_dump::metadata::metadata_source_for_object_fields (cyclomatic 76) crates/ibcmd-dump/src/mssql_dump/metadata.rs:433 — ibcmd_dump::mssql_dump::metadata::metadata_source_for_object_fields has cyclomatic complexity 76 (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 — the same kind of value, with no behaviour of its own — 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.
  • ibcmd_dump::mssql_dump::source_assets::write_source_asset_inner (cyclomatic 76) crates/ibcmd-dump/src/mssql_dump/source_assets.rs:2323 — ibcmd_dump::mssql_dump::source_assets::write_source_asset_inner has cyclomatic complexity 76 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
  • ibcmd_dump::mssql_dump::refs::standalone_child_reference (cyclomatic 61) crates/ibcmd-dump/src/mssql_dump/refs.rs:1582 — ibcmd_dump::mssql_dump::refs::standalone_child_reference has cyclomatic complexity 61 (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.
  • ibcmd_dump::mssql_dump::extension::root::extension_root_xml (cyclomatic 48) crates/ibcmd-dump/src/mssql_dump/extension/root.rs:56 — ibcmd_dump::mssql_dump::extension::root::extension_root_xml 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.
  • ibcmd_dump::mssql_dump::dump_table_row_bytes (cyclomatic 47) crates/ibcmd-dump/src/mssql_dump/mod.rs:7225 — ibcmd_dump::mssql_dump::dump_table_row_bytes has cyclomatic complexity 47 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
  • ibcmd_dump::mssql_dump::source_assets::source_assets_from_metadata_text_inner (cyclomatic 38) crates/ibcmd-dump/src/mssql_dump/source_assets.rs:1582 — ibcmd_dump::mssql_dump::source_assets::source_assets_from_metadata_text_inner 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.
  • ibcmd_dump::mssql_dump::parse_register_properties_from_text (cyclomatic 37) crates/ibcmd-dump/src/mssql_dump/mod.rs:18119 — ibcmd_dump::mssql_dump::parse_register_properties_from_text has cyclomatic complexity 37 (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.
  • ibcmd_dump::mssql_dump::dump_config_inner (cyclomatic 36) crates/ibcmd-dump/src/mssql_dump/mod.rs:2576 — ibcmd_dump::mssql_dump::dump_config_inner 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.
  • ibcmd_dump::mssql_dump::parse_attribute_tabular_section_child_objects_with_declared_failure (cyclomatic 36) crates/ibcmd-dump/src/mssql_dump/mod.rs:20298 — ibcmd_dump::mssql_dump::parse_attribute_tabular_section_child_objects_with_declared_failure 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.
  • ibcmd_dump::mssql_dump::format_register_source_xml (cyclomatic 34) crates/ibcmd-dump/src/mssql_dump/mod.rs:38420 — ibcmd_dump::mssql_dump::format_register_source_xml has cyclomatic complexity 34 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
  • ibcmd_dump::mssql_dump::push_metadata_child_properties_xml_with_tail_order (cyclomatic 33) crates/ibcmd-dump/src/mssql_dump/mod.rs:41576 — ibcmd_dump::mssql_dump::push_metadata_child_properties_xml_with_tail_order has cyclomatic complexity 33 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
  • ibcmd_dump::mssql_dump::parse_flowchart_item (cyclomatic 32) crates/ibcmd-dump/src/mssql_dump/mod.rs:8213 — ibcmd_dump::mssql_dump::parse_flowchart_item has cyclomatic complexity 32 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
  • ibcmd_dump::mssql_dump::register_child_object_tag (cyclomatic 27) crates/ibcmd-dump/src/mssql_dump/mod.rs:19857 — ibcmd_dump::mssql_dump::register_child_object_tag has cyclomatic complexity 27 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
  • ibcmd_dump::mssql_dump::refs::extract_configuration_source_xml (cyclomatic 27) crates/ibcmd-dump/src/mssql_dump/refs.rs:3563 — ibcmd_dump::mssql_dump::refs::extract_configuration_source_xml 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.
  • ibcmd_dump::mssql_dump::metadata::without_adoption_headers (cyclomatic 26) crates/ibcmd-dump/src/mssql_dump/metadata.rs:222 — ibcmd_dump::mssql_dump::metadata::without_adoption_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.
  • ibcmd_dump::mssql_dump::parse_chart_of_characteristic_types_properties_from_text (cyclomatic 23) crates/ibcmd-dump/src/mssql_dump/mod.rs:26621 — ibcmd_dump::mssql_dump::parse_chart_of_characteristic_types_properties_from_text has cyclomatic complexity 23 (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 — the same kind of value, with no behaviour of its own — 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.
  • ibcmd_dump::mssql_dump::source_assets::normalize_ws_definition_own_namespace_prefixes (cyclomatic 23) crates/ibcmd-dump/src/mssql_dump/source_assets.rs:1941 — ibcmd_dump::mssql_dump::source_assets::normalize_ws_definition_own_namespace_prefixes 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.
  • ibcmd_dump::mssql_dump::parse_information_register_child_command_properties_from_fields (cyclomatic 22) crates/ibcmd-dump/src/mssql_dump/mod.rs:10198 — ibcmd_dump::mssql_dump::parse_information_register_child_command_properties_from_fields has cyclomatic complexity 22 (threshold 15). To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (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 — the same kind of value, with no behaviour of its own — 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.
  • ibcmd_dump::mssql_dump::parse_strict_tabular_sections (cyclomatic 22) crates/ibcmd-dump/src/mssql_dump/mod.rs:15458 — ibcmd_dump::mssql_dump::parse_strict_tabular_sections 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.
  • ibcmd_dump::mssql_dump::parse_cct_attribute_properties (cyclomatic 22) crates/ibcmd-dump/src/mssql_dump/mod.rs:27479 — ibcmd_dump::mssql_dump::parse_cct_attribute_properties has cyclomatic complexity 22 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
  • ibcmd_dump::mssql_dump::validate_catalog_child_objects (cyclomatic 22) crates/ibcmd-dump/src/mssql_dump/mod.rs:28699 — ibcmd_dump::mssql_dump::validate_catalog_child_objects 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.
  • ibcmd_dump::mssql_dump::source_assets::source_asset_paths_with_indexes (cyclomatic 22) crates/ibcmd-dump/src/mssql_dump/source_assets.rs:969 — ibcmd_dump::mssql_dump::source_assets::source_asset_paths_with_indexes 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.
  • + 39 more in this group — see findings.md.
D2 · Cognitive Complexity · ibcmd_form_body · ×62
  • ibcmd_form_body::form_body::format_form_child_item_xml (cognitive 535) crates/ibcmd-form-body/src/form_body.rs:33250 — ibcmd_form_body::form_body::format_form_child_item_xml has cognitive complexity 535 (threshold 15). Drivers by points: if/else 307 (382 pts), boolean chains 123, loops 12 (27 pts), match/switch 1 (3 pts) (nesting depth added 92). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level.
  • ibcmd_form_body::form_body::parse_form_child_item_with_metadata_owners (cognitive 505) crates/ibcmd-form-body/src/form_body.rs:13061 — ibcmd_form_body::form_body::parse_form_child_item_with_metadata_owners has cognitive complexity 505 (threshold 15). Drivers by points: if/else 398 (402 pts), boolean chains 93, match/switch 9 (10 pts) (nesting depth added 5). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level.
  • ibcmd_form_body::form_body::format_form_body_open_xml_with_dcs_profiles (cognitive 110) crates/ibcmd-form-body/src/form_body.rs:31693 — ibcmd_form_body::form_body::format_form_body_open_xml_with_dcs_profiles has cognitive complexity 110 (threshold 15). Drivers by points: if/else 63 (99 pts), loops 4 (10 pts), boolean chains 1 (nesting depth added 42). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_form_body::form_body::collect_form_child_item_indexes_from_field_traced (cognitive 108) crates/ibcmd-form-body/src/form_body.rs:12240 — ibcmd_form_body::form_body::collect_form_child_item_indexes_from_field_traced has cognitive complexity 108 (threshold 15). Drivers by points: if/else 37 (87 pts), boolean chains 10, loops 3 (7 pts), match/switch 1 (4 pts) (nesting depth added 57). To reduce it, flatten the nesting: this score is depth rather than breadth — most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language's equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function.
  • ibcmd_form_body::form_body::parse_form_dynamic_list_query_selection (cognitive 107) crates/ibcmd-form-body/src/form_body.rs:8878 — ibcmd_form_body::form_body::parse_form_dynamic_list_query_selection has cognitive complexity 107 (threshold 15). Drivers by points: if/else 21 (54 pts), boolean chains 21, loops 11 (21 pts), match/switch 6 (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.
  • ibcmd_form_body::form_body::format_form_chart_settings_body_xml (cognitive 104) crates/ibcmd-form-body/src/form_body.rs:40619 — ibcmd_form_body::form_body::format_form_chart_settings_body_xml has cognitive complexity 104 (threshold 15). Drivers by points: if/else 50 (72 pts), boolean chains 13, match/switch 5 (10 pts), loops 9 (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.
  • ibcmd_form_body::form_body::format_form_attributes_items_xml_with_dcs_profiles (cognitive 88) crates/ibcmd-form-body/src/form_body.rs:37563 — ibcmd_form_body::form_body::format_form_attributes_items_xml_with_dcs_profiles has cognitive complexity 88 (threshold 15). Drivers by points: if/else 31 (58 pts), loops 9 (27 pts), boolean chains 3 (nesting depth added 45). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_form_body::form_body::walk_form_bound_chain_members (cognitive 72) crates/ibcmd-form-body/src/form_body.rs:26058 — ibcmd_form_body::form_body::walk_form_bound_chain_members has cognitive complexity 72 (threshold 15). Drivers by points: if/else 12 (35 pts), loops 10 (31 pts), match/switch 2 (5 pts), boolean chains 1 (nesting depth added 47). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_form_body::form_body::format_form_usual_group_properties_xml (cognitive 63) crates/ibcmd-form-body/src/form_body.rs:36715 — ibcmd_form_body::form_body::format_form_usual_group_properties_xml has cognitive complexity 63 (threshold 15). Drivers by points: if/else 21 (60 pts), match/switch 1 (2 pts), loops 1 (nesting depth added 40). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_form_body::form_body::tokenize_1c_query (cognitive 62) crates/ibcmd-form-body/src/form_body.rs:8518 — ibcmd_form_body::form_body::tokenize_1c_query has cognitive complexity 62 (threshold 15). Drivers by points: if/else 10 (26 pts), loops 7 (20 pts), boolean chains 16 (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.
  • ibcmd_form_body::form_body::format_form_page_properties_xml (cognitive 62) crates/ibcmd-form-body/src/form_body.rs:36277 — ibcmd_form_body::form_body::format_form_page_properties_xml has cognitive complexity 62 (threshold 15). Drivers by points: if/else 20 (58 pts), match/switch 1 (2 pts), boolean chains 1, loops 1 (nesting depth added 39). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_form_body::form_body::format_form_table_property_xml (cognitive 57) crates/ibcmd-form-body/src/form_body.rs:32574 — ibcmd_form_body::form_body::format_form_table_property_xml has cognitive complexity 57 (threshold 15). Drivers by points: match/switch 21 (41 pts), if/else 6 (9 pts), boolean chains 4, loops 1 (3 pts) (nesting depth added 25). 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.
  • ibcmd_form_body::form_body::apply_form_attribute_scoped_use_always_bindings (cognitive 46) crates/ibcmd-form-body/src/form_body.rs:5536 — ibcmd_form_body::form_body::apply_form_attribute_scoped_use_always_bindings has cognitive complexity 46 (threshold 15). Drivers by points: if/else 18 (42 pts), loops 2 (3 pts), boolean chains 1 (nesting depth added 25). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_form_body::form_body::form_dynamic_list_use_always_universe (cognitive 45) crates/ibcmd-form-body/src/form_body.rs:7480 — ibcmd_form_body::form_body::form_dynamic_list_use_always_universe has cognitive complexity 45 (threshold 15). Drivers by points: if/else 15 (29 pts), loops 4 (10 pts), boolean chains 4, match/switch 1 (2 pts) (nesting depth added 21). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_form_body::form_body::form_command_interface_command_named (cognitive 41) crates/ibcmd-form-body/src/form_body.rs:31094 — ibcmd_form_body::form_body::form_command_interface_command_named has cognitive complexity 41 (threshold 15). Drivers by points: if/else 20 (36 pts), boolean chains 4, 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.
  • ibcmd_form_body::form_body::parse_form_child_item_data_path (cognitive 37) crates/ibcmd-form-body/src/form_body.rs:24029 — ibcmd_form_body::form_body::parse_form_child_item_data_path has cognitive complexity 37 (threshold 15). Drivers by points: if/else 26 (28 pts), match/switch 4 (6 pts), boolean chains 2, loops 1 (nesting depth added 4). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level.
  • ibcmd_form_body::form_body::collect_form_child_item_indexes_with_object_refs (cognitive 35) crates/ibcmd-form-body/src/form_body.rs:11875 — ibcmd_form_body::form_body::collect_form_child_item_indexes_with_object_refs has cognitive complexity 35 (threshold 15). Drivers by points: if/else 14 (26 pts), loops 8 (9 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.
  • ibcmd_form_body::form_body::parse_form_schema_backed_event_record (cognitive 35) crates/ibcmd-form-body/src/form_body.rs:23549 — ibcmd_form_body::form_body::parse_form_schema_backed_event_record has cognitive complexity 35 (threshold 15). Drivers by points: if/else 13 (25 pts), boolean chains 5, loops 3 (5 pts) (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_form_body::form_body::parse_form_attribute_direct_use_always (cognitive 33) crates/ibcmd-form-body/src/form_body.rs:6700 — ibcmd_form_body::form_body::parse_form_attribute_direct_use_always has cognitive complexity 33 (threshold 15). Drivers by points: if/else 16 (24 pts), boolean chains 5, match/switch 1 (3 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.
  • ibcmd_form_body::form_body::collect_form_item_rooted_chain_roots (cognitive 32) crates/ibcmd-form-body/src/form_body.rs:11653 — ibcmd_form_body::form_body::collect_form_item_rooted_chain_roots has cognitive complexity 32 (threshold 15). Drivers by points: if/else 11 (26 pts), loops 4 (6 pts) (nesting depth added 17). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_form_body::form_body::format_form_command_interface_xml (cognitive 32) crates/ibcmd-form-body/src/form_body.rs:38318 — ibcmd_form_body::form_body::format_form_command_interface_xml has cognitive complexity 32 (threshold 15). Drivers by points: if/else 12 (20 pts), loops 4 (12 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.
  • ibcmd_form_body::form_body::extract_form_body_xml_from_body_detailed_single (cognitive 31) crates/ibcmd-form-body/src/form_body.rs:477 — ibcmd_form_body::form_body::extract_form_body_xml_from_body_detailed_single has cognitive complexity 31 (threshold 15). Drivers by points: if/else 26 (27 pts), boolean chains 3, match/switch 1 (nesting depth added 1). To reduce it, split the body: this score is breadth rather than depth — many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
  • ibcmd_form_body::form_body::form_gantt_chart_series_like_xml (cognitive 31) crates/ibcmd-form-body/src/form_body.rs:39482 — ibcmd_form_body::form_body::form_gantt_chart_series_like_xml has cognitive complexity 31 (threshold 15). Drivers by points: if/else 19, boolean chains 9, loops 3. To reduce it, split the body: this score is breadth rather than depth — many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
  • ibcmd_form_body::dcs::canonicalize_form_server_state_conditional_appearances (cognitive 30) crates/ibcmd-form-body/src/dcs.rs:1405 — ibcmd_form_body::dcs::canonicalize_form_server_state_conditional_appearances has cognitive complexity 30 (threshold 15). Drivers by points: if/else 7 (22 pts), boolean chains 5, match/switch 1 (2 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.
  • ibcmd_form_body::form_body::collect_form_body_events (cognitive 29) crates/ibcmd-form-body/src/form_body.rs:4030 — ibcmd_form_body::form_body::collect_form_body_events has cognitive complexity 29 (threshold 15). Drivers by points: if/else 8 (23 pts), loops 3 (6 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.
  • + 37 more in this group — see findings.md.
D4 · Code Duplication · Duplicated block (11 lines × 2) · ×56
  • Duplicated block (11 lines × 2) crates/ibcmd-1c-text/src/brace_list.rs:15 — crates/ibcmd-1c-text/src/brace_list.rs:15-25 | crates/ibcmd-dump/src/mssql_dump/mod.rs:12509-12519 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-1c-text/src/brace_list.rs:15` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (11 lines × 2) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:1277 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:1277-1287 | crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:1420-1430 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:1277` it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows — the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members' bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run — a one-line delegation has no helper inside it to lift — so generate the run from the set it enumerates, or accept it and keep each member's own documentation with it.
  • Duplicated block (11 lines × 2) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:3687 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:3687-3697 | crates/ibcmd-compiler-families/src/compiler/families/utility.rs:2025-2035 — before extracting anything, compare `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs` and `crates/ibcmd-compiler-families/src/compiler/families/utility.rs` as WHOLE FILES: this scan already matched 65 separate duplicated blocks between them, totalling at least 934 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. 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 `return` inside it is the body's own exit and keeps its meaning in the moved unit.
  • Duplicated block (11 lines × 2) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:3706 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:3706-3716 | crates/ibcmd-compiler-families/src/compiler/families/utility.rs:2045-2055 — before extracting anything, compare `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs` and `crates/ibcmd-compiler-families/src/compiler/families/utility.rs` as WHOLE FILES: this scan already matched 65 separate duplicated blocks between them, totalling at least 934 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:3706` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (11 lines × 2) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:4099 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:4099-4109 | crates/ibcmd-compiler-families/src/compiler/families/utility.rs:2342-2352 — before extracting anything, compare `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs` and `crates/ibcmd-compiler-families/src/compiler/families/utility.rs` as WHOLE FILES: this scan already matched 65 separate duplicated blocks between them, totalling at least 934 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. 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 `return` inside it is the body's own exit and keeps its meaning in the moved unit.
  • Duplicated block (11 lines × 2) crates/ibcmd-compiler-families/src/compiler/families/commands.rs:1156 — crates/ibcmd-compiler-families/src/compiler/families/commands.rs:1156-1166 | crates/ibcmd-compiler-families/src/compiler/families/modules.rs:375-385 — before extracting anything, compare `crates/ibcmd-compiler-families/src/compiler/families/commands.rs` and `crates/ibcmd-compiler-families/src/compiler/families/modules.rs` as WHOLE FILES: this scan already matched 9 separate duplicated blocks between them, totalling at least 97 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/commands.rs:1156` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (11 lines × 2) crates/ibcmd-compiler-families/src/compiler/families/native.rs:1022 — crates/ibcmd-compiler-families/src/compiler/families/native.rs:1022-1032 | crates/ibcmd-compiler-families/src/compiler/families/native.rs:1085-1095 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/native.rs:1022` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (11 lines × 2) crates/ibcmd-compiler-families/src/compiler/families/simple.rs:1326 — crates/ibcmd-compiler-families/src/compiler/families/simple.rs:1326-1336 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:1588-1598 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/simple.rs:1326` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (11 lines × 2) crates/ibcmd-compiler/src/compiler/bodies/mxl_native.rs:463 — crates/ibcmd-compiler/src/compiler/bodies/mxl_native.rs:463-473 | crates/ibcmd-compiler/src/compiler/root.rs:1221-1231 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice. 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 `return` inside it is the body's own exit and keeps its meaning in the moved unit.
  • Duplicated block (11 lines × 2) REDACTED:1844 — REDACTED:1844-1854 | crates/ibcmd-config-apply/src/mssql_config_apply/mod.rs:1775-1785 — before extracting anything, compare `REDACTED` and `crates/ibcmd-config-apply/src/mssql_config_apply/mod.rs` as WHOLE FILES: this scan already matched 5 separate duplicated blocks between them, totalling at least 61 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place.
  • Duplicated block (11 lines × 2) crates/ibcmd-core/src/migration/v2_20_to_v2_21.rs:130 — crates/ibcmd-core/src/migration/v2_20_to_v2_21.rs:130-140 | crates/ibcmd-core/src/migration/v2_21_to_v2_20.rs:143-153 — before extracting anything, compare `crates/ibcmd-core/src/migration/v2_20_to_v2_21.rs` and `crates/ibcmd-core/src/migration/v2_21_to_v2_20.rs` as WHOLE FILES: this scan already matched 6 separate duplicated blocks between them, totalling at least 67 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-core/src/migration/v2_20_to_v2_21.rs:130` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (11 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:5178 — crates/ibcmd-dump/src/mssql_dump/mod.rs:5178-5188 | crates/ibcmd-dump/src/mssql_dump/mod.rs:5241-5251 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (11 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:34168 — crates/ibcmd-dump/src/mssql_dump/mod.rs:34168-34178 | crates/ibcmd-dump/src/mssql_dump/mod.rs:34309-34319 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:34168` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (11 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:38227 — crates/ibcmd-dump/src/mssql_dump/mod.rs:38227-38237 | crates/ibcmd-dump/src/mssql_dump/mod.rs:38305-38315 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:38227` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note first that the copies are not typed on the same thing: the declarations holding them bind `dimension` to `&SequenceDimension` in one and `&RecalculationDimension` in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH — their common supertype where they have one, or a new abstraction over them where they do not — and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract.
  • Duplicated block (11 lines × 2) crates/ibcmd-dump/src/mssql_dump/offline_context.rs:81 — crates/ibcmd-dump/src/mssql_dump/offline_context.rs:81-91 | src/form_provenance.rs:328-338 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/offline_context.rs:81` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (11 lines × 2) crates/ibcmd-dump/src/mssql_dump/source_assets.rs:2950 — crates/ibcmd-dump/src/mssql_dump/source_assets.rs:2950-2960 | crates/ibcmd-dump/src/mssql_dump/source_assets.rs:3264-3274 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/source_assets.rs:2950` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (11 lines × 2) crates/ibcmd-dump/src/mssql_dump/source_assets.rs:4560 — crates/ibcmd-dump/src/mssql_dump/source_assets.rs:4560-4570 | crates/ibcmd-dump/src/mssql_dump/source_assets.rs:4657-4667 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/source_assets.rs:4560` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, `crates/ibcmd-dump/src/mssql_dump/source_assets.rs:4559` calls `parse_predefined_rowset_schema`, `get` and `crates/ibcmd-dump/src/mssql_dump/source_assets.rs:4656` does not — after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
  • Duplicated block (11 lines × 2) crates/ibcmd-form-body/src/dcs.rs:1126 — crates/ibcmd-form-body/src/dcs.rs:1126-1136 | crates/ibcmd-form-body/src/dcs.rs:1328-1338 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (11 lines × 2) crates/ibcmd-form-body/src/form_body.rs:4120 — crates/ibcmd-form-body/src/form_body.rs:4120-4130 | crates/ibcmd-form-body/src/form_body.rs:23895-23905 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-form-body/src/form_body.rs:4120` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (11 lines × 2) crates/ibcmd-form-body/src/form_body.rs:36162 — crates/ibcmd-form-body/src/form_body.rs:36162-36172 | crates/ibcmd-form-body/src/form_body.rs:36234-36244 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-form-body/src/form_body.rs:36162` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (11 lines × 2) crates/ibcmd-form-body/src/form_body.rs:38914 — crates/ibcmd-form-body/src/form_body.rs:38914-38924 | crates/ibcmd-form-body/src/form_body.rs:40146-40156 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, `crates/ibcmd-form-body/src/form_body.rs:40157` calls `get`, `trim` and `crates/ibcmd-form-body/src/form_body.rs:38925` does not — after which the two agree again for 3 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
  • Duplicated block (11 lines × 2) crates/ibcmd-metadata-blob/src/lib.rs:5052 — crates/ibcmd-metadata-blob/src/lib.rs:5052-5062 | crates/ibcmd-metadata-blob/src/lib.rs:5217-5227 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-metadata-blob/src/lib.rs:5052` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (11 lines × 2) crates/ibcmd-metadata-blob/src/lib.rs:5873 — crates/ibcmd-metadata-blob/src/lib.rs:5873-5883 | crates/ibcmd-metadata-blob/src/lib.rs:6032-6042 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-metadata-blob/src/lib.rs:5873` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (11 lines × 2) crates/ibcmd-metadata-model/src/metadata_model/registers_export.rs:677 — crates/ibcmd-metadata-model/src/metadata_model/registers_export.rs:677-687 | crates/ibcmd-metadata-model/src/metadata_model/registers_export.rs:902-912 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-metadata-model/src/metadata_model/registers_export.rs:677` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, `crates/ibcmd-metadata-model/src/metadata_model/registers_export.rs:688` calls `child`, `flag`, `slot` and `crates/ibcmd-metadata-model/src/metadata_model/registers_export.rs:913` does not — after which the two agree again for 4 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
  • Duplicated block (11 lines × 2) crates/ibcmd-metadata-model/src/metadata_model/simple.rs:23 — crates/ibcmd-metadata-model/src/metadata_model/simple.rs:23-33 | crates/ibcmd-metadata-model/src/metadata_model/simple_export.rs:30-40 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once. Note first that the copies are not typed on the same thing: the declarations holding them bind `context` to `&DescriptorContext` in one and `&ExportContext` in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH — their common supertype where they have one, or a new abstraction over them where they do not — and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract.
  • + 31 more in this group — see findings.md.
D1 · Cyclomatic Complexity · ibcmd_rs · ×50
  • ibcmd_rs::run (cyclomatic 182) src/main.rs:29 — ibcmd_rs::run has cyclomatic complexity 182 (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 — the same kind of value, with no behaviour of its own — 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.
  • ibcmd_rs::mssql_apply::apply_source_change_inner (cyclomatic 50) src/mssql_apply.rs:81 — ibcmd_rs::mssql_apply::apply_source_change_inner has cyclomatic complexity 50 (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.
  • ibcmd_rs::mssql::stage_source_objects_patch (cyclomatic 44) REDACTED:3896 — ibcmd_rs::mssql::stage_source_objects_patch has cyclomatic complexity 44 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
  • ibcmd_rs::mssql::empty_stage::audit_empty_stage (cyclomatic 42) src/mssql/empty_stage.rs:1121 — ibcmd_rs::mssql::empty_stage::audit_empty_stage has cyclomatic complexity 42 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
  • ibcmd_rs::mssql::activate_staged_main_verified_inner (cyclomatic 39) REDACTED:1073 — ibcmd_rs::mssql::activate_staged_main_verified_inner has cyclomatic complexity 39 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
  • ibcmd_rs::dropin::parse::parse_infobase (cyclomatic 34) src/dropin/parse.rs:927 — ibcmd_rs::dropin::parse::parse_infobase has cyclomatic complexity 34 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
  • ibcmd_rs::mssql_extension_restructure::plan_from_source_trees (cyclomatic 34) REDACTED:1056 — ibcmd_rs::mssql_extension_restructure::plan_from_source_trees has cyclomatic complexity 34 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
  • ibcmd_rs::infobase_oracle::selected_dump_file_names_for_path (cyclomatic 29) src/infobase_oracle.rs:720 — ibcmd_rs::infobase_oracle::selected_dump_file_names_for_path 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.
  • ibcmd_rs::source_audit::audit_native_form_writer (cyclomatic 29) src/source_audit.rs:1536 — ibcmd_rs::source_audit::audit_native_form_writer 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.
  • ibcmd_rs::mssql::prepare_form_body_row (cyclomatic 28) REDACTED:6709 — ibcmd_rs::mssql::prepare_form_body_row has cyclomatic complexity 28 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
  • ibcmd_rs::commands::cf::export (cyclomatic 27) src/commands/cf.rs:1180 — ibcmd_rs::commands::cf::export 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.
  • ibcmd_rs::mssql::metadata_body_bootstrap_rows (cyclomatic 27) REDACTED:2022 — ibcmd_rs::mssql::metadata_body_bootstrap_rows 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.
  • ibcmd_rs::mssql_extension_restructure::classify (cyclomatic 27) REDACTED:259 — ibcmd_rs::mssql_extension_restructure::classify 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.
  • ibcmd_rs::file_import::prepare_locked (cyclomatic 26) src/file_import.rs:281 — ibcmd_rs::file_import::prepare_locked 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.
  • ibcmd_rs::form_provenance::correlate (cyclomatic 26) src/form_provenance.rs:526 — ibcmd_rs::form_provenance::correlate has cyclomatic complexity 26 (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.
  • ibcmd_rs::compatibility::validate_compatibility_matrix (cyclomatic 25) src/compatibility.rs:184 — ibcmd_rs::compatibility::validate_compatibility_matrix 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.
  • ibcmd_rs::dropin::export_queries::run (cyclomatic 24) src/dropin/export_queries.rs:14 — ibcmd_rs::dropin::export_queries::run 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.
  • ibcmd_rs::storage_map::classify_role (cyclomatic 24) src/storage_map.rs:446 — ibcmd_rs::storage_map::classify_role has cyclomatic complexity 24 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
  • ibcmd_rs::file_extension_export::export (cyclomatic 23) src/file_extension_export.rs:51 — ibcmd_rs::file_extension_export::export 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.
  • ibcmd_rs::load::compiled::compile_edit (cyclomatic 23) src/load/compiled.rs:106 — ibcmd_rs::load::compiled::compile_edit 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.
  • ibcmd_rs::storage_map::classify_family (cyclomatic 23) src/storage_map.rs:509 — ibcmd_rs::storage_map::classify_family 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.
  • ibcmd_rs::dropin::parse::parse_apply (cyclomatic 22) src/dropin/parse.rs:1091 — ibcmd_rs::dropin::parse::parse_apply has cyclomatic complexity 22 (threshold 15). To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (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 — the same kind of value, with no behaviour of its own — 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.
  • ibcmd_rs::extension::adopted::rewrite_element (cyclomatic 22) src/extension/adopted.rs:251 — ibcmd_rs::extension::adopted::rewrite_element 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.
  • ibcmd_rs::mssql::offline_compile::compile_source_rows_offline (cyclomatic 22) src/mssql/offline_compile.rs:36 — ibcmd_rs::mssql::offline_compile::compile_source_rows_offline 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.
  • ibcmd_rs::mssql_extension_activation::prepare_extension_activation_impl (cyclomatic 22) REDACTED:330 — ibcmd_rs::mssql_extension_activation::prepare_extension_activation_impl 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.
  • + 25 more in this group — see findings.md.
D2 · Cognitive Complexity · ibcmd_form_writer · ×49
  • ibcmd_form_writer::parse_form_xml_body_properties (cognitive 1688) crates/ibcmd-form-writer/src/lib.rs:7984 — ibcmd_form_writer::parse_form_xml_body_properties has cognitive complexity 1688 (threshold 15). Drivers by points: if/else 430 (1405 pts), boolean chains 198, match/switch 25 (83 pts), loops 2 (nesting depth added 1033). To reduce it, flatten the nesting: this score is depth rather than breadth — most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language's equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function.
  • ibcmd_form_writer::patch_form_layout_child_item_entry (cognitive 272) crates/ibcmd-form-writer/src/lib.rs:18910 — ibcmd_form_writer::patch_form_layout_child_item_entry has cognitive complexity 272 (threshold 15). Drivers by points: if/else 130 (193 pts), boolean chains 78, loops 1 (nesting depth added 63). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_form_writer::patch_form_layout_input_field_extended_options (cognitive 152) crates/ibcmd-form-writer/src/lib.rs:19960 — ibcmd_form_writer::patch_form_layout_input_field_extended_options has cognitive complexity 152 (threshold 15). Drivers by points: if/else 88 (149 pts), boolean chains 3 (nesting depth added 61). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_form_writer::dynamic_list::convert_block (cognitive 130) crates/ibcmd-form-writer/src/dynamic_list.rs:530 — ibcmd_form_writer::dynamic_list::convert_block has cognitive complexity 130 (threshold 15). Drivers by points: if/else 41 (86 pts), match/switch 9 (25 pts), boolean chains 12, loops 4 (7 pts) (nesting depth added 64). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_form_writer::format_form_layout_new_input_field_extended_options (cognitive 85) crates/ibcmd-form-writer/src/lib.rs:17527 — ibcmd_form_writer::format_form_layout_new_input_field_extended_options has cognitive complexity 85 (threshold 15). Drivers by points: if/else 65 (85 pts) (nesting depth added 20). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level.
  • ibcmd_form_writer::format_native_form_body (cognitive 62) crates/ibcmd-form-writer/src/lib.rs:6773 — ibcmd_form_writer::format_native_form_body has cognitive complexity 62 (threshold 15). Drivers by points: match/switch 16 (23 pts), if/else 14 (17 pts), loops 10 (15 pts), boolean chains 7 (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.
  • ibcmd_form_writer::dynamic_list::dynamic_list_bag (cognitive 58) crates/ibcmd-form-writer/src/dynamic_list.rs:1132 — ibcmd_form_writer::dynamic_list::dynamic_list_bag has cognitive complexity 58 (threshold 15). Drivers by points: if/else 14 (29 pts), loops 6 (16 pts), match/switch 6 (8 pts), boolean chains 5 (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.
  • ibcmd_form_writer::format_native_child_item (cognitive 50) crates/ibcmd-form-writer/src/lib.rs:2072 — ibcmd_form_writer::format_native_child_item has cognitive complexity 50 (threshold 15). Drivers by points: if/else 16 (25 pts), match/switch 10 (18 pts), loops 3 (6 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.
  • ibcmd_form_writer::form_chart::chart_record (cognitive 48) crates/ibcmd-form-writer/src/form_chart.rs:283 — ibcmd_form_writer::form_chart::chart_record has cognitive complexity 48 (threshold 15). Drivers by points: loops 24 (25 pts), match/switch 16 (19 pts), if/else 3 (4 pts) (nesting depth added 5). 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.
  • ibcmd_form_writer::native_dynamic_list_references (cognitive 46) crates/ibcmd-form-writer/src/lib.rs:1433 — ibcmd_form_writer::native_dynamic_list_references has cognitive complexity 46 (threshold 15). Drivers by points: if/else 14 (28 pts), loops 9 (14 pts), boolean chains 4 (nesting depth added 19). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_form_writer::patch_form_layout_properties (cognitive 44) crates/ibcmd-form-writer/src/lib.rs:15444 — ibcmd_form_writer::patch_form_layout_properties has cognitive complexity 44 (threshold 15). Drivers by points: if/else 38 (41 pts), match/switch 1 (2 pts), boolean chains 1 (nesting depth added 4). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level.
  • ibcmd_form_writer::apply_form_choice_list_part (cognitive 41) crates/ibcmd-form-writer/src/lib.rs:13750 — ibcmd_form_writer::apply_form_choice_list_part has cognitive complexity 41 (threshold 15). Drivers by points: if/else 11 (27 pts), match/switch 3 (7 pts), boolean chains 6, loops 1 (nesting depth added 20). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_form_writer::form::xml_2_21_writer::apply_rules (cognitive 40) crates/ibcmd-form-writer/src/form/xml_2_21_writer.rs:1176 — ibcmd_form_writer::form::xml_2_21_writer::apply_rules has cognitive complexity 40 (threshold 15). Drivers by points: if/else 10 (20 pts), match/switch 4 (10 pts), loops 5 (9 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.
  • ibcmd_form_writer::native_field_payload (cognitive 38) crates/ibcmd-form-writer/src/lib.rs:4432 — ibcmd_form_writer::native_field_payload has cognitive complexity 38 (threshold 15). Drivers by points: if/else 13 (23 pts), boolean chains 8, match/switch 4 (7 pts) (nesting depth added 13). The drivers above price the dispatch low by construction — a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full — so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident.
  • ibcmd_form_writer::native_root_property_bag (cognitive 33) crates/ibcmd-form-writer/src/lib.rs:3052 — ibcmd_form_writer::native_root_property_bag has cognitive complexity 33 (threshold 15). Drivers by points: if/else 16 (20 pts), match/switch 6 (11 pts), boolean chains 2 (nesting depth added 9). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level.
  • ibcmd_form_writer::form_base_free_model_blockers (cognitive 33) crates/ibcmd-form-writer/src/lib.rs:7498 — ibcmd_form_writer::form_base_free_model_blockers has cognitive complexity 33 (threshold 15). Drivers by points: if/else 13 (20 pts), boolean chains 8, loops 5 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_form_writer::dynamic_list::retype (cognitive 33) crates/ibcmd-form-writer/src/dynamic_list.rs:783 — ibcmd_form_writer::dynamic_list::retype has cognitive complexity 33 (threshold 15). Drivers by points: if/else 11 (21 pts), loops 4 (7 pts), match/switch 1 (5 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.
  • ibcmd_form_writer::native_embedded_spreadsheet (cognitive 32) crates/ibcmd-form-writer/src/lib.rs:6048 — ibcmd_form_writer::native_embedded_spreadsheet has cognitive complexity 32 (threshold 15). Drivers by points: if/else 16 (24 pts), loops 3, match/switch 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.
  • ibcmd_form_writer::validate_form_xml_document (cognitive 31) crates/ibcmd-form-writer/src/lib.rs:7439 — ibcmd_form_writer::validate_form_xml_document has cognitive complexity 31 (threshold 15). Drivers by points: if/else 8 (24 pts), boolean chains 4, match/switch 1 (2 pts), loops 1 (nesting depth added 17). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_form_writer::adopted_form::split_form_base_xml (cognitive 31) crates/ibcmd-form-writer/src/adopted_form.rs:20 — ibcmd_form_writer::adopted_form::split_form_base_xml has cognitive complexity 31 (threshold 15). Drivers by points: if/else 11 (26 pts), boolean chains 2, match/switch 1 (2 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.
  • ibcmd_form_writer::native_dynamic_list_field_maps (cognitive 30) crates/ibcmd-form-writer/src/lib.rs:1572 — ibcmd_form_writer::native_dynamic_list_field_maps has cognitive complexity 30 (threshold 15). Drivers by points: loops 7 (18 pts), if/else 3 (9 pts), match/switch 1 (2 pts), boolean chains 1 (nesting depth added 18). 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.
  • ibcmd_form_writer::adopted_form::without_adoption (cognitive 30) crates/ibcmd-form-writer/src/adopted_form.rs:219 — ibcmd_form_writer::adopted_form::without_adoption has cognitive complexity 30 (threshold 15). Drivers by points: if/else 5 (18 pts), loops 4 (6 pts), match/switch 2 (4 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.
  • ibcmd_form_writer::form::load_8_5_1::report_state_of (cognitive 30) crates/ibcmd-form-writer/src/form/load_8_5_1.rs:418 — ibcmd_form_writer::form::load_8_5_1::report_state_of has cognitive complexity 30 (threshold 15). Drivers by points: if/else 8 (18 pts), loops 4 (10 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.
  • ibcmd_form_writer::pack_form_body_blob_from_form_xml_through (cognitive 29) crates/ibcmd-form-writer/src/lib.rs:1130 — ibcmd_form_writer::pack_form_body_blob_from_form_xml_through has cognitive complexity 29 (threshold 15). Drivers by points: if/else 13 (28 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.
  • ibcmd_form_writer::native_form_body_blockers (cognitive 28) crates/ibcmd-form-writer/src/lib.rs:6598 — ibcmd_form_writer::native_form_body_blockers has cognitive complexity 28 (threshold 15). Drivers by points: if/else 5 (13 pts), loops 5 (9 pts), boolean chains 3, match/switch 1 (3 pts) (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • + 24 more in this group — see findings.md.
D1 · Cyclomatic Complexity · ibcmd_form_body · ×42
  • ibcmd_form_body::form_body::format_form_child_item_xml (cyclomatic 441) crates/ibcmd-form-body/src/form_body.rs:33250 — ibcmd_form_body::form_body::format_form_child_item_xml has cyclomatic complexity 441 (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.
  • ibcmd_form_body::form_body::parse_form_child_item_with_metadata_owners (cyclomatic 403) crates/ibcmd-form-body/src/form_body.rs:13061 — ibcmd_form_body::form_body::parse_form_child_item_with_metadata_owners has cyclomatic complexity 403 (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.
  • ibcmd_form_body::form_body::format_form_table_property_xml (cyclomatic 109) crates/ibcmd-form-body/src/form_body.rs:32574 — ibcmd_form_body::form_body::format_form_table_property_xml has cyclomatic complexity 109 (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 — the same kind of value, with no behaviour of its own — 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. This is NOT this file's highest cyclomatic complexity: ibcmd_form_body::form_body::form_event_name_from_identifier (cyclomatic 112) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • ibcmd_form_body::form_body::format_form_chart_settings_body_xml (cyclomatic 74) crates/ibcmd-form-body/src/form_body.rs:40619 — ibcmd_form_body::form_body::format_form_chart_settings_body_xml has cyclomatic complexity 74 (threshold 15). To reduce it, separate the cases: extract each independent 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's highest cyclomatic complexity: ibcmd_form_body::form_body::form_event_name_from_identifier (cyclomatic 112) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • ibcmd_form_body::form_body::format_form_body_open_xml_with_dcs_profiles (cyclomatic 66) crates/ibcmd-form-body/src/form_body.rs:31693 — ibcmd_form_body::form_body::format_form_body_open_xml_with_dcs_profiles has cyclomatic complexity 66 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top. This is NOT this file's highest cyclomatic complexity: ibcmd_form_body::form_body::form_event_name_from_identifier (cyclomatic 112) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • ibcmd_form_body::form_body::parse_form_dynamic_list_query_selection (cyclomatic 63) crates/ibcmd-form-body/src/form_body.rs:8878 — ibcmd_form_body::form_body::parse_form_dynamic_list_query_selection has cyclomatic complexity 63 (threshold 15). To reduce it, separate the cases: extract each independent 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's highest cyclomatic complexity: ibcmd_form_body::form_body::form_event_name_from_identifier (cyclomatic 112) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • ibcmd_form_body::form_body::collect_form_child_item_indexes_from_field_traced (cyclomatic 50) crates/ibcmd-form-body/src/form_body.rs:12240 — ibcmd_form_body::form_body::collect_form_child_item_indexes_from_field_traced has cyclomatic complexity 50 (threshold 15). To reduce it, separate the cases: extract each independent 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's highest cyclomatic complexity: ibcmd_form_body::form_body::form_event_name_from_identifier (cyclomatic 112) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • ibcmd_form_body::form_body::format_form_page_properties_xml (cyclomatic 44) crates/ibcmd-form-body/src/form_body.rs:36277 — ibcmd_form_body::form_body::format_form_page_properties_xml has cyclomatic complexity 44 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top. This is NOT this file's highest cyclomatic complexity: ibcmd_form_body::form_body::form_event_name_from_identifier (cyclomatic 112) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • ibcmd_form_body::form_body::format_form_usual_group_properties_xml (cyclomatic 43) crates/ibcmd-form-body/src/form_body.rs:36715 — ibcmd_form_body::form_body::format_form_usual_group_properties_xml has cyclomatic complexity 43 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top. This is NOT this file's highest cyclomatic complexity: ibcmd_form_body::form_body::form_event_name_from_identifier (cyclomatic 112) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • ibcmd_form_body::form_body::format_form_attributes_items_xml_with_dcs_profiles (cyclomatic 41) crates/ibcmd-form-body/src/form_body.rs:37563 — ibcmd_form_body::form_body::format_form_attributes_items_xml_with_dcs_profiles has cyclomatic complexity 41 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top. This is NOT this file's highest cyclomatic complexity: ibcmd_form_body::form_body::form_event_name_from_identifier (cyclomatic 112) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • ibcmd_form_body::form_body::form_child_item_tag (cyclomatic 36) crates/ibcmd-form-body/src/form_body.rs:22286 — ibcmd_form_body::form_body::form_child_item_tag has cyclomatic complexity 36 (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 — the same kind of value, with no behaviour of its own — 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. This is NOT this file's highest cyclomatic complexity: ibcmd_form_body::form_body::form_event_name_from_identifier (cyclomatic 112) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • ibcmd_form_body::form_body::parse_form_child_item_data_path (cyclomatic 36) crates/ibcmd-form-body/src/form_body.rs:24029 — ibcmd_form_body::form_body::parse_form_child_item_data_path has cyclomatic complexity 36 (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's highest cyclomatic complexity: ibcmd_form_body::form_body::form_event_name_from_identifier (cyclomatic 112) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • ibcmd_form_body::form_body::tokenize_1c_query (cyclomatic 34) crates/ibcmd-form-body/src/form_body.rs:8518 — ibcmd_form_body::form_body::tokenize_1c_query has cyclomatic complexity 34 (threshold 15). To reduce it, separate the branches: extract each independent case into its own named function so the top-level body reads as a short sequence of named decisions. This is NOT this file's highest cyclomatic complexity: ibcmd_form_body::form_body::form_event_name_from_identifier (cyclomatic 112) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • ibcmd_form_body::form_body::parse_form_child_item_extended_tooltip (cyclomatic 34) crates/ibcmd-form-body/src/form_body.rs:22817 — ibcmd_form_body::form_body::parse_form_child_item_extended_tooltip has cyclomatic complexity 34 (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 — the same kind of value, with no behaviour of its own — 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. This is NOT this file's highest cyclomatic complexity: ibcmd_form_body::form_body::form_event_name_from_identifier (cyclomatic 112) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • ibcmd_form_body::form_body::walk_form_bound_chain_members (cyclomatic 34) crates/ibcmd-form-body/src/form_body.rs:26058 — ibcmd_form_body::form_body::walk_form_bound_chain_members has cyclomatic complexity 34 (threshold 15). To reduce it, separate the branches: extract each independent case into its own named function so the top-level body reads as a short sequence of named decisions. This is NOT this file's highest cyclomatic complexity: ibcmd_form_body::form_body::form_event_name_from_identifier (cyclomatic 112) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • ibcmd_form_body::form_body::extract_form_body_xml_from_body_detailed_single (cyclomatic 30) crates/ibcmd-form-body/src/form_body.rs:477 — ibcmd_form_body::form_body::extract_form_body_xml_from_body_detailed_single has cyclomatic complexity 30 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages. This is NOT this file's highest cyclomatic complexity: ibcmd_form_body::form_body::form_event_name_from_identifier (cyclomatic 112) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • ibcmd_form_body::form_root_42::upgrade (cyclomatic 28) crates/ibcmd-form-body/src/form_root_42.rs:544 — ibcmd_form_body::form_root_42::upgrade has cyclomatic complexity 28 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
  • ibcmd_form_body::form_body::form_command_interface_command_named (cyclomatic 27) crates/ibcmd-form-body/src/form_body.rs:31094 — ibcmd_form_body::form_body::form_command_interface_command_named 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. This is NOT this file's highest cyclomatic complexity: ibcmd_form_body::form_body::form_event_name_from_identifier (cyclomatic 112) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • ibcmd_form_body::form_body::form_gantt_chart_series_like_xml (cyclomatic 27) crates/ibcmd-form-body/src/form_body.rs:39482 — ibcmd_form_body::form_body::form_gantt_chart_series_like_xml has cyclomatic complexity 27 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages. This is NOT this file's highest cyclomatic complexity: ibcmd_form_body::form_body::form_event_name_from_identifier (cyclomatic 112) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • ibcmd_form_body::dcs::canonicalize_form_server_state_conditional_appearances (cyclomatic 22) crates/ibcmd-form-body/src/dcs.rs:1405 — ibcmd_form_body::dcs::canonicalize_form_server_state_conditional_appearances 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.
  • ibcmd_form_body::form_body::apply_form_attribute_scoped_use_always_bindings (cyclomatic 22) crates/ibcmd-form-body/src/form_body.rs:5536 — ibcmd_form_body::form_body::apply_form_attribute_scoped_use_always_bindings 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's highest cyclomatic complexity: ibcmd_form_body::form_body::form_event_name_from_identifier (cyclomatic 112) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • ibcmd_form_body::form_body::parse_form_attribute_direct_use_always (cyclomatic 22) crates/ibcmd-form-body/src/form_body.rs:6700 — ibcmd_form_body::form_body::parse_form_attribute_direct_use_always 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's highest cyclomatic complexity: ibcmd_form_body::form_body::form_event_name_from_identifier (cyclomatic 112) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • ibcmd_form_body::form_body::form_dynamic_list_use_always_universe (cyclomatic 22) crates/ibcmd-form-body/src/form_body.rs:7480 — ibcmd_form_body::form_body::form_dynamic_list_use_always_universe 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's highest cyclomatic complexity: ibcmd_form_body::form_body::form_event_name_from_identifier (cyclomatic 112) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • ibcmd_form_body::form_body::collect_form_child_item_indexes_with_object_refs (cyclomatic 22) crates/ibcmd-form-body/src/form_body.rs:11875 — ibcmd_form_body::form_body::collect_form_child_item_indexes_with_object_refs 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's highest cyclomatic complexity: ibcmd_form_body::form_body::form_event_name_from_identifier (cyclomatic 112) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • ibcmd_form_body::form_body::parse_form_schema_backed_event_record (cyclomatic 22) crates/ibcmd-form-body/src/form_body.rs:23549 — ibcmd_form_body::form_body::parse_form_schema_backed_event_record 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's highest cyclomatic complexity: ibcmd_form_body::form_body::form_event_name_from_identifier (cyclomatic 112) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • + 17 more in this group — see findings.md.
D4 · Code Duplication · Duplicated block (12 lines × 2) · ×42
  • Duplicated block (12 lines × 2) crates/ibcmd-1c-text/src/braced.rs:89 — crates/ibcmd-1c-text/src/braced.rs:89-100 | crates/ibcmd-1c-text/src/braced.rs:455-466 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-1c-text/src/braced.rs:89` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (12 lines × 2) crates/ibcmd-compiler-families/src/compiler/families/services.rs:1287 — crates/ibcmd-compiler-families/src/compiler/families/services.rs:1287-1298 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:1057-1068 — before extracting anything, compare `crates/ibcmd-compiler-families/src/compiler/families/services.rs` and `crates/ibcmd-compiler-families/src/compiler/families/simple.rs` as WHOLE FILES: this scan already matched 36 separate duplicated blocks between them, totalling at least 406 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/services.rs:1287` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (12 lines × 2) crates/ibcmd-compiler-families/src/compiler/families/services.rs:3162 — crates/ibcmd-compiler-families/src/compiler/families/services.rs:3162-3173 | crates/ibcmd-compiler-families/src/compiler/families/services.rs:3180-3191 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (12 lines × 2) crates/ibcmd-compiler/src/compiler/bootstrap.rs:352 — crates/ibcmd-compiler/src/compiler/bootstrap.rs:352-363 | crates/ibcmd-compiler/src/compiler/bootstrap.rs:756-767 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (12 lines × 2) REDACTED:1282 — REDACTED:1282-1293 | REDACTED:1397-1408 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `REDACTED:1282` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (12 lines × 2) crates/ibcmd-dump/src/mssql_dump/forms.rs:136 — crates/ibcmd-dump/src/mssql_dump/forms.rs:136-147 | crates/ibcmd-dump/src/mssql_dump/mod.rs:33414-33425 — before extracting anything, compare `crates/ibcmd-dump/src/mssql_dump/forms.rs` and `crates/ibcmd-dump/src/mssql_dump/mod.rs` as WHOLE FILES: this scan already matched 6 separate duplicated blocks between them, totalling at least 99 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/forms.rs:136` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (12 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:5165 — crates/ibcmd-dump/src/mssql_dump/mod.rs:5165-5176 | crates/ibcmd-dump/src/mssql_dump/mod.rs:5228-5239 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, `crates/ibcmd-dump/src/mssql_dump/mod.rs:5163` calls `form_metadata_file_names`, `extend`, `iter` and `crates/ibcmd-dump/src/mssql_dump/mod.rs:5227` does not — after which the two agree again for 3 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
  • Duplicated block (12 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:10476 — crates/ibcmd-dump/src/mssql_dump/mod.rs:10476-10487 | crates/ibcmd-dump/src/mssql_dump/mod.rs:10514-10525 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:10476` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (12 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:25373 — crates/ibcmd-dump/src/mssql_dump/mod.rs:25373-25404 | crates/ibcmd-dump/src/mssql_dump/mod.rs:25782-25793 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:25373` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
  • Duplicated block (12 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:27042 — crates/ibcmd-dump/src/mssql_dump/mod.rs:27042-27053 | crates/ibcmd-dump/src/mssql_dump/mod.rs:30999-31010 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:27042` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (12 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:28647 — crates/ibcmd-dump/src/mssql_dump/mod.rs:28647-28658 | crates/ibcmd-dump/src/mssql_dump/mod.rs:31445-31456 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:28647` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (12 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:32858 — crates/ibcmd-dump/src/mssql_dump/mod.rs:32858-32869 | crates/ibcmd-dump/src/mssql_dump/mod.rs:32953-32964 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:32858` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (12 lines × 2) crates/ibcmd-dump/src/mssql_dump/refs.rs:1620 — crates/ibcmd-dump/src/mssql_dump/refs.rs:1620-1631 | crates/ibcmd-dump/src/mssql_dump/refs.rs:1816-1827 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/refs.rs:1620` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (12 lines × 2) crates/ibcmd-form-body/src/form_body.rs:22776 — crates/ibcmd-form-body/src/form_body.rs:22776-22787 | crates/ibcmd-form-body/src/form_body.rs:22821-22832 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-form-body/src/form_body.rs:22776` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (12 lines × 2) crates/ibcmd-form-body/src/form_body.rs:23060 — crates/ibcmd-form-body/src/form_body.rs:23060-23071 | crates/ibcmd-form-body/src/form_body.rs:23091-23102 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (12 lines × 2) crates/ibcmd-form-writer/src/lib.rs:20062 — crates/ibcmd-form-writer/src/lib.rs:20062-20073 | crates/ibcmd-form-writer/src/lib.rs:20221-20232 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-form-writer/src/lib.rs:20062` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (12 lines × 2) crates/ibcmd-metadata-blob/src/lib.rs:2329 — crates/ibcmd-metadata-blob/src/lib.rs:2329-2340 | crates/ibcmd-metadata-blob/src/lib.rs:3300-3311 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-metadata-blob/src/lib.rs:2329` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (12 lines × 2) crates/ibcmd-metadata-model/src/metadata_model/audit.rs:159 — crates/ibcmd-metadata-model/src/metadata_model/audit.rs:159-170 | crates/ibcmd-metadata-model/src/metadata_model/export_audit.rs:209-220 — before extracting anything, compare `crates/ibcmd-metadata-model/src/metadata_model/audit.rs` and `crates/ibcmd-metadata-model/src/metadata_model/export_audit.rs` as WHOLE FILES: this scan already matched 4 separate duplicated blocks between them, totalling at least 35 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place.
  • Duplicated block (12 lines × 2) crates/ibcmd-metadata-model/src/metadata_model/registers.rs:595 — crates/ibcmd-metadata-model/src/metadata_model/registers.rs:595-606 | crates/ibcmd-metadata-model/src/metadata_model/registers.rs:753-764 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (12 lines × 2) crates/ibcmd-xml/src/dcs.rs:6339 — crates/ibcmd-xml/src/dcs.rs:6339-6350 | crates/ibcmd-xml/src/dcs.rs:6357-6368 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-xml/src/dcs.rs:6339` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (12 lines × 2) crates/ibcmd-xml/src/dcs_schema.rs:2112 — crates/ibcmd-xml/src/dcs_schema.rs:2112-2123 | crates/ibcmd-xml/src/dcs_schema.rs:2251-2262 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (12 lines × 2) crates/ibcmd-xml/src/dcs_schema.rs:3685 — crates/ibcmd-xml/src/dcs_schema.rs:3685-3696 | REDACTED:665-676 — before extracting anything, compare `crates/ibcmd-xml/src/dcs_schema.rs` and `REDACTED` as WHOLE FILES: this scan already matched 4 separate duplicated blocks between them, totalling at least 39 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. 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 `return` inside it is the body's own exit and keeps its meaning in the moved unit.
  • Duplicated block (12 lines × 2) crates/ibcmd-xml/src/dcs_template.rs:407 — crates/ibcmd-xml/src/dcs_template.rs:407-418 | crates/ibcmd-xml/src/dcs_template.rs:842-853 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-xml/src/dcs_template.rs:407` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (12 lines × 2) src/form_provenance.rs:612 — src/form_provenance.rs:612-623 | src/form_provenance.rs:627-638 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `src/form_provenance.rs:612` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, `src/form_provenance.rs:624` calls `Some` and `src/form_provenance.rs:609` does not — after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
  • Duplicated block (12 lines × 2) src/load/compiled.rs:452 — src/load/compiled.rs:452-463 | src/mssql_extension_tree_load.rs:679-690 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at `src/load/compiled.rs:452` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • + 17 more in this group — see findings.md.
X25 · Inert configuration knob · Configuration option is read nowhere · ×40
  • Configuration option is read nowhere crates/ibcmd-dump/src/mssql_dump/incremental.rs:157 — `IncrementalExportSummary.changed_entries` is offered as a configuration-file option, so whoever configures the program can set it — but no production code reads it. Every value supplied for it is silently ignored. Consult it where it was meant to take effect — or, if it genuinely does nothing, remove it (or mark it deprecated and say so in its documentation) so the configuration stops advertising a setting that changes nothing.
  • Configuration option is read nowhere crates/ibcmd-dump/src/mssql_dump/incremental.rs:159 — `IncrementalExportSummary.unchanged_entries` is offered as a configuration-file option, so whoever configures the program can set it — but no production code reads it. Every value supplied for it is silently ignored. Consult it where it was meant to take effect — or, if it genuinely does nothing, remove it (or mark it deprecated and say so in its documentation) so the configuration stops advertising a setting that changes nothing.
  • Configuration option is read nowhere crates/ibcmd-dump/src/mssql_dump/incremental.rs:161 — `IncrementalExportSummary.removed_entries` is offered as a configuration-file option, so whoever configures the program can set it — but no production code reads it. Every value supplied for it is silently ignored. Consult it where it was meant to take effect — or, if it genuinely does nothing, remove it (or mark it deprecated and say so in its documentation) so the configuration stops advertising a setting that changes nothing.
  • Configuration option is read nowhere crates/ibcmd-dump/src/mssql_dump/incremental.rs:163 — `IncrementalExportSummary.written_files` is offered as a configuration-file option, so whoever configures the program can set it — but no production code reads it. Every value supplied for it is silently ignored. Consult it where it was meant to take effect — or, if it genuinely does nothing, remove it (or mark it deprecated and say so in its documentation) so the configuration stops advertising a setting that changes nothing.
  • Configuration option is read nowhere crates/ibcmd-dump/src/mssql_dump/mod.rs:1457 — `SourceAssetCompletenessReport.diagnostic_clusters` is offered as a configuration-file option, so whoever configures the program can set it — but no production code reads it. A test asserts that it parses, which proves the key is read from the input, not that it does anything. Every value supplied for it is silently ignored. Consult it where it was meant to take effect — or, if it genuinely does nothing, remove it (or mark it deprecated and say so in its documentation) so the configuration stops advertising a setting that changes nothing.
  • Configuration option is read nowhere crates/ibcmd-dump/src/mssql_dump/mod.rs:1771 — `RootMetadataInventoryReport.misses_by_reason` is offered as a configuration-file option, so whoever configures the program can set it — but no production code reads it. Every value supplied for it is silently ignored. Consult it where it was meant to take effect — or, if it genuinely does nothing, remove it (or mark it deprecated and say so in its documentation) so the configuration stops advertising a setting that changes nothing.
  • Configuration option is read nowhere crates/ibcmd-dump/src/mssql_dump/source_asset_diagnostics.rs:12 — `SourceAssetDiagnosticClusterReport.total_clusters` is offered as a configuration-file option, so whoever configures the program can set it — but no production code reads it. A test asserts that it parses, which proves the key is read from the input, not that it does anything. Every value supplied for it is silently ignored. Consult it where it was meant to take effect — or, if it genuinely does nothing, remove it (or mark it deprecated and say so in its documentation) so the configuration stops advertising a setting that changes nothing.
  • Configuration option is read nowhere crates/ibcmd-dump/src/mssql_dump/source_asset_diagnostics.rs:13 — `SourceAssetDiagnosticClusterReport.omitted_clusters` is offered as a configuration-file option, so whoever configures the program can set it — but no production code reads it. A test asserts that it parses, which proves the key is read from the input, not that it does anything. Every value supplied for it is silently ignored. Consult it where it was meant to take effect — or, if it genuinely does nothing, remove it (or mark it deprecated and say so in its documentation) so the configuration stops advertising a setting that changes nothing.
  • Configuration option is read nowhere crates/ibcmd-dump/src/mssql_dump/source_asset_diagnostics.rs:14 — `SourceAssetDiagnosticClusterReport.omitted_entries` is offered as a configuration-file option, so whoever configures the program can set it — but no production code reads it. A test asserts that it parses, which proves the key is read from the input, not that it does anything. Every value supplied for it is silently ignored. Consult it where it was meant to take effect — or, if it genuinely does nothing, remove it (or mark it deprecated and say so in its documentation) so the configuration stops advertising a setting that changes nothing.
  • Configuration option is read nowhere crates/ibcmd-dump/src/mssql_dump/source_asset_diagnostics.rs:15 — `SourceAssetDiagnosticClusterReport.clusters` is offered as a configuration-file option, so whoever configures the program can set it — but no production code reads it. A test asserts that it parses, which proves the key is read from the input, not that it does anything. Every value supplied for it is silently ignored. Consult it where it was meant to take effect — or, if it genuinely does nothing, remove it (or mark it deprecated and say so in its documentation) so the configuration stops advertising a setting that changes nothing.
  • Configuration option is read nowhere crates/ibcmd-schema/src/lib.rs:7121 — `DcsSchemaTemplateEnvelopeEvidenceFixture.extractor_identity` is offered as a configuration-file option, so whoever configures the program can set it — but no production code reads it. Every value supplied for it is silently ignored. Consult it where it was meant to take effect — or, if it genuinely does nothing, remove it (or mark it deprecated and say so in its documentation) so the configuration stops advertising a setting that changes nothing.
  • Configuration option is read nowhere crates/ibcmd-schema/src/lib.rs:7122 — `DcsSchemaTemplateEnvelopeEvidenceFixture.extractor_sha256` is offered as a configuration-file option, so whoever configures the program can set it — but no production code reads it. Every value supplied for it is silently ignored. Consult it where it was meant to take effect — or, if it genuinely does nothing, remove it (or mark it deprecated and say so in its documentation) so the configuration stops advertising a setting that changes nothing.
  • Configuration option is read nowhere crates/ibcmd-schema/src/lib.rs:7123 — `DcsSchemaTemplateEnvelopeEvidenceFixture.seed_sha256` is offered as a configuration-file option, so whoever configures the program can set it — but no production code reads it. Every value supplied for it is silently ignored. Consult it where it was meant to take effect — or, if it genuinely does nothing, remove it (or mark it deprecated and say so in its documentation) so the configuration stops advertising a setting that changes nothing.
  • Configuration option is read nowhere crates/ibcmd-schema/src/lib.rs:7124 — `DcsSchemaTemplateEnvelopeEvidenceFixture.round1_cf_sha256` is offered as a configuration-file option, so whoever configures the program can set it — but no production code reads it. Every value supplied for it is silently ignored. Consult it where it was meant to take effect — or, if it genuinely does nothing, remove it (or mark it deprecated and say so in its documentation) so the configuration stops advertising a setting that changes nothing.
  • Configuration option is read nowhere crates/ibcmd-schema/src/lib.rs:7125 — `DcsSchemaTemplateEnvelopeEvidenceFixture.round2_cf_sha256` is offered as a configuration-file option, so whoever configures the program can set it — but no production code reads it. Every value supplied for it is silently ignored. Consult it where it was meant to take effect — or, if it genuinely does nothing, remove it (or mark it deprecated and say so in its documentation) so the configuration stops advertising a setting that changes nothing.
  • Configuration option is read nowhere crates/ibcmd-schema/src/lib.rs:7126 — `DcsSchemaTemplateEnvelopeEvidenceFixture.round1_template_sha256` is offered as a configuration-file option, so whoever configures the program can set it — but no production code reads it. Every value supplied for it is silently ignored. Consult it where it was meant to take effect — or, if it genuinely does nothing, remove it (or mark it deprecated and say so in its documentation) so the configuration stops advertising a setting that changes nothing.
  • Configuration option is read nowhere crates/ibcmd-schema/src/lib.rs:7127 — `DcsSchemaTemplateEnvelopeEvidenceFixture.round2_template_sha256` is offered as a configuration-file option, so whoever configures the program can set it — but no production code reads it. Every value supplied for it is silently ignored. Consult it where it was meant to take effect — or, if it genuinely does nothing, remove it (or mark it deprecated and say so in its documentation) so the configuration stops advertising a setting that changes nothing.
  • Configuration option is read nowhere crates/ibcmd-schema/src/lib.rs:7128 — `DcsSchemaTemplateEnvelopeEvidenceFixture.round1_packed_sha256` is offered as a configuration-file option, so whoever configures the program can set it — but no production code reads it. Every value supplied for it is silently ignored. Consult it where it was meant to take effect — or, if it genuinely does nothing, remove it (or mark it deprecated and say so in its documentation) so the configuration stops advertising a setting that changes nothing.
  • Configuration option is read nowhere crates/ibcmd-schema/src/lib.rs:7129 — `DcsSchemaTemplateEnvelopeEvidenceFixture.round2_packed_sha256` is offered as a configuration-file option, so whoever configures the program can set it — but no production code reads it. Every value supplied for it is silently ignored. Consult it where it was meant to take effect — or, if it genuinely does nothing, remove it (or mark it deprecated and say so in its documentation) so the configuration stops advertising a setting that changes nothing.
  • Configuration option is read nowhere crates/ibcmd-schema/src/lib.rs:7130 — `DcsSchemaTemplateEnvelopeEvidenceFixture.round1_unpacked_sha256` is offered as a configuration-file option, so whoever configures the program can set it — but no production code reads it. Every value supplied for it is silently ignored. Consult it where it was meant to take effect — or, if it genuinely does nothing, remove it (or mark it deprecated and say so in its documentation) so the configuration stops advertising a setting that changes nothing.
  • Configuration option is read nowhere crates/ibcmd-schema/src/lib.rs:7131 — `DcsSchemaTemplateEnvelopeEvidenceFixture.round2_unpacked_sha256` is offered as a configuration-file option, so whoever configures the program can set it — but no production code reads it. Every value supplied for it is silently ignored. Consult it where it was meant to take effect — or, if it genuinely does nothing, remove it (or mark it deprecated and say so in its documentation) so the configuration stops advertising a setting that changes nothing.
  • Configuration option is read nowhere crates/ibcmd-schema/src/lib.rs:7132 — `DcsSchemaTemplateEnvelopeEvidenceFixture.configuration_encoded_sha256` is offered as a configuration-file option, so whoever configures the program can set it — but no production code reads it. Every value supplied for it is silently ignored. Consult it where it was meant to take effect — or, if it genuinely does nothing, remove it (or mark it deprecated and say so in its documentation) so the configuration stops advertising a setting that changes nothing.
  • Configuration option is read nowhere crates/ibcmd-schema/src/lib.rs:7133 — `DcsSchemaTemplateEnvelopeEvidenceFixture.configuration_decoded_sha256` is offered as a configuration-file option, so whoever configures the program can set it — but no production code reads it. Every value supplied for it is silently ignored. Consult it where it was meant to take effect — or, if it genuinely does nothing, remove it (or mark it deprecated and say so in its documentation) so the configuration stops advertising a setting that changes nothing.
  • Configuration option is read nowhere crates/ibcmd-schema/src/lib.rs:7134 — `DcsSchemaTemplateEnvelopeEvidenceFixture.raw_packed_encoded_sha256` is offered as a configuration-file option, so whoever configures the program can set it — but no production code reads it. Every value supplied for it is silently ignored. Consult it where it was meant to take effect — or, if it genuinely does nothing, remove it (or mark it deprecated and say so in its documentation) so the configuration stops advertising a setting that changes nothing.
  • Configuration option is read nowhere crates/ibcmd-schema/src/lib.rs:7135 — `DcsSchemaTemplateEnvelopeEvidenceFixture.raw_packed_decoded_sha256` is offered as a configuration-file option, so whoever configures the program can set it — but no production code reads it. Every value supplied for it is silently ignored. Consult it where it was meant to take effect — or, if it genuinely does nothing, remove it (or mark it deprecated and say so in its documentation) so the configuration stops advertising a setting that changes nothing.
  • + 15 more in this group — see findings.md.
X5 · Nullable reference types · Symbol treated as nullable, then dereferenced unguarded · ×40
  • Symbol treated as nullable, then dereferenced unguarded xtask/src/main.rs:110 — `Path::new(env!("CARGO_MANIFEST_DIR")).parent()` can be absent — it is an `Option` or `Result`, which is why it is forced — and `.expect()` in `repository_root` forces it with nothing on this path excluding `None`/`Err`: no `if let` or `match` arm that matched it present, no `let … else`, no `is_some()`/`is_ok()` test (or `is_none()`/`is_err()` test that leaves), no `assert!` of it, and for a lookup no proof the key or index exists. This line panics the first time the value is not there. Handle the absent case where it arises: propagate it with `?`, branch on it with `if let` / `match` / `let … else`, or give it a default (`unwrap_or`, `unwrap_or_default`, `unwrap_or_else`).
  • Symbol treated as nullable, then dereferenced unguarded src/conversion.rs:230 — `self.phases.iter_mut().find(|entry|entry.phase==phase)` can be absent — it is an `Option` or `Result`, which is why it is forced — and `.expect()` in `mark` forces it with nothing on this path excluding `None`/`Err`: no `if let` or `match` arm that matched it present, no `let … else`, no `is_some()`/`is_ok()` test (or `is_none()`/`is_err()` test that leaves), no `assert!` of it, and for a lookup no proof the key or index exists. This line panics the first time the value is not there. Handle the absent case where it arises: propagate it with `?`, branch on it with `if let` / `match` / `let … else`, or give it a default (`unwrap_or`, `unwrap_or_default`, `unwrap_or_else`).
  • Symbol treated as nullable, then dereferenced unguarded src/conversion.rs:506 — `PathSegment::name("source")` can be absent — it is an `Option` or `Result`, which is why it is forced — and `.expect()` in `decode_xml_tree` forces it with nothing on this path excluding `None`/`Err`: no `if let` or `match` arm that matched it present, no `let … else`, no `is_some()`/`is_ok()` test (or `is_none()`/`is_err()` test that leaves), no `assert!` of it, and for a lookup no proof the key or index exists. This line panics the first time the value is not there. Handle the absent case where it arises: propagate it with `?`, branch on it with `if let` / `match` / `let … else`, or give it a default (`unwrap_or`, `unwrap_or_default`, `unwrap_or_else`).
  • Symbol treated as nullable, then dereferenced unguarded src/conversion.rs:509 — `ObjectPath::new(vec![PathSegment::name("source").expect("static object path is valid"),PathSegment::index(index),])` can be absent — it is an `Option` or `Result`, which is why it is forced — and `.expect()` in `decode_xml_tree` forces it with nothing on this path excluding `None`/`Err`: no `if let` or `match` arm that matched it present, no `let … else`, no `is_some()`/`is_ok()` test (or `is_none()`/`is_err()` test that leaves), no `assert!` of it, and for a lookup no proof the key or index exists. This line panics the first time the value is not there. Handle the absent case where it arises: propagate it with `?`, branch on it with `if let` / `match` / `let … else`, or give it a default (`unwrap_or`, `unwrap_or_default`, `unwrap_or_else`).
  • Symbol treated as nullable, then dereferenced unguarded src/conversion.rs:883 — `source_profile.xml_dialect.as_ref()` can be absent — it is an `Option` or `Result`, which is why it is forced — and `.expect()` in `convert_xml_to_cf` forces it with nothing on this path excluding `None`/`Err`: no `if let` or `match` arm that matched it present, no `let … else`, no `is_some()`/`is_ok()` test (or `is_none()`/`is_err()` test that leaves), no `assert!` of it, and for a lookup no proof the key or index exists. This line panics the first time the value is not there. Handle the absent case where it arises: propagate it with `?`, branch on it with `if let` / `match` / `let … else`, or give it a default (`unwrap_or`, `unwrap_or_default`, `unwrap_or_else`).
  • Symbol treated as nullable, then dereferenced unguarded src/conversion.rs:907 — `target_profile.storage_profile.as_ref()` can be absent — it is an `Option` or `Result`, which is why it is forced — and `.expect()` in `convert_xml_to_cf` forces it with nothing on this path excluding `None`/`Err`: no `if let` or `match` arm that matched it present, no `let … else`, no `is_some()`/`is_ok()` test (or `is_none()`/`is_err()` test that leaves), no `assert!` of it, and for a lookup no proof the key or index exists. This line panics the first time the value is not there. Handle the absent case where it arises: propagate it with `?`, branch on it with `if let` / `match` / `let … else`, or give it a default (`unwrap_or`, `unwrap_or_default`, `unwrap_or_else`).
  • Symbol treated as nullable, then dereferenced unguarded src/conversion.rs:1373 — `source_profile.storage_profile.as_ref()` can be absent — it is an `Option` or `Result`, which is why it is forced — and `.expect()` in `decode_cf` forces it with nothing on this path excluding `None`/`Err`: no `if let` or `match` arm that matched it present, no `let … else`, no `is_some()`/`is_ok()` test (or `is_none()`/`is_err()` test that leaves), no `assert!` of it, and for a lookup no proof the key or index exists. This line panics the first time the value is not there. Handle the absent case where it arises: propagate it with `?`, branch on it with `if let` / `match` / `let … else`, or give it a default (`unwrap_or`, `unwrap_or_default`, `unwrap_or_else`).
  • Symbol treated as nullable, then dereferenced unguarded src/conversion.rs:1379 — `StorageProvenance::new("offline conversion service")` can be absent — it is an `Option` or `Result`, which is why it is forced — and `.expect()` in `decode_cf` forces it with nothing on this path excluding `None`/`Err`: no `if let` or `match` arm that matched it present, no `let … else`, no `is_some()`/`is_ok()` test (or `is_none()`/`is_err()` test that leaves), no `assert!` of it, and for a lookup no proof the key or index exists. This line panics the first time the value is not there. Handle the absent case where it arises: propagate it with `?`, branch on it with `if let` / `match` / `let … else`, or give it a default (`unwrap_or`, `unwrap_or_default`, `unwrap_or_else`).
  • Symbol treated as nullable, then dereferenced unguarded src/dcs_template_audit.rs:109 — `ProfileId::parse("provider:mssql-legacy")` can be absent — it is an `Option` or `Result`, which is why it is forced — and `.expect()` in `audit_dcs_template_writer` forces it with nothing on this path excluding `None`/`Err`: no `if let` or `match` arm that matched it present, no `let … else`, no `is_some()`/`is_ok()` test (or `is_none()`/`is_err()` test that leaves), no `assert!` of it, and for a lookup no proof the key or index exists. This line panics the first time the value is not there. Handle the absent case where it arises: propagate it with `?`, branch on it with `if let` / `match` / `let … else`, or give it a default (`unwrap_or`, `unwrap_or_default`, `unwrap_or_else`).
  • Symbol treated as nullable, then dereferenced unguarded src/dcs_template_audit.rs:110 — `ProfileId::parse("xml-2.20")` can be absent — it is an `Option` or `Result`, which is why it is forced — and `.expect()` in `audit_dcs_template_writer` forces it with nothing on this path excluding `None`/`Err`: no `if let` or `match` arm that matched it present, no `let … else`, no `is_some()`/`is_ok()` test (or `is_none()`/`is_err()` test that leaves), no `assert!` of it, and for a lookup no proof the key or index exists. This line panics the first time the value is not there. Handle the absent case where it arises: propagate it with `?`, branch on it with `if let` / `match` / `let … else`, or give it a default (`unwrap_or`, `unwrap_or_default`, `unwrap_or_else`).
  • Symbol treated as nullable, then dereferenced unguarded src/dcs_template_audit.rs:299 — `bytes.try_into()` can be absent — it is an `Option` or `Result`, which is why it is forced — and `.expect()` in `split_documents` forces it with nothing on this path excluding `None`/`Err`: no `if let` or `match` arm that matched it present, no `let … else`, no `is_some()`/`is_ok()` test (or `is_none()`/`is_err()` test that leaves), no `assert!` of it, and for a lookup no proof the key or index exists. This line panics the first time the value is not there. Handle the absent case where it arises: propagate it with `?`, branch on it with `if let` / `match` / `let … else`, or give it a default (`unwrap_or`, `unwrap_or_default`, `unwrap_or_else`).
  • Symbol treated as nullable, then dereferenced unguarded src/dcs_template_audit.rs:304 — `bytes.try_into()` can be absent — it is an `Option` or `Result`, which is why it is forced — and `.expect()` in `split_documents` forces it with nothing on this path excluding `None`/`Err`: no `if let` or `match` arm that matched it present, no `let … else`, no `is_some()`/`is_ok()` test (or `is_none()`/`is_err()` test that leaves), no `assert!` of it, and for a lookup no proof the key or index exists. This line panics the first time the value is not there. Handle the absent case where it arises: propagate it with `?`, branch on it with `if let` / `match` / `let … else`, or give it a default (`unwrap_or`, `unwrap_or_default`, `unwrap_or_else`).
  • Symbol treated as nullable, then dereferenced unguarded src/infobase.rs:894 — `self.loaded.as_ref()` can be absent — it is an `Option` or `Result`, which is why it is forced — and `.expect()` in `get` forces it with nothing on this path excluding `None`/`Err`: no `if let` or `match` arm that matched it present, no `let … else`, no `is_some()`/`is_ok()` test (or `is_none()`/`is_err()` test that leaves), no `assert!` of it, and for a lookup no proof the key or index exists. This line panics the first time the value is not there. Handle the absent case where it arises: propagate it with `?`, branch on it with `if let` / `match` / `let … else`, or give it a default (`unwrap_or`, `unwrap_or_default`, `unwrap_or_else`).
  • Symbol treated as nullable, then dereferenced unguarded src/load.rs:74 — `entry.path().strip_prefix(root)` can be absent — it is an `Option` or `Result`, which is why it is forced — and `.expect()` in `relative_files` forces it with nothing on this path excluding `None`/`Err`: no `if let` or `match` arm that matched it present, no `let … else`, no `is_some()`/`is_ok()` test (or `is_none()`/`is_err()` test that leaves), no `assert!` of it, and for a lookup no proof the key or index exists. This line panics the first time the value is not there. Handle the absent case where it arises: propagate it with `?`, branch on it with `if let` / `match` / `let … else`, or give it a default (`unwrap_or`, `unwrap_or_default`, `unwrap_or_else`).
  • Symbol treated as nullable, then dereferenced unguarded src/load.rs:372 — `StorageProfileId::parse("storage:cf-cli")` can be absent — it is an `Option` or `Result`, which is why it is forced — and `.expect()` in `export_base` forces it with nothing on this path excluding `None`/`Err`: no `if let` or `match` arm that matched it present, no `let … else`, no `is_some()`/`is_ok()` test (or `is_none()`/`is_err()` test that leaves), no `assert!` of it, and for a lookup no proof the key or index exists. This line panics the first time the value is not there. Handle the absent case where it arises: propagate it with `?`, branch on it with `if let` / `match` / `let … else`, or give it a default (`unwrap_or`, `unwrap_or_default`, `unwrap_or_else`).
  • Symbol treated as nullable, then dereferenced unguarded src/load.rs:758 — `StorageProfileId::parse(OVERLAY_PROFILE)` can be absent — it is an `Option` or `Result`, which is why it is forced — and `.expect()` in `load_plan` forces it with nothing on this path excluding `None`/`Err`: no `if let` or `match` arm that matched it present, no `let … else`, no `is_some()`/`is_ok()` test (or `is_none()`/`is_err()` test that leaves), no `assert!` of it, and for a lookup no proof the key or index exists. This line panics the first time the value is not there. Handle the absent case where it arises: propagate it with `?`, branch on it with `if let` / `match` / `let … else`, or give it a default (`unwrap_or`, `unwrap_or_default`, `unwrap_or_else`).
  • Symbol treated as nullable, then dereferenced unguarded src/load.rs:773 — `StorageProfileId::parse(OVERLAY_PROFILE)` can be absent — it is an `Option` or `Result`, which is why it is forced — and `.expect()` in `load_plan` forces it with nothing on this path excluding `None`/`Err`: no `if let` or `match` arm that matched it present, no `let … else`, no `is_some()`/`is_ok()` test (or `is_none()`/`is_err()` test that leaves), no `assert!` of it, and for a lookup no proof the key or index exists. This line panics the first time the value is not there. Handle the absent case where it arises: propagate it with `?`, branch on it with `if let` / `match` / `let … else`, or give it a default (`unwrap_or`, `unwrap_or_default`, `unwrap_or_else`).
  • Symbol treated as nullable, then dereferenced unguarded src/load.rs:774 — `StorageProvenance::new("cf load base")` can be absent — it is an `Option` or `Result`, which is why it is forced — and `.expect()` in `load_plan` forces it with nothing on this path excluding `None`/`Err`: no `if let` or `match` arm that matched it present, no `let … else`, no `is_some()`/`is_ok()` test (or `is_none()`/`is_err()` test that leaves), no `assert!` of it, and for a lookup no proof the key or index exists. This line panics the first time the value is not there. Handle the absent case where it arises: propagate it with `?`, branch on it with `if let` / `match` / `let … else`, or give it a default (`unwrap_or`, `unwrap_or_default`, `unwrap_or_else`).
  • Symbol treated as nullable, then dereferenced unguarded src/load.rs:861 — `StorageProfileId::parse(OVERLAY_PROFILE)` can be absent — it is an `Option` or `Result`, which is why it is forced — and `.expect()` in `refresh_configinfo` forces it with nothing on this path excluding `None`/`Err`: no `if let` or `match` arm that matched it present, no `let … else`, no `is_some()`/`is_ok()` test (or `is_none()`/`is_err()` test that leaves), no `assert!` of it, and for a lookup no proof the key or index exists. This line panics the first time the value is not there. Handle the absent case where it arises: propagate it with `?`, branch on it with `if let` / `match` / `let … else`, or give it a default (`unwrap_or`, `unwrap_or_default`, `unwrap_or_else`).
  • Symbol treated as nullable, then dereferenced unguarded src/load.rs:862 — `StorageProvenance::new("cf load staged")` can be absent — it is an `Option` or `Result`, which is why it is forced — and `.expect()` in `refresh_configinfo` forces it with nothing on this path excluding `None`/`Err`: no `if let` or `match` arm that matched it present, no `let … else`, no `is_some()`/`is_ok()` test (or `is_none()`/`is_err()` test that leaves), no `assert!` of it, and for a lookup no proof the key or index exists. This line panics the first time the value is not there. Handle the absent case where it arises: propagate it with `?`, branch on it with `if let` / `match` / `let … else`, or give it a default (`unwrap_or`, `unwrap_or_default`, `unwrap_or_else`).
  • Symbol treated as nullable, then dereferenced unguarded src/load.rs:916 — `text.find(&marker)` can be absent — it is an `Option` or `Result`, which is why it is forced — and `.expect()` in `with_configinfo_digests` forces it with nothing on this path excluding `None`/`Err`: no `if let` or `match` arm that matched it present, no `let … else`, no `is_some()`/`is_ok()` test (or `is_none()`/`is_err()` test that leaves), no `assert!` of it, and for a lookup no proof the key or index exists. This line panics the first time the value is not there. Handle the absent case where it arises: propagate it with `?`, branch on it with `if let` / `match` / `let … else`, or give it a default (`unwrap_or`, `unwrap_or_default`, `unwrap_or_else`).
  • Symbol treated as nullable, then dereferenced unguarded src/mcp.rs:158 — `settings_path.parent()` can be absent — it is an `Option` or `Result`, which is why it is forced — and `.unwrap()` in `open` forces it with nothing on this path excluding `None`/`Err`: no `if let` or `match` arm that matched it present, no `let … else`, no `is_some()`/`is_ok()` test (or `is_none()`/`is_err()` test that leaves), no `assert!` of it, and for a lookup no proof the key or index exists. This line panics the first time the value is not there. Handle the absent case where it arises: propagate it with `?`, branch on it with `if let` / `match` / `let … else`, or give it a default (`unwrap_or`, `unwrap_or_default`, `unwrap_or_else`).
  • Symbol treated as nullable, then dereferenced unguarded src/mcp.rs:176 — `policy_path.parent()` can be absent — it is an `Option` or `Result`, which is why it is forced — and `.unwrap()` in `open` forces it with nothing on this path excluding `None`/`Err`: no `if let` or `match` arm that matched it present, no `let … else`, no `is_some()`/`is_ok()` test (or `is_none()`/`is_err()` test that leaves), no `assert!` of it, and for a lookup no proof the key or index exists. This line panics the first time the value is not there. Handle the absent case where it arises: propagate it with `?`, branch on it with `if let` / `match` / `let … else`, or give it a default (`unwrap_or`, `unwrap_or_default`, `unwrap_or_else`).
  • Symbol treated as nullable, then dereferenced unguarded src/mcp.rs:373 — `self.file_path.as_ref()` can be absent — it is an `Option` or `Result`, which is why it is forced — and `.unwrap()` in `prepare_import` forces it with nothing on this path excluding `None`/`Err`: no `if let` or `match` arm that matched it present, no `let … else`, no `is_some()`/`is_ok()` test (or `is_none()`/`is_err()` test that leaves), no `assert!` of it, and for a lookup no proof the key or index exists. This line panics the first time the value is not there. Handle the absent case where it arises: propagate it with `?`, branch on it with `if let` / `match` / `let … else`, or give it a default (`unwrap_or`, `unwrap_or_default`, `unwrap_or_else`).
  • Symbol treated as nullable, then dereferenced unguarded src/mcp.rs:900 — `json!({"type":"object","properties":properties,"required":required,"additionalProperties":false}).as_object()` can be absent — it is an `Option` or `Result`, which is why it is forced — and `.unwrap()` in `definitions` forces it with nothing on this path excluding `None`/`Err`: no `if let` or `match` arm that matched it present, no `let … else`, no `is_some()`/`is_ok()` test (or `is_none()`/`is_err()` test that leaves), no `assert!` of it, and for a lookup no proof the key or index exists. This line panics the first time the value is not there. Handle the absent case where it arises: propagate it with `?`, branch on it with `if let` / `match` / `let … else`, or give it a default (`unwrap_or`, `unwrap_or_default`, `unwrap_or_else`).
  • + 15 more in this group — see findings.md.
D3 · God Classes · MethodTooLong · ×38
  • MethodTooLong: MigrationExecutor.execute crates/ibcmd-core/src/migration/executor.rs:104 — MethodTooLong — execute runs 270 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted) in one body. The bar is 100 significant lines; this is 170 over it, 2.70× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • MethodTooLong: DcsInnerSchemaEvidenceCorpus.validate crates/ibcmd-schema/src/lib.rs:8605 — MethodTooLong — validate runs 235 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted) in one body. The bar is 100 significant lines; this is 135 over it, 2.35× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • MethodTooLong: BodyWriter.format_record crates/ibcmd-compiler/src/compiler/bodies/mxl_native.rs:1895 — MethodTooLong — format_record runs 199 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted) in one body. The bar is 100 significant lines; this is 99 over it, 1.99× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • MethodTooLong: Writer.write_element REDACTED:983 — MethodTooLong — write_element runs 195 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted) in one body. The bar is 100 significant lines; this is 95 over it, 1.95× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • MethodTooLong: Plan.statements REDACTED:2509 — MethodTooLong — statements runs 183 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted) in one body. The bar is 100 significant lines; this is 83 over it, 1.83× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • MethodTooLong: ObjectView.refresh editors/vscode/src/object-view.ts:164 — MethodTooLong — refresh runs 179 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 79 over it, 1.79× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • MethodTooLong: XmlReader.parse crates/ibcmd-xml/src/reader.rs:91 — MethodTooLong — parse runs 178 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted) in one body. The bar is 100 significant lines; this is 78 over it, 1.78× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • MethodTooLong: StoredConfiguration.prepare_editor_export src/stored_objects/editor_export.rs:17 — MethodTooLong — prepare_editor_export runs 177 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted) in one body. The bar is 100 significant lines; this is 77 over it, 1.77× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • MethodTooLong: DataCompositionXmlWriter.write_start_tag crates/ibcmd-form-body/src/dcs.rs:2111 — MethodTooLong — write_start_tag runs 168 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted) in one body. The bar is 100 significant lines; this is 68 over it, 1.68× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • MethodTooLong: ExternalOwnedSource.from_tree crates/ibcmd-compiler/src/compiler/external_owned.rs:79 — MethodTooLong — from_tree runs 166 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted) in one body. The bar is 100 significant lines; this is 66 over it, 1.66× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • MethodTooLong: Plan.phase_sql REDACTED:191 — MethodTooLong — phase_sql runs 161 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted) in one body. The bar is 100 significant lines; this is 61 over it, 1.61× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • MethodTooLong: MigrationReportError.fmt crates/ibcmd-core/src/migration/report.rs:1303 — MethodTooLong — fmt runs 160 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted) in one body. The bar is 100 significant lines; this is 60 over it, 1.60× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • MethodTooLong: Projector.emit_adopted crates/ibcmd-dump/src/mssql_dump/extension/project.rs:187 — MethodTooLong — emit_adopted runs 157 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted) in one body. The bar is 100 significant lines; this is 57 over it, 1.57× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • MethodTooLong: WebServiceNativeIr.to_xml crates/ibcmd-compiler-families/src/compiler/families/services.rs:923 — MethodTooLong — to_xml runs 150 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted) in one body. The bar is 100 significant lines; this is 50 over it, 1.50× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • MethodTooLong: MigrationReport.from_parts crates/ibcmd-core/src/migration/report.rs:800 — MethodTooLong — from_parts runs 148 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted) in one body. The bar is 100 significant lines; this is 48 over it, 1.48× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • MethodTooLong: DcsSettingsSourceOwnedEvidenceCorpus.validate crates/ibcmd-schema/src/lib.rs:8105 — MethodTooLong — validate runs 147 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted) in one body. The bar is 100 significant lines; this is 47 over it, 1.47× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • MethodTooLong: ModelExport.build crates/ibcmd-dump/src/mssql_dump/model_export.rs:332 — MethodTooLong — build runs 145 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted) in one body. The bar is 100 significant lines; this is 45 over it, 1.45× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • MethodTooLong: DcsSchemaTemplateEnvelopeEvidenceCorpus.validate crates/ibcmd-schema/src/lib.rs:8400 — MethodTooLong — validate runs 143 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted) in one body. The bar is 100 significant lines; this is 43 over it, 1.43× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • MethodTooLong: WebSocketClient.from_xml crates/ibcmd-metadata-model/src/metadata_model/websocket_client.rs:29 — MethodTooLong — from_xml runs 142 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted) in one body. The bar is 100 significant lines; this is 42 over it, 1.42× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • MethodTooLong: DataCompositionXmlWriter.write_document crates/ibcmd-form-body/src/dcs.rs:1827 — MethodTooLong — write_document runs 140 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted) in one body. The bar is 100 significant lines; this is 40 over it, 1.40× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • MethodTooLong: DcsWriterEvidenceCorpus.validate crates/ibcmd-schema/src/lib.rs:11713 — MethodTooLong — validate runs 140 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted) in one body. The bar is 100 significant lines; this is 40 over it, 1.40× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • MethodTooLong: DcsConditionalAppearanceEvidenceCorpus.validate crates/ibcmd-schema/src/lib.rs:9464 — MethodTooLong — validate runs 136 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted) in one body. The bar is 100 significant lines; this is 36 over it, 1.36× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • MethodTooLong: MigrationStepReport.from_parts crates/ibcmd-core/src/migration/report.rs:475 — MethodTooLong — from_parts runs 134 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted) in one body. The bar is 100 significant lines; this is 34 over it, 1.34× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • MethodTooLong: OfflineFormContextFactory.from_plain_rows crates/ibcmd-dump/src/mssql_dump/offline_context.rs:128 — MethodTooLong — from_plain_rows runs 132 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted) in one body. The bar is 100 significant lines; this is 32 over it, 1.32× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • MethodTooLong: Flowchart.item crates/ibcmd-metadata-model/src/metadata_model/bodies_flowchart.rs:479 — MethodTooLong — item runs 132 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted) in one body. The bar is 100 significant lines; this is 32 over it, 1.32× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • + 13 more in this group — see findings.md.
D4 · Code Duplication · Duplicated block (13 lines × 2) · ×38
  • Duplicated block (13 lines × 2) crates/ibcmd-1c-vocab/src/commands.rs:145 — crates/ibcmd-1c-vocab/src/commands.rs:145-157 | crates/ibcmd-dump/src/mssql_dump/mod.rs:36305-36317 — before extracting anything, compare `crates/ibcmd-1c-vocab/src/commands.rs` and `crates/ibcmd-dump/src/mssql_dump/mod.rs` as WHOLE FILES: this scan already matched 4 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. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-1c-vocab/src/commands.rs:145` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (13 lines × 2) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:503 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:503-515 | crates/ibcmd-compiler-families/src/compiler/families/utility.rs:277-289 — before extracting anything, compare `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs` and `crates/ibcmd-compiler-families/src/compiler/families/utility.rs` as WHOLE FILES: this scan already matched 65 separate duplicated blocks between them, totalling at least 934 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:503` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (13 lines × 2) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:2977 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:2977-2989 | crates/ibcmd-compiler-families/src/compiler/families/utility.rs:1556-1568 — before extracting anything, compare `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs` and `crates/ibcmd-compiler-families/src/compiler/families/utility.rs` as WHOLE FILES: this scan already matched 65 separate duplicated blocks between them, totalling at least 934 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:2977` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (13 lines × 2) crates/ibcmd-compiler-families/src/compiler/families/native.rs:821 — crates/ibcmd-compiler-families/src/compiler/families/native.rs:821-833 | crates/ibcmd-compiler-families/src/compiler/families/native.rs:1130-1142 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (13 lines × 2) crates/ibcmd-compiler-families/src/compiler/families/services.rs:3577 — crates/ibcmd-compiler-families/src/compiler/families/services.rs:3577-3589 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:2594-2606 — before extracting anything, compare `crates/ibcmd-compiler-families/src/compiler/families/services.rs` and `crates/ibcmd-compiler-families/src/compiler/families/simple.rs` as WHOLE FILES: this scan already matched 36 separate duplicated blocks between them, totalling at least 406 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/services.rs:3577` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (13 lines × 2) crates/ibcmd-compiler-families/src/compiler/families/services.rs:4328 — crates/ibcmd-compiler-families/src/compiler/families/services.rs:4328-4340 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:3508-3520 — before extracting anything, compare `crates/ibcmd-compiler-families/src/compiler/families/services.rs` and `crates/ibcmd-compiler-families/src/compiler/families/simple.rs` as WHOLE FILES: this scan already matched 36 separate duplicated blocks between them, totalling at least 406 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. 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 `return` inside it is the body's own exit and keeps its meaning in the moved unit.
  • Duplicated block (13 lines × 2) crates/ibcmd-dump/src/mssql_dump/metadata.rs:330 — crates/ibcmd-dump/src/mssql_dump/metadata.rs:330-342 | crates/ibcmd-form-body/src/layout_8_5_1.rs:509-521 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/metadata.rs:330` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (13 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:22879 — crates/ibcmd-dump/src/mssql_dump/mod.rs:22879-22891 | crates/ibcmd-dump/src/mssql_dump/mod.rs:24111-24123 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:22879` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (13 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:28494 — crates/ibcmd-dump/src/mssql_dump/mod.rs:28494-28506 | crates/ibcmd-dump/src/mssql_dump/mod.rs:30011-30023 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:28494` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, `crates/ibcmd-dump/src/mssql_dump/mod.rs:30024` calls `Some` and `crates/ibcmd-dump/src/mssql_dump/mod.rs:28507` does not — after which the two agree again for 4 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
  • Duplicated block (13 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:31187 — crates/ibcmd-dump/src/mssql_dump/mod.rs:31187-31199 | crates/ibcmd-dump/src/mssql_dump/mod.rs:32213-32225 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:31187` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (13 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:38429 — crates/ibcmd-dump/src/mssql_dump/mod.rs:38429-38441 | crates/ibcmd-dump/src/mssql_dump/mod.rs:40453-40465 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:38429` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (13 lines × 2) crates/ibcmd-dump/src/mssql_dump/source_assets.rs:2342 — crates/ibcmd-dump/src/mssql_dump/source_assets.rs:2342-2354 | crates/ibcmd-dump/src/mssql_dump/source_assets.rs:2675-2687 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (13 lines × 2) crates/ibcmd-edt/src/directory.rs:322 — crates/ibcmd-edt/src/directory.rs:322-334 | crates/ibcmd-edt/src/directory.rs:435-447 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-edt/src/directory.rs:322` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (13 lines × 2) crates/ibcmd-form-body/src/form_body.rs:34969 — crates/ibcmd-form-body/src/form_body.rs:34969-34981 | crates/ibcmd-form-body/src/form_body.rs:35703-35715 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-form-body/src/form_body.rs:34969` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (13 lines × 2) crates/ibcmd-form-body/src/form_body.rs:34990 — crates/ibcmd-form-body/src/form_body.rs:34990-35002 | crates/ibcmd-form-body/src/form_body.rs:35016-35028 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-form-body/src/form_body.rs:34990` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (13 lines × 2) crates/ibcmd-form-writer/src/lib.rs:8280 — crates/ibcmd-form-writer/src/lib.rs:8280-8292 | crates/ibcmd-form-writer/src/lib.rs:10128-10140 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-form-writer/src/lib.rs:8280` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (13 lines × 2) crates/ibcmd-metadata-model/src/metadata_model/types_export.rs:110 — crates/ibcmd-metadata-model/src/metadata_model/types_export.rs:110-122 | crates/ibcmd-metadata-model/src/metadata_model/types_export.rs:162-174 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-metadata-model/src/metadata_model/types_export.rs:110` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (13 lines × 2) crates/ibcmd-moxel/src/lib.rs:5709 — crates/ibcmd-moxel/src/lib.rs:5709-5721 | crates/ibcmd-moxel/src/lib.rs:5805-5817 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-moxel/src/lib.rs:5709` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, `crates/ibcmd-moxel/src/lib.rs:5722` calls `contains` and `crates/ibcmd-moxel/src/lib.rs:5818` does not — after which the two agree again for 4 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
  • Duplicated block (13 lines × 2) crates/ibcmd-moxel/src/lib.rs:12045 — crates/ibcmd-moxel/src/lib.rs:12045-12057 | crates/ibcmd-moxel/src/lib.rs:12064-12076 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. 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 `return` inside it is the body's own exit and keeps its meaning in the moved unit.
  • Duplicated block (13 lines × 2) crates/ibcmd-mssql-live/src/mssql_managed_worker/native.rs:1054 — crates/ibcmd-mssql-live/src/mssql_managed_worker/native.rs:1054-1066 | crates/ibcmd-mssql-live/src/mssql_managed_worker/native.rs:1141-1153 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (13 lines × 2) crates/ibcmd-restructure-engine/src/restructure/caches/change.rs:156 — crates/ibcmd-restructure-engine/src/restructure/caches/change.rs:156-168 | crates/ibcmd-restructure-engine/src/restructure/caches/change.rs:227-239 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-restructure-engine/src/restructure/caches/change.rs:156` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (13 lines × 2) crates/ibcmd-xml/src/dcs_schema.rs:1578 — crates/ibcmd-xml/src/dcs_schema.rs:1578-1590 | crates/ibcmd-xml/src/dcs_schema.rs:1681-1693 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-xml/src/dcs_schema.rs:1578` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (13 lines × 2) crates/ibcmd-xml/src/metadata/constant.rs:214 — crates/ibcmd-xml/src/metadata/constant.rs:214-226 | crates/ibcmd-xml/src/metadata/language.rs:102-114 — before extracting anything, compare `crates/ibcmd-xml/src/metadata/constant.rs` and `crates/ibcmd-xml/src/metadata/language.rs` as WHOLE FILES: this scan already matched 19 separate duplicated blocks between them, totalling at least 213 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. 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 `return` inside it is the body's own exit and keeps its meaning in the moved unit.
  • Duplicated block (13 lines × 2) crates/ibcmd-xml/src/metadata/constant.rs:1420 — crates/ibcmd-xml/src/metadata/constant.rs:1420-1432 | crates/ibcmd-xml/src/metadata/language.rs:677-689 — before extracting anything, compare `crates/ibcmd-xml/src/metadata/constant.rs` and `crates/ibcmd-xml/src/metadata/language.rs` as WHOLE FILES: this scan already matched 19 separate duplicated blocks between them, totalling at least 213 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. 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 `return` inside it is the body's own exit and keeps its meaning in the moved unit.
  • Duplicated block (13 lines × 2) src/commands/cf.rs:1213 — src/commands/cf.rs:1213-1225 | src/commands/cf.rs:1285-1297 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `src/commands/cf.rs:1285` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • + 13 more in this group — see findings.md.
D1 · Cyclomatic Complexity · ibcmd_form_writer · ×37
  • ibcmd_form_writer::parse_form_xml_body_properties (cyclomatic 919) crates/ibcmd-form-writer/src/lib.rs:7984 — ibcmd_form_writer::parse_form_xml_body_properties has cyclomatic complexity 919 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
  • ibcmd_form_writer::patch_form_layout_child_item_entry (cyclomatic 188) crates/ibcmd-form-writer/src/lib.rs:18910 — ibcmd_form_writer::patch_form_layout_child_item_entry has cyclomatic complexity 188 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
  • ibcmd_form_writer::patch_form_layout_input_field_extended_options (cyclomatic 74) crates/ibcmd-form-writer/src/lib.rs:19960 — ibcmd_form_writer::patch_form_layout_input_field_extended_options has cyclomatic complexity 74 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
  • ibcmd_form_writer::dynamic_list::convert_block (cyclomatic 58) crates/ibcmd-form-writer/src/dynamic_list.rs:530 — ibcmd_form_writer::dynamic_list::convert_block has cyclomatic complexity 58 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
  • ibcmd_form_writer::format_native_form_body (cyclomatic 53) crates/ibcmd-form-writer/src/lib.rs:6773 — ibcmd_form_writer::format_native_form_body has cyclomatic complexity 53 (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 — the same kind of value, with no behaviour of its own — 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.
  • ibcmd_form_writer::form_chart::chart_record (cyclomatic 51) crates/ibcmd-form-writer/src/form_chart.rs:283 — ibcmd_form_writer::form_chart::chart_record has cyclomatic complexity 51 (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 — the same kind of value, with no behaviour of its own — 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.
  • ibcmd_form_writer::format_form_layout_new_input_field_extended_options (cyclomatic 47) crates/ibcmd-form-writer/src/lib.rs:17527 — ibcmd_form_writer::format_form_layout_new_input_field_extended_options has cyclomatic complexity 47 (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's highest cyclomatic complexity: ibcmd_form_writer::builtin_v8_type_id (cyclomatic 53) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • ibcmd_form_writer::native_field_payload (cyclomatic 41) crates/ibcmd-form-writer/src/lib.rs:4432 — ibcmd_form_writer::native_field_payload has cyclomatic complexity 41 (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 — the same kind of value, with no behaviour of its own — 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. This is NOT this file's highest cyclomatic complexity: ibcmd_form_writer::builtin_v8_type_id (cyclomatic 53) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • ibcmd_form_writer::patch_form_layout_properties (cyclomatic 41) crates/ibcmd-form-writer/src/lib.rs:15444 — ibcmd_form_writer::patch_form_layout_properties has cyclomatic complexity 41 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages. This is NOT this file's highest cyclomatic complexity: ibcmd_form_writer::builtin_v8_type_id (cyclomatic 53) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • ibcmd_form_writer::dynamic_list::dynamic_list_bag (cyclomatic 38) crates/ibcmd-form-writer/src/dynamic_list.rs:1132 — ibcmd_form_writer::dynamic_list::dynamic_list_bag has cyclomatic complexity 38 (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.
  • ibcmd_form_writer::format_native_table_record (cyclomatic 34) crates/ibcmd-form-writer/src/lib.rs:2661 — ibcmd_form_writer::format_native_table_record has cyclomatic complexity 34 (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 — the same kind of value, with no behaviour of its own — 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. This is NOT this file's highest cyclomatic complexity: ibcmd_form_writer::builtin_v8_type_id (cyclomatic 53) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • ibcmd_form_writer::native_root_property_bag (cyclomatic 34) crates/ibcmd-form-writer/src/lib.rs:3052 — ibcmd_form_writer::native_root_property_bag has cyclomatic complexity 34 (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 — the same kind of value, with no behaviour of its own — 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. This is NOT this file's highest cyclomatic complexity: ibcmd_form_writer::builtin_v8_type_id (cyclomatic 53) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • ibcmd_form_writer::format_native_child_item (cyclomatic 31) crates/ibcmd-form-writer/src/lib.rs:2072 — ibcmd_form_writer::format_native_child_item has cyclomatic complexity 31 (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. This is NOT this file's highest cyclomatic complexity: ibcmd_form_writer::builtin_v8_type_id (cyclomatic 53) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • ibcmd_form_writer::native_choice_list_value (cyclomatic 31) crates/ibcmd-form-writer/src/lib.rs:4139 — ibcmd_form_writer::native_choice_list_value has cyclomatic complexity 31 (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 — the same kind of value, with no behaviour of its own — 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. This is NOT this file's highest cyclomatic complexity: ibcmd_form_writer::builtin_v8_type_id (cyclomatic 53) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • ibcmd_form_writer::native_dynamic_list_references (cyclomatic 28) crates/ibcmd-form-writer/src/lib.rs:1433 — ibcmd_form_writer::native_dynamic_list_references 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. This is NOT this file's highest cyclomatic complexity: ibcmd_form_writer::builtin_v8_type_id (cyclomatic 53) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • ibcmd_form_writer::native_embedded_spreadsheet (cyclomatic 28) crates/ibcmd-form-writer/src/lib.rs:6048 — ibcmd_form_writer::native_embedded_spreadsheet 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. This is NOT this file's highest cyclomatic complexity: ibcmd_form_writer::builtin_v8_type_id (cyclomatic 53) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • ibcmd_form_writer::form_base_free_model_blockers (cyclomatic 27) crates/ibcmd-form-writer/src/lib.rs:7498 — ibcmd_form_writer::form_base_free_model_blockers 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. This is NOT this file's highest cyclomatic complexity: ibcmd_form_writer::builtin_v8_type_id (cyclomatic 53) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • ibcmd_form_writer::form_layout_child_item_tag (cyclomatic 27) crates/ibcmd-form-writer/src/lib.rs:21100 — ibcmd_form_writer::form_layout_child_item_tag 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 — the same kind of value, with no behaviour of its own — 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. This is NOT this file's highest cyclomatic complexity: ibcmd_form_writer::builtin_v8_type_id (cyclomatic 53) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • ibcmd_form_writer::apply_form_choice_list_part (cyclomatic 24) crates/ibcmd-form-writer/src/lib.rs:13750 — ibcmd_form_writer::apply_form_choice_list_part 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. This is NOT this file's highest cyclomatic complexity: ibcmd_form_writer::builtin_v8_type_id (cyclomatic 53) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • ibcmd_form_writer::form::xml_2_21_writer::apply_rules (cyclomatic 23) crates/ibcmd-form-writer/src/form/xml_2_21_writer.rs:1176 — ibcmd_form_writer::form::xml_2_21_writer::apply_rules 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.
  • ibcmd_form_writer::validate_form_xml_document (cyclomatic 20) crates/ibcmd-form-writer/src/lib.rs:7439 — ibcmd_form_writer::validate_form_xml_document 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. This is NOT this file's highest cyclomatic complexity: ibcmd_form_writer::builtin_v8_type_id (cyclomatic 53) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • ibcmd_form_writer::patch_form_body_command_entry (cyclomatic 20) crates/ibcmd-form-writer/src/lib.rs:22936 — ibcmd_form_writer::patch_form_body_command_entry has cyclomatic complexity 20 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages. This is NOT this file's highest cyclomatic complexity: ibcmd_form_writer::builtin_v8_type_id (cyclomatic 53) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • ibcmd_form_writer::native_table_addition (cyclomatic 19) crates/ibcmd-form-writer/src/lib.rs:3306 — ibcmd_form_writer::native_table_addition 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 — the same kind of value, with no behaviour of its own — 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. This is NOT this file's highest cyclomatic complexity: ibcmd_form_writer::builtin_v8_type_id (cyclomatic 53) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • ibcmd_form_writer::form_choice_list_part (cyclomatic 19) crates/ibcmd-form-writer/src/lib.rs:13694 — ibcmd_form_writer::form_choice_list_part 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 — the same kind of value, with no behaviour of its own — 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. This is NOT this file's highest cyclomatic complexity: ibcmd_form_writer::builtin_v8_type_id (cyclomatic 53) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • ibcmd_form_writer::native_table_property_bag (cyclomatic 18) crates/ibcmd-form-writer/src/lib.rs:3461 — ibcmd_form_writer::native_table_property_bag has cyclomatic complexity 18 (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 — the same kind of value, with no behaviour of its own — 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. This is NOT this file's highest cyclomatic complexity: ibcmd_form_writer::builtin_v8_type_id (cyclomatic 53) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • + 12 more in this group — see findings.md.
D4 · Code Duplication · Members sharing a duplicated core (4 members, 50+ identical tokens) · ×37
  • Members sharing a duplicated core (4 members, 50+ identical tokens) crates/ibcmd-1c-vocab/src/type_xml.rs:17 — crates/ibcmd-1c-vocab/src/type_xml.rs:17-88 | crates/ibcmd-1c-vocab/src/type_xml.rs:93-163 | crates/ibcmd-dump/src/mssql_dump/mod.rs:44595-44666 | crates/ibcmd-dump/src/mssql_dump/source_assets.rs:5627-5724 — These 4 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below — it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 4 times. The repair is at the members' grain — factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 4 times.
  • Members sharing a duplicated core (4 members, 50+ identical tokens) crates/ibcmd-apply-check/src/apply_check/dbtree.rs:145 — crates/ibcmd-apply-check/src/apply_check/dbtree.rs:145-218 | crates/ibcmd-apply-check/src/apply_check/trees.rs:33-63 | src/dcs_template_audit.rs:79-232 | src/source_audit.rs:2065-2105 — These 4 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below — it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 4 times. The repair is at the members' grain — factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 4 times.
  • Members sharing a duplicated core (4 members, 50+ identical tokens) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:414 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:414-448 | crates/ibcmd-compiler-families/src/compiler/families/services.rs:325-359 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:309-348 | crates/ibcmd-compiler-families/src/compiler/families/utility.rs:190-224 — These 4 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below — it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 4 times. The repair is at the members' grain — factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 4 times.
  • Members sharing a duplicated core (4 members, 50+ identical tokens) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:548 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:548-556 | crates/ibcmd-compiler-families/src/compiler/families/services.rs:1197-1205 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:963-971 | crates/ibcmd-compiler-families/src/compiler/families/utility.rs:312-320 — These 4 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below — it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 4 times. The repair is at the members' grain — factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 4 times.
  • Members sharing a duplicated core (4 members, 50+ identical tokens) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:2655 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:2655-2669 | crates/ibcmd-compiler-families/src/compiler/families/commands.rs:1145-1166 | crates/ibcmd-compiler-families/src/compiler/families/modules.rs:374-385 | crates/ibcmd-compiler-families/src/compiler/families/utility.rs:1324-1338 — These 4 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below — it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 4 times. The repair is at the members' grain — factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 4 times.
  • Members sharing a duplicated core (4 members, 50+ identical tokens) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:2909 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:2909-2950 | crates/ibcmd-compiler-families/src/compiler/families/commands.rs:1225-1262 | crates/ibcmd-compiler-families/src/compiler/families/modules.rs:433-470 | crates/ibcmd-compiler-families/src/compiler/families/utility.rs:1491-1529 — These 4 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below — it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 4 times. The repair is at the members' grain — factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 4 times.
  • Members sharing a duplicated core (4 members, 50+ identical tokens) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:3718 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:3718-3744 | crates/ibcmd-compiler-families/src/compiler/families/services.rs:3524-3550 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:2541-2567 | crates/ibcmd-compiler-families/src/compiler/families/utility.rs:2057-2083 — These 4 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below — it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 4 times. The repair is at the members' grain — factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 4 times.
  • Members sharing a duplicated core (4 members, 50+ identical tokens) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:3746 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:3746-3768 | crates/ibcmd-compiler-families/src/compiler/families/services.rs:3552-3572 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:2569-2589 | crates/ibcmd-compiler-families/src/compiler/families/utility.rs:2085-2107 — These 4 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below — it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 4 times. The repair is at the members' grain — factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 4 times.
  • Members sharing a duplicated core (4 members, 50+ identical tokens) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:3770 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:3770-3785 | crates/ibcmd-compiler-families/src/compiler/families/services.rs:3574-3589 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:2591-2606 | crates/ibcmd-compiler-families/src/compiler/families/utility.rs:2109-2124 — These 4 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below — it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 4 times. The repair is at the members' grain — factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 4 times.
  • Members sharing a duplicated core (4 members, 50+ identical tokens) crates/ibcmd-compiler-families/src/compiler/families/services.rs:2664 — crates/ibcmd-compiler-families/src/compiler/families/services.rs:2664-2696 | crates/ibcmd-compiler-families/src/compiler/families/services.rs:2775-2800 | crates/ibcmd-compiler-families/src/compiler/families/services.rs:2844-2867 | crates/ibcmd-compiler-families/src/compiler/families/services.rs:2939-2962 — These 4 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below — it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 4 times. The repair is at the members' grain — factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 4 times.
  • Members sharing a duplicated core (4 members, 50+ identical tokens) crates/ibcmd-compiler-families/src/compiler/families/services.rs:3380 — crates/ibcmd-compiler-families/src/compiler/families/services.rs:3380-3398 | crates/ibcmd-compiler-families/src/compiler/families/services.rs:3406-3424 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:2397-2415 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:2423-2441 — These 4 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below — it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 4 times. The repair is at the members' grain — factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 4 times.
  • Members sharing a duplicated core (4 members, 50+ identical tokens) crates/ibcmd-core/src/migration/v2_20_to_v2_21.rs:264 — crates/ibcmd-core/src/migration/v2_20_to_v2_21.rs:264-281 | crates/ibcmd-core/src/migration/v2_21_to_v2_20.rs:472-494 | crates/ibcmd-core/src/migration/v2_21_to_v2_20.rs:500-516 | crates/ibcmd-core/src/migration/v2_21_to_v2_20.rs:521-537 — These 4 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below — it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 4 times. The repair is at the members' grain — factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 4 times.
  • Members sharing a duplicated core (4 members, 50+ identical tokens) crates/ibcmd-dump/src/mssql_dump/mod.rs:28891 — crates/ibcmd-dump/src/mssql_dump/mod.rs:28891-28921 | crates/ibcmd-dump/src/mssql_dump/mod.rs:29923-29953 | crates/ibcmd-dump/src/mssql_dump/mod.rs:32818-32850 | crates/ibcmd-dump/src/mssql_dump/mod.rs:33754-33779 — These 4 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below — it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 4 times. The repair is at the members' grain — factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 4 times.
  • Members sharing a duplicated core (4 members, 50+ identical tokens) crates/ibcmd-dump/src/mssql_dump/refs.rs:65 — crates/ibcmd-dump/src/mssql_dump/refs.rs:65-96 | crates/ibcmd-dump/src/mssql_dump/refs.rs:2302-2318 | crates/ibcmd-dump/src/mssql_dump/refs.rs:2348-2379 | crates/ibcmd-dump/src/mssql_dump/refs.rs:3014-3115 — These 4 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below — it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 4 times. The repair is at the members' grain — factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 4 times.
  • Members sharing a duplicated core (4 members, 50+ identical tokens) crates/ibcmd-form-body/src/form_body.rs:3784 — crates/ibcmd-form-body/src/form_body.rs:3784-3861 | crates/ibcmd-form-body/src/form_body.rs:4078-4099 | crates/ibcmd-form-body/src/form_body.rs:4386-4433 | crates/ibcmd-form-body/src/form_body.rs:13081-16451 — These 4 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below — it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 4 times. The repair is at the members' grain — factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 4 times.
  • Members sharing a duplicated core (4 members, 50+ identical tokens) crates/ibcmd-form-body/src/form_body.rs:25007 — crates/ibcmd-form-body/src/form_body.rs:25007-25029 | crates/ibcmd-form-body/src/form_body.rs:27070-27094 | crates/ibcmd-form-body/src/form_body.rs:27399-27427 | crates/ibcmd-form-body/src/form_body.rs:30527-30583 — These 4 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below — it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 4 times. The repair is at the members' grain — factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 4 times.
  • Members sharing a duplicated core (4 members, 50+ identical tokens) crates/ibcmd-form-body/src/form_body.rs:38502 — crates/ibcmd-form-body/src/form_body.rs:38502-38530 | crates/ibcmd-form-body/src/form_body.rs:39135-39175 | crates/ibcmd-form-body/src/form_body.rs:39328-39362 | crates/ibcmd-form-body/src/form_body.rs:39404-39437 — These 4 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below — it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 4 times. The repair is at the members' grain — factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 4 times.
  • Members sharing a duplicated core (4 members, 50+ identical tokens) crates/ibcmd-form-writer/src/lib.rs:16208 — crates/ibcmd-form-writer/src/lib.rs:16208-16218 | crates/ibcmd-form-writer/src/lib.rs:16220-16230 | crates/ibcmd-form-writer/src/lib.rs:21041-21051 | crates/ibcmd-form-writer/src/lib.rs:21053-21063 — These 4 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below — it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 4 times. The repair is at the members' grain — factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 4 times.
  • Members sharing a duplicated core (4 members, 50+ identical tokens) crates/ibcmd-form-writer/src/lib.rs:18500 — crates/ibcmd-form-writer/src/lib.rs:18500-18545 | crates/ibcmd-form-writer/src/lib.rs:18551-18580 | crates/ibcmd-form-writer/src/lib.rs:18599-18632 | crates/ibcmd-form-writer/src/lib.rs:18814-18837 — These 4 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below — it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 4 times. The repair is at the members' grain — factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 4 times.
  • Members sharing a duplicated core (4 members, 50+ identical tokens) crates/ibcmd-metadata-blob/src/lib.rs:733 — crates/ibcmd-metadata-blob/src/lib.rs:733-792 | crates/ibcmd-metadata-blob/src/lib.rs:3221-3293 | crates/ibcmd-metadata-blob/src/lib.rs:3668-3980 | crates/ibcmd-metadata-blob/src/lib.rs:3983-4087 — These 4 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below — it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 4 times. The repair is at the members' grain — factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 4 times.
  • Members sharing a duplicated core (4 members, 50+ identical tokens) crates/ibcmd-metadata-blob/src/lib.rs:6588 — crates/ibcmd-metadata-blob/src/lib.rs:6588-6634 | crates/ibcmd-metadata-blob/src/lib.rs:6639-6667 | crates/ibcmd-metadata-blob/src/lib.rs:6672-6742 | crates/ibcmd-metadata-blob/src/lib.rs:6747-6792 — These 4 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below — it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 4 times. The repair is at the members' grain — factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 4 times.
  • Members sharing a duplicated core (4 members, 50+ identical tokens) crates/ibcmd-metadata-model/src/metadata_model/export_names.rs:277 — crates/ibcmd-metadata-model/src/metadata_model/export_names.rs:277-302 | crates/ibcmd-metadata-model/src/metadata_model/export_names.rs:308-330 | crates/ibcmd-metadata-model/src/metadata_model/export_names.rs:406-428 | REDACTED:993-1015 — These 4 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below — it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 4 times. The repair is at the members' grain — factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 4 times.
  • Members sharing a duplicated core (4 members, 50+ identical tokens) crates/ibcmd-metadata-model/src/metadata_model/registers.rs:395 — crates/ibcmd-metadata-model/src/metadata_model/registers.rs:395-499 | crates/ibcmd-metadata-model/src/metadata_model/registers.rs:583-657 | crates/ibcmd-metadata-model/src/metadata_model/registers.rs:726-807 | crates/ibcmd-metadata-model/src/metadata_model/registers.rs:889-974 — These 4 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below — it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 4 times. The repair is at the members' grain — factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 4 times.
  • Members sharing a duplicated core (4 members, 50+ identical tokens) crates/ibcmd-moxel/src/lib.rs:6090 — crates/ibcmd-moxel/src/lib.rs:6090-6137 | crates/ibcmd-moxel/src/lib.rs:9440-9526 | crates/ibcmd-moxel/src/lib.rs:9531-9584 | crates/ibcmd-moxel/src/lib.rs:9928-10042 — These 4 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below — it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 4 times. The repair is at the members' grain — factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 4 times.
  • Members sharing a duplicated core (4 members, 50+ identical tokens) crates/ibcmd-schema/src/lib.rs:13299 — crates/ibcmd-schema/src/lib.rs:13299-13338 | crates/ibcmd-schema/src/lib.rs:13477-13686 | crates/ibcmd-schema/src/lib.rs:14124-14165 | crates/ibcmd-schema/src/lib.rs:14579-14795 — These 4 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below — it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 4 times. The repair is at the members' grain — factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 4 times.
  • + 12 more in this group — see findings.md.
D4 · Code Duplication · Duplicated block (14 lines × 2) · ×34
  • Duplicated block (14 lines × 2) crates/ibcmd-apply-check/src/apply_check/cli.rs:105 — crates/ibcmd-apply-check/src/apply_check/cli.rs:105-118 | src/mssql_config_apply_command.rs:26-39 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-apply-check/src/apply_check/cli.rs:105` it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows — the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members' bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run — a one-line delegation has no helper inside it to lift — so generate the run from the set it enumerates, or accept it and keep each member's own documentation with it. Note first that the copies are not typed on the same thing: the declarations holding them bind `args` to `&MssqlApplyCheckArgs` in one and `&crate::cli::MssqlConfigApplyArgs` in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH — their common supertype where they have one, or a new abstraction over them where they do not — and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract.
  • Duplicated block (14 lines × 2) crates/ibcmd-apply-check/src/apply_check/dbtree.rs:158 — crates/ibcmd-apply-check/src/apply_check/dbtree.rs:158-171 | crates/ibcmd-apply-check/src/apply_check/trees.rs:39-52 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (14 lines × 2) crates/ibcmd-cf/src/bootstrap.rs:436 — crates/ibcmd-cf/src/bootstrap.rs:436-449 | crates/ibcmd-cf/src/writer.rs:669-682 — before extracting anything, compare `crates/ibcmd-cf/src/bootstrap.rs` and `crates/ibcmd-cf/src/writer.rs` as WHOLE FILES: this scan already matched 3 separate duplicated blocks between them, totalling at least 33 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place.
  • Duplicated block (14 lines × 2) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:2656 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:2656-2669 | crates/ibcmd-compiler-families/src/compiler/families/utility.rs:1325-1338 — before extracting anything, compare `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs` and `crates/ibcmd-compiler-families/src/compiler/families/utility.rs` as WHOLE FILES: this scan already matched 65 separate duplicated blocks between them, totalling at least 934 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. 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 `return` inside it is the body's own exit and keeps its meaning in the moved unit.
  • Duplicated block (14 lines × 2) crates/ibcmd-compiler-families/src/compiler/families/native.rs:504 — crates/ibcmd-compiler-families/src/compiler/families/native.rs:504-517 | crates/ibcmd-compiler-families/src/compiler/families/native.rs:925-938 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (14 lines × 2) crates/ibcmd-compiler-families/src/compiler/families/simple.rs:604 — crates/ibcmd-compiler-families/src/compiler/families/simple.rs:604-617 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:3426-3439 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/simple.rs:604` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (14 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:6090 — crates/ibcmd-dump/src/mssql_dump/mod.rs:6090-6103 | crates/ibcmd-dump/src/mssql_dump/mod.rs:6143-6156 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:6090` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (14 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:18893 — crates/ibcmd-dump/src/mssql_dump/mod.rs:18893-18906 | crates/ibcmd-dump/src/mssql_dump/mod.rs:19438-19458 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:18893` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (14 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:20976 — crates/ibcmd-dump/src/mssql_dump/mod.rs:20976-20989 | crates/ibcmd-dump/src/mssql_dump/mod.rs:34703-34716 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:20976` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (14 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:26064 — crates/ibcmd-dump/src/mssql_dump/mod.rs:26064-26077 | crates/ibcmd-dump/src/mssql_dump/mod.rs:31899-31912 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:26064` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (14 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:38815 — crates/ibcmd-dump/src/mssql_dump/mod.rs:38815-38828 | crates/ibcmd-dump/src/mssql_dump/mod.rs:38967-38980 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (14 lines × 2) crates/ibcmd-form-body/src/dcs.rs:2923 — crates/ibcmd-form-body/src/dcs.rs:2923-2936 | crates/ibcmd-form-body/src/dcs.rs:2939-2952 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. 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 `return` inside it is the body's own exit and keeps its meaning in the moved unit.
  • Duplicated block (14 lines × 2) crates/ibcmd-form-body/src/form_body.rs:11912 — crates/ibcmd-form-body/src/form_body.rs:11912-11925 | crates/ibcmd-form-body/src/form_body.rs:11930-11943 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (14 lines × 2) crates/ibcmd-metadata-blob/src/lib.rs:5843 — crates/ibcmd-metadata-blob/src/lib.rs:5843-5856 | crates/ibcmd-metadata-blob/src/lib.rs:6364-6377 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-metadata-blob/src/lib.rs:5843` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (14 lines × 2) crates/ibcmd-metadata-blob/src/lib.rs:6345 — crates/ibcmd-metadata-blob/src/lib.rs:6345-6358 | crates/ibcmd-metadata-blob/src/lib.rs:6363-6376 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-metadata-blob/src/lib.rs:6345` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (14 lines × 2) crates/ibcmd-metadata-model/src/metadata_model/attribute.rs:390 — crates/ibcmd-metadata-model/src/metadata_model/attribute.rs:390-403 | crates/ibcmd-metadata-model/src/metadata_model/types.rs:746-759 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (14 lines × 2) crates/ibcmd-moxel/src/lib.rs:5719 — crates/ibcmd-moxel/src/lib.rs:5719-5732 | crates/ibcmd-moxel/src/lib.rs:5767-5780 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-moxel/src/lib.rs:5719` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (14 lines × 2) crates/ibcmd-moxel/src/lib.rs:14182 — crates/ibcmd-moxel/src/lib.rs:14182-14195 | crates/ibcmd-moxel/src/lib.rs:14211-14224 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (14 lines × 2) crates/ibcmd-moxel/src/lib.rs:14556 — crates/ibcmd-moxel/src/lib.rs:14556-14569 | crates/ibcmd-moxel/src/lib.rs:14610-14623 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (14 lines × 2) crates/ibcmd-schema/src/lib.rs:2610 — crates/ibcmd-schema/src/lib.rs:2610-2623 | crates/ibcmd-schema/src/lib.rs:2652-2665 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-schema/src/lib.rs:2610` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (14 lines × 2) crates/ibcmd-xml/src/dcs_schema.rs:1503 — crates/ibcmd-xml/src/dcs_schema.rs:1503-1516 | crates/ibcmd-xml/src/dcs_schema.rs:1636-1649 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-xml/src/dcs_schema.rs:1503` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (14 lines × 2) crates/ibcmd-xml/src/dcs_template.rs:652 — crates/ibcmd-xml/src/dcs_template.rs:652-665 | crates/ibcmd-xml/src/dcs_template.rs:730-743 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-xml/src/dcs_template.rs:652` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (14 lines × 2) crates/ibcmd-xml/src/metadata/business_objects.rs:378 — crates/ibcmd-xml/src/metadata/business_objects.rs:378-391 | crates/ibcmd-xml/src/metadata/utility_objects.rs:284-297 — before extracting anything, compare `crates/ibcmd-xml/src/metadata/business_objects.rs` and `crates/ibcmd-xml/src/metadata/utility_objects.rs` as WHOLE FILES: this scan already matched 11 separate duplicated blocks between them, totalling at least 111 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-xml/src/metadata/business_objects.rs:378` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (14 lines × 2) crates/ibcmd-xml/src/metadata/constant.rs:194 — crates/ibcmd-xml/src/metadata/constant.rs:194-207 | crates/ibcmd-xml/src/metadata/language.rs:82-95 — before extracting anything, compare `crates/ibcmd-xml/src/metadata/constant.rs` and `crates/ibcmd-xml/src/metadata/language.rs` as WHOLE FILES: this scan already matched 19 separate duplicated blocks between them, totalling at least 213 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. 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 `return` inside it is the body's own exit and keeps its meaning in the moved unit.
  • Duplicated block (14 lines × 2) crates/ibcmd-xml/src/metadata/functional_option.rs:182 — crates/ibcmd-xml/src/metadata/functional_option.rs:182-195 | crates/ibcmd-xml/src/metadata/functional_options_parameter.rs:166-179 — before extracting anything, compare `crates/ibcmd-xml/src/metadata/functional_option.rs` and `crates/ibcmd-xml/src/metadata/functional_options_parameter.rs` as WHOLE FILES: this scan already matched 17 separate duplicated blocks between them, totalling at least 156 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-xml/src/metadata/functional_option.rs:182` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • + 9 more in this group — see findings.md.
D2 · Cognitive Complexity · ibcmd_moxel · ×32
  • ibcmd_moxel::parse_moxel_spreadsheet_text_with_line_trace (cognitive 120) crates/ibcmd-moxel/src/lib.rs:2111 — ibcmd_moxel::parse_moxel_spreadsheet_text_with_line_trace has cognitive complexity 120 (threshold 15). Drivers by points: if/else 55 (78 pts), boolean chains 23, loops 10 (16 pts), match/switch 3 (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.
  • ibcmd_moxel::parse_moxel_number_format_refs (cognitive 46) crates/ibcmd-moxel/src/lib.rs:9923 — ibcmd_moxel::parse_moxel_number_format_refs has cognitive complexity 46 (threshold 15). Drivers by points: if/else 15 (34 pts), match/switch 2 (6 pts), boolean chains 4, loops 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.
  • ibcmd_moxel::render_moxel_spreadsheet_xml (cognitive 44) crates/ibcmd-moxel/src/lib.rs:11661 — ibcmd_moxel::render_moxel_spreadsheet_xml has cognitive complexity 44 (threshold 15). Drivers by points: if/else 15 (19 pts), loops 17 (19 pts), match/switch 3 (4 pts), boolean chains 2 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_moxel::moxel_output_format_indices (cognitive 44) crates/ibcmd-moxel/src/lib.rs:12116 — ibcmd_moxel::moxel_output_format_indices has cognitive complexity 44 (threshold 15). Drivers by points: if/else 14 (25 pts), loops 7 (11 pts), boolean chains 8 (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.
  • ibcmd_moxel::parse_moxel_rows (cognitive 43) crates/ibcmd-moxel/src/lib.rs:3877 — ibcmd_moxel::parse_moxel_rows has cognitive complexity 43 (threshold 15). Drivers by points: if/else 13 (29 pts), loops 3 (7 pts), boolean chains 5, match/switch 1 (2 pts) (nesting depth added 21). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_moxel::push_moxel_row_xml (cognitive 41) crates/ibcmd-moxel/src/lib.rs:15009 — ibcmd_moxel::push_moxel_row_xml has cognitive complexity 41 (threshold 15). Drivers by points: if/else 21 (30 pts), boolean chains 7, loops 2 (4 pts) (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_moxel::parse_moxel_lines_with_raw_spans (cognitive 37) crates/ibcmd-moxel/src/lib.rs:5362 — ibcmd_moxel::parse_moxel_lines_with_raw_spans has cognitive complexity 37 (threshold 15). Drivers by points: if/else 16 (19 pts), boolean chains 12, loops 2 (6 pts) (nesting depth added 7). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition.
  • ibcmd_moxel::parse_moxel_column_sets_with_source_format_order (cognitive 35) crates/ibcmd-moxel/src/lib.rs:3090 — ibcmd_moxel::parse_moxel_column_sets_with_source_format_order has cognitive complexity 35 (threshold 15). Drivers by points: if/else 13 (29 pts), boolean chains 3, loops 2 (3 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.
  • ibcmd_moxel::moxel_first_use_source_order (cognitive 35) crates/ibcmd-moxel/src/lib.rs:12409 — ibcmd_moxel::moxel_first_use_source_order has cognitive complexity 35 (threshold 15). Drivers by points: if/else 12 (23 pts), loops 7 (10 pts), boolean chains 2 (nesting depth added 14). Of this number, 32 points are the body's 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.
  • ibcmd_moxel::parse_moxel_format_table (cognitive 32) crates/ibcmd-moxel/src/lib.rs:9434 — ibcmd_moxel::parse_moxel_format_table has cognitive complexity 32 (threshold 15). Drivers by points: if/else 9 (19 pts), match/switch 2 (6 pts), boolean chains 4, loops 2 (3 pts) (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_moxel::normalize_moxel_chart_decimal (cognitive 30) crates/ibcmd-moxel/src/lib.rs:8408 — ibcmd_moxel::normalize_moxel_chart_decimal has cognitive complexity 30 (threshold 15). Drivers by points: if/else 17 (22 pts), boolean chains 4, loops 3 (4 pts) (nesting depth added 6). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level.
  • ibcmd_moxel::parse_moxel_chart (cognitive 29) crates/ibcmd-moxel/src/lib.rs:6532 — ibcmd_moxel::parse_moxel_chart has cognitive complexity 29 (threshold 15). Drivers by points: if/else 15 (18 pts), loops 5, match/switch 4, boolean chains 2 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level.
  • ibcmd_moxel::parse_moxel_gantt_chart (cognitive 29) crates/ibcmd-moxel/src/lib.rs:7335 — ibcmd_moxel::parse_moxel_gantt_chart has cognitive complexity 29 (threshold 15). Drivers by points: if/else 15 (16 pts), boolean chains 8, match/switch 4 (5 pts) (nesting depth added 2). To reduce it, split the body: this score is breadth rather than depth — many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
  • ibcmd_moxel::moxel_sparse_source_output_order (cognitive 29) crates/ibcmd-moxel/src/lib.rs:12029 — ibcmd_moxel::moxel_sparse_source_output_order has cognitive complexity 29 (threshold 15). Drivers by points: if/else 9 (14 pts), loops 7 (11 pts), boolean chains 4 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_moxel::parse_moxel_equal_width_only_format_table (cognitive 27) crates/ibcmd-moxel/src/lib.rs:9528 — ibcmd_moxel::parse_moxel_equal_width_only_format_table has cognitive complexity 27 (threshold 15). Drivers by points: if/else 7 (17 pts), boolean chains 5, loops 2 (3 pts), match/switch 1 (2 pts) (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_moxel::parse_moxel_font (cognitive 25) crates/ibcmd-moxel/src/lib.rs:5043 — ibcmd_moxel::parse_moxel_font has cognitive complexity 25 (threshold 15). Drivers by points: if/else 8 (14 pts), match/switch 3 (7 pts), boolean chains 2, loops 1 (2 pts) (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_moxel::remap_moxel_row_and_cell_source_format_indices (cognitive 25) crates/ibcmd-moxel/src/lib.rs:12793 — ibcmd_moxel::remap_moxel_row_and_cell_source_format_indices has cognitive complexity 25 (threshold 15). Drivers by points: if/else 9 (22 pts), loops 2 (3 pts) (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body. This shape REPEATS in the file: one other method here (ibcmd_moxel::remap_moxel_row_and_cell_sparse_internal_format_indices) has the same decision points, in the same order, at the same nesting depths — 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.
  • ibcmd_moxel::remap_moxel_row_and_cell_sparse_internal_format_indices (cognitive 25) crates/ibcmd-moxel/src/lib.rs:12925 — ibcmd_moxel::remap_moxel_row_and_cell_sparse_internal_format_indices has cognitive complexity 25 (threshold 15). Drivers by points: if/else 9 (22 pts), loops 2 (3 pts) (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body. This shape REPEATS in the file: one other method here (ibcmd_moxel::remap_moxel_row_and_cell_source_format_indices) has the same decision points, in the same order, at the same nesting depths — 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.
  • ibcmd_moxel::walk_braced_fields (cognitive 23) crates/ibcmd-moxel/src/lib.rs:390 — ibcmd_moxel::walk_braced_fields has cognitive complexity 23 (threshold 15). Drivers by points: if/else 8 (20 pts), match/switch 1 (2 pts), loops 1 (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_moxel::scan_moxel_row_column_groups (cognitive 23) crates/ibcmd-moxel/src/lib.rs:3330 — ibcmd_moxel::scan_moxel_row_column_groups has cognitive complexity 23 (threshold 15). Drivers by points: if/else 7 (16 pts), boolean chains 3, match/switch 1 (3 pts), loops 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_moxel::remap_moxel_row_and_cell_sparse_source_format_indices (cognitive 22) crates/ibcmd-moxel/src/lib.rs:12832 — ibcmd_moxel::remap_moxel_row_and_cell_sparse_source_format_indices has cognitive complexity 22 (threshold 15). Drivers by points: if/else 6 (19 pts), loops 2 (3 pts) (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_moxel::parse_moxel_cell (cognitive 20) crates/ibcmd-moxel/src/lib.rs:4457 — ibcmd_moxel::parse_moxel_cell has cognitive complexity 20 (threshold 15). Drivers by points: if/else 8 (10 pts), match/switch 8 (9 pts), boolean chains 1 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level.
  • ibcmd_moxel::parse_moxel_pictures (cognitive 20) crates/ibcmd-moxel/src/lib.rs:6087 — ibcmd_moxel::parse_moxel_pictures has cognitive complexity 20 (threshold 15). Drivers by points: if/else 5 (12 pts), boolean chains 3, loops 2 (3 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.
  • ibcmd_moxel::locate_moxel_style_ref_palette_in (cognitive 20) crates/ibcmd-moxel/src/lib.rs:10460 — ibcmd_moxel::locate_moxel_style_ref_palette_in has cognitive complexity 20 (threshold 15). Drivers by points: if/else 8 (16 pts), match/switch 1 (2 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.
  • ibcmd_moxel::parse_moxel_line_table (cognitive 19) crates/ibcmd-moxel/src/lib.rs:5264 — ibcmd_moxel::parse_moxel_line_table has cognitive complexity 19 (threshold 15). Drivers by points: if/else 6 (10 pts), boolean chains 4, match/switch 2 (4 pts), loops 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • + 7 more in this group — see findings.md.
D4 · Code Duplication · Duplicated block (16 lines × 2) · ×31
  • Duplicated block (16 lines × 2) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:2678 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:2678-2693 | crates/ibcmd-compiler-families/src/compiler/families/utility.rs:1347-1362 — before extracting anything, compare `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs` and `crates/ibcmd-compiler-families/src/compiler/families/utility.rs` as WHOLE FILES: this scan already matched 65 separate duplicated blocks between them, totalling at least 934 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:2678` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (16 lines × 2) crates/ibcmd-compiler/src/compiler/bodies/dcs.rs:642 — crates/ibcmd-compiler/src/compiler/bodies/dcs.rs:642-657 | crates/ibcmd-compiler/src/compiler/bodies/dcs.rs:666-681 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (16 lines × 2) REDACTED:1516 — REDACTED:1516-1531 | REDACTED:1599-1614 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `REDACTED:1516` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (16 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:4438 — crates/ibcmd-dump/src/mssql_dump/mod.rs:4438-4453 | crates/ibcmd-dump/src/mssql_dump/mod.rs:5989-6004 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:4438` it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows — the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members' bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run — a one-line delegation has no helper inside it to lift — so generate the run from the set it enumerates, or accept it and keep each member's own documentation with it.
  • Duplicated block (16 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:15328 — crates/ibcmd-dump/src/mssql_dump/mod.rs:15328-15343 | crates/ibcmd-dump/src/mssql_dump/mod.rs:25444-25459 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:15328` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (16 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:20011 — crates/ibcmd-dump/src/mssql_dump/mod.rs:20011-20026 | crates/ibcmd-dump/src/mssql_dump/mod.rs:20058-20073 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:20011` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (16 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:23847 — crates/ibcmd-dump/src/mssql_dump/mod.rs:23847-23862 | crates/ibcmd-dump/src/mssql_dump/mod.rs:24114-24129 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:23847` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (16 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:28906 — crates/ibcmd-dump/src/mssql_dump/mod.rs:28906-28921 | crates/ibcmd-dump/src/mssql_dump/mod.rs:29938-29953 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:28906` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (16 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:37292 — crates/ibcmd-dump/src/mssql_dump/mod.rs:37292-37307 | crates/ibcmd-dump/src/mssql_dump/mod.rs:39270-39285 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:37292` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (16 lines × 2) crates/ibcmd-dump/src/mssql_dump/refs.rs:1202 — crates/ibcmd-dump/src/mssql_dump/refs.rs:1202-1217 | crates/ibcmd-dump/src/mssql_dump/refs.rs:1454-1469 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (16 lines × 2) crates/ibcmd-form-schema/src/lib.rs:2024 — crates/ibcmd-form-schema/src/lib.rs:2024-2039 | crates/ibcmd-form-schema/src/lib.rs:2109-2124 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. 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 `return` inside it is the body's own exit and keeps its meaning in the moved unit.
  • Duplicated block (16 lines × 2) crates/ibcmd-form-writer/src/lib.rs:17261 — crates/ibcmd-form-writer/src/lib.rs:17261-17276 | crates/ibcmd-form-writer/src/lib.rs:17307-17322 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (16 lines × 2) crates/ibcmd-form-writer/src/lib.rs:17965 — crates/ibcmd-form-writer/src/lib.rs:17965-17980 | crates/ibcmd-form-writer/src/lib.rs:18121-18136 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-form-writer/src/lib.rs:17965` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (16 lines × 2) crates/ibcmd-form-writer/src/lib.rs:20532 — crates/ibcmd-form-writer/src/lib.rs:20532-20547 | crates/ibcmd-form-writer/src/lib.rs:20686-20701 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-form-writer/src/lib.rs:20532` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (16 lines × 2) crates/ibcmd-form-writer/src/lib.rs:21474 — crates/ibcmd-form-writer/src/lib.rs:21474-21489 | crates/ibcmd-form-writer/src/lib.rs:21728-21743 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-form-writer/src/lib.rs:21474` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (16 lines × 2) crates/ibcmd-metadata-blob/src/lib.rs:2376 — crates/ibcmd-metadata-blob/src/lib.rs:2376-2391 | crates/ibcmd-metadata-blob/src/lib.rs:3347-3362 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-metadata-blob/src/lib.rs:2376` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (16 lines × 2) crates/ibcmd-metadata-blob/src/lib.rs:5628 — crates/ibcmd-metadata-blob/src/lib.rs:5628-5643 | crates/ibcmd-metadata-blob/src/lib.rs:5739-5754 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-metadata-blob/src/lib.rs:5628` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (16 lines × 2) crates/ibcmd-metadata-blob/src/lib.rs:5786 — crates/ibcmd-metadata-blob/src/lib.rs:5786-5801 | crates/ibcmd-metadata-blob/src/lib.rs:5965-5980 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-metadata-blob/src/lib.rs:5786` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (16 lines × 2) crates/ibcmd-restructure-engine/src/restructure/caches/help_props.rs:141 — crates/ibcmd-restructure-engine/src/restructure/caches/help_props.rs:141-156 | crates/ibcmd-restructure-engine/src/restructure/caches/help_props.rs:170-185 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-restructure-engine/src/restructure/caches/help_props.rs:141` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, `crates/ibcmd-restructure-engine/src/restructure/caches/help_props.rs:138` calls `number`, `push`, `to_owned` and `crates/ibcmd-restructure-engine/src/restructure/caches/help_props.rs:169` does not — after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
  • Duplicated block (16 lines × 2) crates/ibcmd-xml/src/dcs_template.rs:419 — crates/ibcmd-xml/src/dcs_template.rs:419-434 | crates/ibcmd-xml/src/dcs_template.rs:857-872 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (16 lines × 2) REDACTED:1186 — REDACTED:1186-1201 | src/mssql_apply.rs:1565-1580 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once.
  • Duplicated block (16 lines × 2) REDACTED:1645 — REDACTED:1645-1660 | REDACTED:3919-3934 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (16 lines × 2) REDACTED:6520 — REDACTED:6520-6535 | REDACTED:7041-7056 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `REDACTED:6520` it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows — the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members' bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run — a one-line delegation has no helper inside it to lift — so generate the run from the set it enumerates, or accept it and keep each member's own documentation with it. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (16 lines × 2) src/mssql_managed_worker/cli.rs:493 — src/mssql_managed_worker/cli.rs:493-508 | src/mssql_managed_worker/cli.rs:547-562 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, `src/mssql_managed_worker/cli.rs:509` calls `require_supported_main_source_cohort` and `src/mssql_managed_worker/cli.rs:563` does not — after which the two agree again for 3 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
  • Duplicated block (16 lines × 2) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:4429 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:4429-4444 | crates/ibcmd-compiler-families/src/compiler/families/utility.rs:2537-2552 — before extracting anything, compare `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs` and `crates/ibcmd-compiler-families/src/compiler/families/utility.rs` as WHOLE FILES: this scan already matched 65 separate duplicated blocks between them, totalling at least 934 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, `crates/ibcmd-compiler-families/src/compiler/families/utility.rs:2534` calls `is_empty`, `contains`, `native` and `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:4428` does not — after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
  • + 6 more in this group — see findings.md.
D2 · Cognitive Complexity · ibcmd_metadata_blob · ×30
  • ibcmd_metadata_blob::parse_role_rights_xml (cognitive 81) crates/ibcmd-metadata-blob/src/lib.rs:3668 — ibcmd_metadata_blob::parse_role_rights_xml has cognitive complexity 81 (threshold 15). Drivers by points: if/else 23 (68 pts), boolean chains 7, match/switch 2 (5 pts), loops 1 (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.
  • ibcmd_metadata_blob::parse_configuration_object_xml (cognitive 71) crates/ibcmd-metadata-blob/src/lib.rs:7817 — ibcmd_metadata_blob::parse_configuration_object_xml has cognitive complexity 71 (threshold 15). Drivers by points: if/else 22 (54 pts), boolean chains 14, match/switch 1 (2 pts), loops 1 (nesting depth added 33). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_metadata_blob::parse_flowchart_xml (cognitive 62) crates/ibcmd-metadata-blob/src/lib.rs:4769 — ibcmd_metadata_blob::parse_flowchart_xml has cognitive complexity 62 (threshold 15). Drivers by points: if/else 15 (45 pts), boolean chains 10, match/switch 2 (6 pts), loops 1 (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.
  • ibcmd_metadata_blob::role_rights_writer::parse_rights_xml (cognitive 62) crates/ibcmd-metadata-blob/src/role_rights_writer.rs:735 — ibcmd_metadata_blob::role_rights_writer::parse_rights_xml has cognitive complexity 62 (threshold 15). Drivers by points: if/else 18 (47 pts), match/switch 4 (10 pts), boolean chains 4, loops 1 (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.
  • ibcmd_metadata_blob::parse_schedule_xml (cognitive 51) crates/ibcmd-metadata-blob/src/lib.rs:5287 — ibcmd_metadata_blob::parse_schedule_xml has cognitive complexity 51 (threshold 15). Drivers by points: if/else 16 (41 pts), boolean chains 7, match/switch 1 (2 pts), loops 1 (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.
  • ibcmd_metadata_blob::role_rights_writer::parse_uuid_tree (cognitive 46) crates/ibcmd-metadata-blob/src/role_rights_writer.rs:1226 — ibcmd_metadata_blob::role_rights_writer::parse_uuid_tree has cognitive complexity 46 (threshold 15). Drivers by points: if/else 12 (32 pts), match/switch 3 (10 pts), boolean chains 3, loops 1 (nesting depth added 27). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_metadata_blob::parse_simple_metadata_xml_properties (cognitive 45) crates/ibcmd-metadata-blob/src/lib.rs:6097 — ibcmd_metadata_blob::parse_simple_metadata_xml_properties has cognitive complexity 45 (threshold 15). Drivers by points: if/else 13 (37 pts), boolean chains 5, match/switch 1 (2 pts), loops 1 (nesting depth added 25). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_metadata_blob::parse_style_body_xml_items (cognitive 40) crates/ibcmd-metadata-blob/src/lib.rs:1961 — ibcmd_metadata_blob::parse_style_body_xml_items has cognitive complexity 40 (threshold 15). Drivers by points: if/else 12 (30 pts), boolean chains 7, match/switch 1 (2 pts), loops 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.
  • ibcmd_metadata_blob::parse_predefined_data_xml (cognitive 40) crates/ibcmd-metadata-blob/src/lib.rs:4475 — ibcmd_metadata_blob::parse_predefined_data_xml has cognitive complexity 40 (threshold 15). Drivers by points: if/else 10 (28 pts), match/switch 3 (9 pts), boolean chains 2, loops 1 (nesting depth added 24). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_metadata_blob::parse_common_module_xml_properties (cognitive 40) crates/ibcmd-metadata-blob/src/lib.rs:6283 — ibcmd_metadata_blob::parse_common_module_xml_properties has cognitive complexity 40 (threshold 15). Drivers by points: if/else 12 (33 pts), boolean chains 4, match/switch 1 (2 pts), loops 1 (nesting depth added 22). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_metadata_blob::validate_command_interface_xml_document (cognitive 37) crates/ibcmd-metadata-blob/src/lib.rs:2468 — ibcmd_metadata_blob::validate_command_interface_xml_document has cognitive complexity 37 (threshold 15). Drivers by points: if/else 11 (31 pts), boolean chains 3, match/switch 1 (2 pts), loops 1 (nesting depth added 21). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_metadata_blob::parse_help_pages_from_xml (cognitive 32) crates/ibcmd-metadata-blob/src/lib.rs:5149 — ibcmd_metadata_blob::parse_help_pages_from_xml has cognitive complexity 32 (threshold 15). Drivers by points: if/else 8 (24 pts), boolean chains 5, match/switch 1 (2 pts), loops 1 (nesting depth added 17). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_metadata_blob::parse_http_service_method_uuid_from_xml (cognitive 28) crates/ibcmd-metadata-blob/src/lib.rs:3217 — ibcmd_metadata_blob::parse_http_service_method_uuid_from_xml has cognitive complexity 28 (threshold 15). Drivers by points: if/else 9 (18 pts), boolean chains 7, 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.
  • ibcmd_metadata_blob::parse_command_interface_xml (cognitive 26) crates/ibcmd-metadata-blob/src/lib.rs:3983 — ibcmd_metadata_blob::parse_command_interface_xml has cognitive complexity 26 (threshold 15). Drivers by points: if/else 6 (19 pts), match/switch 2 (5 pts), boolean chains 1, 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.
  • ibcmd_metadata_blob::parse_exchange_plan_content_xml (cognitive 24) crates/ibcmd-metadata-blob/src/lib.rs:4089 — ibcmd_metadata_blob::parse_exchange_plan_content_xml has cognitive complexity 24 (threshold 15). Drivers by points: if/else 5 (15 pts), match/switch 2 (5 pts), boolean chains 3, 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.
  • ibcmd_metadata_blob::parse_common_command_xml_properties (cognitive 24) crates/ibcmd-metadata-blob/src/lib.rs:5778 — ibcmd_metadata_blob::parse_common_command_xml_properties has cognitive complexity 24 (threshold 15). Drivers by points: if/else 7 (18 pts), boolean chains 3, match/switch 1 (2 pts), loops 1 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body. This shape REPEATS in the file: one other method here (ibcmd_metadata_blob::parse_command_group_xml_properties) has the same decision points, in the same order, at the same nesting depths — 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.
  • ibcmd_metadata_blob::parse_command_group_xml_properties (cognitive 24) crates/ibcmd-metadata-blob/src/lib.rs:5957 — ibcmd_metadata_blob::parse_command_group_xml_properties has cognitive complexity 24 (threshold 15). Drivers by points: if/else 7 (18 pts), boolean chains 3, match/switch 1 (2 pts), loops 1 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body. This shape REPEATS in the file: one other method here (ibcmd_metadata_blob::parse_common_command_xml_properties) has the same decision points, in the same order, at the same nesting depths — 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.
  • ibcmd_metadata_blob::role_rights_writer::boost_unordered_iteration_order (cognitive 24) crates/ibcmd-metadata-blob/src/role_rights_writer.rs:656 — ibcmd_metadata_blob::role_rights_writer::boost_unordered_iteration_order has cognitive complexity 24 (threshold 15). Drivers by points: if/else 8 (18 pts), loops 3 (6 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.
  • ibcmd_metadata_blob::parse_nested_command_uuid_from_xml (cognitive 23) crates/ibcmd-metadata-blob/src/lib.rs:2328 — ibcmd_metadata_blob::parse_nested_command_uuid_from_xml has cognitive complexity 23 (threshold 15). Drivers by points: if/else 6 (17 pts), boolean chains 3, match/switch 1 (2 pts), loops 1 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body. This shape REPEATS in the file: one other method here (ibcmd_metadata_blob::parse_nested_metadata_child_uuid_from_xml) has the same decision points, in the same order, at the same nesting depths — 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.
  • ibcmd_metadata_blob::parse_nested_metadata_child_uuid_from_xml (cognitive 23) crates/ibcmd-metadata-blob/src/lib.rs:3295 — ibcmd_metadata_blob::parse_nested_metadata_child_uuid_from_xml has cognitive complexity 23 (threshold 15). Drivers by points: if/else 6 (17 pts), boolean chains 3, match/switch 1 (2 pts), loops 1 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body. This shape REPEATS in the file: one other method here (ibcmd_metadata_blob::parse_nested_command_uuid_from_xml) has the same decision points, in the same order, at the same nesting depths — 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.
  • ibcmd_metadata_blob::role_rights_writer::write_role_rights_document (cognitive 22) crates/ibcmd-metadata-blob/src/role_rights_writer.rs:169 — ibcmd_metadata_blob::role_rights_writer::write_role_rights_document has cognitive complexity 22 (threshold 15). Drivers by points: if/else 12 (15 pts), loops 3 (5 pts), match/switch 1 (2 pts) (nesting depth added 6). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level.
  • ibcmd_metadata_blob::xml::parse_element_tree_with (cognitive 21) crates/ibcmd-metadata-blob/src/xml.rs:168 — ibcmd_metadata_blob::xml::parse_element_tree_with has cognitive complexity 21 (threshold 15). Drivers by points: if/else 5 (14 pts), match/switch 3 (6 pts), loops 1 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_metadata_blob::pack_style_body_blob_from_xml_with_base (cognitive 20) crates/ibcmd-metadata-blob/src/lib.rs:1358 — ibcmd_metadata_blob::pack_style_body_blob_from_xml_with_base has cognitive complexity 20 (threshold 15). Drivers by points: if/else 9 (15 pts), loops 3 (5 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.
  • ibcmd_metadata_blob::parse_additional_indexes_xml (cognitive 20) crates/ibcmd-metadata-blob/src/lib.rs:1801 — ibcmd_metadata_blob::parse_additional_indexes_xml has cognitive complexity 20 (threshold 15). Drivers by points: if/else 8 (17 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.
  • ibcmd_metadata_blob::role_rights_writer::write_object_rights (cognitive 20) crates/ibcmd-metadata-blob/src/role_rights_writer.rs:270 — ibcmd_metadata_blob::role_rights_writer::write_object_rights has cognitive complexity 20 (threshold 15). Drivers by points: if/else 8 (12 pts), loops 4 (5 pts), match/switch 1 (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.
  • + 5 more in this group — see findings.md.
D2 · Cognitive Complexity · ibcmd_compiler_families · ×27
  • ibcmd_compiler_families::compiler::families::native::descriptor_own_uuid (cognitive 56) crates/ibcmd-compiler-families/src/compiler/families/native.rs:364 — ibcmd_compiler_families::compiler::families::native::descriptor_own_uuid has cognitive complexity 56 (threshold 15). Drivers by points: if/else 25 (46 pts), boolean chains 6, match/switch 1 (3 pts), loops 1 (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.
  • ibcmd_compiler_families::compiler::families::business_object::type_pattern (cognitive 40) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:3302 — ibcmd_compiler_families::compiler::families::business_object::type_pattern has cognitive complexity 40 (threshold 15). Drivers by points: match/switch 8 (25 pts), if/else 4 (8 pts), boolean chains 6, loops 1 (nesting depth added 21). 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.
  • ibcmd_compiler_families::compiler::families::utility::type_pattern (cognitive 40) crates/ibcmd-compiler-families/src/compiler/families/utility.rs:1646 — ibcmd_compiler_families::compiler::families::utility::type_pattern has cognitive complexity 40 (threshold 15). Drivers by points: match/switch 8 (25 pts), if/else 4 (8 pts), boolean chains 6, loops 1 (nesting depth added 21). 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.
  • ibcmd_compiler_families::compiler::families::simple::write_type_pattern_xml (cognitive 33) crates/ibcmd-compiler-families/src/compiler/families/simple.rs:3406 — ibcmd_compiler_families::compiler::families::simple::write_type_pattern_xml has cognitive complexity 33 (threshold 15). Drivers by points: if/else 14 (29 pts), loops 2, match/switch 1 (2 pts) (nesting depth added 16). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body. This shape REPEATS in the file: one other method here (SessionParameterNativeIr::to_xml) has the same decision points, in the same order, at the same nesting depths — 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.
  • ibcmd_compiler_families::compiler::families::native::write_value (cognitive 31) crates/ibcmd-compiler-families/src/compiler/families/native.rs:558 — ibcmd_compiler_families::compiler::families::native::write_value has cognitive complexity 31 (threshold 15). Drivers by points: if/else 10 (22 pts), boolean chains 4, loops 2 (4 pts), match/switch 1 (nesting depth added 14). The drivers above price the dispatch low by construction — a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full — so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident.
  • ibcmd_compiler_families::compiler::families::simple::project_type_pattern_metadata (cognitive 31) crates/ibcmd-compiler-families/src/compiler/families/simple.rs:1498 — ibcmd_compiler_families::compiler::families::simple::project_type_pattern_metadata has cognitive complexity 31 (threshold 15). Drivers by points: if/else 11 (20 pts), match/switch 3 (6 pts), boolean chains 4, loops 1 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_compiler_families::compiler::families::services::project_http_service (cognitive 30) crates/ibcmd-compiler-families/src/compiler/families/services.rs:1896 — ibcmd_compiler_families::compiler::families::services::project_http_service has cognitive complexity 30 (threshold 15). Drivers by points: if/else 11 (22 pts), boolean chains 5, loops 2 (3 pts) (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_compiler_families::compiler::families::simple::project_constant (cognitive 30) crates/ibcmd-compiler-families/src/compiler/families/simple.rs:1202 — ibcmd_compiler_families::compiler::families::simple::project_constant has cognitive complexity 30 (threshold 15). Drivers by points: if/else 12 (16 pts), match/switch 6 (8 pts), boolean chains 5, 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.
  • ibcmd_compiler_families::compiler::families::business_object::collect_children (cognitive 29) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:1889 — ibcmd_compiler_families::compiler::families::business_object::collect_children has cognitive complexity 29 (threshold 15). Drivers by points: if/else 8 (21 pts), loops 3 (5 pts), match/switch 1 (2 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.
  • ibcmd_compiler_families::compiler::families::services::project_web_service (cognitive 26) crates/ibcmd-compiler-families/src/compiler/families/services.rs:2027 — ibcmd_compiler_families::compiler::families::services::project_web_service has cognitive complexity 26 (threshold 15). Drivers by points: if/else 12 (20 pts), boolean chains 3, loops 2 (3 pts) (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_compiler_families::compiler::families::assets::decode_base64 (cognitive 23) crates/ibcmd-compiler-families/src/compiler/families/assets.rs:1321 — ibcmd_compiler_families::compiler::families::assets::decode_base64 has cognitive complexity 23 (threshold 15). Drivers by points: if/else 9 (15 pts), boolean chains 7, 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.
  • ibcmd_compiler_families::compiler::artifact::discover_source_package (cognitive 22) crates/ibcmd-compiler-families/src/compiler/artifact.rs:21 — ibcmd_compiler_families::compiler::artifact::discover_source_package has cognitive complexity 22 (threshold 15). Drivers by points: if/else 9 (19 pts), loops 2 (3 pts) (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_compiler_families::compiler::families::services::validate_integration_service_ir (cognitive 22) crates/ibcmd-compiler-families/src/compiler/families/services.rs:2698 — ibcmd_compiler_families::compiler::families::services::validate_integration_service_ir has cognitive complexity 22 (threshold 15). Drivers by points: if/else 5 (10 pts), boolean chains 6, loops 3 (4 pts), match/switch 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.
  • ibcmd_compiler_families::compiler::families::services::project_web_packages (cognitive 21) crates/ibcmd-compiler-families/src/compiler/families/services.rs:2210 — ibcmd_compiler_families::compiler::families::services::project_web_packages has cognitive complexity 21 (threshold 15). Drivers by points: if/else 7 (14 pts), loops 3, boolean chains 2, match/switch 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.
  • ibcmd_compiler_families::compiler::families::simple::generated_type_reference_index (cognitive 21) crates/ibcmd-compiler-families/src/compiler/families/simple.rs:1908 — ibcmd_compiler_families::compiler::families::simple::generated_type_reference_index has cognitive complexity 21 (threshold 15). Drivers by points: if/else 6 (14 pts), loops 2 (3 pts), boolean chains 2, match/switch 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.
  • ibcmd_compiler_families::compiler::families::simple::parse_native_type_pattern (cognitive 21) crates/ibcmd-compiler-families/src/compiler/families/simple.rs:2878 — ibcmd_compiler_families::compiler::families::simple::parse_native_type_pattern has cognitive complexity 21 (threshold 15). Drivers by points: if/else 7 (14 pts), match/switch 2 (5 pts), boolean chains 1, loops 1 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_compiler_families::compiler::families::utility::collect_children (cognitive 21) crates/ibcmd-compiler-families/src/compiler/families/utility.rs:911 — ibcmd_compiler_families::compiler::families::utility::collect_children has cognitive complexity 21 (threshold 15). Drivers by points: if/else 4 (13 pts), loops 3 (5 pts), match/switch 1 (2 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.
  • ibcmd_compiler_families::compiler::families::utility::validate_native_identity_inventory (cognitive 21) crates/ibcmd-compiler-families/src/compiler/families/utility.rs:2576 — ibcmd_compiler_families::compiler::families::utility::validate_native_identity_inventory has cognitive complexity 21 (threshold 15). Drivers by points: if/else 5 (12 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.
  • ibcmd_compiler_families::compiler::identity::collect_artifact_identities (cognitive 21) crates/ibcmd-compiler-families/src/compiler/identity.rs:225 — ibcmd_compiler_families::compiler::identity::collect_artifact_identities has cognitive complexity 21 (threshold 15). Drivers by points: if/else 7 (13 pts), loops 3 (5 pts), boolean chains 3 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_compiler_families::compiler::families::services::validate_web_service_ir (cognitive 20) crates/ibcmd-compiler-families/src/compiler/families/services.rs:2869 — ibcmd_compiler_families::compiler::families::services::validate_web_service_ir has cognitive complexity 20 (threshold 15). Drivers by points: if/else 5 (10 pts), boolean chains 5, loops 4 (5 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.
  • ibcmd_compiler_families::compiler::graph::build_artifact_graph (cognitive 19) crates/ibcmd-compiler-families/src/compiler/graph.rs:481 — ibcmd_compiler_families::compiler::graph::build_artifact_graph has cognitive complexity 19 (threshold 15). Drivers by points: if/else 4 (8 pts), loops 5 (8 pts), match/switch 1 (2 pts), boolean chains 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_compiler_families::compiler::families::services::serialize_web_service (cognitive 18) crates/ibcmd-compiler-families/src/compiler/families/services.rs:3269 — ibcmd_compiler_families::compiler::families::services::serialize_web_service has cognitive complexity 18 (threshold 15). Drivers by points: if/else 8 (13 pts), loops 4 (5 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.
  • ibcmd_compiler_families::compiler::families::business_object::write_native_value (cognitive 17) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:3596 — ibcmd_compiler_families::compiler::families::business_object::write_native_value has cognitive complexity 17 (threshold 15). Drivers by points: if/else 5 (10 pts), loops 2 (4 pts), boolean chains 2, match/switch 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.
  • ibcmd_compiler_families::compiler::families::services::generated_type_reference_index (cognitive 17) crates/ibcmd-compiler-families/src/compiler/families/services.rs:1648 — ibcmd_compiler_families::compiler::families::services::generated_type_reference_index has cognitive complexity 17 (threshold 15). Drivers by points: if/else 5 (11 pts), loops 2 (3 pts), match/switch 1 (2 pts), boolean chains 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_compiler_families::compiler::families::utility::write_native_value (cognitive 17) crates/ibcmd-compiler-families/src/compiler/families/utility.rs:1934 — ibcmd_compiler_families::compiler::families::utility::write_native_value has cognitive complexity 17 (threshold 15). Drivers by points: if/else 5 (10 pts), loops 2 (4 pts), boolean chains 2, match/switch 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.
  • + 2 more in this group — see findings.md.
D4 · Code Duplication · Edited copy of a member (8 corresponding lines) · ×26
  • Edited copy of a member (8 corresponding lines) crates/ibcmd-metadata-model/src/metadata_model/common_export.rs:156 — crates/ibcmd-metadata-model/src/metadata_model/common_export.rs:156-163 | crates/ibcmd-metadata-model/src/metadata_model/common_export.rs:568-575 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (8 corresponding lines) crates/ibcmd-form-body/src/form_body.rs:28706 — crates/ibcmd-form-body/src/form_body.rs:28706-28713 | crates/ibcmd-form-body/src/form_body.rs:28718-28747 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (8 corresponding lines) crates/ibcmd-metadata-model/src/metadata_model/audit.rs:308 — crates/ibcmd-metadata-model/src/metadata_model/audit.rs:308-315 | crates/ibcmd-metadata-model/src/metadata_model/export_audit.rs:450-460 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (8 corresponding lines) crates/ibcmd-form-body/src/form_body.rs:31493 — crates/ibcmd-form-body/src/form_body.rs:31493-31500 | crates/ibcmd-form-body/src/form_body.rs:31525-31537 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (8 corresponding lines) crates/ibcmd-dump/src/mssql_dump/mod.rs:15350 — crates/ibcmd-dump/src/mssql_dump/mod.rs:15350-15357 | crates/ibcmd-dump/src/mssql_dump/mod.rs:27055-27062 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (8 corresponding lines) crates/ibcmd-metadata-model/src/metadata_model/bodies_flowchart.rs:170 — crates/ibcmd-metadata-model/src/metadata_model/bodies_flowchart.rs:170-177 | crates/ibcmd-metadata-model/src/metadata_model/mod.rs:165-173 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (8 corresponding lines) crates/ibcmd-form-body/src/form_body.rs:28573 — crates/ibcmd-form-body/src/form_body.rs:28573-28580 | crates/ibcmd-form-body/src/form_body.rs:28582-28590 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (8 corresponding lines) crates/ibcmd-moxel/src/lib.rs:444 — crates/ibcmd-moxel/src/lib.rs:444-451 | crates/ibcmd-moxel/src/lib.rs:456-463 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (8 corresponding lines) crates/ibcmd-form-body/src/form_body.rs:21378 — crates/ibcmd-form-body/src/form_body.rs:21378-21388 | crates/ibcmd-form-body/src/form_body.rs:21393-21400 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (8 corresponding lines) crates/ibcmd-core/src/migration/v2_20_to_v2_21.rs:163 — crates/ibcmd-core/src/migration/v2_20_to_v2_21.rs:163-170 | crates/ibcmd-core/src/migration/v2_21_to_v2_20.rs:188-195 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (8 corresponding lines) crates/ibcmd-form-body/src/form_body.rs:17963 — crates/ibcmd-form-body/src/form_body.rs:17963-17970 | crates/ibcmd-form-body/src/form_body.rs:17978-17985 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (8 corresponding lines) crates/ibcmd-form-schema/src/lib.rs:7146 — crates/ibcmd-form-schema/src/lib.rs:7146-7157 | crates/ibcmd-form-schema/src/lib.rs:7166-7173 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (8 corresponding lines) crates/ibcmd-xml/src/metadata/constant.rs:592 — crates/ibcmd-xml/src/metadata/constant.rs:592-599 | crates/ibcmd-xml/src/metadata/session_parameter.rs:494-502 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (8 corresponding lines) crates/ibcmd-form-body/src/form_body.rs:20203 — crates/ibcmd-form-body/src/form_body.rs:20203-20212 | crates/ibcmd-form-schema/src/lib.rs:5985-5992 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (8 corresponding lines) crates/ibcmd-compiler-families/src/compiler/families/services.rs:4191 — crates/ibcmd-compiler-families/src/compiler/families/services.rs:4191-4198 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:3153-3160 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (8 corresponding lines) REDACTED:10626 — REDACTED:10626-10633 | src/mssql_extensions.rs:839-846 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (8 corresponding lines) crates/ibcmd-1c-text/src/fields.rs:181 — crates/ibcmd-1c-text/src/fields.rs:181-190 | crates/ibcmd-dump/src/mssql_dump/cas.rs:803-810 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (8 corresponding lines) crates/ibcmd-form-body/src/form_body.rs:39042 — crates/ibcmd-form-body/src/form_body.rs:39042-39049 | crates/ibcmd-form-writer/src/lib.rs:2028-2035 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (8 corresponding lines) crates/ibcmd-metadata-model/src/metadata_model/interface.rs:247 — crates/ibcmd-metadata-model/src/metadata_model/interface.rs:247-254 | crates/ibcmd-metadata-model/src/metadata_model/websocket_client.rs:349-356 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (8 corresponding lines) crates/ibcmd-sql/src/sql/mod.rs:98 — crates/ibcmd-sql/src/sql/mod.rs:98-105 | crates/ibcmd-xml/src/source_tree/reader.rs:66-73 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (8 corresponding lines) crates/ibcmd-form-body/src/form_body.rs:18426 — crates/ibcmd-form-body/src/form_body.rs:18426-18433 | crates/ibcmd-form-schema/src/lib.rs:4703-4710 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (8 corresponding lines) crates/ibcmd-metadata-model/src/metadata_model/common_export.rs:797 — crates/ibcmd-metadata-model/src/metadata_model/common_export.rs:797-804 | crates/ibcmd-metadata-model/src/metadata_model/simple_export.rs:613-620 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (8 corresponding lines) crates/ibcmd-metadata-model/src/metadata_model/common.rs:231 — crates/ibcmd-metadata-model/src/metadata_model/common.rs:231-238 | crates/ibcmd-metadata-model/src/metadata_model/registers_parts.rs:106-113 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (8 corresponding lines) _onecdec/make_compat_form_fixtures.py:71 — _onecdec/make_compat_form_fixtures.py:71-78 | _onecdec/make_home_page_fixtures.py:62-70 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (8 corresponding lines) scripts/import-lab/edits.py:270 — scripts/import-lab/edits.py:270-277 | scripts/import-lab/edits.py:440-447 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • + 1 more in this group — see findings.md.
D4 · Code Duplication · Duplicated block (7 lines × 3) · ×26
  • Duplicated block (7 lines × 3) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:2656 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:2656-2663 | crates/ibcmd-compiler-families/src/compiler/families/modules.rs:375-381 | crates/ibcmd-compiler-families/src/compiler/families/utility.rs:1325-1332 — before extracting anything, compare `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs` and `crates/ibcmd-compiler-families/src/compiler/families/utility.rs` as WHOLE FILES: this scan already matched 65 separate duplicated blocks between them, totalling at least 934 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:2656` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
  • Duplicated block (7 lines × 3) crates/ibcmd-compiler/src/compiler/bodies/mxl_native.rs:121 — crates/ibcmd-compiler/src/compiler/bodies/mxl_native.rs:121-127 | REDACTED:548-554 | crates/ibcmd-config-apply/src/mssql_config_apply/dynamic_metadata.rs:400-406 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 3 call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made 3 times.
  • Duplicated block (7 lines × 3) crates/ibcmd-dump/src/mssql_dump/mod.rs:15164 — crates/ibcmd-dump/src/mssql_dump/mod.rs:15164-15170 | crates/ibcmd-form-body/src/form_body.rs:41307-41313 | crates/ibcmd-form-body/src/form_body.rs:41405-41411 — there are 3 copies across 2 file(s) — more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 3 sites; resolving a subset leaves the remainder to drift apart. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, `crates/ibcmd-dump/src/mssql_dump/mod.rs:15161` calls `exchange_plan_characteristics_is_empty`, `get`, `trim` and `crates/ibcmd-form-body/src/form_body.rs:41306` does not — after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
  • Duplicated block (7 lines × 3) crates/ibcmd-dump/src/mssql_dump/mod.rs:17943 — crates/ibcmd-dump/src/mssql_dump/mod.rs:17943-17949 | crates/ibcmd-dump/src/mssql_dump/mod.rs:17984-17990 | crates/ibcmd-dump/src/mssql_dump/mod.rs:18991-18997 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited.
  • Duplicated block (7 lines × 3) crates/ibcmd-dump/src/mssql_dump/mod.rs:29285 — crates/ibcmd-dump/src/mssql_dump/mod.rs:29285-29299 | crates/ibcmd-dump/src/mssql_dump/mod.rs:32363-32369 | crates/ibcmd-dump/src/mssql_dump/mod.rs:33006-33012 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:29285` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (7 lines × 3) crates/ibcmd-form-body/src/form_body.rs:4091 — crates/ibcmd-form-body/src/form_body.rs:4091-4097 | crates/ibcmd-form-body/src/form_body.rs:4413-4419 | crates/ibcmd-form-body/src/form_body.rs:13134-13140 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-form-body/src/form_body.rs:4091` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (7 lines × 3) crates/ibcmd-form-body/src/form_body.rs:13252 — crates/ibcmd-form-body/src/form_body.rs:13252-13258 | crates/ibcmd-form-body/src/form_body.rs:13322-13328 | crates/ibcmd-form-body/src/form_body.rs:13334-13340 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-form-body/src/form_body.rs:13252` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, `crates/ibcmd-form-body/src/form_body.rs:13319` calls `from_raw_layout` and `crates/ibcmd-form-body/src/form_body.rs:13249` does not — after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
  • Duplicated block (7 lines × 3) crates/ibcmd-form-body/src/form_body.rs:39500 — crates/ibcmd-form-body/src/form_body.rs:39500-39506 | crates/ibcmd-moxel/src/lib.rs:7088-7094 | crates/ibcmd-moxel/src/lib.rs:7126-7132 — before extracting anything, compare `crates/ibcmd-form-body/src/form_body.rs` and `crates/ibcmd-moxel/src/lib.rs` as WHOLE FILES: this scan already matched 4 separate duplicated blocks between them, totalling at least 52 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. The two sit in different directories, so one cannot simply be deleted in favour of the other while both are reached separately: hoist the shared part into a location both already depend on and have each file call it, and retire whichever file turns out to have no caller of its own left. Extracting one helper per block leaves the fork in place. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (7 lines × 3) crates/ibcmd-form-writer/src/lib.rs:8386 — crates/ibcmd-form-writer/src/lib.rs:8386-8392 | crates/ibcmd-form-writer/src/lib.rs:8822-8828 | crates/ibcmd-form-writer/src/lib.rs:8936-8943 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-form-writer/src/lib.rs:8386` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (7 lines × 3) crates/ibcmd-metadata-model/src/metadata_model/registers.rs:412 — crates/ibcmd-metadata-model/src/metadata_model/registers.rs:412-418 | crates/ibcmd-metadata-model/src/metadata_model/registers.rs:594-600 | crates/ibcmd-metadata-model/src/metadata_model/registers.rs:752-758 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-metadata-model/src/metadata_model/registers.rs:412` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, `crates/ibcmd-metadata-model/src/metadata_model/registers.rs:419` calls `code` and `crates/ibcmd-metadata-model/src/metadata_model/registers.rs:601` does not — after which the two agree again for 4 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
  • Duplicated block (7 lines × 3) crates/ibcmd-xml/src/metadata/functional_option.rs:125 — crates/ibcmd-xml/src/metadata/functional_option.rs:125-131 | crates/ibcmd-xml/src/metadata/functional_options_parameter.rs:113-119 | crates/ibcmd-xml/src/metadata/session_parameter.rs:169-175 — before extracting anything, compare `crates/ibcmd-xml/src/metadata/functional_option.rs` and `crates/ibcmd-xml/src/metadata/functional_options_parameter.rs` as WHOLE FILES: this scan already matched 17 separate duplicated blocks between them, totalling at least 156 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-xml/src/metadata/functional_option.rs:125` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (7 lines × 3) crates/ibcmd-xml/src/metadata/functional_option.rs:155 — crates/ibcmd-xml/src/metadata/functional_option.rs:155-163 | crates/ibcmd-xml/src/metadata/functional_options_parameter.rs:143-149 | crates/ibcmd-xml/src/metadata/session_parameter.rs:267-273 — before extracting anything, compare `crates/ibcmd-xml/src/metadata/functional_option.rs` and `crates/ibcmd-xml/src/metadata/functional_options_parameter.rs` as WHOLE FILES: this scan already matched 17 separate duplicated blocks between them, totalling at least 156 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-xml/src/metadata/functional_option.rs:155` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
  • Duplicated block (7 lines × 3) crates/ibcmd-dump/src/mssql_dump/source_assets.rs:5916 — crates/ibcmd-dump/src/mssql_dump/source_assets.rs:5916-5922 | crates/ibcmd-dump/src/mssql_dump/source_assets.rs:5923-5929 | crates/ibcmd-dump/src/mssql_dump/source_assets.rs:5932-5938 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, `crates/ibcmd-dump/src/mssql_dump/source_assets.rs:5931` calls `get`, `trim`, `ok` and `crates/ibcmd-dump/src/mssql_dump/source_assets.rs:5915` does not — after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
  • Duplicated block (7 lines × 3) crates/ibcmd-metadata-blob/src/lib.rs:8181 — crates/ibcmd-metadata-blob/src/lib.rs:8181-8187 | REDACTED:7544-7550 | src/trace.rs:390-396 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 3 call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made 3 times. Note first that the copies are not typed on the same thing: the declarations holding them bind `event` to `&BytesStart<'_>` in one and `&quick_xml::events::BytesStart<'_>` in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH — their common supertype where they have one, or a new abstraction over them where they do not — and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract.
  • Duplicated block (7 lines × 3) crates/ibcmd-metadata-model/src/metadata_model/common_export.rs:72 — crates/ibcmd-metadata-model/src/metadata_model/common_export.rs:72-78 | crates/ibcmd-metadata-model/src/metadata_model/forms_export.rs:71-77 | crates/ibcmd-metadata-model/src/metadata_model/simple_export.rs:63-69 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from all 3 call sites, so a change lands once.
  • Duplicated block (7 lines × 3) crates/ibcmd-metadata-blob/src/lib.rs:3806 — crates/ibcmd-metadata-blob/src/lib.rs:3806-3812 | crates/ibcmd-metadata-blob/src/lib.rs:4035-4043 | crates/ibcmd-metadata-blob/src/lib.rs:4122-4128 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-metadata-blob/src/lib.rs:3806` it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows — the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members' bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run — a one-line delegation has no helper inside it to lift — so generate the run from the set it enumerates, or accept it and keep each member's own documentation with it. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
  • Duplicated block (7 lines × 3) crates/ibcmd-dump/src/mssql_dump/mod.rs:17208 — crates/ibcmd-dump/src/mssql_dump/mod.rs:17208-17214 | crates/ibcmd-dump/src/mssql_dump/mod.rs:21883-21890 | crates/ibcmd-dump/src/mssql_dump/refs.rs:4617-4623 — before extracting anything, compare `crates/ibcmd-dump/src/mssql_dump/mod.rs` and `crates/ibcmd-dump/src/mssql_dump/refs.rs` as WHOLE FILES: this scan already matched 13 separate duplicated blocks between them, totalling at least 117 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:17208` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (7 lines × 3) crates/ibcmd-metadata-blob/src/lib.rs:5064 — crates/ibcmd-metadata-blob/src/lib.rs:5064-5071 | crates/ibcmd-metadata-blob/src/lib.rs:5229-5235 | crates/ibcmd-metadata-blob/src/lib.rs:8139-8146 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-metadata-blob/src/lib.rs:5064` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (7 lines × 3) crates/ibcmd-dump/src/mssql_dump/mod.rs:36967 — crates/ibcmd-dump/src/mssql_dump/mod.rs:36967-36973 | crates/ibcmd-dump/src/mssql_dump/source_assets.rs:4552-4558 | crates/ibcmd-dump/src/mssql_dump/source_assets.rs:4642-4648 — before extracting anything, compare `crates/ibcmd-dump/src/mssql_dump/mod.rs` and `crates/ibcmd-dump/src/mssql_dump/source_assets.rs` as WHOLE FILES: this scan already matched 5 separate duplicated blocks between them, totalling at least 36 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:36967` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (7 lines × 3) crates/ibcmd-restructure-engine/src/si.rs:528 — crates/ibcmd-restructure-engine/src/si.rs:528-534 | crates/ibcmd-restructure-engine/src/si.rs:626-632 | crates/ibcmd-restructure-engine/src/si.rs:717-723 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, `crates/ibcmd-restructure-engine/src/si.rs:525` calls `with_capacity` and `crates/ibcmd-restructure-engine/src/si.rs:625` does not — after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
  • Duplicated block (7 lines × 3) crates/ibcmd-xml/src/metadata/functional_option.rs:134 — crates/ibcmd-xml/src/metadata/functional_option.rs:134-140 | crates/ibcmd-xml/src/metadata/functional_options_parameter.rs:122-128 | crates/ibcmd-xml/src/metadata/session_parameter.rs:241-247 — before extracting anything, compare `crates/ibcmd-xml/src/metadata/functional_option.rs` and `crates/ibcmd-xml/src/metadata/functional_options_parameter.rs` as WHOLE FILES: this scan already matched 17 separate duplicated blocks between them, totalling at least 156 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (7 lines × 3) crates/ibcmd-compiler-families/src/compiler/families/form.rs:994 — crates/ibcmd-compiler-families/src/compiler/families/form.rs:994-1000 | crates/ibcmd-compiler-families/src/compiler/families/services.rs:2474-2480 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:2051-2057 — before extracting anything, compare `crates/ibcmd-compiler-families/src/compiler/families/services.rs` and `crates/ibcmd-compiler-families/src/compiler/families/simple.rs` as WHOLE FILES: this scan already matched 36 separate duplicated blocks between them, totalling at least 406 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/form.rs:994` it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows — the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members' bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run — a one-line delegation has no helper inside it to lift — so generate the run from the set it enumerates, or accept it and keep each member's own documentation with it.
  • Duplicated block (7 lines × 3) REDACTED:6467 — REDACTED:6467-6473 | REDACTED:6513-6519 | REDACTED:6565-6571 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `REDACTED:6467` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (7 lines × 3) crates/ibcmd-form-writer/src/lib.rs:21835 — crates/ibcmd-form-writer/src/lib.rs:21835-21841 | crates/ibcmd-form-writer/src/lib.rs:22171-22177 | crates/ibcmd-form-writer/src/lib.rs:23228-23234 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-form-writer/src/lib.rs:21835` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (7 lines × 3) src/commands/cf.rs:1306 — src/commands/cf.rs:1306-1312 | src/load.rs:394-400 | src/load.rs:635-641 — there are 3 copies across 2 file(s) — more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 3 sites; resolving a subset leaves the remainder to drift apart. Read the line range as the matched WINDOW rather than a finished unit: at `src/commands/cf.rs:1306` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • + 1 more in this group — see findings.md.
D3 · God Classes · TooManyFields · ×25
  • TooManyFields: FormChildItem crates/ibcmd-form-body/src/form_body.rs:1861 — TooManyFields — 266 stored fields. The bar is 30 stored fields; this is 236 over it, 8.87× the bar. This is width in DATA, not behaviour: every reader that takes the whole type couples to all of its fields, so a change to any one of them is a change every reader has to be checked against. To reduce it, group the fields that are read together by the same callers into a smaller type of their own, and have this one hold that type as a single member — each reader then names only the group it uses.
  • TooManyFields: FormXmlChildItem crates/ibcmd-form-writer/src/lib.rs:502 — TooManyFields — 145 stored fields. The bar is 30 stored fields; this is 115 over it, 4.83× the bar. This is width in DATA, not behaviour: every reader that takes the whole type couples to all of its fields, so a change to any one of them is a change every reader has to be checked against. To reduce it, group the fields that are read together by the same callers into a smaller type of their own, and have this one hold that type as a single member — each reader then names only the group it uses.
  • TooManyFields: MssqlDumpTimingReport crates/ibcmd-form-body/src/timing.rs:10 — TooManyFields — 89 stored fields. The bar is 30 stored fields; this is 59 over it, 2.97× the bar. This is width in DATA, not behaviour: every reader that takes the whole type couples to all of its fields, so a change to any one of them is a change every reader has to be checked against. To reduce it, group the fields that are read together by the same callers into a smaller type of their own, and have this one hold that type as a single member — each reader then names only the group it uses.
  • TooManyFields: MoxelChart crates/ibcmd-moxel/src/lib.rs:1533 — TooManyFields — 64 stored fields. The bar is 30 stored fields; this is 34 over it, 2.13× the bar. This is width in DATA, not behaviour: every reader that takes the whole type couples to all of its fields, so a change to any one of them is a change every reader has to be checked against. To reduce it, group the fields that are read together by the same callers into a smaller type of their own, and have this one hold that type as a single member — each reader then names only the group it uses.
  • TooManyFields: CatalogProperties crates/ibcmd-dump/src/mssql_dump/mod.rs:11260 — TooManyFields — 56 stored fields. The bar is 30 stored fields; this is 26 over it, 1.87× the bar. This is width in DATA, not behaviour: every reader that takes the whole type couples to all of its fields, so a change to any one of them is a change every reader has to be checked against. To reduce it, group the fields that are read together by the same callers into a smaller type of their own, and have this one hold that type as a single member — each reader then names only the group it uses.
  • TooManyFields: DcsInnerSchemaEvidencePolicy crates/ibcmd-schema/src/lib.rs:7487 — TooManyFields — 55 stored fields. The bar is 30 stored fields; this is 25 over it, 1.83× the bar. This is width in DATA, not behaviour: every reader that takes the whole type couples to all of its fields, so a change to any one of them is a change every reader has to be checked against. To reduce it, group the fields that are read together by the same callers into a smaller type of their own, and have this one hold that type as a single member — each reader then names only the group it uses.
  • TooManyFields: DumpRowContext crates/ibcmd-dump/src/mssql_dump/mod.rs:3754 — TooManyFields — 54 stored fields. The bar is 30 stored fields; this is 24 over it, 1.80× the bar. This is width in DATA, not behaviour: every reader that takes the whole type couples to all of its fields, so a change to any one of them is a change every reader has to be checked against. To reduce it, group the fields that are read together by the same callers into a smaller type of their own, and have this one hold that type as a single member — each reader then names only the group it uses.
  • TooManyFields: FormXmlBodyProperties crates/ibcmd-form-writer/src/lib.rs:121 — TooManyFields — 52 stored fields. The bar is 30 stored fields; this is 22 over it, 1.73× the bar. This is width in DATA, not behaviour: every reader that takes the whole type couples to all of its fields, so a change to any one of them is a change every reader has to be checked against. To reduce it, group the fields that are read together by the same callers into a smaller type of their own, and have this one hold that type as a single member — each reader then names only the group it uses.
  • TooManyFields: ChartOfCharacteristicTypesProperties crates/ibcmd-dump/src/mssql_dump/mod.rs:10766 — TooManyFields — 47 stored fields. The bar is 30 stored fields; this is 17 over it, 1.57× the bar. This is width in DATA, not behaviour: every reader that takes the whole type couples to all of its fields, so a change to any one of them is a change every reader has to be checked against. To reduce it, group the fields that are read together by the same callers into a smaller type of their own, and have this one hold that type as a single member — each reader then names only the group it uses.
  • TooManyFields: TaskProperties crates/ibcmd-dump/src/mssql_dump/mod.rs:11467 — TooManyFields — 47 stored fields. The bar is 30 stored fields; this is 17 over it, 1.57× the bar. This is width in DATA, not behaviour: every reader that takes the whole type couples to all of its fields, so a change to any one of them is a change every reader has to be checked against. To reduce it, group the fields that are read together by the same callers into a smaller type of their own, and have this one hold that type as a single member — each reader then names only the group it uses.
  • TooManyFields: ChartOfAccountsProperties crates/ibcmd-dump/src/mssql_dump/mod.rs:10670 — TooManyFields — 46 stored fields. The bar is 30 stored fields; this is 16 over it, 1.53× the bar. This is width in DATA, not behaviour: every reader that takes the whole type couples to all of its fields, so a change to any one of them is a change every reader has to be checked against. To reduce it, group the fields that are read together by the same callers into a smaller type of their own, and have this one hold that type as a single member — each reader then names only the group it uses.
  • TooManyFields: FormBodyProperties crates/ibcmd-form-body/src/form_body.rs:1349 — TooManyFields — 45 stored fields. The bar is 30 stored fields; this is 15 over it, 1.50× the bar. This is width in DATA, not behaviour: every reader that takes the whole type couples to all of its fields, so a change to any one of them is a change every reader has to be checked against. To reduce it, group the fields that are read together by the same callers into a smaller type of their own, and have this one hold that type as a single member — each reader then names only the group it uses.
  • TooManyFields: NativeFieldItem crates/ibcmd-form-native/src/lib.rs:1789 — TooManyFields — 44 stored fields. The bar is 30 stored fields; this is 14 over it, 1.47× the bar. This is width in DATA, not behaviour: every reader that takes the whole type couples to all of its fields, so a change to any one of them is a change every reader has to be checked against. To reduce it, group the fields that are read together by the same callers into a smaller type of their own, and have this one hold that type as a single member — each reader then names only the group it uses.
  • TooManyFields: NativeTableHead crates/ibcmd-form-native/src/lib.rs:5827 — TooManyFields — 44 stored fields. The bar is 30 stored fields; this is 14 over it, 1.47× the bar. This is width in DATA, not behaviour: every reader that takes the whole type couples to all of its fields, so a change to any one of them is a change every reader has to be checked against. To reduce it, group the fields that are read together by the same callers into a smaller type of their own, and have this one hold that type as a single member — each reader then names only the group it uses.
  • TooManyFields: BusinessProcessProperties crates/ibcmd-dump/src/mssql_dump/mod.rs:11416 — TooManyFields — 43 stored fields. The bar is 30 stored fields; this is 13 over it, 1.43× the bar. This is width in DATA, not behaviour: every reader that takes the whole type couples to all of its fields, so a change to any one of them is a change every reader has to be checked against. To reduce it, group the fields that are read together by the same callers into a smaller type of their own, and have this one hold that type as a single member — each reader then names only the group it uses.
  • TooManyFields: ChartOfCalculationTypesProperties crates/ibcmd-dump/src/mssql_dump/mod.rs:10720 — TooManyFields — 42 stored fields. The bar is 30 stored fields; this is 12 over it, 1.40× the bar. This is width in DATA, not behaviour: every reader that takes the whole type couples to all of its fields, so a change to any one of them is a change every reader has to be checked against. To reduce it, group the fields that are read together by the same callers into a smaller type of their own, and have this one hold that type as a single member — each reader then names only the group it uses.
  • TooManyFields: DocumentProperties crates/ibcmd-dump/src/mssql_dump/mod.rs:11361 — TooManyFields — 42 stored fields. The bar is 30 stored fields; this is 12 over it, 1.40× the bar. This is width in DATA, not behaviour: every reader that takes the whole type couples to all of its fields, so a change to any one of them is a change every reader has to be checked against. To reduce it, group the fields that are read together by the same callers into a smaller type of their own, and have this one hold that type as a single member — each reader then names only the group it uses.
  • TooManyFields: ExchangePlanProperties crates/ibcmd-dump/src/mssql_dump/mod.rs:10849 — TooManyFields — 40 stored fields. The bar is 30 stored fields; this is 10 over it, 1.33× the bar. This is width in DATA, not behaviour: every reader that takes the whole type couples to all of its fields, so a change to any one of them is a change every reader has to be checked against. To reduce it, group the fields that are read together by the same callers into a smaller type of their own, and have this one hold that type as a single member — each reader then names only the group it uses.
  • TooManyFields: MoxelSpreadsheet crates/ibcmd-moxel/src/lib.rs:686 — TooManyFields — 40 stored fields. The bar is 30 stored fields; this is 10 over it, 1.33× the bar. This is width in DATA, not behaviour: every reader that takes the whole type couples to all of its fields, so a change to any one of them is a change every reader has to be checked against. To reduce it, group the fields that are read together by the same callers into a smaller type of their own, and have this one hold that type as a single member — each reader then names only the group it uses.
  • TooManyFields: MetadataChildProperties crates/ibcmd-dump/src/mssql_dump/mod.rs:11056 — TooManyFields — 39 stored fields. The bar is 30 stored fields; this is 9 over it, 1.30× the bar. This is width in DATA, not behaviour: every reader that takes the whole type couples to all of its fields, so a change to any one of them is a change every reader has to be checked against. To reduce it, group the fields that are read together by the same callers into a smaller type of their own, and have this one hold that type as a single member — each reader then names only the group it uses.
  • TooManyFields: NativeButtonItem crates/ibcmd-form-native/src/lib.rs:6947 — TooManyFields — 38 stored fields. The bar is 30 stored fields; this is 8 over it, 1.27× the bar. This is width in DATA, not behaviour: every reader that takes the whole type couples to all of its fields, so a change to any one of them is a change every reader has to be checked against. To reduce it, group the fields that are read together by the same callers into a smaller type of their own, and have this one hold that type as a single member — each reader then names only the group it uses.
  • TooManyFields: DcsConditionalAppearanceEvidencePolicy crates/ibcmd-schema/src/lib.rs:7809 — TooManyFields — 36 stored fields. The bar is 30 stored fields; this is 6 over it, 1.20× the bar. This is width in DATA, not behaviour: every reader that takes the whole type couples to all of its fields, so a change to any one of them is a change every reader has to be checked against. To reduce it, group the fields that are read together by the same callers into a smaller type of their own, and have this one hold that type as a single member — each reader then names only the group it uses.
  • TooManyFields: MssqlDumpConfigArgs crates/ibcmd-dump/src/mssql_dump/args.rs:56 — TooManyFields — 34 stored fields. The bar is 30 stored fields; this is 4 over it, 1.13× the bar. This is width in DATA, not behaviour: every reader that takes the whole type couples to all of its fields, so a change to any one of them is a change every reader has to be checked against. To reduce it, group the fields that are read together by the same callers into a smaller type of their own, and have this one hold that type as a single member — each reader then names only the group it uses.
  • TooManyFields: DcsSettingsSourceOwnedEvidencePolicy crates/ibcmd-schema/src/lib.rs:7056 — TooManyFields — 33 stored fields. The bar is 30 stored fields; this is 3 over it, 1.10× the bar. This is width in DATA, not behaviour: every reader that takes the whole type couples to all of its fields, so a change to any one of them is a change every reader has to be checked against. To reduce it, group the fields that are read together by the same callers into a smaller type of their own, and have this one hold that type as a single member — each reader then names only the group it uses.
  • TooManyFields: ScriptInputs REDACTED:215 — TooManyFields — 32 stored fields. The bar is 30 stored fields; this is 2 over it, 1.07× the bar. This is width in DATA, not behaviour: every reader that takes the whole type couples to all of its fields, so a change to any one of them is a change every reader has to be checked against. To reduce it, group the fields that are read together by the same callers into a smaller type of their own, and have this one hold that type as a single member — each reader then names only the group it uses.
D4 · Code Duplication · Edited copy of a member (12 corresponding lines) · ×25
  • Edited copy of a member (12 corresponding lines) crates/ibcmd-v8/src/format15.rs:243 — crates/ibcmd-v8/src/format15.rs:243-254 | crates/ibcmd-v8/src/format16.rs:326-337 — These two members are one piece of code written twice and then edited apart: 12 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (12 corresponding lines) crates/ibcmd-form-body/src/form_body.rs:38998 — crates/ibcmd-form-body/src/form_body.rs:38998-39009 | crates/ibcmd-form-body/src/form_body.rs:40123-40138 — These two members are one piece of code written twice and then edited apart: 12 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (12 corresponding lines) crates/ibcmd-form-body/src/form_body.rs:28617 — crates/ibcmd-form-body/src/form_body.rs:28617-28628 | crates/ibcmd-form-body/src/form_body.rs:28632-28644 — These two members are one piece of code written twice and then edited apart: 12 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (12 corresponding lines) crates/ibcmd-form-body/src/form_body.rs:22228 — crates/ibcmd-form-body/src/form_body.rs:22228-22239 | crates/ibcmd-form-body/src/form_body.rs:22269-22284 — These two members are one piece of code written twice and then edited apart: 12 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (12 corresponding lines) crates/ibcmd-1c-text/src/fields.rs:225 — crates/ibcmd-1c-text/src/fields.rs:225-237 | crates/ibcmd-metadata-model/src/metadata_model/bodies_flowchart.rs:915-926 — These two members are one piece of code written twice and then edited apart: 12 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (12 corresponding lines) crates/ibcmd-metadata-model/src/metadata_model/registers.rs:1054 — crates/ibcmd-metadata-model/src/metadata_model/registers.rs:1054-1065 | crates/ibcmd-metadata-model/src/metadata_model/registers.rs:1207-1223 — These two members are one piece of code written twice and then edited apart: 12 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (12 corresponding lines) crates/ibcmd-dump/src/mssql_dump/cas.rs:789 — crates/ibcmd-dump/src/mssql_dump/cas.rs:789-801 | REDACTED:1117-1128 — These two members are one piece of code written twice and then edited apart: 12 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (12 corresponding lines) crates/ibcmd-metadata-blob/src/lib.rs:495 — crates/ibcmd-metadata-blob/src/lib.rs:495-510 | crates/ibcmd-metadata-blob/src/lib.rs:525-536 — These two members are one piece of code written twice and then edited apart: 12 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (12 corresponding lines) crates/ibcmd-dump/src/mssql_dump/mod.rs:15957 — crates/ibcmd-dump/src/mssql_dump/mod.rs:15957-15968 | crates/ibcmd-dump/src/mssql_dump/mod.rs:35530-35542 — These two members are one piece of code written twice and then edited apart: 12 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (12 corresponding lines) crates/ibcmd-config-apply/src/mssql_config_apply/mod.rs:526 — crates/ibcmd-config-apply/src/mssql_config_apply/mod.rs:526-537 | REDACTED:225-236 — These two members are one piece of code written twice and then edited apart: 12 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (12 corresponding lines) crates/ibcmd-compiler-families/src/compiler/families/services.rs:3491 — crates/ibcmd-compiler-families/src/compiler/families/services.rs:3491-3502 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:2508-2519 — These two members are one piece of code written twice and then edited apart: 12 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (12 corresponding lines) crates/ibcmd-form-body/src/form_body.rs:7060 — crates/ibcmd-form-body/src/form_body.rs:7060-7075 | crates/ibcmd-form-writer/src/lib.rs:1936-1947 — These two members are one piece of code written twice and then edited apart: 12 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (12 corresponding lines) crates/ibcmd-form-body/src/form_body.rs:2826 — crates/ibcmd-form-body/src/form_body.rs:2826-2837 | crates/ibcmd-form-body/src/form_body.rs:2864-2897 — These two members are one piece of code written twice and then edited apart: 12 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (12 corresponding lines) crates/ibcmd-compiler-families/src/compiler/families/commands.rs:1081 — crates/ibcmd-compiler-families/src/compiler/families/commands.rs:1081-1095 | crates/ibcmd-metadata-blob/src/lib.rs:6968-6979 — These two members are one piece of code written twice and then edited apart: 12 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (12 corresponding lines) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:3583 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:3583-3594 | crates/ibcmd-compiler-families/src/compiler/families/utility.rs:1921-1932 — These two members are one piece of code written twice and then edited apart: 12 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (12 corresponding lines) src/load/external.rs:380 — src/load/external.rs:380-391 | src/mssql_extension_tree_load.rs:64-76 — These two members are one piece of code written twice and then edited apart: 12 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (12 corresponding lines) crates/ibcmd-compiler/src/compiler/bodies/mxl_native.rs:95 — crates/ibcmd-compiler/src/compiler/bodies/mxl_native.rs:95-106 | crates/ibcmd-form-writer/src/lib.rs:24103-24115 — These two members are one piece of code written twice and then edited apart: 12 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (12 corresponding lines) crates/ibcmd-metadata-model/src/metadata_model/export.rs:608 — crates/ibcmd-metadata-model/src/metadata_model/export.rs:608-619 | crates/ibcmd-xml/src/config_dump_info.rs:292-306 — These two members are one piece of code written twice and then edited apart: 12 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (12 corresponding lines) crates/ibcmd-dump/src/mssql_dump/mod.rs:44413 — crates/ibcmd-dump/src/mssql_dump/mod.rs:44413-44424 | crates/ibcmd-dump/src/mssql_dump/mod.rs:44430-44449 — These two members are one piece of code written twice and then edited apart: 12 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (12 corresponding lines) REDACTED:952 — REDACTED:952-963 | src/mssql_extension_load.rs:971-983 — These two members are one piece of code written twice and then edited apart: 12 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (12 corresponding lines) crates/ibcmd-dump/src/mssql_dump/mod.rs:26390 — crates/ibcmd-dump/src/mssql_dump/mod.rs:26390-26401 | crates/ibcmd-dump/src/mssql_dump/mod.rs:26406-26417 — These two members are one piece of code written twice and then edited apart: 12 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (12 corresponding lines) crates/ibcmd-compiler/src/compiler/bootstrap.rs:869 — crates/ibcmd-compiler/src/compiler/bootstrap.rs:869-880 | crates/ibcmd-xml/src/source_comparison.rs:76-87 — These two members are one piece of code written twice and then edited apart: 12 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (12 corresponding lines) crates/ibcmd-xml/src/metadata/configuration_mobile.rs:31 — crates/ibcmd-xml/src/metadata/configuration_mobile.rs:31-42 | crates/ibcmd-xml/src/metadata/configuration_v85_projection.rs:28-39 — These two members are one piece of code written twice and then edited apart: 12 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (12 corresponding lines) crates/ibcmd-moxel/src/lib.rs:7175 — crates/ibcmd-moxel/src/lib.rs:7175-7188 | crates/ibcmd-form-body/src/form_body.rs:39612-39623 — These two members are one piece of code written twice and then edited apart: 12 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (12 corresponding lines) crates/ibcmd-1c-vocab/src/role_rights.rs:80 — crates/ibcmd-1c-vocab/src/role_rights.rs:80-91 | crates/ibcmd-metadata-blob/src/role_rights_writer.rs:1211-1222 — These two members are one piece of code written twice and then edited apart: 12 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copy of a member (10 corresponding lines) · ×25
  • Edited copy of a member (10 corresponding lines) src/load.rs:204 — src/load.rs:204-213 | src/mssql_extension_tree_load.rs:278-288 — These two members are one piece of code written twice and then edited apart: 10 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (10 corresponding lines) crates/ibcmd-xml/src/metadata/constant.rs:550 — crates/ibcmd-xml/src/metadata/constant.rs:550-563 | crates/ibcmd-xml/src/metadata/session_parameter.rs:460-469 — These two members are one piece of code written twice and then edited apart: 10 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (10 corresponding lines) crates/ibcmd-dump/src/mssql_dump/mod.rs:20754 — crates/ibcmd-dump/src/mssql_dump/mod.rs:20754-20763 | crates/ibcmd-dump/src/mssql_dump/mod.rs:22453-22463 — These two members are one piece of code written twice and then edited apart: 10 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (10 corresponding lines) crates/ibcmd-form-body/src/form_body.rs:4132 — crates/ibcmd-form-body/src/form_body.rs:4132-4141 | crates/ibcmd-form-body/src/form_body.rs:4148-4164 — These two members are one piece of code written twice and then edited apart: 10 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (10 corresponding lines) crates/ibcmd-core/src/storage.rs:1233 — crates/ibcmd-core/src/storage.rs:1233-1242 | crates/ibcmd-core/src/storage.rs:1756-1766 — These two members are one piece of code written twice and then edited apart: 10 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (10 corresponding lines) crates/ibcmd-dump/src/mssql_dump/source_assets.rs:3522 — crates/ibcmd-dump/src/mssql_dump/source_assets.rs:3522-3532 | crates/ibcmd-dump/src/mssql_dump/source_assets.rs:3549-3558 — These two members are one piece of code written twice and then edited apart: 10 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (10 corresponding lines) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:2844 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:2844-2853 | crates/ibcmd-compiler-families/src/compiler/families/utility.rs:1458-1467 — These two members are one piece of code written twice and then edited apart: 10 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (10 corresponding lines) crates/ibcmd-compiler-families/src/compiler/families/native.rs:712 — crates/ibcmd-compiler-families/src/compiler/families/native.rs:712-721 | crates/ibcmd-compiler-families/src/compiler/families/native.rs:1058-1067 — These two members are one piece of code written twice and then edited apart: 10 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (10 corresponding lines) crates/ibcmd-form-writer/src/lib.rs:985 — crates/ibcmd-form-writer/src/lib.rs:985-994 | crates/ibcmd-metadata-blob/src/lib.rs:1517-1526 — These two members are one piece of code written twice and then edited apart: 10 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (10 corresponding lines) REDACTED:1858 — REDACTED:1858-1867 | REDACTED:2961-2978 — These two members are one piece of code written twice and then edited apart: 10 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (10 corresponding lines) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:4515 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:4515-4524 | crates/ibcmd-compiler-families/src/compiler/families/utility.rs:2674-2683 — These two members are one piece of code written twice and then edited apart: 10 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (10 corresponding lines) crates/ibcmd-compiler-families/src/compiler/families/commands.rs:1193 — crates/ibcmd-compiler-families/src/compiler/families/commands.rs:1193-1202 | crates/ibcmd-compiler/src/compiler/bootstrap.rs:1329-1338 — These two members are one piece of code written twice and then edited apart: 10 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (10 corresponding lines) crates/ibcmd-filedb/src/pager.rs:147 — crates/ibcmd-filedb/src/pager.rs:147-156 | crates/ibcmd-filedb/src/pager.rs:158-168 — These two members are one piece of code written twice and then edited apart: 10 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (10 corresponding lines) crates/ibcmd-1c-text/src/braced.rs:120 — crates/ibcmd-1c-text/src/braced.rs:120-129 | crates/ibcmd-dump/src/mssql_dump/extension/mod.rs:317-326 — These two members are one piece of code written twice and then edited apart: 10 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (10 corresponding lines) crates/ibcmd-xml/src/metadata/external_data_source.rs:22 — crates/ibcmd-xml/src/metadata/external_data_source.rs:22-31 | crates/ibcmd-xml/src/metadata/external_objects.rs:113-124 — These two members are one piece of code written twice and then edited apart: 10 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (10 corresponding lines) crates/ibcmd-form-body/src/layout_8_5_1.rs:88 — crates/ibcmd-form-body/src/layout_8_5_1.rs:88-98 | crates/ibcmd-form-writer/src/form/load_8_5_1.rs:1103-1112 — These two members are one piece of code written twice and then edited apart: 10 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (10 corresponding lines) crates/ibcmd-dump/src/mssql_dump/mod.rs:35030 — crates/ibcmd-dump/src/mssql_dump/mod.rs:35030-35041 | crates/ibcmd-dump/src/mssql_dump/mod.rs:35061-35070 — These two members are one piece of code written twice and then edited apart: 10 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (10 corresponding lines) crates/ibcmd-core/src/dcs_schema.rs:1331 — crates/ibcmd-core/src/dcs_schema.rs:1331-1340 | crates/ibcmd-core/src/dcs_schema.rs:1587-1601 — These two members are one piece of code written twice and then edited apart: 10 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (10 corresponding lines) crates/ibcmd-form-native/src/lib.rs:435 — crates/ibcmd-form-native/src/lib.rs:435-444 | crates/ibcmd-form-writer/src/form_chart.rs:1633-1642 — These two members are one piece of code written twice and then edited apart: 10 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (10 corresponding lines) crates/ibcmd-compiler-families/src/compiler/families/assets.rs:1367 — crates/ibcmd-compiler-families/src/compiler/families/assets.rs:1367-1378 | REDACTED:684-693 — These two members are one piece of code written twice and then edited apart: 10 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (10 corresponding lines) crates/ibcmd-cf/src/overlay.rs:337 — crates/ibcmd-cf/src/overlay.rs:337-346 | crates/ibcmd-cf/src/writer.rs:446-456 — These two members are one piece of code written twice and then edited apart: 10 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (10 corresponding lines) crates/ibcmd-dump/src/mssql_dump/mod.rs:17235 — crates/ibcmd-dump/src/mssql_dump/mod.rs:17235-17246 | crates/ibcmd-schema/src/lib.rs:18587-18596 — These two members are one piece of code written twice and then edited apart: 10 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (10 corresponding lines) crates/ibcmd-form-writer/src/form_chart.rs:1870 — crates/ibcmd-form-writer/src/form_chart.rs:1870-1879 | crates/ibcmd-form-writer/src/form_planner.rs:476-485 — These two members are one piece of code written twice and then edited apart: 10 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (10 corresponding lines) crates/ibcmd-form-body/src/dcs.rs:3243 — crates/ibcmd-form-body/src/dcs.rs:3243-3254 | crates/ibcmd-form-writer/src/dynamic_list.rs:51-60 — These two members are one piece of code written twice and then edited apart: 10 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (10 corresponding lines) crates/ibcmd-form-body/src/form_body.rs:20575 — crates/ibcmd-form-body/src/form_body.rs:20575-20584 | crates/ibcmd-form-schema/src/lib.rs:5401-5410 — These two members are one piece of code written twice and then edited apart: 10 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
IC1 · Incompleteness & stubs · Unfinished branch · ×25
  • Unfinished branch — a todo!() / unimplemented!() arm in a real function crates/ibcmd-config-apply/src/mssql_config_apply/mod.rs:564 — `require_no_unfinished_operation` does real work, but one of its branches is `Err` with a "not implemented" message — a case that was never written, and a panic the first time it is reached. Implement the case, or return an error that says why it is not handled.
  • Unfinished branch — a todo!() / unimplemented!() arm in a real function crates/ibcmd-form-writer/src/lib.rs:23530 — `parse_metadata_type_pattern_element` does real work, but one of its branches is `anyhow!` with a "not implemented" message — a case that was never written, and a panic the first time it is reached. Implement the case, or return an error that says why it is not handled.
  • Unfinished branch — a todo!() / unimplemented!() arm in a real function crates/ibcmd-form-writer/src/lib.rs:23541 — `parse_metadata_type_pattern_element` does real work, but one of its branches is `anyhow!` with a "not implemented" message — a case that was never written, and a panic the first time it is reached. Implement the case, or return an error that says why it is not handled.
  • Unfinished branch — a todo!() / unimplemented!() arm in a real function crates/ibcmd-form-writer/src/lib.rs:23559 — `parse_metadata_type_pattern_element` does real work, but one of its branches is `Err` with a "not implemented" message — a case that was never written, and a panic the first time it is reached. Implement the case, or return an error that says why it is not handled.
  • Unfinished branch — a todo!() / unimplemented!() arm in a real function crates/ibcmd-metadata-blob/src/lib.rs:6942 — `parse_common_command_picture` does real work, but one of its branches is `Err` with a "not implemented" message — a case that was never written, and a panic the first time it is reached. Implement the case, or return an error that says why it is not handled.
  • Unfinished branch — a todo!() / unimplemented!() arm in a real function crates/ibcmd-metadata-model/src/metadata_model/external_data_source.rs:326 — `function_element` does real work, but one of its branches is `bail!` with a "not implemented" message — a case that was never written, and a panic the first time it is reached. Implement the case, or return an error that says why it is not handled.
  • Unfinished branch — a todo!() / unimplemented!() arm in a real function crates/ibcmd-xml/src/metadata/business_objects.rs:1240 — `encode_business_object` does real work, but one of its branches is `Err` with a "not implemented" message — a case that was never written, and a panic the first time it is reached. Implement the case, or return an error that says why it is not handled.
  • Unfinished branch — a todo!() / unimplemented!() arm in a real function crates/ibcmd-xml/src/metadata/common_objects.rs:422 — `encode_common_object` does real work, but one of its branches is `Err` with a "not implemented" message — a case that was never written, and a panic the first time it is reached. Implement the case, or return an error that says why it is not handled.
  • Unfinished branch — a todo!() / unimplemented!() arm in a real function crates/ibcmd-xml/src/metadata/functional_option.rs:352 — `encode_functional_option` does real work, but one of its branches is `Err` with a "not implemented" message — a case that was never written, and a panic the first time it is reached. Implement the case, or return an error that says why it is not handled.
  • Unfinished branch — a todo!() / unimplemented!() arm in a real function crates/ibcmd-xml/src/metadata/functional_options_parameter.rs:338 — `encode_functional_options_parameter` does real work, but one of its branches is `Err` with a "not implemented" message — a case that was never written, and a panic the first time it is reached. Implement the case, or return an error that says why it is not handled.
  • Unfinished branch — a todo!() / unimplemented!() arm in a real function crates/ibcmd-xml/src/metadata/hierarchical_objects.rs:840 — `encode_hierarchical_object` does real work, but one of its branches is `Err` with a "not implemented" message — a case that was never written, and a panic the first time it is reached. Implement the case, or return an error that says why it is not handled.
  • Unfinished branch — a todo!() / unimplemented!() arm in a real function crates/ibcmd-xml/src/metadata/register_objects.rs:1027 — `encode_register_object` does real work, but one of its branches is `Err` with a "not implemented" message — a case that was never written, and a panic the first time it is reached. Implement the case, or return an error that says why it is not handled.
  • Unfinished branch — a todo!() / unimplemented!() arm in a real function crates/ibcmd-xml/src/metadata/services.rs:2537 — `encode_scheduled_job` does real work, but one of its branches is `Err` with a "not implemented" message — a case that was never written, and a panic the first time it is reached. Implement the case, or return an error that says why it is not handled.
  • Unfinished branch — a todo!() / unimplemented!() arm in a real function crates/ibcmd-xml/src/metadata/services.rs:2581 — `encode_event_subscription` does real work, but one of its branches is `Err` with a "not implemented" message — a case that was never written, and a panic the first time it is reached. Implement the case, or return an error that says why it is not handled.
  • Unfinished branch — a todo!() / unimplemented!() arm in a real function crates/ibcmd-xml/src/metadata/services.rs:2624 — `encode_xdto_package` does real work, but one of its branches is `Err` with a "not implemented" message — a case that was never written, and a panic the first time it is reached. Implement the case, or return an error that says why it is not handled.
  • Unfinished branch — a todo!() / unimplemented!() arm in a real function crates/ibcmd-xml/src/metadata/services.rs:2667 — `encode_http_service` does real work, but one of its branches is `Err` with a "not implemented" message — a case that was never written, and a panic the first time it is reached. Implement the case, or return an error that says why it is not handled.
  • Unfinished branch — a todo!() / unimplemented!() arm in a real function crates/ibcmd-xml/src/metadata/services.rs:2710 — `encode_web_service` does real work, but one of its branches is `Err` with a "not implemented" message — a case that was never written, and a panic the first time it is reached. Implement the case, or return an error that says why it is not handled.
  • Unfinished branch — a todo!() / unimplemented!() arm in a real function crates/ibcmd-xml/src/metadata/services.rs:2753 — `encode_ws_reference` does real work, but one of its branches is `Err` with a "not implemented" message — a case that was never written, and a panic the first time it is reached. Implement the case, or return an error that says why it is not handled.
  • Unfinished branch — a todo!() / unimplemented!() arm in a real function crates/ibcmd-xml/src/metadata/services.rs:2797 — `encode_integration_service` does real work, but one of its branches is `Err` with a "not implemented" message — a case that was never written, and a panic the first time it is reached. Implement the case, or return an error that says why it is not handled.
  • Unfinished branch — a todo!() / unimplemented!() arm in a real function crates/ibcmd-xml/src/metadata/session_parameter.rs:738 — `encode_type_pattern_family` does real work, but one of its branches is `Err` with a "not implemented" message — a case that was never written, and a panic the first time it is reached. Implement the case, or return an error that says why it is not handled.
  • Unfinished branch — a todo!() / unimplemented!() arm in a real function crates/ibcmd-xml/src/metadata/utility_objects.rs:714 — `encode_utility_object` does real work, but one of its branches is `Err` with a "not implemented" message — a case that was never written, and a panic the first time it is reached. Implement the case, or return an error that says why it is not handled.
  • Unfinished branch — a todo!() / unimplemented!() arm in a real function src/infobase.rs:364 — `export_config_policy` does real work, but one of its branches is `bail!` with a "not implemented" message — a case that was never written, and a panic the first time it is reached. Implement the case, or return an error that says why it is not handled.
  • Unfinished branch — a todo!() / unimplemented!() arm in a real function src/infobase/export_commands.rs:25 — `info` does real work, but one of its branches is `bail!` with a "not implemented" message — a case that was never written, and a panic the first time it is reached. Implement the case, or return an error that says why it is not handled.
  • Unfinished branch — a todo!() / unimplemented!() arm in a real function src/infobase/export_commands.rs:218 — `objects` does real work, but one of its branches is `bail!` with a "not implemented" message — a case that was never written, and a panic the first time it is reached. Implement the case, or return an error that says why it is not handled.
  • Unfinished branch — a todo!() / unimplemented!() arm in a real function src/mssql/cf_load_stage.rs:75 — `load_config_command` does real work, but one of its branches is `bail!` with a "not implemented" message — a case that was never written, and a panic the first time it is reached. Implement the case, or return an error that says why it is not handled.
D1 · Cyclomatic Complexity · ibcmd_moxel · ×24
  • ibcmd_moxel::parse_moxel_spreadsheet_text_with_line_trace (cyclomatic 82) crates/ibcmd-moxel/src/lib.rs:2111 — ibcmd_moxel::parse_moxel_spreadsheet_text_with_line_trace has cyclomatic complexity 82 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
  • ibcmd_moxel::render_moxel_spreadsheet_xml (cyclomatic 39) crates/ibcmd-moxel/src/lib.rs:11661 — ibcmd_moxel::render_moxel_spreadsheet_xml has cyclomatic complexity 39 (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. This is NOT this file's highest cyclomatic complexity: ibcmd_moxel::parse_moxel_web_color (cyclomatic 59) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • ibcmd_moxel::parse_moxel_lines_with_raw_spans (cyclomatic 31) crates/ibcmd-moxel/src/lib.rs:5362 — ibcmd_moxel::parse_moxel_lines_with_raw_spans has cyclomatic complexity 31 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages. This is NOT this file's highest cyclomatic complexity: ibcmd_moxel::parse_moxel_web_color (cyclomatic 59) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • ibcmd_moxel::parse_moxel_chart (cyclomatic 31) crates/ibcmd-moxel/src/lib.rs:6532 — ibcmd_moxel::parse_moxel_chart has cyclomatic complexity 31 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages. This is NOT this file's highest cyclomatic complexity: ibcmd_moxel::parse_moxel_web_color (cyclomatic 59) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • ibcmd_moxel::parse_moxel_gantt_chart (cyclomatic 31) crates/ibcmd-moxel/src/lib.rs:7335 — ibcmd_moxel::parse_moxel_gantt_chart has cyclomatic complexity 31 (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. This is NOT this file's highest cyclomatic complexity: ibcmd_moxel::parse_moxel_web_color (cyclomatic 59) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • ibcmd_moxel::parse_moxel_print_settings_field (cyclomatic 31) crates/ibcmd-moxel/src/lib.rs:8997 — ibcmd_moxel::parse_moxel_print_settings_field has cyclomatic complexity 31 (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 — the same kind of value, with no behaviour of its own — 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. This is NOT this file's highest cyclomatic complexity: ibcmd_moxel::parse_moxel_web_color (cyclomatic 59) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • ibcmd_moxel::moxel_output_format_indices (cyclomatic 29) crates/ibcmd-moxel/src/lib.rs:12116 — ibcmd_moxel::moxel_output_format_indices 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. This is NOT this file's highest cyclomatic complexity: ibcmd_moxel::parse_moxel_web_color (cyclomatic 59) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • ibcmd_moxel::push_moxel_row_xml (cyclomatic 28) crates/ibcmd-moxel/src/lib.rs:15009 — ibcmd_moxel::push_moxel_row_xml 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. This is NOT this file's highest cyclomatic complexity: ibcmd_moxel::parse_moxel_web_color (cyclomatic 59) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • ibcmd_moxel::parse_moxel_number_format_refs (cyclomatic 25) crates/ibcmd-moxel/src/lib.rs:9923 — ibcmd_moxel::parse_moxel_number_format_refs 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. This is NOT this file's highest cyclomatic complexity: ibcmd_moxel::parse_moxel_web_color (cyclomatic 59) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • ibcmd_moxel::parse_moxel_line_table (cyclomatic 24) crates/ibcmd-moxel/src/lib.rs:5264 — ibcmd_moxel::parse_moxel_line_table 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 — the same kind of value, with no behaviour of its own — 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. This is NOT this file's highest cyclomatic complexity: ibcmd_moxel::parse_moxel_web_color (cyclomatic 59) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • ibcmd_moxel::parse_moxel_rows (cyclomatic 22) crates/ibcmd-moxel/src/lib.rs:3877 — ibcmd_moxel::parse_moxel_rows 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's highest cyclomatic complexity: ibcmd_moxel::parse_moxel_web_color (cyclomatic 59) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • ibcmd_moxel::moxel_first_use_source_order (cyclomatic 22) crates/ibcmd-moxel/src/lib.rs:12409 — ibcmd_moxel::moxel_first_use_source_order has cyclomatic complexity 22 (threshold 15). Of this number, 19 points are the body's 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. This is NOT this file's highest cyclomatic complexity: ibcmd_moxel::parse_moxel_web_color (cyclomatic 59) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • ibcmd_moxel::parse_moxel_font (cyclomatic 21) crates/ibcmd-moxel/src/lib.rs:5043 — ibcmd_moxel::parse_moxel_font has cyclomatic complexity 21 (threshold 15). To reduce it, separate the branches: extract each independent case into its own named function so the top-level body reads as a short sequence of named decisions. This is NOT this file's highest cyclomatic complexity: ibcmd_moxel::parse_moxel_web_color (cyclomatic 59) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • ibcmd_moxel::normalize_moxel_chart_decimal (cyclomatic 21) crates/ibcmd-moxel/src/lib.rs:8408 — ibcmd_moxel::normalize_moxel_chart_decimal has cyclomatic complexity 21 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages. This is NOT this file's highest cyclomatic complexity: ibcmd_moxel::parse_moxel_web_color (cyclomatic 59) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • ibcmd_moxel::moxel_sparse_source_output_order (cyclomatic 21) crates/ibcmd-moxel/src/lib.rs:12029 — ibcmd_moxel::moxel_sparse_source_output_order 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's highest cyclomatic complexity: ibcmd_moxel::parse_moxel_web_color (cyclomatic 59) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • ibcmd_moxel::parse_moxel_column_sets_with_source_format_order (cyclomatic 19) crates/ibcmd-moxel/src/lib.rs:3090 — ibcmd_moxel::parse_moxel_column_sets_with_source_format_order 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. This is NOT this file's highest cyclomatic complexity: ibcmd_moxel::parse_moxel_web_color (cyclomatic 59) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • ibcmd_moxel::parse_moxel_drawing (cyclomatic 19) crates/ibcmd-moxel/src/lib.rs:6368 — ibcmd_moxel::parse_moxel_drawing 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 — the same kind of value, with no behaviour of its own — 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. This is NOT this file's highest cyclomatic complexity: ibcmd_moxel::parse_moxel_web_color (cyclomatic 59) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • ibcmd_moxel::parse_moxel_format_table (cyclomatic 19) crates/ibcmd-moxel/src/lib.rs:9434 — ibcmd_moxel::parse_moxel_format_table 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. This is NOT this file's highest cyclomatic complexity: ibcmd_moxel::parse_moxel_web_color (cyclomatic 59) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • ibcmd_moxel::parse_moxel_cell (cyclomatic 18) crates/ibcmd-moxel/src/lib.rs:4457 — ibcmd_moxel::parse_moxel_cell has cyclomatic complexity 18 (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 — the same kind of value, with no behaviour of its own — 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. This is NOT this file's highest cyclomatic complexity: ibcmd_moxel::parse_moxel_web_color (cyclomatic 59) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • ibcmd_moxel::parse_moxel_value_type_item (cyclomatic 17) crates/ibcmd-moxel/src/lib.rs:8730 — ibcmd_moxel::parse_moxel_value_type_item 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 — the same kind of value, with no behaviour of its own — 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. This is NOT this file's highest cyclomatic complexity: ibcmd_moxel::parse_moxel_web_color (cyclomatic 59) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • ibcmd_moxel::parse_moxel_equal_width_only_format_table (cyclomatic 17) crates/ibcmd-moxel/src/lib.rs:9528 — ibcmd_moxel::parse_moxel_equal_width_only_format_table 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's highest cyclomatic complexity: ibcmd_moxel::parse_moxel_web_color (cyclomatic 59) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • ibcmd_moxel::push_moxel_format_body_xml (cyclomatic 17) crates/ibcmd-moxel/src/lib.rs:13279 — ibcmd_moxel::push_moxel_format_body_xml 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's highest cyclomatic complexity: ibcmd_moxel::parse_moxel_web_color (cyclomatic 59) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • ibcmd_moxel::parse_moxel_chart_color (cyclomatic 16) crates/ibcmd-moxel/src/lib.rs:7599 — ibcmd_moxel::parse_moxel_chart_color 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 — the same kind of value, with no behaviour of its own — 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. This is NOT this file's highest cyclomatic complexity: ibcmd_moxel::parse_moxel_web_color (cyclomatic 59) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • ibcmd_moxel::push_moxel_drawing_xml (cyclomatic 16) crates/ibcmd-moxel/src/lib.rs:13724 — ibcmd_moxel::push_moxel_drawing_xml 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 — the same kind of value, with no behaviour of its own — 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. This is NOT this file's highest cyclomatic complexity: ibcmd_moxel::parse_moxel_web_color (cyclomatic 59) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
D4 · Code Duplication · Edited copy of a member (7 corresponding lines) · ×24
  • Edited copy of a member (7 corresponding lines) crates/ibcmd-moxel/src/lib.rs:8545 — crates/ibcmd-moxel/src/lib.rs:8545-8555 | crates/ibcmd-moxel/src/lib.rs:8557-8563 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (7 corresponding lines) src/file_infobase.rs:432 — src/file_infobase.rs:432-438 | src/infobase.rs:825-831 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (7 corresponding lines) crates/ibcmd-metadata-model/src/metadata_model/common_export.rs:166 — crates/ibcmd-metadata-model/src/metadata_model/common_export.rs:166-172 | crates/ibcmd-metadata-model/src/metadata_model/forms_export.rs:292-298 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (7 corresponding lines) src/dropin/extension.rs:166 — src/dropin/extension.rs:166-172 | src/dropin/extension.rs:174-186 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (7 corresponding lines) crates/ibcmd-dump/src/mssql_dump/model_export.rs:233 — crates/ibcmd-dump/src/mssql_dump/model_export.rs:233-239 | crates/ibcmd-dump/src/mssql_dump/model_export.rs:245-252 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (7 corresponding lines) src/external/rename.rs:23 — src/external/rename.rs:23-29 | src/external/rename.rs:150-157 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (7 corresponding lines) crates/ibcmd-xml/src/metadata/services.rs:1030 — crates/ibcmd-xml/src/metadata/services.rs:1030-1036 | crates/ibcmd-xml/src/metadata/constant.rs:297-303 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (7 corresponding lines) crates/ibcmd-form-schema/src/lib.rs:7246 — crates/ibcmd-form-schema/src/lib.rs:7246-7258 | crates/ibcmd-form-schema/src/lib.rs:8823-8829 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (7 corresponding lines) crates/ibcmd-form-writer/src/lib.rs:23826 — crates/ibcmd-form-writer/src/lib.rs:23826-23834 | REDACTED:7613-7619 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (7 corresponding lines) crates/ibcmd-metadata-model/src/metadata_model/common_export.rs:103 — crates/ibcmd-metadata-model/src/metadata_model/common_export.rs:103-109 | crates/ibcmd-metadata-model/src/metadata_model/simple_export.rs:77-83 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (7 corresponding lines) REDACTED:650 — REDACTED:650-657 | src/external/header.rs:130-136 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (7 corresponding lines) crates/ibcmd-apply-check/src/apply_check/check.rs:752 — crates/ibcmd-apply-check/src/apply_check/check.rs:752-761 | crates/ibcmd-apply-check/src/apply_check/trees.rs:382-388 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (7 corresponding lines) crates/ibcmd-form-body/src/form_body.rs:16916 — crates/ibcmd-form-body/src/form_body.rs:16916-16922 | crates/ibcmd-form-schema/src/lib.rs:5138-5147 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (7 corresponding lines) crates/ibcmd-compiler/src/compiler/bodies/form.rs:72 — crates/ibcmd-compiler/src/compiler/bodies/form.rs:72-80 | crates/ibcmd-compiler/src/compiler/bodies/mxl.rs:82-88 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (7 corresponding lines) crates/ibcmd-config-apply/src/mssql_config_apply/model.rs:39 — crates/ibcmd-config-apply/src/mssql_config_apply/model.rs:39-45 | crates/ibcmd-restructure-engine/src/text.rs:16-22 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (7 corresponding lines) crates/ibcmd-edt/src/codec.rs:345 — crates/ibcmd-edt/src/codec.rs:345-351 | crates/ibcmd-edt/src/directory.rs:141-147 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (7 corresponding lines) crates/ibcmd-core/src/profile.rs:667 — crates/ibcmd-core/src/profile.rs:667-673 | crates/ibcmd-dump/src/mssql_dump/mod.rs:12223-12229 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (7 corresponding lines) crates/ibcmd-metadata-model/src/metadata_model/external_data_source.rs:291 — crates/ibcmd-metadata-model/src/metadata_model/external_data_source.rs:291-299 | crates/ibcmd-metadata-model/src/metadata_model/external_data_source_children.rs:180-186 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (7 corresponding lines) crates/ibcmd-metadata-model/src/metadata_model/common.rs:195 — crates/ibcmd-metadata-model/src/metadata_model/common.rs:195-201 | crates/ibcmd-metadata-model/src/metadata_model/types.rs:457-463 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (7 corresponding lines) crates/ibcmd-compiler/src/compiler/bodies/mxl_native.rs:428 — crates/ibcmd-compiler/src/compiler/bodies/mxl_native.rs:428-434 | crates/ibcmd-metadata-blob/src/interface_assets.rs:328-334 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (7 corresponding lines) crates/ibcmd-1c-vocab/src/values.rs:38 — crates/ibcmd-1c-vocab/src/values.rs:38-44 | crates/ibcmd-dump/src/mssql_dump/mod.rs:34547-34554 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (7 corresponding lines) crates/ibcmd-compiler-families/src/compiler/families/form.rs:772 — crates/ibcmd-compiler-families/src/compiler/families/form.rs:772-780 | crates/ibcmd-form-writer/src/lib.rs:15020-15026 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (7 corresponding lines) crates/ibcmd-form-writer/src/lib.rs:23317 — crates/ibcmd-form-writer/src/lib.rs:23317-23323 | crates/ibcmd-xml/src/metadata/functional_option.rs:285-293 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (7 corresponding lines) scripts/import-lab/edits.py:54 — scripts/import-lab/edits.py:54-60 | scripts/import-lab/edits.py:63-69 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Duplicated block (5 lines × 3) · ×24
  • Duplicated block (5 lines × 3) crates/ibcmd-1c-vocab/src/commands.rs:144 — crates/ibcmd-1c-vocab/src/commands.rs:144-148 | crates/ibcmd-dump/src/mssql_dump/mod.rs:36279-36283 | crates/ibcmd-dump/src/mssql_dump/mod.rs:36304-36308 — before extracting anything, compare `crates/ibcmd-1c-vocab/src/commands.rs` and `crates/ibcmd-dump/src/mssql_dump/mod.rs` as WHOLE FILES: this scan already matched 4 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.
  • Duplicated block (5 lines × 3) crates/ibcmd-core/src/diagnostic.rs:648 — crates/ibcmd-core/src/diagnostic.rs:648-652 | crates/ibcmd-core/src/model.rs:169-173 | crates/ibcmd-core/src/opaque.rs:135-139 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from all 3 call sites, so a change lands once.
  • Duplicated block (5 lines × 3) crates/ibcmd-dump/src/mssql_dump/mod.rs:8886 — crates/ibcmd-dump/src/mssql_dump/mod.rs:8886-8890 | crates/ibcmd-moxel/src/lib.rs:4689-4693 | crates/ibcmd-moxel/src/lib.rs:10071-10075 — before extracting anything, compare `crates/ibcmd-dump/src/mssql_dump/mod.rs` and `crates/ibcmd-moxel/src/lib.rs` as WHOLE FILES: this scan already matched 5 separate duplicated blocks between them, totalling at least 31 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. The two sit in different directories, so one cannot simply be deleted in favour of the other while both are reached separately: hoist the shared part into a location both already depend on and have each file call it, and retire whichever file turns out to have no caller of its own left. Extracting one helper per block leaves the fork in place.
  • Duplicated block (5 lines × 3) crates/ibcmd-dump/src/mssql_dump/mod.rs:8954 — crates/ibcmd-dump/src/mssql_dump/mod.rs:8954-8958 | crates/ibcmd-dump/src/mssql_dump/refs.rs:4452-4456 | crates/ibcmd-dump/src/mssql_dump/source_assets.rs:4292-4296 — before extracting anything, compare `crates/ibcmd-dump/src/mssql_dump/mod.rs` and `crates/ibcmd-dump/src/mssql_dump/refs.rs` as WHOLE FILES: this scan already matched 13 separate duplicated blocks between them, totalling at least 117 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (5 lines × 3) crates/ibcmd-dump/src/mssql_dump/refs.rs:4454 — crates/ibcmd-dump/src/mssql_dump/refs.rs:4454-4458 | crates/ibcmd-dump/src/mssql_dump/role_rights.rs:767-771 | crates/ibcmd-dump/src/mssql_dump/source_assets.rs:4294-4299 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from all 3 call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/refs.rs:4454` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (5 lines × 3) crates/ibcmd-metadata-blob/src/lib.rs:5571 — crates/ibcmd-metadata-blob/src/lib.rs:5571-5575 | crates/ibcmd-metadata-blob/src/lib.rs:5683-5687 | crates/ibcmd-metadata-blob/src/lib.rs:6100-6105 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited.
  • Duplicated block (5 lines × 3) crates/ibcmd-metadata-model/src/metadata_model/registers_export.rs:677 — crates/ibcmd-metadata-model/src/metadata_model/registers_export.rs:677-681 | crates/ibcmd-metadata-model/src/metadata_model/registers_export.rs:901-906 | crates/ibcmd-metadata-model/src/metadata_model/registers_export.rs:1051-1055 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-metadata-model/src/metadata_model/registers_export.rs:677` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (5 lines × 3) crates/ibcmd-xml/src/dcs.rs:1889 — crates/ibcmd-xml/src/dcs.rs:1889-1893 | crates/ibcmd-xml/src/dcs.rs:4025-4029 | crates/ibcmd-xml/src/metadata/external_data_source.rs:47-51 — there are 3 copies across 2 file(s) — more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 3 sites; resolving a subset leaves the remainder to drift apart. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-xml/src/dcs.rs:1889` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (5 lines × 3) crates/ibcmd-xml/src/metadata/configuration_mobile.rs:46 — crates/ibcmd-xml/src/metadata/configuration_mobile.rs:46-50 | crates/ibcmd-xml/src/metadata/configuration_v85_projection.rs:100-104 | crates/ibcmd-xml/src/metadata/external_data_source.rs:47-51 — before extracting anything, compare `crates/ibcmd-xml/src/metadata/configuration_mobile.rs` and `crates/ibcmd-xml/src/metadata/configuration_v85_projection.rs` as WHOLE FILES: this scan already matched 5 separate duplicated blocks between them, totalling at least 31 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-xml/src/metadata/configuration_mobile.rs:46` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, `crates/ibcmd-xml/src/metadata/configuration_mobile.rs:51` calls `Comment` and `crates/ibcmd-xml/src/metadata/external_data_source.rs:52` does not — after which the two agree again for 3 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
  • Duplicated block (5 lines × 3) REDACTED:2610 — REDACTED:2610-2614 | REDACTED:7181-7185 | REDACTED:7420-7424 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited.
  • Duplicated block (5 lines × 3) src/source_audit.rs:1678 — src/source_audit.rs:1678-1682 | src/source_audit.rs:2699-2703 | src/source_audit.rs:3297-3301 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited.
  • Duplicated block (5 lines × 3) crates/ibcmd-dump/src/mssql_dump/refs.rs:4062 — crates/ibcmd-dump/src/mssql_dump/refs.rs:4062-4066 | crates/ibcmd-form-body/src/form_body.rs:18584-18588 | crates/ibcmd-form-body/src/form_extension.rs:35-39 — before extracting anything, compare `crates/ibcmd-dump/src/mssql_dump/refs.rs` and `crates/ibcmd-form-body/src/form_body.rs` as WHOLE FILES: this scan already matched 4 separate duplicated blocks between them, totalling at least 30 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. The two sit in different directories, so one cannot simply be deleted in favour of the other while both are reached separately: hoist the shared part into a location both already depend on and have each file call it, and retire whichever file turns out to have no caller of its own left. Extracting one helper per block leaves the fork in place.
  • Duplicated block (5 lines × 3) crates/ibcmd-form-body/src/form_body.rs:27504 — crates/ibcmd-form-body/src/form_body.rs:27504-27508 | crates/ibcmd-form-native/src/lib.rs:9452-9456 | crates/ibcmd-metadata-model/src/metadata_model/objects_parts.rs:864-868 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 3 call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made 3 times. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-form-body/src/form_body.rs:27504` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (5 lines × 3) crates/ibcmd-restructure-engine/src/restructure/entry.rs:179 — crates/ibcmd-restructure-engine/src/restructure/entry.rs:179-183 | crates/ibcmd-restructure/src/scheduled_jobs.rs:10-14 | REDACTED:802-806 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 3 call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made 3 times.
  • Duplicated block (5 lines × 3) crates/ibcmd-xml/src/metadata/constant.rs:285 — crates/ibcmd-xml/src/metadata/constant.rs:285-289 | crates/ibcmd-xml/src/metadata/services.rs:1057-1061 | crates/ibcmd-xml/src/metadata/session_parameter.rs:224-228 — before extracting anything, compare `crates/ibcmd-xml/src/metadata/constant.rs` and `crates/ibcmd-xml/src/metadata/session_parameter.rs` as WHOLE FILES: this scan already matched 7 separate duplicated blocks between them, totalling at least 57 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place.
  • Duplicated block (5 lines × 3) crates/ibcmd-xml/src/metadata/constant.rs:291 — crates/ibcmd-xml/src/metadata/constant.rs:291-295 | crates/ibcmd-xml/src/metadata/services.rs:1063-1067 | crates/ibcmd-xml/src/metadata/session_parameter.rs:230-234 — before extracting anything, compare `crates/ibcmd-xml/src/metadata/constant.rs` and `crates/ibcmd-xml/src/metadata/session_parameter.rs` as WHOLE FILES: this scan already matched 7 separate duplicated blocks between them, totalling at least 57 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place.
  • Duplicated block (5 lines × 3) crates/ibcmd-metadata-blob/src/lib.rs:747 — crates/ibcmd-metadata-blob/src/lib.rs:747-751 | crates/ibcmd-metadata-blob/src/lib.rs:3680-3685 | crates/ibcmd-metadata-blob/src/lib.rs:3989-3995 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-metadata-blob/src/lib.rs:747` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
  • Duplicated block (5 lines × 3) REDACTED:5626 — REDACTED:5626-5630 | REDACTED:5722-5726 | REDACTED:6068-6072 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `REDACTED:5626` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, `REDACTED:5624` calls `infer_scheduled_job_schedule_path` and `REDACTED:5720` does not — after which the two agree again for 3 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
  • Duplicated block (5 lines × 3) crates/ibcmd-form-writer/src/lib.rs:22551 — crates/ibcmd-form-writer/src/lib.rs:22551-22555 | crates/ibcmd-metadata-blob/src/lib.rs:1390-1394 | crates/ibcmd-metadata-blob/src/lib.rs:2165-2169 — before extracting anything, compare `crates/ibcmd-form-writer/src/lib.rs` and `crates/ibcmd-metadata-blob/src/lib.rs` as WHOLE FILES: this scan already matched 5 separate duplicated blocks between them, totalling at least 33 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 `crates/ibcmd-form-writer/src/lib.rs:22551` it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows — the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members' bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run — a one-line delegation has no helper inside it to lift — so generate the run from the set it enumerates, or accept it and keep each member's own documentation with it.
  • Duplicated block (5 lines × 3) crates/ibcmd-form-body/src/form_body.rs:3012 — crates/ibcmd-form-body/src/form_body.rs:3012-3016 | crates/ibcmd-form-body/src/form_body.rs:3049-3053 | crates/ibcmd-form-body/src/form_body.rs:3170-3174 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-form-body/src/form_body.rs:3012` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, `crates/ibcmd-form-body/src/form_body.rs:3018` calls `Some` and `crates/ibcmd-form-body/src/form_body.rs:3055` does not — after which the two agree again for 3 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
  • Duplicated block (5 lines × 3) REDACTED:5625 — REDACTED:5625-5629 | REDACTED:6067-6071 | REDACTED:6972-6976 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited.
  • Duplicated block (5 lines × 3) crates/ibcmd-moxel/src/lib.rs:7678 — crates/ibcmd-moxel/src/lib.rs:7678-7682 | crates/ibcmd-moxel/src/lib.rs:7700-7704 | crates/ibcmd-moxel/src/lib.rs:7728-7732 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, `crates/ibcmd-moxel/src/lib.rs:7706` calls `get`, `trim` and `crates/ibcmd-moxel/src/lib.rs:7734` does not — after which the two agree again for 3 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
  • Duplicated block (5 lines × 3) crates/ibcmd-metadata-model/src/metadata_model/export_names.rs:23 — crates/ibcmd-metadata-model/src/metadata_model/export_names.rs:23-27 | crates/ibcmd-metadata-model/src/metadata_model/export_names.rs:40-44 | crates/ibcmd-metadata-model/src/metadata_model/export_names.rs:57-61 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (5 lines × 3) _onecdec/base_free_round.py:27 — _onecdec/base_free_round.py:27-31 | _onecdec/stress_load.py:34-38 | _onecdec/verify_edit.py:33-37 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from all 3 call sites, so a change lands once. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, `_onecdec/verify_edit.py:39` calls `group` and `_onecdec/base_free_round.py:32` does not — after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
D1 · Cyclomatic Complexity · ibcmd_metadata_blob · ×23
  • ibcmd_metadata_blob::role_rights_writer::parse_rights_xml (cyclomatic 54) crates/ibcmd-metadata-blob/src/role_rights_writer.rs:735 — ibcmd_metadata_blob::role_rights_writer::parse_rights_xml has cyclomatic complexity 54 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
  • ibcmd_metadata_blob::parse_role_rights_xml (cyclomatic 52) crates/ibcmd-metadata-blob/src/lib.rs:3668 — ibcmd_metadata_blob::parse_role_rights_xml has cyclomatic complexity 52 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
  • ibcmd_metadata_blob::parse_configuration_object_xml (cyclomatic 44) crates/ibcmd-metadata-blob/src/lib.rs:7817 — ibcmd_metadata_blob::parse_configuration_object_xml has cyclomatic complexity 44 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
  • ibcmd_metadata_blob::parse_flowchart_xml (cyclomatic 38) crates/ibcmd-metadata-blob/src/lib.rs:4769 — ibcmd_metadata_blob::parse_flowchart_xml 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 is NOT this file's highest cyclomatic complexity: ibcmd_metadata_blob::metadata_reference_source_folder (cyclomatic 43) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • ibcmd_metadata_blob::parse_schedule_xml (cyclomatic 30) crates/ibcmd-metadata-blob/src/lib.rs:5287 — ibcmd_metadata_blob::parse_schedule_xml 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. This is NOT this file's highest cyclomatic complexity: ibcmd_metadata_blob::metadata_reference_source_folder (cyclomatic 43) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • ibcmd_metadata_blob::parse_style_body_xml_items (cyclomatic 28) crates/ibcmd-metadata-blob/src/lib.rs:1961 — ibcmd_metadata_blob::parse_style_body_xml_items 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. This is NOT this file's highest cyclomatic complexity: ibcmd_metadata_blob::metadata_reference_source_folder (cyclomatic 43) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • ibcmd_metadata_blob::parse_simple_metadata_xml_properties (cyclomatic 27) crates/ibcmd-metadata-blob/src/lib.rs:6097 — ibcmd_metadata_blob::parse_simple_metadata_xml_properties 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. This is NOT this file's highest cyclomatic complexity: ibcmd_metadata_blob::metadata_reference_source_folder (cyclomatic 43) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • ibcmd_metadata_blob::parse_predefined_data_xml (cyclomatic 25) crates/ibcmd-metadata-blob/src/lib.rs:4475 — ibcmd_metadata_blob::parse_predefined_data_xml 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. This is NOT this file's highest cyclomatic complexity: ibcmd_metadata_blob::metadata_reference_source_folder (cyclomatic 43) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • ibcmd_metadata_blob::parse_common_module_xml_properties (cyclomatic 25) crates/ibcmd-metadata-blob/src/lib.rs:6283 — ibcmd_metadata_blob::parse_common_module_xml_properties 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. This is NOT this file's highest cyclomatic complexity: ibcmd_metadata_blob::metadata_reference_source_folder (cyclomatic 43) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • ibcmd_metadata_blob::parse_http_service_method_uuid_from_xml (cyclomatic 24) crates/ibcmd-metadata-blob/src/lib.rs:3217 — ibcmd_metadata_blob::parse_http_service_method_uuid_from_xml 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. This is NOT this file's highest cyclomatic complexity: ibcmd_metadata_blob::metadata_reference_source_folder (cyclomatic 43) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • ibcmd_metadata_blob::role_rights_writer::parse_uuid_tree (cyclomatic 24) crates/ibcmd-metadata-blob/src/role_rights_writer.rs:1226 — ibcmd_metadata_blob::role_rights_writer::parse_uuid_tree 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. This is NOT this file's highest cyclomatic complexity: ibcmd_metadata_blob::role_rights_writer::metadata_family_folder (cyclomatic 41) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • ibcmd_metadata_blob::validate_command_interface_xml_document (cyclomatic 23) crates/ibcmd-metadata-blob/src/lib.rs:2468 — ibcmd_metadata_blob::validate_command_interface_xml_document 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. This is NOT this file's highest cyclomatic complexity: ibcmd_metadata_blob::metadata_reference_source_folder (cyclomatic 43) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • ibcmd_metadata_blob::parse_help_pages_from_xml (cyclomatic 21) crates/ibcmd-metadata-blob/src/lib.rs:5149 — ibcmd_metadata_blob::parse_help_pages_from_xml 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's highest cyclomatic complexity: ibcmd_metadata_blob::metadata_reference_source_folder (cyclomatic 43) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • ibcmd_metadata_blob::parse_exchange_plan_content_xml (cyclomatic 19) crates/ibcmd-metadata-blob/src/lib.rs:4089 — ibcmd_metadata_blob::parse_exchange_plan_content_xml 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. This is NOT this file's highest cyclomatic complexity: ibcmd_metadata_blob::metadata_reference_source_folder (cyclomatic 43) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • ibcmd_metadata_blob::parse_common_command_xml_properties (cyclomatic 19) crates/ibcmd-metadata-blob/src/lib.rs:5778 — ibcmd_metadata_blob::parse_common_command_xml_properties 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. This shape REPEATS in the file: one other method here (ibcmd_metadata_blob::parse_command_group_xml_properties) has the same decision points, in the same order, at the same nesting depths — 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 is NOT this file's highest cyclomatic complexity: ibcmd_metadata_blob::metadata_reference_source_folder (cyclomatic 43) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • ibcmd_metadata_blob::parse_command_group_xml_properties (cyclomatic 19) crates/ibcmd-metadata-blob/src/lib.rs:5957 — ibcmd_metadata_blob::parse_command_group_xml_properties 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. This shape REPEATS in the file: one other method here (ibcmd_metadata_blob::parse_common_command_xml_properties) has the same decision points, in the same order, at the same nesting depths — 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 is NOT this file's highest cyclomatic complexity: ibcmd_metadata_blob::metadata_reference_source_folder (cyclomatic 43) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • ibcmd_metadata_blob::parse_nested_command_uuid_from_xml (cyclomatic 18) crates/ibcmd-metadata-blob/src/lib.rs:2328 — ibcmd_metadata_blob::parse_nested_command_uuid_from_xml 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 shape REPEATS in the file: one other method here (ibcmd_metadata_blob::parse_nested_metadata_child_uuid_from_xml) has the same decision points, in the same order, at the same nesting depths — 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 is NOT this file's highest cyclomatic complexity: ibcmd_metadata_blob::metadata_reference_source_folder (cyclomatic 43) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • ibcmd_metadata_blob::parse_nested_metadata_child_uuid_from_xml (cyclomatic 18) crates/ibcmd-metadata-blob/src/lib.rs:3295 — ibcmd_metadata_blob::parse_nested_metadata_child_uuid_from_xml 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 shape REPEATS in the file: one other method here (ibcmd_metadata_blob::parse_nested_command_uuid_from_xml) has the same decision points, in the same order, at the same nesting depths — 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 is NOT this file's highest cyclomatic complexity: ibcmd_metadata_blob::metadata_reference_source_folder (cyclomatic 43) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • ibcmd_metadata_blob::parse_command_interface_xml (cyclomatic 17) crates/ibcmd-metadata-blob/src/lib.rs:3983 — ibcmd_metadata_blob::parse_command_interface_xml 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's highest cyclomatic complexity: ibcmd_metadata_blob::metadata_reference_source_folder (cyclomatic 43) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • ibcmd_metadata_blob::parse_additional_indexes_xml (cyclomatic 16) crates/ibcmd-metadata-blob/src/lib.rs:1801 — ibcmd_metadata_blob::parse_additional_indexes_xml 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. This is NOT this file's highest cyclomatic complexity: ibcmd_metadata_blob::metadata_reference_source_folder (cyclomatic 43) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • ibcmd_metadata_blob::parse_owner_field_uuids (cyclomatic 16) crates/ibcmd-metadata-blob/src/lib.rs:1872 — ibcmd_metadata_blob::parse_owner_field_uuids 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. This is NOT this file's highest cyclomatic complexity: ibcmd_metadata_blob::metadata_reference_source_folder (cyclomatic 43) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • ibcmd_metadata_blob::parse_generated_type_type_id (cyclomatic 16) crates/ibcmd-metadata-blob/src/lib.rs:8117 — ibcmd_metadata_blob::parse_generated_type_type_id 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. This is NOT this file's highest cyclomatic complexity: ibcmd_metadata_blob::metadata_reference_source_folder (cyclomatic 43) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • ibcmd_metadata_blob::xml::parse_element_tree_with (cyclomatic 16) crates/ibcmd-metadata-blob/src/xml.rs:168 — ibcmd_metadata_blob::xml::parse_element_tree_with 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.
D4 · Code Duplication · Edited copy of a member (13 corresponding lines) · ×23
  • Edited copy of a member (13 corresponding lines) src/load.rs:83 — src/load.rs:83-95 | src/mssql_extension_tree_load.rs:605-631 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (13 corresponding lines) crates/ibcmd-moxel/src/lib.rs:14446 — crates/ibcmd-moxel/src/lib.rs:14446-14458 | crates/ibcmd-moxel/src/lib.rs:14460-14472 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (13 corresponding lines) crates/ibcmd-1c-text/src/braced.rs:297 — crates/ibcmd-1c-text/src/braced.rs:297-309 | crates/ibcmd-1c-text/src/braced.rs:430-445 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (13 corresponding lines) crates/ibcmd-dump/src/mssql_dump/mod.rs:15865 — crates/ibcmd-dump/src/mssql_dump/mod.rs:15865-15879 | crates/ibcmd-dump/src/mssql_dump/refs.rs:5011-5023 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (13 corresponding lines) crates/ibcmd-core/src/diagnostic.rs:646 — crates/ibcmd-core/src/diagnostic.rs:646-660 | crates/ibcmd-core/src/storage.rs:389-401 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (13 corresponding lines) crates/ibcmd-metadata-model/src/metadata_model/common.rs:116 — crates/ibcmd-metadata-model/src/metadata_model/common.rs:116-128 | crates/ibcmd-metadata-model/src/metadata_model/mod.rs:185-199 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (13 corresponding lines) crates/ibcmd-form-writer/src/lib.rs:19795 — crates/ibcmd-form-writer/src/lib.rs:19795-19807 | crates/ibcmd-form-writer/src/lib.rs:21227-21241 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (13 corresponding lines) src/source_audit.rs:336 — src/source_audit.rs:336-348 | src/source_audit.rs:957-969 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (13 corresponding lines) crates/ibcmd-compiler-families/src/compiler/families/services.rs:3437 — crates/ibcmd-compiler-families/src/compiler/families/services.rs:3437-3449 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:2454-2466 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (13 corresponding lines) crates/ibcmd-form-body/src/form_body.rs:4118 — crates/ibcmd-form-body/src/form_body.rs:4118-4130 | crates/ibcmd-form-body/src/form_body.rs:23893-23905 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (13 corresponding lines) crates/ibcmd-form-writer/src/lib.rs:970 — crates/ibcmd-form-writer/src/lib.rs:970-982 | crates/ibcmd-metadata-blob/src/lib.rs:1497-1512 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (13 corresponding lines) crates/ibcmd-core/src/family.rs:249 — crates/ibcmd-core/src/family.rs:249-261 | crates/ibcmd-xml/src/metadata/registry.rs:50-62 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (13 corresponding lines) crates/ibcmd-xml/src/metadata/functional_option.rs:239 — crates/ibcmd-xml/src/metadata/functional_option.rs:239-251 | crates/ibcmd-xml/src/metadata/functional_options_parameter.rs:202-214 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (13 corresponding lines) crates/ibcmd-parallel/src/lib.rs:42 — crates/ibcmd-parallel/src/lib.rs:42-54 | crates/ibcmd-parallel/src/lib.rs:66-79 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (13 corresponding lines) crates/ibcmd-dump/src/mssql_dump/mod.rs:20550 — crates/ibcmd-dump/src/mssql_dump/mod.rs:20550-20562 | crates/ibcmd-dump/src/mssql_dump/mod.rs:20570-20588 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (13 corresponding lines) crates/ibcmd-schema/src/lib.rs:15028 — crates/ibcmd-schema/src/lib.rs:15028-15040 | crates/ibcmd-schema/src/lib.rs:15042-15054 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (13 corresponding lines) src/settings.rs:511 — src/settings.rs:511-523 | src/settings.rs:609-621 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (13 corresponding lines) src/source_oracle.rs:256 — src/source_oracle.rs:256-268 | src/source_oracle.rs:559-574 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (13 corresponding lines) crates/ibcmd-form-body/src/form_body.rs:7143 — crates/ibcmd-form-body/src/form_body.rs:7143-7156 | crates/ibcmd-form-body/src/form_body.rs:8049-8061 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (13 corresponding lines) crates/ibcmd-v8/src/reader.rs:104 — crates/ibcmd-v8/src/reader.rs:104-116 | crates/ibcmd-v8/src/reader.rs:118-135 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (13 corresponding lines) crates/ibcmd-form-writer/src/lib.rs:13400 — crates/ibcmd-form-writer/src/lib.rs:13400-13413 | crates/ibcmd-form-writer/src/lib.rs:24029-24041 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (13 corresponding lines) crates/ibcmd-metadata-model/src/metadata_model/common.rs:710 — crates/ibcmd-metadata-model/src/metadata_model/common.rs:710-722 | crates/ibcmd-metadata-model/src/metadata_model/common.rs:1970-1982 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (13 corresponding lines) scripts/edt-lab/prepare_macos.py:37 — scripts/edt-lab/prepare_macos.py:37-53 | scripts/edt-lab/xml_to_edt_macos.py:49-61 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Duplicated block (15 lines × 2) · ×22
  • Duplicated block (15 lines × 2) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:1265 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:1265-1279 | crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:1571-1585 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (15 lines × 2) crates/ibcmd-compiler-families/src/compiler/families/services.rs:3558 — crates/ibcmd-compiler-families/src/compiler/families/services.rs:3558-3572 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:2575-2589 — before extracting anything, compare `crates/ibcmd-compiler-families/src/compiler/families/services.rs` and `crates/ibcmd-compiler-families/src/compiler/families/simple.rs` as WHOLE FILES: this scan already matched 36 separate duplicated blocks between them, totalling at least 406 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/services.rs:3558` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (15 lines × 2) REDACTED:233 — REDACTED:233-247 | src/dump_sources.rs:305-319 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at `REDACTED:233` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (15 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:17966 — crates/ibcmd-dump/src/mssql_dump/mod.rs:17966-17980 | crates/ibcmd-dump/src/mssql_dump/mod.rs:19016-19030 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:17966` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (15 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:28660 — crates/ibcmd-dump/src/mssql_dump/mod.rs:28660-28674 | crates/ibcmd-dump/src/mssql_dump/mod.rs:30151-30165 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, `crates/ibcmd-dump/src/mssql_dump/mod.rs:30148` calls `push` and `crates/ibcmd-dump/src/mssql_dump/mod.rs:28657` does not — after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
  • Duplicated block (15 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:39838 — crates/ibcmd-dump/src/mssql_dump/mod.rs:39838-39852 | crates/ibcmd-dump/src/mssql_dump/mod.rs:40037-40051 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:39838` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (15 lines × 2) crates/ibcmd-form-body/src/form_body.rs:4699 — crates/ibcmd-form-body/src/form_body.rs:4699-4713 | crates/ibcmd-form-body/src/form_body.rs:5542-5556 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (15 lines × 2) crates/ibcmd-form-writer/src/lib.rs:8435 — crates/ibcmd-form-writer/src/lib.rs:8435-8449 | crates/ibcmd-form-writer/src/lib.rs:8457-8471 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-form-writer/src/lib.rs:8435` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (15 lines × 2) crates/ibcmd-form-writer/src/lib.rs:16989 — crates/ibcmd-form-writer/src/lib.rs:16989-17003 | crates/ibcmd-form-writer/src/lib.rs:20693-20707 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-form-writer/src/lib.rs:16989` it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows — the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members' bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run — a one-line delegation has no helper inside it to lift — so generate the run from the set it enumerates, or accept it and keep each member's own documentation with it.
  • Duplicated block (15 lines × 2) crates/ibcmd-form-writer/src/lib.rs:20514 — crates/ibcmd-form-writer/src/lib.rs:20514-20528 | crates/ibcmd-form-writer/src/lib.rs:20668-20682 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-form-writer/src/lib.rs:20514` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (15 lines × 2) crates/ibcmd-moxel/src/lib.rs:5682 — crates/ibcmd-moxel/src/lib.rs:5682-5696 | crates/ibcmd-moxel/src/lib.rs:5814-5828 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-moxel/src/lib.rs:5682` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, `crates/ibcmd-moxel/src/lib.rs:5680` calls `get`, `is_some_and` and `crates/ibcmd-moxel/src/lib.rs:5812` does not — after which the two agree again for 3 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
  • Duplicated block (15 lines × 2) crates/ibcmd-moxel/src/lib.rs:12656 — crates/ibcmd-moxel/src/lib.rs:12656-12670 | crates/ibcmd-moxel/src/lib.rs:12691-12705 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-moxel/src/lib.rs:12656` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (15 lines × 2) crates/ibcmd-v8/src/block.rs:189 — crates/ibcmd-v8/src/block.rs:189-203 | crates/ibcmd-v8/src/block.rs:449-463 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-v8/src/block.rs:189` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note first that the copies are not typed on the same thing: the declarations holding them bind `address` to `u32` in one and `u64` in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH — their common supertype where they have one, or a new abstraction over them where they do not — and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract.
  • Duplicated block (15 lines × 2) crates/ibcmd-xml/src/dcs_schema.rs:2608 — crates/ibcmd-xml/src/dcs_schema.rs:2608-2622 | crates/ibcmd-xml/src/dcs_schema.rs:2624-2638 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-xml/src/dcs_schema.rs:2608` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (15 lines × 2) crates/ibcmd-xml/src/dcs_template.rs:545 — crates/ibcmd-xml/src/dcs_template.rs:545-559 | crates/ibcmd-xml/src/dcs_template.rs:977-991 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-xml/src/dcs_template.rs:545` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (15 lines × 2) crates/ibcmd-xml/src/writer.rs:401 — crates/ibcmd-xml/src/writer.rs:401-415 | crates/ibcmd-xml/src/writer.rs:452-466 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (15 lines × 2) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:2636 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:2636-2650 | crates/ibcmd-compiler-families/src/compiler/families/utility.rs:1305-1319 — before extracting anything, compare `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs` and `crates/ibcmd-compiler-families/src/compiler/families/utility.rs` as WHOLE FILES: this scan already matched 65 separate duplicated blocks between them, totalling at least 934 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. 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 `return` inside it is the body's own exit and keeps its meaning in the moved unit.
  • Duplicated block (15 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:23870 — crates/ibcmd-dump/src/mssql_dump/mod.rs:23870-23884 | crates/ibcmd-dump/src/mssql_dump/mod.rs:24159-24173 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (15 lines × 2) crates/ibcmd-metadata-model/src/metadata_model/external_data_source_children.rs:470 — crates/ibcmd-metadata-model/src/metadata_model/external_data_source_children.rs:470-484 | crates/ibcmd-metadata-model/src/metadata_model/external_data_source_children.rs:524-538 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-metadata-model/src/metadata_model/external_data_source_children.rs:470` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (15 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:25286 — crates/ibcmd-dump/src/mssql_dump/mod.rs:25286-25300 | crates/ibcmd-dump/src/mssql_dump/mod.rs:25691-25705 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:25286` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (15 lines × 2) crates/ibcmd-xml/src/metadata/constant.rs:644 — crates/ibcmd-xml/src/metadata/constant.rs:644-658 | crates/ibcmd-xml/src/metadata/language.rs:367-381 — before extracting anything, compare `crates/ibcmd-xml/src/metadata/constant.rs` and `crates/ibcmd-xml/src/metadata/language.rs` as WHOLE FILES: this scan already matched 19 separate duplicated blocks between them, totalling at least 213 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place.
  • Duplicated block (15 lines × 2) crates/ibcmd-moxel/src/lib.rs:13753 — crates/ibcmd-moxel/src/lib.rs:13753-13767 | crates/ibcmd-moxel/src/lib.rs:14859-14873 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-moxel/src/lib.rs:13753` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
X17 · Uncapped recursion over a caller-supplied document · Recursive walk over a caller-supplied document has no depth cap · ×21
  • Recursive walk over a caller-supplied document has no depth cap src/stored_objects.rs:1072 — `children` is public and takes a `StoredConfiguration` as its receiver from its caller, and it calls itself at line 1072 with a piece of the document — and nowhere in the walk is a depth or nesting counter compared with a bound. The walk therefore spends one stack frame per LEVEL of the value it is handed, so the nesting of the caller's document — not this code — decides how deep the stack goes. When a Rust thread runs out of stack it is not unwound: the runtime reports the overflow and aborts the process, so `catch_unwind` does not stop it and every other request the process serves dies with it (spawned threads, a Tokio worker included, get 2 MiB by default). serde_json and serde_yaml stop parsing at 128 levels only on their default path; a value from `disable_recursion_limit`, from another format or parser, or built in code carries whatever nesting it was given. Thread a depth argument through `children` and reject the value past a fixed maximum, or rewrite the descent with an explicit stack.
  • Recursive walk over a caller-supplied document has no depth cap src/stored_objects.rs:1081 — `resolve` is public and takes a `StoredConfiguration` as its receiver from its caller, and it calls itself at line 1081 with a piece of the document — and nowhere in the walk is a depth or nesting counter compared with a bound. The walk therefore spends one stack frame per LEVEL of the value it is handed, so the nesting of the caller's document — not this code — decides how deep the stack goes. When a Rust thread runs out of stack it is not unwound: the runtime reports the overflow and aborts the process, so `catch_unwind` does not stop it and every other request the process serves dies with it (spawned threads, a Tokio worker included, get 2 MiB by default). serde_json and serde_yaml stop parsing at 128 levels only on their default path; a value from `disable_recursion_limit`, from another format or parser, or built in code carries whatever nesting it was given. Thread a depth argument through `resolve` and reject the value past a fixed maximum, or rewrite the descent with an explicit stack.
  • Recursive walk over a caller-supplied document has no depth cap src/stored_objects.rs:1327 — `status_with_versions` is public and takes a `StoredConfiguration` as its receiver from its caller, and it calls itself at line 1327 with a piece of the document — and nowhere in the walk is a depth or nesting counter compared with a bound. The walk therefore spends one stack frame per LEVEL of the value it is handed, so the nesting of the caller's document — not this code — decides how deep the stack goes. When a Rust thread runs out of stack it is not unwound: the runtime reports the overflow and aborts the process, so `catch_unwind` does not stop it and every other request the process serves dies with it (spawned threads, a Tokio worker included, get 2 MiB by default). serde_json and serde_yaml stop parsing at 128 levels only on their default path; a value from `disable_recursion_limit`, from another format or parser, or built in code carries whatever nesting it was given. Thread a depth argument through `status_with_versions` and reject the value past a fixed maximum, or rewrite the descent with an explicit stack.
  • Recursive walk over a caller-supplied document has no depth cap crates/ibcmd-xml/src/node.rs:186 — `clone` is public and takes a `XmlElement` as its receiver from its caller, and it calls itself at line 186 with a piece of the document — and nowhere in the walk is a depth or nesting counter compared with a bound. The walk therefore spends one stack frame per LEVEL of the value it is handed, so the nesting of the caller's document — not this code — decides how deep the stack goes. When a Rust thread runs out of stack it is not unwound: the runtime reports the overflow and aborts the process, so `catch_unwind` does not stop it and every other request the process serves dies with it (spawned threads, a Tokio worker included, get 2 MiB by default). serde_json and serde_yaml stop parsing at 128 levels only on their default path; a value from `disable_recursion_limit`, from another format or parser, or built in code carries whatever nesting it was given. Thread a depth argument through `clone` and reject the value past a fixed maximum, or rewrite the descent with an explicit stack.
  • Recursive walk over a caller-supplied document has no depth cap crates/ibcmd-xml/src/writer.rs:375 — `node_output_len` is public and takes `node: &XmlNode` from its caller, and it recurses at line 375 through `element_output_len` and back with a piece of the document (and at line 440) — and nowhere in the walk is a depth or nesting counter compared with a bound. The walk therefore spends one stack frame per LEVEL of the value it is handed, so the nesting of the caller's document — not this code — decides how deep the stack goes. When a Rust thread runs out of stack it is not unwound: the runtime reports the overflow and aborts the process, so `catch_unwind` does not stop it and every other request the process serves dies with it (spawned threads, a Tokio worker included, get 2 MiB by default). serde_json and serde_yaml stop parsing at 128 levels only on their default path; a value from `disable_recursion_limit`, from another format or parser, or built in code carries whatever nesting it was given. Thread a depth argument through `node_output_len` and reject the value past a fixed maximum, or rewrite the descent with an explicit stack.
  • Recursive walk over a caller-supplied document has no depth cap crates/ibcmd-xml/src/writer.rs:665 — `node_to_vec_with_policy` is public, takes a document from its caller (line 103) and hands it to `element_out`, which recurses at line 665 through `node_out` and back with a piece of the document (and at line 745) — and nowhere in the walk is a depth or nesting counter compared with a bound. The walk therefore spends one stack frame per LEVEL of the value it is handed, so the nesting of the caller's document — not this code — decides how deep the stack goes. When a Rust thread runs out of stack it is not unwound: the runtime reports the overflow and aborts the process, so `catch_unwind` does not stop it and every other request the process serves dies with it (spawned threads, a Tokio worker included, get 2 MiB by default). serde_json and serde_yaml stop parsing at 128 levels only on their default path; a value from `disable_recursion_limit`, from another format or parser, or built in code carries whatever nesting it was given. Thread a depth argument through `element_out` and reject the value past a fixed maximum, or rewrite the descent with an explicit stack.
  • Recursive walk over a caller-supplied document has no depth cap crates/ibcmd-xml/src/metadata/business_objects.rs:726 — `collect_embedded_elements` is public, takes a document from its caller (line 697) and hands it to `visit`, which calls itself at line 726 with a piece of the document — and nowhere in the walk is a depth or nesting counter compared with a bound. The walk therefore spends one stack frame per LEVEL of the value it is handed, so the nesting of the caller's document — not this code — decides how deep the stack goes. When a Rust thread runs out of stack it is not unwound: the runtime reports the overflow and aborts the process, so `catch_unwind` does not stop it and every other request the process serves dies with it (spawned threads, a Tokio worker included, get 2 MiB by default). serde_json and serde_yaml stop parsing at 128 levels only on their default path; a value from `disable_recursion_limit`, from another format or parser, or built in code carries whatever nesting it was given. Thread a depth argument through `visit` and reject the value past a fixed maximum, or rewrite the descent with an explicit stack.
  • Recursive walk over a caller-supplied document has no depth cap crates/ibcmd-restructure/src/brace.rs:126 — `serialize_row` is public, takes a document from its caller (line 90) and hands it to `write_node`, which calls itself at line 126 with a piece of the document — and nowhere in the walk is a depth or nesting counter compared with a bound. The walk therefore spends one stack frame per LEVEL of the value it is handed, so the nesting of the caller's document — not this code — decides how deep the stack goes. When a Rust thread runs out of stack it is not unwound: the runtime reports the overflow and aborts the process, so `catch_unwind` does not stop it and every other request the process serves dies with it (spawned threads, a Tokio worker included, get 2 MiB by default). serde_json and serde_yaml stop parsing at 128 levels only on their default path; a value from `disable_recursion_limit`, from another format or parser, or built in code carries whatever nesting it was given. Thread a depth argument through `write_node` and reject the value past a fixed maximum, or rewrite the descent with an explicit stack.
  • Recursive walk over a caller-supplied document has no depth cap crates/ibcmd-form-body/src/form_body.rs:1109 — `without_usual_group_behavior` is public and takes `items: &mut[FormChildItem]` from its caller, and it calls itself at line 1109 with a piece of the document — and nowhere in the walk is a depth or nesting counter compared with a bound. The walk therefore spends one stack frame per LEVEL of the value it is handed, so the nesting of the caller's document — not this code — decides how deep the stack goes. When a Rust thread runs out of stack it is not unwound: the runtime reports the overflow and aborts the process, so `catch_unwind` does not stop it and every other request the process serves dies with it (spawned threads, a Tokio worker included, get 2 MiB by default). serde_json and serde_yaml stop parsing at 128 levels only on their default path; a value from `disable_recursion_limit`, from another format or parser, or built in code carries whatever nesting it was given. Thread a depth argument through `without_usual_group_behavior` and reject the value past a fixed maximum, or rewrite the descent with an explicit stack.
  • Recursive walk over a caller-supplied document has no depth cap crates/ibcmd-form-body/src/form_body.rs:1236 — `collect_opaque_choice_list_diagnostics` is public and takes `items: &[FormChildItem]` from its caller, and it calls itself at line 1236 with a piece of the document — and nowhere in the walk is a depth or nesting counter compared with a bound. The walk therefore spends one stack frame per LEVEL of the value it is handed, so the nesting of the caller's document — not this code — decides how deep the stack goes. When a Rust thread runs out of stack it is not unwound: the runtime reports the overflow and aborts the process, so `catch_unwind` does not stop it and every other request the process serves dies with it (spawned threads, a Tokio worker included, get 2 MiB by default). serde_json and serde_yaml stop parsing at 128 levels only on their default path; a value from `disable_recursion_limit`, from another format or parser, or built in code carries whatever nesting it was given. Thread a depth argument through `collect_opaque_choice_list_diagnostics` and reject the value past a fixed maximum, or rewrite the descent with an explicit stack.
  • Recursive walk over a caller-supplied document has no depth cap crates/ibcmd-form-body/src/form_body.rs:1302 — `collect_opaque_choice_parameters_diagnostics` is public and takes `items: &[FormChildItem]` from its caller, and it calls itself at line 1302 with a piece of the document — and nowhere in the walk is a depth or nesting counter compared with a bound. The walk therefore spends one stack frame per LEVEL of the value it is handed, so the nesting of the caller's document — not this code — decides how deep the stack goes. When a Rust thread runs out of stack it is not unwound: the runtime reports the overflow and aborts the process, so `catch_unwind` does not stop it and every other request the process serves dies with it (spawned threads, a Tokio worker included, get 2 MiB by default). serde_json and serde_yaml stop parsing at 128 levels only on their default path; a value from `disable_recursion_limit`, from another format or parser, or built in code carries whatever nesting it was given. Thread a depth argument through `collect_opaque_choice_parameters_diagnostics` and reject the value past a fixed maximum, or rewrite the descent with an explicit stack.
  • Recursive walk over a caller-supplied document has no depth cap crates/ibcmd-form-body/src/form_body.rs:2412 — `record_complete_table_schema_events` is public, takes a document from its caller (line 10753) and hands it to `visit`, which calls itself at line 2412 with a piece of the document (and at line 2434, line 10845) — and nowhere in the walk is a depth or nesting counter compared with a bound. The walk therefore spends one stack frame per LEVEL of the value it is handed, so the nesting of the caller's document — not this code — decides how deep the stack goes. When a Rust thread runs out of stack it is not unwound: the runtime reports the overflow and aborts the process, so `catch_unwind` does not stop it and every other request the process serves dies with it (spawned threads, a Tokio worker included, get 2 MiB by default). serde_json and serde_yaml stop parsing at 128 levels only on their default path; a value from `disable_recursion_limit`, from another format or parser, or built in code carries whatever nesting it was given. Thread a depth argument through `visit` and reject the value past a fixed maximum, or rewrite the descent with an explicit stack.
  • Recursive walk over a caller-supplied document has no depth cap crates/ibcmd-form-body/src/form_body.rs:10774 — `record_complete_table_schema_events` is public, takes a document from its caller (line 10753) and hands it to `count_tables`, which calls itself at line 10774 with a piece of the document — and nowhere in the walk is a depth or nesting counter compared with a bound. The walk therefore spends one stack frame per LEVEL of the value it is handed, so the nesting of the caller's document — not this code — decides how deep the stack goes. When a Rust thread runs out of stack it is not unwound: the runtime reports the overflow and aborts the process, so `catch_unwind` does not stop it and every other request the process serves dies with it (spawned threads, a Tokio worker included, get 2 MiB by default). serde_json and serde_yaml stop parsing at 128 levels only on their default path; a value from `disable_recursion_limit`, from another format or parser, or built in code carries whatever nesting it was given. Thread a depth argument through `count_tables` and reject the value past a fixed maximum, or rewrite the descent with an explicit stack.
  • Recursive walk over a caller-supplied document has no depth cap crates/ibcmd-form-body/src/form_body.rs:21557 — `apply_form_table_user_settings_groups` is public and takes `items: &mut[FormChildItem]` from its caller, and it calls itself at line 21557 with a piece of the document — and nowhere in the walk is a depth or nesting counter compared with a bound. The walk therefore spends one stack frame per LEVEL of the value it is handed, so the nesting of the caller's document — not this code — decides how deep the stack goes. When a Rust thread runs out of stack it is not unwound: the runtime reports the overflow and aborts the process, so `catch_unwind` does not stop it and every other request the process serves dies with it (spawned threads, a Tokio worker included, get 2 MiB by default). serde_json and serde_yaml stop parsing at 128 levels only on their default path; a value from `disable_recursion_limit`, from another format or parser, or built in code carries whatever nesting it was given. Thread a depth argument through `apply_form_table_user_settings_groups` and reject the value past a fixed maximum, or rewrite the descent with an explicit stack.
  • Recursive walk over a caller-supplied document has no depth cap crates/ibcmd-form-body/src/form_body.rs:32246 — `format_form_child_items_xml` is public and takes `items: &[FormChildItem]` from its caller, and it recurses at line 32246 through `format_form_context_menu_xml`, `format_form_child_item_xml` and back with a piece of the document (and at line 33256, line 33314, line 36158, line 36219, line 36222, line 36231, line 36248, line 36259, line 36271, line 37489) — and nowhere in the walk is a depth or nesting counter compared with a bound. The walk therefore spends one stack frame per LEVEL of the value it is handed, so the nesting of the caller's document — not this code — decides how deep the stack goes. When a Rust thread runs out of stack it is not unwound: the runtime reports the overflow and aborts the process, so `catch_unwind` does not stop it and every other request the process serves dies with it (spawned threads, a Tokio worker included, get 2 MiB by default). serde_json and serde_yaml stop parsing at 128 levels only on their default path; a value from `disable_recursion_limit`, from another format or parser, or built in code carries whatever nesting it was given. Thread a depth argument through `format_form_child_items_xml` and reject the value past a fixed maximum, or rewrite the descent with an explicit stack.
  • Recursive walk over a caller-supplied document has no depth cap crates/ibcmd-form-body/src/form_extension.rs:238 — `mark` is public, takes a document from its caller (line 207) and hands it to `mark_items`, which calls itself at line 238 with a piece of the document — and nowhere in the walk is a depth or nesting counter compared with a bound. The walk therefore spends one stack frame per LEVEL of the value it is handed, so the nesting of the caller's document — not this code — decides how deep the stack goes. When a Rust thread runs out of stack it is not unwound: the runtime reports the overflow and aborts the process, so `catch_unwind` does not stop it and every other request the process serves dies with it (spawned threads, a Tokio worker included, get 2 MiB by default). serde_json and serde_yaml stop parsing at 128 levels only on their default path; a value from `disable_recursion_limit`, from another format or parser, or built in code carries whatever nesting it was given. Thread a depth argument through `mark_items` and reject the value past a fixed maximum, or rewrite the descent with an explicit stack.
  • Recursive walk over a caller-supplied document has no depth cap crates/ibcmd-form-body/src/layout_8_5_1.rs:79 — `to_text` is public, takes a document from its caller (line 64) and hands it to `emit`, which calls itself at line 79 with a piece of the document — and nowhere in the walk is a depth or nesting counter compared with a bound. The walk therefore spends one stack frame per LEVEL of the value it is handed, so the nesting of the caller's document — not this code — decides how deep the stack goes. When a Rust thread runs out of stack it is not unwound: the runtime reports the overflow and aborts the process, so `catch_unwind` does not stop it and every other request the process serves dies with it (spawned threads, a Tokio worker included, get 2 MiB by default). serde_json and serde_yaml stop parsing at 128 levels only on their default path; a value from `disable_recursion_limit`, from another format or parser, or built in code carries whatever nesting it was given. Thread a depth argument through `emit` and reject the value past a fixed maximum, or rewrite the descent with an explicit stack.
  • Recursive walk over a caller-supplied document has no depth cap crates/ibcmd-dump/src/mssql_dump/command_interface.rs:1114 — `push_client_application_interface_group_xml` is public and takes `group: &ClientApplicationInterfaceGroup` from its caller, and it recurses at line 1114 through `push_client_application_interface_node_xml` and back with a piece of the document (and at line 1087) — and nowhere in the walk is a depth or nesting counter compared with a bound. The walk therefore spends one stack frame per LEVEL of the value it is handed, so the nesting of the caller's document — not this code — decides how deep the stack goes. When a Rust thread runs out of stack it is not unwound: the runtime reports the overflow and aborts the process, so `catch_unwind` does not stop it and every other request the process serves dies with it (spawned threads, a Tokio worker included, get 2 MiB by default). serde_json and serde_yaml stop parsing at 128 levels only on their default path; a value from `disable_recursion_limit`, from another format or parser, or built in code carries whatever nesting it was given. Thread a depth argument through `push_client_application_interface_group_xml` and reject the value past a fixed maximum, or rewrite the descent with an explicit stack.
  • Recursive walk over a caller-supplied document has no depth cap crates/ibcmd-dump/src/mssql_dump/source_assets.rs:4203 — `insert_predefined_item_references` is public and takes `items: &[PredefinedItem]` from its caller, and it calls itself at line 4203 with a piece of the document — and nowhere in the walk is a depth or nesting counter compared with a bound. The walk therefore spends one stack frame per LEVEL of the value it is handed, so the nesting of the caller's document — not this code — decides how deep the stack goes. When a Rust thread runs out of stack it is not unwound: the runtime reports the overflow and aborts the process, so `catch_unwind` does not stop it and every other request the process serves dies with it (spawned threads, a Tokio worker included, get 2 MiB by default). serde_json and serde_yaml stop parsing at 128 levels only on their default path; a value from `disable_recursion_limit`, from another format or parser, or built in code carries whatever nesting it was given. Thread a depth argument through `insert_predefined_item_references` and reject the value past a fixed maximum, or rewrite the descent with an explicit stack.
  • Recursive walk over a caller-supplied document has no depth cap crates/ibcmd-dump/src/mssql_dump/source_assets.rs:5258 — `push_predefined_item_xml` is public and takes `item: &PredefinedItem` from its caller, and it calls itself at line 5258 with a piece of the document — and nowhere in the walk is a depth or nesting counter compared with a bound. The walk therefore spends one stack frame per LEVEL of the value it is handed, so the nesting of the caller's document — not this code — decides how deep the stack goes. When a Rust thread runs out of stack it is not unwound: the runtime reports the overflow and aborts the process, so `catch_unwind` does not stop it and every other request the process serves dies with it (spawned threads, a Tokio worker included, get 2 MiB by default). serde_json and serde_yaml stop parsing at 128 levels only on their default path; a value from `disable_recursion_limit`, from another format or parser, or built in code carries whatever nesting it was given. Thread a depth argument through `push_predefined_item_xml` and reject the value past a fixed maximum, or rewrite the descent with an explicit stack.
  • Recursive walk over a caller-supplied document has no depth cap crates/ibcmd-core/src/value.rs:595 — `clone` is public and takes a `CanonicalValue` as its receiver from its caller, and it calls itself at line 595 with a piece of the document (and at line 596, line 597, line 598, line 599, line 600, line 602, line 611) — and nowhere in the walk is a depth or nesting counter compared with a bound. The walk therefore spends one stack frame per LEVEL of the value it is handed, so the nesting of the caller's document — not this code — decides how deep the stack goes. When a Rust thread runs out of stack it is not unwound: the runtime reports the overflow and aborts the process, so `catch_unwind` does not stop it and every other request the process serves dies with it (spawned threads, a Tokio worker included, get 2 MiB by default). serde_json and serde_yaml stop parsing at 128 levels only on their default path; a value from `disable_recursion_limit`, from another format or parser, or built in code carries whatever nesting it was given. Thread a depth argument through `clone` and reject the value past a fixed maximum, or rewrite the descent with an explicit stack.
D4 · Code Duplication · Edited copy of a member (11 corresponding lines) · ×20
  • Edited copy of a member (11 corresponding lines) crates/ibcmd-form-body/src/form_body.rs:3099 — crates/ibcmd-form-body/src/form_body.rs:3099-3115 | crates/ibcmd-form-body/src/form_body.rs:3117-3140 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (11 corresponding lines) crates/ibcmd-dump/src/mssql_dump/mod.rs:14819 — crates/ibcmd-dump/src/mssql_dump/mod.rs:14819-14829 | crates/ibcmd-form-body/src/form_body.rs:11188-11198 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (11 corresponding lines) crates/ibcmd-xml/src/dcs.rs:3181 — crates/ibcmd-xml/src/dcs.rs:3181-3191 | crates/ibcmd-xml/src/dcs.rs:3499-3511 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (11 corresponding lines) crates/ibcmd-compiler/src/compiler/bodies/mxl_native.rs:2410 — crates/ibcmd-compiler/src/compiler/bodies/mxl_native.rs:2410-2420 | crates/ibcmd-compiler/src/compiler/bodies/mxl_native.rs:2617-2631 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (11 corresponding lines) crates/ibcmd-form-writer/src/form/xml_2_21_writer.rs:184 — crates/ibcmd-form-writer/src/form/xml_2_21_writer.rs:184-197 | crates/ibcmd-form-writer/src/form/xml_2_21_writer.rs:270-280 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (11 corresponding lines) crates/ibcmd-xml/src/comparison.rs:71 — crates/ibcmd-xml/src/comparison.rs:71-81 | crates/ibcmd-xml/src/source_comparison.rs:88-98 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (11 corresponding lines) crates/ibcmd-restructure-engine/src/restructure/catalog.rs:310 — crates/ibcmd-restructure-engine/src/restructure/catalog.rs:310-321 | crates/ibcmd-restructure-engine/src/restructure/object.rs:119-129 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (11 corresponding lines) crates/ibcmd-form-writer/src/lib.rs:15612 — crates/ibcmd-form-writer/src/lib.rs:15612-15625 | crates/ibcmd-form-writer/src/lib.rs:15826-15836 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (11 corresponding lines) crates/ibcmd-form-body/src/form_body.rs:16967 — crates/ibcmd-form-body/src/form_body.rs:16967-16977 | crates/ibcmd-form-body/src/form_body.rs:40066-40079 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (11 corresponding lines) crates/ibcmd-dump/src/mssql_dump/cas.rs:763 — crates/ibcmd-dump/src/mssql_dump/cas.rs:763-773 | REDACTED:816-832 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (11 corresponding lines) crates/ibcmd-compiler-families/src/compiler/families/assets.rs:65 — crates/ibcmd-compiler-families/src/compiler/families/assets.rs:65-75 | crates/ibcmd-compiler-families/src/compiler/families/assets.rs:77-87 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (11 corresponding lines) crates/ibcmd-dump/src/mssql_dump/cas.rs:776 — crates/ibcmd-dump/src/mssql_dump/cas.rs:776-786 | REDACTED:1105-1115 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (11 corresponding lines) crates/ibcmd-compiler/src/compiler/root.rs:1208 — crates/ibcmd-compiler/src/compiler/root.rs:1208-1218 | crates/ibcmd-form-writer/src/lib.rs:23813-23823 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (11 corresponding lines) crates/ibcmd-dump/src/mssql_dump/command_interface.rs:178 — crates/ibcmd-dump/src/mssql_dump/command_interface.rs:178-191 | crates/ibcmd-dump/src/mssql_dump/selected.rs:328-338 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (11 corresponding lines) crates/ibcmd-xml/src/dcs.rs:824 — crates/ibcmd-xml/src/dcs.rs:824-834 | crates/ibcmd-xml/src/dcs.rs:1473-1483 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (11 corresponding lines) crates/ibcmd-dump/src/mssql_dump/source_assets.rs:6011 — crates/ibcmd-dump/src/mssql_dump/source_assets.rs:6011-6021 | crates/ibcmd-dump/src/mssql_dump/source_assets.rs:6023-6033 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (11 corresponding lines) crates/ibcmd-xml/src/metadata/business_objects.rs:1113 — crates/ibcmd-xml/src/metadata/business_objects.rs:1113-1126 | crates/ibcmd-xml/src/metadata/business_objects.rs:1188-1198 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (11 corresponding lines) crates/ibcmd-dump/src/mssql_dump/mod.rs:27945 — crates/ibcmd-dump/src/mssql_dump/mod.rs:27945-27955 | crates/ibcmd-dump/src/mssql_dump/mod.rs:31869-31880 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (11 corresponding lines) src/dump_sources.rs:632 — src/dump_sources.rs:632-644 | src/infobase.rs:1409-1419 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (11 corresponding lines) crates/ibcmd-metadata-blob/src/lib.rs:4918 — crates/ibcmd-metadata-blob/src/lib.rs:4918-4928 | crates/ibcmd-metadata-blob/src/lib.rs:4939-4955 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copy of a member (14 corresponding lines) · ×20
  • Edited copy of a member (14 corresponding lines) crates/ibcmd-restructure-engine/src/restructure/caches/xdto_types.rs:76 — crates/ibcmd-restructure-engine/src/restructure/caches/xdto_types.rs:76-91 | crates/ibcmd-restructure-engine/src/restructure/xdto.rs:53-66 — These two members are one piece of code written twice and then edited apart: 14 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (14 corresponding lines) crates/ibcmd-dump/src/mssql_dump/refs.rs:4041 — crates/ibcmd-dump/src/mssql_dump/refs.rs:4041-4060 | crates/ibcmd-moxel/src/lib.rs:10543-10556 — These two members are one piece of code written twice and then edited apart: 14 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (14 corresponding lines) crates/ibcmd-restructure/src/schema.rs:379 — crates/ibcmd-restructure/src/schema.rs:379-392 | crates/ibcmd-restructure/src/schema.rs:407-422 — These two members are one piece of code written twice and then edited apart: 14 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (14 corresponding lines) crates/ibcmd-dump/src/mssql_dump/source_assets.rs:4430 — crates/ibcmd-dump/src/mssql_dump/source_assets.rs:4430-4443 | crates/ibcmd-dump/src/mssql_dump/source_assets.rs:4760-4777 — These two members are one piece of code written twice and then edited apart: 14 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (14 corresponding lines) src/load/index.rs:116 — src/load/index.rs:116-129 | src/source.rs:213-230 — These two members are one piece of code written twice and then edited apart: 14 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (14 corresponding lines) crates/ibcmd-form-body/src/form_body.rs:17232 — crates/ibcmd-form-body/src/form_body.rs:17232-17246 | crates/ibcmd-moxel/src/lib.rs:7801-7814 — These two members are one piece of code written twice and then edited apart: 14 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (14 corresponding lines) crates/ibcmd-metadata-model/src/metadata_model/objects_parts.rs:235 — crates/ibcmd-metadata-model/src/metadata_model/objects_parts.rs:235-249 | crates/ibcmd-metadata-model/src/metadata_model/objects_parts.rs:272-285 — These two members are one piece of code written twice and then edited apart: 14 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (14 corresponding lines) crates/ibcmd-form-body/src/dcs.rs:1285 — crates/ibcmd-form-body/src/dcs.rs:1285-1298 | crates/ibcmd-form-body/src/dcs.rs:1381-1396 — These two members are one piece of code written twice and then edited apart: 14 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (14 corresponding lines) crates/ibcmd-metadata-model/src/metadata_model/types.rs:156 — crates/ibcmd-metadata-model/src/metadata_model/types.rs:156-169 | crates/ibcmd-metadata-model/src/metadata_model/types.rs:202-215 — These two members are one piece of code written twice and then edited apart: 14 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (14 corresponding lines) crates/ibcmd-form-writer/src/form/load_8_5_1.rs:2056 — crates/ibcmd-form-writer/src/form/load_8_5_1.rs:2056-2069 | crates/ibcmd-form-writer/src/form/load_8_5_1.rs:2071-2086 — These two members are one piece of code written twice and then edited apart: 14 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (14 corresponding lines) crates/ibcmd-xml/src/source_tree/reader.rs:93 — crates/ibcmd-xml/src/source_tree/reader.rs:93-106 | crates/ibcmd-xml/src/source_tree/reader.rs:175-188 — These two members are one piece of code written twice and then edited apart: 14 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (14 corresponding lines) crates/ibcmd-metadata-model/src/metadata_model/simple_export.rs:108 — crates/ibcmd-metadata-model/src/metadata_model/simple_export.rs:108-121 | crates/ibcmd-metadata-model/src/metadata_model/simple_export.rs:241-254 — These two members are one piece of code written twice and then edited apart: 14 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (14 corresponding lines) crates/ibcmd-compiler-families/src/compiler/families/business_object/register_native.rs:318 — crates/ibcmd-compiler-families/src/compiler/families/business_object/register_native.rs:318-334 | crates/ibcmd-compiler-families/src/compiler/families/business_object/register_native.rs:712-725 — These two members are one piece of code written twice and then edited apart: 14 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (14 corresponding lines) src/mssql_managed_worker/cli.rs:589 — src/mssql_managed_worker/cli.rs:589-602 | src/mssql_managed_worker/cli.rs:608-621 — These two members are one piece of code written twice and then edited apart: 14 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (14 corresponding lines) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:2784 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:2784-2797 | crates/ibcmd-compiler-families/src/compiler/families/services.rs:2442-2455 — These two members are one piece of code written twice and then edited apart: 14 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (14 corresponding lines) REDACTED:416 — REDACTED:416-429 | REDACTED:822-835 — These two members are one piece of code written twice and then edited apart: 14 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (14 corresponding lines) crates/ibcmd-dump/src/mssql_dump/mod.rs:38147 — crates/ibcmd-dump/src/mssql_dump/mod.rs:38147-38160 | crates/ibcmd-dump/src/mssql_dump/mod.rs:39854-39867 — These two members are one piece of code written twice and then edited apart: 14 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (14 corresponding lines) crates/ibcmd-dump/src/mssql_dump/refs.rs:1067 — crates/ibcmd-dump/src/mssql_dump/refs.rs:1067-1082 | crates/ibcmd-dump/src/mssql_dump/refs.rs:1124-1137 — These two members are one piece of code written twice and then edited apart: 14 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (14 corresponding lines) crates/ibcmd-xml/src/dcs.rs:2633 — crates/ibcmd-xml/src/dcs.rs:2633-2646 | crates/ibcmd-xml/src/dcs.rs:3946-3959 — These two members are one piece of code written twice and then edited apart: 14 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (14 corresponding lines) scripts/apply-trace/lab/s1g-caches/make_cases_n.py:181 — scripts/apply-trace/lab/s1g-caches/make_cases_n.py:181-196 | scripts/apply-trace/lab/s1g-caches/make_cases_n.py:221-237 — These two members are one piece of code written twice and then edited apart: 14 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copy of a member (9 corresponding lines) · ×20
  • Edited copy of a member (9 corresponding lines) REDACTED:6092 — REDACTED:6092-6100 | src/mssql/empty_stage.rs:290-298 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (9 corresponding lines) crates/ibcmd-form-body/src/form_body.rs:17774 — crates/ibcmd-form-body/src/form_body.rs:17774-17782 | crates/ibcmd-form-body/src/form_body.rs:17788-17796 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (9 corresponding lines) crates/ibcmd-form-body/src/form_body.rs:3613 — crates/ibcmd-form-body/src/form_body.rs:3613-3621 | crates/ibcmd-form-writer/src/lib.rs:15977-15985 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (9 corresponding lines) crates/ibcmd-metadata-blob/src/lib.rs:4445 — crates/ibcmd-metadata-blob/src/lib.rs:4445-4455 | crates/ibcmd-metadata-blob/src/lib.rs:4457-4465 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (9 corresponding lines) REDACTED:708 — REDACTED:708-716 | src/mssql_extensions.rs:848-856 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (9 corresponding lines) crates/ibcmd-metadata-model/src/metadata_model/registers.rs:261 — crates/ibcmd-metadata-model/src/metadata_model/registers.rs:261-269 | crates/ibcmd-metadata-model/src/metadata_model/registers.rs:331-339 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (9 corresponding lines) crates/ibcmd-form-writer/src/lib.rs:16394 — crates/ibcmd-form-writer/src/lib.rs:16394-16402 | crates/ibcmd-form-writer/src/lib.rs:16405-16413 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (9 corresponding lines) crates/ibcmd-form-schema/src/lib.rs:1027 — crates/ibcmd-form-schema/src/lib.rs:1027-1036 | crates/ibcmd-form-schema/src/lib.rs:1083-1091 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (9 corresponding lines) crates/ibcmd-compiler/src/compiler/root.rs:499 — crates/ibcmd-compiler/src/compiler/root.rs:499-507 | crates/ibcmd-compiler/src/compiler/version.rs:170-182 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (9 corresponding lines) crates/ibcmd-metadata-model/src/metadata_model/index.rs:156 — crates/ibcmd-metadata-model/src/metadata_model/index.rs:156-165 | crates/ibcmd-metadata-model/src/metadata_model/index.rs:170-178 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (9 corresponding lines) crates/ibcmd-compiler-families/src/compiler/families/form.rs:567 — crates/ibcmd-compiler-families/src/compiler/families/form.rs:567-575 | crates/ibcmd-xml/src/metadata/websocket_client.rs:17-25 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (9 corresponding lines) crates/ibcmd-form-body/src/form_body.rs:3863 — crates/ibcmd-form-body/src/form_body.rs:3863-3871 | crates/ibcmd-form-body/src/form_body.rs:19687-19697 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (9 corresponding lines) crates/ibcmd-dump/src/mssql_dump/source_assets.rs:4942 — crates/ibcmd-dump/src/mssql_dump/source_assets.rs:4942-4951 | crates/ibcmd-dump/src/mssql_dump/mod.rs:34598-34606 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (9 corresponding lines) crates/ibcmd-form-body/src/form_body.rs:4372 — crates/ibcmd-form-body/src/form_body.rs:4372-4381 | crates/ibcmd-form-writer/src/lib.rs:7951-7959 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (9 corresponding lines) REDACTED:235 — REDACTED:235-243 | crates/ibcmd-mssql-live/src/mssql_recovery_artifact.rs:70-78 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (9 corresponding lines) crates/ibcmd-dump/src/mssql_dump/model_export.rs:776 — crates/ibcmd-dump/src/mssql_dump/model_export.rs:776-784 | crates/ibcmd-dump/src/mssql_dump/source_assets.rs:2214-2222 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (9 corresponding lines) REDACTED:233 — REDACTED:233-241 | REDACTED:310-322 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (9 corresponding lines) src/form_matrix.rs:94 — src/form_matrix.rs:94-102 | src/plan.rs:835-843 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (9 corresponding lines) crates/ibcmd-metadata-blob/src/interface_assets.rs:100 — crates/ibcmd-metadata-blob/src/interface_assets.rs:100-109 | crates/ibcmd-module-blob/src/raw.rs:21-29 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (9 corresponding lines) crates/ibcmd-1c-vocab/src/types.rs:366 — crates/ibcmd-1c-vocab/src/types.rs:366-375 | crates/ibcmd-form-schema/src/lib.rs:152-160 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Duplicated block (6 lines × 3) · ×20
  • Duplicated block (6 lines × 3) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:736 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:736-741 | crates/ibcmd-compiler-families/src/compiler/families/services.rs:1428-1433 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:1187-1192 — before extracting anything, compare `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs` and `crates/ibcmd-compiler-families/src/compiler/families/services.rs` as WHOLE FILES: this scan already matched 10 separate duplicated blocks between them, totalling at least 103 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:736` it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows — the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members' bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run — a one-line delegation has no helper inside it to lift — so generate the run from the set it enumerates, or accept it and keep each member's own documentation with it.
  • Duplicated block (6 lines × 3) crates/ibcmd-dump/src/mssql_dump/mod.rs:5128 — crates/ibcmd-dump/src/mssql_dump/mod.rs:5128-5133 | crates/ibcmd-dump/src/mssql_dump/mod.rs:5178-5183 | crates/ibcmd-dump/src/mssql_dump/mod.rs:5241-5246 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited.
  • Duplicated block (6 lines × 3) crates/ibcmd-dump/src/mssql_dump/mod.rs:5127 — crates/ibcmd-dump/src/mssql_dump/mod.rs:5127-5133 | crates/ibcmd-dump/src/mssql_dump/mod.rs:5199-5204 | crates/ibcmd-dump/src/mssql_dump/mod.rs:5240-5246 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:5127` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (6 lines × 3) crates/ibcmd-dump/src/mssql_dump/mod.rs:38190 — crates/ibcmd-dump/src/mssql_dump/mod.rs:38190-38195 | crates/ibcmd-dump/src/mssql_dump/mod.rs:39876-39881 | crates/ibcmd-dump/src/mssql_dump/mod.rs:40061-40066 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:38190` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, `crates/ibcmd-dump/src/mssql_dump/mod.rs:40059` calls `acknowledge_internal_only` and `crates/ibcmd-dump/src/mssql_dump/mod.rs:39874` does not — after which the two agree again for 3 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
  • Duplicated block (6 lines × 3) crates/ibcmd-form-body/src/form_body.rs:3102 — crates/ibcmd-form-body/src/form_body.rs:3102-3107 | crates/ibcmd-form-body/src/form_body.rs:3120-3125 | crates/ibcmd-form-body/src/form_body.rs:3147-3152 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-form-body/src/form_body.rs:3102` it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows — the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members' bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run — a one-line delegation has no helper inside it to lift — so generate the run from the set it enumerates, or accept it and keep each member's own documentation with it.
  • Duplicated block (6 lines × 3) crates/ibcmd-form-writer/src/form/xml_2_21_writer.rs:189 — crates/ibcmd-form-writer/src/form/xml_2_21_writer.rs:189-194 | crates/ibcmd-form-writer/src/form/xml_2_21_writer.rs:273-278 | crates/ibcmd-form-writer/src/form/xml_2_21_writer.rs:330-337 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited.
  • Duplicated block (6 lines × 3) crates/ibcmd-form-writer/src/lib.rs:21455 — crates/ibcmd-form-writer/src/lib.rs:21455-21460 | crates/ibcmd-form-writer/src/lib.rs:21713-21718 | crates/ibcmd-form-writer/src/lib.rs:21909-21914 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (6 lines × 3) crates/ibcmd-metadata-blob/src/lib.rs:2454 — crates/ibcmd-metadata-blob/src/lib.rs:2454-2459 | crates/ibcmd-metadata-blob/src/lib.rs:2699-2704 | crates/ibcmd-metadata-blob/src/lib.rs:2812-2817 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited.
  • Duplicated block (6 lines × 3) REDACTED:1418 — REDACTED:1418-1423 | REDACTED:1468-1473 | REDACTED:2433-2438 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `REDACTED:1418` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (6 lines × 3) crates/ibcmd-xml/src/metadata/business_objects.rs:387 — crates/ibcmd-xml/src/metadata/business_objects.rs:387-392 | crates/ibcmd-xml/src/metadata/register_objects.rs:446-451 | crates/ibcmd-xml/src/metadata/utility_objects.rs:293-298 — before extracting anything, compare `crates/ibcmd-xml/src/metadata/business_objects.rs` and `crates/ibcmd-xml/src/metadata/register_objects.rs` as WHOLE FILES: this scan already matched 6 separate duplicated blocks between them, totalling at least 54 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-xml/src/metadata/business_objects.rs:387` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (6 lines × 3) crates/ibcmd-xml/src/metadata/constant.rs:1398 — crates/ibcmd-xml/src/metadata/constant.rs:1398-1403 | crates/ibcmd-xml/src/metadata/external_objects.rs:693-698 | crates/ibcmd-xml/src/metadata/language.rs:655-660 — before extracting anything, compare `crates/ibcmd-xml/src/metadata/constant.rs` and `crates/ibcmd-xml/src/metadata/language.rs` as WHOLE FILES: this scan already matched 19 separate duplicated blocks between them, totalling at least 213 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-xml/src/metadata/constant.rs:1398` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (6 lines × 3) crates/ibcmd-xml/src/metadata/services.rs:869 — crates/ibcmd-xml/src/metadata/services.rs:869-874 | crates/ibcmd-xml/src/metadata/services.rs:911-916 | crates/ibcmd-xml/src/metadata/services.rs:961-966 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-xml/src/metadata/services.rs:869` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (6 lines × 3) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:2766 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:2766-2771 | crates/ibcmd-compiler-families/src/compiler/families/services.rs:2435-2440 | crates/ibcmd-compiler-families/src/compiler/families/utility.rs:1426-1431 — before extracting anything, compare `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs` and `crates/ibcmd-compiler-families/src/compiler/families/services.rs` as WHOLE FILES: this scan already matched 10 separate duplicated blocks between them, totalling at least 103 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place.
  • Duplicated block (6 lines × 3) crates/ibcmd-metadata-model/src/metadata_model/index.rs:129 — crates/ibcmd-metadata-model/src/metadata_model/index.rs:129-134 | src/stored_objects.rs:293-298 | src/stored_objects.rs:518-523 — there are 3 copies across 2 file(s) — more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 3 sites; resolving a subset leaves the remainder to drift apart.
  • Duplicated block (6 lines × 3) crates/ibcmd-xml/src/metadata/functional_option.rs:326 — crates/ibcmd-xml/src/metadata/functional_option.rs:326-331 | crates/ibcmd-xml/src/metadata/functional_options_parameter.rs:308-313 | crates/ibcmd-xml/src/metadata/session_parameter.rs:692-697 — before extracting anything, compare `crates/ibcmd-xml/src/metadata/functional_option.rs` and `crates/ibcmd-xml/src/metadata/functional_options_parameter.rs` as WHOLE FILES: this scan already matched 17 separate duplicated blocks between them, totalling at least 156 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place.
  • Duplicated block (6 lines × 3) crates/ibcmd-metadata-model/src/metadata_model/registers_export.rs:1005 — crates/ibcmd-metadata-model/src/metadata_model/registers_export.rs:1005-1010 | crates/ibcmd-metadata-model/src/metadata_model/registers_export.rs:1064-1069 | crates/ibcmd-metadata-model/src/metadata_model/registers_export.rs:1109-1114 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-metadata-model/src/metadata_model/registers_export.rs:1005` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, `crates/ibcmd-metadata-model/src/metadata_model/registers_export.rs:1107` calls `list`, `item` and `crates/ibcmd-metadata-model/src/metadata_model/registers_export.rs:1003` does not — after which the two agree again for 3 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
  • Duplicated block (6 lines × 3) crates/ibcmd-xml/src/metadata/functional_options_parameter.rs:145 — crates/ibcmd-xml/src/metadata/functional_options_parameter.rs:145-150 | crates/ibcmd-xml/src/metadata/language.rs:215-220 | crates/ibcmd-xml/src/metadata/session_parameter.rs:269-274 — before extracting anything, compare `crates/ibcmd-xml/src/metadata/functional_options_parameter.rs` and `crates/ibcmd-xml/src/metadata/session_parameter.rs` as WHOLE FILES: this scan already matched 11 separate duplicated blocks between them, totalling at least 101 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-xml/src/metadata/functional_options_parameter.rs:145` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (6 lines × 3) crates/ibcmd-form-body/src/form_body.rs:39159 — crates/ibcmd-form-body/src/form_body.rs:39159-39164 | crates/ibcmd-form-body/src/form_body.rs:39495-39500 | crates/ibcmd-form-body/src/form_body.rs:39518-39523 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-form-body/src/form_body.rs:39159` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, `crates/ibcmd-form-body/src/form_body.rs:39502` calls `get`, `trim` and `crates/ibcmd-form-body/src/form_body.rs:39166` does not — after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
  • Duplicated block (6 lines × 3) crates/ibcmd-metadata-blob/src/lib.rs:1967 — crates/ibcmd-metadata-blob/src/lib.rs:1967-1972 | crates/ibcmd-metadata-blob/src/lib.rs:5154-5159 | crates/ibcmd-metadata-blob/src/lib.rs:6108-6113 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-metadata-blob/src/lib.rs:1967` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (6 lines × 3) crates/ibcmd-dump/src/mssql_dump/mod.rs:18998 — crates/ibcmd-dump/src/mssql_dump/mod.rs:18998-19003 | crates/ibcmd-dump/src/mssql_dump/mod.rs:26436-26441 | crates/ibcmd-dump/src/mssql_dump/mod.rs:26578-26583 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. Note first that the copies are not typed on the same thing: the declarations holding them bind `definitions` to `&[]` in one and `&[ChartStandardTabularSectionDefinition]` in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH — their common supertype where they have one, or a new abstraction over them where they do not — and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract.
D4 · Code Duplication · Duplicated block (8 lines × 3) · ×19
  • Duplicated block (8 lines × 3) crates/ibcmd-compiler-families/src/compiler/families/commands.rs:1230 — crates/ibcmd-compiler-families/src/compiler/families/commands.rs:1230-1237 | crates/ibcmd-compiler-families/src/compiler/families/form.rs:985-992 | crates/ibcmd-compiler-families/src/compiler/families/modules.rs:438-445 — before extracting anything, compare `crates/ibcmd-compiler-families/src/compiler/families/commands.rs` and `crates/ibcmd-compiler-families/src/compiler/families/form.rs` as WHOLE FILES: this scan already matched 3 separate duplicated blocks between them, totalling at least 37 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/commands.rs:1230` it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows — the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members' bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run — a one-line delegation has no helper inside it to lift — so generate the run from the set it enumerates, or accept it and keep each member's own documentation with it.
  • Duplicated block (8 lines × 3) crates/ibcmd-compiler-families/src/compiler/families/services.rs:2786 — crates/ibcmd-compiler-families/src/compiler/families/services.rs:2786-2793 | crates/ibcmd-compiler-families/src/compiler/families/services.rs:2853-2860 | crates/ibcmd-compiler-families/src/compiler/families/services.rs:2948-2955 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/services.rs:2786` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (8 lines × 3) crates/ibcmd-dump/src/mssql_dump/mod.rs:9127 — crates/ibcmd-dump/src/mssql_dump/mod.rs:9127-9134 | crates/ibcmd-dump/src/mssql_dump/mod.rs:14792-14799 | crates/ibcmd-dump/src/mssql_dump/mod.rs:14838-14845 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, `crates/ibcmd-dump/src/mssql_dump/mod.rs:14789` calls `first`, `trim`, `Some` and `crates/ibcmd-dump/src/mssql_dump/mod.rs:9126` does not — after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
  • Duplicated block (8 lines × 3) crates/ibcmd-dump/src/mssql_dump/refs.rs:790 — crates/ibcmd-dump/src/mssql_dump/refs.rs:790-797 | crates/ibcmd-dump/src/mssql_dump/refs.rs:1257-1264 | crates/ibcmd-dump/src/mssql_dump/refs.rs:2866-2873 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/refs.rs:790` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (8 lines × 3) crates/ibcmd-form-body/src/dcs.rs:3705 — crates/ibcmd-form-body/src/dcs.rs:3705-3712 | crates/ibcmd-xml/src/dcs_schema.rs:2866-2873 | REDACTED:586-593 — before extracting anything, compare `crates/ibcmd-xml/src/dcs_schema.rs` and `REDACTED` as WHOLE FILES: this scan already matched 4 separate duplicated blocks between them, totalling at least 39 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place.
  • Duplicated block (8 lines × 3) crates/ibcmd-form-body/src/form_body.rs:21167 — crates/ibcmd-form-body/src/form_body.rs:21167-21174 | crates/ibcmd-form-body/src/form_body.rs:21204-21211 | crates/ibcmd-form-body/src/form_body.rs:21242-21249 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (8 lines × 3) crates/ibcmd-form-writer/src/lib.rs:18483 — crates/ibcmd-form-writer/src/lib.rs:18483-18490 | crates/ibcmd-form-writer/src/lib.rs:22099-22106 | crates/ibcmd-form-writer/src/lib.rs:22948-22955 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Note first that the copies are not typed on the same thing: the declarations holding them bind `text` to `&str` in one and `&mut String` in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH — their common supertype where they have one, or a new abstraction over them where they do not — and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract.
  • Duplicated block (8 lines × 3) src/form_provenance.rs:599 — src/form_provenance.rs:599-606 | src/form_provenance.rs:614-621 | src/form_provenance.rs:629-636 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `src/form_provenance.rs:599` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, `src/form_provenance.rs:607` calls `Some` and `src/form_provenance.rs:637` does not — after which the two agree again for 3 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
  • Duplicated block (8 lines × 3) REDACTED:1003 — REDACTED:1003-1010 | src/mssql_extension_load.rs:143-150 | src/mssql_extension_load.rs:401-408 — there are 3 copies across 2 file(s) — more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 3 sites; resolving a subset leaves the remainder to drift apart. Read the line range as the matched WINDOW rather than a finished unit: at `REDACTED:1003` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note first that the copies are not typed on the same thing: the declarations holding them bind `args` to `&MssqlActivateStagedMainArgs` in one and `&MssqlLoadExtensionArgs` in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH — their common supertype where they have one, or a new abstraction over them where they do not — and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract.
  • Duplicated block (8 lines × 3) crates/ibcmd-core/src/dcs.rs:1341 — crates/ibcmd-core/src/dcs.rs:1341-1348 | crates/ibcmd-core/src/dcs.rs:1372-1379 | crates/ibcmd-core/src/dcs.rs:1406-1413 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-core/src/dcs.rs:1341` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (8 lines × 3) crates/ibcmd-form-native/src/lib.rs:176 — crates/ibcmd-form-native/src/lib.rs:176-183 | crates/ibcmd-metadata-model/src/metadata_model/objects_parts.rs:1213-1220 | crates/ibcmd-metadata-model/src/metadata_model/registers_parts.rs:628-635 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 3 call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made 3 times.
  • Duplicated block (8 lines × 3) crates/ibcmd-compiler-families/src/compiler/families/commands.rs:1372 — crates/ibcmd-compiler-families/src/compiler/families/commands.rs:1372-1379 | crates/ibcmd-compiler-families/src/compiler/families/form.rs:1089-1096 | crates/ibcmd-compiler-families/src/compiler/families/modules.rs:538-545 — before extracting anything, compare `crates/ibcmd-compiler-families/src/compiler/families/commands.rs` and `crates/ibcmd-compiler-families/src/compiler/families/form.rs` as WHOLE FILES: this scan already matched 3 separate duplicated blocks between them, totalling at least 37 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place.
  • Duplicated block (8 lines × 3) crates/ibcmd-compiler-families/src/compiler/families/services.rs:2633 — crates/ibcmd-compiler-families/src/compiler/families/services.rs:2633-2640 | crates/ibcmd-dump/src/mssql_dump/mod.rs:34897-34904 | crates/ibcmd-dump/src/mssql_dump/mod.rs:35622-35629 — before extracting anything, compare `crates/ibcmd-compiler-families/src/compiler/families/services.rs` and `crates/ibcmd-dump/src/mssql_dump/mod.rs` as WHOLE FILES: this scan already matched 4 separate duplicated blocks between them, totalling at least 41 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. The two sit in different directories, so one cannot simply be deleted in favour of the other while both are reached separately: hoist the shared part into a location both already depend on and have each file call it, and retire whichever file turns out to have no caller of its own left. Extracting one helper per block leaves the fork in place.
  • Duplicated block (8 lines × 3) crates/ibcmd-form-writer/src/lib.rs:10446 — crates/ibcmd-form-writer/src/lib.rs:10446-10453 | crates/ibcmd-form-writer/src/lib.rs:10493-10500 | crates/ibcmd-form-writer/src/lib.rs:10809-10819 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-form-writer/src/lib.rs:10446` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (8 lines × 3) crates/ibcmd-dump/src/mssql_dump/mod.rs:14990 — crates/ibcmd-dump/src/mssql_dump/mod.rs:14990-14997 | crates/ibcmd-dump/src/mssql_dump/mod.rs:17293-17302 | crates/ibcmd-dump/src/mssql_dump/mod.rs:19052-19060 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:14990` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (8 lines × 3) crates/ibcmd-xml/src/dcs.rs:2538 — crates/ibcmd-xml/src/dcs.rs:2538-2545 | crates/ibcmd-xml/src/dcs.rs:3421-3428 | crates/ibcmd-xml/src/dcs.rs:3877-3884 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-xml/src/dcs.rs:2538` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (8 lines × 3) crates/ibcmd-metadata-model/src/metadata_model/registers_export.rs:649 — crates/ibcmd-metadata-model/src/metadata_model/registers_export.rs:649-656 | crates/ibcmd-metadata-model/src/metadata_model/registers_export.rs:856-863 | crates/ibcmd-metadata-model/src/metadata_model/registers_export.rs:1030-1037 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-metadata-model/src/metadata_model/registers_export.rs:649` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (8 lines × 3) crates/ibcmd-dump/src/mssql_dump/mod.rs:14687 — crates/ibcmd-dump/src/mssql_dump/mod.rs:14687-14694 | crates/ibcmd-dump/src/mssql_dump/mod.rs:35190-35197 | crates/ibcmd-dump/src/mssql_dump/mod.rs:35596-35603 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited.
  • Duplicated block (8 lines × 3) src/source_audit.rs:293 — src/source_audit.rs:293-300 | src/source_audit.rs:577-584 | src/source_audit.rs:692-699 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `src/source_audit.rs:293` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
D2 · Cognitive Complexity · ibcmd_config_apply · ×18
  • ibcmd_config_apply::mssql_config_apply::dynamic::plan_dynamic (cognitive 156) REDACTED:1133 — ibcmd_config_apply::mssql_config_apply::dynamic::plan_dynamic has cognitive complexity 156 (threshold 15). Drivers by points: if/else 71 (104 pts), match/switch 8 (23 pts), boolean chains 18, loops 6 (11 pts) (nesting depth added 53). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_config_apply::mssql_config_apply::removals::analyze (cognitive 133) REDACTED:112 — ibcmd_config_apply::mssql_config_apply::removals::analyze has cognitive complexity 133 (threshold 15). Drivers by points: if/else 47 (93 pts), loops 15 (22 pts), match/switch 5 (12 pts), boolean chains 6 (nesting depth added 60). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_config_apply::mssql_config_apply::objects::analyze (cognitive 112) REDACTED:238 — ibcmd_config_apply::mssql_config_apply::objects::analyze has cognitive complexity 112 (threshold 15). Drivers by points: if/else 32 (69 pts), loops 15 (29 pts), match/switch 4 (8 pts), boolean chains 6 (nesting depth added 55). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_config_apply::mssql_config_apply::plan_with_gate (cognitive 108) crates/ibcmd-config-apply/src/mssql_config_apply/mod.rs:972 — ibcmd_config_apply::mssql_config_apply::plan_with_gate has cognitive complexity 108 (threshold 15). Drivers by points: if/else 53 (75 pts), boolean chains 19, loops 6 (8 pts), match/switch 3 (6 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.
  • ibcmd_config_apply::mssql_config_apply::dynamic::judge_rows (cognitive 51) REDACTED:340 — ibcmd_config_apply::mssql_config_apply::dynamic::judge_rows has cognitive complexity 51 (threshold 15). Drivers by points: if/else 13 (34 pts), match/switch 4 (11 pts), boolean chains 4, loops 2 (nesting depth added 28). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_config_apply::mssql_config_apply::objects::plan_search_info (cognitive 49) REDACTED:754 — ibcmd_config_apply::mssql_config_apply::objects::plan_search_info has cognitive complexity 49 (threshold 15). Drivers by points: if/else 17 (35 pts), loops 6 (13 pts), boolean chains 1 (nesting depth added 25). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_config_apply::mssql_config_apply::recovery::write_recovery (cognitive 37) crates/ibcmd-config-apply/src/mssql_config_apply/recovery.rs:303 — ibcmd_config_apply::mssql_config_apply::recovery::write_recovery has cognitive complexity 37 (threshold 15). Drivers by points: loops 11 (22 pts), if/else 11 (12 pts), match/switch 2 (3 pts) (nesting depth added 13). 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.
  • ibcmd_config_apply::mssql_config_apply::dynamic::object_kinds (cognitive 34) REDACTED:637 — ibcmd_config_apply::mssql_config_apply::dynamic::object_kinds has cognitive complexity 34 (threshold 15). Drivers by points: if/else 10 (21 pts), loops 7 (9 pts), boolean chains 4 (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_config_apply::mssql_config_apply::sqlgen::render_apply_script (cognitive 25) REDACTED:377 — ibcmd_config_apply::mssql_config_apply::sqlgen::render_apply_script has cognitive complexity 25 (threshold 15). Drivers by points: if/else 16 (19 pts), loops 3 (4 pts), boolean chains 2 (nesting depth added 4). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level.
  • ibcmd_config_apply::restructure::s1::decide (cognitive 24) crates/ibcmd-config-apply/src/restructure/s1.rs:159 — ibcmd_config_apply::restructure::s1::decide has cognitive complexity 24 (threshold 15). Drivers by points: if/else 9 (10 pts), match/switch 8, boolean chains 3, loops 2 (3 pts) (nesting depth added 2). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_config_apply::mssql_config_apply::registrations::plan (cognitive 22) crates/ibcmd-config-apply/src/mssql_config_apply/registrations.rs:115 — ibcmd_config_apply::mssql_config_apply::registrations::plan has cognitive complexity 22 (threshold 15). Drivers by points: if/else 6 (12 pts), loops 7 (8 pts), boolean chains 1, match/switch 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.
  • ibcmd_config_apply::mssql_config_apply::objects::registration_nodes (cognitive 21) REDACTED:654 — ibcmd_config_apply::mssql_config_apply::objects::registration_nodes has cognitive complexity 21 (threshold 15). Drivers by points: if/else 7 (15 pts), loops 5 (6 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.
  • ibcmd_config_apply::mssql_config_apply::sqlgen::render_new_registrations (cognitive 21) REDACTED:981 — ibcmd_config_apply::mssql_config_apply::sqlgen::render_new_registrations has cognitive complexity 21 (threshold 15). Drivers by points: loops 5 (12 pts), if/else 4 (5 pts), boolean chains 2, match/switch 1 (2 pts) (nesting depth added 9). 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.
  • ibcmd_config_apply::mssql_config_apply::apply_with_gate (cognitive 20) crates/ibcmd-config-apply/src/mssql_config_apply/mod.rs:1765 — ibcmd_config_apply::mssql_config_apply::apply_with_gate has cognitive complexity 20 (threshold 15). Drivers by points: if/else 11 (15 pts), match/switch 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.
  • ibcmd_config_apply::mssql_config_apply::dynamic::validate_pending_metadata (cognitive 17) REDACTED:883 — ibcmd_config_apply::mssql_config_apply::dynamic::validate_pending_metadata has cognitive complexity 17 (threshold 15). Drivers by points: if/else 6 (14 pts), boolean chains 2, loops 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_config_apply::mssql_config_apply::dynamic_overlay::plan_appends (cognitive 17) REDACTED:438 — ibcmd_config_apply::mssql_config_apply::dynamic_overlay::plan_appends has cognitive complexity 17 (threshold 15). Drivers by points: loops 7 (8 pts), if/else 5 (7 pts), boolean chains 2 (nesting depth added 3). 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.
  • ibcmd_config_apply::mssql_config_apply::gate::classify_bodies (cognitive 17) REDACTED:620 — ibcmd_config_apply::mssql_config_apply::gate::classify_bodies has cognitive complexity 17 (threshold 15). Drivers by points: if/else 4 (8 pts), match/switch 2 (4 pts), boolean chains 3, loops 2 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_config_apply::mssql_config_apply::gate::read_kinds (cognitive 16) REDACTED:466 — ibcmd_config_apply::mssql_config_apply::gate::read_kinds has cognitive complexity 16 (threshold 15). Drivers by points: if/else 8 (9 pts), loops 3 (4 pts), boolean chains 2, match/switch 1 (nesting depth added 2). To reduce it, split the body: this score is breadth rather than depth — many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D2 · Cognitive Complexity · ibcmd_metadata_model · ×18
  • ibcmd_metadata_model::metadata_model::root_export::decode (cognitive 81) crates/ibcmd-metadata-model/src/metadata_model/root_export.rs:380 — ibcmd_metadata_model::metadata_model::root_export::decode has cognitive complexity 81 (threshold 15). Drivers by points: if/else 34 (46 pts), loops 12 (15 pts), boolean chains 10, match/switch 7 (10 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.
  • ibcmd_metadata_model::metadata_model::types_export::type_children (cognitive 45) crates/ibcmd-metadata-model/src/metadata_model/types_export.rs:90 — ibcmd_metadata_model::metadata_model::types_export::type_children has cognitive complexity 45 (threshold 15). Drivers by points: if/else 15 (32 pts), match/switch 4 (12 pts), loops 1 (nesting depth added 25). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_metadata_model::metadata_model::root_export::read_row (cognitive 40) crates/ibcmd-metadata-model/src/metadata_model/root_export.rs:66 — ibcmd_metadata_model::metadata_model::root_export::read_row has cognitive complexity 40 (threshold 15). Drivers by points: if/else 13 (33 pts), loops 2 (3 pts), match/switch 2 (3 pts), boolean chains 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.
  • ibcmd_metadata_model::metadata_model::export::write_element (cognitive 33) crates/ibcmd-metadata-model/src/metadata_model/export.rs:518 — ibcmd_metadata_model::metadata_model::export::write_element has cognitive complexity 33 (threshold 15). Drivers by points: if/else 11 (20 pts), loops 6 (9 pts), boolean chains 2, match/switch 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.
  • ibcmd_metadata_model::metadata_model::root::properties_tuple (cognitive 30) crates/ibcmd-metadata-model/src/metadata_model/root.rs:676 — ibcmd_metadata_model::metadata_model::root::properties_tuple has cognitive complexity 30 (threshold 15). Drivers by points: if/else 6 (17 pts), loops 4 (7 pts), match/switch 2 (5 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.
  • ibcmd_metadata_model::metadata_model::objects_export::decode (cognitive 26) crates/ibcmd-metadata-model/src/metadata_model/objects_export.rs:653 — ibcmd_metadata_model::metadata_model::objects_export::decode has cognitive complexity 26 (threshold 15). Drivers by points: if/else 6 (10 pts), loops 7 (10 pts), match/switch 2 (5 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.
  • ibcmd_metadata_model::metadata_model::registers_parts::shortcut (cognitive 26) crates/ibcmd-metadata-model/src/metadata_model/registers_parts.rs:622 — ibcmd_metadata_model::metadata_model::registers_parts::shortcut has cognitive complexity 26 (threshold 15). Drivers by points: if/else 10 (17 pts), match/switch 3 (6 pts), loops 1 (2 pts), boolean chains 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_metadata_model::metadata_model::types::data_path (cognitive 26) crates/ibcmd-metadata-model/src/metadata_model/types.rs:574 — ibcmd_metadata_model::metadata_model::types::data_path has cognitive complexity 26 (threshold 15). Drivers by points: if/else 13 (21 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.
  • ibcmd_metadata_model::metadata_model::objects_export::names (cognitive 25) crates/ibcmd-metadata-model/src/metadata_model/objects_export.rs:1519 — ibcmd_metadata_model::metadata_model::objects_export::names has cognitive complexity 25 (threshold 15). Drivers by points: loops 5 (12 pts), match/switch 2 (7 pts), if/else 3 (6 pts) (nesting depth added 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.
  • ibcmd_metadata_model::metadata_model::common_export::font_attributes (cognitive 24) crates/ibcmd-metadata-model/src/metadata_model/common_export.rs:270 — ibcmd_metadata_model::metadata_model::common_export::font_attributes has cognitive complexity 24 (threshold 15). Drivers by points: if/else 13 (16 pts), match/switch 4 (7 pts), loops 1 (nesting depth added 6). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level.
  • ibcmd_metadata_model::metadata_model::objects_export::decode_slot (cognitive 23) crates/ibcmd-metadata-model/src/metadata_model/objects_export.rs:777 — ibcmd_metadata_model::metadata_model::objects_export::decode_slot has cognitive complexity 23 (threshold 15). Drivers by points: if/else 9 (15 pts), loops 3 (6 pts), 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.
  • ibcmd_metadata_model::metadata_model::external_data_source_children::child_objects (cognitive 21) crates/ibcmd-metadata-model/src/metadata_model/external_data_source_children.rs:611 — ibcmd_metadata_model::metadata_model::external_data_source_children::child_objects has cognitive complexity 21 (threshold 15). Drivers by points: loops 4 (12 pts), if/else 4 (8 pts), match/switch 1 (nesting depth added 12). The drivers above price the dispatch low by construction — a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full — so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident.
  • ibcmd_metadata_model::metadata_model::types::corpus::measure_object (cognitive 21) crates/ibcmd-metadata-model/src/metadata_model/types.rs:740 — ibcmd_metadata_model::metadata_model::types::corpus::measure_object has cognitive complexity 21 (threshold 15). Drivers by points: if/else 8 (11 pts), loops 2 (6 pts), boolean chains 4 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_metadata_model::metadata_model::export_audit::audit_export (cognitive 20) crates/ibcmd-metadata-model/src/metadata_model/export_audit.rs:127 — ibcmd_metadata_model::metadata_model::export_audit::audit_export has cognitive complexity 20 (threshold 15). Drivers by points: if/else 5 (12 pts), match/switch 3 (6 pts), loops 2 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_metadata_model::metadata_model::objects_parts::shortcut (cognitive 20) crates/ibcmd-metadata-model/src/metadata_model/objects_parts.rs:1208 — ibcmd_metadata_model::metadata_model::objects_parts::shortcut has cognitive complexity 20 (threshold 15). Drivers by points: match/switch 4 (9 pts), if/else 7 (8 pts), loops 1 (2 pts), boolean chains 1 (nesting depth added 7). 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.
  • ibcmd_metadata_model::metadata_model::audit::brace_path_at (cognitive 19) crates/ibcmd-metadata-model/src/metadata_model/audit.rs:264 — ibcmd_metadata_model::metadata_model::audit::brace_path_at has cognitive complexity 19 (threshold 15). Drivers by points: if/else 6 (15 pts), match/switch 1 (3 pts), loops 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_metadata_model::metadata_model::objects_export::decode_child (cognitive 19) crates/ibcmd-metadata-model/src/metadata_model/objects_export.rs:1029 — ibcmd_metadata_model::metadata_model::objects_export::decode_child has cognitive complexity 19 (threshold 15). Drivers by points: if/else 7 (11 pts), match/switch 4 (8 pts) (nesting depth added 8). The drivers above price the dispatch low by construction — a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full — so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident.
  • ibcmd_metadata_model::metadata_model::attribute::corpus::measure (cognitive 17) crates/ibcmd-metadata-model/src/metadata_model/attribute.rs:384 — ibcmd_metadata_model::metadata_model::attribute::corpus::measure has cognitive complexity 17 (threshold 15). Drivers by points: if/else 10 (14 pts), match/switch 1 (2 pts), loops 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D4 · Code Duplication · Edited copy of a member (15 corresponding lines) · ×18
  • Edited copy of a member (15 corresponding lines) crates/ibcmd-metadata-blob/src/role_rights_writer.rs:1139 — crates/ibcmd-metadata-blob/src/role_rights_writer.rs:1139-1153 | crates/ibcmd-metadata-blob/src/role_rights_writer.rs:1155-1172 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (15 corresponding lines) crates/ibcmd-dump/src/mssql_dump/mod.rs:27459 — crates/ibcmd-dump/src/mssql_dump/mod.rs:27459-27473 | crates/ibcmd-dump/src/mssql_dump/mod.rs:32039-32053 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (15 corresponding lines) crates/ibcmd-dump/src/mssql_dump/mod.rs:36747 — crates/ibcmd-dump/src/mssql_dump/mod.rs:36747-36763 | crates/ibcmd-dump/src/mssql_dump/mod.rs:36765-36779 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (15 corresponding lines) crates/ibcmd-dump/src/mssql_dump/refs.rs:5193 — crates/ibcmd-dump/src/mssql_dump/refs.rs:5193-5207 | crates/ibcmd-form-body/src/compatibility.rs:85-99 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (15 corresponding lines) crates/ibcmd-restructure/src/schema.rs:486 — crates/ibcmd-restructure/src/schema.rs:486-500 | crates/ibcmd-restructure/src/schema.rs:503-518 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (15 corresponding lines) crates/ibcmd-dump/src/mssql_dump/mod.rs:27152 — crates/ibcmd-dump/src/mssql_dump/mod.rs:27152-27170 | crates/ibcmd-dump/src/mssql_dump/mod.rs:32798-32812 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (15 corresponding lines) xtask/src/main.rs:749 — xtask/src/main.rs:749-764 | xtask/src/main.rs:772-786 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (15 corresponding lines) crates/ibcmd-dump/src/mssql_dump/mod.rs:17560 — crates/ibcmd-dump/src/mssql_dump/mod.rs:17560-17577 | crates/ibcmd-dump/src/mssql_dump/mod.rs:32881-32895 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (15 corresponding lines) src/stored_objects.rs:1709 — src/stored_objects.rs:1709-1724 | src/update.rs:143-157 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (15 corresponding lines) crates/ibcmd-form-body/src/form_body.rs:3638 — crates/ibcmd-form-body/src/form_body.rs:3638-3658 | crates/ibcmd-form-body/src/form_body.rs:21403-21417 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (15 corresponding lines) src/mssql/stage_guard.rs:206 — src/mssql/stage_guard.rs:206-231 | src/mssql/stage_guard.rs:241-255 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (15 corresponding lines) crates/ibcmd-form-body/src/form_body.rs:2343 — crates/ibcmd-form-body/src/form_body.rs:2343-2357 | crates/ibcmd-form-body/src/form_body.rs:2367-2381 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (15 corresponding lines) crates/ibcmd-dump/src/mssql_dump/refs.rs:1159 — crates/ibcmd-dump/src/mssql_dump/refs.rs:1159-1173 | crates/ibcmd-dump/src/mssql_dump/refs.rs:1369-1387 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (15 corresponding lines) crates/ibcmd-form-body/src/form_root_42.rs:55 — crates/ibcmd-form-body/src/form_root_42.rs:55-69 | crates/ibcmd-form-body/src/layout_8_5_1.rs:70-84 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (15 corresponding lines) crates/ibcmd-compiler-families/src/compiler/families/services.rs:3123 — crates/ibcmd-compiler-families/src/compiler/families/services.rs:3123-3137 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:2200-2214 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (15 corresponding lines) crates/ibcmd-1c-text/src/fields.rs:81 — crates/ibcmd-1c-text/src/fields.rs:81-95 | crates/ibcmd-xml/src/dcs_schema.rs:953-969 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (15 corresponding lines) src/settings/commands.rs:203 — src/settings/commands.rs:203-217 | src/settings/commands.rs:224-238 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (15 corresponding lines) _onecdec/make_fixtures.py:17 — _onecdec/make_fixtures.py:17-33 | _onecdec/make_variant_fixtures.py:57-71 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D15 · Churn × Complexity Hotspots · Repeated repair · ×17
  • Repeated repair: crates/ibcmd-filedb/src/lib.rs crates/ibcmd-filedb/src/lib.rs:647 — crates/ibcmd-filedb/src/lib.rs changed 18 times in last 90 days and 13 of those changes were fix/bug commits, so repair is the majority of this file's churn. Its max cyclomatic complexity is 12 (its worst body is WriteSession::write_copy at line 647), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn × complexity hotspot — 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: “fix(tests): remove every temporary directory a test creates (#567)”; “fix(filedb): refuse mismatched Windows ACLs before copying”; “fix(filedb): retain guarded Windows write support (#360)”; “fix(filedb): bound retained rows and reject part overflow #520”. 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-04..2026-11-02, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-04 13:20:30 +03:00' --until='2026-11-02 13:20:30 +03:00' --full-history --no-merges -- crates/ibcmd-filedb/src/lib.rs`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Repeated repair: crates/ibcmd-filedb/src/config.rs crates/ibcmd-filedb/src/config.rs:112 — crates/ibcmd-filedb/src/config.rs changed 12 times in last 90 days and 7 of those changes were fix/bug commits, so repair is the majority of this file's churn. Its max cyclomatic complexity is 11 (its worst body is ibcmd_filedb::config::read_records_bounded at line 112), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn × complexity hotspot — 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: “fix(tests): remove every temporary directory a test creates (#567)”; “fix(filedb): validate the full measured CONFIG field profile #520”; “fix(filedb): refuse unknown record flags before image selection #520”; “fix(filedb): bound retained rows and reject part overflow #520”. 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-04..2026-11-02, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-04 13:20:30 +03:00' --until='2026-11-02 13:20:30 +03:00' --full-history --no-merges -- crates/ibcmd-filedb/src/config.rs`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Repeated repair: src/mcp.rs src/mcp.rs:924 — src/mcp.rs changed 11 times in last 90 days and 7 of those changes were fix/bug commits, so repair is the majority of this file's churn. Its max cyclomatic complexity is 15 (its worst body is Adapter::call_tool at line 924), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn × complexity hotspot — 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: “fix(tests): remove every temporary directory a test creates (#567)”; “fix(mcp): store the listing the walk visited; review fixes”; “fix(mcp): a source snapshot compares directory listings”; “fix(mcp): refuse incomplete selected export payloads”. 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-04..2026-11-02, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-04 13:20:30 +03:00' --until='2026-11-02 13:20:30 +03:00' --full-history --no-merges -- src/mcp.rs`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Repeated repair: src/infobase/export_commands.rs src/infobase/export_commands.rs:141 — src/infobase/export_commands.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's churn. Its max cyclomatic complexity is 7 (its worst body is ObjectSink::publish at line 141), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn × complexity hotspot — 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: “fix(tests): remove every temporary directory a test creates (#567)”; “fix(editor): validate complete maps before export”; “fix(export): validate selected objects before publication”; “fix(integration): preserve backend refusals and registry read checks”. 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-04..2026-11-02, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-04 13:20:30 +03:00' --until='2026-11-02 13:20:30 +03:00' --full-history --no-merges -- src/infobase/export_commands.rs`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Repeated repair: src/mssql_source_change/files.rs src/mssql_source_change/files.rs:350 — src/mssql_source_change/files.rs changed 7 times in last 90 days and 7 of those changes were fix/bug commits, so repair is the majority of this file's churn. Its max cyclomatic complexity is 10 (its worst body is OriginalFile::read_into at line 350), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn × complexity hotspot — 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: “fix(source): retain bounded XML custody in bundled backend (#385)”; “fix(source): retain bounded XML cache custody for editor export (#381)”; “fix(source): bound cached XML descriptor custody”; “fix(source): bound consumed XML descriptor custody”. 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-04..2026-11-02, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-04 13:20:30 +03:00' --until='2026-11-02 13:20:30 +03:00' --full-history --no-merges -- src/mssql_source_change/files.rs`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Repeated repair: crates/ibcmd-filedb/src/object.rs crates/ibcmd-filedb/src/object.rs:40 — crates/ibcmd-filedb/src/object.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's churn. Its max cyclomatic complexity is 13 (its worst body is Object::open at line 40), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn × complexity hotspot — 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: “fix(tests): remove every temporary directory a test creates (#567)”; “fix(filedb): preserve snapshot generations and source cancellation”; “fix(filedb): bound guarded staging and preserve recovery generations”; “fix(filedb): bound guarded staging and preserve recovery generations”. 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-04..2026-11-02, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-04 13:20:30 +03:00' --until='2026-11-02 13:20:30 +03:00' --full-history --no-merges -- crates/ibcmd-filedb/src/object.rs`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Repeated repair: src/postgres_infobase.rs src/postgres_infobase.rs:118 — src/postgres_infobase.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's churn. Its max cyclomatic complexity is 3 (its worst body is ibcmd_rs::postgres_infobase::write_stage at line 118), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn × complexity hotspot — 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: “fix(tests): initialize native import selection in PostgreSQL wire fixture”; “fix(postgres): lock CF load generation before planning (#353)”; “test(postgres): initialize scoped snapshot in import regression”; “fix(postgres): lock import generation before planning (#370)”. 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-04..2026-11-02, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-04 13:20:30 +03:00' --until='2026-11-02 13:20:30 +03:00' --full-history --no-merges -- src/postgres_infobase.rs`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Repeated repair: editors/vscode/src/rpc.ts editors/vscode/src/rpc.ts:114 — editors/vscode/src/rpc.ts changed 5 times in last 90 days and 4 of those changes were fix/bug commits, so repair is the majority of this file's churn. Its max cyclomatic complexity is 11 (its worst body is RpcClient.receive at line 114), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn × complexity hotspot — 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: “fix(vscode): preserve sources and report current connection crashes”; “fix(vscode): preserve connection sources and lifecycle errors”; “fix(vscode): preserve connection sources and coherent object views”; “fix(editor): redact import errors and preserve recovery outcomes”. 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-04..2026-11-02, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-04 13:20:30 +03:00' --until='2026-11-02 13:20:30 +03:00' --full-history --no-merges -- editors/vscode/src/rpc.ts`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Repeated repair: crates/ibcmd-filedb/src/pager.rs crates/ibcmd-filedb/src/pager.rs:61 — crates/ibcmd-filedb/src/pager.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's churn. Its max cyclomatic complexity is 7 (its worst body is Pager::new at line 61), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn × complexity hotspot — 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: “fix(filedb): bound guarded staging and preserve recovery generations”; “fix(filedb): bound guarded staging and preserve recovery generations”; “fix(mcp): bound and cancel file database materialization”; “fix(filedb): review -- collation per locale, held lock, owner and mode, page isolation”. 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-04..2026-11-02, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-04 13:20:30 +03:00' --until='2026-11-02 13:20:30 +03:00' --full-history --no-merges -- crates/ibcmd-filedb/src/pager.rs`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Repeated repair: crates/ibcmd-filedb/src/blob.rs crates/ibcmd-filedb/src/blob.rs:28 — crates/ibcmd-filedb/src/blob.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's churn. Its max cyclomatic complexity is 9 (its worst body is ibcmd_filedb::blob::read_chain_accounted at line 28), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn × complexity hotspot — 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: “fix(filedb): bound guarded staging and preserve recovery generations”; “fix(mcp): bound and cancel file database materialization”; “fix(filedb): review -- collation per locale, held lock, owner and mode, page isolation”. 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-04..2026-11-02, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-04 13:20:30 +03:00' --until='2026-11-02 13:20:30 +03:00' --full-history --no-merges -- crates/ibcmd-filedb/src/blob.rs`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Repeated repair: crates/ibcmd-filedb/src/descr.rs crates/ibcmd-filedb/src/descr.rs:74 — crates/ibcmd-filedb/src/descr.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's churn. Its max cyclomatic complexity is 15 (its worst body is ibcmd_filedb::descr::parse_value at line 74), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn × complexity hotspot — 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: “fix(filedb): bound guarded staging and preserve recovery generations”; “fix(mcp): bound and cancel file database materialization”; “fix(filedb): review -- collation per locale, held lock, owner and mode, page isolation”. 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-04..2026-11-02, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-04 13:20:30 +03:00' --until='2026-11-02 13:20:30 +03:00' --full-history --no-merges -- crates/ibcmd-filedb/src/descr.rs`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Repeated repair: crates/ibcmd-edt/src/directory.rs crates/ibcmd-edt/src/directory.rs:178 — crates/ibcmd-edt/src/directory.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's churn. Its max cyclomatic complexity is 15 (its worst body is ibcmd_edt::directory::accounting at line 178), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn × complexity hotspot — 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: “fix(tests): remove every temporary directory a test creates (#567)”; “fix(edt): frame witnessed empty form-module scaffolds natively”; “fix(edt): preserve current form paths and native projections”. 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-04..2026-11-02, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-04 13:20:30 +03:00' --until='2026-11-02 13:20:30 +03:00' --full-history --no-merges -- crates/ibcmd-edt/src/directory.rs`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Repeated repair: editors/vscode/src/status.ts editors/vscode/src/status.ts:15 — editors/vscode/src/status.ts changed 4 times in last 90 days and 3 of those changes were fix/bug commits, so repair is the majority of this file's churn. Its max cyclomatic complexity is 4 (its worst body is status.pendingText at line 15), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn × complexity hotspot — 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: “fix(vscode): preserve sources and report current connection crashes”; “fix(vscode): preserve connection sources and lifecycle errors”; “fix(vscode): preserve connection sources and coherent object views”. 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-04..2026-11-02, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-04 13:20:30 +03:00' --until='2026-11-02 13:20:30 +03:00' --full-history --no-merges -- editors/vscode/src/status.ts`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Repeated repair: src/conversion/edt.rs src/conversion/edt.rs:5 — src/conversion/edt.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's churn. Its max cyclomatic complexity is 8 (its worst body is ibcmd_rs::conversion::edt::convert at line 5), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn × complexity hotspot — 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: “fix(edt): remove source dialect evidence size ceilings”; “fix(cli): retain offending EDT source descriptor path”; “fix(edt): validate metadata profiles without rejecting interface bodies”. 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-04..2026-11-02, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-04 13:20:30 +03:00' --until='2026-11-02 13:20:30 +03:00' --full-history --no-merges -- src/conversion/edt.rs`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Repeated repair: crates/ibcmd-filedb/src/extensions.rs crates/ibcmd-filedb/src/extensions.rs:171 — crates/ibcmd-filedb/src/extensions.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's churn. Its max cyclomatic complexity is 11 (its worst body is ibcmd_filedb::extensions::decode_records_checked at line 171), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn × complexity hotspot — 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: “fix(tests): remove every temporary directory a test creates (#567)”; “fix(integration): preserve backend refusals and registry read checks”; “fix(filedb): reject unmeasured extension export states #520”. 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-04..2026-11-02, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-04 13:20:30 +03:00' --until='2026-11-02 13:20:30 +03:00' --full-history --no-merges -- crates/ibcmd-filedb/src/extensions.rs`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Repeated repair: editors/vscode/src/import.ts editors/vscode/src/import.ts:97 — editors/vscode/src/import.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's churn. Its max cyclomatic complexity is 7 (its worst body is import.runImport at line 97), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn × complexity hotspot — 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: “fix(vscode): preserve complete import owner mapping (#382)”; “fix(vscode): negotiate import protocol and cover root collections”; “fix(editor): redact import errors and preserve recovery outcomes”. 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-04..2026-11-02, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-04 13:20:30 +03:00' --until='2026-11-02 13:20:30 +03:00' --full-history --no-merges -- editors/vscode/src/import.ts`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Repeated repair: scripts/package_release.py scripts/package_release.py:57 — scripts/package_release.py changed 3 times in last 90 days and 3 of those changes were fix/bug commits, so repair is the majority of this file's churn. Its max cyclomatic complexity is 8 (its worst body is package_release.main at line 57), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn × complexity hotspot — 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: “fix(dist): license own code under MIT and audit release notices”; “fix(edt): preserve control paths and nullable chart colors”; “fix(edt): preserve complete current chart and picture semantics”. 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-04..2026-11-02, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-04 13:20:30 +03:00' --until='2026-11-02 13:20:30 +03:00' --full-history --no-merges -- scripts/package_release.py`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
D1 · Cyclomatic Complexity · ibcmd_compiler_families · ×16
  • ibcmd_compiler_families::compiler::families::simple::project_constant (cyclomatic 31) crates/ibcmd-compiler-families/src/compiler/families/simple.rs:1202 — ibcmd_compiler_families::compiler::families::simple::project_constant has cyclomatic complexity 31 (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 — the same kind of value, with no behaviour of its own — 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.
  • ibcmd_compiler_families::compiler::families::business_object::type_pattern (cyclomatic 29) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:3302 — ibcmd_compiler_families::compiler::families::business_object::type_pattern has cyclomatic complexity 29 (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 — the same kind of value, with no behaviour of its own — 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.
  • ibcmd_compiler_families::compiler::families::utility::type_pattern (cyclomatic 29) crates/ibcmd-compiler-families/src/compiler/families/utility.rs:1646 — ibcmd_compiler_families::compiler::families::utility::type_pattern has cyclomatic complexity 29 (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 — the same kind of value, with no behaviour of its own — 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.
  • ibcmd_compiler_families::compiler::families::native::descriptor_own_uuid (cyclomatic 27) crates/ibcmd-compiler-families/src/compiler/families/native.rs:364 — ibcmd_compiler_families::compiler::families::native::descriptor_own_uuid 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.
  • ibcmd_compiler_families::compiler::families::simple::project_type_pattern_metadata (cyclomatic 25) crates/ibcmd-compiler-families/src/compiler/families/simple.rs:1498 — ibcmd_compiler_families::compiler::families::simple::project_type_pattern_metadata 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.
  • ibcmd_compiler_families::compiler::families::business_object::decode_native_ir (cyclomatic 22) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:3798 — ibcmd_compiler_families::compiler::families::business_object::decode_native_ir has cyclomatic complexity 22 (threshold 15). To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (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 — the same kind of value, with no behaviour of its own — 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.
  • ibcmd_compiler_families::compiler::families::services::project_http_service (cyclomatic 19) crates/ibcmd-compiler-families/src/compiler/families/services.rs:1896 — ibcmd_compiler_families::compiler::families::services::project_http_service 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.
  • ibcmd_compiler_families::compiler::families::simple::parse_native_type_pattern (cyclomatic 19) crates/ibcmd-compiler-families/src/compiler/families/simple.rs:2878 — ibcmd_compiler_families::compiler::families::simple::parse_native_type_pattern 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.
  • ibcmd_compiler_families::compiler::families::simple::write_type_pattern_xml (cyclomatic 19) crates/ibcmd-compiler-families/src/compiler/families/simple.rs:3406 — ibcmd_compiler_families::compiler::families::simple::write_type_pattern_xml 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. This shape REPEATS in the file: one other method here (SessionParameterNativeIr::to_xml) has the same decision points, in the same order, at the same nesting depths — 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.
  • ibcmd_compiler_families::compiler::families::services::project_web_service (cyclomatic 18) crates/ibcmd-compiler-families/src/compiler/families/services.rs:2027 — ibcmd_compiler_families::compiler::families::services::project_web_service 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.
  • ibcmd_compiler_families::compiler::families::business_object::collect_children (cyclomatic 17) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:1889 — ibcmd_compiler_families::compiler::families::business_object::collect_children 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.
  • ibcmd_compiler_families::compiler::families::business_object::register_native::decode_register_family (cyclomatic 17) crates/ibcmd-compiler-families/src/compiler/families/business_object/register_native.rs:1319 — ibcmd_compiler_families::compiler::families::business_object::register_native::decode_register_family 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.
  • ibcmd_compiler_families::compiler::families::native::write_value (cyclomatic 17) crates/ibcmd-compiler-families/src/compiler/families/native.rs:558 — ibcmd_compiler_families::compiler::families::native::write_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.
  • ibcmd_compiler_families::compiler::families::services::validate_integration_service_ir (cyclomatic 17) crates/ibcmd-compiler-families/src/compiler/families/services.rs:2698 — ibcmd_compiler_families::compiler::families::services::validate_integration_service_ir has cyclomatic complexity 17 (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.
  • ibcmd_compiler_families::compiler::families::assets::decode_base64 (cyclomatic 16) crates/ibcmd-compiler-families/src/compiler/families/assets.rs:1321 — ibcmd_compiler_families::compiler::families::assets::decode_base64 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.
  • ibcmd_compiler_families::compiler::families::simple::project_functional_option (cyclomatic 16) crates/ibcmd-compiler-families/src/compiler/families/simple.rs:1693 — ibcmd_compiler_families::compiler::families::simple::project_functional_option has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D4 · Code Duplication · Duplicated block (10 lines × 3) · ×15
  • Duplicated block (10 lines × 3) crates/ibcmd-1c-vocab/src/type_xml.rs:52 — crates/ibcmd-1c-vocab/src/type_xml.rs:52-61 | crates/ibcmd-1c-vocab/src/type_xml.rs:130-139 | crates/ibcmd-dump/src/mssql_dump/mod.rs:44630-44639 — before extracting anything, compare `crates/ibcmd-1c-vocab/src/type_xml.rs` and `crates/ibcmd-dump/src/mssql_dump/mod.rs` as WHOLE FILES: this scan already matched 6 separate duplicated blocks between them, totalling at least 118 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. 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 `crates/ibcmd-1c-vocab/src/type_xml.rs:52` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (10 lines × 3) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:678 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:678-687 | crates/ibcmd-compiler-families/src/compiler/families/commands.rs:321-330 | crates/ibcmd-compiler-families/src/compiler/families/utility.rs:380-389 — before extracting anything, compare `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs` and `crates/ibcmd-compiler-families/src/compiler/families/commands.rs` as WHOLE FILES: this scan already matched 3 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. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:678` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (10 lines × 3) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:1295 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:1295-1304 | crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:1433-1442 | crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:1724-1733 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:1295` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:1305` calls `enum_property`, `invalid_model` and `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:1444` does not — after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
  • Duplicated block (10 lines × 3) crates/ibcmd-compiler-families/src/compiler/families/services.rs:3145 — crates/ibcmd-compiler-families/src/compiler/families/services.rs:3145-3154 | crates/ibcmd-compiler-families/src/compiler/families/services.rs:3163-3172 | crates/ibcmd-compiler-families/src/compiler/families/services.rs:3181-3190 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/services.rs:3145` it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows — the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members' bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run — a one-line delegation has no helper inside it to lift — so generate the run from the set it enumerates, or accept it and keep each member's own documentation with it. Note first that the copies are not typed on the same thing: the declarations holding them bind `value` to `&WsReferenceNativeIr` in one and `&IntegrationServiceNativeIr` in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH — their common supertype where they have one, or a new abstraction over them where they do not — and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract.
  • Duplicated block (10 lines × 3) crates/ibcmd-dump/src/mssql_dump/mod.rs:28067 — crates/ibcmd-dump/src/mssql_dump/mod.rs:28067-28076 | crates/ibcmd-dump/src/mssql_dump/mod.rs:29558-29567 | crates/ibcmd-dump/src/mssql_dump/mod.rs:30750-30759 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:28067` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (10 lines × 3) crates/ibcmd-dump/src/mssql_dump/source_assets.rs:89 — crates/ibcmd-dump/src/mssql_dump/source_assets.rs:89-98 | crates/ibcmd-dump/src/mssql_dump/source_assets.rs:118-127 | crates/ibcmd-dump/src/mssql_dump/source_assets.rs:1211-1220 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited.
  • Duplicated block (10 lines × 3) crates/ibcmd-dump/src/mssql_dump/upgrade.rs:71 — crates/ibcmd-dump/src/mssql_dump/upgrade.rs:71-80 | crates/ibcmd-dump/src/mssql_dump/upgrade.rs:119-128 | crates/ibcmd-dump/src/mssql_dump/upgrade.rs:434-443 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/upgrade.rs:71` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (10 lines × 3) crates/ibcmd-form-writer/src/lib.rs:15630 — crates/ibcmd-form-writer/src/lib.rs:15630-15639 | crates/ibcmd-form-writer/src/lib.rs:15889-15898 | crates/ibcmd-form-writer/src/lib.rs:15942-15951 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-form-writer/src/lib.rs:15630` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (10 lines × 3) crates/ibcmd-v8/src/format15.rs:287 — crates/ibcmd-v8/src/format15.rs:287-296 | crates/ibcmd-v8/src/format16.rs:370-379 | crates/ibcmd-v8/src/reader.rs:934-943 — before extracting anything, compare `crates/ibcmd-v8/src/format15.rs` and `crates/ibcmd-v8/src/format16.rs` as WHOLE FILES: this scan already matched 7 separate duplicated blocks between them, totalling at least 82 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-v8/src/format15.rs:287` it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows — the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members' bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run — a one-line delegation has no helper inside it to lift — so generate the run from the set it enumerates, or accept it and keep each member's own documentation with it.
  • Duplicated block (10 lines × 3) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:763 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:763-772 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:1891-1900 | crates/ibcmd-compiler-families/src/compiler/families/utility.rs:448-457 — before extracting anything, compare `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs` and `crates/ibcmd-compiler-families/src/compiler/families/simple.rs` as WHOLE FILES: this scan already matched 12 separate duplicated blocks between them, totalling at least 149 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:763` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (10 lines × 3) crates/ibcmd-config-apply/src/mssql_config_apply/recovery.rs:381 — crates/ibcmd-config-apply/src/mssql_config_apply/recovery.rs:381-390 | crates/ibcmd-config-apply/src/mssql_config_apply/recovery.rs:419-428 | crates/ibcmd-config-apply/src/mssql_config_apply/recovery.rs:512-521 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-config-apply/src/mssql_config_apply/recovery.rs:381` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (10 lines × 3) crates/ibcmd-metadata-model/src/metadata_model/export_names.rs:281 — crates/ibcmd-metadata-model/src/metadata_model/export_names.rs:281-290 | crates/ibcmd-metadata-model/src/metadata_model/export_names.rs:312-321 | crates/ibcmd-metadata-model/src/metadata_model/export_names.rs:410-419 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-metadata-model/src/metadata_model/export_names.rs:281` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (10 lines × 3) crates/ibcmd-compiler-families/src/compiler/families/services.rs:4400 — crates/ibcmd-compiler-families/src/compiler/families/services.rs:4400-4409 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:3550-3559 | crates/ibcmd-xml/src/writer.rs:808-817 — before extracting anything, compare `crates/ibcmd-compiler-families/src/compiler/families/services.rs` and `crates/ibcmd-compiler-families/src/compiler/families/simple.rs` as WHOLE FILES: this scan already matched 36 separate duplicated blocks between them, totalling at least 406 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place.
  • Duplicated block (10 lines × 3) crates/ibcmd-compiler-families/src/compiler/families/services.rs:3063 — crates/ibcmd-compiler-families/src/compiler/families/services.rs:3063-3072 | crates/ibcmd-compiler-families/src/compiler/families/services.rs:3124-3133 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:2201-2210 — before extracting anything, compare `crates/ibcmd-compiler-families/src/compiler/families/services.rs` and `crates/ibcmd-compiler-families/src/compiler/families/simple.rs` as WHOLE FILES: this scan already matched 36 separate duplicated blocks between them, totalling at least 406 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Note first that the copies are not typed on the same thing: the declarations holding them bind `value` to `&ScheduledJobNativeIr` in one and `&XdtoPackageNativeIr` in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH — their common supertype where they have one, or a new abstraction over them where they do not — and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract.
  • Duplicated block (10 lines × 3) crates/ibcmd-compiler-families/src/compiler/families/services.rs:406 — crates/ibcmd-compiler-families/src/compiler/families/services.rs:406-415 | crates/ibcmd-compiler-families/src/compiler/families/services.rs:812-821 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:820-829 — before extracting anything, compare `crates/ibcmd-compiler-families/src/compiler/families/services.rs` and `crates/ibcmd-compiler-families/src/compiler/families/simple.rs` as WHOLE FILES: this scan already matched 36 separate duplicated blocks between them, totalling at least 406 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, `crates/ibcmd-compiler-families/src/compiler/families/services.rs:811` calls `validate_http_ir` and `crates/ibcmd-compiler-families/src/compiler/families/simple.rs:819` does not — after which the two agree again for 4 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
D5 · Coupling · Off the main sequence · ×15
  • Off the main sequence: ibcmd-1c-text — ibcmd-1c-text: abstractness 0.00, instability 0.00, distance 1.00 — zone of pain — concrete and depended on by 17 project(s), so it's rigid to change.
  • Off the main sequence: ibcmd-cancel — ibcmd-cancel: abstractness 0.00, instability 0.00, distance 1.00 — zone of pain — concrete and depended on by 3 project(s), so it's rigid to change.
  • Off the main sequence: ibcmd-dynamic-generation — ibcmd-dynamic-generation: abstractness 0.00, instability 0.00, distance 1.00 — zone of pain — concrete and depended on by 3 project(s), so it's rigid to change.
  • Off the main sequence: ibcmd-form-schema — ibcmd-form-schema: abstractness 0.00, instability 0.00, distance 1.00 — zone of pain — concrete and depended on by 5 project(s), so it's rigid to change.
  • Off the main sequence: ibcmd-postgres — ibcmd-postgres: abstractness 0.00, instability 0.00, distance 1.00 — zone of pain — concrete and depended on by 2 project(s), so it's rigid to change.
  • Off the main sequence: ibcmd-schema — ibcmd-schema: abstractness 0.00, instability 0.00, distance 1.00 — zone of pain — concrete and depended on by 12 project(s), so it's rigid to change.
  • Off the main sequence: ibcmd-core — ibcmd-core: abstractness 0.02, instability 0.00, distance 0.98 — zone of pain — concrete and depended on by 16 project(s), so it's rigid to change.
  • Off the main sequence: ibcmd-filedb — ibcmd-filedb: abstractness 0.05, instability 0.00, distance 0.95 — zone of pain — concrete and depended on by 2 project(s), so it's rigid to change.
  • Off the main sequence: ibcmd-module-blob — ibcmd-module-blob: abstractness 0.00, instability 0.17, distance 0.83 — zone of pain — concrete and depended on by 10 project(s), so it's rigid to change.
  • Off the main sequence: ibcmd-restructure — ibcmd-restructure: abstractness 0.00, instability 0.17, distance 0.83 — zone of pain — concrete and depended on by 5 project(s), so it's rigid to change.
  • Off the main sequence: ibcmd-form-native — ibcmd-form-native: abstractness 0.03, instability 0.14, distance 0.83 — zone of pain — concrete and depended on by 6 project(s), so it's rigid to change.
  • Off the main sequence: ibcmd-xml — ibcmd-xml: abstractness 0.02, instability 0.15, distance 0.82 — zone of pain — concrete and depended on by 11 project(s), so it's rigid to change.
  • Off the main sequence: ibcmd-sql — ibcmd-sql: abstractness 0.06, instability 0.13, distance 0.81 — zone of pain — concrete and depended on by 7 project(s), so it's rigid to change.
  • Off the main sequence: ibcmd-v8 — ibcmd-v8: abstractness 0.00, instability 0.20, distance 0.80 — zone of pain — concrete and depended on by 4 project(s), so it's rigid to change.
  • Off the main sequence: ibcmd-moxel — ibcmd-moxel: abstractness 0.02, instability 0.20, distance 0.78 — zone of pain — concrete and depended on by 4 project(s), so it's rigid to change.
S1 · Web-Security Posture · Weak hash algorithm · ×15
  • Weak hash algorithm crates/ibcmd-dump/src/mssql_dump/cas.rs:95 — MD5/SHA1 is computed here, and both are collision-broken. If this digest protects anything — a signature, an integrity or tamper check, a credential, or any value an attacker can influence — that is a real weakness: use SHA-256+ (`sha2::Sha256::digest(…)`) 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 — a non-cryptographic hash such as xxhash or murmurhash says it in code — 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.
  • Weak hash algorithm crates/ibcmd-dump/src/mssql_dump/extension/mod.rs:671 — MD5/SHA1 is computed here, and both are collision-broken. If this digest protects anything — a signature, an integrity or tamper check, a credential, or any value an attacker can influence — that is a real weakness: use SHA-256+ (`sha2::Sha256::digest(…)`) 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 — a non-cryptographic hash such as xxhash or murmurhash says it in code — 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.
  • Weak hash algorithm crates/ibcmd-dump/src/mssql_dump/extension/mod.rs:761 — MD5/SHA1 is computed here, and both are collision-broken. If this digest protects anything — a signature, an integrity or tamper check, a credential, or any value an attacker can influence — that is a real weakness: use SHA-256+ (`sha2::Sha256::digest(…)`) 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 — a non-cryptographic hash such as xxhash or murmurhash says it in code — 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.
  • Weak hash algorithm crates/ibcmd-dump/src/mssql_dump/refs.rs:4853 — MD5/SHA1 is computed here, and both are collision-broken. If this digest protects anything — a signature, an integrity or tamper check, a credential, or any value an attacker can influence — that is a real weakness: use SHA-256+ (`sha2::Sha256::digest(…)`) 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 — a non-cryptographic hash such as xxhash or murmurhash says it in code — 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.
  • Weak hash algorithm REDACTED:262 — MD5/SHA1 is computed here, and both are collision-broken. If this digest protects anything — a signature, an integrity or tamper check, a credential, or any value an attacker can influence — that is a real weakness: use SHA-256+ (`sha2::Sha256::digest(…)`) 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 — a non-cryptographic hash such as xxhash or murmurhash says it in code — 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.
  • Weak hash algorithm REDACTED:631 — MD5/SHA1 is computed here, and both are collision-broken. If this digest protects anything — a signature, an integrity or tamper check, a credential, or any value an attacker can influence — that is a real weakness: use SHA-256+ (`sha2::Sha256::digest(…)`) 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 — a non-cryptographic hash such as xxhash or murmurhash says it in code — 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.
  • Weak hash algorithm crates/ibcmd-postgres/src/lib.rs:150 — MD5/SHA1 is computed here, and both are collision-broken. If this digest protects anything — a signature, an integrity or tamper check, a credential, or any value an attacker can influence — that is a real weakness: use SHA-256+ (`sha2::Sha256::digest(…)`) 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 — a non-cryptographic hash such as xxhash or murmurhash says it in code — 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.
  • Weak hash algorithm crates/ibcmd-postgres/src/lib.rs:154 — MD5/SHA1 is computed here, and both are collision-broken. If this digest protects anything — a signature, an integrity or tamper check, a credential, or any value an attacker can influence — that is a real weakness: use SHA-256+ (`sha2::Sha256::digest(…)`) 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 — a non-cryptographic hash such as xxhash or murmurhash says it in code — 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.
  • Weak hash algorithm src/external/mod.rs:28 — MD5/SHA1 is computed here, and both are collision-broken. If this digest protects anything — a signature, an integrity or tamper check, a credential, or any value an attacker can influence — that is a real weakness: use SHA-256+ (`sha2::Sha256::digest(…)`) 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 — a non-cryptographic hash such as xxhash or murmurhash says it in code — 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.
  • Weak hash algorithm src/load.rs:879 — MD5/SHA1 is computed here, and both are collision-broken. If this digest protects anything — a signature, an integrity or tamper check, a credential, or any value an attacker can influence — that is a real weakness: use SHA-256+ (`sha2::Sha256::digest(…)`) 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 — a non-cryptographic hash such as xxhash or murmurhash says it in code — 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.
  • Weak hash algorithm src/load/compiled.rs:418 — MD5/SHA1 is computed here, and both are collision-broken. If this digest protects anything — a signature, an integrity or tamper check, a credential, or any value an attacker can influence — that is a real weakness: use SHA-256+ (`sha2::Sha256::digest(…)`) 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 — a non-cryptographic hash such as xxhash or murmurhash says it in code — 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.
  • Weak hash algorithm REDACTED:415 — MD5/SHA1 is computed here, and both are collision-broken. If this digest protects anything — a signature, an integrity or tamper check, a credential, or any value an attacker can influence — that is a real weakness: use SHA-256+ (`sha2::Sha256::digest(…)`) 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 — a non-cryptographic hash such as xxhash or murmurhash says it in code — 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.
  • Weak hash algorithm REDACTED:433 — MD5/SHA1 is computed here, and both are collision-broken. If this digest protects anything — a signature, an integrity or tamper check, a credential, or any value an attacker can influence — that is a real weakness: use SHA-256+ (`sha2::Sha256::digest(…)`) 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 — a non-cryptographic hash such as xxhash or murmurhash says it in code — 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.
  • Weak hash algorithm REDACTED:464 — MD5/SHA1 is computed here, and both are collision-broken. If this digest protects anything — a signature, an integrity or tamper check, a credential, or any value an attacker can influence — that is a real weakness: use SHA-256+ (`sha2::Sha256::digest(…)`) 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 — a non-cryptographic hash such as xxhash or murmurhash says it in code — 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.
  • Weak hash algorithm src/mssql_extension_load.rs:337 — MD5/SHA1 is computed here, and both are collision-broken. If this digest protects anything — a signature, an integrity or tamper check, a credential, or any value an attacker can influence — that is a real weakness: use SHA-256+ (`sha2::Sha256::digest(…)`) 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 — a non-cryptographic hash such as xxhash or murmurhash says it in code — 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.
D4 · Code Duplication · Edited copy of a member (19 corresponding lines) · ×14
  • Edited copy of a member (19 corresponding lines) crates/ibcmd-moxel/src/lib.rs:7542 — crates/ibcmd-moxel/src/lib.rs:7542-7560 | crates/ibcmd-moxel/src/lib.rs:7562-7585 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (19 corresponding lines) crates/ibcmd-compiler-families/src/compiler/families/form.rs:262 — crates/ibcmd-compiler-families/src/compiler/families/form.rs:262-280 | crates/ibcmd-compiler-families/src/compiler/families/modules.rs:190-210 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (19 corresponding lines) crates/ibcmd-form-body/src/layout_8_5_1.rs:358 — crates/ibcmd-form-body/src/layout_8_5_1.rs:358-376 | crates/ibcmd-form-writer/src/form/load_8_5_1.rs:1246-1264 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (19 corresponding lines) crates/ibcmd-moxel/src/lib.rs:7697 — crates/ibcmd-moxel/src/lib.rs:7697-7715 | crates/ibcmd-moxel/src/lib.rs:7725-7745 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (19 corresponding lines) src/settings/restructure.rs:42 — src/settings/restructure.rs:42-60 | src/settings/restructure.rs:64-82 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (19 corresponding lines) crates/ibcmd-dump/src/mssql_dump/mod.rs:20829 — crates/ibcmd-dump/src/mssql_dump/mod.rs:20829-20847 | crates/ibcmd-dump/src/mssql_dump/mod.rs:22780-22798 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (19 corresponding lines) crates/ibcmd-form-body/src/form_body.rs:21448 — crates/ibcmd-form-body/src/form_body.rs:21448-21466 | crates/ibcmd-form-schema/src/lib.rs:8559-8577 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (19 corresponding lines) crates/ibcmd-compiler-families/src/compiler/families/native.rs:817 — crates/ibcmd-compiler-families/src/compiler/families/native.rs:817-837 | crates/ibcmd-compiler-families/src/compiler/families/native.rs:1126-1144 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (19 corresponding lines) REDACTED:8758 — REDACTED:8758-8776 | REDACTED:8853-8876 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (19 corresponding lines) crates/ibcmd-form-body/src/form_body.rs:23059 — crates/ibcmd-form-body/src/form_body.rs:23059-23077 | crates/ibcmd-form-body/src/form_body.rs:23090-23109 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (19 corresponding lines) crates/ibcmd-dump-readers/src/metadata_owner_graph.rs:1165 — crates/ibcmd-dump-readers/src/metadata_owner_graph.rs:1165-1183 | crates/ibcmd-dump-readers/src/metadata_owner_graph.rs:1193-1211 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (19 corresponding lines) crates/ibcmd-config-apply/src/mssql_config_apply/params_marker.rs:131 — crates/ibcmd-config-apply/src/mssql_config_apply/params_marker.rs:131-155 | crates/ibcmd-config-apply/src/mssql_config_apply/params_marker.rs:300-318 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (19 corresponding lines) crates/ibcmd-compiler-families/src/compiler/families/native.rs:503 — crates/ibcmd-compiler-families/src/compiler/families/native.rs:503-522 | crates/ibcmd-compiler-families/src/compiler/families/native.rs:924-942 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (19 corresponding lines) REDACTED:75 — REDACTED:75-93 | REDACTED:423-441 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Duplicated block (11 lines × 3) · ×14
  • Duplicated block (11 lines × 3) crates/ibcmd-1c-text/src/xml.rs:38 — crates/ibcmd-1c-text/src/xml.rs:38-48 | crates/ibcmd-1c-text/src/xml.rs:52-62 | crates/ibcmd-xml/src/metadata/children.rs:83-93 — there are 3 copies across 2 file(s) — more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 3 sites; resolving a subset leaves the remainder to drift apart. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-1c-text/src/xml.rs:52` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (11 lines × 3) crates/ibcmd-compiler-families/src/compiler/families/services.rs:4388 — crates/ibcmd-compiler-families/src/compiler/families/services.rs:4388-4398 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:3523-3533 | crates/ibcmd-xml/src/writer.rs:819-829 — before extracting anything, compare `crates/ibcmd-compiler-families/src/compiler/families/services.rs` and `crates/ibcmd-compiler-families/src/compiler/families/simple.rs` as WHOLE FILES: this scan already matched 36 separate duplicated blocks between them, totalling at least 406 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. 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 `return` inside it is the body's own exit and keeps its meaning in the moved unit.
  • Duplicated block (11 lines × 3) crates/ibcmd-dump/src/mssql_dump/mod.rs:30525 — crates/ibcmd-dump/src/mssql_dump/mod.rs:30525-30535 | crates/ibcmd-dump/src/mssql_dump/mod.rs:31193-31203 | crates/ibcmd-dump/src/mssql_dump/mod.rs:32219-32229 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:30525` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (11 lines × 3) crates/ibcmd-form-body/src/form_body.rs:2810 — crates/ibcmd-form-body/src/form_body.rs:2810-2820 | crates/ibcmd-form-body/src/form_body.rs:3514-3524 | crates/ibcmd-form-body/src/form_body.rs:3529-3539 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-form-body/src/form_body.rs:2810` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (11 lines × 3) crates/ibcmd-restructure-engine/src/restructure/caches/members.rs:154 — crates/ibcmd-restructure-engine/src/restructure/caches/members.rs:154-164 | crates/ibcmd-restructure-engine/src/restructure/caches/slots.rs:549-559 | crates/ibcmd-restructure-engine/src/restructure/catalog.rs:222-232 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 3 call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made 3 times.
  • Duplicated block (11 lines × 3) crates/ibcmd-xml/src/dcs.rs:2700 — crates/ibcmd-xml/src/dcs.rs:2700-2710 | crates/ibcmd-xml/src/dcs.rs:3244-3254 | crates/ibcmd-xml/src/dcs.rs:3802-3812 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited.
  • Duplicated block (11 lines × 3) crates/ibcmd-xml/src/dcs.rs:2720 — crates/ibcmd-xml/src/dcs.rs:2720-2730 | crates/ibcmd-xml/src/dcs.rs:3264-3274 | crates/ibcmd-xml/src/dcs.rs:3822-3832 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-xml/src/dcs.rs:2720` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (11 lines × 3) crates/ibcmd-dump/src/mssql_dump/mod.rs:44904 — crates/ibcmd-dump/src/mssql_dump/mod.rs:44904-44914 | src/dump_sources.rs:761-771 | src/infobase.rs:1444-1454 — before extracting anything, compare `src/dump_sources.rs` and `src/infobase.rs` as WHOLE FILES: this scan already matched 6 separate duplicated blocks between them, totalling at least 50 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. 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 `return` inside it is the body's own exit and keeps its meaning in the moved unit.
  • Duplicated block (11 lines × 3) crates/ibcmd-compiler-families/src/compiler/families/business_object/register_native.rs:975 — crates/ibcmd-compiler-families/src/compiler/families/business_object/register_native.rs:975-985 | crates/ibcmd-compiler-families/src/compiler/families/business_object/register_native.rs:1126-1136 | crates/ibcmd-compiler-families/src/compiler/families/business_object/register_native.rs:1274-1284 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/business_object/register_native.rs:975` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, `crates/ibcmd-compiler-families/src/compiler/families/business_object/register_native.rs:974` calls `enum_code` and `crates/ibcmd-compiler-families/src/compiler/families/business_object/register_native.rs:1125` does not — after which the two agree again for 4 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
  • Duplicated block (11 lines × 3) crates/ibcmd-xml/src/dcs_schema.rs:2063 — crates/ibcmd-xml/src/dcs_schema.rs:2063-2073 | crates/ibcmd-xml/src/dcs_schema.rs:2098-2108 | crates/ibcmd-xml/src/dcs_schema.rs:2148-2158 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-xml/src/dcs_schema.rs:2063` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (11 lines × 3) crates/ibcmd-metadata-blob/src/lib.rs:2384 — crates/ibcmd-metadata-blob/src/lib.rs:2384-2394 | crates/ibcmd-metadata-blob/src/lib.rs:3281-3293 | crates/ibcmd-metadata-blob/src/lib.rs:3355-3365 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-metadata-blob/src/lib.rs:2384` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (11 lines × 3) crates/ibcmd-xml/src/metadata/business_objects.rs:410 — crates/ibcmd-xml/src/metadata/business_objects.rs:410-420 | crates/ibcmd-xml/src/metadata/hierarchical_objects.rs:391-401 | crates/ibcmd-xml/src/metadata/utility_objects.rs:323-333 — before extracting anything, compare `crates/ibcmd-xml/src/metadata/business_objects.rs` and `crates/ibcmd-xml/src/metadata/hierarchical_objects.rs` as WHOLE FILES: this scan already matched 7 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. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-xml/src/metadata/business_objects.rs:410` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (11 lines × 3) crates/ibcmd-xml/src/dcs.rs:2429 — crates/ibcmd-xml/src/dcs.rs:2429-2439 | crates/ibcmd-xml/src/dcs.rs:2816-2826 | crates/ibcmd-xml/src/dcs.rs:3693-3703 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-xml/src/dcs.rs:2429` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (11 lines × 3) _onecdec/make_adopted_exchange_plan_fixture.py:66 — _onecdec/make_adopted_exchange_plan_fixture.py:66-76 | _onecdec/make_adopted_predefined_fixture.py:65-75 | _onecdec/make_adopted_role_fixture.py:79-89 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from all 3 call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `_onecdec/make_adopted_exchange_plan_fixture.py:66` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D1 · Cyclomatic Complexity · ibcmd_metadata_model · ×13
  • ibcmd_metadata_model::metadata_model::root_export::decode (cyclomatic 63) crates/ibcmd-metadata-model/src/metadata_model/root_export.rs:380 — ibcmd_metadata_model::metadata_model::root_export::decode has cyclomatic complexity 63 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
  • ibcmd_metadata_model::metadata_model::objects_parts::shortcut (cyclomatic 33) crates/ibcmd-metadata-model/src/metadata_model/objects_parts.rs:1208 — ibcmd_metadata_model::metadata_model::objects_parts::shortcut has cyclomatic complexity 33 (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 — the same kind of value, with no behaviour of its own — 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.
  • ibcmd_metadata_model::metadata_model::objects_export::decode_slot (cyclomatic 31) crates/ibcmd-metadata-model/src/metadata_model/objects_export.rs:777 — ibcmd_metadata_model::metadata_model::objects_export::decode_slot has cyclomatic complexity 31 (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 — the same kind of value, with no behaviour of its own — 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.
  • ibcmd_metadata_model::metadata_model::common_export::font_attributes (cyclomatic 23) crates/ibcmd-metadata-model/src/metadata_model/common_export.rs:270 — ibcmd_metadata_model::metadata_model::common_export::font_attributes 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.
  • ibcmd_metadata_model::metadata_model::registers_parts::shortcut (cyclomatic 23) crates/ibcmd-metadata-model/src/metadata_model/registers_parts.rs:622 — ibcmd_metadata_model::metadata_model::registers_parts::shortcut 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.
  • ibcmd_metadata_model::metadata_model::root_export::read_row (cyclomatic 23) crates/ibcmd-metadata-model/src/metadata_model/root_export.rs:66 — ibcmd_metadata_model::metadata_model::root_export::read_row 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.
  • ibcmd_metadata_model::metadata_model::types_export::type_children (cyclomatic 21) crates/ibcmd-metadata-model/src/metadata_model/types_export.rs:90 — ibcmd_metadata_model::metadata_model::types_export::type_children 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.
  • ibcmd_metadata_model::metadata_model::objects_export::decode (cyclomatic 19) crates/ibcmd-metadata-model/src/metadata_model/objects_export.rs:653 — ibcmd_metadata_model::metadata_model::objects_export::decode has cyclomatic complexity 19 (threshold 15). To reduce it, separate the branches: extract each independent case into its own named function so the top-level body reads as a short sequence of named decisions. This is NOT this file's highest cyclomatic complexity: ibcmd_metadata_model::metadata_model::objects_export::shortcut (cyclomatic 28) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • ibcmd_metadata_model::metadata_model::common_export::names (cyclomatic 17) crates/ibcmd-metadata-model/src/metadata_model/common_export.rs:807 — ibcmd_metadata_model::metadata_model::common_export::names 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. This is NOT this file's highest cyclomatic complexity: ibcmd_metadata_model::metadata_model::common_export::decode (cyclomatic 20) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • ibcmd_metadata_model::metadata_model::export::write_element (cyclomatic 17) crates/ibcmd-metadata-model/src/metadata_model/export.rs:518 — ibcmd_metadata_model::metadata_model::export::write_element 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.
  • ibcmd_metadata_model::metadata_model::registers_export::names (cyclomatic 17) crates/ibcmd-metadata-model/src/metadata_model/registers_export.rs:1197 — ibcmd_metadata_model::metadata_model::registers_export::names 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 — the same kind of value, with no behaviour of its own — 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.
  • ibcmd_metadata_model::metadata_model::types::data_path (cyclomatic 16) crates/ibcmd-metadata-model/src/metadata_model/types.rs:574 — ibcmd_metadata_model::metadata_model::types::data_path has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top. This is NOT this file's highest cyclomatic complexity: ibcmd_metadata_model::metadata_model::types::typed_value (cyclomatic 19) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • ibcmd_metadata_model::metadata_model::types_export::value_element (cyclomatic 16) crates/ibcmd-metadata-model/src/metadata_model/types_export.rs:264 — ibcmd_metadata_model::metadata_model::types_export::value_element 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 — the same kind of value, with no behaviour of its own — 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.
D2 · Cognitive Complexity · ibcmd_restructure_engine · ×13
  • ibcmd_restructure_engine::restructure::caches::trace_diagnostic::inspect (cognitive 103) crates/ibcmd-restructure-engine/src/restructure/caches/trace_diagnostic.rs:220 — ibcmd_restructure_engine::restructure::caches::trace_diagnostic::inspect has cognitive complexity 103 (threshold 15). Drivers by points: if/else 26 (61 pts), loops 19 (37 pts), match/switch 1 (3 pts), boolean chains 2 (nesting depth added 55). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_restructure_engine::restructure::plan::plan_object (cognitive 84) REDACTED:1359 — ibcmd_restructure_engine::restructure::plan::plan_object has cognitive complexity 84 (threshold 15). Drivers by points: if/else 35 (62 pts), loops 10 (12 pts), boolean chains 6, match/switch 2 (4 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.
  • ibcmd_restructure_engine::restructure::entry::main_entry (cognitive 78) crates/ibcmd-restructure-engine/src/restructure/entry.rs:351 — ibcmd_restructure_engine::restructure::entry::main_entry has cognitive complexity 78 (threshold 15). Drivers by points: if/else 35 (66 pts), boolean chains 8, loops 3, match/switch 1 (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.
  • ibcmd_restructure_engine::restructure::plan::plan (cognitive 50) REDACTED:1062 — ibcmd_restructure_engine::restructure::plan::plan has cognitive complexity 50 (threshold 15). Drivers by points: if/else 17 (24 pts), loops 11 (16 pts), boolean chains 10 (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.
  • ibcmd_restructure_engine::restructure::plan::plan_sections (cognitive 31) REDACTED:1788 — ibcmd_restructure_engine::restructure::plan::plan_sections has cognitive complexity 31 (threshold 15). Drivers by points: if/else 6 (18 pts), loops 3 (7 pts), match/switch 2 (6 pts) (nesting depth added 20). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_restructure_engine::restructure::plan::check_object (cognitive 29) REDACTED:2211 — ibcmd_restructure_engine::restructure::plan::check_object has cognitive complexity 29 (threshold 15). Drivers by points: if/else 12 (17 pts), boolean chains 10, loops 2 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_restructure_engine::restructure::caches::change::rewrite (cognitive 26) crates/ibcmd-restructure-engine/src/restructure/caches/change.rs:64 — ibcmd_restructure_engine::restructure::caches::change::rewrite has cognitive complexity 26 (threshold 15). Drivers by points: if/else 6 (13 pts), loops 9 (11 pts), match/switch 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.
  • ibcmd_restructure_engine::restructure::plan::find_changes (cognitive 22) REDACTED:696 — ibcmd_restructure_engine::restructure::plan::find_changes has cognitive complexity 22 (threshold 15). Drivers by points: if/else 5 (15 pts), match/switch 2 (4 pts), loops 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.
  • ibcmd_restructure_engine::restructure::caches::slots::inspect_layout (cognitive 20) crates/ibcmd-restructure-engine/src/restructure/caches/slots.rs:432 — ibcmd_restructure_engine::restructure::caches::slots::inspect_layout has cognitive complexity 20 (threshold 15). Drivers by points: if/else 9 (13 pts), loops 2 (3 pts), match/switch 1 (3 pts), boolean chains 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_restructure_engine::restructure::exec::verify_structure (cognitive 18) crates/ibcmd-restructure-engine/src/restructure/exec.rs:306 — ibcmd_restructure_engine::restructure::exec::verify_structure has cognitive complexity 18 (threshold 15). Drivers by points: if/else 8 (11 pts), boolean chains 3, loops 2, match/switch 1 (2 pts) (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_restructure_engine::restructure::exec::after_phase (cognitive 17) crates/ibcmd-restructure-engine/src/restructure/exec.rs:178 — ibcmd_restructure_engine::restructure::exec::after_phase has cognitive complexity 17 (threshold 15). Drivers by points: loops 5 (10 pts), if/else 2 (6 pts), match/switch 1 (nesting depth added 9). The drivers above price the dispatch low by construction — a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full — so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident.
  • ibcmd_restructure_engine::restructure::caches::slots::declared_slots (cognitive 16) crates/ibcmd-restructure-engine/src/restructure/caches/slots.rs:279 — ibcmd_restructure_engine::restructure::caches::slots::declared_slots has cognitive complexity 16 (threshold 15). Drivers by points: match/switch 3 (7 pts), if/else 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.
  • ibcmd_restructure_engine::restructure::plan::widened_field (cognitive 16) REDACTED:787 — ibcmd_restructure_engine::restructure::plan::widened_field has cognitive complexity 16 (threshold 15). Drivers by points: if/else 9, boolean chains 6, match/switch 1. To reduce it, split the body: this score is breadth rather than depth — many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D4 · Code Duplication · Edited copy of a member (18 corresponding lines) · ×13
  • Edited copy of a member (18 corresponding lines) crates/ibcmd-dump/src/mssql_dump/forms.rs:189 — crates/ibcmd-dump/src/mssql_dump/forms.rs:189-206 | crates/ibcmd-dump/src/mssql_dump/refs.rs:2232-2251 — These two members are one piece of code written twice and then edited apart: 18 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (18 corresponding lines) crates/ibcmd-form-writer/src/lib.rs:18453 — crates/ibcmd-form-writer/src/lib.rs:18453-18470 | crates/ibcmd-form-writer/src/lib.rs:21070-21089 — These two members are one piece of code written twice and then edited apart: 18 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (18 corresponding lines) crates/ibcmd-cf/src/bootstrap.rs:485 — crates/ibcmd-cf/src/bootstrap.rs:485-505 | crates/ibcmd-cf/src/writer.rs:721-738 — These two members are one piece of code written twice and then edited apart: 18 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (18 corresponding lines) crates/ibcmd-compiler/src/compiler/bodies/mxl_native.rs:2812 — crates/ibcmd-compiler/src/compiler/bodies/mxl_native.rs:2812-2829 | crates/ibcmd-compiler/src/compiler/bodies/mxl_native.rs:2871-2890 — These two members are one piece of code written twice and then edited apart: 18 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (18 corresponding lines) src/postgres_infobase.rs:22 — src/postgres_infobase.rs:22-46 | src/postgres_infobase.rs:52-69 — These two members are one piece of code written twice and then edited apart: 18 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (18 corresponding lines) crates/ibcmd-compiler/src/file_identity.rs:11 — crates/ibcmd-compiler/src/file_identity.rs:11-28 | src/source_oracle.rs:615-635 — These two members are one piece of code written twice and then edited apart: 18 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (18 corresponding lines) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:3699 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:3699-3716 | crates/ibcmd-compiler-families/src/compiler/families/utility.rs:2037-2055 — These two members are one piece of code written twice and then edited apart: 18 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (18 corresponding lines) crates/ibcmd-core/src/migration/compatibility.rs:319 — crates/ibcmd-core/src/migration/compatibility.rs:319-339 | crates/ibcmd-core/src/migration/compatibility.rs:345-362 — These two members are one piece of code written twice and then edited apart: 18 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (18 corresponding lines) crates/ibcmd-metadata-model/src/metadata_model/bodies_predefined.rs:305 — crates/ibcmd-metadata-model/src/metadata_model/bodies_predefined.rs:305-322 | crates/ibcmd-metadata-model/src/metadata_model/bodies_predefined.rs:380-398 — These two members are one piece of code written twice and then edited apart: 18 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (18 corresponding lines) crates/ibcmd-form-writer/src/lib.rs:22442 — crates/ibcmd-form-writer/src/lib.rs:22442-22460 | crates/ibcmd-form-writer/src/lib.rs:22465-22482 — These two members are one piece of code written twice and then edited apart: 18 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (18 corresponding lines) crates/ibcmd-dump/src/mssql_dump/mod.rs:16275 — crates/ibcmd-dump/src/mssql_dump/mod.rs:16275-16292 | crates/ibcmd-dump/src/mssql_dump/mod.rs:16299-16322 — These two members are one piece of code written twice and then edited apart: 18 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (18 corresponding lines) crates/ibcmd-v8/src/block.rs:186 — crates/ibcmd-v8/src/block.rs:186-203 | crates/ibcmd-v8/src/block.rs:445-463 — These two members are one piece of code written twice and then edited apart: 18 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (18 corresponding lines) REDACTED:1103 — REDACTED:1103-1120 | REDACTED:661-682 — These two members are one piece of code written twice and then edited apart: 18 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Duplicated block (17 lines × 2) · ×13
  • Duplicated block (17 lines × 2) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:2009 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:2009-2025 | crates/ibcmd-compiler-families/src/compiler/families/utility.rs:1228-1244 — before extracting anything, compare `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs` and `crates/ibcmd-compiler-families/src/compiler/families/utility.rs` as WHOLE FILES: this scan already matched 65 separate duplicated blocks between them, totalling at least 934 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. 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 `return` inside it is the body's own exit and keeps its meaning in the moved unit.
  • Duplicated block (17 lines × 2) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:3728 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:3728-3744 | crates/ibcmd-compiler-families/src/compiler/families/utility.rs:2067-2083 — before extracting anything, compare `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs` and `crates/ibcmd-compiler-families/src/compiler/families/utility.rs` as WHOLE FILES: this scan already matched 65 separate duplicated blocks between them, totalling at least 934 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:3728` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (17 lines × 2) crates/ibcmd-compiler-families/src/compiler/families/services.rs:3534 — crates/ibcmd-compiler-families/src/compiler/families/services.rs:3534-3550 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:2551-2567 — before extracting anything, compare `crates/ibcmd-compiler-families/src/compiler/families/services.rs` and `crates/ibcmd-compiler-families/src/compiler/families/simple.rs` as WHOLE FILES: this scan already matched 36 separate duplicated blocks between them, totalling at least 406 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/services.rs:3534` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (17 lines × 2) REDACTED:1093 — REDACTED:1093-1109 | REDACTED:1263-1279 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `REDACTED:1093` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (17 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:4675 — crates/ibcmd-dump/src/mssql_dump/mod.rs:4675-4691 | crates/ibcmd-dump/src/mssql_dump/mod.rs:6472-6488 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (17 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:40020 — crates/ibcmd-dump/src/mssql_dump/mod.rs:40020-40036 | crates/ibcmd-dump/src/mssql_dump/mod.rs:40202-40218 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:40020` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (17 lines × 2) crates/ibcmd-form-body/src/form_body.rs:40000 — crates/ibcmd-form-body/src/form_body.rs:40000-40016 | crates/ibcmd-moxel/src/lib.rs:8390-8406 — before extracting anything, compare `crates/ibcmd-form-body/src/form_body.rs` and `crates/ibcmd-moxel/src/lib.rs` as WHOLE FILES: this scan already matched 4 separate duplicated blocks between them, totalling at least 52 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 `return` inside it is the body's own exit and keeps its meaning in the moved unit.
  • Duplicated block (17 lines × 2) crates/ibcmd-metadata-blob/src/lib.rs:2358 — crates/ibcmd-metadata-blob/src/lib.rs:2358-2374 | crates/ibcmd-metadata-blob/src/lib.rs:3329-3345 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-metadata-blob/src/lib.rs:2358` it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows — the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members' bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run — a one-line delegation has no helper inside it to lift — so generate the run from the set it enumerates, or accept it and keep each member's own documentation with it.
  • Duplicated block (17 lines × 2) crates/ibcmd-moxel/src/lib.rs:4695 — crates/ibcmd-moxel/src/lib.rs:4695-4711 | crates/ibcmd-moxel/src/lib.rs:10077-10093 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-moxel/src/lib.rs:4695` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (17 lines × 2) src/infobase.rs:270 — src/infobase.rs:270-286 | src/infobase.rs:666-682 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. 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 `return` inside it is the body's own exit and keeps its meaning in the moved unit.
  • Duplicated block (17 lines × 2) src/main.rs:229 — src/main.rs:229-245 | src/main.rs:272-288 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `src/main.rs:229` it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows — the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members' bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run — a one-line delegation has no helper inside it to lift — so generate the run from the set it enumerates, or accept it and keep each member's own documentation with it.
  • Duplicated block (17 lines × 2) crates/ibcmd-metadata-blob/src/lib.rs:3858 — crates/ibcmd-metadata-blob/src/lib.rs:3858-3874 | crates/ibcmd-metadata-blob/src/lib.rs:3881-3897 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-metadata-blob/src/lib.rs:3858` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (17 lines × 2) crates/ibcmd-xml/src/metadata/business_objects.rs:353 — crates/ibcmd-xml/src/metadata/business_objects.rs:353-369 | crates/ibcmd-xml/src/metadata/utility_objects.rs:258-274 — before extracting anything, compare `crates/ibcmd-xml/src/metadata/business_objects.rs` and `crates/ibcmd-xml/src/metadata/utility_objects.rs` as WHOLE FILES: this scan already matched 11 separate duplicated blocks between them, totalling at least 111 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-xml/src/metadata/business_objects.rs:353` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D1 · Cyclomatic Complexity · ibcmd_config_apply · ×12
  • ibcmd_config_apply::mssql_config_apply::dynamic::plan_dynamic (cyclomatic 95) REDACTED:1133 — ibcmd_config_apply::mssql_config_apply::dynamic::plan_dynamic has cyclomatic complexity 95 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
  • ibcmd_config_apply::mssql_config_apply::plan_with_gate (cyclomatic 78) crates/ibcmd-config-apply/src/mssql_config_apply/mod.rs:972 — ibcmd_config_apply::mssql_config_apply::plan_with_gate has cyclomatic complexity 78 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
  • ibcmd_config_apply::mssql_config_apply::removals::analyze (cyclomatic 71) REDACTED:112 — ibcmd_config_apply::mssql_config_apply::removals::analyze has cyclomatic complexity 71 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
  • ibcmd_config_apply::mssql_config_apply::objects::analyze (cyclomatic 56) REDACTED:238 — ibcmd_config_apply::mssql_config_apply::objects::analyze has cyclomatic complexity 56 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
  • ibcmd_config_apply::mssql_config_apply::dynamic::judge_rows (cyclomatic 29) REDACTED:340 — ibcmd_config_apply::mssql_config_apply::dynamic::judge_rows 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.
  • ibcmd_config_apply::mssql_config_apply::objects::plan_search_info (cyclomatic 23) REDACTED:754 — ibcmd_config_apply::mssql_config_apply::objects::plan_search_info 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.
  • ibcmd_config_apply::mssql_config_apply::recovery::write_recovery (cyclomatic 23) crates/ibcmd-config-apply/src/mssql_config_apply/recovery.rs:303 — ibcmd_config_apply::mssql_config_apply::recovery::write_recovery has cyclomatic complexity 23 (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.
  • ibcmd_config_apply::mssql_config_apply::dynamic::object_kinds (cyclomatic 22) REDACTED:637 — ibcmd_config_apply::mssql_config_apply::dynamic::object_kinds 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.
  • ibcmd_config_apply::restructure::s1::decide (cyclomatic 22) crates/ibcmd-config-apply/src/restructure/s1.rs:159 — ibcmd_config_apply::restructure::s1::decide has cyclomatic complexity 22 (threshold 15). To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (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 — the same kind of value, with no behaviour of its own — 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.
  • ibcmd_config_apply::mssql_config_apply::sqlgen::render_apply_script (cyclomatic 20) REDACTED:377 — ibcmd_config_apply::mssql_config_apply::sqlgen::render_apply_script has cyclomatic complexity 20 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
  • ibcmd_config_apply::mssql_config_apply::apply_with_gate (cyclomatic 19) crates/ibcmd-config-apply/src/mssql_config_apply/mod.rs:1765 — ibcmd_config_apply::mssql_config_apply::apply_with_gate 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.
  • ibcmd_config_apply::mssql_config_apply::registrations::plan (cyclomatic 17) crates/ibcmd-config-apply/src/mssql_config_apply/registrations.rs:115 — ibcmd_config_apply::mssql_config_apply::registrations::plan 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.
D4 · Code Duplication · Edited copy of a member (20 corresponding lines) · ×12
  • Edited copy of a member (20 corresponding lines) crates/ibcmd-dump/src/mssql_dump/upgrade.rs:514 — crates/ibcmd-dump/src/mssql_dump/upgrade.rs:514-533 | crates/ibcmd-dump/src/mssql_dump/upgrade.rs:545-564 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (20 corresponding lines) crates/ibcmd-compiler-families/src/compiler/families/assets.rs:1406 — crates/ibcmd-compiler-families/src/compiler/families/assets.rs:1406-1425 | crates/ibcmd-compiler-families/src/compiler/families/commands.rs:1268-1290 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (20 corresponding lines) crates/ibcmd-v8/src/format15.rs:256 — crates/ibcmd-v8/src/format15.rs:256-275 | crates/ibcmd-v8/src/format16.rs:339-358 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (20 corresponding lines) crates/ibcmd-dump/src/mssql_dump/source_assets.rs:88 — crates/ibcmd-dump/src/mssql_dump/source_assets.rs:88-107 | crates/ibcmd-dump/src/mssql_dump/source_assets.rs:117-136 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (20 corresponding lines) crates/ibcmd-dump/src/mssql_dump/mod.rs:17527 — crates/ibcmd-dump/src/mssql_dump/mod.rs:17527-17546 | crates/ibcmd-dump/src/mssql_dump/mod.rs:17623-17649 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (20 corresponding lines) crates/ibcmd-moxel/src/lib.rs:14964 — crates/ibcmd-moxel/src/lib.rs:14964-14986 | crates/ibcmd-moxel/src/lib.rs:14988-15007 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (20 corresponding lines) crates/ibcmd-dump/src/mssql_dump/mod.rs:26058 — crates/ibcmd-dump/src/mssql_dump/mod.rs:26058-26077 | crates/ibcmd-dump/src/mssql_dump/mod.rs:31885-31912 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (20 corresponding lines) crates/ibcmd-xml/src/metadata/functional_options_parameter.rs:248 — crates/ibcmd-xml/src/metadata/functional_options_parameter.rs:248-275 | crates/ibcmd-xml/src/metadata/services.rs:2103-2122 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (20 corresponding lines) crates/ibcmd-moxel/src/lib.rs:12361 — crates/ibcmd-moxel/src/lib.rs:12361-12384 | crates/ibcmd-moxel/src/lib.rs:12587-12606 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (20 corresponding lines) crates/ibcmd-dump/src/mssql_dump/mod.rs:18892 — crates/ibcmd-dump/src/mssql_dump/mod.rs:18892-18911 | crates/ibcmd-dump/src/mssql_dump/mod.rs:19437-19463 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (20 corresponding lines) scripts/restructure-lab/edit_cases_s1.py:188 — scripts/restructure-lab/edit_cases_s1.py:188-207 | scripts/restructure-lab/s1k/cases.py:57-81 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (20 corresponding lines) scripts/restructure-lab/edit85.py:16 — scripts/restructure-lab/edit85.py:16-35 | scripts/restructure-lab/edit_second.py:17-41 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Duplicated block (18 lines × 2) · ×12
  • Duplicated block (18 lines × 2) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:3011 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:3011-3028 | crates/ibcmd-compiler-families/src/compiler/families/utility.rs:1578-1595 — before extracting anything, compare `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs` and `crates/ibcmd-compiler-families/src/compiler/families/utility.rs` as WHOLE FILES: this scan already matched 65 separate duplicated blocks between them, totalling at least 934 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:3011` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (18 lines × 2) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:3486 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:3486-3503 | crates/ibcmd-compiler-families/src/compiler/families/utility.rs:1823-1840 — before extracting anything, compare `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs` and `crates/ibcmd-compiler-families/src/compiler/families/utility.rs` as WHOLE FILES: this scan already matched 65 separate duplicated blocks between them, totalling at least 934 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. 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 `return` inside it is the body's own exit and keeps its meaning in the moved unit.
  • Duplicated block (18 lines × 2) crates/ibcmd-compiler-families/src/compiler/families/services.rs:3505 — crates/ibcmd-compiler-families/src/compiler/families/services.rs:3505-3522 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:2522-2539 — before extracting anything, compare `crates/ibcmd-compiler-families/src/compiler/families/services.rs` and `crates/ibcmd-compiler-families/src/compiler/families/simple.rs` as WHOLE FILES: this scan already matched 36 separate duplicated blocks between them, totalling at least 406 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. 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 `return` inside it is the body's own exit and keeps its meaning in the moved unit.
  • Duplicated block (18 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:4509 — crates/ibcmd-dump/src/mssql_dump/mod.rs:4509-4526 | crates/ibcmd-dump/src/mssql_dump/mod.rs:6266-6283 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (18 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:23251 — crates/ibcmd-dump/src/mssql_dump/mod.rs:23251-23268 | crates/ibcmd-dump/src/mssql_dump/mod.rs:23621-23638 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:23251` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (18 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:28779 — crates/ibcmd-dump/src/mssql_dump/mod.rs:28779-28796 | crates/ibcmd-dump/src/mssql_dump/mod.rs:30255-30272 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (18 lines × 2) crates/ibcmd-metadata-blob/src/lib.rs:5080 — crates/ibcmd-metadata-blob/src/lib.rs:5080-5097 | crates/ibcmd-metadata-blob/src/lib.rs:5243-5260 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-metadata-blob/src/lib.rs:5080` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (18 lines × 2) crates/ibcmd-v8/src/block.rs:336 — crates/ibcmd-v8/src/block.rs:336-353 | crates/ibcmd-v8/src/block.rs:608-625 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. 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 `return` inside it is the body's own exit and keeps its meaning in the moved unit.
  • Duplicated block (18 lines × 2) src/conversion.rs:784 — src/conversion.rs:784-801 | src/conversion.rs:1190-1207 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `src/conversion.rs:784` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (18 lines × 2) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:4324 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:4324-4341 | crates/ibcmd-compiler-families/src/compiler/families/utility.rs:2423-2440 — before extracting anything, compare `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs` and `crates/ibcmd-compiler-families/src/compiler/families/utility.rs` as WHOLE FILES: this scan already matched 65 separate duplicated blocks between them, totalling at least 934 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:4324` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (18 lines × 2) crates/ibcmd-compiler-families/src/compiler/families/services.rs:4121 — crates/ibcmd-compiler-families/src/compiler/families/services.rs:4121-4138 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:3017-3034 — before extracting anything, compare `crates/ibcmd-compiler-families/src/compiler/families/services.rs` and `crates/ibcmd-compiler-families/src/compiler/families/simple.rs` as WHOLE FILES: this scan already matched 36 separate duplicated blocks between them, totalling at least 406 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (18 lines × 2) crates/ibcmd-form-body/src/form_body.rs:41246 — crates/ibcmd-form-body/src/form_body.rs:41246-41264 | crates/ibcmd-form-body/src/form_body.rs:41332-41349 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-form-body/src/form_body.rs:41246` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Edited copy of a member (21 corresponding lines) · ×11
  • Edited copy of a member (21 corresponding lines) crates/ibcmd-metadata-model/src/metadata_model/registers_export.rs:253 — crates/ibcmd-metadata-model/src/metadata_model/registers_export.rs:253-273 | crates/ibcmd-metadata-model/src/metadata_model/registers_export.rs:285-313 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (21 corresponding lines) crates/ibcmd-form-writer/src/lib.rs:21491 — crates/ibcmd-form-writer/src/lib.rs:21491-21517 | crates/ibcmd-form-writer/src/lib.rs:22045-22065 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (21 corresponding lines) crates/ibcmd-xml/src/dcs.rs:1045 — crates/ibcmd-xml/src/dcs.rs:1045-1068 | crates/ibcmd-xml/src/dcs.rs:1173-1193 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (21 corresponding lines) crates/ibcmd-core/src/model.rs:158 — crates/ibcmd-core/src/model.rs:158-179 | crates/ibcmd-core/src/opaque.rs:125-145 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (21 corresponding lines) crates/ibcmd-xml/src/dcs.rs:1198 — crates/ibcmd-xml/src/dcs.rs:1198-1224 | crates/ibcmd-xml/src/dcs.rs:1227-1247 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (21 corresponding lines) crates/ibcmd-metadata-blob/src/lib.rs:881 — crates/ibcmd-metadata-blob/src/lib.rs:881-902 | crates/ibcmd-metadata-blob/src/lib.rs:3166-3186 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (21 corresponding lines) crates/ibcmd-form-writer/src/form/load_8_5_1.rs:1183 — crates/ibcmd-form-writer/src/form/load_8_5_1.rs:1183-1203 | crates/ibcmd-metadata-blob/src/lib.rs:1473-1493 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (21 corresponding lines) crates/ibcmd-dump/src/mssql_dump/mod.rs:44871 — crates/ibcmd-dump/src/mssql_dump/mod.rs:44871-44892 | src/infobase.rs:1421-1441 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (21 corresponding lines) crates/ibcmd-xml/src/metadata/business_objects.rs:871 — crates/ibcmd-xml/src/metadata/business_objects.rs:871-891 | crates/ibcmd-xml/src/metadata/hierarchical_objects.rs:792-813 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (21 corresponding lines) crates/ibcmd-form-writer/src/lib.rs:23183 — crates/ibcmd-form-writer/src/lib.rs:23183-23203 | src/trace.rs:343-367 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (21 corresponding lines) crates/ibcmd-core/src/dcs_schema.rs:926 — crates/ibcmd-core/src/dcs_schema.rs:926-946 | crates/ibcmd-core/src/dcs_schema.rs:1465-1485 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Duplicated block (21 lines × 2) · ×11
  • Duplicated block (21 lines × 2) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:4391 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:4391-4411 | crates/ibcmd-compiler-families/src/compiler/families/utility.rs:2586-2606 — before extracting anything, compare `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs` and `crates/ibcmd-compiler-families/src/compiler/families/utility.rs` as WHOLE FILES: this scan already matched 65 separate duplicated blocks between them, totalling at least 934 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:4391` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (21 lines × 2) crates/ibcmd-dump/src/mssql_dump/forms.rs:149 — crates/ibcmd-dump/src/mssql_dump/forms.rs:149-169 | crates/ibcmd-dump/src/mssql_dump/mod.rs:33427-33447 — before extracting anything, compare `crates/ibcmd-dump/src/mssql_dump/forms.rs` and `crates/ibcmd-dump/src/mssql_dump/mod.rs` as WHOLE FILES: this scan already matched 6 separate duplicated blocks between them, totalling at least 99 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/forms.rs:149` it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows — the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members' bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run — a one-line delegation has no helper inside it to lift — so generate the run from the set it enumerates, or accept it and keep each member's own documentation with it.
  • Duplicated block (21 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:14199 — crates/ibcmd-dump/src/mssql_dump/mod.rs:14199-14219 | crates/ibcmd-dump/src/mssql_dump/mod.rs:14232-14252 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:14199` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (21 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:28745 — crates/ibcmd-dump/src/mssql_dump/mod.rs:28745-28765 | crates/ibcmd-dump/src/mssql_dump/mod.rs:30232-30252 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (21 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:28816 — crates/ibcmd-dump/src/mssql_dump/mod.rs:28816-28836 | crates/ibcmd-dump/src/mssql_dump/mod.rs:30281-30301 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (21 lines × 2) crates/ibcmd-moxel/src/lib.rs:13175 — crates/ibcmd-moxel/src/lib.rs:13175-13195 | crates/ibcmd-moxel/src/lib.rs:13529-13549 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-moxel/src/lib.rs:13529` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (21 lines × 2) crates/ibcmd-xml/src/metadata/constant.rs:1392 — crates/ibcmd-xml/src/metadata/constant.rs:1392-1412 | crates/ibcmd-xml/src/metadata/language.rs:649-669 — before extracting anything, compare `crates/ibcmd-xml/src/metadata/constant.rs` and `crates/ibcmd-xml/src/metadata/language.rs` as WHOLE FILES: this scan already matched 19 separate duplicated blocks between them, totalling at least 213 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. 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 `return` inside it is the body's own exit and keeps its meaning in the moved unit.
  • Duplicated block (21 lines × 2) src/source_audit.rs:290 — src/source_audit.rs:290-310 | src/source_audit.rs:574-594 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `src/source_audit.rs:290` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (21 lines × 2) crates/ibcmd-form-writer/src/lib.rs:21447 — crates/ibcmd-form-writer/src/lib.rs:21447-21467 | crates/ibcmd-form-writer/src/lib.rs:21705-21725 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-form-writer/src/lib.rs:21447` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (21 lines × 2) crates/ibcmd-form-native/src/lib.rs:6578 — crates/ibcmd-form-native/src/lib.rs:6578-6598 | crates/ibcmd-form-native/src/lib.rs:8357-8377 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-form-native/src/lib.rs:6578` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (21 lines × 2) crates/ibcmd-compiler-families/src/compiler/bodies/mod.rs:125 — crates/ibcmd-compiler-families/src/compiler/bodies/mod.rs:125-145 | crates/ibcmd-compiler-families/src/compiler/families/assets.rs:985-1005 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/bodies/mod.rs:125` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (8 lines × 4) · ×11
  • Duplicated block (8 lines × 4) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:549 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:549-556 | crates/ibcmd-compiler-families/src/compiler/families/services.rs:1198-1205 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:964-971 | crates/ibcmd-compiler-families/src/compiler/families/utility.rs:313-320 — before extracting anything, compare `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs` and `crates/ibcmd-compiler-families/src/compiler/families/services.rs` as WHOLE FILES: this scan already matched 10 separate duplicated blocks between them, totalling at least 103 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. 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 `return` inside it is the body's own exit and keeps its meaning in the moved unit.
  • Duplicated block (8 lines × 4) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:3771 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:3771-3778 | crates/ibcmd-compiler-families/src/compiler/families/services.rs:3575-3582 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:2592-2599 | crates/ibcmd-compiler-families/src/compiler/families/utility.rs:2110-2117 — before extracting anything, compare `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs` and `crates/ibcmd-compiler-families/src/compiler/families/services.rs` as WHOLE FILES: this scan already matched 10 separate duplicated blocks between them, totalling at least 103 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place.
  • Duplicated block (8 lines × 4) crates/ibcmd-dump/src/mssql_dump/mod.rs:27748 — crates/ibcmd-dump/src/mssql_dump/mod.rs:27748-27755 | crates/ibcmd-dump/src/mssql_dump/mod.rs:28602-28609 | crates/ibcmd-dump/src/mssql_dump/mod.rs:30113-30120 | crates/ibcmd-dump/src/mssql_dump/mod.rs:31401-31408 — all 4 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:27748` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (8 lines × 4) crates/ibcmd-dump/src/mssql_dump/mod.rs:28897 — crates/ibcmd-dump/src/mssql_dump/mod.rs:28897-28904 | crates/ibcmd-dump/src/mssql_dump/mod.rs:29929-29936 | crates/ibcmd-dump/src/mssql_dump/mod.rs:32823-32830 | crates/ibcmd-dump/src/mssql_dump/mod.rs:33755-33762 — all 4 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:28897` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (8 lines × 4) crates/ibcmd-edt/src/extensions.rs:8 — crates/ibcmd-edt/src/extensions.rs:8-15 | crates/ibcmd-edt/src/extensions.rs:44-51 | crates/ibcmd-edt/src/extensions.rs:78-85 | crates/ibcmd-edt/src/extensions.rs:112-119 — all 4 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-edt/src/extensions.rs:8` it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows — the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members' bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run — a one-line delegation has no helper inside it to lift — so generate the run from the set it enumerates, or accept it and keep each member's own documentation with it.
  • Duplicated block (8 lines × 4) crates/ibcmd-form-body/src/form_body.rs:25008 — crates/ibcmd-form-body/src/form_body.rs:25008-25015 | crates/ibcmd-form-body/src/form_body.rs:27071-27078 | crates/ibcmd-form-body/src/form_body.rs:27400-27407 | crates/ibcmd-form-body/src/form_body.rs:30528-30535 — all 4 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited.
  • Duplicated block (8 lines × 4) crates/ibcmd-form-body/src/form_body.rs:38516 — crates/ibcmd-form-body/src/form_body.rs:38516-38523 | crates/ibcmd-form-body/src/form_body.rs:39149-39156 | crates/ibcmd-form-body/src/form_body.rs:39347-39354 | crates/ibcmd-form-body/src/form_body.rs:39423-39430 — all 4 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-form-body/src/form_body.rs:38516` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, `crates/ibcmd-form-body/src/form_body.rs:39356` calls `form_chart_compact`, `get` and `crates/ibcmd-form-body/src/form_body.rs:38525` does not — after which the two agree again for 3 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
  • Duplicated block (8 lines × 4) crates/ibcmd-metadata-blob/src/lib.rs:5055 — crates/ibcmd-metadata-blob/src/lib.rs:5055-5062 | crates/ibcmd-metadata-blob/src/lib.rs:5220-5227 | crates/ibcmd-metadata-blob/src/lib.rs:5578-5585 | crates/ibcmd-metadata-blob/src/lib.rs:5689-5696 — all 4 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-metadata-blob/src/lib.rs:5055` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, `crates/ibcmd-metadata-blob/src/lib.rs:5063` calls `path_ends_with` and `crates/ibcmd-metadata-blob/src/lib.rs:5586` does not — after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
  • Duplicated block (8 lines × 4) crates/ibcmd-xml/src/metadata/services.rs:1987 — crates/ibcmd-xml/src/metadata/services.rs:1987-1994 | crates/ibcmd-xml/src/metadata/services.rs:2316-2323 | crates/ibcmd-xml/src/metadata/services.rs:2358-2365 | crates/ibcmd-xml/src/metadata/services.rs:2396-2403 — all 4 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-xml/src/metadata/services.rs:1987` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, `crates/ibcmd-xml/src/metadata/services.rs:1986` calls `reject_attributes` and `crates/ibcmd-xml/src/metadata/services.rs:2315` does not — after which the two agree again for 4 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
  • Duplicated block (8 lines × 4) src/dropin/parse.rs:974 — src/dropin/parse.rs:974-981 | src/dropin/parse.rs:1166-1173 | src/dropin/parse.rs:1233-1240 | src/dropin/parse.rs:1266-1273 — all 4 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited.
  • Duplicated block (8 lines × 4) crates/ibcmd-metadata-model/src/metadata_model/registers_export.rs:523 — crates/ibcmd-metadata-model/src/metadata_model/registers_export.rs:523-530 | crates/ibcmd-metadata-model/src/metadata_model/registers_export.rs:648-655 | crates/ibcmd-metadata-model/src/metadata_model/registers_export.rs:855-862 | crates/ibcmd-metadata-model/src/metadata_model/registers_export.rs:1029-1036 — all 4 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, `crates/ibcmd-metadata-model/src/metadata_model/registers_export.rs:531` calls `modern` and `crates/ibcmd-metadata-model/src/metadata_model/registers_export.rs:656` does not — after which the two agree again for 4 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
D4 · Code Duplication · Members sharing a duplicated core (5 members, 50+ identical tokens) · ×10
  • Members sharing a duplicated core (5 members, 50+ identical tokens) crates/ibcmd-compiler/src/compiler/bootstrap.rs:1822 — crates/ibcmd-compiler/src/compiler/bootstrap.rs:1822-1844 | crates/ibcmd-xml/src/metadata/characteristics.rs:415-434 | crates/ibcmd-xml/src/metadata/configuration_mobile.rs:14-29 | crates/ibcmd-xml/src/metadata/configuration_v85_projection.rs:15-26 | crates/ibcmd-xml/src/metadata/external_data_source.rs:33-43 — These 5 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below — it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 5 times. The repair is at the members' grain — factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 5 times.
  • Members sharing a duplicated core (5 members, 50+ identical tokens) crates/ibcmd-dump/src/mssql_dump/mod.rs:26207 — crates/ibcmd-dump/src/mssql_dump/mod.rs:26207-26223 | crates/ibcmd-dump/src/mssql_dump/mod.rs:28855-28868 | crates/ibcmd-dump/src/mssql_dump/mod.rs:29904-29917 | crates/ibcmd-dump/src/mssql_dump/mod.rs:31145-31162 | crates/ibcmd-dump/src/mssql_dump/mod.rs:31929-31942 — These 5 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below — it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 5 times. The repair is at the members' grain — factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 5 times.
  • Members sharing a duplicated core (5 members, 50+ identical tokens) crates/ibcmd-form-body/src/form_body.rs:2807 — crates/ibcmd-form-body/src/form_body.rs:2807-2820 | crates/ibcmd-form-body/src/form_body.rs:3370-3384 | crates/ibcmd-form-body/src/form_body.rs:3386-3401 | crates/ibcmd-form-body/src/form_body.rs:3503-3524 | crates/ibcmd-form-body/src/form_body.rs:3526-3539 — These 5 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below — it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 5 times. The repair is at the members' grain — factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 5 times.
  • Members sharing a duplicated core (5 members, 50+ identical tokens) crates/ibcmd-form-writer/src/lib.rs:15627 — crates/ibcmd-form-writer/src/lib.rs:15627-15639 | crates/ibcmd-form-writer/src/lib.rs:15872-15884 | crates/ibcmd-form-writer/src/lib.rs:15886-15898 | crates/ibcmd-form-writer/src/lib.rs:15900-15912 | crates/ibcmd-form-writer/src/lib.rs:15939-15951 — These 5 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below — it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 5 times. The repair is at the members' grain — factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 5 times.
  • Members sharing a duplicated core (5 members, 50+ identical tokens) crates/ibcmd-metadata-blob/src/lib.rs:5781 — crates/ibcmd-metadata-blob/src/lib.rs:5781-5955 | crates/ibcmd-metadata-blob/src/lib.rs:5960-6095 | crates/ibcmd-metadata-blob/src/lib.rs:6097-6217 | crates/ibcmd-metadata-blob/src/lib.rs:6283-6445 | crates/ibcmd-metadata-blob/src/lib.rs:8117-8173 — These 5 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below — it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 5 times. The repair is at the members' grain — factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 5 times.
  • Members sharing a duplicated core (5 members, 50+ identical tokens) crates/ibcmd-metadata-model/src/metadata_model/registers_export.rs:522 — crates/ibcmd-metadata-model/src/metadata_model/registers_export.rs:522-645 | crates/ibcmd-metadata-model/src/metadata_model/registers_export.rs:647-738 | crates/ibcmd-metadata-model/src/metadata_model/registers_export.rs:740-852 | crates/ibcmd-metadata-model/src/metadata_model/registers_export.rs:854-971 | crates/ibcmd-metadata-model/src/metadata_model/registers_export.rs:1028-1078 — These 5 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below — it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 5 times. The repair is at the members' grain — factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 5 times.
  • Members sharing a duplicated core (5 members, 50+ identical tokens) crates/ibcmd-xml/src/dcs.rs:2387 — crates/ibcmd-xml/src/dcs.rs:2387-2514 | crates/ibcmd-xml/src/dcs.rs:2779-2896 | crates/ibcmd-xml/src/dcs.rs:3388-3461 | crates/ibcmd-xml/src/dcs.rs:3576-3646 | crates/ibcmd-xml/src/dcs.rs:3651-3766 — These 5 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below — it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 5 times. The repair is at the members' grain — factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 5 times.
  • Members sharing a duplicated core (5 members, 50+ identical tokens) crates/ibcmd-xml/src/metadata/functional_option.rs:310 — crates/ibcmd-xml/src/metadata/functional_option.rs:310-324 | crates/ibcmd-xml/src/metadata/functional_options_parameter.rs:292-306 | crates/ibcmd-xml/src/metadata/language.rs:249-263 | crates/ibcmd-xml/src/metadata/services.rs:2429-2443 | crates/ibcmd-xml/src/metadata/session_parameter.rs:676-690 — These 5 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below — it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 5 times. The repair is at the members' grain — factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 5 times.
  • Members sharing a duplicated core (5 members, 50+ identical tokens) REDACTED:974 — REDACTED:974-1022 | REDACTED:1039-1060 | src/mssql_apply.rs:716-818 | src/mssql_extension_load.rs:141-390 | src/mssql_extension_load.rs:394-420 — These 5 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below — it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 5 times. The repair is at the members' grain — factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 5 times.
  • Members sharing a duplicated core (5 members, 50+ identical tokens) src/storage_map.rs:213 — src/storage_map.rs:213-246 | src/storage_map.rs:248-281 | src/storage_map.rs:283-316 | src/storage_map.rs:318-353 | src/storage_map.rs:355-388 — These 5 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below — it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 5 times. The repair is at the members' grain — factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 5 times.
D4 · Code Duplication · Edited copy of a member (22 corresponding lines) · ×10
  • Edited copy of a member (22 corresponding lines) crates/ibcmd-restructure-engine/src/restructure/caches/xdto_types.rs:94 — crates/ibcmd-restructure-engine/src/restructure/caches/xdto_types.rs:94-115 | crates/ibcmd-restructure-engine/src/restructure/xdto.rs:68-89 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (22 corresponding lines) crates/ibcmd-dump/src/mssql_dump/mod.rs:32855 — crates/ibcmd-dump/src/mssql_dump/mod.rs:32855-32876 | crates/ibcmd-dump/src/mssql_dump/mod.rs:32950-32981 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (22 corresponding lines) crates/ibcmd-form-body/src/form_body.rs:29907 — crates/ibcmd-form-body/src/form_body.rs:29907-29931 | crates/ibcmd-form-body/src/form_body.rs:29938-29959 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (22 corresponding lines) REDACTED:226 — REDACTED:226-247 | src/dump_sources.rs:293-319 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (22 corresponding lines) crates/ibcmd-mssql-live/src/mssql_managed_worker/native.rs:1667 — crates/ibcmd-mssql-live/src/mssql_managed_worker/native.rs:1667-1696 | REDACTED:837-858 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (22 corresponding lines) crates/ibcmd-form-native/src/lib.rs:6075 — crates/ibcmd-form-native/src/lib.rs:6075-6096 | crates/ibcmd-form-native/src/lib.rs:8764-8790 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (22 corresponding lines) crates/ibcmd-form-schema/src/lib.rs:830 — crates/ibcmd-form-schema/src/lib.rs:830-851 | crates/ibcmd-form-schema/src/lib.rs:853-874 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (22 corresponding lines) crates/ibcmd-dump/src/mssql_dump/mod.rs:7138 — crates/ibcmd-dump/src/mssql_dump/mod.rs:7138-7162 | crates/ibcmd-dump/src/mssql_dump/selected.rs:228-249 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (22 corresponding lines) crates/ibcmd-cf/src/export.rs:344 — crates/ibcmd-cf/src/export.rs:344-367 | REDACTED:2936-2957 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (22 corresponding lines) _onecdec/make_config_compat_fixtures.py:28 — _onecdec/make_config_compat_fixtures.py:28-49 | _onecdec/make_home_page_fixtures.py:85-114 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copy of a member (16 corresponding lines) · ×10
  • Edited copy of a member (16 corresponding lines) crates/ibcmd-form-writer/src/form_chart.rs:845 — crates/ibcmd-form-writer/src/form_chart.rs:845-860 | crates/ibcmd-form-writer/src/form_chart.rs:862-877 — These two members are one piece of code written twice and then edited apart: 16 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (16 corresponding lines) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:3542 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:3542-3558 | crates/ibcmd-compiler-families/src/compiler/families/utility.rs:1881-1896 — These two members are one piece of code written twice and then edited apart: 16 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (16 corresponding lines) crates/ibcmd-form-writer/src/lib.rs:6234 — crates/ibcmd-form-writer/src/lib.rs:6234-6249 | crates/ibcmd-form-writer/src/lib.rs:6270-6292 — These two members are one piece of code written twice and then edited apart: 16 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (16 corresponding lines) crates/ibcmd-dump/src/mssql_dump/mod.rs:22465 — crates/ibcmd-dump/src/mssql_dump/mod.rs:22465-22480 | crates/ibcmd-dump/src/mssql_dump/mod.rs:23069-23091 — These two members are one piece of code written twice and then edited apart: 16 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (16 corresponding lines) crates/ibcmd-xml/src/metadata/constant.rs:568 — crates/ibcmd-xml/src/metadata/constant.rs:568-587 | crates/ibcmd-xml/src/metadata/session_parameter.rs:474-489 — These two members are one piece of code written twice and then edited apart: 16 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (16 corresponding lines) crates/ibcmd-xml/src/dcs_schema.rs:2604 — crates/ibcmd-xml/src/dcs_schema.rs:2604-2622 | crates/ibcmd-xml/src/dcs_schema.rs:2623-2638 — These two members are one piece of code written twice and then edited apart: 16 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (16 corresponding lines) crates/ibcmd-form-writer/src/lib.rs:21862 — crates/ibcmd-form-writer/src/lib.rs:21862-21877 | crates/ibcmd-form-writer/src/lib.rs:22252-22267 — These two members are one piece of code written twice and then edited apart: 16 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (16 corresponding lines) src/commands/cf.rs:652 — src/commands/cf.rs:652-667 | src/commands/cf.rs:1481-1496 — These two members are one piece of code written twice and then edited apart: 16 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (16 corresponding lines) src/dcs_template_audit.rs:339 — src/dcs_template_audit.rs:339-354 | src/source_audit.rs:2423-2438 — These two members are one piece of code written twice and then edited apart: 16 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (16 corresponding lines) crates/ibcmd-metadata-model/src/metadata_model/registers_parts.rs:535 — crates/ibcmd-metadata-model/src/metadata_model/registers_parts.rs:535-551 | crates/ibcmd-metadata-model/src/metadata_model/objects_parts.rs:1167-1182 — These two members are one piece of code written twice and then edited apart: 16 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copy of a member (4 corresponding lines) · ×10
  • Edited copy of a member (4 corresponding lines) crates/ibcmd-dump/src/mssql_dump/incremental.rs:121 — crates/ibcmd-dump/src/mssql_dump/incremental.rs:121-124 | src/plan.rs:1349-1352 — These two members are one piece of code written twice and then edited apart: 4 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (4 corresponding lines) crates/ibcmd-form-body/src/form_body.rs:20297 — crates/ibcmd-form-body/src/form_body.rs:20297-20300 | crates/ibcmd-form-schema/src/lib.rs:9069-9072 — These two members are one piece of code written twice and then edited apart: 4 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (4 corresponding lines) crates/ibcmd-form-body/src/form_body.rs:18307 — crates/ibcmd-form-body/src/form_body.rs:18307-18310 | crates/ibcmd-form-schema/src/lib.rs:1681-1684 — These two members are one piece of code written twice and then edited apart: 4 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (4 corresponding lines) crates/ibcmd-form-body/src/form_body.rs:18530 — crates/ibcmd-form-body/src/form_body.rs:18530-18533 | crates/ibcmd-form-schema/src/lib.rs:8844-8847 — These two members are one piece of code written twice and then edited apart: 4 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (4 corresponding lines) crates/ibcmd-form-body/src/layout_8_5_1.rs:304 — crates/ibcmd-form-body/src/layout_8_5_1.rs:304-307 | crates/ibcmd-form-writer/src/form/load_8_5_1.rs:1212-1215 — These two members are one piece of code written twice and then edited apart: 4 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (4 corresponding lines) crates/ibcmd-metadata-model/src/metadata_model/common_export.rs:81 — crates/ibcmd-metadata-model/src/metadata_model/common_export.rs:81-84 | crates/ibcmd-metadata-model/src/metadata_model/forms_export.rs:88-91 — These two members are one piece of code written twice and then edited apart: 4 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (4 corresponding lines) crates/ibcmd-compiler/src/compiler/external_intake.rs:125 — crates/ibcmd-compiler/src/compiler/external_intake.rs:125-128 | crates/ibcmd-compiler/src/compiler/external_owned.rs:75-78 — These two members are one piece of code written twice and then edited apart: 4 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (4 corresponding lines) crates/ibcmd-dump/src/mssql_dump/source_assets.rs:3560 — crates/ibcmd-dump/src/mssql_dump/source_assets.rs:3560-3563 | crates/ibcmd-moxel/src/lib.rs:3201-3204 — These two members are one piece of code written twice and then edited apart: 4 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (4 corresponding lines) src/infobase_oracle.rs:1059 — src/infobase_oracle.rs:1059-1062 | src/mssql/stage_guard.rs:644-647 — These two members are one piece of code written twice and then edited apart: 4 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (4 corresponding lines) _onecdec/make_adopted_kinds_fixture.py:27 — _onecdec/make_adopted_kinds_fixture.py:27-30 | _onecdec/make_adopted_widened_fixture.py:29-32 — These two members are one piece of code written twice and then edited apart: 4 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Duplicated block (23 lines × 2) · ×10
  • Duplicated block (23 lines × 2) crates/ibcmd-1c-text/src/fields.rs:98 — crates/ibcmd-1c-text/src/fields.rs:98-120 | crates/ibcmd-1c-text/src/fields.rs:145-167 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-1c-text/src/fields.rs:98` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (23 lines × 2) crates/ibcmd-compiler-families/src/compiler/bodies/mod.rs:119 — crates/ibcmd-compiler-families/src/compiler/bodies/mod.rs:119-141 | crates/ibcmd-compiler-families/src/compiler/families/commands.rs:195-217 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/bodies/mod.rs:119` it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows — the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members' bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run — a one-line delegation has no helper inside it to lift — so generate the run from the set it enumerates, or accept it and keep each member's own documentation with it. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, `crates/ibcmd-compiler-families/src/compiler/families/commands.rs:219` calls `as_str` and `crates/ibcmd-compiler-families/src/compiler/bodies/mod.rs:143` does not — after which the two agree again for 3 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
  • Duplicated block (23 lines × 2) crates/ibcmd-compiler-families/src/compiler/families/commands.rs:1240 — crates/ibcmd-compiler-families/src/compiler/families/commands.rs:1240-1262 | crates/ibcmd-compiler-families/src/compiler/families/modules.rs:448-470 — before extracting anything, compare `crates/ibcmd-compiler-families/src/compiler/families/commands.rs` and `crates/ibcmd-compiler-families/src/compiler/families/modules.rs` as WHOLE FILES: this scan already matched 9 separate duplicated blocks between them, totalling at least 97 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/commands.rs:1240` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (23 lines × 2) crates/ibcmd-compiler-families/src/compiler/families/form.rs:208 — crates/ibcmd-compiler-families/src/compiler/families/form.rs:208-230 | crates/ibcmd-compiler-families/src/compiler/families/modules.rs:134-156 — before extracting anything, compare `crates/ibcmd-compiler-families/src/compiler/families/form.rs` and `crates/ibcmd-compiler-families/src/compiler/families/modules.rs` as WHOLE FILES: this scan already matched 8 separate duplicated blocks between them, totalling at least 141 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/form.rs:208` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (23 lines × 2) crates/ibcmd-form-body/src/dcs.rs:1578 — crates/ibcmd-form-body/src/dcs.rs:1578-1600 | crates/ibcmd-xml/src/dcs_schema.rs:5001-5023 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-form-body/src/dcs.rs:1578` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (23 lines × 2) crates/ibcmd-form-body/src/form_body.rs:20863 — crates/ibcmd-form-body/src/form_body.rs:20863-20885 | crates/ibcmd-form-body/src/form_body.rs:20898-20920 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-form-body/src/form_body.rs:20863` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (23 lines × 2) crates/ibcmd-metadata-model/src/metadata_model/objects_export.rs:1437 — crates/ibcmd-metadata-model/src/metadata_model/objects_export.rs:1437-1459 | crates/ibcmd-metadata-model/src/metadata_model/registers_export.rs:403-425 — before extracting anything, compare `crates/ibcmd-metadata-model/src/metadata_model/objects_export.rs` and `crates/ibcmd-metadata-model/src/metadata_model/registers_export.rs` as WHOLE FILES: this scan already matched 7 separate duplicated blocks between them, totalling at least 124 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-metadata-model/src/metadata_model/objects_export.rs:1437` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (23 lines × 2) REDACTED:117 — REDACTED:117-139 | REDACTED:465-487 — before extracting anything, compare `REDACTED` and `REDACTED` as WHOLE FILES: this scan already matched 3 separate duplicated blocks between them, totalling at least 61 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 `REDACTED:117` it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows — the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members' bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run — a one-line delegation has no helper inside it to lift — so generate the run from the set it enumerates, or accept it and keep each member's own documentation with it.
  • Duplicated block (23 lines × 2) src/dropin/parse.rs:1234 — src/dropin/parse.rs:1234-1256 | src/dropin/parse.rs:1267-1289 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `src/dropin/parse.rs:1234` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (23 lines × 2) crates/ibcmd-compiler-families/src/compiler/families/form.rs:860 — crates/ibcmd-compiler-families/src/compiler/families/form.rs:860-882 | crates/ibcmd-compiler-families/src/compiler/families/modules.rs:347-369 — before extracting anything, compare `crates/ibcmd-compiler-families/src/compiler/families/form.rs` and `crates/ibcmd-compiler-families/src/compiler/families/modules.rs` as WHOLE FILES: this scan already matched 8 separate duplicated blocks between them, totalling at least 141 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/form.rs:860` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note first that the copies are not typed on the same thing: the declarations holding them bind `profile` to `&FormMetadataProfile` in one and `&CommonModuleProfile` in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH — their common supertype where they have one, or a new abstraction over them where they do not — and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract.
D4 · Code Duplication · Duplicated block (20 lines × 2) · ×10
  • Duplicated block (20 lines × 2) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:2956 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:2956-2975 | crates/ibcmd-compiler-families/src/compiler/families/utility.rs:1535-1554 — before extracting anything, compare `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs` and `crates/ibcmd-compiler-families/src/compiler/families/utility.rs` as WHOLE FILES: this scan already matched 65 separate duplicated blocks between them, totalling at least 934 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:2956` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (20 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:38511 — crates/ibcmd-dump/src/mssql_dump/mod.rs:38511-38530 | crates/ibcmd-dump/src/mssql_dump/mod.rs:40624-40643 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:38511` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (20 lines × 2) crates/ibcmd-dump/src/mssql_dump/refs.rs:1339 — crates/ibcmd-dump/src/mssql_dump/refs.rs:1339-1358 | crates/ibcmd-dump/src/mssql_dump/refs.rs:1421-1440 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/refs.rs:1339` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (20 lines × 2) crates/ibcmd-form-writer/src/form/load_8_5_1.rs:329 — crates/ibcmd-form-writer/src/form/load_8_5_1.rs:329-348 | crates/ibcmd-form-writer/src/form/xml_2_21_writer.rs:1600-1619 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-form-writer/src/form/load_8_5_1.rs:329` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, `crates/ibcmd-form-writer/src/form/xml_2_21_writer.rs:1597` calls `within` and `crates/ibcmd-form-writer/src/form/load_8_5_1.rs:328` does not — after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
  • Duplicated block (20 lines × 2) crates/ibcmd-form-writer/src/lib.rs:17989 — crates/ibcmd-form-writer/src/lib.rs:17989-18008 | crates/ibcmd-form-writer/src/lib.rs:18151-18170 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-form-writer/src/lib.rs:17989` it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows — the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members' bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run — a one-line delegation has no helper inside it to lift — so generate the run from the set it enumerates, or accept it and keep each member's own documentation with it. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, `crates/ibcmd-form-writer/src/lib.rs:18148` calls `form_new_extended_group_title_text_color`, `form_new_extended_group_title_font`, `form_new_extended_group_options` and `crates/ibcmd-form-writer/src/lib.rs:17988` does not — after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
  • Duplicated block (20 lines × 2) src/conversion.rs:1042 — src/conversion.rs:1042-1061 | src/conversion.rs:1224-1243 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (20 lines × 2) src/dropin/mod.rs:355 — src/dropin/mod.rs:355-374 | src/dropin/mod.rs:391-410 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (20 lines × 2) src/external/export.rs:127 — src/external/export.rs:127-146 | src/external/export.rs:171-190 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (20 lines × 2) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:4359 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:4359-4378 | crates/ibcmd-compiler-families/src/compiler/families/utility.rs:2505-2524 — before extracting anything, compare `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs` and `crates/ibcmd-compiler-families/src/compiler/families/utility.rs` as WHOLE FILES: this scan already matched 65 separate duplicated blocks between them, totalling at least 934 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:4359` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (20 lines × 2) crates/ibcmd-form-body/src/form_body.rs:8602 — crates/ibcmd-form-body/src/form_body.rs:8602-8621 | crates/ibcmd-form-body/src/form_body.rs:8673-8692 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. 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 `return` inside it is the body's own exit and keeps its meaning in the moved unit.
D4 · Code Duplication · Duplicated block (9 lines × 3) · ×10
  • Duplicated block (9 lines × 3) crates/ibcmd-dump/src/mssql_dump/mod.rs:28994 — crates/ibcmd-dump/src/mssql_dump/mod.rs:28994-29002 | crates/ibcmd-dump/src/mssql_dump/mod.rs:30572-30580 | crates/ibcmd-dump/src/mssql_dump/mod.rs:31270-31278 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited.
  • Duplicated block (9 lines × 3) crates/ibcmd-form-writer/src/lib.rs:21824 — crates/ibcmd-form-writer/src/lib.rs:21824-21832 | crates/ibcmd-form-writer/src/lib.rs:22161-22169 | crates/ibcmd-form-writer/src/lib.rs:23215-23223 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (9 lines × 3) crates/ibcmd-metadata-blob/src/lib.rs:5574 — crates/ibcmd-metadata-blob/src/lib.rs:5574-5582 | crates/ibcmd-metadata-blob/src/lib.rs:5685-5693 | crates/ibcmd-metadata-blob/src/lib.rs:6297-6305 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-metadata-blob/src/lib.rs:5574` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (9 lines × 3) crates/ibcmd-moxel/src/lib.rs:8652 — crates/ibcmd-moxel/src/lib.rs:8652-8660 | crates/ibcmd-moxel/src/lib.rs:8882-8890 | crates/ibcmd-moxel/src/lib.rs:10473-10481 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. 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 `return` inside it is the body's own exit and keeps its meaning in the moved unit.
  • Duplicated block (9 lines × 3) crates/ibcmd-xml/src/metadata/business_objects.rs:467 — crates/ibcmd-xml/src/metadata/business_objects.rs:467-475 | crates/ibcmd-xml/src/metadata/utility_objects.rs:556-564 | crates/ibcmd-xml/src/metadata/utility_objects.rs:646-654 — before extracting anything, compare `crates/ibcmd-xml/src/metadata/business_objects.rs` and `crates/ibcmd-xml/src/metadata/utility_objects.rs` as WHOLE FILES: this scan already matched 11 separate duplicated blocks between them, totalling at least 111 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-xml/src/metadata/business_objects.rs:467` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (9 lines × 3) src/mssql_extension_export.rs:71 — src/mssql_extension_export.rs:71-79 | src/mssql_extension_load.rs:165-173 | src/mssql_extension_load.rs:456-464 — before extracting anything, compare `src/mssql_extension_export.rs` and `src/mssql_extension_load.rs` as WHOLE FILES: this scan already matched 4 separate duplicated blocks between them, totalling at least 42 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Note first that the copies are not typed on the same thing: the declarations holding them bind `args` to `&MssqlDumpExtensionArgs` in one and `&MssqlLoadExtensionArgs` in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH — their common supertype where they have one, or a new abstraction over them where they do not — and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract.
  • Duplicated block (9 lines × 3) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:2802 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:2802-2810 | crates/ibcmd-compiler-families/src/compiler/families/services.rs:2425-2433 | crates/ibcmd-compiler-families/src/compiler/families/utility.rs:1444-1452 — before extracting anything, compare `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs` and `crates/ibcmd-compiler-families/src/compiler/families/services.rs` as WHOLE FILES: this scan already matched 10 separate duplicated blocks between them, totalling at least 103 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:2802` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (9 lines × 3) crates/ibcmd-dump/src/mssql_dump/mod.rs:37970 — crates/ibcmd-dump/src/mssql_dump/mod.rs:37970-37980 | crates/ibcmd-dump/src/mssql_dump/mod.rs:40451-40459 | crates/ibcmd-dump/src/mssql_dump/mod.rs:44129-44137 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:37970` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (9 lines × 3) crates/ibcmd-xml/src/metadata/language.rs:136 — crates/ibcmd-xml/src/metadata/language.rs:136-145 | crates/ibcmd-xml/src/metadata/services.rs:876-884 | crates/ibcmd-xml/src/metadata/services.rs:918-926 — before extracting anything, compare `crates/ibcmd-xml/src/metadata/language.rs` and `crates/ibcmd-xml/src/metadata/services.rs` as WHOLE FILES: this scan already matched 6 separate duplicated blocks between them, totalling at least 53 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-xml/src/metadata/language.rs:136` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (9 lines × 3) crates/ibcmd-xml/src/metadata/common_objects.rs:162 — crates/ibcmd-xml/src/metadata/common_objects.rs:162-170 | crates/ibcmd-xml/src/metadata/hierarchical_objects.rs:311-319 | crates/ibcmd-xml/src/metadata/register_objects.rs:409-417 — before extracting anything, compare `crates/ibcmd-xml/src/metadata/common_objects.rs` and `crates/ibcmd-xml/src/metadata/hierarchical_objects.rs` as WHOLE FILES: this scan already matched 6 separate duplicated blocks between them, totalling at least 67 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-xml/src/metadata/common_objects.rs:162` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The `return` at the foot of the matched lines is the enclosing body's own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that `return` occupied — no decision has to be handed back and re-acted on.
D1 · Cyclomatic Complexity · ibcmd_restructure_engine · ×9
  • ibcmd_restructure_engine::restructure::plan::plan_object (cyclomatic 52) REDACTED:1359 — ibcmd_restructure_engine::restructure::plan::plan_object has cyclomatic complexity 52 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
  • ibcmd_restructure_engine::restructure::caches::trace_diagnostic::inspect (cyclomatic 48) crates/ibcmd-restructure-engine/src/restructure/caches/trace_diagnostic.rs:220 — ibcmd_restructure_engine::restructure::caches::trace_diagnostic::inspect 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.
  • ibcmd_restructure_engine::restructure::entry::main_entry (cyclomatic 42) crates/ibcmd-restructure-engine/src/restructure/entry.rs:351 — ibcmd_restructure_engine::restructure::entry::main_entry has cyclomatic complexity 42 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
  • ibcmd_restructure_engine::restructure::plan::plan (cyclomatic 39) REDACTED:1062 — ibcmd_restructure_engine::restructure::plan::plan has cyclomatic complexity 39 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
  • ibcmd_restructure_engine::restructure::caches::slots::declared_slots (cyclomatic 28) crates/ibcmd-restructure-engine/src/restructure/caches/slots.rs:279 — ibcmd_restructure_engine::restructure::caches::slots::declared_slots 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 — the same kind of value, with no behaviour of its own — 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.
  • ibcmd_restructure_engine::restructure::plan::check_object (cyclomatic 25) REDACTED:2211 — ibcmd_restructure_engine::restructure::plan::check_object 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.
  • ibcmd_restructure_engine::restructure::exec::column_matches (cyclomatic 20) crates/ibcmd-restructure-engine/src/restructure/exec.rs:277 — ibcmd_restructure_engine::restructure::exec::column_matches 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 — the same kind of value, with no behaviour of its own — 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.
  • ibcmd_restructure_engine::restructure::plan::widened_field (cyclomatic 17) REDACTED:787 — ibcmd_restructure_engine::restructure::plan::widened_field 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.
  • ibcmd_restructure_engine::restructure::caches::change::rewrite (cyclomatic 16) crates/ibcmd-restructure-engine/src/restructure/caches/change.rs:64 — ibcmd_restructure_engine::restructure::caches::change::rewrite 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.
D2 · Cognitive Complexity · ibcmd_edt · ×9
  • ibcmd_edt::bounded::validate_xml_with_policy (cognitive 158) crates/ibcmd-edt/src/bounded.rs:31 — ibcmd_edt::bounded::validate_xml_with_policy has cognitive complexity 158 (threshold 15). Drivers by points: if/else 31 (104 pts), boolean chains 36, loops 5 (16 pts), match/switch 1 (2 pts) (nesting depth added 85). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_edt::codec::validate_control (cognitive 113) crates/ibcmd-edt/src/codec.rs:120 — ibcmd_edt::codec::validate_control has cognitive complexity 113 (threshold 15). Drivers by points: if/else 20 (70 pts), loops 8 (23 pts), match/switch 5 (16 pts), boolean chains 4 (nesting depth added 76). Of this number, 98 points are the body's own statements and 15 belong to 2 function items inside it that branch. The drivers above price the dispatch low by construction — a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full — so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident.
  • ibcmd_edt::codec::same_body_bytes (cognitive 77) crates/ibcmd-edt/src/codec.rs:1063 — ibcmd_edt::codec::same_body_bytes has cognitive complexity 77 (threshold 15). Drivers by points: boolean chains 60, if/else 32 (52 pts), loops 5 (11 pts), match/switch 3 (5 pts) (nesting depth added 28). 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 shape REPEATS in the file: one other method here (ibcmd_edt::codec::same_body_bytes::normalized) has the same decision points, in the same order, at the same nesting depths — 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.
  • ibcmd_edt::codec::canonical_inventory_with_policy (cognitive 61) crates/ibcmd-edt/src/codec.rs:822 — ibcmd_edt::codec::canonical_inventory_with_policy has cognitive complexity 61 (threshold 15). Drivers by points: if/else 11 (25 pts), match/switch 6 (21 pts), loops 6 (10 pts), boolean chains 5 (nesting depth added 33). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_edt::extensions::source_extensions_from_model (cognitive 48) crates/ibcmd-edt/src/extensions.rs:4 — ibcmd_edt::extensions::source_extensions_from_model has cognitive complexity 48 (threshold 15). Drivers by points: if/else 14 (26 pts), loops 12 (17 pts), boolean chains 5 (nesting depth added 17). Most of this is not in the body itself: 10 of the 48 points are its own statements and the rest belongs to 6 function items inside it that branch (visit, event_visit, chart_visit, …). 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.
  • ibcmd_edt::codec::same_body_bytes::normalized (cognitive 40) crates/ibcmd-edt/src/codec.rs:1249 — ibcmd_edt::codec::same_body_bytes::normalized has cognitive complexity 40 (threshold 15). Drivers by points: if/else 12 (18 pts), boolean chains 17, loops 3, match/switch 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. This shape REPEATS in the file: one other method here (ibcmd_edt::codec::same_body_bytes) has the same decision points, in the same order, at the same nesting depths — 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.
  • ibcmd_edt::bounded::visit (cognitive 31) crates/ibcmd-edt/src/bounded.rs:461 — ibcmd_edt::bounded::visit has cognitive complexity 31 (threshold 15). Drivers by points: if/else 12 (27 pts), boolean chains 2, loops 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.
  • ibcmd_edt::codec::inventory_accounting_with_profile (cognitive 22) crates/ibcmd-edt/src/codec.rs:455 — ibcmd_edt::codec::inventory_accounting_with_profile has cognitive complexity 22 (threshold 15). Drivers by points: if/else 7 (11 pts), match/switch 2 (7 pts), boolean chains 3, loops 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_edt::directory::accounting (cognitive 18) crates/ibcmd-edt/src/directory.rs:178 — ibcmd_edt::directory::accounting has cognitive complexity 18 (threshold 15). Drivers by points: match/switch 3 (7 pts), if/else 3 (6 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.
D2 · Cognitive Complexity · ibcmd_apply_check · ×9
  • ibcmd_apply_check::apply_check::plan::build (cognitive 78) crates/ibcmd-apply-check/src/apply_check/plan.rs:100 — ibcmd_apply_check::apply_check::plan::build has cognitive complexity 78 (threshold 15). Drivers by points: if/else 20 (39 pts), loops 10 (19 pts), match/switch 6 (11 pts), boolean chains 9 (nesting depth added 33). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_apply_check::apply_check::check::check_planned (cognitive 69) crates/ibcmd-apply-check/src/apply_check/check.rs:311 — ibcmd_apply_check::apply_check::check::check_planned has cognitive complexity 69 (threshold 15). Drivers by points: match/switch 14 (36 pts), if/else 11 (26 pts), loops 4 (5 pts), boolean chains 2 (nesting depth added 38). 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.
  • ibcmd_apply_check::apply_check::trees::check_trees (cognitive 39) crates/ibcmd-apply-check/src/apply_check/trees.rs:164 — ibcmd_apply_check::apply_check::trees::check_trees has cognitive complexity 39 (threshold 15). Drivers by points: match/switch 10 (23 pts), if/else 4 (8 pts), loops 6, boolean chains 2 (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.
  • ibcmd_apply_check::apply_check::rules::decide_child (cognitive 33) crates/ibcmd-apply-check/src/apply_check/rules.rs:328 — ibcmd_apply_check::apply_check::rules::decide_child has cognitive complexity 33 (threshold 15). Drivers by points: match/switch 10 (25 pts), if/else 5 (8 pts) (nesting depth added 18). 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.
  • ibcmd_apply_check::apply_check::tree_diff::diff_element (cognitive 23) crates/ibcmd-apply-check/src/apply_check/tree_diff.rs:201 — ibcmd_apply_check::apply_check::tree_diff::diff_element has cognitive complexity 23 (threshold 15). Drivers by points: if/else 6 (10 pts), loops 7, boolean chains 4, 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.
  • ibcmd_apply_check::apply_check::dbtree::compare_planned (cognitive 17) crates/ibcmd-apply-check/src/apply_check/dbtree.rs:312 — ibcmd_apply_check::apply_check::dbtree::compare_planned has cognitive complexity 17 (threshold 15). Drivers by points: if/else 3 (6 pts), match/switch 3 (6 pts), loops 4 (5 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.
  • ibcmd_apply_check::apply_check::s1::one (cognitive 17) crates/ibcmd-apply-check/src/apply_check/s1.rs:428 — ibcmd_apply_check::apply_check::s1::one has cognitive complexity 17 (threshold 15). Drivers by points: match/switch 7 (11 pts), if/else 5 (6 pts) (nesting depth added 5). 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.
  • ibcmd_apply_check::apply_check::dbtree::scan (cognitive 16) crates/ibcmd-apply-check/src/apply_check/dbtree.rs:145 — ibcmd_apply_check::apply_check::dbtree::scan has cognitive complexity 16 (threshold 15). Drivers by points: if/else 5 (8 pts), match/switch 2 (4 pts), loops 3, boolean chains 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_apply_check::apply_check::upgrade::align (cognitive 16) crates/ibcmd-apply-check/src/apply_check/upgrade.rs:282 — ibcmd_apply_check::apply_check::upgrade::align has cognitive complexity 16 (threshold 15). Drivers by points: if/else 6 (10 pts), boolean chains 3, loops 2 (3 pts) (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · BodyWriter · ×9
  • BodyWriter::format_record (cognitive 68) crates/ibcmd-compiler/src/compiler/bodies/mxl_native.rs:1895 — BodyWriter::format_record has cognitive complexity 68 (threshold 15). Drivers by points: if/else 13 (30 pts), match/switch 11 (30 pts), loops 5 (8 pts) (nesting depth added 39). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • BodyWriter::value_type_entry (cognitive 56) crates/ibcmd-compiler/src/compiler/bodies/mxl_native.rs:2154 — BodyWriter::value_type_entry has cognitive complexity 56 (threshold 15). Drivers by points: match/switch 8 (32 pts), if/else 6 (19 pts), boolean chains 3, loops 2 (nesting depth added 37). 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.
  • BodyWriter::font_record (cognitive 37) crates/ibcmd-compiler/src/compiler/bodies/mxl_native.rs:2422 — BodyWriter::font_record has cognitive complexity 37 (threshold 15). Drivers by points: if/else 15 (27 pts), match/switch 4 (9 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.
  • BodyWriter::mark_drawing_formats (cognitive 29) crates/ibcmd-compiler/src/compiler/bodies/mxl_native.rs:890 — BodyWriter::mark_drawing_formats has cognitive complexity 29 (threshold 15). Drivers by points: if/else 8 (20 pts), loops 6 (8 pts), boolean chains 1 (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • BodyWriter::merges (cognitive 24) crates/ibcmd-compiler/src/compiler/bodies/mxl_native.rs:1633 — BodyWriter::merges has cognitive complexity 24 (threshold 15). Drivers by points: if/else 4 (14 pts), loops 4 (6 pts), match/switch 1 (3 pts), boolean chains 1 (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • BodyWriter::drawing (cognitive 21) crates/ibcmd-compiler/src/compiler/bodies/mxl_native.rs:1336 — BodyWriter::drawing has cognitive complexity 21 (threshold 15). Drivers by points: if/else 8 (12 pts), match/switch 4 (6 pts), boolean chains 3 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • BodyWriter::column_sets (cognitive 19) crates/ibcmd-compiler/src/compiler/bodies/mxl_native.rs:1226 — BodyWriter::column_sets has cognitive complexity 19 (threshold 15). Drivers by points: if/else 5 (11 pts), loops 5 (6 pts), match/switch 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.
  • BodyWriter::rows (cognitive 17) crates/ibcmd-compiler/src/compiler/bodies/mxl_native.rs:1010 — BodyWriter::rows has cognitive complexity 17 (threshold 15). Drivers by points: if/else 3 (8 pts), loops 3 (6 pts), match/switch 1 (2 pts), boolean chains 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • BodyWriter::print_properties (cognitive 16) crates/ibcmd-compiler/src/compiler/bodies/mxl_native.rs:1757 — BodyWriter::print_properties has cognitive complexity 16 (threshold 15). Drivers by points: match/switch 4 (11 pts), if/else 2 (3 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.
D2 · Cognitive Complexity · ibcmd_compiler · ×9
  • ibcmd_compiler::compiler::bootstrap::compile_source_tree_mode (cognitive 39) crates/ibcmd-compiler/src/compiler/bootstrap.rs:406 — ibcmd_compiler::compiler::bootstrap::compile_source_tree_mode has cognitive complexity 39 (threshold 15). Drivers by points: if/else 14 (27 pts), loops 8 (9 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.
  • ibcmd_compiler::compiler::root::collect_configuration_families (cognitive 28) crates/ibcmd-compiler/src/compiler/root.rs:581 — ibcmd_compiler::compiler::root::collect_configuration_families has cognitive complexity 28 (threshold 15). Drivers by points: if/else 7 (18 pts), loops 5 (9 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.
  • ibcmd_compiler::compiler::bodies::mxl_native::typed_value (cognitive 22) crates/ibcmd-compiler/src/compiler/bodies/mxl_native.rs:2916 — ibcmd_compiler::compiler::bodies::mxl_native::typed_value has cognitive complexity 22 (threshold 15). Drivers by points: if/else 6 (13 pts), boolean chains 4, loops 2 (4 pts), match/switch 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.
  • ibcmd_compiler::compiler::bootstrap::project_configuration (cognitive 22) crates/ibcmd-compiler/src/compiler/bootstrap.rs:1340 — ibcmd_compiler::compiler::bootstrap::project_configuration has cognitive complexity 22 (threshold 15). Drivers by points: if/else 7 (10 pts), match/switch 3 (8 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.
  • ibcmd_compiler::compiler::bodies::mxl::decode_plain (cognitive 21) crates/ibcmd-compiler/src/compiler/bodies/mxl.rs:124 — ibcmd_compiler::compiler::bodies::mxl::decode_plain has cognitive complexity 21 (threshold 15). Drivers by points: if/else 12 (14 pts), boolean chains 5, loops 1 (2 pts) (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level.
  • ibcmd_compiler::compiler::bodies::mxl_native::parse_dom (cognitive 21) crates/ibcmd-compiler/src/compiler/bodies/mxl_native.rs:322 — ibcmd_compiler::compiler::bodies::mxl_native::parse_dom has cognitive complexity 21 (threshold 15). Drivers by points: if/else 5 (14 pts), match/switch 3 (6 pts), loops 1 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_compiler::compiler::bodies::dcs_2_21::with_stored_picture_values (cognitive 16) crates/ibcmd-compiler/src/compiler/bodies/dcs_2_21.rs:171 — ibcmd_compiler::compiler::bodies::dcs_2_21::with_stored_picture_values has cognitive complexity 16 (threshold 15). Drivers by points: if/else 7 (12 pts), match/switch 1 (2 pts), boolean chains 1, loops 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_compiler::compiler::bodies::predefined::validate_items (cognitive 16) crates/ibcmd-compiler/src/compiler/bodies/predefined.rs:350 — ibcmd_compiler::compiler::bodies::predefined::validate_items has cognitive complexity 16 (threshold 15). Drivers by points: if/else 9 (10 pts), boolean chains 5, loops 1 (nesting depth added 1). To reduce it, split the body: this score is breadth rather than depth — many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
  • ibcmd_compiler::compiler::root::validate_configuration_properties (cognitive 16) crates/ibcmd-compiler/src/compiler/root.rs:637 — ibcmd_compiler::compiler::root::validate_configuration_properties has cognitive complexity 16 (threshold 15). Drivers by points: if/else 5 (9 pts), loops 6, boolean chains 1 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D4 · Code Duplication · Edited copy of a member (24 corresponding lines) · ×9
  • Edited copy of a member (24 corresponding lines) src/external/rename.rs:122 — src/external/rename.rs:122-145 | src/external/rename.rs:176-200 — These two members are one piece of code written twice and then edited apart: 24 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (24 corresponding lines) crates/ibcmd-restructure-engine/src/restructure/caches/members.rs:124 — crates/ibcmd-restructure-engine/src/restructure/caches/members.rs:124-147 | crates/ibcmd-restructure-engine/src/restructure/catalog.rs:431-459 — These two members are one piece of code written twice and then edited apart: 24 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (24 corresponding lines) crates/ibcmd-metadata-blob/src/lib.rs:565 — crates/ibcmd-metadata-blob/src/lib.rs:565-588 | src/source_audit.rs:1098-1123 — These two members are one piece of code written twice and then edited apart: 24 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (24 corresponding lines) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:2604 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:2604-2630 | crates/ibcmd-compiler-families/src/compiler/families/utility.rs:1276-1299 — These two members are one piece of code written twice and then edited apart: 24 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (24 corresponding lines) crates/ibcmd-moxel/src/lib.rs:4688 — crates/ibcmd-moxel/src/lib.rs:4688-4711 | crates/ibcmd-moxel/src/lib.rs:10070-10093 — These two members are one piece of code written twice and then edited apart: 24 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (24 corresponding lines) src/file_infobase.rs:39 — src/file_infobase.rs:39-69 | src/file_infobase.rs:224-247 — These two members are one piece of code written twice and then edited apart: 24 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (24 corresponding lines) crates/ibcmd-schema/src/lib.rs:9425 — crates/ibcmd-schema/src/lib.rs:9425-9448 | crates/ibcmd-schema/src/lib.rs:9700-9727 — These two members are one piece of code written twice and then edited apart: 24 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (24 corresponding lines) crates/ibcmd-dump/src/mssql_dump/mod.rs:10050 — crates/ibcmd-dump/src/mssql_dump/mod.rs:10050-10073 | crates/ibcmd-dump/src/mssql_dump/mod.rs:10146-10171 — These two members are one piece of code written twice and then edited apart: 24 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (24 corresponding lines) _onecdec/make_choice_list_dates_fixture.py:63 — _onecdec/make_choice_list_dates_fixture.py:63-88 | _onecdec/make_role_rights_fixtures.py:54-77 — These two members are one piece of code written twice and then edited apart: 24 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copy of a member (25 corresponding lines) · ×9
  • Edited copy of a member (25 corresponding lines) crates/ibcmd-restructure/src/schema.rs:253 — crates/ibcmd-restructure/src/schema.rs:253-277 | crates/ibcmd-restructure/src/schema.rs:307-336 — These two members are one piece of code written twice and then edited apart: 25 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (25 corresponding lines) crates/ibcmd-dump/src/mssql_dump/mod.rs:10464 — crates/ibcmd-dump/src/mssql_dump/mod.rs:10464-10492 | crates/ibcmd-dump/src/mssql_dump/mod.rs:10506-10530 — These two members are one piece of code written twice and then edited apart: 25 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (25 corresponding lines) crates/ibcmd-form-writer/src/lib.rs:23326 — crates/ibcmd-form-writer/src/lib.rs:23326-23350 | crates/ibcmd-form-writer/src/lib.rs:23353-23377 — These two members are one piece of code written twice and then edited apart: 25 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (25 corresponding lines) crates/ibcmd-metadata-model/src/metadata_model/registers.rs:988 — crates/ibcmd-metadata-model/src/metadata_model/registers.rs:988-1017 | crates/ibcmd-metadata-model/src/metadata_model/registers.rs:1139-1163 — These two members are one piece of code written twice and then edited apart: 25 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (25 corresponding lines) crates/ibcmd-xml/src/metadata/business_objects.rs:466 — crates/ibcmd-xml/src/metadata/business_objects.rs:466-490 | crates/ibcmd-xml/src/metadata/utility_objects.rs:645-669 — These two members are one piece of code written twice and then edited apart: 25 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (25 corresponding lines) crates/ibcmd-dump/src/mssql_dump/mod.rs:31968 — crates/ibcmd-dump/src/mssql_dump/mod.rs:31968-31992 | crates/ibcmd-dump/src/mssql_dump/mod.rs:32001-32031 — These two members are one piece of code written twice and then edited apart: 25 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (25 corresponding lines) crates/ibcmd-restructure-engine/src/restructure/caches/help_props.rs:127 — crates/ibcmd-restructure-engine/src/restructure/caches/help_props.rs:127-156 | crates/ibcmd-restructure-engine/src/restructure/caches/help_props.rs:161-185 — These two members are one piece of code written twice and then edited apart: 25 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (25 corresponding lines) crates/ibcmd-dump/src/mssql_dump/mod.rs:9979 — crates/ibcmd-dump/src/mssql_dump/mod.rs:9979-10013 | REDACTED:7452-7476 — These two members are one piece of code written twice and then edited apart: 25 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (25 corresponding lines) _onecdec/make_compat_form_fixtures.py:90 — _onecdec/make_compat_form_fixtures.py:90-123 | _onecdec/make_extension_root_fixtures.py:124-148 — These two members are one piece of code written twice and then edited apart: 25 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Duplicated block (19 lines × 2) · ×9
  • Duplicated block (19 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:42661 — crates/ibcmd-dump/src/mssql_dump/mod.rs:42661-42679 | crates/ibcmd-dump/src/mssql_dump/mod.rs:42762-42780 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (19 lines × 2) crates/ibcmd-form-schema/src/lib.rs:833 — crates/ibcmd-form-schema/src/lib.rs:833-851 | crates/ibcmd-form-schema/src/lib.rs:856-874 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-form-schema/src/lib.rs:833` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (19 lines × 2) REDACTED:97 — REDACTED:97-115 | REDACTED:445-463 — before extracting anything, compare `REDACTED` and `REDACTED` as WHOLE FILES: this scan already matched 3 separate duplicated blocks between them, totalling at least 61 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 `REDACTED:97` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (19 lines × 2) crates/ibcmd-schema/src/lib.rs:9347 — crates/ibcmd-schema/src/lib.rs:9347-9365 | crates/ibcmd-schema/src/lib.rs:9642-9660 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-schema/src/lib.rs:9347` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The `return` at the foot of the matched lines is the enclosing body's own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that `return` occupied — no decision has to be handed back and re-acted on.
  • Duplicated block (19 lines × 2) src/conversion.rs:575 — src/conversion.rs:575-593 | src/conversion.rs:834-852 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `src/conversion.rs:575` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, `src/conversion.rs:832` calls `uses_base_free_compiler` and `src/conversion.rs:574` does not — after which the two agree again for 3 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
  • Duplicated block (19 lines × 2) REDACTED:9410 — REDACTED:9410-9428 | REDACTED:9531-9549 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (19 lines × 2) crates/ibcmd-compiler-families/src/compiler/families/simple.rs:487 — crates/ibcmd-compiler-families/src/compiler/families/simple.rs:487-505 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:543-561 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/simple.rs:487` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (19 lines × 2) REDACTED:47 — REDACTED:47-65 | REDACTED:395-413 — before extracting anything, compare `REDACTED` and `REDACTED` as WHOLE FILES: this scan already matched 3 separate duplicated blocks between them, totalling at least 61 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 `return` inside it is the body's own exit and keeps its meaning in the moved unit.
  • Duplicated block (19 lines × 2) crates/ibcmd-xml/src/dcs.rs:2529 — crates/ibcmd-xml/src/dcs.rs:2529-2547 | crates/ibcmd-xml/src/dcs.rs:3868-3886 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-xml/src/dcs.rs:2529` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note first that the copies are not typed on the same thing: the declarations holding them bind `policy` to `&ibcmd_schema::DcsFilterPolicy` in one and `&ibcmd_schema::DcsOrderPolicy` in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH — their common supertype where they have one, or a new abstraction over them where they do not — and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract.
D1 · Cyclomatic Complexity · ibcmd_edt · ×8
  • ibcmd_edt::bounded::validate_xml_with_policy (cyclomatic 76) crates/ibcmd-edt/src/bounded.rs:31 — ibcmd_edt::bounded::validate_xml_with_policy has cyclomatic complexity 76 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
  • ibcmd_edt::codec::same_body_bytes (cyclomatic 70) crates/ibcmd-edt/src/codec.rs:1063 — ibcmd_edt::codec::same_body_bytes has cyclomatic complexity 70 (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. This shape REPEATS in the file: one other method here (ibcmd_edt::codec::same_body_bytes::normalized) has the same decision points, in the same order, at the same nesting depths — 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.
  • ibcmd_edt::codec::validate_control (cyclomatic 44) crates/ibcmd-edt/src/codec.rs:120 — ibcmd_edt::codec::validate_control has cyclomatic complexity 44 (threshold 15). Of this number, 37 points are the body's own statements and 7 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.
  • ibcmd_edt::codec::canonical_inventory_with_policy (cyclomatic 34) crates/ibcmd-edt/src/codec.rs:822 — ibcmd_edt::codec::canonical_inventory_with_policy has cyclomatic complexity 34 (threshold 15). To reduce it, separate the branches: extract each independent case into its own named function so the top-level body reads as a short sequence of named decisions.
  • ibcmd_edt::codec::same_body_bytes::normalized (cyclomatic 34) crates/ibcmd-edt/src/codec.rs:1249 — ibcmd_edt::codec::same_body_bytes::normalized has cyclomatic complexity 34 (threshold 15). To reduce it, separate the branches: extract each independent case into its own named function so the top-level body reads as a short sequence of named decisions. This shape REPEATS in the file: one other method here (ibcmd_edt::codec::same_body_bytes) has the same decision points, in the same order, at the same nesting depths — 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.
  • ibcmd_edt::extensions::source_extensions_from_model (cyclomatic 31) crates/ibcmd-edt/src/extensions.rs:4 — ibcmd_edt::extensions::source_extensions_from_model has cyclomatic complexity 31 (threshold 15). Most of this is not in the body itself: 9 of the 31 points are its own statements and the rest belongs to 6 function items inside it that branch (visit, event_visit, chart_visit, …). 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.
  • ibcmd_edt::bounded::visit (cyclomatic 16) crates/ibcmd-edt/src/bounded.rs:461 — ibcmd_edt::bounded::visit 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.
  • ibcmd_edt::codec::inventory_accounting_with_profile (cyclomatic 16) crates/ibcmd-edt/src/codec.rs:455 — ibcmd_edt::codec::inventory_accounting_with_profile 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.
D3 · God Classes · ClassTooLong · ×8
  • ClassTooLong: BodyWriter crates/ibcmd-compiler/src/compiler/bodies/mxl_native.rs:714 — ClassTooLong — 1494 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted), 38 methods, 2 blocks, lines 714-2692. The bar is 400 significant lines; this is 1094 over it, 3.74× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
  • ClassTooLong: DataCompositionXmlWriter crates/ibcmd-form-body/src/dcs.rs:1786 — ClassTooLong — 809 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted), 27 methods, 2 blocks, lines 1786-3055. The bar is 400 significant lines; this is 409 over it, 2.02× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
  • ClassTooLong: NativeRuntime crates/ibcmd-mssql-live/src/mssql_managed_worker/native.rs:309 — ClassTooLong — 727 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted), 18 methods, 3 blocks, lines 309-1347. The bar is 400 significant lines; this is 327 over it, 1.82× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
  • ClassTooLong: MetadataSourceContext crates/ibcmd-metadata-blob/src/lib.rs:356 — ClassTooLong — 600 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted), 29 methods, 6 blocks, lines 356-7732. The bar is 400 significant lines; this is 200 over it, 1.50× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
  • ClassTooLong: Writer REDACTED:829 — ClassTooLong — 532 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted), 7 methods, 2 blocks, lines 829-1523. The bar is 400 significant lines; this is 132 over it, 1.33× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
  • ClassTooLong: Obj crates/ibcmd-metadata-model/src/metadata_model/objects_parts.rs:126 — ClassTooLong — 528 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted), 39 methods, 2 blocks, lines 126-848. The bar is 400 significant lines; this is 128 over it, 1.32× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
  • ClassTooLong: Flowchart crates/ibcmd-metadata-model/src/metadata_model/bodies_flowchart.rs:134 — ClassTooLong — 490 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted), 16 methods, 2 blocks, lines 134-810. The bar is 400 significant lines; this is 90 over it, 1.23× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
  • ClassTooLong: StoredConfiguration src/stored_objects.rs:932 — ClassTooLong — 485 significant lines (blank, comment-only and punctuation-only lines excluded, and inline test code — #[cfg(test)] modules and bare #[test] functions — not counted), 25 methods, 2 blocks, lines 932-1605. The bar is 400 significant lines; this is 85 over it, 1.21× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
D4 · Code Duplication · Edited copy of a member (17 corresponding lines) · ×8
  • Edited copy of a member (17 corresponding lines) crates/ibcmd-1c-vocab/src/values.rs:8 — crates/ibcmd-1c-vocab/src/values.rs:8-24 | crates/ibcmd-schema/src/lib.rs:1199-1215 — These two members are one piece of code written twice and then edited apart: 17 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (17 corresponding lines) crates/ibcmd-dump/src/mssql_dump/selected.rs:385 — crates/ibcmd-dump/src/mssql_dump/selected.rs:385-403 | crates/ibcmd-dump/src/mssql_dump/selected.rs:409-425 — These two members are one piece of code written twice and then edited apart: 17 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (17 corresponding lines) crates/ibcmd-core/src/model.rs:723 — crates/ibcmd-core/src/model.rs:723-739 | crates/ibcmd-core/src/model.rs:1006-1029 — These two members are one piece of code written twice and then edited apart: 17 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (17 corresponding lines) crates/ibcmd-form-writer/src/lib.rs:22420 — crates/ibcmd-form-writer/src/lib.rs:22420-22436 | crates/ibcmd-form-writer/src/lib.rs:22607-22623 — These two members are one piece of code written twice and then edited apart: 17 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (17 corresponding lines) src/mssql/empty_stage.rs:1089 — src/mssql/empty_stage.rs:1089-1105 | src/mssql/override_stage.rs:431-447 — These two members are one piece of code written twice and then edited apart: 17 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (17 corresponding lines) crates/ibcmd-form-body/src/form_body.rs:2846 — crates/ibcmd-form-body/src/form_body.rs:2846-2862 | crates/ibcmd-form-body/src/form_body.rs:2906-2923 — These two members are one piece of code written twice and then edited apart: 17 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (17 corresponding lines) crates/ibcmd-xml/src/metadata/business_objects.rs:915 — crates/ibcmd-xml/src/metadata/business_objects.rs:915-936 | crates/ibcmd-xml/src/metadata/common_objects.rs:196-212 — These two members are one piece of code written twice and then edited apart: 17 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (17 corresponding lines) REDACTED:7900 — REDACTED:7900-7917 | REDACTED:7919-7935 — These two members are one piece of code written twice and then edited apart: 17 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copy of a member (5 corresponding lines) · ×8
  • Edited copy of a member (5 corresponding lines) crates/ibcmd-dump/src/mssql_dump/mod.rs:8183 — crates/ibcmd-dump/src/mssql_dump/mod.rs:8183-8188 | crates/ibcmd-form-body/src/form_root_42.rs:141-145 — These two members are one piece of code written twice and then edited apart: 5 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (5 corresponding lines) crates/ibcmd-metadata-model/src/metadata_model/audit.rs:302 — crates/ibcmd-metadata-model/src/metadata_model/audit.rs:302-306 | src/mssql/empty_stage.rs:1082-1086 — These two members are one piece of code written twice and then edited apart: 5 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (5 corresponding lines) crates/ibcmd-core/src/asset.rs:442 — crates/ibcmd-core/src/asset.rs:442-451 | crates/ibcmd-core/src/storage.rs:830-834 — These two members are one piece of code written twice and then edited apart: 5 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (5 corresponding lines) crates/ibcmd-form-body/src/form_body.rs:26519 — crates/ibcmd-form-body/src/form_body.rs:26519-26523 | crates/ibcmd-schema/src/lib.rs:2272-2276 — These two members are one piece of code written twice and then edited apart: 5 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (5 corresponding lines) crates/ibcmd-compiler/src/file_identity.rs:4 — crates/ibcmd-compiler/src/file_identity.rs:4-8 | src/source_oracle.rs:602-612 — These two members are one piece of code written twice and then edited apart: 5 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (5 corresponding lines) crates/ibcmd-module-blob/src/raw.rs:64 — crates/ibcmd-module-blob/src/raw.rs:64-68 | crates/ibcmd-restructure/src/names.rs:190-194 — These two members are one piece of code written twice and then edited apart: 5 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (5 corresponding lines) crates/ibcmd-dump/src/mssql_dump/source_assets.rs:873 — crates/ibcmd-dump/src/mssql_dump/source_assets.rs:873-879 | crates/ibcmd-module-blob/src/raw.rs:70-74 — These two members are one piece of code written twice and then edited apart: 5 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (5 corresponding lines) scripts/restructure-lab/form_bindings.py:17 — scripts/restructure-lab/form_bindings.py:17-21 | scripts/restructure-lab/s1k/cases.py:150-158 — These two members are one piece of code written twice and then edited apart: 5 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Duplicated block (13 lines × 3) · ×8
  • Duplicated block (13 lines × 3) crates/ibcmd-compiler/src/compiler/external_owned.rs:400 — crates/ibcmd-compiler/src/compiler/external_owned.rs:400-412 | crates/ibcmd-xml/src/metadata/constant.rs:260-272 | crates/ibcmd-xml/src/metadata/language.rs:308-320 — before extracting anything, compare `crates/ibcmd-xml/src/metadata/constant.rs` and `crates/ibcmd-xml/src/metadata/language.rs` as WHOLE FILES: this scan already matched 19 separate duplicated blocks between them, totalling at least 213 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. 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 `return` inside it is the body's own exit and keeps its meaning in the moved unit.
  • Duplicated block (13 lines × 3) crates/ibcmd-dump/src/mssql_dump/mod.rs:38168 — crates/ibcmd-dump/src/mssql_dump/mod.rs:38168-38180 | crates/ibcmd-dump/src/mssql_dump/mod.rs:42663-42675 | crates/ibcmd-dump/src/mssql_dump/mod.rs:42764-42776 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited.
  • Duplicated block (13 lines × 3) crates/ibcmd-form-body/src/form_body.rs:34268 — crates/ibcmd-form-body/src/form_body.rs:34268-34280 | crates/ibcmd-form-body/src/form_body.rs:35016-35028 | crates/ibcmd-form-body/src/form_body.rs:36047-36059 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-form-body/src/form_body.rs:34268` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (13 lines × 3) crates/ibcmd-xml/src/metadata/constant.rs:391 — crates/ibcmd-xml/src/metadata/constant.rs:391-403 | crates/ibcmd-xml/src/metadata/language.rs:281-293 | crates/ibcmd-xml/src/metadata/services.rs:2461-2473 — before extracting anything, compare `crates/ibcmd-xml/src/metadata/constant.rs` and `crates/ibcmd-xml/src/metadata/language.rs` as WHOLE FILES: this scan already matched 19 separate duplicated blocks between them, totalling at least 213 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. 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 `return` inside it is the body's own exit and keeps its meaning in the moved unit.
  • Duplicated block (13 lines × 3) crates/ibcmd-xml/src/metadata/functional_option.rs:296 — crates/ibcmd-xml/src/metadata/functional_option.rs:296-308 | crates/ibcmd-xml/src/metadata/functional_options_parameter.rs:278-290 | crates/ibcmd-xml/src/metadata/session_parameter.rs:662-674 — before extracting anything, compare `crates/ibcmd-xml/src/metadata/functional_option.rs` and `crates/ibcmd-xml/src/metadata/functional_options_parameter.rs` as WHOLE FILES: this scan already matched 17 separate duplicated blocks between them, totalling at least 156 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. 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 `return` inside it is the body's own exit and keeps its meaning in the moved unit.
  • Duplicated block (13 lines × 3) crates/ibcmd-1c-vocab/src/type_xml.rs:71 — crates/ibcmd-1c-vocab/src/type_xml.rs:71-83 | crates/ibcmd-1c-vocab/src/type_xml.rs:148-160 | crates/ibcmd-dump/src/mssql_dump/mod.rs:44649-44661 — before extracting anything, compare `crates/ibcmd-1c-vocab/src/type_xml.rs` and `crates/ibcmd-dump/src/mssql_dump/mod.rs` as WHOLE FILES: this scan already matched 6 separate duplicated blocks between them, totalling at least 118 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. The two sit in different directories, so one cannot simply be deleted in favour of the other while both are reached separately: hoist the shared part into a location both already depend on and have each file call it, and retire whichever file turns out to have no caller of its own left. Extracting one helper per block leaves the fork in place.
  • Duplicated block (13 lines × 3) REDACTED:1286 — REDACTED:1286-1298 | REDACTED:1401-1413 | REDACTED:1436-1448 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `REDACTED:1286` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (13 lines × 3) crates/ibcmd-xml/src/dcs.rs:2994 — crates/ibcmd-xml/src/dcs.rs:2994-3006 | crates/ibcmd-xml/src/dcs.rs:3021-3033 | crates/ibcmd-xml/src/dcs.rs:3064-3076 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-xml/src/dcs.rs:2994` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The `return` at the foot of the matched lines is the enclosing body's own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that `return` occupied — no decision has to be handed back and re-acted on.
D4 · Code Duplication · Duplicated block (12 lines × 3) · ×8
  • Duplicated block (12 lines × 3) crates/ibcmd-compiler-families/src/compiler/families/business_object/register_native.rs:962 — crates/ibcmd-compiler-families/src/compiler/families/business_object/register_native.rs:962-973 | crates/ibcmd-compiler-families/src/compiler/families/business_object/register_native.rs:1114-1125 | crates/ibcmd-compiler-families/src/compiler/families/business_object/register_native.rs:1261-1272 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/business_object/register_native.rs:962` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, `crates/ibcmd-compiler-families/src/compiler/families/business_object/register_native.rs:974` calls `enum_code` and `crates/ibcmd-compiler-families/src/compiler/families/business_object/register_native.rs:1126` does not — after which the two agree again for 4 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
  • Duplicated block (12 lines × 3) REDACTED:1220 — REDACTED:1220-1231 | REDACTED:1319-1330 | REDACTED:1369-1380 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `REDACTED:1220` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (12 lines × 3) crates/ibcmd-dump/src/mssql_dump/mod.rs:9415 — crates/ibcmd-dump/src/mssql_dump/mod.rs:9415-9426 | crates/ibcmd-dump/src/mssql_dump/mod.rs:40892-40903 | crates/ibcmd-dump/src/mssql_dump/mod.rs:41175-41186 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited.
  • Duplicated block (12 lines × 3) crates/ibcmd-form-writer/src/lib.rs:21866 — crates/ibcmd-form-writer/src/lib.rs:21866-21877 | crates/ibcmd-form-writer/src/lib.rs:22230-22241 | crates/ibcmd-form-writer/src/lib.rs:22256-22267 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-form-writer/src/lib.rs:21866` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (12 lines × 3) src/mssql_extension_export.rs:57 — src/mssql_extension_export.rs:57-68 | src/mssql_extension_load.rs:115-126 | src/mssql_extension_load.rs:177-188 — before extracting anything, compare `src/mssql_extension_export.rs` and `src/mssql_extension_load.rs` as WHOLE FILES: this scan already matched 4 separate duplicated blocks between them, totalling at least 42 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `src/mssql_extension_export.rs:57` it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows — the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members' bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run — a one-line delegation has no helper inside it to lift — so generate the run from the set it enumerates, or accept it and keep each member's own documentation with it. Note first that the copies are not typed on the same thing: the declarations holding them bind `args` to `&MssqlDumpExtensionArgs` in one and `&MssqlLoadExtensionArgs` in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH — their common supertype where they have one, or a new abstraction over them where they do not — and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract.
  • Duplicated block (12 lines × 3) crates/ibcmd-config-apply/src/mssql_config_apply/mod.rs:2015 — crates/ibcmd-config-apply/src/mssql_config_apply/mod.rs:2015-2026 | REDACTED:1577-1588 | REDACTED:10466-10477 — there are 3 copies across 2 file(s) — more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 3 sites; resolving a subset leaves the remainder to drift apart.
  • Duplicated block (12 lines × 3) crates/ibcmd-dump/src/mssql_dump/mod.rs:38691 — crates/ibcmd-dump/src/mssql_dump/mod.rs:38691-38711 | crates/ibcmd-dump/src/mssql_dump/mod.rs:38850-38868 | crates/ibcmd-dump/src/mssql_dump/mod.rs:39051-39062 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:38691` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (12 lines × 3) crates/ibcmd-moxel/src/lib.rs:5668 — crates/ibcmd-moxel/src/lib.rs:5668-5679 | crates/ibcmd-moxel/src/lib.rs:5753-5764 | crates/ibcmd-moxel/src/lib.rs:5801-5812 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-moxel/src/lib.rs:5668` it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows — the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members' bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run — a one-line delegation has no helper inside it to lift — so generate the run from the set it enumerates, or accept it and keep each member's own documentation with it. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, `crates/ibcmd-moxel/src/lib.rs:5681` calls `get`, `is_some_and` and `crates/ibcmd-moxel/src/lib.rs:5814` does not — after which the two agree again for 3 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
D4 · Code Duplication · Duplicated block (6–7 lines × 2) · ×8
  • Duplicated block (6–7 lines × 2) crates/ibcmd-compiler-families/src/compiler/families/simple.rs:1265 — crates/ibcmd-compiler-families/src/compiler/families/simple.rs:1265-1270 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:1538-1544 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
  • Duplicated block (6–7 lines × 2) crates/ibcmd-compiler-families/src/compiler/families/simple.rs:1769 — crates/ibcmd-compiler-families/src/compiler/families/simple.rs:1769-1775 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:1857-1862 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/simple.rs:1769` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (6–7 lines × 2) crates/ibcmd-compiler-families/src/compiler/families/utility.rs:714 — crates/ibcmd-compiler-families/src/compiler/families/utility.rs:714-720 | crates/ibcmd-compiler-families/src/compiler/families/utility.rs:762-767 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/utility.rs:714` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (6–7 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:15624 — crates/ibcmd-dump/src/mssql_dump/mod.rs:15624-15629 | crates/ibcmd-dump/src/mssql_dump/mod.rs:15708-15714 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:15624` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
  • Duplicated block (6–7 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:23208 — crates/ibcmd-dump/src/mssql_dump/mod.rs:23208-23214 | crates/ibcmd-dump/src/mssql_dump/mod.rs:23574-23579 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
  • Duplicated block (6–7 lines × 2) crates/ibcmd-dump/src/mssql_dump/refs.rs:4453 — crates/ibcmd-dump/src/mssql_dump/refs.rs:4453-4458 | crates/ibcmd-dump/src/mssql_dump/source_assets.rs:4293-4299 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/refs.rs:4453` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (6–7 lines × 2) src/infobase_oracle.rs:957 — src/infobase_oracle.rs:957-962 | src/mssql_apply.rs:1286-1292 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
  • Duplicated block (6–7 lines × 2) crates/ibcmd-metadata-blob/src/lib.rs:6113 — crates/ibcmd-metadata-blob/src/lib.rs:6113-6119 | crates/ibcmd-metadata-blob/src/lib.rs:6134-6139 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-metadata-blob/src/lib.rs:6134` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D1 · Cyclomatic Complexity · BodyWriter · ×7
  • BodyWriter::format_record (cyclomatic 103) crates/ibcmd-compiler/src/compiler/bodies/mxl_native.rs:1895 — BodyWriter::format_record has cyclomatic complexity 103 (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 — the same kind of value, with no behaviour of its own — 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.
  • BodyWriter::print_properties (cyclomatic 32) crates/ibcmd-compiler/src/compiler/bodies/mxl_native.rs:1757 — BodyWriter::print_properties has cyclomatic complexity 32 (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 — the same kind of value, with no behaviour of its own — 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. This is NOT this file's highest cyclomatic complexity: ibcmd_compiler::compiler::bodies::mxl_native::web_color_code (cyclomatic 59) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • BodyWriter::value_type_entry (cyclomatic 27) crates/ibcmd-compiler/src/compiler/bodies/mxl_native.rs:2154 — BodyWriter::value_type_entry 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 — the same kind of value, with no behaviour of its own — 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. This is NOT this file's highest cyclomatic complexity: ibcmd_compiler::compiler::bodies::mxl_native::web_color_code (cyclomatic 59) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • BodyWriter::font_record (cyclomatic 26) crates/ibcmd-compiler/src/compiler/bodies/mxl_native.rs:2422 — BodyWriter::font_record has cyclomatic complexity 26 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top. This is NOT this file's highest cyclomatic complexity: ibcmd_compiler::compiler::bodies::mxl_native::web_color_code (cyclomatic 59) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • BodyWriter::drawing (cyclomatic 25) crates/ibcmd-compiler/src/compiler/bodies/mxl_native.rs:1336 — BodyWriter::drawing has cyclomatic complexity 25 (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 — the same kind of value, with no behaviour of its own — 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. This is NOT this file's highest cyclomatic complexity: ibcmd_compiler::compiler::bodies::mxl_native::web_color_code (cyclomatic 59) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • BodyWriter::cell (cyclomatic 18) crates/ibcmd-compiler/src/compiler/bodies/mxl_native.rs:1062 — BodyWriter::cell has cyclomatic complexity 18 (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 — the same kind of value, with no behaviour of its own — 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. This is NOT this file's highest cyclomatic complexity: ibcmd_compiler::compiler::bodies::mxl_native::web_color_code (cyclomatic 59) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • BodyWriter::mark_drawing_formats (cyclomatic 16) crates/ibcmd-compiler/src/compiler/bodies/mxl_native.rs:890 — BodyWriter::mark_drawing_formats 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. This is NOT this file's highest cyclomatic complexity: ibcmd_compiler::compiler::bodies::mxl_native::web_color_code (cyclomatic 59) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
D1 · Cyclomatic Complexity · ibcmd_compiler · ×7
  • ibcmd_compiler::compiler::bootstrap::project_configuration (cyclomatic 46) crates/ibcmd-compiler/src/compiler/bootstrap.rs:1340 — ibcmd_compiler::compiler::bootstrap::project_configuration has cyclomatic complexity 46 (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 — the same kind of value, with no behaviour of its own — 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.
  • ibcmd_compiler::compiler::bootstrap::compile_source_tree_mode (cyclomatic 25) crates/ibcmd-compiler/src/compiler/bootstrap.rs:406 — ibcmd_compiler::compiler::bootstrap::compile_source_tree_mode 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. This is NOT this file's highest cyclomatic complexity: BootstrapCompileError::fmt (cyclomatic 30) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • ibcmd_compiler::compiler::bodies::mxl_native::typed_value (cyclomatic 19) crates/ibcmd-compiler/src/compiler/bodies/mxl_native.rs:2916 — ibcmd_compiler::compiler::bodies::mxl_native::typed_value 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. This is NOT this file's highest cyclomatic complexity: ibcmd_compiler::compiler::bodies::mxl_native::web_color_code (cyclomatic 59) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • ibcmd_compiler::compiler::bootstrap::compile_metadata (cyclomatic 19) crates/ibcmd-compiler/src/compiler/bootstrap.rs:923 — ibcmd_compiler::compiler::bootstrap::compile_metadata 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 — the same kind of value, with no behaviour of its own — 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. This is NOT this file's highest cyclomatic complexity: BootstrapCompileError::fmt (cyclomatic 30) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
  • ibcmd_compiler::compiler::compile_source_with_payload_limit (cyclomatic 17) crates/ibcmd-compiler/src/compiler/mod.rs:273 — ibcmd_compiler::compiler::compile_source_with_payload_limit 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 — the same kind of value, with no behaviour of its own — 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.
  • ibcmd_compiler::compiler::bodies::mxl::decode_plain (cyclomatic 17) crates/ibcmd-compiler/src/compiler/bodies/mxl.rs:124 — ibcmd_compiler::compiler::bodies::mxl::decode_plain 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.
  • ibcmd_compiler::compiler::bodies::predefined::validate_items (cyclomatic 16) crates/ibcmd-compiler/src/compiler/bodies/predefined.rs:350 — ibcmd_compiler::compiler::bodies::predefined::validate_items has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D4 · Code Duplication · Edited copy of a member (26 corresponding lines) · ×7
  • Edited copy of a member (26 corresponding lines) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:4323 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:4323-4348 | crates/ibcmd-compiler-families/src/compiler/families/utility.rs:2422-2447 — These two members are one piece of code written twice and then edited apart: 26 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (26 corresponding lines) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:4421 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:4421-4446 | crates/ibcmd-compiler-families/src/compiler/families/utility.rs:2526-2554 — These two members are one piece of code written twice and then edited apart: 26 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (26 corresponding lines) crates/ibcmd-compiler-families/src/compiler/families/services.rs:4120 — crates/ibcmd-compiler-families/src/compiler/families/services.rs:4120-4145 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:3016-3041 — These two members are one piece of code written twice and then edited apart: 26 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (26 corresponding lines) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:4350 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:4350-4378 | crates/ibcmd-compiler-families/src/compiler/families/utility.rs:2499-2524 — These two members are one piece of code written twice and then edited apart: 26 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (26 corresponding lines) crates/ibcmd-dump/src/mssql_dump/extension/form.rs:281 — crates/ibcmd-dump/src/mssql_dump/extension/form.rs:281-306 | crates/ibcmd-dump/src/mssql_dump/extension/form.rs:378-406 — These two members are one piece of code written twice and then edited apart: 26 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (26 corresponding lines) crates/ibcmd-dump/src/mssql_dump/mod.rs:15064 — crates/ibcmd-dump/src/mssql_dump/mod.rs:15064-15092 | crates/ibcmd-dump/src/mssql_dump/mod.rs:27106-27131 — These two members are one piece of code written twice and then edited apart: 26 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (26 corresponding lines) crates/ibcmd-compiler-families/src/compiler/families/form.rs:205 — crates/ibcmd-compiler-families/src/compiler/families/form.rs:205-230 | crates/ibcmd-compiler-families/src/compiler/families/modules.rs:131-156 — These two members are one piece of code written twice and then edited apart: 26 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copy of a member (23 corresponding lines) · ×7
  • Edited copy of a member (23 corresponding lines) crates/ibcmd-form-writer/src/lib.rs:20852 — crates/ibcmd-form-writer/src/lib.rs:20852-20874 | crates/ibcmd-form-writer/src/lib.rs:20902-20926 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (23 corresponding lines) REDACTED:3673 — REDACTED:3673-3696 | REDACTED:3700-3722 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (23 corresponding lines) crates/ibcmd-dump/src/mssql_dump/mod.rs:34130 — crates/ibcmd-dump/src/mssql_dump/mod.rs:34130-34152 | crates/ibcmd-dump/src/mssql_dump/mod.rs:34162-34196 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (23 corresponding lines) crates/ibcmd-xml/src/metadata/business_objects.rs:1014 — crates/ibcmd-xml/src/metadata/business_objects.rs:1014-1039 | crates/ibcmd-xml/src/metadata/business_objects.rs:1046-1068 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (23 corresponding lines) crates/ibcmd-core/src/opaque.rs:710 — crates/ibcmd-core/src/opaque.rs:710-732 | crates/ibcmd-core/src/storage.rs:1118-1141 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (23 corresponding lines) crates/ibcmd-cf/src/writer.rs:219 — crates/ibcmd-cf/src/writer.rs:219-241 | crates/ibcmd-cf/src/writer.rs:247-270 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (23 corresponding lines) crates/ibcmd-moxel/src/lib.rs:14549 — crates/ibcmd-moxel/src/lib.rs:14549-14571 | crates/ibcmd-moxel/src/lib.rs:14603-14625 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Duplicated block (13–14 lines × 2) · ×7
  • Duplicated block (13–14 lines × 2) crates/ibcmd-compiler-families/src/compiler/families/services.rs:2241 — crates/ibcmd-compiler-families/src/compiler/families/services.rs:2241-2254 | crates/ibcmd-compiler-families/src/compiler/families/services.rs:2374-2386 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/services.rs:2241` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
  • Duplicated block (13–14 lines × 2) crates/ibcmd-compiler-families/src/compiler/families/simple.rs:2243 — crates/ibcmd-compiler-families/src/compiler/families/simple.rs:2243-2255 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:2296-2309 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/simple.rs:2243` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (13–14 lines × 2) crates/ibcmd-dump/src/mssql_dump/source_assets.rs:89 — crates/ibcmd-dump/src/mssql_dump/source_assets.rs:89-101 | crates/ibcmd-dump/src/mssql_dump/source_assets.rs:118-131 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/source_assets.rs:89` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (13–14 lines × 2) crates/ibcmd-form-writer/src/lib.rs:21496 — crates/ibcmd-form-writer/src/lib.rs:21496-21509 | crates/ibcmd-form-writer/src/lib.rs:22048-22060 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-form-writer/src/lib.rs:21496` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (13–14 lines × 2) crates/ibcmd-xml/src/dcs_schema.rs:235 — crates/ibcmd-xml/src/dcs_schema.rs:235-248 | crates/ibcmd-xml/src/dcs_schema.rs:368-380 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (13–14 lines × 2) src/dropin/mod.rs:454 — src/dropin/mod.rs:454-466 | src/dropin/mod.rs:778-791 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
  • Duplicated block (13–14 lines × 2) crates/ibcmd-compiler-families/src/compiler/families/services.rs:1930 — crates/ibcmd-compiler-families/src/compiler/families/services.rs:1930-1942 | crates/ibcmd-compiler-families/src/compiler/families/services.rs:2073-2086 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/services.rs:1930` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, `crates/ibcmd-compiler-families/src/compiler/families/services.rs:2072` calls `project_web_packages`, `property` and `crates/ibcmd-compiler-families/src/compiler/families/services.rs:1929` does not — after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
D4 · Code Duplication · Duplicated block (7 lines × 4) · ×7
  • Duplicated block (7 lines × 4) crates/ibcmd-compiler-families/src/compiler/families/services.rs:1655 — crates/ibcmd-compiler-families/src/compiler/families/services.rs:1655-1661 | crates/ibcmd-compiler-families/src/compiler/families/services.rs:2241-2247 | crates/ibcmd-compiler-families/src/compiler/families/services.rs:2374-2380 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:1915-1922 — before extracting anything, compare `crates/ibcmd-compiler-families/src/compiler/families/services.rs` and `crates/ibcmd-compiler-families/src/compiler/families/simple.rs` as WHOLE FILES: this scan already matched 36 separate duplicated blocks between them, totalling at least 406 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/services.rs:1655` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
  • Duplicated block (7 lines × 4) crates/ibcmd-compiler-families/src/compiler/families/services.rs:2684 — crates/ibcmd-compiler-families/src/compiler/families/services.rs:2684-2690 | crates/ibcmd-compiler-families/src/compiler/families/services.rs:2788-2794 | crates/ibcmd-compiler-families/src/compiler/families/services.rs:2855-2861 | crates/ibcmd-compiler-families/src/compiler/families/services.rs:2950-2956 — all 4 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/services.rs:2684` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (7 lines × 4) crates/ibcmd-form-writer/src/lib.rs:15628 — crates/ibcmd-form-writer/src/lib.rs:15628-15634 | crates/ibcmd-form-writer/src/lib.rs:15887-15893 | crates/ibcmd-form-writer/src/lib.rs:15901-15907 | crates/ibcmd-form-writer/src/lib.rs:15940-15946 — all 4 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (7 lines × 4) src/infobase.rs:215 — src/infobase.rs:215-221 | src/infobase.rs:240-246 | src/infobase.rs:276-282 | src/infobase.rs:672-678 — all 4 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited.
  • Duplicated block (7 lines × 4) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:2741 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:2741-2747 | crates/ibcmd-compiler-families/src/compiler/families/utility.rs:1401-1407 | crates/ibcmd-xml/src/metadata/constant.rs:720-726 | crates/ibcmd-xml/src/metadata/language.rs:443-449 — before extracting anything, compare `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs` and `crates/ibcmd-compiler-families/src/compiler/families/utility.rs` as WHOLE FILES: this scan already matched 65 separate duplicated blocks between them, totalling at least 934 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place.
  • Duplicated block (7 lines × 4) crates/ibcmd-dump/src/mssql_dump/mod.rs:32371 — crates/ibcmd-dump/src/mssql_dump/mod.rs:32371-32377 | crates/ibcmd-dump/src/mssql_dump/mod.rs:32647-32654 | crates/ibcmd-dump/src/mssql_dump/mod.rs:33010-33016 | crates/ibcmd-dump/src/mssql_dump/mod.rs:34694-34701 — all 4 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:32371` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (7 lines × 4) crates/ibcmd-xml/src/metadata/business_objects.rs:391 — crates/ibcmd-xml/src/metadata/business_objects.rs:391-397 | crates/ibcmd-xml/src/metadata/hierarchical_objects.rs:363-369 | crates/ibcmd-xml/src/metadata/register_objects.rs:450-456 | crates/ibcmd-xml/src/metadata/utility_objects.rs:297-303 — before extracting anything, compare `crates/ibcmd-xml/src/metadata/business_objects.rs` and `crates/ibcmd-xml/src/metadata/hierarchical_objects.rs` as WHOLE FILES: this scan already matched 7 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. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-xml/src/metadata/business_objects.rs:391` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (5 lines × 5) · ×7
  • Duplicated block (5 lines × 5) crates/ibcmd-compiler/src/compiler/bootstrap.rs:1823 — crates/ibcmd-compiler/src/compiler/bootstrap.rs:1823-1827 | crates/ibcmd-xml/src/metadata/characteristics.rs:416-420 | crates/ibcmd-xml/src/metadata/configuration_mobile.rs:15-19 | crates/ibcmd-xml/src/metadata/configuration_v85_projection.rs:16-20 | crates/ibcmd-xml/src/metadata/external_data_source.rs:34-38 — before extracting anything, compare `crates/ibcmd-xml/src/metadata/configuration_mobile.rs` and `crates/ibcmd-xml/src/metadata/configuration_v85_projection.rs` as WHOLE FILES: this scan already matched 5 separate duplicated blocks between them, totalling at least 31 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler/src/compiler/bootstrap.rs:1823` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, `crates/ibcmd-xml/src/metadata/configuration_v85_projection.rs:21` calls `Comment` and `crates/ibcmd-xml/src/metadata/external_data_source.rs:39` does not — after which the two agree again for 4 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
  • Duplicated block (5 lines × 5) crates/ibcmd-dump/src/mssql_dump/mod.rs:18994 — crates/ibcmd-dump/src/mssql_dump/mod.rs:18994-18998 | crates/ibcmd-dump/src/mssql_dump/mod.rs:27225-27229 | crates/ibcmd-dump/src/mssql_dump/mod.rs:28998-29002 | crates/ibcmd-dump/src/mssql_dump/mod.rs:30576-30580 | crates/ibcmd-dump/src/mssql_dump/mod.rs:31274-31278 — all 5 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited.
  • Duplicated block (5 lines × 5) crates/ibcmd-dump/src/mssql_dump/mod.rs:38190 — crates/ibcmd-dump/src/mssql_dump/mod.rs:38190-38194 | crates/ibcmd-dump/src/mssql_dump/mod.rs:39876-39880 | crates/ibcmd-dump/src/mssql_dump/mod.rs:40061-40065 | crates/ibcmd-dump/src/mssql_dump/mod.rs:40501-40505 | crates/ibcmd-dump/src/mssql_dump/mod.rs:40583-40587 — all 5 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:38190` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, `crates/ibcmd-dump/src/mssql_dump/mod.rs:40059` calls `acknowledge_internal_only` and `crates/ibcmd-dump/src/mssql_dump/mod.rs:39874` does not — after which the two agree again for 3 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
  • Duplicated block (5 lines × 5) crates/ibcmd-form-writer/src/lib.rs:15630 — crates/ibcmd-form-writer/src/lib.rs:15630-15634 | crates/ibcmd-form-writer/src/lib.rs:15875-15879 | crates/ibcmd-form-writer/src/lib.rs:15889-15893 | crates/ibcmd-form-writer/src/lib.rs:15903-15907 | crates/ibcmd-form-writer/src/lib.rs:15942-15946 — all 5 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-form-writer/src/lib.rs:15630` it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows — the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members' bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run — a one-line delegation has no helper inside it to lift — so generate the run from the set it enumerates, or accept it and keep each member's own documentation with it. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (5 lines × 5) crates/ibcmd-metadata-blob/src/lib.rs:2329 — crates/ibcmd-metadata-blob/src/lib.rs:2329-2333 | crates/ibcmd-metadata-blob/src/lib.rs:3222-3226 | crates/ibcmd-metadata-blob/src/lib.rs:3300-3304 | crates/ibcmd-metadata-blob/src/lib.rs:6098-6103 | crates/ibcmd-metadata-blob/src/lib.rs:6284-6289 — all 5 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited.
  • Duplicated block (5 lines × 5) crates/ibcmd-xml/src/dcs.rs:2408 — crates/ibcmd-xml/src/dcs.rs:2408-2412 | crates/ibcmd-xml/src/dcs.rs:2795-2799 | crates/ibcmd-xml/src/dcs.rs:3416-3420 | crates/ibcmd-xml/src/dcs.rs:3596-3600 | crates/ibcmd-xml/src/dcs.rs:3672-3676 — all 5 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-xml/src/dcs.rs:2408` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (5 lines × 5) crates/ibcmd-xml/src/metadata/services.rs:469 — crates/ibcmd-xml/src/metadata/services.rs:469-473 | crates/ibcmd-xml/src/metadata/services.rs:501-519 | crates/ibcmd-xml/src/metadata/services.rs:546-559 | crates/ibcmd-xml/src/metadata/services.rs:586-601 | crates/ibcmd-xml/src/metadata/services.rs:737-741 — all 5 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-xml/src/metadata/services.rs:469` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D1 · Cyclomatic Complexity · ibcmd_apply_check · ×6
  • ibcmd_apply_check::apply_check::plan::build (cyclomatic 46) crates/ibcmd-apply-check/src/apply_check/plan.rs:100 — ibcmd_apply_check::apply_check::plan::build has cyclomatic complexity 46 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
  • ibcmd_apply_check::apply_check::check::check_planned (cyclomatic 43) crates/ibcmd-apply-check/src/apply_check/check.rs:311 — ibcmd_apply_check::apply_check::check::check_planned has cyclomatic complexity 43 (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 — the same kind of value, with no behaviour of its own — 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.
  • ibcmd_apply_check::apply_check::trees::check_trees (cyclomatic 30) crates/ibcmd-apply-check/src/apply_check/trees.rs:164 — ibcmd_apply_check::apply_check::trees::check_trees has cyclomatic complexity 30 (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 — the same kind of value, with no behaviour of its own — 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.
  • ibcmd_apply_check::apply_check::s1::one (cyclomatic 25) crates/ibcmd-apply-check/src/apply_check/s1.rs:428 — ibcmd_apply_check::apply_check::s1::one has cyclomatic complexity 25 (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 — the same kind of value, with no behaviour of its own — 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.
  • ibcmd_apply_check::apply_check::rules::decide_child (cyclomatic 22) crates/ibcmd-apply-check/src/apply_check/rules.rs:328 — ibcmd_apply_check::apply_check::rules::decide_child has cyclomatic complexity 22 (threshold 15). To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (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 — the same kind of value, with no behaviour of its own — 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.
  • ibcmd_apply_check::apply_check::tree_diff::diff_element (cyclomatic 19) crates/ibcmd-apply-check/src/apply_check/tree_diff.rs:201 — ibcmd_apply_check::apply_check::tree_diff::diff_element has cyclomatic complexity 19 (threshold 15). To reduce it, separate the branches: extract each independent case into its own named function so the top-level body reads as a short sequence of named decisions.
D2 · Cognitive Complexity · ibcmd_schema · ×6
  • ibcmd_schema::parse_raw_form_choice_parameter_links (cognitive 39) crates/ibcmd-schema/src/lib.rs:2137 — ibcmd_schema::parse_raw_form_choice_parameter_links has cognitive complexity 39 (threshold 15). Drivers by points: if/else 13 (26 pts), match/switch 3 (8 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.
  • ibcmd_schema::parse_form_choice_list_item_inner (cognitive 25) crates/ibcmd-schema/src/lib.rs:818 — ibcmd_schema::parse_form_choice_list_item_inner has cognitive complexity 25 (threshold 15). Drivers by points: if/else 8 (12 pts), boolean chains 8, match/switch 3 (5 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.
  • ibcmd_schema::braced_fields_bounded (cognitive 20) crates/ibcmd-schema/src/lib.rs:2599 — ibcmd_schema::braced_fields_bounded has cognitive complexity 20 (threshold 15). Drivers by points: if/else 8 (16 pts), match/switch 1 (2 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.
  • ibcmd_schema::recompute_migration_backlog (cognitive 18) crates/ibcmd-schema/src/lib.rs:11282 — ibcmd_schema::recompute_migration_backlog has cognitive complexity 18 (threshold 15). Drivers by points: if/else 3 (11 pts), loops 3 (6 pts), boolean chains 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_schema::scan_braced (cognitive 17) crates/ibcmd-schema/src/lib.rs:2645 — ibcmd_schema::scan_braced has cognitive complexity 17 (threshold 15). Drivers by points: if/else 6 (14 pts), match/switch 1 (2 pts), loops 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_schema::parse_form_choice_parameter_value (cognitive 16) crates/ibcmd-schema/src/lib.rs:2278 — ibcmd_schema::parse_form_choice_parameter_value has cognitive complexity 16 (threshold 15). Drivers by points: boolean chains 10, if/else 3, match/switch 2 (3 pts) (nesting depth added 1). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators.
D2 · Cognitive Complexity · ibcmd_mssql_live · ×6
  • ibcmd_mssql_live::mssql_main_activation::render_main_activation_sql_internal (cognitive 28) REDACTED:846 — ibcmd_mssql_live::mssql_main_activation::render_main_activation_sql_internal has cognitive complexity 28 (threshold 15). Drivers by points: if/else 17 (22 pts), boolean chains 4, match/switch 2 (nesting depth added 5). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level.
  • ibcmd_mssql_live::mssql_managed_worker::native::require_shutdown_census (cognitive 26) crates/ibcmd-mssql-live/src/mssql_managed_worker/native.rs:204 — ibcmd_mssql_live::mssql_managed_worker::native::require_shutdown_census has cognitive complexity 26 (threshold 15). Drivers by points: if/else 6 (11 pts), boolean chains 8, loops 4 (5 pts), match/switch 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.
  • ibcmd_mssql_live::mssql_managed_worker::native::authentication::verify (cognitive 26) crates/ibcmd-mssql-live/src/mssql_managed_worker/native/authentication.rs:207 — ibcmd_mssql_live::mssql_managed_worker::native::authentication::verify has cognitive complexity 26 (threshold 15). Drivers by points: if/else 7 (21 pts), loops 2 (3 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.
  • ibcmd_mssql_live::mssql_main_activation::prepare_main_activation_for (cognitive 21) REDACTED:536 — ibcmd_mssql_live::mssql_main_activation::prepare_main_activation_for has cognitive complexity 21 (threshold 15). Drivers by points: if/else 9 (11 pts), boolean chains 8, loops 2 (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition.
  • ibcmd_mssql_live::mssql_managed_worker::native::require_shutdown_graph (cognitive 19) crates/ibcmd-mssql-live/src/mssql_managed_worker/native.rs:1423 — ibcmd_mssql_live::mssql_managed_worker::native::require_shutdown_graph has cognitive complexity 19 (threshold 15). Drivers by points: if/else 5 (10 pts), boolean chains 7, loops 2 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_mssql_live::mssql_managed_worker::native::listener_authority (cognitive 19) crates/ibcmd-mssql-live/src/mssql_managed_worker/native.rs:1575 — ibcmd_mssql_live::mssql_managed_worker::native::listener_authority has cognitive complexity 19 (threshold 15). Drivers by points: if/else 5 (10 pts), boolean chains 5, loops 3 (4 pts) (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D35 · Change Coupling · Change coupling · ×6
  • Change coupling: config.ts ↔ rpc.ts editors/vscode/src/config.ts:1 — `editors/vscode/src/config.ts` and `editors/vscode/src/rpc.ts` change together 80% of the time (8 of the 10 commits that touched whichever of the two files changed less often, counting a file under its earlier names as well — 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 — a sibling reference still needs an import — 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 8 shared commits counted here, the most recent 3 are `ff36a8dd` fix(vscode): preserve sources and report current connection crashes; `01fccdd2` fix(vscode): preserve connection sources and lifecycle errors; `6a1606ba` fix(vscode): preserve connection sources and lifecycle errors — run `git show` on any of them.
  • Change coupling: infobase_oracle.rs ↔ mssql_apply.rs src/infobase_oracle.rs:1 — `src/infobase_oracle.rs` and `src/mssql_apply.rs` change together 64% of the time (9 of the 14 commits that touched whichever of the two files changed less often, counting a file under its earlier names as well — 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 — a sibling reference still needs an import — 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 9 shared commits counted here, the most recent 3 are `eed8c1af` fix(postgres): scope probe snapshots to export operations (#369); `8163b1c4` fix(postgres): scope probe snapshots to export operations (#369); `98221073` fix(postgres): scope probe snapshots to export operations (#369) — run `git show` on any of them.
  • Change coupling: parse.rs ↔ infobase_oracle.rs src/dropin/parse.rs:1 — `src/dropin/parse.rs` and `src/infobase_oracle.rs` change together 57% of the time (8 of the 14 commits that touched whichever of the two files changed less often, counting a file under its earlier names as well — 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 — 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 — the registration is the link, and it is meant not to be an import — 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 8 shared commits counted here, the most recent 3 are `4d2048a7` infobase config export --dbms=PostgreSQL: export from PostgreSQL with…; `c7062faa` feat: infobase config export|import --db-path for file infobases; `36f29c72` import files: stage the rows of listed files only (#363) — run `git show` on any of them.
  • Change coupling: form_extension.rs ↔ tests.rs crates/ibcmd-dump/src/mssql_dump/form_extension.rs:1 — `crates/ibcmd-dump/src/mssql_dump/form_extension.rs` and `crates/ibcmd-dump/src/mssql_dump/tests.rs` change together 55% of the time (6 of the 11 commits that touched whichever of the two files changed less often, counting a file under its earlier names as well — 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 — a sibling reference still needs an import — 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 6 shared commits counted here, the most recent 3 are `b53e8ac2` refactor(form-body): move the form reader into ibcmd-form-body (#559) (at that commit the files were still `src/mssql_dump/form_extension.rs` and `src/mssql_dump/tests.rs`); `4f977301` fix(forms): refuse trailing handler data and isolate cleanup test (#414) (at that commit the files were still `src/mssql_dump/form_extension.rs` and `src/mssql_dump/tests.rs`); `b309b63a` fix(forms): preserve adopted 8.5 events and failed-row cleanup (#414) (at that commit the files were still `src/mssql_dump/form_extension.rs` and `src/mssql_dump/tests.rs`) — run `git show` on any of them.
  • Change coupling: dcs.rs ↔ dcs_template.rs crates/ibcmd-dump/src/mssql_dump/dcs.rs:1 — `crates/ibcmd-dump/src/mssql_dump/dcs.rs` and `crates/ibcmd-xml/src/dcs_template.rs` change together 53% of the time (8 of the 15 commits that touched whichever of the two files changed less often, counting a file under its earlier names as well — 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 — 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 — the registration is the link, and it is meant not to be an import — 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 8 shared commits counted here, the most recent 3 are `0d1e3cdb` feat(dcs): rewrite terminal area templates and inline their appearances (at that commit the file was still `src/mssql_dump/dcs.rs`); `557a7a66` feat(dcs): admit header-declared settings counts and TypeSet resolutions (at that commit the file was still `src/mssql_dump/dcs.rs`); `fbdc499c` feat(dcs): fall back to transliteration when the settings cohort refuses (at that commit the file was still `src/mssql_dump/dcs.rs`) — run `git show` on any of them.
  • Change coupling: dcs.rs ↔ lib.rs crates/ibcmd-compiler/src/compiler/bodies/dcs.rs:1 — `crates/ibcmd-compiler/src/compiler/bodies/dcs.rs` and `crates/ibcmd-schema/src/lib.rs` change together 50% of the time (16 of the 32 commits that touched whichever of the two files changed less often, counting a file under its earlier names as well — 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 — 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 — the registration is the link, and it is meant not to be an import — 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 16 shared commits counted here, the most recent 3 are `557a7a66` feat(dcs): admit header-declared settings counts and TypeSet resolutions (at that commit the file was still `src/compiler/bodies/dcs.rs`); `179903f9` feat(dcs): admit the evidenced two-field query data set (at that commit the file was still `src/compiler/bodies/dcs.rs`); `e0661bcb` feat(dcs): support evidenced optional data set link fields (at that commit the file was still `src/compiler/bodies/dcs.rs`) — run `git show` on any of them.
D4 · Code Duplication · Members sharing a duplicated core (6 members, 50+ identical tokens) · ×6
  • Members sharing a duplicated core (6 members, 50+ identical tokens) crates/ibcmd-1c-text/src/fields.rs:239 — crates/ibcmd-1c-text/src/fields.rs:239-252 | crates/ibcmd-form-body/src/form_body.rs:39027-39040 | crates/ibcmd-form-body/src/form_body.rs:39720-39734 | crates/ibcmd-moxel/src/lib.rs:7312-7326 | crates/ibcmd-schema/src/lib.rs:1173-1186 | crates/ibcmd-schema/src/lib.rs:2406-2419 — 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 — 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' grain — factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 6 times.
  • Members sharing a duplicated core (6 members, 50+ identical tokens) crates/ibcmd-apply-check/src/apply_check/roles.rs:186 — crates/ibcmd-apply-check/src/apply_check/roles.rs:186-193 | crates/ibcmd-compiler/src/compiler/bodies/mxl_native.rs:475-482 | crates/ibcmd-dump/src/mssql_dump/extension/mod.rs:278-285 | crates/ibcmd-form-body/src/layout_8_5_1.rs:309-316 | crates/ibcmd-form-writer/src/form/load_8_5_1.rs:1217-1224 | crates/ibcmd-restructure-engine/src/text.rs:25-32 — 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 — 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' grain — factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 6 times.
  • Members sharing a duplicated core (6 members, 50+ identical tokens) crates/ibcmd-cf/src/writer.rs:363 — crates/ibcmd-cf/src/writer.rs:363-380 | crates/ibcmd-v8/src/format15.rs:277-299 | crates/ibcmd-v8/src/format16.rs:360-382 | crates/ibcmd-v8/src/reader.rs:924-946 | crates/ibcmd-v8/src/writer.rs:284-310 | crates/ibcmd-v8/src/writer.rs:895-921 — 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 — 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' grain — factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 6 times.
  • Members sharing a duplicated core (6 members, 50+ identical tokens) crates/ibcmd-dump/src/mssql_dump/forms.rs:426 — crates/ibcmd-dump/src/mssql_dump/forms.rs:426-517 | crates/ibcmd-dump/src/mssql_dump/mod.rs:37270-37317 | crates/ibcmd-dump/src/mssql_dump/mod.rs:37340-37383 | crates/ibcmd-dump/src/mssql_dump/mod.rs:39232-39508 | crates/ibcmd-dump/src/mssql_dump/mod.rs:42377-42422 | crates/ibcmd-dump/src/mssql_dump/mod.rs:42428-42487 — 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 — 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' grain — factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 6 times.
  • Members sharing a duplicated core (6 members, 50+ identical tokens) crates/ibcmd-schema/src/lib.rs:7997 — crates/ibcmd-schema/src/lib.rs:7997-8078 | crates/ibcmd-schema/src/lib.rs:8948-9157 | crates/ibcmd-schema/src/lib.rs:9193-9423 | crates/ibcmd-schema/src/lib.rs:9464-9698 | crates/ibcmd-schema/src/lib.rs:9744-9933 | crates/ibcmd-schema/src/lib.rs:9976-10152 — 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 — 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' grain — factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 6 times.
  • Members sharing a duplicated core (6 members, 50+ identical tokens) REDACTED:3305 — REDACTED:3305-3348 | REDACTED:3352-3375 | REDACTED:3379-3466 | REDACTED:3470-3539 | REDACTED:3543-3578 | REDACTED:3582-3669 — 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 — 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' grain — factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 6 times.
D4 · Code Duplication · Edited copy of a member (35 corresponding lines) · ×6
  • Edited copy of a member (35 corresponding lines) crates/ibcmd-xml/src/metadata/constant.rs:671 — crates/ibcmd-xml/src/metadata/constant.rs:671-705 | crates/ibcmd-xml/src/metadata/language.rs:394-428 — These two members are one piece of code written twice and then edited apart: 35 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (35 corresponding lines) crates/ibcmd-compiler-families/src/compiler/families/services.rs:1651 — crates/ibcmd-compiler-families/src/compiler/families/services.rs:1651-1685 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:1911-1959 — These two members are one piece of code written twice and then edited apart: 35 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (35 corresponding lines) crates/ibcmd-compiler-families/src/compiler/families/services.rs:604 — crates/ibcmd-compiler-families/src/compiler/families/services.rs:604-638 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:776-812 — These two members are one piece of code written twice and then edited apart: 35 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (35 corresponding lines) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:2955 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:2955-2989 | crates/ibcmd-compiler-families/src/compiler/families/utility.rs:1534-1568 — These two members are one piece of code written twice and then edited apart: 35 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (35 corresponding lines) crates/ibcmd-moxel/src/lib.rs:12796 — crates/ibcmd-moxel/src/lib.rs:12796-12830 | crates/ibcmd-moxel/src/lib.rs:12931-12982 — These two members are one piece of code written twice and then edited apart: 35 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (35 corresponding lines) REDACTED:6466 — REDACTED:6466-6502 | REDACTED:6673-6707 — These two members are one piece of code written twice and then edited apart: 35 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copy of a member (29 corresponding lines) · ×6
  • Edited copy of a member (29 corresponding lines) crates/ibcmd-moxel/src/lib.rs:7080 — crates/ibcmd-moxel/src/lib.rs:7080-7114 | crates/ibcmd-moxel/src/lib.rs:7118-7146 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (29 corresponding lines) crates/ibcmd-form-body/src/dcs.rs:1571 — crates/ibcmd-form-body/src/dcs.rs:1571-1600 | crates/ibcmd-xml/src/dcs_schema.rs:4995-5023 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (29 corresponding lines) src/load/compiled.rs:444 — src/load/compiled.rs:444-472 | src/mssql_extension_tree_load.rs:672-706 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (29 corresponding lines) crates/ibcmd-dump/src/mssql_dump/mod.rs:38188 — crates/ibcmd-dump/src/mssql_dump/mod.rs:38188-38224 | crates/ibcmd-dump/src/mssql_dump/mod.rs:38274-38302 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (29 corresponding lines) REDACTED:1081 — REDACTED:1081-1109 | REDACTED:1251-1279 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (29 corresponding lines) crates/ibcmd-form-body/src/form_body.rs:4564 — crates/ibcmd-form-body/src/form_body.rs:4564-4595 | crates/ibcmd-form-body/src/form_body.rs:4662-4690 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copy of a member (6 corresponding lines) · ×6
  • Edited copy of a member (6 corresponding lines) docs/apply/evidence/params-marker/native-seed-resume-v2/classify_seed_resume_transitions_v2.py:10 — docs/apply/evidence/params-marker/native-seed-resume-v2/classify_seed_resume_transitions_v2.py:10-15 | docs/apply/evidence/platform85/extension-version-failed/diff-full-snapshots.py:48-55 — These two members are one piece of code written twice and then edited apart: 6 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (6 corresponding lines) crates/ibcmd-platform-spec/src/platform/mod.rs:94 — crates/ibcmd-platform-spec/src/platform/mod.rs:94-99 | crates/ibcmd-platform/src/lib.rs:137-142 — These two members are one piece of code written twice and then edited apart: 6 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (6 corresponding lines) src/commands/cf.rs:366 — src/commands/cf.rs:366-371 | src/conversion.rs:248-253 — These two members are one piece of code written twice and then edited apart: 6 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (6 corresponding lines) crates/ibcmd-metadata-model/src/metadata_model/bodies_predefined.rs:151 — crates/ibcmd-metadata-model/src/metadata_model/bodies_predefined.rs:151-159 | crates/ibcmd-metadata-model/src/metadata_model/common.rs:166-171 — These two members are one piece of code written twice and then edited apart: 6 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (6 corresponding lines) crates/ibcmd-compiler-families/src/compiler/families/services.rs:2502 — crates/ibcmd-compiler-families/src/compiler/families/services.rs:2502-2507 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:2079-2084 — These two members are one piece of code written twice and then edited apart: 6 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (6 corresponding lines) crates/ibcmd-core/src/semantic.rs:88 — crates/ibcmd-core/src/semantic.rs:88-93 | crates/ibcmd-core/src/storage.rs:1072-1077 — These two members are one piece of code written twice and then edited apart: 6 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Duplicated block (6 lines × 4) · ×6
  • Duplicated block (6 lines × 4) crates/ibcmd-compiler-families/src/compiler/families/form.rs:748 — crates/ibcmd-compiler-families/src/compiler/families/form.rs:748-753 | crates/ibcmd-compiler/src/compiler/bootstrap.rs:1847-1852 | crates/ibcmd-xml/src/metadata/configuration_mobile.rs:46-51 | crates/ibcmd-xml/src/metadata/configuration_v85_projection.rs:100-105 — before extracting anything, compare `crates/ibcmd-xml/src/metadata/configuration_mobile.rs` and `crates/ibcmd-xml/src/metadata/configuration_v85_projection.rs` as WHOLE FILES: this scan already matched 5 separate duplicated blocks between them, totalling at least 31 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/form.rs:748` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (6 lines × 4) crates/ibcmd-compiler-families/src/compiler/families/services.rs:2244 — crates/ibcmd-compiler-families/src/compiler/families/services.rs:2244-2249 | crates/ibcmd-compiler-families/src/compiler/families/services.rs:2377-2382 | crates/ibcmd-compiler/src/compiler/bootstrap.rs:1331-1336 | crates/ibcmd-xml/src/metadata/external_named.rs:55-60 — there are 4 copies across 3 file(s) — more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 4 sites; resolving a subset leaves the remainder to drift apart. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/services.rs:2244` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (6 lines × 4) crates/ibcmd-dump/src/mssql_dump/mod.rs:38437 — crates/ibcmd-dump/src/mssql_dump/mod.rs:38437-38442 | crates/ibcmd-dump/src/mssql_dump/mod.rs:40461-40466 | crates/ibcmd-dump/src/mssql_dump/mod.rs:40501-40506 | crates/ibcmd-dump/src/mssql_dump/mod.rs:40583-40588 — all 4 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:38437` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (6 lines × 4) crates/ibcmd-metadata-model/src/metadata_model/export_names.rs:278 — crates/ibcmd-metadata-model/src/metadata_model/export_names.rs:278-283 | crates/ibcmd-metadata-model/src/metadata_model/export_names.rs:309-314 | crates/ibcmd-metadata-model/src/metadata_model/export_names.rs:407-412 | REDACTED:994-999 — there are 4 copies across 2 file(s) — more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 4 sites; resolving a subset leaves the remainder to drift apart. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-metadata-model/src/metadata_model/export_names.rs:278` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (6 lines × 4) crates/ibcmd-form-writer/src/lib.rs:8390 — crates/ibcmd-form-writer/src/lib.rs:8390-8395 | crates/ibcmd-form-writer/src/lib.rs:8749-8754 | crates/ibcmd-form-writer/src/lib.rs:8826-8831 | crates/ibcmd-form-writer/src/lib.rs:8941-8946 — all 4 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-form-writer/src/lib.rs:8390` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (6 lines × 4) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:2752 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:2752-2757 | crates/ibcmd-compiler-families/src/compiler/families/services.rs:2415-2420 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:2027-2032 | crates/ibcmd-compiler-families/src/compiler/families/utility.rs:1412-1417 — before extracting anything, compare `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs` and `crates/ibcmd-compiler-families/src/compiler/families/services.rs` as WHOLE FILES: this scan already matched 10 separate duplicated blocks between them, totalling at least 103 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:2752` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D2 · Cognitive Complexity · ibcmd_form_native · ×5
  • ibcmd_form_native::resolve_data_path_tokens (cognitive 85) crates/ibcmd-form-native/src/lib.rs:9707 — ibcmd_form_native::resolve_data_path_tokens has cognitive complexity 85 (threshold 15). Drivers by points: if/else 20 (63 pts), match/switch 4 (17 pts), boolean chains 4, loops 1 (nesting depth added 56). To reduce it, flatten the nesting: this score is depth rather than breadth — most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language's equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function.
  • ibcmd_form_native::resolve_metadata_data_path_part (cognitive 26) crates/ibcmd-form-native/src/lib.rs:9976 — ibcmd_form_native::resolve_metadata_data_path_part has cognitive complexity 26 (threshold 15). Drivers by points: if/else 15 (20 pts), boolean chains 3, loops 1 (2 pts), match/switch 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_form_native::format_native_shortcut (cognitive 25) crates/ibcmd-form-native/src/lib.rs:173 — ibcmd_form_native::format_native_shortcut has cognitive complexity 25 (threshold 15). Drivers by points: if/else 9 (16 pts), match/switch 3 (6 pts), loops 1 (2 pts), boolean chains 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_form_native::format_native_font (cognitive 18) crates/ibcmd-form-native/src/lib.rs:1529 — ibcmd_form_native::format_native_font has cognitive complexity 18 (threshold 15). Drivers by points: if/else 9 (11 pts), match/switch 4 (5 pts), loops 2 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level.
  • ibcmd_form_native::walk_data_path_context (cognitive 16) crates/ibcmd-form-native/src/lib.rs:9587 — ibcmd_form_native::walk_data_path_context 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.
D2 · Cognitive Complexity · ibcmd_filedb · ×5
  • ibcmd_filedb::index::rebuild (cognitive 40) crates/ibcmd-filedb/src/index.rs:263 — ibcmd_filedb::index::rebuild has cognitive complexity 40 (threshold 15). Drivers by points: if/else 18 (29 pts), loops 7 (10 pts), boolean chains 1 (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_filedb::descr::parse_table_checked (cognitive 20) crates/ibcmd-filedb/src/descr.rs:229 — ibcmd_filedb::descr::parse_table_checked has cognitive complexity 20 (threshold 15). Drivers by points: if/else 4 (11 pts), loops 3 (7 pts), match/switch 1 (2 pts) (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_filedb::descr::parse_value (cognitive 18) crates/ibcmd-filedb/src/descr.rs:74 — ibcmd_filedb::descr::parse_value has cognitive complexity 18 (threshold 15). Drivers by points: match/switch 3 (7 pts), loops 3 (6 pts), if/else 3 (4 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.
  • ibcmd_filedb::extensions::decode_records_checked (cognitive 18) crates/ibcmd-filedb/src/extensions.rs:171 — ibcmd_filedb::extensions::decode_records_checked has cognitive complexity 18 (threshold 15). Drivers by points: if/else 6 (13 pts), loops 2 (3 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.
  • ibcmd_filedb::blob::build (cognitive 16) crates/ibcmd-filedb/src/blob.rs:81 — ibcmd_filedb::blob::build has cognitive complexity 16 (threshold 15). Drivers by points: if/else 8 (12 pts), loops 3 (4 pts) (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · ibcmd_1c_text · ×5
  • ibcmd_1c_text::strings::parse_1c_quoted_string_with_len (cognitive 27) crates/ibcmd-1c-text/src/strings.rs:41 — ibcmd_1c_text::strings::parse_1c_quoted_string_with_len has cognitive complexity 27 (threshold 15). Drivers by points: if/else 9 (23 pts), match/switch 1 (3 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.
  • ibcmd_1c_text::brace_list::fields (cognitive 20) crates/ibcmd-1c-text/src/brace_list.rs:8 — ibcmd_1c_text::brace_list::fields has cognitive complexity 20 (threshold 15). Drivers by points: if/else 7 (16 pts), match/switch 1 (3 pts), loops 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_1c_text::braced::for_each_1c_braced_field_jumped (cognitive 17) crates/ibcmd-1c-text/src/braced.rs:369 — ibcmd_1c_text::braced::for_each_1c_braced_field_jumped has cognitive complexity 17 (threshold 15). Drivers by points: if/else 4 (8 pts), match/switch 2 (4 pts), boolean chains 3, loops 2 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_1c_text::namespaces::declare_palette_namespace_beside_style (cognitive 17) crates/ibcmd-1c-text/src/namespaces.rs:21 — ibcmd_1c_text::namespaces::declare_palette_namespace_beside_style has cognitive complexity 17 (threshold 15). Drivers by points: if/else 7 (13 pts), loops 2 (3 pts), boolean chains 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_1c_text::fields::decode_base64_mime (cognitive 16) crates/ibcmd-1c-text/src/fields.rs:97 — ibcmd_1c_text::fields::decode_base64_mime has cognitive complexity 16 (threshold 15). Drivers by points: if/else 6 (13 pts), loops 2 (3 pts) (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · ibcmd_restructure · ×5
  • ibcmd_restructure::brace::parse_list (cognitive 22) crates/ibcmd-restructure/src/brace.rs:157 — ibcmd_restructure::brace::parse_list has cognitive complexity 22 (threshold 15). Drivers by points: if/else 5 (12 pts), match/switch 2 (6 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.
  • ibcmd_restructure::schema::add_field_indexes (cognitive 21) crates/ibcmd-restructure/src/schema.rs:597 — ibcmd_restructure::schema::add_field_indexes has cognitive complexity 21 (threshold 15). Drivers by points: if/else 9 (13 pts), boolean chains 5, loops 2, match/switch 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.
  • ibcmd_restructure::schema::sql_type (cognitive 21) crates/ibcmd-restructure/src/schema.rs:929 — ibcmd_restructure::schema::sql_type has cognitive complexity 21 (threshold 15). Drivers by points: if/else 9 (15 pts), match/switch 3 (6 pts) (nesting depth added 9). The drivers above price the dispatch low by construction — a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full — so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident.
  • ibcmd_restructure::schema::declared_indexes (cognitive 20) crates/ibcmd-restructure/src/schema.rs:1094 — ibcmd_restructure::schema::declared_indexes has cognitive complexity 20 (threshold 15). Drivers by points: loops 6 (14 pts), if/else 2 (5 pts), match/switch 1 (nesting depth added 11). The drivers above price the dispatch low by construction — a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full — so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident.
  • ibcmd_restructure::extension::validate_addition (cognitive 16) REDACTED:241 — ibcmd_restructure::extension::validate_addition has cognitive complexity 16 (threshold 15). Drivers by points: if/else 5 (9 pts), loops 4 (6 pts), boolean chains 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D3 · God Classes · TooManyMethods · ×5
  • TooManyMethods: FormTableSchema crates/ibcmd-form-schema/src/lib.rs:8410 — TooManyMethods — 73 methods. The bar is 30 methods; this is 43 over it, 2.43× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
  • TooManyMethods: FormFieldSchema crates/ibcmd-form-schema/src/lib.rs:3731 — TooManyMethods — 51 methods. The bar is 30 methods; this is 21 over it, 1.70× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
  • TooManyMethods: ConfigurationPropertiesEvidencedDefaultBlockPolicy crates/ibcmd-schema/src/lib.rs:5639 — TooManyMethods — 41 methods. The bar is 30 methods; this is 11 over it, 1.37× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
  • TooManyMethods: Obj crates/ibcmd-metadata-model/src/metadata_model/objects_parts.rs:126 — TooManyMethods — 39 methods. The bar is 30 methods; this is 9 over it, 1.30× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
  • TooManyMethods: BodyWriter crates/ibcmd-compiler/src/compiler/bodies/mxl_native.rs:714 — TooManyMethods — 38 methods. The bar is 30 methods; this is 8 over it, 1.27× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
D4 · Code Duplication · Edited copy of a member (33 corresponding lines) · ×5
  • Edited copy of a member (33 corresponding lines) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:893 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:893-925 | crates/ibcmd-compiler-families/src/compiler/families/utility.rs:568-600 — These two members are one piece of code written twice and then edited apart: 33 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (33 corresponding lines) crates/ibcmd-dump/src/mssql_dump/mod.rs:15367 — crates/ibcmd-dump/src/mssql_dump/mod.rs:15367-15405 | crates/ibcmd-dump/src/mssql_dump/mod.rs:29333-29365 — These two members are one piece of code written twice and then edited apart: 33 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (33 corresponding lines) crates/ibcmd-dump/src/mssql_dump/source_assets.rs:4550 — crates/ibcmd-dump/src/mssql_dump/source_assets.rs:4550-4583 | crates/ibcmd-dump/src/mssql_dump/source_assets.rs:4640-4672 — These two members are one piece of code written twice and then edited apart: 33 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (33 corresponding lines) crates/ibcmd-xml/src/metadata/constant.rs:914 — crates/ibcmd-xml/src/metadata/constant.rs:914-946 | crates/ibcmd-xml/src/metadata/language.rs:486-521 — These two members are one piece of code written twice and then edited apart: 33 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (33 corresponding lines) crates/ibcmd-form-body/src/form_body.rs:21166 — crates/ibcmd-form-body/src/form_body.rs:21166-21198 | crates/ibcmd-form-body/src/form_body.rs:21241-21274 — These two members are one piece of code written twice and then edited apart: 33 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copy of a member (32 corresponding lines) · ×5
  • Edited copy of a member (32 corresponding lines) crates/ibcmd-compiler-families/src/compiler/families/services.rs:3602 — crates/ibcmd-compiler-families/src/compiler/families/services.rs:3602-3640 | crates/ibcmd-compiler-families/src/compiler/families/services.rs:3644-3675 — These two members are one piece of code written twice and then edited apart: 32 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (32 corresponding lines) crates/ibcmd-1c-vocab/src/style.rs:170 — crates/ibcmd-1c-vocab/src/style.rs:170-212 | crates/ibcmd-form-body/src/form_body.rs:17041-17072 — These two members are one piece of code written twice and then edited apart: 32 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (32 corresponding lines) crates/ibcmd-metadata-blob/src/lib.rs:7462 — crates/ibcmd-metadata-blob/src/lib.rs:7462-7533 | crates/ibcmd-metadata-blob/src/lib.rs:7635-7666 — These two members are one piece of code written twice and then edited apart: 32 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (32 corresponding lines) crates/ibcmd-metadata-model/src/metadata_model/bodies_predefined.rs:272 — crates/ibcmd-metadata-model/src/metadata_model/bodies_predefined.rs:272-303 | crates/ibcmd-metadata-model/src/metadata_model/bodies_predefined.rs:336-370 — These two members are one piece of code written twice and then edited apart: 32 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (32 corresponding lines) crates/ibcmd-compiler-families/src/compiler/families/simple.rs:2216 — crates/ibcmd-compiler-families/src/compiler/families/simple.rs:2216-2258 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:2280-2311 — These two members are one piece of code written twice and then edited apart: 32 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copy of a member (39 corresponding lines) · ×5
  • Edited copy of a member (39 corresponding lines) crates/ibcmd-xml/src/dcs.rs:768 — crates/ibcmd-xml/src/dcs.rs:768-815 | crates/ibcmd-xml/src/dcs.rs:1427-1465 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (39 corresponding lines) crates/ibcmd-form-body/src/form_body.rs:40430 — crates/ibcmd-form-body/src/form_body.rs:40430-40468 | crates/ibcmd-form-body/src/form_body.rs:40479-40517 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (39 corresponding lines) crates/ibcmd-dump/src/mssql_dump/source_assets.rs:4078 — crates/ibcmd-dump/src/mssql_dump/source_assets.rs:4078-4116 | crates/ibcmd-dump/src/mssql_dump/source_assets.rs:4132-4177 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (39 corresponding lines) crates/ibcmd-form-body/src/form_body.rs:37012 — crates/ibcmd-form-body/src/form_body.rs:37012-37050 | crates/ibcmd-form-body/src/form_body.rs:37054-37092 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (39 corresponding lines) crates/ibcmd-dump/src/mssql_dump/mod.rs:41045 — crates/ibcmd-dump/src/mssql_dump/mod.rs:41045-41083 | crates/ibcmd-dump/src/mssql_dump/mod.rs:42105-42150 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copy of a member (27 corresponding lines) · ×5
  • Edited copy of a member (27 corresponding lines) crates/ibcmd-xml/src/form_choice_parameters.rs:181 — crates/ibcmd-xml/src/form_choice_parameters.rs:181-208 | crates/ibcmd-xml/src/form_choice_parameters.rs:537-563 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (27 corresponding lines) crates/ibcmd-moxel/src/lib.rs:14516 — crates/ibcmd-moxel/src/lib.rs:14516-14542 | crates/ibcmd-moxel/src/lib.rs:14919-14950 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (27 corresponding lines) crates/ibcmd-xml/src/metadata/constant.rs:355 — crates/ibcmd-xml/src/metadata/constant.rs:355-383 | crates/ibcmd-xml/src/metadata/language.rs:153-179 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (27 corresponding lines) crates/ibcmd-form-writer/src/lib.rs:18252 — crates/ibcmd-form-writer/src/lib.rs:18252-18278 | crates/ibcmd-form-writer/src/lib.rs:18284-18313 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (27 corresponding lines) crates/ibcmd-dump/src/mssql_dump/mod.rs:26140 — crates/ibcmd-dump/src/mssql_dump/mod.rs:26140-26167 | crates/ibcmd-dump/src/mssql_dump/mod.rs:32249-32275 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copy of a member (28 corresponding lines) · ×5
  • Edited copy of a member (28 corresponding lines) crates/ibcmd-xml/src/metadata/functional_option.rs:256 — crates/ibcmd-xml/src/metadata/functional_option.rs:256-283 | crates/ibcmd-xml/src/metadata/functional_options_parameter.rs:219-246 — These two members are one piece of code written twice and then edited apart: 28 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (28 corresponding lines) crates/ibcmd-form-body/src/dcs.rs:1125 — crates/ibcmd-form-body/src/dcs.rs:1125-1152 | crates/ibcmd-form-body/src/dcs.rs:1327-1360 — These two members are one piece of code written twice and then edited apart: 28 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (28 corresponding lines) crates/ibcmd-form-body/src/form_body.rs:20858 — crates/ibcmd-form-body/src/form_body.rs:20858-20885 | crates/ibcmd-form-body/src/form_body.rs:20893-20920 — These two members are one piece of code written twice and then edited apart: 28 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (28 corresponding lines) crates/ibcmd-dump/src/mssql_dump/legacy_child.rs:15 — crates/ibcmd-dump/src/mssql_dump/legacy_child.rs:15-46 | crates/ibcmd-dump/src/mssql_dump/mod.rs:12506-12533 — These two members are one piece of code written twice and then edited apart: 28 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (28 corresponding lines) crates/ibcmd-moxel/src/lib.rs:12652 — crates/ibcmd-moxel/src/lib.rs:12652-12679 | crates/ibcmd-moxel/src/lib.rs:12686-12715 — These two members are one piece of code written twice and then edited apart: 28 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copies of one member (3 members, 15+ corresponding lines) · ×5
  • Edited copies of one member (3 members, 15+ corresponding lines) crates/ibcmd-metadata-model/src/metadata_model/export_names.rs:22 — crates/ibcmd-metadata-model/src/metadata_model/export_names.rs:22-36 | crates/ibcmd-metadata-model/src/metadata_model/export_names.rs:39-53 | crates/ibcmd-metadata-model/src/metadata_model/export_names.rs:56-77 — These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 15 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart.
  • Edited copies of one member (3 members, 15+ corresponding lines) src/external/rename.rs:84 — src/external/rename.rs:84-102 | src/external/rename.rs:106-120 | src/external/rename.rs:160-174 — These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 15 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart.
  • Edited copies of one member (3 members, 15+ corresponding lines) crates/ibcmd-xml/src/dcs.rs:2699 — crates/ibcmd-xml/src/dcs.rs:2699-2713 | crates/ibcmd-xml/src/dcs.rs:3243-3257 | crates/ibcmd-xml/src/dcs.rs:3801-3815 — These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 15 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart.
  • Edited copies of one member (3 members, 15+ corresponding lines) crates/ibcmd-moxel/src/lib.rs:12987 — crates/ibcmd-moxel/src/lib.rs:12987-13013 | crates/ibcmd-moxel/src/lib.rs:13015-13033 | crates/ibcmd-moxel/src/lib.rs:13058-13072 — These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 15 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart.
  • Edited copies of one member (3 members, 15+ corresponding lines) crates/ibcmd-moxel/src/lib.rs:4773 — crates/ibcmd-moxel/src/lib.rs:4773-4787 | crates/ibcmd-moxel/src/lib.rs:8920-8934 | crates/ibcmd-moxel/src/lib.rs:8980-8995 — These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 15 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart.
D4 · Code Duplication · Edited copies of one member (3 members, 14+ corresponding lines) · ×5
  • Edited copies of one member (3 members, 14+ corresponding lines) crates/ibcmd-xml/src/metadata/business_objects.rs:1200 — crates/ibcmd-xml/src/metadata/business_objects.rs:1200-1213 | crates/ibcmd-xml/src/metadata/common.rs:1729-1744 | crates/ibcmd-xml/src/metadata/services.rs:2262-2275 — These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 14 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart.
  • Edited copies of one member (3 members, 14+ corresponding lines) crates/ibcmd-restructure-engine/src/restructure/caches/members.rs:153 — crates/ibcmd-restructure-engine/src/restructure/caches/members.rs:153-168 | crates/ibcmd-restructure-engine/src/restructure/caches/slots.rs:548-561 | crates/ibcmd-restructure-engine/src/restructure/catalog.rs:221-234 — These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 14 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart.
  • Edited copies of one member (3 members, 14+ corresponding lines) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:3126 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:3126-3139 | crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:3147-3163 | crates/ibcmd-compiler-families/src/compiler/families/utility.rs:1631-1644 — These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 14 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart.
  • Edited copies of one member (3 members, 14+ corresponding lines) crates/ibcmd-form-writer/src/lib.rs:21759 — crates/ibcmd-form-writer/src/lib.rs:21759-21772 | crates/ibcmd-form-writer/src/lib.rs:22071-22088 | crates/ibcmd-form-writer/src/lib.rs:22917-22934 — These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 14 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart.
  • Edited copies of one member (3 members, 14+ corresponding lines) crates/ibcmd-cf/src/preamble.rs:57 — crates/ibcmd-cf/src/preamble.rs:57-70 | crates/ibcmd-v8/src/writer.rs:62-77 | crates/ibcmd-v8/src/writer.rs:636-650 — These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 14 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart.
D4 · Code Duplication · Duplicated block (27 lines × 2) · ×5
  • Duplicated block (27 lines × 2) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:2924 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:2924-2950 | crates/ibcmd-compiler-families/src/compiler/families/utility.rs:1503-1529 — before extracting anything, compare `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs` and `crates/ibcmd-compiler-families/src/compiler/families/utility.rs` as WHOLE FILES: this scan already matched 65 separate duplicated blocks between them, totalling at least 934 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:2924` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (27 lines × 2) REDACTED:260 — REDACTED:260-286 | src/dump_sources.rs:334-360 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice. 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 `return` inside it is the body's own exit and keeps its meaning in the moved unit.
  • Duplicated block (27 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:39525 — crates/ibcmd-dump/src/mssql_dump/mod.rs:39525-39551 | crates/ibcmd-dump/src/mssql_dump/mod.rs:40703-40729 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:39525` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (27 lines × 2) crates/ibcmd-form-native/src/lib.rs:2040 — crates/ibcmd-form-native/src/lib.rs:2040-2066 | crates/ibcmd-form-native/src/lib.rs:7101-7127 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-form-native/src/lib.rs:2040` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (27 lines × 2) _onecdec/big_compare.py:51 — _onecdec/big_compare.py:51-77 | _onecdec/big_compare_v85.py:33-59 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once. 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.
D4 · Code Duplication · Duplicated block (10–11 lines × 2) · ×5
  • Duplicated block (10–11 lines × 2) crates/ibcmd-1c-text/src/fields.rs:124 — crates/ibcmd-1c-text/src/fields.rs:124-134 | crates/ibcmd-1c-text/src/fields.rs:168-177 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-1c-text/src/fields.rs:124` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, `crates/ibcmd-1c-text/src/fields.rs:166` calls `base64_value` and `crates/ibcmd-1c-text/src/fields.rs:122` does not — after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
  • Duplicated block (10–11 lines × 2) crates/ibcmd-compiler-families/src/compiler/families/services.rs:1652 — crates/ibcmd-compiler-families/src/compiler/families/services.rs:1652-1661 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:1912-1922 — before extracting anything, compare `crates/ibcmd-compiler-families/src/compiler/families/services.rs` and `crates/ibcmd-compiler-families/src/compiler/families/simple.rs` as WHOLE FILES: this scan already matched 36 separate duplicated blocks between them, totalling at least 406 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/services.rs:1652` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
  • Duplicated block (10–11 lines × 2) crates/ibcmd-edt/src/bounded.rs:90 — crates/ibcmd-edt/src/bounded.rs:90-100 | crates/ibcmd-edt/src/codec.rs:1039-1048 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-edt/src/bounded.rs:90` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (10–11 lines × 2) REDACTED:7709 — REDACTED:7709-7719 | REDACTED:7808-7817 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `REDACTED:7709` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
  • Duplicated block (10–11 lines × 2) src/plan.rs:596 — src/plan.rs:596-606 | src/plan.rs:610-619 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `src/plan.rs:596` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
D4 · Code Duplication · Duplicated block (7 lines × 6) · ×5
  • Duplicated block (7 lines × 6) crates/ibcmd-apply-check/src/apply_check/roles.rs:187 — crates/ibcmd-apply-check/src/apply_check/roles.rs:187-193 | crates/ibcmd-compiler/src/compiler/bodies/mxl_native.rs:476-482 | crates/ibcmd-dump/src/mssql_dump/extension/mod.rs:279-285 | crates/ibcmd-form-body/src/layout_8_5_1.rs:310-316 | crates/ibcmd-form-writer/src/form/load_8_5_1.rs:1218-1224 | crates/ibcmd-restructure-engine/src/text.rs:26-32 — before extracting anything, compare `crates/ibcmd-form-body/src/layout_8_5_1.rs` and `crates/ibcmd-form-writer/src/form/load_8_5_1.rs` as WHOLE FILES: this scan already matched 3 separate duplicated blocks between them, totalling at least 55 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 `return` inside it is the body's own exit and keeps its meaning in the moved unit.
  • Duplicated block (7 lines × 6) crates/ibcmd-cf/src/writer.rs:372 — crates/ibcmd-cf/src/writer.rs:372-378 | crates/ibcmd-v8/src/format15.rs:291-297 | crates/ibcmd-v8/src/format16.rs:374-380 | crates/ibcmd-v8/src/reader.rs:938-944 | crates/ibcmd-v8/src/writer.rs:298-304 | crates/ibcmd-v8/src/writer.rs:909-915 — before extracting anything, compare `crates/ibcmd-v8/src/format15.rs` and `crates/ibcmd-v8/src/format16.rs` as WHOLE FILES: this scan already matched 7 separate duplicated blocks between them, totalling at least 82 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place.
  • Duplicated block (7 lines × 6) crates/ibcmd-schema/src/lib.rs:8063 — crates/ibcmd-schema/src/lib.rs:8063-8072 | crates/ibcmd-schema/src/lib.rs:9145-9151 | crates/ibcmd-schema/src/lib.rs:9411-9417 | crates/ibcmd-schema/src/lib.rs:9686-9692 | crates/ibcmd-schema/src/lib.rs:9907-9927 | crates/ibcmd-schema/src/lib.rs:10134-10140 — all 6 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-schema/src/lib.rs:8063` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, `crates/ibcmd-schema/src/lib.rs:9685` calls `as_str` and `crates/ibcmd-schema/src/lib.rs:9144` does not — after which the two agree again for 4 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
  • Duplicated block (7 lines × 6) src/main.rs:110 — src/main.rs:110-116 | src/main.rs:119-125 | src/main.rs:128-134 | src/main.rs:161-167 | src/main.rs:414-420 | src/main.rs:721-727 — all 6 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `src/main.rs:110` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (7 lines × 6) crates/ibcmd-dump/src/mssql_dump/upgrade.rs:730 — crates/ibcmd-dump/src/mssql_dump/upgrade.rs:730-736 | crates/ibcmd-platform-spec/src/adapters/mssql_legacy.rs:206-212 | REDACTED:126-132 | crates/ibcmd-restructure/src/scheduled_jobs.rs:64-70 | src/load/seed.rs:219-225 | src/mssql/empty_stage.rs:1010-1016 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 6 call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made 6 times.
IC1 · Incompleteness & stubs · Empty method body · ×5
  • Empty method body — does nothing with its inputs crates/ibcmd-dump/src/mssql_dump/extension/mod.rs:477 — `note_compatibility` takes parameters but its body is empty — it accepts inputs and does nothing. Either implement it or remove it.
  • Empty method body — does nothing with its inputs crates/ibcmd-dump/src/mssql_dump/extension/mod.rs:486 — `note_indexes` takes parameters but its body is empty — it accepts inputs and does nothing. Either implement it or remove it.
  • Empty method body — does nothing with its inputs crates/ibcmd-metadata-blob/src/lib.rs:2297 — `set_always_used_constants_source` takes parameters but its body is empty — it accepts inputs and does nothing. Either implement it or remove it.
  • Empty method body — does nothing with its inputs crates/ibcmd-moxel/src/lib.rs:90 — `push_xml_element_text` takes parameters but its body is empty — it accepts inputs and does nothing. Either implement it or remove it.
  • Empty method body — does nothing with its inputs src/commands/cf.rs:641 — `rollback_extraction_output` takes parameters but its body is empty — it accepts inputs and does nothing. Either implement it or remove it.
X12 · Unreachable branch · Statement is unreachable · ×5
  • Statement is unreachable — control never gets past the statement before it crates/ibcmd-form-writer/src/lib.rs:2579 — `Err(anyhow !("<{}> has no writer yet", item.tag))` follows `{ let record = native_table_addition(item, kind, data_paths, command_ids, ite…` (line 2562) in the same block, and control never passes that statement — it returns, breaks, continues, panics, exits or calls a function that never returns. This code cannot run for any input; rustc warns `unreachable_code` on it. Delete it, or move it before the statement that leaves if it was meant to run.
  • Statement is unreachable — control never gets past the statement before it crates/ibcmd-form-body/src/form_body.rs:28896 — `if let Some(reference) = object_refs.get(& uuid) && let Some(command_name) = …` follows `{ return Some(format !("Form.Item.{}.StandardCommand.{standard}", owner.name)…` (line 28890) in the same block, and control never passes that statement — it returns, breaks, continues, panics, exits or calls a function that never returns. This code cannot run for any input; rustc warns `unreachable_code` on it. Delete it, or move it before the statement that leaves if it was meant to run.
  • Statement is unreachable — control never gets past the statement before it crates/ibcmd-form-body/src/form_body.rs:39497 — `let record = split_1c_braced_fields(outer.get(1) ?.trim(), 0) ?;` follows `{ return None; }` (line 39494) in the same block, and control never passes that statement — it returns, breaks, continues, panics, exits or calls a function that never returns. This code cannot run for any input; rustc warns `unreachable_code` on it. Delete it, or move it before the statement that leaves if it was meant to run.
  • Statement is unreachable — control never gets past the statement before it crates/ibcmd-filedb/src/windows_security.rs:152 — `let result = Self { allocation : allocation.0, owner, group, };` follows `{ return Err(Error::Refused("invalid file owner/group/DACL descriptor".into()…` (line 147) in the same block, and control never passes that statement — it returns, breaks, continues, panics, exits or calls a function that never returns. This code cannot run for any input; rustc warns `unreachable_code` on it. Delete it, or move it before the statement that leaves if it was meant to run.
  • Statement is unreachable — control never gets past the statement before it crates/ibcmd-dump/src/mssql_dump/mod.rs:24105 — `let path_end = index.checked_add(path_count) ?;` follows `{ return None; }` (line 24102) in the same block, and control never passes that statement — it returns, breaks, continues, panics, exits or calls a function that never returns. This code cannot run for any input; rustc warns `unreachable_code` on it. Delete it, or move it before the statement that leaves if it was meant to run.
D1 · Cyclomatic Complexity · ibcmd_form_native · ×4
  • ibcmd_form_native::resolve_data_path_tokens (cyclomatic 31) crates/ibcmd-form-native/src/lib.rs:9707 — ibcmd_form_native::resolve_data_path_tokens has cyclomatic complexity 31 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
  • ibcmd_form_native::format_native_shortcut (cyclomatic 22) crates/ibcmd-form-native/src/lib.rs:173 — ibcmd_form_native::format_native_shortcut 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.
  • ibcmd_form_native::format_native_font (cyclomatic 22) crates/ibcmd-form-native/src/lib.rs:1529 — ibcmd_form_native::format_native_font has cyclomatic complexity 22 (threshold 15). To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (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 — the same kind of value, with no behaviour of its own — 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.
  • ibcmd_form_native::resolve_metadata_data_path_part (cyclomatic 21) crates/ibcmd-form-native/src/lib.rs:9976 — ibcmd_form_native::resolve_metadata_data_path_part 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.
D30 · Dependency Vulnerabilities · Medium advisory (unsound) · ×4
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
D30 · Dependency Vulnerabilities · Medium vulnerability · ×4
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
D4 · Code Duplication · Members sharing a duplicated core (8 members, 50+ identical tokens) · ×4
  • Members sharing a duplicated core (8 members, 50+ identical tokens) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:1184 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:1184-1325 | crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:1331-1460 | crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:1511-1618 | crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:1624-1754 | crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:1760-1877 | crates/ibcmd-compiler-families/src/compiler/families/business_object/register_native.rs:894-992 | crates/ibcmd-compiler-families/src/compiler/families/business_object/register_native.rs:1040-1143 | crates/ibcmd-compiler-families/src/compiler/families/business_object/register_native.rs:1171-1291 — These 8 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below — it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 8 times. The repair is at the members' grain — factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 8 times.
  • Members sharing a duplicated core (8 members, 50+ identical tokens) crates/ibcmd-compiler-families/src/compiler/families/services.rs:1446 — crates/ibcmd-compiler-families/src/compiler/families/services.rs:1446-1519 | crates/ibcmd-compiler-families/src/compiler/families/services.rs:1524-1601 | crates/ibcmd-compiler-families/src/compiler/families/services.rs:1690-1735 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:1205-1412 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:1417-1475 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:1502-1657 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:1696-1800 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:1805-1885 — These 8 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below — it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 8 times. The repair is at the members' grain — factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 8 times.
  • Members sharing a duplicated core (8 members, 50+ identical tokens) crates/ibcmd-dump/src/mssql_dump/mod.rs:38226 — crates/ibcmd-dump/src/mssql_dump/mod.rs:38226-38268 | crates/ibcmd-dump/src/mssql_dump/mod.rs:38304-38330 | crates/ibcmd-dump/src/mssql_dump/mod.rs:40378-40444 | crates/ibcmd-dump/src/mssql_dump/mod.rs:40653-40687 | crates/ibcmd-dump/src/mssql_dump/mod.rs:41325-41346 | crates/ibcmd-dump/src/mssql_dump/mod.rs:41406-41483 | crates/ibcmd-dump/src/mssql_dump/mod.rs:44348-44380 | crates/ibcmd-dump/src/mssql_dump/mod.rs:44533-44586 — These 8 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below — it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 8 times. The repair is at the members' grain — factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 8 times.
  • Members sharing a duplicated core (8 members, 50+ identical tokens) crates/ibcmd-xml/src/metadata/functional_option.rs:80 — crates/ibcmd-xml/src/metadata/functional_option.rs:80-131 | crates/ibcmd-xml/src/metadata/functional_options_parameter.rs:79-119 | crates/ibcmd-xml/src/metadata/language.rs:120-151 | crates/ibcmd-xml/src/metadata/services.rs:422-475 | crates/ibcmd-xml/src/metadata/services.rs:481-521 | crates/ibcmd-xml/src/metadata/services.rs:527-561 | crates/ibcmd-xml/src/metadata/services.rs:567-690 | crates/ibcmd-xml/src/metadata/services.rs:696-845 — These 8 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below — it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 8 times. The repair is at the members' grain — factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 8 times.
D4 · Code Duplication · Edited copy of a member (38 corresponding lines) · ×4
  • Edited copy of a member (38 corresponding lines) crates/ibcmd-compiler-families/src/compiler/families/services.rs:2460 — crates/ibcmd-compiler-families/src/compiler/families/services.rs:2460-2497 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:2037-2074 — These two members are one piece of code written twice and then edited apart: 38 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (38 corresponding lines) crates/ibcmd-restructure-engine/src/restructure/caches/registry.rs:183 — crates/ibcmd-restructure-engine/src/restructure/caches/registry.rs:183-220 | crates/ibcmd-restructure-engine/src/restructure/registry.rs:37-91 — These two members are one piece of code written twice and then edited apart: 38 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (38 corresponding lines) crates/ibcmd-cf/src/payload.rs:181 — crates/ibcmd-cf/src/payload.rs:181-236 | crates/ibcmd-cf/src/payload.rs:238-275 — These two members are one piece of code written twice and then edited apart: 38 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (38 corresponding lines) crates/ibcmd-1c-text/src/brace_list.rs:8 — crates/ibcmd-1c-text/src/brace_list.rs:8-47 | crates/ibcmd-dump/src/mssql_dump/upgrade.rs:745-782 — These two members are one piece of code written twice and then edited apart: 38 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copy of a member (30 corresponding lines) · ×4
  • Edited copy of a member (30 corresponding lines) src/external/export.rs:123 — src/external/export.rs:123-152 | src/external/export.rs:159-202 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (30 corresponding lines) crates/ibcmd-dump/src/mssql_dump/mod.rs:10414 — crates/ibcmd-dump/src/mssql_dump/mod.rs:10414-10444 | crates/ibcmd-dump/src/mssql_dump/refs.rs:1547-1576 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (30 corresponding lines) crates/ibcmd-xml/src/dcs.rs:2665 — crates/ibcmd-xml/src/dcs.rs:2665-2694 | crates/ibcmd-xml/src/dcs.rs:3196-3238 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (30 corresponding lines) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:4390 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:4390-4419 | crates/ibcmd-compiler-families/src/compiler/families/utility.rs:2585-2619 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copies of one member (3 members, 16+ corresponding lines) · ×4
  • Edited copies of one member (3 members, 16+ corresponding lines) _onecdec/make_empty_root_interface_fixture.py:25 — _onecdec/make_empty_root_interface_fixture.py:25-41 | _onecdec/make_form_compat_probe.py:26-41 | _onecdec/make_search_form_fixture.py:23-41 — 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' 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.
  • Edited copies of one member (3 members, 16+ corresponding lines) src/mssql_extension_export.rs:408 — src/mssql_extension_export.rs:408-428 | src/mssql_extension_load.rs:1367-1382 | src/mssql_extensions.rs:596-613 — 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' 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.
  • Edited copies of one member (3 members, 16+ corresponding lines) crates/ibcmd-form-body/src/form_body.rs:23261 — crates/ibcmd-form-body/src/form_body.rs:23261-23276 | crates/ibcmd-form-body/src/form_body.rs:23285-23300 | crates/ibcmd-form-body/src/form_body.rs:23337-23355 — 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' 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.
  • Edited copies of one member (3 members, 16+ corresponding lines) crates/ibcmd-core/src/dcs.rs:463 — crates/ibcmd-core/src/dcs.rs:463-478 | crates/ibcmd-core/src/dcs.rs:695-710 | crates/ibcmd-core/src/dcs.rs:882-897 — 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' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart.
D4 · Code Duplication · Edited copy of a member (31 corresponding lines) · ×4
  • Edited copy of a member (31 corresponding lines) crates/ibcmd-xml/src/metadata/hierarchical_objects.rs:703 — crates/ibcmd-xml/src/metadata/hierarchical_objects.rs:703-736 | crates/ibcmd-xml/src/metadata/register_objects.rs:939-969 — These two members are one piece of code written twice and then edited apart: 31 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (31 corresponding lines) crates/ibcmd-compiler/src/compiler/bodies/mxl_native.rs:111 — crates/ibcmd-compiler/src/compiler/bodies/mxl_native.rs:111-141 | crates/ibcmd-config-apply/src/mssql_config_apply/dynamic_metadata.rs:391-424 — These two members are one piece of code written twice and then edited apart: 31 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (31 corresponding lines) REDACTED:8946 — REDACTED:8946-8976 | REDACTED:8978-9015 — These two members are one piece of code written twice and then edited apart: 31 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (31 corresponding lines) crates/ibcmd-compiler-families/src/compiler/families/assets.rs:971 — crates/ibcmd-compiler-families/src/compiler/families/assets.rs:971-1005 | crates/ibcmd-compiler-families/src/compiler/families/commands.rs:192-222 — These two members are one piece of code written twice and then edited apart: 31 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copies of one member (3 members, 23+ corresponding lines) · ×4
  • Edited copies of one member (3 members, 23+ corresponding lines) crates/ibcmd-form-writer/src/lib.rs:21819 — crates/ibcmd-form-writer/src/lib.rs:21819-21841 | crates/ibcmd-form-writer/src/lib.rs:22149-22180 | crates/ibcmd-form-writer/src/lib.rs:23210-23234 — These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 23 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart.
  • Edited copies of one member (3 members, 23+ corresponding lines) crates/ibcmd-dump/src/mssql_dump/mod.rs:8885 — crates/ibcmd-dump/src/mssql_dump/mod.rs:8885-8907 | crates/ibcmd-schema/src/lib.rs:1028-1050 | crates/ibcmd-schema/src/lib.rs:2554-2576 — These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 23 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart.
  • Edited copies of one member (3 members, 23+ corresponding lines) REDACTED:383 — REDACTED:383-407 | REDACTED:415-437 | REDACTED:840-864 — These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 23 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart.
  • Edited copies of one member (3 members, 23+ corresponding lines) REDACTED:5594 — REDACTED:5594-5616 | REDACTED:6032-6058 | REDACTED:6594-6625 — These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 23 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart.
D4 · Code Duplication · Edited copies of one member (3 members, 12+ corresponding lines) · ×4
  • Edited copies of one member (3 members, 12+ corresponding lines) crates/ibcmd-form-body/src/form_body.rs:19565 — crates/ibcmd-form-body/src/form_body.rs:19565-19576 | crates/ibcmd-form-body/src/form_body.rs:21495-21515 | crates/ibcmd-form-body/src/form_body.rs:21561-21583 — 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' 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.
  • Edited copies of one member (3 members, 12+ corresponding lines) crates/ibcmd-core/src/diagnostic.rs:633 — crates/ibcmd-core/src/diagnostic.rs:633-644 | crates/ibcmd-core/src/storage.rs:248-263 | crates/ibcmd-core/src/value.rs:155-170 — 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' 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.
  • Edited copies of one member (3 members, 12+ corresponding lines) crates/ibcmd-compiler-families/src/compiler/families/services.rs:2349 — crates/ibcmd-compiler-families/src/compiler/families/services.rs:2349-2364 | crates/ibcmd-compiler-families/src/compiler/families/services.rs:2528-2539 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:2090-2101 — 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' 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.
  • Edited copies of one member (3 members, 12+ corresponding lines) crates/ibcmd-form-body/src/form_body.rs:32239 — crates/ibcmd-form-body/src/form_body.rs:32239-32250 | crates/ibcmd-form-body/src/form_body.rs:37302-37318 | crates/ibcmd-form-body/src/form_body.rs:38280-38291 — 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' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart.
D4 · Code Duplication · Edited copies of one member (3 members, 8+ corresponding lines) · ×4
  • Edited copies of one member (3 members, 8+ corresponding lines) crates/ibcmd-form-writer/src/lib.rs:22647 — crates/ibcmd-form-writer/src/lib.rs:22647-22655 | crates/ibcmd-form-writer/src/lib.rs:22660-22667 | crates/ibcmd-form-writer/src/lib.rs:22672-22679 — These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 8 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' 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.
  • Edited copies of one member (3 members, 8+ corresponding lines) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:4526 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:4526-4534 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:3141-3148 | crates/ibcmd-compiler-families/src/compiler/families/utility.rs:2685-2693 — These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 8 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' 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.
  • Edited copies of one member (3 members, 8+ corresponding lines) crates/ibcmd-metadata-model/src/metadata_model/attribute.rs:130 — crates/ibcmd-metadata-model/src/metadata_model/attribute.rs:130-139 | crates/ibcmd-metadata-model/src/metadata_model/root.rs:650-660 | crates/ibcmd-metadata-model/src/metadata_model/simple.rs:82-89 — These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 8 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' 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.
  • Edited copies of one member (3 members, 8+ corresponding lines) src/mssql/override_stage.rs:283 — src/mssql/override_stage.rs:283-290 | src/mssql/stage_guard.rs:561-570 | src/stored_objects.rs:816-825 — These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 8 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart.
D4 · Code Duplication · Edited copies of one member (3 members, 7+ corresponding lines) · ×4
  • Edited copies of one member (3 members, 7+ corresponding lines) crates/ibcmd-1c-vocab/src/types.rs:244 — crates/ibcmd-1c-vocab/src/types.rs:244-254 | crates/ibcmd-dump/src/mssql_dump/mod.rs:15003-15009 | crates/ibcmd-dump/src/mssql_dump/mod.rs:19316-19322 — 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' 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.
  • Edited copies of one member (3 members, 7+ corresponding lines) crates/ibcmd-metadata-model/src/metadata_model/objects_parts.rs:31 — crates/ibcmd-metadata-model/src/metadata_model/objects_parts.rs:31-37 | crates/ibcmd-metadata-model/src/metadata_model/objects_parts.rs:416-423 | crates/ibcmd-metadata-model/src/metadata_model/registers_parts.rs:50-56 — 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' 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.
  • Edited copies of one member (3 members, 7+ corresponding lines) crates/ibcmd-metadata-model/src/metadata_model/bodies_flowchart.rs:72 — crates/ibcmd-metadata-model/src/metadata_model/bodies_flowchart.rs:72-78 | crates/ibcmd-metadata-model/src/metadata_model/common.rs:73-79 | crates/ibcmd-metadata-model/src/metadata_model/objects_parts.rs:856-862 — 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' 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.
  • Edited copies of one member (3 members, 7+ corresponding lines) crates/ibcmd-form-writer/src/form_chart.rs:1848 — crates/ibcmd-form-writer/src/form_chart.rs:1848-1854 | crates/ibcmd-form-writer/src/form_planner.rs:449-455 | crates/ibcmd-metadata-blob/src/interface_assets.rs:218-224 — 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' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart.
D4 · Code Duplication · Duplicated block (9–10 lines × 2) · ×4
  • Duplicated block (9–10 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:32642 — crates/ibcmd-dump/src/mssql_dump/mod.rs:32642-32650 | crates/ibcmd-dump/src/mssql_dump/refs.rs:508-517 — before extracting anything, compare `crates/ibcmd-dump/src/mssql_dump/mod.rs` and `crates/ibcmd-dump/src/mssql_dump/refs.rs` as WHOLE FILES: this scan already matched 13 separate duplicated blocks between them, totalling at least 117 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
  • Duplicated block (9–10 lines × 2) crates/ibcmd-moxel/src/lib.rs:2661 — crates/ibcmd-moxel/src/lib.rs:2661-2670 | crates/ibcmd-moxel/src/lib.rs:11973-11981 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-moxel/src/lib.rs:2661` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (9–10 lines × 2) crates/ibcmd-xml/src/dcs_schema.rs:1262 — crates/ibcmd-xml/src/dcs_schema.rs:1262-1270 | crates/ibcmd-xml/src/dcs_schema.rs:4325-4334 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-xml/src/dcs_schema.rs:4325` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (9–10 lines × 2) crates/ibcmd-form-body/src/form_body.rs:38999 — crates/ibcmd-form-body/src/form_body.rs:38999-39007 | crates/ibcmd-form-body/src/form_body.rs:40124-40133 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-form-body/src/form_body.rs:40124` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
D4 · Code Duplication · Duplicated block (9 lines × 5) · ×4
  • Duplicated block (9 lines × 5) crates/ibcmd-dump/src/mssql_dump/mod.rs:15020 — crates/ibcmd-dump/src/mssql_dump/mod.rs:15020-15028 | crates/ibcmd-dump/src/mssql_dump/mod.rs:26099-26107 | crates/ibcmd-dump/src/mssql_dump/mod.rs:30530-30538 | crates/ibcmd-dump/src/mssql_dump/mod.rs:31198-31206 | crates/ibcmd-dump/src/mssql_dump/mod.rs:32224-32232 — all 5 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:15020` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (9 lines × 5) crates/ibcmd-form-body/src/form_body.rs:2808 — crates/ibcmd-form-body/src/form_body.rs:2808-2816 | crates/ibcmd-form-body/src/form_body.rs:3371-3379 | crates/ibcmd-form-body/src/form_body.rs:3387-3395 | crates/ibcmd-form-body/src/form_body.rs:3512-3520 | crates/ibcmd-form-body/src/form_body.rs:3527-3535 — all 5 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-form-body/src/form_body.rs:2808` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, `crates/ibcmd-form-body/src/form_body.rs:3398` calls `Some` and `crates/ibcmd-form-body/src/form_body.rs:3382` does not — after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
  • Duplicated block (9 lines × 5) crates/ibcmd-metadata-blob/src/lib.rs:5091 — crates/ibcmd-metadata-blob/src/lib.rs:5091-5099 | crates/ibcmd-metadata-blob/src/lib.rs:5254-5262 | crates/ibcmd-metadata-blob/src/lib.rs:5637-5645 | crates/ibcmd-metadata-blob/src/lib.rs:5748-5756 | crates/ibcmd-metadata-blob/src/lib.rs:6270-6278 — all 5 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-metadata-blob/src/lib.rs:5091` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (9 lines × 5) crates/ibcmd-xml/src/metadata/services.rs:434 — crates/ibcmd-xml/src/metadata/services.rs:434-442 | crates/ibcmd-xml/src/metadata/services.rs:493-515 | crates/ibcmd-xml/src/metadata/services.rs:539-555 | crates/ibcmd-xml/src/metadata/services.rs:578-597 | crates/ibcmd-xml/src/metadata/services.rs:707-715 — all 5 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-xml/src/metadata/services.rs:434` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
D4 · Code Duplication · Duplicated block (8 lines × 5) · ×4
  • Duplicated block (8 lines × 5) crates/ibcmd-compiler-families/src/compiler/families/services.rs:1447 — crates/ibcmd-compiler-families/src/compiler/families/services.rs:1447-1454 | crates/ibcmd-compiler-families/src/compiler/families/services.rs:1525-1532 | crates/ibcmd-compiler-families/src/compiler/families/services.rs:1691-1698 | crates/ibcmd-compiler-families/src/compiler/families/services.rs:1900-1907 | crates/ibcmd-compiler-families/src/compiler/families/services.rs:2031-2038 — all 5 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/services.rs:1447` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (8 lines × 5) crates/ibcmd-dump/src/mssql_dump/mod.rs:27946 — crates/ibcmd-dump/src/mssql_dump/mod.rs:27946-27953 | crates/ibcmd-dump/src/mssql_dump/mod.rs:31185-31192 | crates/ibcmd-dump/src/mssql_dump/mod.rs:32211-32218 | crates/ibcmd-dump/src/mssql_dump/mod.rs:32856-32863 | crates/ibcmd-dump/src/mssql_dump/mod.rs:32951-32958 — all 5 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (8 lines × 5) crates/ibcmd-v8/src/format15.rs:289 — crates/ibcmd-v8/src/format15.rs:289-296 | crates/ibcmd-v8/src/format16.rs:372-379 | crates/ibcmd-v8/src/reader.rs:936-943 | crates/ibcmd-v8/src/writer.rs:296-303 | crates/ibcmd-v8/src/writer.rs:907-914 — before extracting anything, compare `crates/ibcmd-v8/src/format15.rs` and `crates/ibcmd-v8/src/format16.rs` as WHOLE FILES: this scan already matched 7 separate duplicated blocks between them, totalling at least 82 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-v8/src/format15.rs:289` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (8 lines × 5) REDACTED:1013 — REDACTED:1013-1020 | REDACTED:1051-1058 | src/mssql_apply.rs:743-750 | src/mssql_extension_load.rs:153-160 | src/mssql_extension_load.rs:411-418 — there are 5 copies across 3 file(s) — more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 5 sites; resolving a subset leaves the remainder to drift apart. Read the line range as the matched WINDOW rather than a finished unit: at `REDACTED:1013` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note first that the copies are not typed on the same thing: the declarations holding them bind `args` to `&MssqlActivateStagedMainArgs` in one and `&MssqlApplySourceChangeArgs` in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH — their common supertype where they have one, or a new abstraction over them where they do not — and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract.
D4 · Code Duplication · Duplicated block (5 lines × 4) · ×4
  • Duplicated block (5 lines × 4) crates/ibcmd-apply-check/src/apply_check/dbtree.rs:157 — crates/ibcmd-apply-check/src/apply_check/dbtree.rs:157-161 | crates/ibcmd-apply-check/src/apply_check/trees.rs:38-42 | src/dcs_template_audit.rs:83-87 | src/source_audit.rs:2067-2071 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 4 call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made 4 times. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-apply-check/src/apply_check/dbtree.rs:157` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (5 lines × 4) crates/ibcmd-dump/src/mssql_dump/mod.rs:29283 — crates/ibcmd-dump/src/mssql_dump/mod.rs:29283-29295 | crates/ibcmd-dump/src/mssql_dump/mod.rs:32361-32365 | crates/ibcmd-dump/src/mssql_dump/mod.rs:32916-32920 | crates/ibcmd-dump/src/mssql_dump/mod.rs:33004-33008 — all 4 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, `crates/ibcmd-dump/src/mssql_dump/mod.rs:32914` calls `with_capacity` and `crates/ibcmd-dump/src/mssql_dump/mod.rs:33002` does not — after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
  • Duplicated block (5 lines × 4) crates/ibcmd-form-writer/src/lib.rs:16209 — crates/ibcmd-form-writer/src/lib.rs:16209-16213 | crates/ibcmd-form-writer/src/lib.rs:16221-16225 | crates/ibcmd-form-writer/src/lib.rs:21042-21046 | crates/ibcmd-form-writer/src/lib.rs:21054-21058 — all 4 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-form-writer/src/lib.rs:16209` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (5 lines × 4) crates/ibcmd-dump/src/mssql_dump/mod.rs:22130 — crates/ibcmd-dump/src/mssql_dump/mod.rs:22130-22134 | crates/ibcmd-moxel/src/lib.rs:5930-5934 | crates/ibcmd-moxel/src/lib.rs:7119-7123 | crates/ibcmd-moxel/src/lib.rs:8037-8041 — before extracting anything, compare `crates/ibcmd-dump/src/mssql_dump/mod.rs` and `crates/ibcmd-moxel/src/lib.rs` as WHOLE FILES: this scan already matched 5 separate duplicated blocks between them, totalling at least 31 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.
D4 · Code Duplication · Edited copy of a member (2 corresponding lines) · ×4
  • Edited copy of a member (2 corresponding lines) scripts/apply-trace/lab/s1g-caches/reg_cmp.py:15 — scripts/apply-trace/lab/s1g-caches/reg_cmp.py:15-16 | scripts/restructure-lab/s1k/check_register.py:21-22 — These two members are one piece of code written twice and then edited apart: 2 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (2 corresponding lines) scripts/restructure-lab/lab.py:22 — scripts/restructure-lab/lab.py:22-23 | scripts/restructure-lab/si_diff.py:25-26 — These two members are one piece of code written twice and then edited apart: 2 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (2 corresponding lines) scripts/restructure-lab/entries_diff.py:30 — scripts/restructure-lab/entries_diff.py:30-31 | scripts/restructure-lab/make_cases_md.py:27-28 — These two members are one piece of code written twice and then edited apart: 2 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (2 corresponding lines) scripts/restructure-lab/s1k/overlay.py:18 — scripts/restructure-lab/s1k/overlay.py:18-19 | scripts/restructure-lab/schema_order_dump.py:31-32 — These two members are one piece of code written twice and then edited apart: 2 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D1 · Cyclomatic Complexity · DataCompositionXmlWriter · ×3
  • DataCompositionXmlWriter::write_document (cyclomatic 36) crates/ibcmd-form-body/src/dcs.rs:1827 — DataCompositionXmlWriter::write_document 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.
  • DataCompositionXmlWriter::write_start_tag (cyclomatic 36) crates/ibcmd-form-body/src/dcs.rs:2111 — DataCompositionXmlWriter::write_start_tag 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.
  • DataCompositionXmlWriter::write_text (cyclomatic 27) crates/ibcmd-form-body/src/dcs.rs:2370 — DataCompositionXmlWriter::write_text 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.
D1 · Cyclomatic Complexity · ibcmd_schema · ×3
  • ibcmd_schema::parse_form_choice_list_item_inner (cyclomatic 30) crates/ibcmd-schema/src/lib.rs:818 — ibcmd_schema::parse_form_choice_list_item_inner has cyclomatic complexity 30 (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 — the same kind of value, with no behaviour of its own — 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.
  • ibcmd_schema::parse_raw_form_choice_parameter_links (cyclomatic 26) crates/ibcmd-schema/src/lib.rs:2137 — ibcmd_schema::parse_raw_form_choice_parameter_links 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.
  • ibcmd_schema::parse_form_choice_parameter_value (cyclomatic 24) crates/ibcmd-schema/src/lib.rs:2278 — ibcmd_schema::parse_form_choice_parameter_value 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 — the same kind of value, with no behaviour of its own — 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.
D1 · Cyclomatic Complexity · ibcmd_mssql_live · ×3
  • ibcmd_mssql_live::mssql_main_activation::render_main_activation_sql_internal (cyclomatic 27) REDACTED:846 — ibcmd_mssql_live::mssql_main_activation::render_main_activation_sql_internal has cyclomatic complexity 27 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
  • ibcmd_mssql_live::mssql_main_activation::prepare_main_activation_for (cyclomatic 20) REDACTED:536 — ibcmd_mssql_live::mssql_main_activation::prepare_main_activation_for has cyclomatic complexity 20 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
  • ibcmd_mssql_live::mssql_managed_worker::native::require_shutdown_census (cyclomatic 20) crates/ibcmd-mssql-live/src/mssql_managed_worker/native.rs:204 — ibcmd_mssql_live::mssql_managed_worker::native::require_shutdown_census 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.
D2 · Cognitive Complexity · StoredConfiguration · ×3
  • StoredConfiguration::prepare_editor_export (cognitive 104) src/stored_objects/editor_export.rs:17 — StoredConfiguration::prepare_editor_export has cognitive complexity 104 (threshold 15). Drivers by points: if/else 26 (56 pts), loops 15 (40 pts), boolean chains 6, match/switch 2 (nesting depth added 55). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • StoredConfiguration::status_with_files (cognitive 22) src/stored_objects.rs:1458 — StoredConfiguration::status_with_files has cognitive complexity 22 (threshold 15). Drivers by points: if/else 4 (8 pts), match/switch 3 (7 pts), loops 4 (6 pts), boolean chains 1 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • StoredConfiguration::export_with_descriptor_check_unlocked (cognitive 16) src/stored_objects.rs:1124 — StoredConfiguration::export_with_descriptor_check_unlocked has cognitive complexity 16 (threshold 15). Drivers by points: if/else 6 (12 pts), boolean chains 2, loops 2 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · ibcmd_core · ×3
  • ibcmd_core::dcs::validate_settings (cognitive 80) crates/ibcmd-core/src/dcs.rs:1270 — ibcmd_core::dcs::validate_settings has cognitive complexity 80 (threshold 15). Drivers by points: if/else 32 (65 pts), loops 5 (9 pts), boolean chains 6 (nesting depth added 37). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_core::validate::validate_ownership_cycles (cognitive 27) crates/ibcmd-core/src/validate.rs:268 — ibcmd_core::validate::validate_ownership_cycles has cognitive complexity 27 (threshold 15). Drivers by points: if/else 6 (15 pts), loops 6 (8 pts), boolean chains 2, match/switch 1 (2 pts) (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_core::storage::validate_image_with_retained_byte_limit (cognitive 19) crates/ibcmd-core/src/storage.rs:1273 — ibcmd_core::storage::validate_image_with_retained_byte_limit has cognitive complexity 19 (threshold 15). Drivers by points: if/else 8 (13 pts), match/switch 2 (4 pts), loops 2 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · DataCompositionXmlWriter · ×3
  • DataCompositionXmlWriter::write_document (cognitive 75) crates/ibcmd-form-body/src/dcs.rs:1827 — DataCompositionXmlWriter::write_document has cognitive complexity 75 (threshold 15). Drivers by points: if/else 18 (62 pts), boolean chains 7, match/switch 2 (5 pts), loops 1 (nesting depth added 47). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • DataCompositionXmlWriter::write_start_tag (cognitive 59) crates/ibcmd-form-body/src/dcs.rs:2111 — DataCompositionXmlWriter::write_start_tag has cognitive complexity 59 (threshold 15). Drivers by points: if/else 25 (42 pts), boolean chains 12, loops 4 (5 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.
  • DataCompositionXmlWriter::write_text (cognitive 40) crates/ibcmd-form-body/src/dcs.rs:2370 — DataCompositionXmlWriter::write_text has cognitive complexity 40 (threshold 15). Drivers by points: if/else 13 (24 pts), boolean chains 13, match/switch 1 (3 pts) (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D30 · Dependency Vulnerabilities · Medium CVE · ×3
  • REDACTED
  • REDACTED
  • REDACTED
D4 · Code Duplication · Members sharing a duplicated core (9 members, 50+ identical tokens) · ×3
  • Members sharing a duplicated core (9 members, 50+ identical tokens) crates/ibcmd-dump/src/mssql_dump/mod.rs:17941 — crates/ibcmd-dump/src/mssql_dump/mod.rs:17941-17980 | crates/ibcmd-dump/src/mssql_dump/mod.rs:17982-18038 | crates/ibcmd-dump/src/mssql_dump/mod.rs:18976-19030 | crates/ibcmd-dump/src/mssql_dump/mod.rs:26425-26514 | crates/ibcmd-dump/src/mssql_dump/mod.rs:27214-27292 | crates/ibcmd-dump/src/mssql_dump/mod.rs:28993-29074 | crates/ibcmd-dump/src/mssql_dump/mod.rs:30571-30626 | crates/ibcmd-dump/src/mssql_dump/mod.rs:31269-31325 | crates/ibcmd-dump/src/mssql_dump/mod.rs:32292-32347 — These 9 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below — it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 9 times. The repair is at the members' grain — factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 9 times.
  • Members sharing a duplicated core (9 members, 50+ identical tokens) crates/ibcmd-dump/src/mssql_dump/mod.rs:37969 — crates/ibcmd-dump/src/mssql_dump/mod.rs:37969-38121 | crates/ibcmd-dump/src/mssql_dump/mod.rs:38689-38840 | crates/ibcmd-dump/src/mssql_dump/mod.rs:38847-38983 | crates/ibcmd-dump/src/mssql_dump/mod.rs:39048-39225 | crates/ibcmd-dump/src/mssql_dump/mod.rs:39232-39508 | crates/ibcmd-dump/src/mssql_dump/mod.rs:39670-39852 | crates/ibcmd-dump/src/mssql_dump/mod.rs:39874-40051 | crates/ibcmd-dump/src/mssql_dump/mod.rs:40058-40230 | crates/ibcmd-dump/src/mssql_dump/mod.rs:40693-40840 — These 9 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below — it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 9 times. The repair is at the members' grain — factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 9 times.
  • Members sharing a duplicated core (9 members, 50+ identical tokens) crates/ibcmd-schema/src/lib.rs:7985 — crates/ibcmd-schema/src/lib.rs:7985-7995 | crates/ibcmd-schema/src/lib.rs:8093-8103 | crates/ibcmd-schema/src/lib.rs:8388-8398 | crates/ibcmd-schema/src/lib.rs:8593-8603 | crates/ibcmd-schema/src/lib.rs:8936-8946 | crates/ibcmd-schema/src/lib.rs:9181-9191 | crates/ibcmd-schema/src/lib.rs:9452-9462 | crates/ibcmd-schema/src/lib.rs:9731-9742 | crates/ibcmd-schema/src/lib.rs:9964-9974 — These 9 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below — it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 9 times. The repair is at the members' grain — factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 9 times.
D4 · Code Duplication · Edited copy of a member (44 corresponding lines) · ×3
  • Edited copy of a member (44 corresponding lines) src/commands/cf.rs:918 — src/commands/cf.rs:918-961 | src/commands/cf.rs:968-1018 — These two members are one piece of code written twice and then edited apart: 44 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (44 corresponding lines) crates/ibcmd-form-writer/src/lib.rs:15988 — crates/ibcmd-form-writer/src/lib.rs:15988-16036 | crates/ibcmd-form-writer/src/lib.rs:16042-16085 — These two members are one piece of code written twice and then edited apart: 44 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (44 corresponding lines) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:3600 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:3600-3643 | crates/ibcmd-compiler-families/src/compiler/families/utility.rs:1938-1981 — These two members are one piece of code written twice and then edited apart: 44 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copy of a member (43 corresponding lines) · ×3
  • Edited copy of a member (43 corresponding lines) REDACTED:6512 — REDACTED:6512-6554 | REDACTED:7022-7071 — These two members are one piece of code written twice and then edited apart: 43 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (43 corresponding lines) crates/ibcmd-dump/src/mssql_dump/mod.rs:23416 — crates/ibcmd-dump/src/mssql_dump/mod.rs:23416-23458 | crates/ibcmd-dump/src/mssql_dump/mod.rs:23746-23790 — These two members are one piece of code written twice and then edited apart: 43 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (43 corresponding lines) crates/ibcmd-metadata-model/src/metadata_model/export.rs:205 — crates/ibcmd-metadata-model/src/metadata_model/export.rs:205-250 | crates/ibcmd-metadata-model/src/metadata_model/export.rs:253-295 — These two members are one piece of code written twice and then edited apart: 43 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copy of a member (46 corresponding lines) · ×3
  • Edited copy of a member (46 corresponding lines) crates/ibcmd-xml/src/metadata/constant.rs:305 — crates/ibcmd-xml/src/metadata/constant.rs:305-353 | crates/ibcmd-xml/src/metadata/session_parameter.rs:177-222 — These two members are one piece of code written twice and then edited apart: 46 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (46 corresponding lines) crates/ibcmd-xml/src/metadata/business_objects.rs:744 — crates/ibcmd-xml/src/metadata/business_objects.rs:744-798 | crates/ibcmd-xml/src/metadata/utility_objects.rs:423-468 — These two members are one piece of code written twice and then edited apart: 46 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (46 corresponding lines) REDACTED:3164 — REDACTED:3164-3214 | REDACTED:3258-3303 — These two members are one piece of code written twice and then edited apart: 46 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copy of a member (41 corresponding lines) · ×3
  • Edited copy of a member (41 corresponding lines) crates/ibcmd-moxel/src/lib.rs:8645 — crates/ibcmd-moxel/src/lib.rs:8645-8688 | crates/ibcmd-moxel/src/lib.rs:8875-8915 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (41 corresponding lines) REDACTED:3114 — REDACTED:3114-3162 | REDACTED:3216-3256 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (41 corresponding lines) src/dropin/extension.rs:80 — src/dropin/extension.rs:80-122 | src/dropin/extension.rs:124-164 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copy of a member (47 corresponding lines) · ×3
  • Edited copy of a member (47 corresponding lines) crates/ibcmd-form-writer/src/lib.rs:17800 — crates/ibcmd-form-writer/src/lib.rs:17800-17846 | crates/ibcmd-form-writer/src/lib.rs:18120-18173 — These two members are one piece of code written twice and then edited apart: 47 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (47 corresponding lines) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:2674 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:2674-2729 | crates/ibcmd-compiler-families/src/compiler/families/utility.rs:1343-1389 — These two members are one piece of code written twice and then edited apart: 47 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (47 corresponding lines) crates/ibcmd-v8/src/format15.rs:113 — crates/ibcmd-v8/src/format15.rs:113-159 | crates/ibcmd-v8/src/format16.rs:130-196 — These two members are one piece of code written twice and then edited apart: 47 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copies of one member (3 members, 13+ corresponding lines) · ×3
  • Edited copies of one member (3 members, 13+ corresponding lines) src/dropin/mod.rs:704 — src/dropin/mod.rs:704-719 | src/dropin/mod.rs:796-808 | src/dropin/mod.rs:810-822 — 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' 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.
  • Edited copies of one member (3 members, 13+ corresponding lines) crates/ibcmd-form-body/src/dcs.rs:2663 — crates/ibcmd-form-body/src/dcs.rs:2663-2678 | crates/ibcmd-form-body/src/dcs.rs:2684-2696 | crates/ibcmd-form-body/src/dcs.rs:2844-2856 — 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' 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.
  • Edited copies of one member (3 members, 13+ corresponding lines) crates/ibcmd-form-writer/src/form_chart.rs:1856 — crates/ibcmd-form-writer/src/form_chart.rs:1856-1868 | crates/ibcmd-form-writer/src/form_planner.rs:457-474 | crates/ibcmd-metadata-blob/src/interface_assets.rs:226-238 — 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' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart.
D4 · Code Duplication · Edited copies of one member (3 members, 17+ corresponding lines) · ×3
  • Edited copies of one member (3 members, 17+ corresponding lines) crates/ibcmd-dump/src/mssql_dump/mod.rs:17011 — crates/ibcmd-dump/src/mssql_dump/mod.rs:17011-17028 | crates/ibcmd-dump/src/mssql_dump/mod.rs:35290-35306 | crates/ibcmd-dump/src/mssql_dump/mod.rs:35478-35495 — These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 17 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' 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.
  • Edited copies of one member (3 members, 17+ corresponding lines) crates/ibcmd-dump/src/mssql_dump/mod.rs:9123 — crates/ibcmd-dump/src/mssql_dump/mod.rs:9123-9143 | crates/ibcmd-dump/src/mssql_dump/mod.rs:14834-14850 | crates/ibcmd-dump/src/mssql_dump/refs.rs:3952-3970 — These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 17 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' 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.
  • Edited copies of one member (3 members, 17+ corresponding lines) crates/ibcmd-core/src/capability.rs:264 — crates/ibcmd-core/src/capability.rs:264-281 | crates/ibcmd-core/src/migration/step.rs:226-242 | crates/ibcmd-core/src/migration/step.rs:246-263 — These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 17 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart.
D4 · Code Duplication · Edited copies of one member (4 members, 13+ corresponding lines) · ×3
  • Edited copies of one member (4 members, 13+ corresponding lines) crates/ibcmd-form-body/src/form_body.rs:2982 — crates/ibcmd-form-body/src/form_body.rs:2982-2994 | crates/ibcmd-form-body/src/form_body.rs:2996-3008 | crates/ibcmd-form-body/src/form_body.rs:3059-3072 | crates/ibcmd-form-body/src/form_body.rs:3144-3162 — These 4 members are one piece of code written 4 times and then edited apart: every two of them correspond over at least 13 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' 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.
  • Edited copies of one member (4 members, 13+ corresponding lines) crates/ibcmd-dump/src/mssql_dump/extension/project.rs:93 — crates/ibcmd-dump/src/mssql_dump/extension/project.rs:93-105 | crates/ibcmd-form-body/src/dcs.rs:3746-3758 | crates/ibcmd-xml/src/dcs_schema.rs:126-138 | crates/ibcmd-xml/src/dcs_schema.rs:2808-2823 — These 4 members are one piece of code written 4 times and then edited apart: every two of them correspond over at least 13 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' 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.
  • Edited copies of one member (4 members, 13+ corresponding lines) crates/ibcmd-dump/src/mssql_dump/mod.rs:35046 — crates/ibcmd-dump/src/mssql_dump/mod.rs:35046-35059 | crates/ibcmd-form-body/src/form_body.rs:5465-5480 | crates/ibcmd-form-body/src/form_body.rs:10373-10385 | crates/ibcmd-form-body/src/form_body.rs:10418-10430 — These 4 members are one piece of code written 4 times and then edited apart: every two of them correspond over at least 13 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 4 times and the copies will drift further apart.
D4 · Code Duplication · Edited copies of one member (3 members, 6+ corresponding lines) · ×3
  • Edited copies of one member (3 members, 6+ corresponding lines) crates/ibcmd-form-body/src/form_body.rs:18560 — crates/ibcmd-form-body/src/form_body.rs:18560-18566 | crates/ibcmd-form-body/src/form_body.rs:18568-18573 | crates/ibcmd-form-body/src/form_body.rs:23216-23221 — 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' 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.
  • Edited copies of one member (3 members, 6+ corresponding lines) crates/ibcmd-dump/src/mssql_dump/extension/form.rs:68 — crates/ibcmd-dump/src/mssql_dump/extension/form.rs:68-73 | crates/ibcmd-dump/src/mssql_dump/extension/project.rs:117-122 | src/mssql_extension_load.rs:1175-1181 — 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' 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.
  • Edited copies of one member (3 members, 6+ corresponding lines) crates/ibcmd-xml/src/metadata/constant.rs:410 — crates/ibcmd-xml/src/metadata/constant.rs:410-415 | crates/ibcmd-xml/src/metadata/language.rs:300-305 | crates/ibcmd-xml/src/metadata/services.rs:2480-2485 — 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' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart.
D4 · Code Duplication · Duplicated block (22 lines × 2) · ×3
  • Duplicated block (22 lines × 2) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:894 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:894-915 | crates/ibcmd-compiler-families/src/compiler/families/utility.rs:569-590 — before extracting anything, compare `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs` and `crates/ibcmd-compiler-families/src/compiler/families/utility.rs` as WHOLE FILES: this scan already matched 65 separate duplicated blocks between them, totalling at least 934 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:894` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (22 lines × 2) REDACTED:1931 — REDACTED:1931-1952 | crates/ibcmd-config-apply/src/mssql_config_apply/mod.rs:1930-1951 — before extracting anything, compare `REDACTED` and `crates/ibcmd-config-apply/src/mssql_config_apply/mod.rs` as WHOLE FILES: this scan already matched 5 separate duplicated blocks between them, totalling at least 61 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `REDACTED:1931` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (22 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:25350 — crates/ibcmd-dump/src/mssql_dump/mod.rs:25350-25371 | crates/ibcmd-dump/src/mssql_dump/mod.rs:25759-25780 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:25350` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (16–17 lines × 2) · ×3
  • Duplicated block (16–17 lines × 2) crates/ibcmd-form-body/src/layout_8_5_1.rs:102 — crates/ibcmd-form-body/src/layout_8_5_1.rs:102-118 | crates/ibcmd-form-writer/src/form/load_8_5_1.rs:1125-1140 — before extracting anything, compare `crates/ibcmd-form-body/src/layout_8_5_1.rs` and `crates/ibcmd-form-writer/src/form/load_8_5_1.rs` as WHOLE FILES: this scan already matched 3 separate duplicated blocks between them, totalling at least 55 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 `crates/ibcmd-form-body/src/layout_8_5_1.rs:102` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (16–17 lines × 2) src/source_audit.rs:2020 — src/source_audit.rs:2020-2036 | src/source_audit.rs:2348-2363 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `src/source_audit.rs:2020` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (16–17 lines × 2) crates/ibcmd-xml/src/dcs.rs:918 — crates/ibcmd-xml/src/dcs.rs:918-933 | crates/ibcmd-xml/src/dcs.rs:1347-1363 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-xml/src/dcs.rs:918` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
D4 · Code Duplication · Duplicated block (16 lines × 3) · ×3
  • Duplicated block (16 lines × 3) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:3506 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:3506-3521 | crates/ibcmd-compiler-families/src/compiler/families/commands.rs:1064-1079 | crates/ibcmd-compiler-families/src/compiler/families/utility.rs:1843-1858 — before extracting anything, compare `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs` and `crates/ibcmd-compiler-families/src/compiler/families/commands.rs` as WHOLE FILES: this scan already matched 3 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. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. 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 `return` inside it is the body's own exit and keeps its meaning in the moved unit.
  • Duplicated block (16 lines × 3) crates/ibcmd-dump/src/mssql_dump/forms.rs:173 — crates/ibcmd-dump/src/mssql_dump/forms.rs:173-188 | crates/ibcmd-dump/src/mssql_dump/mod.rs:33451-33466 | crates/ibcmd-dump/src/mssql_dump/mod.rs:33881-33896 — before extracting anything, compare `crates/ibcmd-dump/src/mssql_dump/forms.rs` and `crates/ibcmd-dump/src/mssql_dump/mod.rs` as WHOLE FILES: this scan already matched 6 separate duplicated blocks between them, totalling at least 99 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/forms.rs:173` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (16 lines × 3) crates/ibcmd-dump/src/mssql_dump/mod.rs:22416 — crates/ibcmd-dump/src/mssql_dump/mod.rs:22416-22431 | crates/ibcmd-dump/src/mssql_dump/mod.rs:24492-24507 | crates/ibcmd-dump/src/mssql_dump/mod.rs:24766-24781 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:22416` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (15–16 lines × 2) · ×3
  • Duplicated block (15–16 lines × 2) crates/ibcmd-form-body/src/record_text.rs:150 — crates/ibcmd-form-body/src/record_text.rs:150-164 | crates/ibcmd-form-body/src/record_text.rs:191-206 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-form-body/src/record_text.rs:150` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (15–16 lines × 2) crates/ibcmd-xml/src/metadata/constant.rs:449 — crates/ibcmd-xml/src/metadata/constant.rs:449-463 | crates/ibcmd-xml/src/metadata/session_parameter.rs:360-375 — before extracting anything, compare `crates/ibcmd-xml/src/metadata/constant.rs` and `crates/ibcmd-xml/src/metadata/session_parameter.rs` as WHOLE FILES: this scan already matched 7 separate duplicated blocks between them, totalling at least 57 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-xml/src/metadata/session_parameter.rs:360` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
  • Duplicated block (15–16 lines × 2) src/commands/cf.rs:846 — src/commands/cf.rs:846-861 | src/commands/cf.rs:987-1001 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `src/commands/cf.rs:846` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (13 lines × 6) · ×3
  • Duplicated block (13 lines × 6) crates/ibcmd-dump/src/mssql_dump/forms.rs:453 — crates/ibcmd-dump/src/mssql_dump/forms.rs:453-465 | crates/ibcmd-dump/src/mssql_dump/mod.rs:37291-37303 | crates/ibcmd-dump/src/mssql_dump/mod.rs:37361-37373 | crates/ibcmd-dump/src/mssql_dump/mod.rs:39269-39281 | crates/ibcmd-dump/src/mssql_dump/mod.rs:42397-42409 | crates/ibcmd-dump/src/mssql_dump/mod.rs:42449-42461 — before extracting anything, compare `crates/ibcmd-dump/src/mssql_dump/forms.rs` and `crates/ibcmd-dump/src/mssql_dump/mod.rs` as WHOLE FILES: this scan already matched 6 separate duplicated blocks between them, totalling at least 99 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/forms.rs:453` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (13 lines × 6) REDACTED:3307 — REDACTED:3307-3319 | REDACTED:3354-3366 | REDACTED:3386-3398 | REDACTED:3472-3484 | REDACTED:3548-3560 | REDACTED:3592-3604 — all 6 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Note first that the copies are not typed on the same thing: the declarations holding them bind `args` to `&MssqlStageCommonModuleArgs` in one and `&MssqlStageCommonModulesArgs` in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH — their common supertype where they have one, or a new abstraction over them where they do not — and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, `REDACTED:3589` calls `is_empty`, `Err` and `REDACTED:3385` does not — after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
  • Duplicated block (13 lines × 6) crates/ibcmd-compiler-families/src/compiler/families/services.rs:1451 — crates/ibcmd-compiler-families/src/compiler/families/services.rs:1451-1463 | crates/ibcmd-compiler-families/src/compiler/families/services.rs:1529-1541 | crates/ibcmd-compiler-families/src/compiler/families/services.rs:1695-1707 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:1433-1445 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:1709-1721 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:1818-1830 — before extracting anything, compare `crates/ibcmd-compiler-families/src/compiler/families/services.rs` and `crates/ibcmd-compiler-families/src/compiler/families/simple.rs` as WHOLE FILES: this scan already matched 36 separate duplicated blocks between them, totalling at least 406 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/services.rs:1451` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (12–13 lines × 2) · ×3
  • Duplicated block (12–13 lines × 2) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:778 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:778-789 | crates/ibcmd-compiler-families/src/compiler/families/utility.rs:463-475 — before extracting anything, compare `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs` and `crates/ibcmd-compiler-families/src/compiler/families/utility.rs` as WHOLE FILES: this scan already matched 65 separate duplicated blocks between them, totalling at least 934 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:778` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (12–13 lines × 2) crates/ibcmd-dump/src/mssql_dump/role_rights.rs:683 — crates/ibcmd-dump/src/mssql_dump/role_rights.rs:683-695 | crates/ibcmd-dump/src/mssql_dump/role_rights.rs:718-729 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, `crates/ibcmd-dump/src/mssql_dump/role_rights.rs:680` calls `Some` and `crates/ibcmd-dump/src/mssql_dump/role_rights.rs:717` does not — after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
  • Duplicated block (12–13 lines × 2) src/plan.rs:790 — src/plan.rs:790-802 | src/plan.rs:1018-1029 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `src/plan.rs:790` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
D4 · Code Duplication · Duplicated block (10 lines × 4) · ×3
  • Duplicated block (10 lines × 4) src/dropin/mod.rs:360 — src/dropin/mod.rs:360-369 | src/dropin/mod.rs:396-405 | src/dropin/mod.rs:456-465 | src/dropin/mod.rs:780-789 — all 4 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited.
  • Duplicated block (10 lines × 4) src/mssql_extension_export.rs:54 — src/mssql_extension_export.rs:54-63 | src/mssql_extension_load.rs:112-121 | src/mssql_extension_load.rs:174-183 | src/mssql_extension_load.rs:465-474 — before extracting anything, compare `src/mssql_extension_export.rs` and `src/mssql_extension_load.rs` as WHOLE FILES: this scan already matched 4 separate duplicated blocks between them, totalling at least 42 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Note first that the copies are not typed on the same thing: the declarations holding them bind `args` to `&MssqlDumpExtensionArgs` in one and `&MssqlLoadExtensionArgs` in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH — their common supertype where they have one, or a new abstraction over them where they do not — and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract.
  • Duplicated block (10 lines × 4) crates/ibcmd-1c-vocab/src/type_xml.rs:67 — crates/ibcmd-1c-vocab/src/type_xml.rs:67-77 | crates/ibcmd-1c-vocab/src/type_xml.rs:145-154 | crates/ibcmd-dump/src/mssql_dump/mod.rs:44645-44655 | crates/ibcmd-dump/src/mssql_dump/source_assets.rs:5706-5715 — before extracting anything, compare `crates/ibcmd-1c-vocab/src/type_xml.rs` and `crates/ibcmd-dump/src/mssql_dump/mod.rs` as WHOLE FILES: this scan already matched 6 separate duplicated blocks between them, totalling at least 118 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. 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 `crates/ibcmd-1c-vocab/src/type_xml.rs:67` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (8–9 lines × 2) · ×3
  • Duplicated block (8–9 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:23227 — crates/ibcmd-dump/src/mssql_dump/mod.rs:23227-23234 | crates/ibcmd-dump/src/mssql_dump/mod.rs:23606-23614 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:23606` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (8–9 lines × 2) crates/ibcmd-form-writer/src/lib.rs:7440 — crates/ibcmd-form-writer/src/lib.rs:7440-7447 | crates/ibcmd-metadata-blob/src/lib.rs:2469-2477 — before extracting anything, compare `crates/ibcmd-form-writer/src/lib.rs` and `crates/ibcmd-metadata-blob/src/lib.rs` as WHOLE FILES: this scan already matched 5 separate duplicated blocks between them, totalling at least 33 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 `crates/ibcmd-form-writer/src/lib.rs:7440` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (8–9 lines × 2) REDACTED:1038 — REDACTED:1038-1045 | REDACTED:1078-1086 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `REDACTED:1038` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
D4 · Code Duplication · Duplicated block (7–8 lines × 4) · ×3
  • Duplicated block (7–8 lines × 4) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:2923 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:2923-2930 | crates/ibcmd-compiler-families/src/compiler/families/commands.rs:1239-1245 | crates/ibcmd-compiler-families/src/compiler/families/modules.rs:447-453 | crates/ibcmd-compiler-families/src/compiler/families/utility.rs:1502-1509 — before extracting anything, compare `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs` and `crates/ibcmd-compiler-families/src/compiler/families/commands.rs` as WHOLE FILES: this scan already matched 3 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. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:2923` it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows — the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members' bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run — a one-line delegation has no helper inside it to lift — so generate the run from the set it enumerates, or accept it and keep each member's own documentation with it. The `return` at the foot of the matched lines is the enclosing body's own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that `return` occupied — no decision has to be handed back and re-acted on. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
  • Duplicated block (7–8 lines × 4) crates/ibcmd-metadata-blob/src/lib.rs:6589 — crates/ibcmd-metadata-blob/src/lib.rs:6589-6596 | crates/ibcmd-metadata-blob/src/lib.rs:6640-6646 | crates/ibcmd-metadata-blob/src/lib.rs:6673-6679 | crates/ibcmd-metadata-blob/src/lib.rs:6748-6754 — all 4 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Note first that the copies are not typed on the same thing: the declarations holding them bind `properties` to `&ConstantXmlProperties` in one and `&DefinedTypeXmlProperties` in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH — their common supertype where they have one, or a new abstraction over them where they do not — and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract.
  • Duplicated block (7–8 lines × 4) _onecdec/big_compare.py:30 — _onecdec/big_compare.py:30-37 | _onecdec/corpus_compare.py:16-22 | _onecdec/exact_compare.py:27-34 | _onecdec/verify_load.py:39-46 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from all 4 call sites, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
D4 · Code Duplication · Duplicated block (7–8 lines × 2) · ×3
  • Duplicated block (7–8 lines × 2) crates/ibcmd-compiler-families/src/compiler/families/business_object/register_native.rs:940 — crates/ibcmd-compiler-families/src/compiler/families/business_object/register_native.rs:940-947 | crates/ibcmd-compiler-families/src/compiler/families/business_object/register_native.rs:1092-1098 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/business_object/register_native.rs:940` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (7–8 lines × 2) crates/ibcmd-dump/src/mssql_dump/extension/form.rs:314 — crates/ibcmd-dump/src/mssql_dump/extension/form.rs:314-320 | crates/ibcmd-dump/src/mssql_dump/extension/form.rs:384-391 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/extension/form.rs:314` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
  • Duplicated block (7–8 lines × 2) crates/ibcmd-form-body/src/form_body.rs:41307 — crates/ibcmd-form-body/src/form_body.rs:41307-41314 | crates/ibcmd-form-body/src/form_body.rs:41405-41411 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
D6 · Cohesion (LCOM4) · Low cohesion · ×3
  • Low cohesion: CanonicalValue (LCOM4 6) crates/ibcmd-core/src/value.rs:565 — CanonicalValue's methods fall into 6 groups that share no field and call none of each other, against a bar of more than 3 for this run (LCOM4, configurable — your repository's bar is the one quoted here). Each group is a set of methods reachable from one another through shared fields or direct calls, so 6 groups means the type has that many internally-connected clusters with nothing tying them together. Types whose shape makes a high count expected — and which would otherwise dominate this list — are excluded before this row is raised, so this is a genuine split candidate rather than a metric reading. It is still a shape, not a defect: confirm the groups match responsibilities you can name before splitting.
  • Low cohesion: FormCheckBoxFieldSchema (LCOM4 5) crates/ibcmd-form-schema/src/lib.rs:3440 — FormCheckBoxFieldSchema's methods fall into 5 groups that share no field and call none of each other, against a bar of more than 3 for this run (LCOM4, configurable — your repository's bar is the one quoted here). Each group is a set of methods reachable from one another through shared fields or direct calls, so 5 groups means the type has that many internally-connected clusters with nothing tying them together. Types whose shape makes a high count expected — and which would otherwise dominate this list — are excluded before this row is raised, so this is a genuine split candidate rather than a metric reading. It is still a shape, not a defect: confirm the groups match responsibilities you can name before splitting.
  • Low cohesion: MainActivationPlan (LCOM4 4) REDACTED:160 — MainActivationPlan's methods fall into 4 groups that share no field and call none of each other, against a bar of more than 3 for this run (LCOM4, configurable — your repository's bar is the one quoted here). Each group is a set of methods reachable from one another through shared fields or direct calls, so 4 groups means the type has that many internally-connected clusters with nothing tying them together. Types whose shape makes a high count expected — and which would otherwise dominate this list — are excluded before this row is raised, so this is a genuine split candidate rather than a metric reading. It is still a shape, not a defect: confirm the groups match responsibilities you can name before splitting.
D1 · Cyclomatic Complexity · ibcmd_1c_vocab · ×2
  • ibcmd_1c_vocab::role_rights::role_standard_attribute_descriptor (cyclomatic 109) crates/ibcmd-1c-vocab/src/role_rights.rs:138 — ibcmd_1c_vocab::role_rights::role_standard_attribute_descriptor has cyclomatic complexity 109 (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 — the same kind of value, with no behaviour of its own — 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.
  • ibcmd_1c_vocab::commands::parse_common_command_picture_value (cyclomatic 27) crates/ibcmd-1c-vocab/src/commands.rs:140 — ibcmd_1c_vocab::commands::parse_common_command_picture_value has cyclomatic complexity 27 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · ibcmd_core · ×2
  • ibcmd_core::dcs::validate_settings (cyclomatic 44) crates/ibcmd-core/src/dcs.rs:1270 — ibcmd_core::dcs::validate_settings has cyclomatic complexity 44 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
  • ibcmd_core::validate::validate_ownership_cycles (cyclomatic 16) crates/ibcmd-core/src/validate.rs:268 — ibcmd_core::validate::validate_ownership_cycles 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.
D1 · Cyclomatic Complexity · read_compact9_recovery.read_live (cyclomatic 22) · ×2
  • read_compact9_recovery.read_live (cyclomatic 22) docs/apply/evidence/live-gate/compact9-runtime-preexec/read_compact9_recovery.py:24 — read_compact9_recovery.read_live has cyclomatic complexity 22 (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.
  • read_compact9_recovery.read_live (cyclomatic 22) docs/apply/evidence/live-gate/compact9-startup-preexec-v2/read_compact9_recovery.py:24 — read_compact9_recovery.read_live has cyclomatic complexity 22 (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.
D1 · Cyclomatic Complexity · Plan · ×2
  • Plan::phase_sql (cyclomatic 19) REDACTED:191 — Plan::phase_sql has cyclomatic complexity 19 (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.
  • Plan::statements (cyclomatic 18) REDACTED:2509 — Plan::statements has cyclomatic complexity 18 (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.
D1 · Cyclomatic Complexity · ibcmd_mssql_extensions · ×2
  • ibcmd_mssql_extensions::mssql_extension_stage::validate_manifest_with_format_gate (cyclomatic 17) REDACTED:324 — ibcmd_mssql_extensions::mssql_extension_stage::validate_manifest_with_format_gate 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.
  • ibcmd_mssql_extensions::mssql_extension_stage::split_top_level_records (cyclomatic 16) REDACTED:1019 — ibcmd_mssql_extensions::mssql_extension_stage::split_top_level_records 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.
D1 · Cyclomatic Complexity · read_compact9_recovery.verify (cyclomatic 17) · ×2
  • read_compact9_recovery.verify (cyclomatic 17) docs/apply/evidence/live-gate/compact9-runtime-preexec/read_compact9_recovery.py:61 — read_compact9_recovery.verify 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.
  • read_compact9_recovery.verify (cyclomatic 17) docs/apply/evidence/live-gate/compact9-startup-preexec-v2/read_compact9_recovery.py:61 — read_compact9_recovery.verify 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.
D2 · Cognitive Complexity · Plan · ×2
  • Plan::statements (cognitive 42) REDACTED:2509 — Plan::statements has cognitive complexity 42 (threshold 15). Drivers by points: loops 13 (28 pts), if/else 7 (14 pts) (nesting depth added 22). 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.
  • Plan::phase_sql (cognitive 25) REDACTED:191 — Plan::phase_sql has cognitive complexity 25 (threshold 15). Drivers by points: loops 14 (17 pts), if/else 4 (8 pts) (nesting depth added 7). 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.
D2 · Cognitive Complexity · ibcmd_1c_vocab · ×2
  • ibcmd_1c_vocab::commands::parse_common_command_picture_value (cognitive 32) crates/ibcmd-1c-vocab/src/commands.rs:140 — ibcmd_1c_vocab::commands::parse_common_command_picture_value has cognitive complexity 32 (threshold 15). Drivers by points: if/else 25 (31 pts), boolean chains 1 (nesting depth added 6). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition.
  • ibcmd_1c_vocab::role_rights::role_standard_attribute_descriptor (cognitive 27) crates/ibcmd-1c-vocab/src/role_rights.rs:138 — ibcmd_1c_vocab::role_rights::role_standard_attribute_descriptor has cognitive complexity 27 (threshold 15). Drivers by points: match/switch 14 (27 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.
D2 · Cognitive Complexity · ReferenceIndexes · ×2
  • ReferenceIndexes::build (cognitive 29) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:759 — ReferenceIndexes::build has cognitive complexity 29 (threshold 15). Drivers by points: if/else 9 (23 pts), loops 3 (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.
  • ReferenceIndexes::build (cognitive 17) crates/ibcmd-compiler-families/src/compiler/families/utility.rs:444 — ReferenceIndexes::build has cognitive complexity 17 (threshold 15). Drivers by points: if/else 6 (11 pts), loops 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.
D2 · Cognitive Complexity · read_compact9_recovery.read_live (cognitive 29) · ×2
  • read_compact9_recovery.read_live (cognitive 29) docs/apply/evidence/live-gate/compact9-runtime-preexec/read_compact9_recovery.py:24 — read_compact9_recovery.read_live has cognitive complexity 29 (threshold 15). Drivers by points: boolean chains 11, ternaries 4 (10 pts), loops 4 (5 pts), if/else 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.
  • read_compact9_recovery.read_live (cognitive 29) docs/apply/evidence/live-gate/compact9-startup-preexec-v2/read_compact9_recovery.py:24 — read_compact9_recovery.read_live has cognitive complexity 29 (threshold 15). Drivers by points: boolean chains 11, ternaries 4 (10 pts), loops 4 (5 pts), if/else 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.
D2 · Cognitive Complexity · ibcmd_cf · ×2
  • ibcmd_cf::overlay::preflight (cognitive 24) crates/ibcmd-cf/src/overlay.rs:515 — ibcmd_cf::overlay::preflight has cognitive complexity 24 (threshold 15). Drivers by points: if/else 9 (15 pts), match/switch 3 (7 pts), loops 2 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • ibcmd_cf::writer::project_entries (cognitive 17) crates/ibcmd-cf/src/writer.rs:272 — ibcmd_cf::writer::project_entries has cognitive complexity 17 (threshold 15). Drivers by points: if/else 7 (15 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.
D2 · Cognitive Complexity · read_compact9_recovery.verify (cognitive 23) · ×2
  • read_compact9_recovery.verify (cognitive 23) docs/apply/evidence/live-gate/compact9-runtime-preexec/read_compact9_recovery.py:61 — read_compact9_recovery.verify has cognitive complexity 23 (threshold 15). Drivers by points: ternaries 5 (10 pts), boolean chains 7, loops 3 (4 pts), if/else 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.
  • read_compact9_recovery.verify (cognitive 23) docs/apply/evidence/live-gate/compact9-startup-preexec-v2/read_compact9_recovery.py:61 — read_compact9_recovery.verify has cognitive complexity 23 (threshold 15). Drivers by points: ternaries 5 (10 pts), boolean chains 7, loops 3 (4 pts), if/else 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.
D2 · Cognitive Complexity · MigrationExecutor · ×2
  • MigrationExecutor::execute (cognitive 22) crates/ibcmd-core/src/migration/executor.rs:104 — MigrationExecutor::execute has cognitive complexity 22 (threshold 15). Drivers by points: if/else 8 (15 pts), match/switch 3 (6 pts), loops 1 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • MigrationExecutor::validate_plan (cognitive 19) crates/ibcmd-core/src/migration/executor.rs:413 — MigrationExecutor::validate_plan has cognitive complexity 19 (threshold 15). Drivers by points: if/else 8 (14 pts), boolean chains 3, loops 2 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · ibcmd_mssql_extensions · ×2
  • ibcmd_mssql_extensions::mssql_extension_stage::split_top_level_records (cognitive 22) REDACTED:1019 — ibcmd_mssql_extensions::mssql_extension_stage::split_top_level_records has cognitive complexity 22 (threshold 15). Drivers by points: if/else 4 (10 pts), loops 3 (5 pts), boolean chains 4, match/switch 1 (3 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.
  • ibcmd_mssql_extensions::mssql_extension_stage::validate_manifest_with_format_gate (cognitive 17) REDACTED:324 — ibcmd_mssql_extensions::mssql_extension_stage::validate_manifest_with_format_gate has cognitive complexity 17 (threshold 15). Drivers by points: if/else 11 (12 pts), boolean chains 4, loops 1 (nesting depth added 1). To reduce it, split the body: this score is breadth rather than depth — many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D2 · Cognitive Complexity · NativeRuntime · ×2
  • NativeRuntime::stop_owned (cognitive 21) crates/ibcmd-mssql-live/src/mssql_managed_worker/native.rs:658 — NativeRuntime::stop_owned has cognitive complexity 21 (threshold 15). Drivers by points: if/else 8 (13 pts), loops 5, boolean chains 3 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • NativeRuntime::observe (cognitive 20) crates/ibcmd-mssql-live/src/mssql_managed_worker/native.rs:461 — NativeRuntime::observe has cognitive complexity 20 (threshold 15). Drivers by points: if/else 8 (12 pts), loops 5 (7 pts), boolean chains 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D29 · Static Analysis (SAST) · REDACTED
  • REDACTED
  • REDACTED
D4 · Code Duplication · Near-duplicate member pair (26 shared lines) · ×2
  • Near-duplicate member pair (26 shared lines) crates/ibcmd-metadata-blob/src/lib.rs:1961 — crates/ibcmd-metadata-blob/src/lib.rs:1961-2059 | crates/ibcmd-metadata-blob/src/lib.rs:5149-5214 — These two members are variants of one another: 26 of their lines are already reported as duplicated blocks below, spread through both bodies rather than gathered into one. Read them as a single construct written twice. The repair is at the members' grain — factor the shared pipeline into one implementation the two call with their differences as parameters or as an injected step, or, where the difference is systematic (sync against async, one transport against another), generate one from the other. Extracting the individual blocks below is not the same fix: it leaves the two bodies in place and the next edit still has to be made twice.
  • Near-duplicate member pair (26 shared lines) crates/ibcmd-metadata-model/src/metadata_model/audit.rs:135 — crates/ibcmd-metadata-model/src/metadata_model/audit.rs:135-204 | crates/ibcmd-metadata-model/src/metadata_model/export_audit.rs:132-251 — These two members are variants of one another: 26 of their lines are already reported as duplicated blocks below, spread through both bodies rather than gathered into one. Read them as a single construct written twice. The repair is at the members' grain — factor the shared pipeline into one implementation the two call with their differences as parameters or as an injected step, or, where the difference is systematic (sync against async, one transport against another), generate one from the other. Extracting the individual blocks below is not the same fix: it leaves the two bodies in place and the next edit still has to be made twice.
D4 · Code Duplication · Members sharing a duplicated core (7 members, 50+ identical tokens) · ×2
  • Members sharing a duplicated core (7 members, 50+ identical tokens) crates/ibcmd-compiler-families/src/compiler/families/form.rs:747 — crates/ibcmd-compiler-families/src/compiler/families/form.rs:747-770 | crates/ibcmd-compiler/src/compiler/bootstrap.rs:1846-1869 | crates/ibcmd-xml/src/dcs.rs:1773-1963 | crates/ibcmd-xml/src/dcs.rs:4024-4034 | crates/ibcmd-xml/src/metadata/configuration_mobile.rs:44-56 | crates/ibcmd-xml/src/metadata/configuration_v85_projection.rs:48-129 | crates/ibcmd-xml/src/metadata/external_data_source.rs:45-56 — These 7 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below — it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 7 times. The repair is at the members' grain — factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 7 times.
  • Members sharing a duplicated core (7 members, 50+ identical tokens) crates/ibcmd-xml/src/metadata/services.rs:1071 — crates/ibcmd-xml/src/metadata/services.rs:1071-1112 | crates/ibcmd-xml/src/metadata/services.rs:1116-1149 | crates/ibcmd-xml/src/metadata/services.rs:1236-1260 | crates/ibcmd-xml/src/metadata/services.rs:1264-1400 | crates/ibcmd-xml/src/metadata/services.rs:1404-1583 | crates/ibcmd-xml/src/metadata/services.rs:1587-1687 | crates/ibcmd-xml/src/metadata/services.rs:1691-1885 — These 7 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below — it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 7 times. The repair is at the members' grain — factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 7 times.
D4 · Code Duplication · Edited copy of a member (37 corresponding lines) · ×2
  • Edited copy of a member (37 corresponding lines) _onecdec/big_compare.py:41 — _onecdec/big_compare.py:41-77 | _onecdec/big_compare_v85.py:22-59 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (37 corresponding lines) crates/ibcmd-dump/src/mssql_dump/timing.rs:101 — crates/ibcmd-dump/src/mssql_dump/timing.rs:101-147 | crates/ibcmd-dump/src/mssql_dump/timing.rs:151-187 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copy of a member (69 corresponding lines) · ×2
  • Edited copy of a member (69 corresponding lines) crates/ibcmd-restructure-engine/src/restructure/catalog.rs:238 — crates/ibcmd-restructure-engine/src/restructure/catalog.rs:238-306 | crates/ibcmd-restructure-engine/src/restructure/object.rs:132-200 — These two members are one piece of code written twice and then edited apart: 69 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (69 corresponding lines) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:762 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:762-836 | crates/ibcmd-compiler-families/src/compiler/families/utility.rs:447-515 — These two members are one piece of code written twice and then edited apart: 69 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copy of a member (48 corresponding lines) · ×2
  • Edited copy of a member (48 corresponding lines) crates/ibcmd-form-writer/src/lib.rs:21442 — crates/ibcmd-form-writer/src/lib.rs:21442-21489 | crates/ibcmd-form-writer/src/lib.rs:21894-21956 — These two members are one piece of code written twice and then edited apart: 48 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (48 corresponding lines) REDACTED:96 — REDACTED:96-143 | REDACTED:444-491 — These two members are one piece of code written twice and then edited apart: 48 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copy of a member (55 corresponding lines) · ×2
  • Edited copy of a member (55 corresponding lines) crates/ibcmd-cf/src/bootstrap.rs:418 — crates/ibcmd-cf/src/bootstrap.rs:418-472 | crates/ibcmd-cf/src/writer.rs:653-708 — These two members are one piece of code written twice and then edited apart: 55 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (55 corresponding lines) crates/ibcmd-form-body/src/layout_8_5_1.rs:100 — crates/ibcmd-form-body/src/layout_8_5_1.rs:100-155 | crates/ibcmd-form-writer/src/form/load_8_5_1.rs:1123-1177 — These two members are one piece of code written twice and then edited apart: 55 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copy of a member (79 corresponding lines) · ×2
  • Edited copy of a member (79 corresponding lines) crates/ibcmd-compiler-families/src/compiler/families/services.rs:131 — crates/ibcmd-compiler-families/src/compiler/families/services.rs:131-213 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:125-203 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (79 corresponding lines) crates/ibcmd-dump/src/mssql_dump/mod.rs:40270 — crates/ibcmd-dump/src/mssql_dump/mod.rs:40270-40348 | crates/ibcmd-dump/src/mssql_dump/mod.rs:40961-41043 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copy of a member (57 corresponding lines) · ×2
  • Edited copy of a member (57 corresponding lines) crates/ibcmd-form-writer/src/lib.rs:7439 — crates/ibcmd-form-writer/src/lib.rs:7439-7495 | crates/ibcmd-metadata-blob/src/lib.rs:2468-2557 — These two members are one piece of code written twice and then edited apart: 57 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (57 corresponding lines) src/storage_map.rs:446 — src/storage_map.rs:446-507 | src/storage_map.rs:509-565 — These two members are one piece of code written twice and then edited apart: 57 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copy of a member (40 corresponding lines) · ×2
  • Edited copy of a member (40 corresponding lines) crates/ibcmd-xml/src/metadata/services.rs:851 — crates/ibcmd-xml/src/metadata/services.rs:851-890 | crates/ibcmd-xml/src/metadata/session_parameter.rs:121-175 — These two members are one piece of code written twice and then edited apart: 40 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (40 corresponding lines) src/source.rs:46 — src/source.rs:46-85 | src/source.rs:128-167 — These two members are one piece of code written twice and then edited apart: 40 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copy of a member (34 corresponding lines) · ×2
  • Edited copy of a member (34 corresponding lines) crates/ibcmd-metadata-model/src/metadata_model/objects_export.rs:1414 — crates/ibcmd-metadata-model/src/metadata_model/objects_export.rs:1414-1459 | crates/ibcmd-metadata-model/src/metadata_model/registers_export.rs:392-425 — These two members are one piece of code written twice and then edited apart: 34 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (34 corresponding lines) crates/ibcmd-1c-text/src/fields.rs:97 — crates/ibcmd-1c-text/src/fields.rs:97-134 | crates/ibcmd-1c-text/src/fields.rs:144-177 — These two members are one piece of code written twice and then edited apart: 34 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copies of one member (3 members, 46+ corresponding lines) · ×2
  • Edited copies of one member (3 members, 46+ corresponding lines) crates/ibcmd-dump/src/mssql_dump/mod.rs:22852 — crates/ibcmd-dump/src/mssql_dump/mod.rs:22852-22897 | crates/ibcmd-dump/src/mssql_dump/mod.rs:23813-23862 | crates/ibcmd-dump/src/mssql_dump/mod.rs:24081-24129 — These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 46 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart.
  • Edited copies of one member (3 members, 46+ corresponding lines) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:487 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:487-544 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:883-959 | crates/ibcmd-compiler-families/src/compiler/families/utility.rs:263-308 — These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 46 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart.
D4 · Code Duplication · Edited copy of a member (49 corresponding lines) · ×2
  • Edited copy of a member (49 corresponding lines) src/mssql_managed_worker/cli.rs:478 — src/mssql_managed_worker/cli.rs:478-533 | src/mssql_managed_worker/cli.rs:537-585 — These two members are one piece of code written twice and then edited apart: 49 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (49 corresponding lines) crates/ibcmd-dump/src/mssql_dump/mod.rs:29220 — crates/ibcmd-dump/src/mssql_dump/mod.rs:29220-29273 | crates/ibcmd-dump/src/mssql_dump/mod.rs:29386-29434 — These two members are one piece of code written twice and then edited apart: 49 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copies of one member (3 members, 24+ corresponding lines) · ×2
  • Edited copies of one member (3 members, 24+ corresponding lines) crates/ibcmd-form-body/src/form_body.rs:9442 — crates/ibcmd-form-body/src/form_body.rs:9442-9465 | crates/ibcmd-form-body/src/form_body.rs:9470-9497 | crates/ibcmd-form-body/src/form_body.rs:9557-9596 — These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 24 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart.
  • Edited copies of one member (3 members, 24+ corresponding lines) crates/ibcmd-dump/src/mssql_dump/mod.rs:22905 — crates/ibcmd-dump/src/mssql_dump/mod.rs:22905-22933 | crates/ibcmd-dump/src/mssql_dump/mod.rs:24158-24183 | crates/ibcmd-dump/src/mssql_dump/mod.rs:24192-24215 — These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 24 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart.
D4 · Code Duplication · Edited copies of one member (3 members, 18+ corresponding lines) · ×2
  • Edited copies of one member (3 members, 18+ corresponding lines) crates/ibcmd-dump/src/mssql_dump/upgrade.rs:63 — crates/ibcmd-dump/src/mssql_dump/upgrade.rs:63-80 | crates/ibcmd-dump/src/mssql_dump/upgrade.rs:151-172 | crates/ibcmd-dump/src/mssql_dump/upgrade.rs:419-443 — 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' 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.
  • Edited copies of one member (3 members, 18+ corresponding lines) crates/ibcmd-v8/src/block.rs:388 — crates/ibcmd-v8/src/block.rs:388-405 | crates/ibcmd-v8/src/block.rs:663-680 | crates/ibcmd-v8/src/reader.rs:895-912 — 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' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart.
D4 · Code Duplication · Edited copies of one member (3 members, 30+ corresponding lines) · ×2
  • Edited copies of one member (3 members, 30+ corresponding lines) crates/ibcmd-compiler-families/src/compiler/families/assets.rs:1458 — crates/ibcmd-compiler-families/src/compiler/families/assets.rs:1458-1493 | crates/ibcmd-compiler-families/src/compiler/families/commands.rs:1334-1368 | crates/ibcmd-compiler-families/src/compiler/families/form.rs:1056-1085 — These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 30 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart.
  • Edited copies of one member (3 members, 30+ corresponding lines) crates/ibcmd-moxel/src/lib.rs:4057 — crates/ibcmd-moxel/src/lib.rs:4057-4086 | crates/ibcmd-moxel/src/lib.rs:4105-4134 | crates/ibcmd-moxel/src/lib.rs:4140-4172 — These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 30 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart.
D4 · Code Duplication · Edited copies of one member (4 members, 22+ corresponding lines) · ×2
  • Edited copies of one member (4 members, 22+ corresponding lines) crates/ibcmd-dump/src/mssql_dump/mod.rs:14977 — crates/ibcmd-dump/src/mssql_dump/mod.rs:14977-14998 | crates/ibcmd-dump/src/mssql_dump/mod.rs:17277-17303 | crates/ibcmd-dump/src/mssql_dump/mod.rs:19037-19061 | crates/ibcmd-dump/src/mssql_dump/mod.rs:33119-33151 — These 4 members are one piece of code written 4 times and then edited apart: every two of them correspond over at least 22 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 4 times and the copies will drift further apart.
  • Edited copies of one member (4 members, 22+ corresponding lines) crates/ibcmd-xml/src/dcs.rs:4610 — crates/ibcmd-xml/src/dcs.rs:4610-4636 | crates/ibcmd-xml/src/dcs.rs:4641-4667 | crates/ibcmd-xml/src/dcs.rs:4673-4694 | crates/ibcmd-xml/src/dcs.rs:4700-4723 — These 4 members are one piece of code written 4 times and then edited apart: every two of them correspond over at least 22 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 4 times and the copies will drift further apart.
D4 · Code Duplication · Edited copies of one member (3 members, 20+ corresponding lines) · ×2
  • Edited copies of one member (3 members, 20+ corresponding lines) _onecdec/make_old_root_fixtures.py:36 — _onecdec/make_old_root_fixtures.py:36-59 | _onecdec/make_upgrade_fixtures.py:119-142 | _onecdec/spike_adapter.py:13-32 — These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 20 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart.
  • Edited copies of one member (3 members, 20+ corresponding lines) crates/ibcmd-dump/src/mssql_dump/mod.rs:26229 — crates/ibcmd-dump/src/mssql_dump/mod.rs:26229-26248 | crates/ibcmd-dump/src/mssql_dump/mod.rs:27176-27195 | crates/ibcmd-dump/src/mssql_dump/mod.rs:31049-31069 — These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 20 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart.
D4 · Code Duplication · Edited copies of one member (3 members, 19+ corresponding lines) · ×2
  • Edited copies of one member (3 members, 19+ corresponding lines) crates/ibcmd-xml/src/dcs.rs:867 — crates/ibcmd-xml/src/dcs.rs:867-885 | crates/ibcmd-xml/src/dcs.rs:1317-1338 | crates/ibcmd-xml/src/dcs.rs:1509-1527 — These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 19 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart.
  • Edited copies of one member (3 members, 19+ corresponding lines) crates/ibcmd-form-body/src/form_body.rs:19008 — crates/ibcmd-form-body/src/form_body.rs:19008-19026 | crates/ibcmd-form-body/src/form_body.rs:20927-20948 | crates/ibcmd-form-body/src/form_body.rs:20956-20978 — These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 19 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart.
D4 · Code Duplication · Edited copies of one member (5 members, 12+ corresponding lines) · ×2
  • Edited copies of one member (5 members, 12+ corresponding lines) crates/ibcmd-1c-text/src/xml.rs:8 — crates/ibcmd-1c-text/src/xml.rs:8-20 | crates/ibcmd-1c-text/src/xml.rs:50-62 | crates/ibcmd-xml/src/metadata/children.rs:81-93 | crates/ibcmd-xml/src/metadata/constant.rs:1553-1566 | src/extension/root.rs:92-103 — 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' 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.
  • Edited copies of one member (5 members, 12+ corresponding lines) crates/ibcmd-core/src/migration/v2_20_to_v2_21.rs:225 — crates/ibcmd-core/src/migration/v2_20_to_v2_21.rs:225-240 | crates/ibcmd-core/src/migration/v2_20_to_v2_21.rs:245-259 | crates/ibcmd-core/src/migration/v2_21_to_v2_20.rs:397-412 | crates/ibcmd-core/src/migration/v2_21_to_v2_20.rs:419-433 | crates/ibcmd-core/src/migration/v2_21_to_v2_20.rs:438-449 — 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' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 5 times and the copies will drift further apart.
D4 · Code Duplication · Edited copies of one member (4 members, 6+ corresponding lines) · ×2
  • Edited copies of one member (4 members, 6+ corresponding lines) _onecdec/cmp.py:4 — _onecdec/cmp.py:4-9 | _onecdec/load_compare.py:26-31 | _onecdec/make_upgrade_fixtures.py:203-208 | _onecdec/spike_compare.py:14-19 — These 4 members are one piece of code written 4 times and then edited apart: every two of them correspond over at least 6 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' 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.
  • Edited copies of one member (4 members, 6+ corresponding lines) REDACTED:9078 — REDACTED:9078-9083 | REDACTED:9085-9090 | src/plan.rs:669-674 | src/source.rs:178-183 — These 4 members are one piece of code written 4 times and then edited apart: every two of them correspond over at least 6 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 4 times and the copies will drift further apart.
D4 · Code Duplication · Edited copies of one member (3 members, 9+ corresponding lines) · ×2
  • Edited copies of one member (3 members, 9+ corresponding lines) crates/ibcmd-dump/src/mssql_dump/mod.rs:27096 — crates/ibcmd-dump/src/mssql_dump/mod.rs:27096-27104 | crates/ibcmd-dump/src/mssql_dump/mod.rs:29870-29881 | crates/ibcmd-dump/src/mssql_dump/mod.rs:32185-32195 — 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' 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.
  • Edited copies of one member (3 members, 9+ corresponding lines) REDACTED:1332 — REDACTED:1332-1343 | REDACTED:1628-1638 | crates/ibcmd-restructure-engine/src/text.rs:6-14 — 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' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart.
D4 · Code Duplication · Duplicated block (64 lines × 2) · ×2
  • Duplicated block (64 lines × 2) crates/ibcmd-1c-vocab/src/type_xml.rs:25 — crates/ibcmd-1c-vocab/src/type_xml.rs:25-88 | crates/ibcmd-dump/src/mssql_dump/mod.rs:44603-44666 — before extracting anything, compare `crates/ibcmd-1c-vocab/src/type_xml.rs` and `crates/ibcmd-dump/src/mssql_dump/mod.rs` as WHOLE FILES: this scan already matched 6 separate duplicated blocks between them, totalling at least 118 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. 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 `crates/ibcmd-1c-vocab/src/type_xml.rs:25` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (64 lines × 2) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:2400 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:2400-2463 | crates/ibcmd-compiler-families/src/compiler/families/utility.rs:1135-1198 — before extracting anything, compare `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs` and `crates/ibcmd-compiler-families/src/compiler/families/utility.rs` as WHOLE FILES: this scan already matched 65 separate duplicated blocks between them, totalling at least 934 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:2400` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (47 lines × 2) · ×2
  • Duplicated block (47 lines × 2) crates/ibcmd-form-body/src/form_body.rs:38325 — crates/ibcmd-form-body/src/form_body.rs:38325-38371 | crates/ibcmd-form-body/src/form_body.rs:38377-38423 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-form-body/src/form_body.rs:38325` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (47 lines × 2) scripts/apply-trace/lab/s1g-caches/snapshot.py:137 — scripts/apply-trace/lab/s1g-caches/snapshot.py:137-183 | scripts/restructure-lab/snapshot.py:137-183 — before extracting anything, compare `scripts/apply-trace/lab/s1g-caches/snapshot.py` and `scripts/restructure-lab/snapshot.py` as WHOLE FILES: this scan already matched 5 separate duplicated blocks between them, totalling at least 122 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.
D4 · Code Duplication · Duplicated block (38 lines × 2) · ×2
  • Duplicated block (38 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:28706 — crates/ibcmd-dump/src/mssql_dump/mod.rs:28706-28743 | crates/ibcmd-dump/src/mssql_dump/mod.rs:30194-30231 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:28706` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (38 lines × 2) crates/ibcmd-metadata-model/src/metadata_model/objects_export.rs:1374 — crates/ibcmd-metadata-model/src/metadata_model/objects_export.rs:1374-1411 | crates/ibcmd-metadata-model/src/metadata_model/registers_export.rs:352-389 — before extracting anything, compare `crates/ibcmd-metadata-model/src/metadata_model/objects_export.rs` and `crates/ibcmd-metadata-model/src/metadata_model/registers_export.rs` as WHOLE FILES: this scan already matched 7 separate duplicated blocks between them, totalling at least 124 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. 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 `return` inside it is the body's own exit and keeps its meaning in the moved unit.
D4 · Code Duplication · Duplicated block (29 lines × 2) · ×2
  • Duplicated block (29 lines × 2) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:3310 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:3310-3338 | crates/ibcmd-compiler-families/src/compiler/families/utility.rs:1654-1682 — before extracting anything, compare `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs` and `crates/ibcmd-compiler-families/src/compiler/families/utility.rs` as WHOLE FILES: this scan already matched 65 separate duplicated blocks between them, totalling at least 934 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:3310` it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows — the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members' bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run — a one-line delegation has no helper inside it to lift — so generate the run from the set it enumerates, or accept it and keep each member's own documentation with it.
  • Duplicated block (29 lines × 2) crates/ibcmd-form-writer/src/lib.rs:15989 — crates/ibcmd-form-writer/src/lib.rs:15989-16017 | crates/ibcmd-form-writer/src/lib.rs:16043-16071 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-form-writer/src/lib.rs:15989` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (25–27 lines × 2) · ×2
  • Duplicated block (25–27 lines × 2) crates/ibcmd-dump/src/mssql_dump/source_assets.rs:2956 — crates/ibcmd-dump/src/mssql_dump/source_assets.rs:2956-2982 | crates/ibcmd-dump/src/mssql_dump/source_assets.rs:2997-3021 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/source_assets.rs:2956` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (25–27 lines × 2) crates/ibcmd-form-writer/src/lib.rs:22097 — crates/ibcmd-form-writer/src/lib.rs:22097-22121 | crates/ibcmd-form-writer/src/lib.rs:22945-22971 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-form-writer/src/lib.rs:22097` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (26 lines × 2) · ×2
  • Duplicated block (26 lines × 2) crates/ibcmd-core/src/migration/v2_20_to_v2_21.rs:195 — crates/ibcmd-core/src/migration/v2_20_to_v2_21.rs:195-220 | crates/ibcmd-core/src/migration/v2_21_to_v2_20.rs:259-284 — before extracting anything, compare `crates/ibcmd-core/src/migration/v2_20_to_v2_21.rs` and `crates/ibcmd-core/src/migration/v2_21_to_v2_20.rs` as WHOLE FILES: this scan already matched 6 separate duplicated blocks between them, totalling at least 67 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. 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 `return` inside it is the body's own exit and keeps its meaning in the moved unit.
  • Duplicated block (26 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:38747 — crates/ibcmd-dump/src/mssql_dump/mod.rs:38747-38772 | crates/ibcmd-dump/src/mssql_dump/mod.rs:38874-38899 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:38747` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (25 lines × 2) · ×2
  • Duplicated block (25 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:23421 — crates/ibcmd-dump/src/mssql_dump/mod.rs:23421-23445 | crates/ibcmd-dump/src/mssql_dump/mod.rs:23753-23777 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:23421` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (25 lines × 2) crates/ibcmd-moxel/src/lib.rs:8646 — crates/ibcmd-moxel/src/lib.rs:8646-8670 | crates/ibcmd-moxel/src/lib.rs:8876-8900 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-moxel/src/lib.rs:8646` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (19 lines × 3) · ×2
  • Duplicated block (19 lines × 3) crates/ibcmd-compiler-families/src/compiler/families/services.rs:2986 — crates/ibcmd-compiler-families/src/compiler/families/services.rs:2986-3004 | crates/ibcmd-dump/src/mssql_dump/mod.rs:35564-35582 | crates/ibcmd-xml/src/dcs.rs:4322-4340 — before extracting anything, compare `crates/ibcmd-compiler-families/src/compiler/families/services.rs` and `crates/ibcmd-dump/src/mssql_dump/mod.rs` as WHOLE FILES: this scan already matched 4 separate duplicated blocks between them, totalling at least 41 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 `return` inside it is the body's own exit and keeps its meaning in the moved unit.
  • Duplicated block (19 lines × 3) crates/ibcmd-form-writer/src/lib.rs:11402 — crates/ibcmd-form-writer/src/lib.rs:11402-11420 | crates/ibcmd-form-writer/src/lib.rs:11428-11446 | crates/ibcmd-form-writer/src/lib.rs:11453-11471 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-form-writer/src/lib.rs:11402` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (16 lines × 4) · ×2
  • Duplicated block (16 lines × 4) crates/ibcmd-metadata-blob/src/lib.rs:5907 — crates/ibcmd-metadata-blob/src/lib.rs:5907-5922 | crates/ibcmd-metadata-blob/src/lib.rs:6066-6081 | crates/ibcmd-metadata-blob/src/lib.rs:6192-6207 | crates/ibcmd-metadata-blob/src/lib.rs:6408-6423 — all 4 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-metadata-blob/src/lib.rs:5907` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (16 lines × 4) crates/ibcmd-moxel/src/lib.rs:6093 — crates/ibcmd-moxel/src/lib.rs:6093-6108 | crates/ibcmd-moxel/src/lib.rs:9472-9487 | crates/ibcmd-moxel/src/lib.rs:9537-9552 | crates/ibcmd-moxel/src/lib.rs:10010-10025 — all 4 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited.
D4 · Code Duplication · Duplicated block (15 lines × 3) · ×2
  • Duplicated block (15 lines × 3) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:911 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:911-925 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:1986-2000 | crates/ibcmd-compiler-families/src/compiler/families/utility.rs:586-600 — before extracting anything, compare `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs` and `crates/ibcmd-compiler-families/src/compiler/families/simple.rs` as WHOLE FILES: this scan already matched 12 separate duplicated blocks between them, totalling at least 149 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:911` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (15 lines × 3) crates/ibcmd-form-body/src/form_body.rs:34253 — crates/ibcmd-form-body/src/form_body.rs:34253-34267 | crates/ibcmd-form-body/src/form_body.rs:35700-35714 | crates/ibcmd-form-body/src/form_body.rs:36029-36043 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-form-body/src/form_body.rs:34253` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (14–15 lines × 2) · ×2
  • Duplicated block (14–15 lines × 2) crates/ibcmd-compiler-families/src/compiler/families/business_object/register_native.rs:1110 — crates/ibcmd-compiler-families/src/compiler/families/business_object/register_native.rs:1110-1123 | crates/ibcmd-compiler-families/src/compiler/families/business_object/register_native.rs:1256-1270 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/business_object/register_native.rs:1110` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, `crates/ibcmd-compiler-families/src/compiler/families/business_object/register_native.rs:1273` calls `enum_code` and `crates/ibcmd-compiler-families/src/compiler/families/business_object/register_native.rs:1126` does not — after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
  • Duplicated block (14–15 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:10415 — crates/ibcmd-dump/src/mssql_dump/mod.rs:10415-10428 | crates/ibcmd-dump/src/mssql_dump/refs.rs:1548-1562 — before extracting anything, compare `crates/ibcmd-dump/src/mssql_dump/mod.rs` and `crates/ibcmd-dump/src/mssql_dump/refs.rs` as WHOLE FILES: this scan already matched 13 separate duplicated blocks between them, totalling at least 117 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:10415` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
D4 · Code Duplication · Duplicated block (24 lines × 2) · ×2
  • Duplicated block (24 lines × 2) crates/ibcmd-metadata-model/src/metadata_model/objects_export.rs:1464 — crates/ibcmd-metadata-model/src/metadata_model/objects_export.rs:1464-1487 | crates/ibcmd-metadata-model/src/metadata_model/registers_export.rs:431-454 — before extracting anything, compare `crates/ibcmd-metadata-model/src/metadata_model/objects_export.rs` and `crates/ibcmd-metadata-model/src/metadata_model/registers_export.rs` as WHOLE FILES: this scan already matched 7 separate duplicated blocks between them, totalling at least 124 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place.
  • Duplicated block (24 lines × 2) scripts/apply-trace/lab/s1g-caches/db.py:15 — scripts/apply-trace/lab/s1g-caches/db.py:15-38 | scripts/restructure-lab/db.py:15-38 — before extracting anything, compare `scripts/apply-trace/lab/s1g-caches/db.py` and `scripts/restructure-lab/db.py` as WHOLE FILES: 100% of the shorter file's lines also appear in the other, so this reads as one file having been copied from the other rather than as a helper waiting to be extracted. The 1 duplicated block(s) this scan matched between them are fragments of that copy, not the extent of it — treat the file pair as the unit. 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.
D4 · Code Duplication · Duplicated block (14 lines × 3) · ×2
  • Duplicated block (14 lines × 3) crates/ibcmd-1c-text/src/brace_list.rs:16 — crates/ibcmd-1c-text/src/brace_list.rs:16-29 | crates/ibcmd-dump/src/mssql_dump/legacy_child.rs:20-33 | crates/ibcmd-dump/src/mssql_dump/upgrade.rs:753-766 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 3 call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made 3 times. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-1c-text/src/brace_list.rs:16` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (14 lines × 3) src/conversion.rs:760 — src/conversion.rs:760-773 | src/conversion.rs:1280-1295 | src/conversion/edt.rs:219-232 — there are 3 copies across 2 file(s) — more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 3 sites; resolving a subset leaves the remainder to drift apart. Read the line range as the matched WINDOW rather than a finished unit: at `src/conversion.rs:760` it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows — the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members' bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run — a one-line delegation has no helper inside it to lift — so generate the run from the set it enumerates, or accept it and keep each member's own documentation with it.
D4 · Code Duplication · Duplicated block (13 lines × 4) · ×2
  • Duplicated block (13 lines × 4) crates/ibcmd-compiler-families/src/compiler/families/services.rs:3386 — crates/ibcmd-compiler-families/src/compiler/families/services.rs:3386-3398 | crates/ibcmd-compiler-families/src/compiler/families/services.rs:3412-3424 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:2403-2415 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:2429-2441 — before extracting anything, compare `crates/ibcmd-compiler-families/src/compiler/families/services.rs` and `crates/ibcmd-compiler-families/src/compiler/families/simple.rs` as WHOLE FILES: this scan already matched 36 separate duplicated blocks between them, totalling at least 406 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/services.rs:3386` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (13 lines × 4) crates/ibcmd-xml/src/dcs_template.rs:442 — crates/ibcmd-xml/src/dcs_template.rs:442-454 | crates/ibcmd-xml/src/dcs_template.rs:484-496 | crates/ibcmd-xml/src/dcs_template.rs:877-889 | crates/ibcmd-xml/src/dcs_template.rs:921-933 — all 4 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-xml/src/dcs_template.rs:442` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (11–13 lines × 2) · ×2
  • Duplicated block (11–13 lines × 2) crates/ibcmd-cf/src/bootstrap.rs:491 — crates/ibcmd-cf/src/bootstrap.rs:491-503 | crates/ibcmd-cf/src/writer.rs:726-736 — before extracting anything, compare `crates/ibcmd-cf/src/bootstrap.rs` and `crates/ibcmd-cf/src/writer.rs` as WHOLE FILES: this scan already matched 3 separate duplicated blocks between them, totalling at least 33 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-cf/src/bootstrap.rs:491` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (11–13 lines × 2) crates/ibcmd-form-body/src/form_body.rs:32181 — crates/ibcmd-form-body/src/form_body.rs:32181-32193 | crates/ibcmd-form-body/src/form_body.rs:37629-37639 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
D4 · Code Duplication · Duplicated block (24–25 lines × 2) · ×2
  • Duplicated block (24–25 lines × 2) crates/ibcmd-metadata-blob/src/lib.rs:5563 — crates/ibcmd-metadata-blob/src/lib.rs:5563-5587 | crates/ibcmd-metadata-blob/src/lib.rs:5675-5698 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-metadata-blob/src/lib.rs:5563` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (24–25 lines × 2) crates/ibcmd-restructure-engine/src/restructure/catalog.rs:256 — crates/ibcmd-restructure-engine/src/restructure/catalog.rs:256-280 | crates/ibcmd-restructure-engine/src/restructure/object.rs:150-173 — before extracting anything, compare `crates/ibcmd-restructure-engine/src/restructure/catalog.rs` and `crates/ibcmd-restructure-engine/src/restructure/object.rs` as WHOLE FILES: this scan already matched 3 separate duplicated blocks between them, totalling at least 42 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-restructure-engine/src/restructure/catalog.rs:256` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (12 lines × 6) · ×2
  • Duplicated block (12 lines × 6) crates/ibcmd-1c-text/src/fields.rs:241 — crates/ibcmd-1c-text/src/fields.rs:241-252 | crates/ibcmd-form-body/src/form_body.rs:39029-39040 | crates/ibcmd-form-body/src/form_body.rs:39723-39734 | crates/ibcmd-moxel/src/lib.rs:7315-7326 | crates/ibcmd-schema/src/lib.rs:1175-1186 | crates/ibcmd-schema/src/lib.rs:2408-2419 — before extracting anything, compare `crates/ibcmd-form-body/src/form_body.rs` and `crates/ibcmd-moxel/src/lib.rs` as WHOLE FILES: this scan already matched 4 separate duplicated blocks between them, totalling at least 52 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 `crates/ibcmd-1c-text/src/fields.rs:241` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (12 lines × 6) crates/ibcmd-metadata-blob/src/lib.rs:5609 — crates/ibcmd-metadata-blob/src/lib.rs:5609-5620 | crates/ibcmd-metadata-blob/src/lib.rs:5720-5731 | crates/ibcmd-metadata-blob/src/lib.rs:5850-5861 | crates/ibcmd-metadata-blob/src/lib.rs:6014-6025 | crates/ibcmd-metadata-blob/src/lib.rs:6164-6175 | crates/ibcmd-metadata-blob/src/lib.rs:6371-6382 — all 6 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-metadata-blob/src/lib.rs:5609` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (11–12 lines × 3) · ×2
  • Duplicated block (11–12 lines × 3) crates/ibcmd-1c-vocab/src/type_xml.rs:27 — crates/ibcmd-1c-vocab/src/type_xml.rs:27-38 | crates/ibcmd-1c-vocab/src/type_xml.rs:107-117 | crates/ibcmd-dump/src/mssql_dump/mod.rs:44605-44616 — before extracting anything, compare `crates/ibcmd-1c-vocab/src/type_xml.rs` and `crates/ibcmd-dump/src/mssql_dump/mod.rs` as WHOLE FILES: this scan already matched 6 separate duplicated blocks between them, totalling at least 118 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. 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 `crates/ibcmd-1c-vocab/src/type_xml.rs:27` it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows — the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members' bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run — a one-line delegation has no helper inside it to lift — so generate the run from the set it enumerates, or accept it and keep each member's own documentation with it.
  • Duplicated block (11–12 lines × 3) REDACTED:649 — REDACTED:649-659 | REDACTED:679-690 | REDACTED:908-919 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `REDACTED:649` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, `REDACTED:907` calls `quote_string` and `REDACTED:677` does not — after which the two agree again for 3 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
D4 · Code Duplication · Duplicated block (11 lines × 4) · ×2
  • Duplicated block (11 lines × 4) crates/ibcmd-metadata-blob/src/lib.rs:2024 — crates/ibcmd-metadata-blob/src/lib.rs:2024-2034 | crates/ibcmd-metadata-blob/src/lib.rs:4524-4534 | crates/ibcmd-metadata-blob/src/lib.rs:5186-5196 | crates/ibcmd-metadata-blob/src/lib.rs:5354-5364 — all 4 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-metadata-blob/src/lib.rs:2024` it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows — the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members' bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run — a one-line delegation has no helper inside it to lift — so generate the run from the set it enumerates, or accept it and keep each member's own documentation with it.
  • Duplicated block (11 lines × 4) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:3747 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:3747-3757 | crates/ibcmd-compiler-families/src/compiler/families/services.rs:3553-3563 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:2570-2580 | crates/ibcmd-compiler-families/src/compiler/families/utility.rs:2086-2096 — before extracting anything, compare `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs` and `crates/ibcmd-compiler-families/src/compiler/families/services.rs` as WHOLE FILES: this scan already matched 10 separate duplicated blocks between them, totalling at least 103 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:3747` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
D4 · Code Duplication · Duplicated block (9–11 lines × 3) · ×2
  • Duplicated block (9–11 lines × 3) crates/ibcmd-dump/src/mssql_dump/mod.rs:27747 — crates/ibcmd-dump/src/mssql_dump/mod.rs:27747-27755 | crates/ibcmd-dump/src/mssql_dump/mod.rs:28599-28609 | crates/ibcmd-dump/src/mssql_dump/mod.rs:30110-30120 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:28599` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (9–11 lines × 3) src/commands/cf.rs:851 — src/commands/cf.rs:851-861 | src/commands/cf.rs:936-944 | src/commands/cf.rs:992-1001 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `src/commands/cf.rs:851` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (10–11 lines × 3) · ×2
  • Duplicated block (10–11 lines × 3) crates/ibcmd-dump/src/mssql_dump/mod.rs:35047 — crates/ibcmd-dump/src/mssql_dump/mod.rs:35047-35056 | crates/ibcmd-dump/src/mssql_dump/refs.rs:3956-3966 | crates/ibcmd-form-body/src/form_body.rs:5466-5475 — before extracting anything, compare `crates/ibcmd-dump/src/mssql_dump/mod.rs` and `crates/ibcmd-dump/src/mssql_dump/refs.rs` as WHOLE FILES: this scan already matched 13 separate duplicated blocks between them, totalling at least 117 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place.
  • Duplicated block (10–11 lines × 3) crates/ibcmd-dump/src/mssql_dump/mod.rs:35251 — crates/ibcmd-dump/src/mssql_dump/mod.rs:35251-35261 | crates/ibcmd-dump/src/mssql_dump/mod.rs:35316-35325 | crates/ibcmd-dump/src/mssql_dump/mod.rs:35366-35375 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:35251` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
D4 · Code Duplication · Duplicated block (9 lines × 4) · ×2
  • Duplicated block (9 lines × 4) crates/ibcmd-dump/src/mssql_dump/mod.rs:37280 — crates/ibcmd-dump/src/mssql_dump/mod.rs:37280-37288 | crates/ibcmd-dump/src/mssql_dump/mod.rs:37350-37358 | crates/ibcmd-dump/src/mssql_dump/mod.rs:42386-42394 | crates/ibcmd-dump/src/mssql_dump/mod.rs:42438-42446 — all 4 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:37280` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, `crates/ibcmd-dump/src/mssql_dump/mod.rs:37277` calls `as_str` and `crates/ibcmd-dump/src/mssql_dump/mod.rs:42383` does not — after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
  • Duplicated block (9 lines × 4) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:3787 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:3787-3795 | crates/ibcmd-compiler-families/src/compiler/families/services.rs:3591-3599 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:2608-2616 | crates/ibcmd-compiler-families/src/compiler/families/utility.rs:2126-2134 — before extracting anything, compare `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs` and `crates/ibcmd-compiler-families/src/compiler/families/services.rs` as WHOLE FILES: this scan already matched 10 separate duplicated blocks between them, totalling at least 103 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place.
D4 · Code Duplication · Duplicated block (7–9 lines × 3) · ×2
  • Duplicated block (7–9 lines × 3) crates/ibcmd-metadata-blob/src/lib.rs:4815 — crates/ibcmd-metadata-blob/src/lib.rs:4815-4823 | crates/ibcmd-metadata-blob/src/lib.rs:4825-4833 | crates/ibcmd-metadata-blob/src/lib.rs:4834-4840 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-metadata-blob/src/lib.rs:4834` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
  • Duplicated block (7–9 lines × 3) crates/ibcmd-metadata-blob/src/lib.rs:7880 — crates/ibcmd-metadata-blob/src/lib.rs:7880-7888 | crates/ibcmd-metadata-blob/src/lib.rs:7899-7907 | crates/ibcmd-metadata-blob/src/lib.rs:7916-7922 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-metadata-blob/src/lib.rs:7880` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, `crates/ibcmd-metadata-blob/src/lib.rs:7899` calls `push` and `crates/ibcmd-metadata-blob/src/lib.rs:7916` does not — after which the two agree again for 4 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
D4 · Code Duplication · Duplicated block (8 lines × 6) · ×2
  • Duplicated block (8 lines × 6) crates/ibcmd-dump/src/mssql_dump/mod.rs:15022 — crates/ibcmd-dump/src/mssql_dump/mod.rs:15022-15029 | crates/ibcmd-dump/src/mssql_dump/mod.rs:26101-26108 | crates/ibcmd-dump/src/mssql_dump/mod.rs:30532-30539 | crates/ibcmd-dump/src/mssql_dump/mod.rs:31200-31207 | crates/ibcmd-dump/src/mssql_dump/mod.rs:32226-32233 | crates/ibcmd-dump/src/mssql_dump/mod.rs:32885-32892 — all 6 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (8 lines × 6) crates/ibcmd-xml/src/metadata/functional_option.rs:87 — crates/ibcmd-xml/src/metadata/functional_option.rs:87-94 | crates/ibcmd-xml/src/metadata/functional_options_parameter.rs:86-93 | crates/ibcmd-xml/src/metadata/language.rs:127-134 | crates/ibcmd-xml/src/metadata/services.rs:429-436 | crates/ibcmd-xml/src/metadata/services.rs:488-495 | crates/ibcmd-xml/src/metadata/services.rs:534-541 — before extracting anything, compare `crates/ibcmd-xml/src/metadata/functional_option.rs` and `crates/ibcmd-xml/src/metadata/functional_options_parameter.rs` as WHOLE FILES: this scan already matched 17 separate duplicated blocks between them, totalling at least 156 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-xml/src/metadata/functional_option.rs:87` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The `return` at the foot of the matched lines is the enclosing body's own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that `return` occupied — no decision has to be handed back and re-acted on.
D4 · Code Duplication · Duplicated block (7 lines × 5) · ×2
  • Duplicated block (7 lines × 5) crates/ibcmd-metadata-blob/src/lib.rs:1966 — crates/ibcmd-metadata-blob/src/lib.rs:1966-1972 | crates/ibcmd-metadata-blob/src/lib.rs:5805-5811 | crates/ibcmd-metadata-blob/src/lib.rs:5979-5985 | crates/ibcmd-metadata-blob/src/lib.rs:6107-6113 | crates/ibcmd-metadata-blob/src/lib.rs:6300-6306 — all 5 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-metadata-blob/src/lib.rs:1966` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (7 lines × 5) crates/ibcmd-xml/src/metadata/functional_option.rs:311 — crates/ibcmd-xml/src/metadata/functional_option.rs:311-317 | crates/ibcmd-xml/src/metadata/functional_options_parameter.rs:293-299 | crates/ibcmd-xml/src/metadata/language.rs:250-256 | crates/ibcmd-xml/src/metadata/services.rs:2430-2436 | crates/ibcmd-xml/src/metadata/session_parameter.rs:677-683 — before extracting anything, compare `crates/ibcmd-xml/src/metadata/functional_option.rs` and `crates/ibcmd-xml/src/metadata/functional_options_parameter.rs` as WHOLE FILES: this scan already matched 17 separate duplicated blocks between them, totalling at least 156 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-xml/src/metadata/functional_option.rs:311` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (6–7 lines × 3) · ×2
  • Duplicated block (6–7 lines × 3) crates/ibcmd-1c-vocab/src/commands.rs:111 — crates/ibcmd-1c-vocab/src/commands.rs:111-116 | crates/ibcmd-metadata-model/src/metadata_model/objects_export.rs:1438-1444 | crates/ibcmd-metadata-model/src/metadata_model/registers_export.rs:404-410 — before extracting anything, compare `crates/ibcmd-metadata-model/src/metadata_model/objects_export.rs` and `crates/ibcmd-metadata-model/src/metadata_model/registers_export.rs` as WHOLE FILES: this scan already matched 7 separate duplicated blocks between them, totalling at least 124 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place.
  • Duplicated block (6–7 lines × 3) crates/ibcmd-dump/src/mssql_dump/mod.rs:14982 — crates/ibcmd-dump/src/mssql_dump/mod.rs:14982-14987 | crates/ibcmd-dump/src/mssql_dump/mod.rs:17282-17288 | crates/ibcmd-dump/src/mssql_dump/mod.rs:19044-19049 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:17282` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, `crates/ibcmd-dump/src/mssql_dump/mod.rs:19043` calls `metadata_source_folder_for_kind` and `crates/ibcmd-dump/src/mssql_dump/mod.rs:14981` does not — after which the two agree again for 4 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
D4 · Code Duplication · Duplicated block (5 lines × 6) · ×2
  • Duplicated block (5 lines × 6) crates/ibcmd-schema/src/lib.rs:8059 — crates/ibcmd-schema/src/lib.rs:8059-8069 | crates/ibcmd-schema/src/lib.rs:9117-9121 | crates/ibcmd-schema/src/lib.rs:9365-9369 | crates/ibcmd-schema/src/lib.rs:9660-9664 | crates/ibcmd-schema/src/lib.rs:9903-9924 | crates/ibcmd-schema/src/lib.rs:10100-10104 — all 6 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-schema/src/lib.rs:8059` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, `crates/ibcmd-schema/src/lib.rs:9666` calls `as_str` and `crates/ibcmd-schema/src/lib.rs:9123` does not — after which the two agree again for 3 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
  • Duplicated block (5 lines × 6) crates/ibcmd-dump/src/mssql_dump/mod.rs:38189 — crates/ibcmd-dump/src/mssql_dump/mod.rs:38189-38193 | crates/ibcmd-dump/src/mssql_dump/mod.rs:38275-38279 | crates/ibcmd-dump/src/mssql_dump/mod.rs:39875-39879 | crates/ibcmd-dump/src/mssql_dump/mod.rs:40060-40064 | crates/ibcmd-dump/src/mssql_dump/mod.rs:40500-40504 | crates/ibcmd-dump/src/mssql_dump/mod.rs:40582-40586 — all 6 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, `crates/ibcmd-dump/src/mssql_dump/mod.rs:40059` calls `acknowledge_internal_only` and `crates/ibcmd-dump/src/mssql_dump/mod.rs:39874` does not — after which the two agree again for 4 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
D4 · Code Duplication · Duplicated block (7 lines × 7) · ×2
  • Duplicated block (7 lines × 7) crates/ibcmd-xml/src/metadata/services.rs:1072 — crates/ibcmd-xml/src/metadata/services.rs:1072-1078 | crates/ibcmd-xml/src/metadata/services.rs:1117-1123 | crates/ibcmd-xml/src/metadata/services.rs:1237-1243 | crates/ibcmd-xml/src/metadata/services.rs:1265-1271 | crates/ibcmd-xml/src/metadata/services.rs:1405-1411 | crates/ibcmd-xml/src/metadata/services.rs:1588-1594 | crates/ibcmd-xml/src/metadata/services.rs:1692-1698 — all 7 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (7 lines × 7) crates/ibcmd-dump/src/mssql_dump/mod.rs:15024 — crates/ibcmd-dump/src/mssql_dump/mod.rs:15024-15030 | crates/ibcmd-dump/src/mssql_dump/mod.rs:20838-20844 | crates/ibcmd-dump/src/mssql_dump/mod.rs:30534-30540 | crates/ibcmd-dump/src/mssql_dump/mod.rs:31202-31208 | crates/ibcmd-dump/src/mssql_dump/mod.rs:32228-32234 | crates/ibcmd-dump/src/mssql_dump/mod.rs:32375-32381 | crates/ibcmd-dump/src/mssql_dump/mod.rs:32887-32893 — all 7 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:15024` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Edited copies of one member (3 members, 3+ corresponding lines) · ×2
  • Edited copies of one member (3 members, 3+ corresponding lines) _onecdec/make_adopted_exchange_plan_fixture.py:32 — _onecdec/make_adopted_exchange_plan_fixture.py:32-35 | _onecdec/make_adopted_predefined_fixture.py:37-39 | _onecdec/make_adopted_subscription_fixture.py:29-32 — These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 3 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart.
  • Edited copies of one member (3 members, 3+ corresponding lines) scripts/restructure-lab/edit_cases_s1.py:104 — scripts/restructure-lab/edit_cases_s1.py:104-106 | scripts/restructure-lab/mix_forms.py:25-27 | scripts/restructure-lab/s1k/new_objects.py:29-31 — These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 3 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart.
R2 · Cyclomatic Complexity · Complex function (anonymous) (cyclomatic 11, cognitive 10) · ×2
  • Complex function (anonymous) (cyclomatic 11, cognitive 10) editors/vscode/src/configuration-tree.ts:670 — (anonymous) has cyclomatic complexity 11 and cognitive complexity 10; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth — arms side by side rather than stacked — and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes.
  • Complex function (anonymous) (cyclomatic 11, cognitive 10) editors/vscode/src/database-commands.ts:101 — (anonymous) has cyclomatic complexity 11 and cognitive complexity 10; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth — arms side by side rather than stacked — and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes.
C1 · Data Protection · No data-protection/encryption · ×1
  • No data-protection/encryption docs/apply/evidence/restructuring/a2-structure-statements.sql:249 — No encryption usage (RustCrypto's aes-gcm/chacha20poly1305 encrypting, ring or aws-lc-rs aead sealing, orion, libsodium's secretbox, openssl symm, age, SQLCipher keyed by PRAGMA key, pgcrypto, MongoDB client-side field-level encryption, the OS keyring) was found, and this repository persists personal data in the model cited here — sensitive data at rest may be unprotected. If TDE/KMS/vault is delegated to infrastructure, ignore.
D1 · Cyclomatic Complexity · extension.activate (cyclomatic 64) · ×1
  • extension.activate (cyclomatic 64) editors/vscode/src/extension.ts:19 — extension.activate has cyclomatic complexity 64 (threshold 15). Most of this is not in the body itself: 4 of the 64 points are its own statements and the rest belongs to 16 function literals inside it that branch (lines 652, 501, 524, …). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D1 · Cyclomatic Complexity · extension.activate.importFiles (cyclomatic 56) · ×1
  • extension.activate.importFiles (cyclomatic 56) editors/vscode/src/extension.ts:253 — extension.activate.importFiles has cyclomatic complexity 56 (threshold 15). Of this number, 29 points are the body's own statements and 27 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.
D1 · Cyclomatic Complexity · ObjectView.refresh (cyclomatic 52) · ×1
  • ObjectView.refresh (cyclomatic 52) editors/vscode/src/object-view.ts:164 — ObjectView.refresh has cyclomatic complexity 52 (threshold 15). Most of this is not in the body itself: 8 of the 52 points are its own statements and the rest belongs to 3 function literals inside it that branch (lines 196, 271, 215). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D1 · Cyclomatic Complexity · StoredConfiguration · ×1
  • StoredConfiguration::prepare_editor_export (cyclomatic 48) src/stored_objects/editor_export.rs:17 — StoredConfiguration::prepare_editor_export 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.
D1 · Cyclomatic Complexity · extension.activate.edit (cyclomatic 47) · ×1
  • extension.activate.edit (cyclomatic 47) editors/vscode/src/extension.ts:697 — extension.activate.edit has cyclomatic complexity 47 (threshold 15). Of this number, 43 points are the body's own statements and 4 belong to 3 function literals inside it that branch. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · Writer · ×1
  • Writer::write_element (cyclomatic 46) REDACTED:983 — Writer::write_element has cyclomatic complexity 46 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · Projector · ×1
  • Projector::emit_adopted (cyclomatic 38) crates/ibcmd-dump/src/mssql_dump/extension/project.rs:187 — Projector::emit_adopted has cyclomatic complexity 38 (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.
D1 · Cyclomatic Complexity · DcsWriterEvidenceCorpus · ×1
  • DcsWriterEvidenceCorpus::validate (cyclomatic 36) crates/ibcmd-schema/src/lib.rs:11713 — DcsWriterEvidenceCorpus::validate 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.
D1 · Cyclomatic Complexity · MigrationStepReport · ×1
  • MigrationStepReport::from_parts (cyclomatic 34) crates/ibcmd-core/src/migration/report.rs:475 — MigrationStepReport::from_parts has cyclomatic complexity 34 (threshold 15). To reduce it, separate the branches: extract each independent case into its own named function so the top-level body reads as a short sequence of named decisions.
D1 · Cyclomatic Complexity · config.editConfig (cyclomatic 33) · ×1
  • config.editConfig (cyclomatic 33) editors/vscode/src/config.ts:24 — config.editConfig has cyclomatic complexity 33 (threshold 15). Of this number, 27 points are the body's own statements and 6 belong to 3 function literals inside it that branch. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · object-export.exportObjects (cyclomatic 33) · ×1
  • object-export.exportObjects (cyclomatic 33) editors/vscode/src/object-export.ts:173 — object-export.exportObjects has cyclomatic complexity 33 (threshold 15). Most of this is not in the body itself: 6 of the 33 points are its own statements and the rest belongs to 5 function literals inside it that branch (lines 209, 213, 267, …). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D1 · Cyclomatic Complexity · MigrationReport · ×1
  • MigrationReport::from_parts (cyclomatic 32) crates/ibcmd-core/src/migration/report.rs:800 — MigrationReport::from_parts has cyclomatic complexity 32 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top. This is NOT this file's highest cyclomatic complexity: MigrationReportError::code (cyclomatic 33) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
D1 · Cyclomatic Complexity · Document · ×1
  • Document::collect (cyclomatic 31) crates/ibcmd-compiler/src/compiler/bodies/mxl_native.rs:610 — Document::collect has cyclomatic complexity 31 (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 — the same kind of value, with no behaviour of its own — 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. This is NOT this file's highest cyclomatic complexity: ibcmd_compiler::compiler::bodies::mxl_native::web_color_code (cyclomatic 59) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
D1 · Cyclomatic Complexity · ModelExport · ×1
  • ModelExport::build (cyclomatic 31) crates/ibcmd-dump/src/mssql_dump/model_export.rs:332 — ModelExport::build has cyclomatic complexity 31 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · database-commands.registerDatabaseCommands (cyclomatic 31) · ×1
  • database-commands.registerDatabaseCommands (cyclomatic 31) editors/vscode/src/database-commands.ts:16 — database-commands.registerDatabaseCommands has cyclomatic complexity 31 (threshold 15). Most of this is not in the body itself: 1 of the 31 points is its own statement and the rest belongs to 7 function items inside it that branch (a function literal at line 101, a function literal at line 88, a function literal at line 31, …). The named helpers are already separate functions; the literals' 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's 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.
D1 · Cyclomatic Complexity · UpConversion · ×1
  • UpConversion::convert_item (cyclomatic 28) crates/ibcmd-form-writer/src/form/load_8_5_1.rs:1785 — UpConversion::convert_item has cyclomatic complexity 28 (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. This is NOT this file's highest cyclomatic complexity: ibcmd_form_writer::form::load_8_5_1::up_bag (cyclomatic 29) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
D1 · Cyclomatic Complexity · ConservativeGate · ×1
  • ConservativeGate::check (cyclomatic 27) REDACTED:289 — ConservativeGate::check 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.
D1 · Cyclomatic Complexity · ConfigDumpInfo · ×1
  • ConfigDumpInfo::parse (cyclomatic 27) crates/ibcmd-xml/src/config_dump_info.rs:109 — ConfigDumpInfo::parse 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.
D1 · Cyclomatic Complexity · extension.activate.switchTo (cyclomatic 27) · ×1
  • extension.activate.switchTo (cyclomatic 27) editors/vscode/src/extension.ts:113 — extension.activate.switchTo has cyclomatic complexity 27 (threshold 15). Of this number, 16 points are the body's own statements and 11 belong to 2 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · Obj · ×1
  • Obj::encode (cyclomatic 26) crates/ibcmd-metadata-model/src/metadata_model/objects_parts.rs:440 — Obj::encode 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 — the same kind of value, with no behaviour of its own — 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.
D1 · Cyclomatic Complexity · CanonicalCoverageCorpus · ×1
  • CanonicalCoverageCorpus::validate (cyclomatic 26) crates/ibcmd-schema/src/lib.rs:12771 — CanonicalCoverageCorpus::validate 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.
D1 · Cyclomatic Complexity · XmlReader · ×1
  • XmlReader::parse (cyclomatic 25) crates/ibcmd-xml/src/reader.rs:91 — XmlReader::parse 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.
D1 · Cyclomatic Complexity · corpus_compare.main (cyclomatic 25) · ×1
  • corpus_compare.main (cyclomatic 25) _onecdec/corpus_compare.py:34 — corpus_compare.main 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.
D1 · Cyclomatic Complexity · verify_edit.main (cyclomatic 24) · ×1
  • verify_edit.main (cyclomatic 24) _onecdec/verify_edit.py:44 — verify_edit.main 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.
D1 · Cyclomatic Complexity · DatabaseSource.children (cyclomatic 24) · ×1
  • DatabaseSource.children (cyclomatic 24) editors/vscode/src/configuration-tree.ts:505 — DatabaseSource.children has cyclomatic complexity 24 (threshold 15). Of this number, 17 points are the body's own statements and 7 belong 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.
D1 · Cyclomatic Complexity · ConfigurationView.constructor (cyclomatic 24) · ×1
  • ConfigurationView.constructor (cyclomatic 24) editors/vscode/src/configuration-view.ts:26 — ConfigurationView.constructor has cyclomatic complexity 24 (threshold 15). Most of this is not in the body itself: 1 of the 24 points is its own statement and the rest belongs to 6 function literals inside it that branch (lines 76, 62, 89, …). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D1 · Cyclomatic Complexity · Record · ×1
  • Record::from_brace (cyclomatic 22) crates/ibcmd-metadata-model/src/metadata_model/external_data_source.rs:136 — Record::from_brace 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.
D1 · Cyclomatic Complexity · read_compact8_recovery.read_live (cyclomatic 22) · ×1
  • read_compact8_recovery.read_live (cyclomatic 22) docs/apply/evidence/live-gate/compact8-runtime-preexec/read_compact8_recovery.py:24 — read_compact8_recovery.read_live has cyclomatic complexity 22 (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.
D1 · Cyclomatic Complexity · extension.activate.runExport (cyclomatic 22) · ×1
  • extension.activate.runExport (cyclomatic 22) editors/vscode/src/extension.ts:426 — extension.activate.runExport has cyclomatic complexity 22 (threshold 15). Of this number, 19 points are the body's 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.
D1 · Cyclomatic Complexity · big_compare.main (cyclomatic 21) · ×1
  • big_compare.main (cyclomatic 21) _onecdec/big_compare.py:40 — big_compare.main 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.
D1 · Cyclomatic Complexity · big_compare_v85.main (cyclomatic 21) · ×1
  • big_compare_v85.main (cyclomatic 21) _onecdec/big_compare_v85.py:21 — big_compare_v85.main 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.
D1 · Cyclomatic Complexity · ibcmd_filedb · ×1
  • ibcmd_filedb::index::rebuild (cyclomatic 20) crates/ibcmd-filedb/src/index.rs:263 — ibcmd_filedb::index::rebuild 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.
D1 · Cyclomatic Complexity · ibcmd_restructure · ×1
  • ibcmd_restructure::schema::add_field_indexes (cyclomatic 20) crates/ibcmd-restructure/src/schema.rs:597 — ibcmd_restructure::schema::add_field_indexes 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.
D1 · Cyclomatic Complexity · ibcmd_sql · ×1
  • ibcmd_sql::sql::mssql::script::scan_line (cyclomatic 20) crates/ibcmd-sql/src/sql/mssql/script.rs:136 — ibcmd_sql::sql::mssql::script::scan_line 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 — the same kind of value, with no behaviour of its own — 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.
D1 · Cyclomatic Complexity · Session · ×1
  • Session::open (cyclomatic 20) src/server/infobases.rs:401 — Session::open has cyclomatic complexity 20 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · SessionParameterNativeIr · ×1
  • SessionParameterNativeIr::to_xml (cyclomatic 19) crates/ibcmd-compiler-families/src/compiler/families/simple.rs:581 — SessionParameterNativeIr::to_xml 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. This shape REPEATS in the file: one other method here (ibcmd_compiler_families::compiler::families::simple::write_type_pattern_xml) has the same decision points, in the same order, at the same nesting depths — 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.
D1 · Cyclomatic Complexity · BootstrapManifest · ×1
  • BootstrapManifest::validate (cyclomatic 19) crates/ibcmd-compiler-readiness/src/lib.rs:198 — BootstrapManifest::validate 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.
D1 · Cyclomatic Complexity · OfflineFormContextFactory · ×1
  • OfflineFormContextFactory::from_plain_rows (cyclomatic 19) crates/ibcmd-dump/src/mssql_dump/offline_context.rs:128 — OfflineFormContextFactory::from_plain_rows has cyclomatic complexity 19 (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.
D1 · Cyclomatic Complexity · MainActivationPlan · ×1
  • MainActivationPlan::dry_run_report (cyclomatic 19) REDACTED:342 — MainActivationPlan::dry_run_report has cyclomatic complexity 19 (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.
D1 · Cyclomatic Complexity · stress_load.one (cyclomatic 19) · ×1
  • stress_load.one (cyclomatic 19) _onecdec/stress_load.py:110 — stress_load.one 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.
D1 · Cyclomatic Complexity · TreeModel.children (cyclomatic 19) · ×1
  • TreeModel.children (cyclomatic 19) editors/vscode/src/configuration-tree.ts:596 — TreeModel.children has cyclomatic complexity 19 (threshold 15). Most of this is not in the body itself: 4 of the 19 points are its own statements and the rest belongs to 7 function literals inside it that branch (lines 611, 641, 626, …). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D1 · Cyclomatic Complexity · MetadataOrderCorpus · ×1
  • MetadataOrderCorpus::validate (cyclomatic 18) crates/ibcmd-schema/src/lib.rs:12994 — MetadataOrderCorpus::validate has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · scsu_std.decode (cyclomatic 18) · ×1
  • scsu_std.decode (cyclomatic 18) _onecdec/scsu_std.py:20 — scsu_std.decode 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.
D1 · Cyclomatic Complexity · XmlSource.children (cyclomatic 18) · ×1
  • XmlSource.children (cyclomatic 18) editors/vscode/src/configuration-tree.ts:416 — XmlSource.children has cyclomatic complexity 18 (threshold 15). Most of this is not in the body itself: 8 of the 18 points are its own statements and the rest belongs to one function item inside it that branches (walk). 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.
D1 · Cyclomatic Complexity · configuration-tree.descriptor (cyclomatic 18) · ×1
  • configuration-tree.descriptor (cyclomatic 18) editors/vscode/src/configuration-tree.ts:273 — configuration-tree.descriptor has cyclomatic complexity 18 (threshold 15). Of this number, 9 points are the body's own statements and 9 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.
D1 · Cyclomatic Complexity · WebServiceNativeIr · ×1
  • WebServiceNativeIr::to_xml (cyclomatic 17) crates/ibcmd-compiler-families/src/compiler/families/services.rs:923 — WebServiceNativeIr::to_xml 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.
D1 · Cyclomatic Complexity · FormCommandSchema · ×1
  • FormCommandSchema::from_raw_layout (cyclomatic 17) crates/ibcmd-form-schema/src/lib.rs:1921 — FormCommandSchema::from_raw_layout 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 — the same kind of value, with no behaviour of its own — 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. This is NOT this file's highest cyclomatic complexity: FormInputFieldExtendedOptionSlot::index (cyclomatic 60) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
D1 · Cyclomatic Complexity · DialectRegistry · ×1
  • DialectRegistry::detect_with_policy (cyclomatic 17) crates/ibcmd-xml/src/dialect.rs:594 — DialectRegistry::detect_with_policy 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's highest cyclomatic complexity: DialectError::fmt (cyclomatic 21) is higher and carries no row of its own — 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 function is counted neither in this dimension's figures nor in its score.
D1 · Cyclomatic Complexity · exact_compare.main (cyclomatic 17) · ×1
  • exact_compare.main (cyclomatic 17) _onecdec/exact_compare.py:73 — exact_compare.main 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.
D1 · Cyclomatic Complexity · read_compact8_recovery.verify (cyclomatic 17) · ×1
  • read_compact8_recovery.verify (cyclomatic 17) docs/apply/evidence/live-gate/compact8-runtime-preexec/read_compact8_recovery.py:61 — read_compact8_recovery.verify 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.
D1 · Cyclomatic Complexity · xtask · ×1
  • xtask::main (cyclomatic 16) xtask/src/main.rs:57 — xtask::main 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 — the same kind of value, with no behaviour of its own — 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.
D1 · Cyclomatic Complexity · scsu_std.decode_bocu1 (cyclomatic 16) · ×1
  • scsu_std.decode_bocu1 (cyclomatic 16) _onecdec/scsu_std.py:106 — scsu_std.decode_bocu1 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.
D1 · Cyclomatic Complexity · verify_load.corpus (cyclomatic 16) · ×1
  • verify_load.corpus (cyclomatic 16) _onecdec/verify_load.py:54 — verify_load.corpus 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.
D1 · Cyclomatic Complexity · git-baseline.gitBaseline (cyclomatic 16) · ×1
  • git-baseline.gitBaseline (cyclomatic 16) editors/vscode/src/git-baseline.ts:7 — git-baseline.gitBaseline 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.
D2 · Cognitive Complexity · Writer · ×1
  • Writer::write_element (cognitive 83) REDACTED:983 — Writer::write_element has cognitive complexity 83 (threshold 15). Drivers by points: if/else 31 (55 pts), boolean chains 16, match/switch 3 (8 pts), loops 3 (4 pts) (nesting depth added 30). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · extension.activate (cognitive 69) · ×1
  • extension.activate (cognitive 69) editors/vscode/src/extension.ts:19 — extension.activate has cognitive complexity 69 (threshold 15). Drivers by points: if/else 29 (40 pts), boolean chains 16, error handling 4 (6 pts), ternaries 2 (5 pts), loops 2 (nesting depth added 16). Most of this is not in the body itself: 3 of the 69 points are its own statements and the rest belongs to 16 function literals inside it that branch (lines 652, 524, 854, …). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D2 · Cognitive Complexity · ObjectView.refresh (cognitive 63) · ×1
  • ObjectView.refresh (cognitive 63) editors/vscode/src/object-view.ts:164 — ObjectView.refresh has cognitive complexity 63 (threshold 15). Drivers by points: if/else 18 (26 pts), ternaries 11 (19 pts), boolean chains 12, loops 4 (5 pts), error handling 1 (nesting depth added 17). Most of this is not in the body itself: 6 of the 63 points are its own statements and the rest belongs to 3 function literals inside it that branch (lines 196, 271, 215). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D2 · Cognitive Complexity · ModelExport · ×1
  • ModelExport::build (cognitive 55) crates/ibcmd-dump/src/mssql_dump/model_export.rs:332 — ModelExport::build has cognitive complexity 55 (threshold 15). Drivers by points: if/else 15 (32 pts), loops 9 (14 pts), match/switch 2 (5 pts), boolean chains 4 (nesting depth added 25). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · extension.activate.importFiles (cognitive 54) · ×1
  • extension.activate.importFiles (cognitive 54) editors/vscode/src/extension.ts:253 — extension.activate.importFiles has cognitive complexity 54 (threshold 15). Drivers by points: if/else 15 (23 pts), boolean chains 13, ternaries 7 (13 pts), error handling 2 (3 pts), loops 1 (2 pts) (nesting depth added 16). Of this number, 30 points are the body's own statements and 24 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.
D2 · Cognitive Complexity · Projector · ×1
  • Projector::emit_adopted (cognitive 50) crates/ibcmd-dump/src/mssql_dump/extension/project.rs:187 — Projector::emit_adopted has cognitive complexity 50 (threshold 15). Drivers by points: if/else 11 (21 pts), loops 7 (11 pts), match/switch 5 (11 pts), boolean chains 7 (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.
D2 · Cognitive Complexity · CanonicalCoverageCorpus · ×1
  • CanonicalCoverageCorpus::validate (cognitive 47) crates/ibcmd-schema/src/lib.rs:12771 — CanonicalCoverageCorpus::validate has cognitive complexity 47 (threshold 15). Drivers by points: if/else 14 (36 pts), boolean chains 5, loops 3 (4 pts), match/switch 1 (2 pts) (nesting depth added 24). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · MigrationReport · ×1
  • MigrationReport::from_parts (cognitive 46) crates/ibcmd-core/src/migration/report.rs:800 — MigrationReport::from_parts has cognitive complexity 46 (threshold 15). Drivers by points: if/else 21 (35 pts), loops 4 (6 pts), boolean chains 4, 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.
D2 · Cognitive Complexity · DcsWriterEvidenceCorpus · ×1
  • DcsWriterEvidenceCorpus::validate (cognitive 46) crates/ibcmd-schema/src/lib.rs:11713 — DcsWriterEvidenceCorpus::validate has cognitive complexity 46 (threshold 15). Drivers by points: if/else 16 (24 pts), boolean chains 11, loops 6 (9 pts), match/switch 1 (2 pts) (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · extension.activate.edit (cognitive 44) · ×1
  • extension.activate.edit (cognitive 44) editors/vscode/src/extension.ts:697 — extension.activate.edit has cognitive complexity 44 (threshold 15). Drivers by points: if/else 16 (18 pts), boolean chains 14, ternaries 11 (12 pts) (nesting depth added 3). Of this number, 40 points are the body's own statements and 4 belong to 3 function literals inside it that branch. To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition.
D2 · Cognitive Complexity · extension.activate.switchTo (cognitive 41) · ×1
  • extension.activate.switchTo (cognitive 41) editors/vscode/src/extension.ts:113 — extension.activate.switchTo has cognitive complexity 41 (threshold 15). Drivers by points: if/else 23 (39 pts), error handling 2 (nesting depth added 16). Of this number, 28 points are the body's own statements and 13 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.
D2 · Cognitive Complexity · corpus_compare.main (cognitive 40) · ×1
  • corpus_compare.main (cognitive 40) _onecdec/corpus_compare.py:34 — corpus_compare.main has cognitive complexity 40 (threshold 15). Drivers by points: if/else 9 (18 pts), loops 6 (9 pts), ternaries 3 (6 pts), boolean chains 4, error handling 1 (3 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.
D2 · Cognitive Complexity · ConservativeGate · ×1
  • ConservativeGate::check (cognitive 38) REDACTED:289 — ConservativeGate::check has cognitive complexity 38 (threshold 15). Drivers by points: if/else 15 (27 pts), match/switch 2 (5 pts), boolean chains 3, loops 3 (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · MigrationStepReport · ×1
  • MigrationStepReport::from_parts (cognitive 37) crates/ibcmd-core/src/migration/report.rs:475 — MigrationStepReport::from_parts has cognitive complexity 37 (threshold 15). Drivers by points: if/else 11 (18 pts), boolean chains 11, loops 4 (5 pts), match/switch 2 (3 pts) (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · scsu_std.decode_bocu1 (cognitive 37) · ×1
  • scsu_std.decode_bocu1 (cognitive 37) _onecdec/scsu_std.py:106 — scsu_std.decode_bocu1 has cognitive complexity 37 (threshold 15). Drivers by points: if/else 12 (29 pts), loops 2 (4 pts), ternaries 1 (4 pts) (nesting depth added 22). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · verify_edit.main (cognitive 37) · ×1
  • verify_edit.main (cognitive 37) _onecdec/verify_edit.py:44 — verify_edit.main has cognitive complexity 37 (threshold 15). Drivers by points: if/else 14 (19 pts), ternaries 8 (13 pts), loops 2 (3 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.
D2 · Cognitive Complexity · ExternalOwnedSource · ×1
  • ExternalOwnedSource::from_tree (cognitive 36) crates/ibcmd-compiler/src/compiler/external_owned.rs:79 — ExternalOwnedSource::from_tree has cognitive complexity 36 (threshold 15). Drivers by points: if/else 9 (21 pts), loops 5 (8 pts), match/switch 2 (7 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.
D2 · Cognitive Complexity · big_compare_v85.main (cognitive 36) · ×1
  • big_compare_v85.main (cognitive 36) _onecdec/big_compare_v85.py:21 — big_compare_v85.main has cognitive complexity 36 (threshold 15). Drivers by points: if/else 8 (18 pts), loops 5 (8 pts), boolean chains 6, ternaries 1 (4 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.
D2 · Cognitive Complexity · big_compare.main (cognitive 35) · ×1
  • big_compare.main (cognitive 35) _onecdec/big_compare.py:40 — big_compare.main has cognitive complexity 35 (threshold 15). Drivers by points: if/else 8 (17 pts), loops 5 (8 pts), boolean chains 6, ternaries 1 (4 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.
D2 · Cognitive Complexity · object-export.exportObjects (cognitive 35) · ×1
  • object-export.exportObjects (cognitive 35) editors/vscode/src/object-export.ts:173 — object-export.exportObjects has cognitive complexity 35 (threshold 15). Drivers by points: if/else 14 (20 pts), loops 7, boolean chains 5, error handling 1 (2 pts), ternaries 1 (nesting depth added 7). Most of this is not in the body itself: 4 of the 35 points are its own statements and the rest belongs to 5 function literals inside it that branch (lines 209, 213, 267, …). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D2 · Cognitive Complexity · MetadataOrderCorpus · ×1
  • MetadataOrderCorpus::validate (cognitive 34) crates/ibcmd-schema/src/lib.rs:12994 — MetadataOrderCorpus::validate has cognitive complexity 34 (threshold 15). Drivers by points: if/else 9 (24 pts), loops 3 (5 pts), boolean chains 3, match/switch 1 (2 pts) (nesting depth added 18). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · WebServiceNativeIr · ×1
  • WebServiceNativeIr::to_xml (cognitive 33) crates/ibcmd-compiler-families/src/compiler/families/services.rs:923 — WebServiceNativeIr::to_xml has cognitive complexity 33 (threshold 15). Drivers by points: if/else 11 (18 pts), loops 8 (13 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.
D2 · Cognitive Complexity · SessionParameterNativeIr · ×1
  • SessionParameterNativeIr::to_xml (cognitive 33) crates/ibcmd-compiler-families/src/compiler/families/simple.rs:581 — SessionParameterNativeIr::to_xml has cognitive complexity 33 (threshold 15). Drivers by points: if/else 14 (29 pts), loops 2, match/switch 1 (2 pts) (nesting depth added 16). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body. This shape REPEATS in the file: one other method here (ibcmd_compiler_families::compiler::families::simple::write_type_pattern_xml) has the same decision points, in the same order, at the same nesting depths — 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.
D2 · Cognitive Complexity · config.editConfig (cognitive 33) · ×1
  • config.editConfig (cognitive 33) editors/vscode/src/config.ts:24 — config.editConfig has cognitive complexity 33 (threshold 15). Drivers by points: if/else 14 (18 pts), boolean chains 10, loops 3, ternaries 2 (nesting depth added 4). Of this number, 30 points are the body's own statements and 3 belong to 3 function literals inside it that branch. To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level.
D2 · Cognitive Complexity · ConfigDumpInfo · ×1
  • ConfigDumpInfo::parse (cognitive 32) crates/ibcmd-xml/src/config_dump_info.rs:109 — ConfigDumpInfo::parse has cognitive complexity 32 (threshold 15). Drivers by points: if/else 10 (23 pts), boolean chains 4, match/switch 2 (4 pts), loops 1 (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · Inventory · ×1
  • Inventory::walk (cognitive 31) crates/ibcmd-edt/src/disk.rs:37 — Inventory::walk has cognitive complexity 31 (threshold 15). Drivers by points: if/else 8 (23 pts), loops 2 (3 pts), match/switch 1 (3 pts), boolean chains 2 (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.
D2 · Cognitive Complexity · load_compare.main (cognitive 30) · ×1
  • load_compare.main (cognitive 30) _onecdec/load_compare.py:34 — load_compare.main has cognitive complexity 30 (threshold 15). Drivers by points: if/else 9 (22 pts), loops 3 (5 pts), boolean chains 3 (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · diff-full-snapshots.verify_ranges (cognitive 30) · ×1
  • diff-full-snapshots.verify_ranges (cognitive 30) docs/apply/evidence/platform85/extension-version-failed/diff-full-snapshots.py:11 — diff-full-snapshots.verify_ranges has cognitive complexity 30 (threshold 15). Drivers by points: if/else 7 (20 pts), loops 4 (8 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.
D2 · Cognitive Complexity · UpConversion · ×1
  • UpConversion::convert_item (cognitive 29) crates/ibcmd-form-writer/src/form/load_8_5_1.rs:1785 — UpConversion::convert_item has cognitive complexity 29 (threshold 15). Drivers by points: if/else 9 (14 pts), loops 4 (8 pts), boolean chains 5, 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.
D2 · Cognitive Complexity · FeatureSemanticsCorpus · ×1
  • FeatureSemanticsCorpus::validate (cognitive 29) crates/ibcmd-schema/src/lib.rs:12667 — FeatureSemanticsCorpus::validate has cognitive complexity 29 (threshold 15). Drivers by points: if/else 5 (18 pts), loops 4 (10 pts), boolean chains 1 (nesting depth added 19). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · verify_load.corpus (cognitive 29) · ×1
  • verify_load.corpus (cognitive 29) _onecdec/verify_load.py:54 — verify_load.corpus has cognitive complexity 29 (threshold 15). Drivers by points: if/else 10 (20 pts), loops 2 (4 pts), boolean chains 3, error handling 1 (2 pts) (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · read_compact8_recovery.read_live (cognitive 29) · ×1
  • read_compact8_recovery.read_live (cognitive 29) docs/apply/evidence/live-gate/compact8-runtime-preexec/read_compact8_recovery.py:24 — read_compact8_recovery.read_live has cognitive complexity 29 (threshold 15). Drivers by points: boolean chains 11, ternaries 4 (10 pts), loops 4 (5 pts), if/else 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.
D2 · Cognitive Complexity · database-commands.registerDatabaseCommands (cognitive 29) · ×1
  • database-commands.registerDatabaseCommands (cognitive 29) editors/vscode/src/database-commands.ts:16 — database-commands.registerDatabaseCommands has cognitive complexity 29 (threshold 15). Drivers by points: if/else 13, ternaries 7 (8 pts), boolean chains 7, error handling 1 (nesting depth added 1). None of this is in the body itself: all 29 points belong to 7 function items inside it that branch (a function literal at line 101, a function literal at line 88, a function literal at line 31, …). The named helpers are already separate functions; the literals' 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's 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.
D2 · Cognitive Complexity · BootstrapManifest · ×1
  • BootstrapManifest::validate (cognitive 27) crates/ibcmd-compiler-readiness/src/lib.rs:198 — BootstrapManifest::validate has cognitive complexity 27 (threshold 15). Drivers by points: if/else 10 (18 pts), loops 6 (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.
D2 · Cognitive Complexity · SiMain · ×1
  • SiMain::child_order (cognitive 27) crates/ibcmd-restructure-engine/src/si.rs:328 — SiMain::child_order has cognitive complexity 27 (threshold 15). Drivers by points: loops 8 (15 pts), if/else 4 (11 pts), boolean chains 1 (nesting depth added 14). 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.
D2 · Cognitive Complexity · DialectRegistry · ×1
  • DialectRegistry::detect_with_policy (cognitive 27) crates/ibcmd-xml/src/dialect.rs:594 — DialectRegistry::detect_with_policy has cognitive complexity 27 (threshold 15). Drivers by points: if/else 12 (16 pts), loops 5 (10 pts), match/switch 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.
D2 · Cognitive Complexity · stress_load.one (cognitive 27) · ×1
  • stress_load.one (cognitive 27) _onecdec/stress_load.py:110 — stress_load.one has cognitive complexity 27 (threshold 15). Drivers by points: if/else 12 (17 pts), boolean chains 4, error handling 1 (2 pts), loops 1 (2 pts), ternaries 1 (2 pts) (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · extension.activate.runExport (cognitive 27) · ×1
  • extension.activate.runExport (cognitive 27) editors/vscode/src/extension.ts:426 — extension.activate.runExport has cognitive complexity 27 (threshold 15). Drivers by points: if/else 9 (13 pts), ternaries 3 (8 pts), boolean chains 5, error handling 1 (nesting depth added 9). Of this number, 26 points are the body's 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.
D2 · Cognitive Complexity · NativeParser · ×1
  • NativeParser::outline_list (cognitive 26) crates/ibcmd-compiler-families/src/compiler/families/native.rs:983 — NativeParser::outline_list has cognitive complexity 26 (threshold 15). Drivers by points: if/else 9 (19 pts), match/switch 2 (4 pts), loops 2, 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.
D2 · Cognitive Complexity · database-files.differences (cognitive 26) · ×1
  • database-files.differences (cognitive 26) editors/vscode/src/database-files.ts:134 — database-files.differences has cognitive complexity 26 (threshold 15). Drivers by points: if/else 6 (18 pts), loops 3 (6 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.
D2 · Cognitive Complexity · WriterRuleCorpus · ×1
  • WriterRuleCorpus::validate (cognitive 25) crates/ibcmd-schema/src/lib.rs:12529 — WriterRuleCorpus::validate has cognitive complexity 25 (threshold 15). Drivers by points: if/else 7 (18 pts), loops 2 (3 pts), match/switch 1 (3 pts), boolean chains 1 (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · XmlReader · ×1
  • XmlReader::parse (cognitive 25) crates/ibcmd-xml/src/reader.rs:91 — XmlReader::parse has cognitive complexity 25 (threshold 15). Drivers by points: if/else 9 (17 pts), match/switch 2 (4 pts), boolean chains 2, loops 2 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · CanonicalValue · ×1
  • CanonicalValue::fmt (cognitive 24) crates/ibcmd-core/src/value.rs:669 — CanonicalValue::fmt has cognitive complexity 24 (threshold 15). Drivers by points: if/else 2 (10 pts), loops 3 (9 pts), match/switch 2 (5 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.
D2 · Cognitive Complexity · Record · ×1
  • Record::from_brace (cognitive 24) crates/ibcmd-metadata-model/src/metadata_model/external_data_source.rs:136 — Record::from_brace has cognitive complexity 24 (threshold 15). Drivers by points: if/else 10 (14 pts), boolean chains 6, 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.
D2 · Cognitive Complexity · exact_compare.main (cognitive 24) · ×1
  • exact_compare.main (cognitive 24) _onecdec/exact_compare.py:73 — exact_compare.main has cognitive complexity 24 (threshold 15). Drivers by points: if/else 7 (9 pts), loops 4 (7 pts), ternaries 2 (5 pts), boolean chains 3 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · ConfigurationView.constructor (cognitive 24) · ×1
  • ConfigurationView.constructor (cognitive 24) editors/vscode/src/configuration-view.ts:26 — ConfigurationView.constructor has cognitive complexity 24 (threshold 15). Drivers by points: if/else 12 (13 pts), boolean chains 6, ternaries 2 (3 pts), error handling 2 (nesting depth added 2). None of this is in the body itself: all 24 points belong to 6 function literals inside it that branch (lines 76, 62, 89, …). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D2 · Cognitive Complexity · MainActivationPlan · ×1
  • MainActivationPlan::dry_run_report (cognitive 23) REDACTED:342 — MainActivationPlan::dry_run_report has cognitive complexity 23 (threshold 15). Drivers by points: boolean chains 12, if/else 11. 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.
D2 · Cognitive Complexity · ibcmd_sql · ×1
  • ibcmd_sql::sql::mssql::script::scan_line (cognitive 23) crates/ibcmd-sql/src/sql/mssql/script.rs:136 — ibcmd_sql::sql::mssql::script::scan_line has cognitive complexity 23 (threshold 15). Drivers by points: match/switch 6 (17 pts), if/else 2 (5 pts), loops 1 (nesting depth added 14). 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.
D2 · Cognitive Complexity · upgrade_rules.parse (cognitive 23) · ×1
  • upgrade_rules.parse (cognitive 23) _onecdec/upgrade_rules.py:19 — upgrade_rules.parse has cognitive complexity 23 (threshold 15). Drivers by points: if/else 8 (20 pts), boolean chains 2, loops 1 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · upgrade_sim.generalize (cognitive 23) · ×1
  • upgrade_sim.generalize (cognitive 23) _onecdec/upgrade_sim.py:83 — upgrade_sim.generalize has cognitive complexity 23 (threshold 15). Drivers by points: if/else 6 (14 pts), loops 4 (6 pts), boolean chains 3 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · read_compact8_recovery.verify (cognitive 23) · ×1
  • read_compact8_recovery.verify (cognitive 23) docs/apply/evidence/live-gate/compact8-runtime-preexec/read_compact8_recovery.py:61 — read_compact8_recovery.verify has cognitive complexity 23 (threshold 15). Drivers by points: ternaries 5 (10 pts), boolean chains 7, loops 3 (4 pts), if/else 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.
D2 · Cognitive Complexity · git-baseline.gitBaseline (cognitive 23) · ×1
  • git-baseline.gitBaseline (cognitive 23) editors/vscode/src/git-baseline.ts:7 — git-baseline.gitBaseline has cognitive complexity 23 (threshold 15). Drivers by points: if/else 10 (15 pts), ternaries 2 (5 pts), boolean chains 2, loops 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · OpaqueAssetVisitor · ×1
  • OpaqueAssetVisitor::visit_map (cognitive 22) crates/ibcmd-core/src/opaque.rs:269 — OpaqueAssetVisitor::visit_map has cognitive complexity 22 (threshold 15). Drivers by points: if/else 7 (18 pts), match/switch 1 (2 pts), boolean chains 1, loops 1 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · ibcmd_dump_readers · ×1
  • ibcmd_dump_readers::extension::predefined::rewrite (cognitive 22) crates/ibcmd-dump-readers/src/extension/predefined.rs:106 — ibcmd_dump_readers::extension::predefined::rewrite has cognitive complexity 22 (threshold 15). Drivers by points: if/else 8 (19 pts), boolean chains 2, loops 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · SchemaPlan · ×1
  • SchemaPlan::build (cognitive 22) REDACTED:157 — SchemaPlan::build has cognitive complexity 22 (threshold 15). Drivers by points: if/else 8 (19 pts), loops 2 (3 pts) (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · RpcClient.receive (cognitive 22) · ×1
  • RpcClient.receive (cognitive 22) editors/vscode/src/rpc.ts:114 — RpcClient.receive has cognitive complexity 22 (threshold 15). Drivers by points: if/else 10 (21 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.
D2 · Cognitive Complexity · configuration-tree.descriptor · ×1
  • configuration-tree.descriptor::contained (cognitive 22) editors/vscode/src/configuration-tree.ts:298 — configuration-tree.descriptor::contained has cognitive complexity 22 (threshold 15). Drivers by points: if/else 5 (11 pts), ternaries 3 (6 pts), loops 2 (5 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.
D2 · Cognitive Complexity · Upgrade · ×1
  • Upgrade::emit_table (cognitive 21) crates/ibcmd-dump/src/mssql_dump/extension/form.rs:308 — Upgrade::emit_table has cognitive complexity 21 (threshold 15). Drivers by points: if/else 4 (10 pts), loops 2 (5 pts), boolean chains 3, match/switch 2 (3 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.
D2 · Cognitive Complexity · ServiceScope · ×1
  • ServiceScope::from_schemas (cognitive 21) REDACTED:501 — ServiceScope::from_schemas has cognitive complexity 21 (threshold 15). Drivers by points: if/else 7 (15 pts), loops 4 (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.
D2 · Cognitive Complexity · gen_external_corpus.main (cognitive 21) · ×1
  • gen_external_corpus.main (cognitive 21) _onecdec/gen_external_corpus.py:83 — gen_external_corpus.main has cognitive complexity 21 (threshold 15). Drivers by points: if/else 7 (11 pts), loops 4 (6 pts), error handling 1 (2 pts), ternaries 2 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · verify_load.cf (cognitive 21) · ×1
  • verify_load.cf (cognitive 21) _onecdec/verify_load.py:123 — verify_load.cf has cognitive complexity 21 (threshold 15). Drivers by points: if/else 6 (12 pts), loops 4 (5 pts), boolean chains 2, ternaries 1 (2 pts) (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · DatabaseSource.children (cognitive 21) · ×1
  • DatabaseSource.children (cognitive 21) editors/vscode/src/configuration-tree.ts:505 — DatabaseSource.children has cognitive complexity 21 (threshold 15). Drivers by points: if/else 9 (12 pts), ternaries 5, boolean chains 4 (nesting depth added 3). Of this number, 16 points are the body's own statements and 5 belong to one function literal inside it that branches. To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition.
D2 · Cognitive Complexity · Ownership · ×1
  • Ownership::new (cognitive 20) crates/ibcmd-dump/src/mssql_dump/incremental.rs:525 — Ownership::new has cognitive complexity 20 (threshold 15). Drivers by points: if/else 9 (19 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.
D2 · Cognitive Complexity · Session · ×1
  • Session::open (cognitive 20) src/server/infobases.rs:401 — Session::open has cognitive complexity 20 (threshold 15). Drivers by points: if/else 10 (13 pts), boolean chains 5, match/switch 2 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition.
D2 · Cognitive Complexity · XmlSource.children (cognitive 20) · ×1
  • XmlSource.children (cognitive 20) editors/vscode/src/configuration-tree.ts:416 — XmlSource.children has cognitive complexity 20 (threshold 15). Drivers by points: if/else 12 (16 pts), boolean chains 1, error handling 1, loops 1, ternaries 1 (nesting depth added 4). Most of this is not in the body itself: 8 of the 20 points are its own statements and the rest belongs to one function item inside it that branches (walk). 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.
D2 · Cognitive Complexity · Verdict · ×1
  • Verdict::render_text (cognitive 19) crates/ibcmd-apply-check/src/apply_check/model.rs:275 — Verdict::render_text has cognitive complexity 19 (threshold 15). Drivers by points: if/else 11 (14 pts), loops 2 (4 pts), match/switch 1 (nesting depth added 5). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level.
D2 · Cognitive Complexity · SourceOwnerPreimages · ×1
  • SourceOwnerPreimages::capture_client (cognitive 19) REDACTED:104 — SourceOwnerPreimages::capture_client has cognitive complexity 19 (threshold 15). Drivers by points: if/else 5 (9 pts), loops 6 (7 pts), match/switch 1 (2 pts), boolean chains 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · MigrationGraph · ×1
  • MigrationGraph::shortest_paths (cognitive 19) crates/ibcmd-core/src/migration/graph.rs:573 — MigrationGraph::shortest_paths has cognitive complexity 19 (threshold 15). Drivers by points: if/else 4 (12 pts), loops 2 (3 pts), match/switch 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.
D2 · Cognitive Complexity · OfflineFormContextFactory · ×1
  • OfflineFormContextFactory::from_plain_rows (cognitive 19) crates/ibcmd-dump/src/mssql_dump/offline_context.rs:128 — OfflineFormContextFactory::from_plain_rows has cognitive complexity 19 (threshold 15). Drivers by points: loops 12 (13 pts), match/switch 2 (4 pts), if/else 2 (nesting depth added 3). 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.
D2 · Cognitive Complexity · Settings · ×1
  • Settings::from_sources (cognitive 19) src/settings.rs:393 — Settings::from_sources has cognitive complexity 19 (threshold 15). Drivers by points: if/else 8 (16 pts), loops 2 (3 pts) (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · Shared · ×1
  • Shared::ensure_folder (cognitive 18) crates/ibcmd-dump/src/mssql_dump/output_writer.rs:194 — Shared::ensure_folder has cognitive complexity 18 (threshold 15). Drivers by points: if/else 5 (8 pts), loops 3 (4 pts), match/switch 2 (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.
D2 · Cognitive Complexity · Object · ×1
  • Object::open (cognitive 18) crates/ibcmd-filedb/src/object.rs:40 — Object::open has cognitive complexity 18 (threshold 15). Drivers by points: if/else 5 (10 pts), loops 3 (6 pts), match/switch 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.
D2 · Cognitive Complexity · GuardedUndoPlan · ×1
  • GuardedUndoPlan::render_into (cognitive 18) REDACTED:466 — GuardedUndoPlan::render_into has cognitive complexity 18 (threshold 15). Drivers by points: loops 7 (12 pts), if/else 3 (6 pts) (nesting depth added 8). 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.
D2 · Cognitive Complexity · Service · ×1
  • Service::parse (cognitive 18) crates/ibcmd-restructure/src/scheduled_jobs.rs:90 — Service::parse has cognitive complexity 18 (threshold 15). Drivers by points: if/else 7 (13 pts), loops 2 (3 pts), boolean chains 2 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · ExternalNamedOwnerContext · ×1
  • ExternalNamedOwnerContext::from_root (cognitive 18) crates/ibcmd-xml/src/metadata/external_named.rs:39 — ExternalNamedOwnerContext::from_root has cognitive complexity 18 (threshold 15). Drivers by points: if/else 4 (11 pts), loops 2 (4 pts), boolean chains 2, match/switch 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.
D2 · Cognitive Complexity · ConfigDumpInfoSnapshot · ×1
  • ConfigDumpInfoSnapshot::owners (cognitive 18) src/native_export_status.rs:41 — ConfigDumpInfoSnapshot::owners has cognitive complexity 18 (threshold 15). Drivers by points: if/else 7 (11 pts), boolean chains 6, loops 1 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · base_free_round.main (cognitive 18) · ×1
  • base_free_round.main (cognitive 18) _onecdec/base_free_round.py:53 — base_free_round.main has cognitive complexity 18 (threshold 15). Drivers by points: if/else 6 (11 pts), loops 3 (5 pts), boolean chains 1, ternaries 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · stress_load.main (cognitive 18) · ×1
  • stress_load.main (cognitive 18) _onecdec/stress_load.py:164 — stress_load.main has cognitive complexity 18 (threshold 15). Drivers by points: if/else 6 (10 pts), ternaries 5 (6 pts), loops 2 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · ibcmd_compiler_readiness · ×1
  • ibcmd_compiler_readiness::validate_declaration (cognitive 17) crates/ibcmd-compiler-readiness/src/lib.rs:604 — ibcmd_compiler_readiness::validate_declaration has cognitive complexity 17 (threshold 15). Drivers by points: if/else 7 (12 pts), boolean chains 2, loops 2, match/switch 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · XmlEdits · ×1
  • XmlEdits::place_child (cognitive 17) crates/ibcmd-form-writer/src/form/xml_2_21_writer.rs:282 — XmlEdits::place_child has cognitive complexity 17 (threshold 15). Drivers by points: if/else 3 (8 pts), match/switch 4 (6 pts), loops 2 (3 pts) (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · TypeIndex · ×1
  • TypeIndex::parse (cognitive 17) crates/ibcmd-restructure-engine/src/restructure/caches/type_index.rs:50 — TypeIndex::parse has cognitive complexity 17 (threshold 15). Drivers by points: if/else 6 (11 pts), loops 3 (6 pts) (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · ObjectDecoder · ×1
  • ObjectDecoder::finish (cognitive 17) crates/ibcmd-xml/src/metadata/common.rs:906 — ObjectDecoder::finish has cognitive complexity 17 (threshold 15). Drivers by points: if/else 6 (11 pts), boolean chains 3, loops 1 (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.
D2 · Cognitive Complexity · stress_forms.main (cognitive 17) · ×1
  • stress_forms.main (cognitive 17) _onecdec/stress_forms.py:18 — stress_forms.main has cognitive complexity 17 (threshold 15). Drivers by points: if/else 6 (9 pts), error handling 1 (3 pts), boolean chains 2, loops 2, ternaries 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · stress_load.edit (cognitive 17) · ×1
  • stress_load.edit (cognitive 17) _onecdec/stress_load.py:51 — stress_load.edit has cognitive complexity 17 (threshold 15). Drivers by points: if/else 7 (13 pts), loops 3, boolean chains 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · DcsSchema · ×1
  • DcsSchema::new_parts (cognitive 16) crates/ibcmd-core/src/dcs_schema.rs:1845 — DcsSchema::new_parts has cognitive complexity 16 (threshold 15). Drivers by points: if/else 11 (13 pts), boolean chains 2, loops 1 (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level.
D2 · Cognitive Complexity · GraphIndex · ×1
  • GraphIndex::new (cognitive 16) crates/ibcmd-core/src/graph.rs:126 — GraphIndex::new has cognitive complexity 16 (threshold 15). Drivers by points: if/else 3 (8 pts), match/switch 2 (5 pts), loops 2 (3 pts) (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · SourceTreeRoleRightsSource · ×1
  • SourceTreeRoleRightsSource::object_node (cognitive 16) crates/ibcmd-metadata-blob/src/role_rights_writer.rs:1077 — SourceTreeRoleRightsSource::object_node has cognitive complexity 16 (threshold 15). Drivers by points: if/else 7 (9 pts), loops 2 (4 pts), boolean chains 3 (nesting depth added 4). To reduce it, split the body: this score is breadth rather than depth — many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D2 · Cognitive Complexity · ConfigIndex · ×1
  • ConfigIndex::assemble (cognitive 16) crates/ibcmd-metadata-model/src/metadata_model/index.rs:180 — ConfigIndex::assemble has cognitive complexity 16 (threshold 15). Drivers by points: if/else 4 (7 pts), loops 3 (5 pts), match/switch 1 (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.
D2 · Cognitive Complexity · MssqlClient · ×1
  • MssqlClient::write_rows (cognitive 16) crates/ibcmd-sql/src/sql/mssql/mod.rs:108 — MssqlClient::write_rows has cognitive complexity 16 (threshold 15). Drivers by points: if/else 7 (9 pts), match/switch 3 (5 pts), loops 2 (nesting depth added 4). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level.
D2 · Cognitive Complexity · ibcmd_v8 · ×1
  • ibcmd_v8::reader::index_chain (cognitive 16) crates/ibcmd-v8/src/reader.rs:747 — ibcmd_v8::reader::index_chain has cognitive complexity 16 (threshold 15). Drivers by points: if/else 7 (15 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.
D2 · Cognitive Complexity · MetadataEnvelope · ×1
  • MetadataEnvelope::from_parts_with_external_state (cognitive 16) crates/ibcmd-xml/src/metadata/common.rs:209 — MetadataEnvelope::from_parts_with_external_state has cognitive complexity 16 (threshold 15). Drivers by points: if/else 10 (12 pts), loops 2 (3 pts), boolean chains 1 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level.
D2 · Cognitive Complexity · SourceTree · ×1
  • SourceTree::validate (cognitive 16) crates/ibcmd-xml/src/source_tree/mod.rs:262 — SourceTree::validate has cognitive complexity 16 (threshold 15). Drivers by points: if/else 5 (10 pts), loops 4 (5 pts), boolean chains 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · FilesSelection · ×1
  • FilesSelection::trim (cognitive 16) src/mssql/files_stage.rs:240 — FilesSelection::trim has cognitive complexity 16 (threshold 15). Drivers by points: if/else 6 (10 pts), boolean chains 3, loops 3 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · gen_external_corpus.make_source (cognitive 16) · ×1
  • gen_external_corpus.make_source (cognitive 16) _onecdec/gen_external_corpus.py:46 — gen_external_corpus.make_source has cognitive complexity 16 (threshold 15). Drivers by points: if/else 3 (10 pts), loops 3 (6 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.
D2 · Cognitive Complexity · spike_adapter.fields (cognitive 16) · ×1
  • spike_adapter.fields (cognitive 16) _onecdec/spike_adapter.py:12 — spike_adapter.fields has cognitive complexity 16 (threshold 15). Drivers by points: if/else 5 (13 pts), boolean chains 2, loops 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · spike_compare.one (cognitive 16) · ×1
  • spike_compare.one (cognitive 16) _onecdec/spike_compare.py:22 — spike_compare.one has cognitive complexity 16 (threshold 15). Drivers by points: if/else 8 (11 pts), boolean chains 3, loops 1, ternaries 1 (nesting depth added 3). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D29 · Static Analysis (SAST) · REDACTED · ×1
  • REDACTED
D29 · Static Analysis (SAST) · REDACTED · ×1
  • REDACTED
D35 · Change Coupling · Change-coupling hub · ×1
  • Change-coupling hub: help.rs → cli.rs, infobase.rs, infobase_oracle.rs src/dropin/help.rs — `src/dropin/help.rs` changes together with 3 other files — `src/cli.rs`, `src/infobase.rs`, `src/infobase_oracle.rs` — none of which declares a dependency on it: one file is the hub of 3 separate couplings, not 3 unrelated pairs. Read the hub first: if the others each duplicate a part of what it does, the shared concern belongs in ONE unit and extracting it clears every edge at once; if the hub is a registry, dispatcher or barrel that must name each of them, the coupling is structural and the question is whether that list can be discovered instead of enumerated. Fixing the hub is one change; breaking the couplings one pair at a time is 3.
D36 · Supply-chain Provenance & Signing · REDACTED · ×1
  • REDACTED
D36 · Supply-chain Provenance & Signing · REDACTED · ×1
  • REDACTED
D4 · Code Duplication · Near-duplicate member family (4 members, 82 shared lines) · ×1
  • Near-duplicate member family (4 members, 82 shared lines) crates/ibcmd-dump/src/mssql_dump/mod.rs:27681 — crates/ibcmd-dump/src/mssql_dump/mod.rs:27681-27913 | crates/ibcmd-dump/src/mssql_dump/mod.rs:28527-28697 | crates/ibcmd-dump/src/mssql_dump/mod.rs:30040-30187 | crates/ibcmd-dump/src/mssql_dump/mod.rs:31331-31489 — These 4 members are variants of one another: a block of 82 lines reported below appears in every one of them, and the pairwise near-duplicate rows they would otherwise produce are collapsed into this row. Read them as one construct written 4 times. The repair is at the members' grain — factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 4 times.
D4 · Code Duplication · Near-duplicate member family (4 members, 25 shared lines) · ×1
  • Near-duplicate member family (4 members, 25 shared lines) crates/ibcmd-metadata-blob/src/lib.rs:5051 — crates/ibcmd-metadata-blob/src/lib.rs:5051-5110 | crates/ibcmd-metadata-blob/src/lib.rs:5216-5265 | crates/ibcmd-metadata-blob/src/lib.rs:5558-5665 | crates/ibcmd-metadata-blob/src/lib.rs:5670-5776 — These 4 members are variants of one another: a block of 25 lines reported below appears in every one of them, and the pairwise near-duplicate rows they would otherwise produce are collapsed into this row. Read them as one construct written 4 times. The repair is at the members' grain — factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 4 times.
D4 · Code Duplication · Near-duplicate member family (3 members, 25 shared lines) · ×1
  • Near-duplicate member family (3 members, 25 shared lines) crates/ibcmd-metadata-blob/src/lib.rs:2328 — crates/ibcmd-metadata-blob/src/lib.rs:2328-2394 | crates/ibcmd-metadata-blob/src/lib.rs:3221-3293 | crates/ibcmd-metadata-blob/src/lib.rs:3299-3365 — These 3 members are variants of one another: a block of 25 lines reported below appears in every one of them, and the pairwise near-duplicate rows they would otherwise produce are collapsed into this row. Read them as one construct written 3 times. The repair is at the members' grain — factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 3 times.
D4 · Code Duplication · Near-duplicate member family (3 members, 16 shared lines) · ×1
  • Near-duplicate member family (3 members, 16 shared lines) crates/ibcmd-dump/src/mssql_dump/mod.rs:30516 — crates/ibcmd-dump/src/mssql_dump/mod.rs:30516-30546 | crates/ibcmd-dump/src/mssql_dump/mod.rs:31184-31220 | crates/ibcmd-dump/src/mssql_dump/mod.rs:32210-32241 — These 3 members are variants of one another: a block of 16 lines reported below appears in every one of them, and the pairwise near-duplicate rows they would otherwise produce are collapsed into this row. Read them as one construct written 3 times. The repair is at the members' grain — factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 3 times.
D4 · Code Duplication · Near-duplicate member pair (69 shared lines) · ×1
  • Near-duplicate member pair (69 shared lines) crates/ibcmd-xml/src/dcs_template.rs:393 — crates/ibcmd-xml/src/dcs_template.rs:393-566 | crates/ibcmd-xml/src/dcs_template.rs:831-998 — These two members are variants of one another: 69 of their lines are already reported as duplicated blocks below, spread through both bodies rather than gathered into one. Read them as a single construct written twice. The repair is at the members' grain — factor the shared pipeline into one implementation the two call with their differences as parameters or as an injected step, or, where the difference is systematic (sync against async, one transport against another), generate one from the other. Extracting the individual blocks below is not the same fix: it leaves the two bodies in place and the next edit still has to be made twice.
D4 · Code Duplication · Near-duplicate member pair (61 shared lines) · ×1
  • Near-duplicate member pair (61 shared lines) REDACTED:1840 — REDACTED:1840-1952 | crates/ibcmd-config-apply/src/mssql_config_apply/mod.rs:1769-1951 — These two members are variants of one another: 61 of their lines are already reported as duplicated blocks below, spread through both bodies rather than gathered into one. Read them as a single construct written twice. The repair is at the members' grain — factor the shared pipeline into one implementation the two call with their differences as parameters or as an injected step, or, where the difference is systematic (sync against async, one transport against another), generate one from the other. Extracting the individual blocks below is not the same fix: it leaves the two bodies in place and the next edit still has to be made twice.
D4 · Code Duplication · Near-duplicate member pair (55 shared lines) · ×1
  • Near-duplicate member pair (55 shared lines) crates/ibcmd-dump/src/mssql_dump/mod.rs:23175 — crates/ibcmd-dump/src/mssql_dump/mod.rs:23175-23292 | crates/ibcmd-dump/src/mssql_dump/mod.rs:23541-23662 — These two members are variants of one another: 55 of their lines are already reported as duplicated blocks below, spread through both bodies rather than gathered into one. Read them as a single construct written twice. The repair is at the members' grain — factor the shared pipeline into one implementation the two call with their differences as parameters or as an injected step, or, where the difference is systematic (sync against async, one transport against another), generate one from the other. Extracting the individual blocks below is not the same fix: it leaves the two bodies in place and the next edit still has to be made twice.
D4 · Code Duplication · Near-duplicate member pair (53 shared lines) · ×1
  • Near-duplicate member pair (53 shared lines) src/source_audit.rs:1920 — src/source_audit.rs:1920-2036 | src/source_audit.rs:2196-2363 — These two members are variants of one another: 53 of their lines are already reported as duplicated blocks below, spread through both bodies rather than gathered into one. Read them as a single construct written twice. The repair is at the members' grain — factor the shared pipeline into one implementation the two call with their differences as parameters or as an injected step, or, where the difference is systematic (sync against async, one transport against another), generate one from the other. Extracting the individual blocks below is not the same fix: it leaves the two bodies in place and the next edit still has to be made twice.
D4 · Code Duplication · Near-duplicate member pair (49 shared lines) · ×1
  • Near-duplicate member pair (49 shared lines) crates/ibcmd-dump/src/mssql_dump/forms.rs:135 — crates/ibcmd-dump/src/mssql_dump/forms.rs:135-188 | crates/ibcmd-dump/src/mssql_dump/mod.rs:33413-33466 — 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' grain — factor the shared pipeline into one implementation the two call with their differences as parameters or as an injected step, or, where the difference is systematic (sync against async, one transport against another), generate one from the other. Extracting the individual blocks below is not the same fix: it leaves the two bodies in place and the next edit still has to be made twice.
D4 · Code Duplication · Near-duplicate member pair (47 shared lines) · ×1
  • Near-duplicate member pair (47 shared lines) crates/ibcmd-xml/src/dcs_schema.rs:1498 — crates/ibcmd-xml/src/dcs_schema.rs:1498-1599 | crates/ibcmd-xml/src/dcs_schema.rs:1620-1759 — These two members are variants of one another: 47 of their lines are already reported as duplicated blocks below, spread through both bodies rather than gathered into one. Read them as a single construct written twice. The repair is at the members' grain — factor the shared pipeline into one implementation the two call with their differences as parameters or as an injected step, or, where the difference is systematic (sync against async, one transport against another), generate one from the other. Extracting the individual blocks below is not the same fix: it leaves the two bodies in place and the next edit still has to be made twice.
D4 · Code Duplication · Near-duplicate member pair (46 shared lines) · ×1
  • Near-duplicate member pair (46 shared lines) crates/ibcmd-dump/src/mssql_dump/mod.rs:32355 — crates/ibcmd-dump/src/mssql_dump/mod.rs:32355-32436 | crates/ibcmd-dump/src/mssql_dump/mod.rs:32989-33078 — These two members are variants of one another: 46 of their lines are already reported as duplicated blocks below, spread through both bodies rather than gathered into one. Read them as a single construct written twice. The repair is at the members' grain — factor the shared pipeline into one implementation the two call with their differences as parameters or as an injected step, or, where the difference is systematic (sync against async, one transport against another), generate one from the other. Extracting the individual blocks below is not the same fix: it leaves the two bodies in place and the next edit still has to be made twice.
D4 · Code Duplication · Near-duplicate member pair (34 shared lines) · ×1
  • Near-duplicate member pair (34 shared lines) crates/ibcmd-dump/src/mssql_dump/mod.rs:25274 — crates/ibcmd-dump/src/mssql_dump/mod.rs:25274-25336 | crates/ibcmd-dump/src/mssql_dump/mod.rs:25679-25746 — 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' grain — factor the shared pipeline into one implementation the two call with their differences as parameters or as an injected step, or, where the difference is systematic (sync against async, one transport against another), generate one from the other. Extracting the individual blocks below is not the same fix: it leaves the two bodies in place and the next edit still has to be made twice.
D4 · Code Duplication · Members sharing a duplicated core (40 members, 50+ identical tokens) · ×1
  • Members sharing a duplicated core (40 members, 50+ identical tokens) REDACTED:4461 — REDACTED:4461-4473 | REDACTED:4577-4589 | REDACTED:4593-4605 | REDACTED:4609-4621 | REDACTED:4625-4637 | REDACTED:4641-4653 | REDACTED:4657-4669 | REDACTED:4673-4685 | REDACTED:4689-4701 | REDACTED:4703-4715 | REDACTED:4719-4731 | REDACTED:4735-4747 | REDACTED:4751-4763 | REDACTED:4767-4779 | REDACTED:4783-4795 | REDACTED:4799-4811 | REDACTED:4815-4827 | REDACTED:4831-4843 | REDACTED:4847-4859 | REDACTED:4863-4875 | REDACTED:4879-4891 | REDACTED:4895-4907 | REDACTED:4911-4923 | REDACTED:4940-4952 | REDACTED:4956-4968 | REDACTED:4972-4984 | REDACTED:4986-4998 | REDACTED:5002-5014 | REDACTED:5018-5030 | REDACTED:5034-5046 | REDACTED:5050-5062 | REDACTED:5066-5078 | REDACTED:5082-5094 | REDACTED:5098-5110 | REDACTED:5114-5126 | REDACTED:5130-5142 | REDACTED:5146-5158 | REDACTED:5162-5174 | REDACTED:5178-5190 | REDACTED:5194-5206 — These 40 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below — it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 40 times. The repair is at the members' grain — factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 40 times.
D4 · Code Duplication · Members sharing a duplicated core (17 members, 50+ identical tokens) · ×1
  • Members sharing a duplicated core (17 members, 50+ identical tokens) crates/ibcmd-xml/src/metadata/business_objects.rs:1219 — crates/ibcmd-xml/src/metadata/business_objects.rs:1219-1267 | crates/ibcmd-xml/src/metadata/common_objects.rs:401-444 | crates/ibcmd-xml/src/metadata/constant.rs:611-642 | crates/ibcmd-xml/src/metadata/functional_option.rs:336-374 | crates/ibcmd-xml/src/metadata/functional_options_parameter.rs:318-360 | crates/ibcmd-xml/src/metadata/hierarchical_objects.rs:819-862 | crates/ibcmd-xml/src/metadata/language.rs:336-365 | crates/ibcmd-xml/src/metadata/register_objects.rs:1006-1049 | crates/ibcmd-xml/src/metadata/services.rs:2521-2559 | crates/ibcmd-xml/src/metadata/services.rs:2564-2603 | crates/ibcmd-xml/src/metadata/services.rs:2608-2646 | crates/ibcmd-xml/src/metadata/services.rs:2651-2689 | crates/ibcmd-xml/src/metadata/services.rs:2694-2732 | crates/ibcmd-xml/src/metadata/services.rs:2737-2775 | crates/ibcmd-xml/src/metadata/services.rs:2780-2819 | crates/ibcmd-xml/src/metadata/session_parameter.rs:716-760 | crates/ibcmd-xml/src/metadata/utility_objects.rs:693-736 — These 17 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below — it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 17 times. The repair is at the members' grain — factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 17 times.
D4 · Code Duplication · Edited copy of a member (369 corresponding lines) · ×1
  • Edited copy of a member (369 corresponding lines) crates/ibcmd-dump/src/mssql_dump/mod.rs:29450 — crates/ibcmd-dump/src/mssql_dump/mod.rs:29450-29865 | crates/ibcmd-dump/src/mssql_dump/mod.rs:30642-31010 — These two members are one piece of code written twice and then edited apart: 369 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copy of a member (138 corresponding lines) · ×1
  • Edited copy of a member (138 corresponding lines) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:3305 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:3305-3442 | crates/ibcmd-compiler-families/src/compiler/families/utility.rs:1649-1788 — These two members are one piece of code written twice and then edited apart: 138 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copy of a member (113 corresponding lines) · ×1
  • Edited copy of a member (113 corresponding lines) crates/ibcmd-dump/src/mssql_dump/mod.rs:28705 — crates/ibcmd-dump/src/mssql_dump/mod.rs:28705-28849 | crates/ibcmd-dump/src/mssql_dump/mod.rs:30193-30305 — These two members are one piece of code written twice and then edited apart: 113 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copy of a member (127 corresponding lines) · ×1
  • Edited copy of a member (127 corresponding lines) crates/ibcmd-compiler-families/src/compiler/families/services.rs:1899 — crates/ibcmd-compiler-families/src/compiler/families/services.rs:1899-2025 | crates/ibcmd-compiler-families/src/compiler/families/services.rs:2030-2208 — These two members are one piece of code written twice and then edited apart: 127 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copy of a member (97 corresponding lines) · ×1
  • Edited copy of a member (97 corresponding lines) crates/ibcmd-compiler-families/src/compiler/families/services.rs:3826 — crates/ibcmd-compiler-families/src/compiler/families/services.rs:3826-3922 | crates/ibcmd-compiler-families/src/compiler/families/services.rs:3924-4042 — These two members are one piece of code written twice and then edited apart: 97 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copy of a member (96 corresponding lines) · ×1
  • Edited copy of a member (96 corresponding lines) crates/ibcmd-compiler-families/src/compiler/families/simple.rs:585 — crates/ibcmd-compiler-families/src/compiler/families/simple.rs:585-701 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:3410-3505 — These two members are one piece of code written twice and then edited apart: 96 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copy of a member (135 corresponding lines) · ×1
  • Edited copy of a member (135 corresponding lines) crates/ibcmd-dump/src/mssql_dump/mod.rs:43601 — crates/ibcmd-dump/src/mssql_dump/mod.rs:43601-43735 | crates/ibcmd-dump/src/mssql_dump/mod.rs:43740-43882 — These two members are one piece of code written twice and then edited apart: 135 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copy of a member (73 corresponding lines) · ×1
  • Edited copy of a member (73 corresponding lines) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:1894 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:1894-2002 | crates/ibcmd-compiler-families/src/compiler/families/utility.rs:916-988 — These two members are one piece of code written twice and then edited apart: 73 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copy of a member (89 corresponding lines) · ×1
  • Edited copy of a member (89 corresponding lines) crates/ibcmd-v8/src/block.rs:240 — crates/ibcmd-v8/src/block.rs:240-328 | crates/ibcmd-v8/src/block.rs:494-600 — These two members are one piece of code written twice and then edited apart: 89 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copy of a member (66 corresponding lines) · ×1
  • Edited copy of a member (66 corresponding lines) crates/ibcmd-compiler-families/src/compiler/families/services.rs:1233 — crates/ibcmd-compiler-families/src/compiler/families/services.rs:1233-1298 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:999-1068 — These two members are one piece of code written twice and then edited apart: 66 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copy of a member (65 corresponding lines) · ×1
  • Edited copy of a member (65 corresponding lines) crates/ibcmd-v8/src/format15.rs:177 — crates/ibcmd-v8/src/format15.rs:177-241 | crates/ibcmd-v8/src/format16.rs:238-324 — These two members are one piece of code written twice and then edited apart: 65 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copy of a member (52 corresponding lines) · ×1
  • Edited copy of a member (52 corresponding lines) crates/ibcmd-metadata-model/src/metadata_model/objects_export.rs:1462 — crates/ibcmd-metadata-model/src/metadata_model/objects_export.rs:1462-1513 | crates/ibcmd-metadata-model/src/metadata_model/registers_export.rs:428-480 — These two members are one piece of code written twice and then edited apart: 52 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copy of a member (62 corresponding lines) · ×1
  • Edited copy of a member (62 corresponding lines) crates/ibcmd-form-writer/src/lib.rs:16840 — crates/ibcmd-form-writer/src/lib.rs:16840-16901 | crates/ibcmd-form-writer/src/lib.rs:20563-20632 — These two members are one piece of code written twice and then edited apart: 62 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copy of a member (58 corresponding lines) · ×1
  • Edited copy of a member (58 corresponding lines) crates/ibcmd-form-native/src/lib.rs:173 — crates/ibcmd-form-native/src/lib.rs:173-230 | crates/ibcmd-metadata-model/src/metadata_model/registers_parts.rs:622-686 — These two members are one piece of code written twice and then edited apart: 58 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copy of a member (61 corresponding lines) · ×1
  • Edited copy of a member (61 corresponding lines) crates/ibcmd-compiler-families/src/compiler/families/services.rs:671 — crates/ibcmd-compiler-families/src/compiler/families/services.rs:671-768 | crates/ibcmd-compiler-families/src/compiler/families/services.rs:808-868 — These two members are one piece of code written twice and then edited apart: 61 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copy of a member (51 corresponding lines) · ×1
  • Edited copy of a member (51 corresponding lines) crates/ibcmd-metadata-blob/src/lib.rs:7327 — crates/ibcmd-metadata-blob/src/lib.rs:7327-7377 | crates/ibcmd-metadata-blob/src/lib.rs:7553-7620 — These two members are one piece of code written twice and then edited apart: 51 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copy of a member (56 corresponding lines) · ×1
  • Edited copy of a member (56 corresponding lines) crates/ibcmd-dump/src/mssql_dump/mod.rs:16444 — crates/ibcmd-dump/src/mssql_dump/mod.rs:16444-16505 | crates/ibcmd-dump/src/mssql_dump/mod.rs:16513-16568 — These two members are one piece of code written twice and then edited apart: 56 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copy of a member (45 corresponding lines) · ×1
  • Edited copy of a member (45 corresponding lines) crates/ibcmd-xml/src/dcs_schema.rs:2093 — crates/ibcmd-xml/src/dcs_schema.rs:2093-2137 | crates/ibcmd-xml/src/dcs_schema.rs:2143-2187 — These two members are one piece of code written twice and then edited apart: 45 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copy of a member (70 corresponding lines) · ×1
  • Edited copy of a member (70 corresponding lines) crates/ibcmd-form-body/src/form_body.rs:36520 — crates/ibcmd-form-body/src/form_body.rs:36520-36589 | crates/ibcmd-form-body/src/form_body.rs:36591-36660 — These two members are one piece of code written twice and then edited apart: 70 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copy of a member (50 corresponding lines) · ×1
  • Edited copy of a member (50 corresponding lines) crates/ibcmd-xml/src/dcs.rs:914 — crates/ibcmd-xml/src/dcs.rs:914-963 | crates/ibcmd-xml/src/dcs.rs:1342-1392 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copies of one member (4 members, 41+ corresponding lines) · ×1
  • Edited copies of one member (4 members, 41+ corresponding lines) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:702 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:702-749 | crates/ibcmd-compiler-families/src/compiler/families/services.rs:1394-1441 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:1153-1200 | crates/ibcmd-compiler-families/src/compiler/families/utility.rs:395-435 — These 4 members are one piece of code written 4 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' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 4 times and the copies will drift further apart.
D4 · Code Duplication · Edited copy of a member (59 corresponding lines) · ×1
  • Edited copy of a member (59 corresponding lines) crates/ibcmd-dump/src/mssql_dump/mod.rs:28452 — crates/ibcmd-dump/src/mssql_dump/mod.rs:28452-28510 | crates/ibcmd-dump/src/mssql_dump/mod.rs:29969-30028 — 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 — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copies of one member (3 members, 44+ corresponding lines) · ×1
  • Edited copies of one member (3 members, 44+ corresponding lines) crates/ibcmd-dump/src/mssql_dump/mod.rs:32901 — crates/ibcmd-dump/src/mssql_dump/mod.rs:32901-32944 | crates/ibcmd-dump/src/mssql_dump/mod.rs:35311-35356 | crates/ibcmd-dump/src/mssql_dump/mod.rs:35361-35404 — These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 44 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart.
D4 · Code Duplication · Edited copies of one member (4 members, 44+ corresponding lines) · ×1
  • Edited copies of one member (4 members, 44+ corresponding lines) crates/ibcmd-compiler-families/src/compiler/bodies/mod.rs:33 — crates/ibcmd-compiler-families/src/compiler/bodies/mod.rs:33-77 | crates/ibcmd-compiler-families/src/compiler/families/assets.rs:887-934 | crates/ibcmd-compiler-families/src/compiler/families/commands.rs:109-152 | crates/ibcmd-compiler-families/src/compiler/families/utility.rs:109-153 — These 4 members are one piece of code written 4 times and then edited apart: every two of them correspond over at least 44 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 4 times and the copies will drift further apart.
D4 · Code Duplication · Edited copy of a member (71 corresponding lines) · ×1
  • Edited copy of a member (71 corresponding lines) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:2393 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:2393-2463 | crates/ibcmd-compiler-families/src/compiler/families/utility.rs:1116-1198 — These two members are one piece of code written twice and then edited apart: 71 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copy of a member (53 corresponding lines) · ×1
  • Edited copy of a member (53 corresponding lines) crates/ibcmd-metadata-blob/src/lib.rs:6910 — crates/ibcmd-metadata-blob/src/lib.rs:6910-6966 | crates/ibcmd-metadata-blob/src/lib.rs:7036-7088 — These two members are one piece of code written twice and then edited apart: 53 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copies of one member (3 members, 32+ corresponding lines) · ×1
  • Edited copies of one member (3 members, 32+ corresponding lines) REDACTED:1281 — REDACTED:1281-1312 | REDACTED:1396-1428 | REDACTED:1430-1467 — These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 32 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart.
D4 · Code Duplication · Edited copies of one member (3 members, 33+ corresponding lines) · ×1
  • Edited copies of one member (3 members, 33+ corresponding lines) crates/ibcmd-xml/src/dcs.rs:2719 — crates/ibcmd-xml/src/dcs.rs:2719-2758 | crates/ibcmd-xml/src/dcs.rs:3263-3302 | crates/ibcmd-xml/src/dcs.rs:3821-3853 — These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 33 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart.
D4 · Code Duplication · Edited copies of one member (3 members, 69+ corresponding lines) · ×1
  • Edited copies of one member (3 members, 69+ corresponding lines) crates/ibcmd-xml/src/metadata/register_objects.rs:678 — crates/ibcmd-xml/src/metadata/register_objects.rs:678-756 | crates/ibcmd-xml/src/metadata/register_objects.rs:762-835 | crates/ibcmd-xml/src/metadata/register_objects.rs:841-909 — These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 69 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart.
D4 · Code Duplication · Edited copies of one member (3 members, 28+ corresponding lines) · ×1
  • Edited copies of one member (3 members, 28+ corresponding lines) crates/ibcmd-metadata-model/src/metadata_model/registers.rs:517 — crates/ibcmd-metadata-model/src/metadata_model/registers.rs:517-555 | crates/ibcmd-metadata-model/src/metadata_model/registers.rs:669-696 | crates/ibcmd-metadata-model/src/metadata_model/registers.rs:824-857 — These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 28 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart.
D4 · Code Duplication · Edited copy of a member (42 corresponding lines) · ×1
  • Edited copy of a member (42 corresponding lines) crates/ibcmd-core/src/migration/v2_20_to_v2_21.rs:64 — crates/ibcmd-core/src/migration/v2_20_to_v2_21.rs:64-108 | crates/ibcmd-core/src/migration/v2_21_to_v2_20.rs:75-116 — These two members are one piece of code written twice and then edited apart: 42 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copies of one member (4 members, 19+ corresponding lines) · ×1
  • Edited copies of one member (4 members, 19+ corresponding lines) crates/ibcmd-compiler-families/src/compiler/families/services.rs:3710 — crates/ibcmd-compiler-families/src/compiler/families/services.rs:3710-3729 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:2807-2827 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:2831-2849 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:2851-2876 — These 4 members are one piece of code written 4 times and then edited apart: every two of them correspond over at least 19 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 4 times and the copies will drift further apart.
D4 · Code Duplication · Edited copies of one member (4 members, 29+ corresponding lines) · ×1
  • Edited copies of one member (4 members, 29+ corresponding lines) crates/ibcmd-form-body/src/form_body.rs:38913 — crates/ibcmd-form-body/src/form_body.rs:38913-38945 | crates/ibcmd-form-body/src/form_body.rs:38948-38976 | crates/ibcmd-form-body/src/form_body.rs:40145-40175 | crates/ibcmd-form-body/src/form_body.rs:40196-40231 — These 4 members are one piece of code written 4 times and then edited apart: every two of them correspond over at least 29 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 4 times and the copies will drift further apart.
D4 · Code Duplication · Edited copies of one member (3 members, 21+ corresponding lines) · ×1
  • Edited copies of one member (3 members, 21+ corresponding lines) crates/ibcmd-filedb/src/write_paths.rs:138 — crates/ibcmd-filedb/src/write_paths.rs:138-168 | crates/ibcmd-filedb/src/write_paths.rs:170-198 | crates/ibcmd-filedb/src/write_paths.rs:200-220 — These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 21 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart.
D4 · Code Duplication · Edited copies of one member (5 members, 20+ corresponding lines) · ×1
  • Edited copies of one member (5 members, 20+ corresponding lines) crates/ibcmd-dump/src/mssql_dump/mod.rs:9409 — crates/ibcmd-dump/src/mssql_dump/mod.rs:9409-9428 | crates/ibcmd-dump/src/mssql_dump/mod.rs:40886-40905 | crates/ibcmd-dump/src/mssql_dump/mod.rs:41090-41118 | crates/ibcmd-dump/src/mssql_dump/mod.rs:41169-41188 | crates/ibcmd-dump/src/mssql_dump/mod.rs:42201-42221 — These 5 members are one piece of code written 5 times and then edited apart: every two of them correspond over at least 20 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 5 times and the copies will drift further apart.
D4 · Code Duplication · Edited copies of one member (5 members, 19+ corresponding lines) · ×1
  • Edited copies of one member (5 members, 19+ corresponding lines) crates/ibcmd-metadata-blob/src/lib.rs:590 — crates/ibcmd-metadata-blob/src/lib.rs:590-611 | crates/ibcmd-metadata-blob/src/lib.rs:653-674 | crates/ibcmd-metadata-blob/src/lib.rs:676-697 | crates/ibcmd-metadata-blob/src/lib.rs:705-723 | crates/ibcmd-metadata-blob/src/lib.rs:3140-3159 — These 5 members are one piece of code written 5 times and then edited apart: every two of them correspond over at least 19 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 5 times and the copies will drift further apart.
D4 · Code Duplication · Edited copies of one member (6 members, 15+ corresponding lines) · ×1
  • Edited copies of one member (6 members, 15+ corresponding lines) crates/ibcmd-core/src/capability.rs:353 — crates/ibcmd-core/src/capability.rs:353-375 | crates/ibcmd-core/src/dcs.rs:321-340 | crates/ibcmd-core/src/dcs.rs:515-534 | crates/ibcmd-core/src/dcs.rs:747-766 | crates/ibcmd-core/src/diagnostic.rs:419-439 | crates/ibcmd-core/src/migration/report.rs:1648-1662 — These 6 members are one piece of code written 6 times and then edited apart: every two of them correspond over at least 15 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 6 times and the copies will drift further apart.
D4 · Code Duplication · Edited copies of one member (3 members, 26+ corresponding lines) · ×1
  • Edited copies of one member (3 members, 26+ corresponding lines) REDACTED:1219 — REDACTED:1219-1244 | REDACTED:1318-1362 | REDACTED:1368-1394 — 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' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart.
D4 · Code Duplication · Edited copies of one member (4 members, 17+ corresponding lines) · ×1
  • Edited copies of one member (4 members, 17+ corresponding lines) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:3653 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:3653-3669 | crates/ibcmd-compiler-families/src/compiler/families/services.rs:3451-3467 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:2468-2484 | crates/ibcmd-compiler-families/src/compiler/families/utility.rs:1991-2007 — These 4 members are one piece of code written 4 times and then edited apart: every two of them correspond over at least 17 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 4 times and the copies will drift further apart.
D4 · Code Duplication · Edited copies of one member (4 members, 14+ corresponding lines) · ×1
  • Edited copies of one member (4 members, 14+ corresponding lines) crates/ibcmd-form-writer/src/lib.rs:15654 — crates/ibcmd-form-writer/src/lib.rs:15654-15667 | crates/ibcmd-form-writer/src/lib.rs:15669-15682 | crates/ibcmd-form-writer/src/lib.rs:15766-15779 | crates/ibcmd-form-writer/src/lib.rs:15956-15975 — These 4 members are one piece of code written 4 times and then edited apart: every two of them correspond over at least 14 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 4 times and the copies will drift further apart.
D4 · Code Duplication · Edited copies of one member (4 members, 12+ corresponding lines) · ×1
  • Edited copies of one member (4 members, 12+ corresponding lines) crates/ibcmd-compiler-families/src/compiler/bodies/command_interface.rs:527 — crates/ibcmd-compiler-families/src/compiler/bodies/command_interface.rs:527-550 | crates/ibcmd-compiler/src/compiler/bodies/dcs.rs:779-801 | crates/ibcmd-compiler/src/compiler/bodies/form.rs:157-172 | crates/ibcmd-compiler/src/compiler/bodies/mxl.rs:256-267 — These 4 members are one piece of code written 4 times and then edited apart: every two of them correspond over at least 12 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 4 times and the copies will drift further apart.
D4 · Code Duplication · Edited copies of one member (4 members, 18+ corresponding lines) · ×1
  • Edited copies of one member (4 members, 18+ corresponding lines) crates/ibcmd-dump/src/mssql_dump/mod.rs:10179 — crates/ibcmd-dump/src/mssql_dump/mod.rs:10179-10196 | crates/ibcmd-dump/src/mssql_dump/mod.rs:21658-21683 | crates/ibcmd-dump/src/mssql_dump/mod.rs:21941-21962 | crates/ibcmd-dump/src/mssql_dump/mod.rs:22094-22111 — These 4 members are one piece of code written 4 times and then edited apart: every two of them correspond over at least 18 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 4 times and the copies will drift further apart.
D4 · Code Duplication · Edited copies of one member (4 members, 11+ corresponding lines) · ×1
  • Edited copies of one member (4 members, 11+ corresponding lines) crates/ibcmd-form-body/src/form_body.rs:9156 — crates/ibcmd-form-body/src/form_body.rs:9156-9166 | crates/ibcmd-form-body/src/form_body.rs:21362-21373 | crates/ibcmd-form-body/src/form_body.rs:21472-21483 | crates/ibcmd-form-body/src/form_body.rs:31061-31071 — These 4 members are one piece of code written 4 times and then edited apart: every two of them correspond over at least 11 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 4 times and the copies will drift further apart.
D4 · Code Duplication · Edited copies of one member (4 members, 16+ corresponding lines) · ×1
  • Edited copies of one member (4 members, 16+ corresponding lines) crates/ibcmd-form-writer/src/lib.rs:17631 — crates/ibcmd-form-writer/src/lib.rs:17631-17646 | crates/ibcmd-form-writer/src/lib.rs:17651-17668 | crates/ibcmd-form-writer/src/lib.rs:17670-17685 | crates/ibcmd-form-writer/src/lib.rs:17690-17707 — These 4 members are one piece of code written 4 times and then edited apart: every two of them correspond over at least 16 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 4 times and the copies will drift further apart.
D4 · Code Duplication · Edited copies of one member (5 members, 11+ corresponding lines) · ×1
  • Edited copies of one member (5 members, 11+ corresponding lines) crates/ibcmd-compiler-families/src/compiler/families/commands.rs:1171 — crates/ibcmd-compiler-families/src/compiler/families/commands.rs:1171-1181 | crates/ibcmd-compiler-families/src/compiler/families/form.rs:903-913 | crates/ibcmd-compiler-families/src/compiler/families/modules.rs:390-400 | crates/ibcmd-compiler-families/src/compiler/families/services.rs:2400-2410 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:2012-2022 — These 5 members are one piece of code written 5 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' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 5 times and the copies will drift further apart.
D4 · Code Duplication · Edited copies of one member (3 members, 11+ corresponding lines) · ×1
  • Edited copies of one member (3 members, 11+ corresponding lines) crates/ibcmd-parallel/src/lib.rs:105 — crates/ibcmd-parallel/src/lib.rs:105-115 | crates/ibcmd-parallel/src/lib.rs:117-127 | crates/ibcmd-parallel/src/lib.rs:129-139 — 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' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart.
D4 · Code Duplication · Edited copies of one member (7 members, 5+ corresponding lines) · ×1
  • Edited copies of one member (7 members, 5+ corresponding lines) crates/ibcmd-form-writer/src/lib.rs:18638 — crates/ibcmd-form-writer/src/lib.rs:18638-18642 | crates/ibcmd-form-writer/src/lib.rs:18648-18652 | crates/ibcmd-form-writer/src/lib.rs:18658-18662 | crates/ibcmd-form-writer/src/lib.rs:18668-18672 | crates/ibcmd-form-writer/src/lib.rs:18678-18682 | crates/ibcmd-form-writer/src/lib.rs:18688-18692 | crates/ibcmd-form-writer/src/lib.rs:18698-18704 — These 7 members are one piece of code written 7 times and then edited apart: every two of them correspond over at least 5 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 7 times and the copies will drift further apart.
D4 · Code Duplication · Edited copies of one member (4 members, 8+ corresponding lines) · ×1
  • Edited copies of one member (4 members, 8+ corresponding lines) REDACTED:4500 — REDACTED:4500-4507 | REDACTED:4566-4573 | src/source_audit.rs:374-381 | src/source_audit.rs:383-390 — These 4 members are one piece of code written 4 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' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 4 times and the copies will drift further apart.
D4 · Code Duplication · Edited copies of one member (7 members, 7+ corresponding lines) · ×1
  • Edited copies of one member (7 members, 7+ corresponding lines) crates/ibcmd-cf/src/bootstrap.rs:474 — crates/ibcmd-cf/src/bootstrap.rs:474-480 | crates/ibcmd-cf/src/writer.rs:710-716 | crates/ibcmd-edt/src/directory.rs:113-119 | crates/ibcmd-xml/src/source_tree/writer.rs:115-121 | src/conversion.rs:1514-1523 | src/source_oracle.rs:642-652 | src/source_oracle.rs:986-992 — These 7 members are one piece of code written 7 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' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 7 times and the copies will drift further apart.
D4 · Code Duplication · Edited copies of one member (4 members, 7+ corresponding lines) · ×1
  • Edited copies of one member (4 members, 7+ corresponding lines) crates/ibcmd-form-writer/src/form_chart.rs:1570 — crates/ibcmd-form-writer/src/form_chart.rs:1570-1581 | crates/ibcmd-metadata-model/src/metadata_model/bodies_aggregates.rs:54-60 | crates/ibcmd-metadata-model/src/metadata_model/bodies_flowchart.rs:157-163 | crates/ibcmd-metadata-model/src/metadata_model/common.rs:174-180 — These 4 members are one piece of code written 4 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' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 4 times and the copies will drift further apart.
D4 · Code Duplication · Edited copies of one member (5 members, 4+ corresponding lines) · ×1
  • Edited copies of one member (5 members, 4+ corresponding lines) src/compatibility.rs:387 — src/compatibility.rs:387-390 | REDACTED:1619-1622 | src/plan.rs:564-567 | src/source.rs:173-176 | src/trace.rs:143-146 — These 5 members are one piece of code written 5 times and then edited apart: every two of them correspond over at least 4 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 5 times and the copies will drift further apart.
D4 · Code Duplication · Duplicated block (262 lines × 2) · ×1
  • Duplicated block (262 lines × 2) crates/ibcmd-form-writer/src/lib.rs:9064 — crates/ibcmd-form-writer/src/lib.rs:9064-9325 | crates/ibcmd-form-writer/src/lib.rs:9609-9870 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
D4 · Code Duplication · Duplicated block (101–105 lines × 2) · ×1
  • Duplicated block (101–105 lines × 2) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:3342 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:3342-3442 | crates/ibcmd-compiler-families/src/compiler/families/utility.rs:1684-1788 — before extracting anything, compare `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs` and `crates/ibcmd-compiler-families/src/compiler/families/utility.rs` as WHOLE FILES: this scan already matched 65 separate duplicated blocks between them, totalling at least 934 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:3342` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (72–73 lines × 2) · ×1
  • Duplicated block (72–73 lines × 2) crates/ibcmd-form-writer/src/lib.rs:8114 — crates/ibcmd-form-writer/src/lib.rs:8114-8186 | crates/ibcmd-form-writer/src/lib.rs:8652-8723 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
D4 · Code Duplication · Duplicated block (59 lines × 2) · ×1
  • Duplicated block (59 lines × 2) crates/ibcmd-form-writer/src/lib.rs:8987 — crates/ibcmd-form-writer/src/lib.rs:8987-9045 | crates/ibcmd-form-writer/src/lib.rs:9547-9605 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-form-writer/src/lib.rs:8987` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, `crates/ibcmd-form-writer/src/lib.rs:9606` calls `from_escaped`, `decode` and `crates/ibcmd-form-writer/src/lib.rs:9046` does not — after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
D4 · Code Duplication · Duplicated block (46 lines × 2) · ×1
  • Duplicated block (46 lines × 2) crates/ibcmd-form-writer/src/lib.rs:16856 — crates/ibcmd-form-writer/src/lib.rs:16856-16901 | crates/ibcmd-form-writer/src/lib.rs:20587-20632 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-form-writer/src/lib.rs:16856` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (39–41 lines × 2) · ×1
  • Duplicated block (39–41 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:4595 — crates/ibcmd-dump/src/mssql_dump/mod.rs:4595-4633 | crates/ibcmd-dump/src/mssql_dump/mod.rs:6430-6470 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:4595` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (36–37 lines × 2) · ×1
  • Duplicated block (36–37 lines × 2) crates/ibcmd-xml/src/source_tree/reader.rs:368 — crates/ibcmd-xml/src/source_tree/reader.rs:368-403 | src/source_audit.rs:423-459 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-xml/src/source_tree/reader.rs:368` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
D4 · Code Duplication · Duplicated block (36 lines × 2) · ×1
  • Duplicated block (36 lines × 2) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:3601 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:3601-3636 | crates/ibcmd-compiler-families/src/compiler/families/utility.rs:1939-1974 — before extracting anything, compare `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs` and `crates/ibcmd-compiler-families/src/compiler/families/utility.rs` as WHOLE FILES: this scan already matched 65 separate duplicated blocks between them, totalling at least 934 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:3601` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (33 lines × 2) · ×1
  • Duplicated block (33 lines × 2) crates/ibcmd-v8/src/format15.rs:206 — crates/ibcmd-v8/src/format15.rs:206-238 | crates/ibcmd-v8/src/format16.rs:286-318 — before extracting anything, compare `crates/ibcmd-v8/src/format15.rs` and `crates/ibcmd-v8/src/format16.rs` as WHOLE FILES: this scan already matched 7 separate duplicated blocks between them, totalling at least 82 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-v8/src/format15.rs:206` it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows — the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members' bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run — a one-line delegation has no helper inside it to lift — so generate the run from the set it enumerates, or accept it and keep each member's own documentation with it.
D4 · Code Duplication · Duplicated block (29–32 lines × 2) · ×1
  • Duplicated block (29–32 lines × 2) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:1432 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:1432-1460 | crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:1723-1754 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:1432` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (40 lines × 2) · ×1
  • Duplicated block (40 lines × 2) crates/ibcmd-metadata-model/src/metadata_model/common_export.rs:456 — crates/ibcmd-metadata-model/src/metadata_model/common_export.rs:456-495 | crates/ibcmd-metadata-model/src/metadata_model/forms_export.rs:161-200 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once. 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 `return` inside it is the body's own exit and keeps its meaning in the moved unit.
D4 · Code Duplication · Duplicated block (31 lines × 4) · ×1
  • Duplicated block (31 lines × 4) crates/ibcmd-dump/src/mssql_dump/mod.rs:38013 — crates/ibcmd-dump/src/mssql_dump/mod.rs:38013-38043 | crates/ibcmd-dump/src/mssql_dump/mod.rs:39701-39731 | crates/ibcmd-dump/src/mssql_dump/mod.rs:39897-39927 | crates/ibcmd-dump/src/mssql_dump/mod.rs:40115-40145 — all 4 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:38013` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, `crates/ibcmd-dump/src/mssql_dump/mod.rs:38044` calls `push_register_standard_attributes_xml`, `push_str`, `push_exchange_plan_based_on_xml` and `crates/ibcmd-dump/src/mssql_dump/mod.rs:39732` does not — after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
D4 · Code Duplication · Duplicated block (9–31 lines × 2) · ×1
  • Duplicated block (9–31 lines × 2) crates/ibcmd-form-body/src/form_body.rs:8935 — crates/ibcmd-form-body/src/form_body.rs:8935-8965 | crates/ibcmd-form-body/src/form_body.rs:9033-9041 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
D4 · Code Duplication · Duplicated block (31 lines × 2) · ×1
  • Duplicated block (31 lines × 2) crates/ibcmd-form-body/src/layout_8_5_1.rs:422 — crates/ibcmd-form-body/src/layout_8_5_1.rs:422-452 | crates/ibcmd-form-writer/src/form/load_8_5_1.rs:1415-1445 — before extracting anything, compare `crates/ibcmd-form-body/src/layout_8_5_1.rs` and `crates/ibcmd-form-writer/src/form/load_8_5_1.rs` as WHOLE FILES: this scan already matched 3 separate duplicated blocks between them, totalling at least 55 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 `return` inside it is the body's own exit and keeps its meaning in the moved unit.
D4 · Code Duplication · Duplicated block (30 lines × 2) · ×1
  • Duplicated block (30 lines × 2) REDACTED:9338 — REDACTED:9338-9367 | REDACTED:9551-9580 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
D4 · Code Duplication · Duplicated block (25–29 lines × 8) · ×1
  • Duplicated block (25–29 lines × 8) crates/ibcmd-dump/src/mssql_dump/mod.rs:38068 — crates/ibcmd-dump/src/mssql_dump/mod.rs:38068-38096 | crates/ibcmd-dump/src/mssql_dump/mod.rs:38789-38813 | crates/ibcmd-dump/src/mssql_dump/mod.rs:38933-38957 | crates/ibcmd-dump/src/mssql_dump/mod.rs:39150-39174 | crates/ibcmd-dump/src/mssql_dump/mod.rs:39439-39463 | crates/ibcmd-dump/src/mssql_dump/mod.rs:39766-39794 | crates/ibcmd-dump/src/mssql_dump/mod.rs:39974-40002 | crates/ibcmd-dump/src/mssql_dump/mod.rs:40161-40185 — all 8 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:38068` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, `crates/ibcmd-dump/src/mssql_dump/mod.rs:38787` calls `xml_bool` and `crates/ibcmd-dump/src/mssql_dump/mod.rs:38932` does not — after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
D4 · Code Duplication · Duplicated block (29 lines × 3) · ×1
  • Duplicated block (29 lines × 3) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:415 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:415-443 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:310-338 | crates/ibcmd-compiler-families/src/compiler/families/utility.rs:191-219 — before extracting anything, compare `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs` and `crates/ibcmd-compiler-families/src/compiler/families/simple.rs` as WHOLE FILES: this scan already matched 12 separate duplicated blocks between them, totalling at least 149 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:415` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (24–29 lines × 2) · ×1
  • Duplicated block (24–29 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:10234 — crates/ibcmd-dump/src/mssql_dump/mod.rs:10234-10257 | crates/ibcmd-dump/src/mssql_dump/mod.rs:22138-22166 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, `crates/ibcmd-dump/src/mssql_dump/mod.rs:10232` calls `parse_information_register_command_picture_descriptor`, `get`, `parse_metadata_picture_transparent_pixel` and `crates/ibcmd-dump/src/mssql_dump/mod.rs:22137` does not — after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
D4 · Code Duplication · Duplicated block (32 lines × 2) · ×1
  • Duplicated block (32 lines × 2) crates/ibcmd-metadata-blob/src/lib.rs:3744 — crates/ibcmd-metadata-blob/src/lib.rs:3744-3775 | crates/ibcmd-metadata-blob/src/lib.rs:3777-3808 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. 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 `return` inside it is the body's own exit and keeps its meaning in the moved unit.
D4 · Code Duplication · Duplicated block (25–28 lines × 2) · ×1
  • Duplicated block (25–28 lines × 2) crates/ibcmd-form-body/src/form_body.rs:34256 — crates/ibcmd-form-body/src/form_body.rs:34256-34280 | crates/ibcmd-form-body/src/form_body.rs:36032-36059 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-form-body/src/form_body.rs:34256` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (26–27 lines × 4) · ×1
  • Duplicated block (26–27 lines × 4) crates/ibcmd-dump/src/mssql_dump/mod.rs:27758 — crates/ibcmd-dump/src/mssql_dump/mod.rs:27758-27784 | crates/ibcmd-dump/src/mssql_dump/mod.rs:28612-28638 | crates/ibcmd-dump/src/mssql_dump/mod.rs:30123-30149 | crates/ibcmd-dump/src/mssql_dump/mod.rs:31411-31436 — all 4 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:27758` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (23–27 lines × 2) · ×1
  • Duplicated block (23–27 lines × 2) crates/ibcmd-compiler-families/src/compiler/families/business_object/register_native.rs:539 — crates/ibcmd-compiler-families/src/compiler/families/business_object/register_native.rs:539-561 | crates/ibcmd-compiler-families/src/compiler/families/business_object/register_native.rs:781-807 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/business_object/register_native.rs:539` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (22–27 lines × 2) · ×1
  • Duplicated block (22–27 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:4463 — crates/ibcmd-dump/src/mssql_dump/mod.rs:4463-4489 | crates/ibcmd-dump/src/mssql_dump/mod.rs:6026-6047 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
D4 · Code Duplication · Duplicated block (16–27 lines × 2) · ×1
  • Duplicated block (16–27 lines × 2) crates/ibcmd-form-body/src/form_body.rs:6394 — crates/ibcmd-form-body/src/form_body.rs:6394-6420 | crates/ibcmd-form-body/src/form_body.rs:7102-7117 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
D4 · Code Duplication · Duplicated block (26–27 lines × 2) · ×1
  • Duplicated block (26–27 lines × 2) crates/ibcmd-form-native/src/lib.rs:7746 — crates/ibcmd-form-native/src/lib.rs:7746-7771 | crates/ibcmd-form-native/src/lib.rs:8176-8202 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-form-native/src/lib.rs:7746` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note first that the copies are not typed on the same thing: the declarations holding them bind `payload` to `&NativeUsualGroupPayload<'_>` in one and `&NativePagePayload<'_>` in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH — their common supertype where they have one, or a new abstraction over them where they do not — and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, `crates/ibcmd-form-native/src/lib.rs:7745` calls `root_code` and `crates/ibcmd-form-native/src/lib.rs:8176` does not — after which the two agree again for 3 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
D4 · Code Duplication · Duplicated block (23–26 lines × 2) · ×1
  • Duplicated block (23–26 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:36842 — crates/ibcmd-dump/src/mssql_dump/mod.rs:36842-36864 | crates/ibcmd-dump/src/mssql_dump/mod.rs:37109-37134 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
D4 · Code Duplication · Duplicated block (24–26 lines × 2) · ×1
  • Duplicated block (24–26 lines × 2) crates/ibcmd-moxel/src/lib.rs:14519 — crates/ibcmd-moxel/src/lib.rs:14519-14542 | crates/ibcmd-moxel/src/lib.rs:14925-14950 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-moxel/src/lib.rs:14519` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (25–26 lines × 2) · ×1
  • Duplicated block (25–26 lines × 2) crates/ibcmd-schema/src/lib.rs:8412 — crates/ibcmd-schema/src/lib.rs:8412-8437 | crates/ibcmd-schema/src/lib.rs:8668-8692 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-schema/src/lib.rs:8412` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, `crates/ibcmd-schema/src/lib.rs:8412` calls `to_owned` and `crates/ibcmd-schema/src/lib.rs:8668` does not — after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
D4 · Code Duplication · Duplicated block (25 lines × 4) · ×1
  • Duplicated block (25 lines × 4) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:422 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:422-446 | crates/ibcmd-compiler-families/src/compiler/families/services.rs:333-357 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:317-341 | crates/ibcmd-compiler-families/src/compiler/families/utility.rs:198-222 — before extracting anything, compare `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs` and `crates/ibcmd-compiler-families/src/compiler/families/services.rs` as WHOLE FILES: this scan already matched 10 separate duplicated blocks between them, totalling at least 103 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:422` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (24 lines × 4) · ×1
  • Duplicated block (24 lines × 4) crates/ibcmd-dump/src/mssql_dump/mod.rs:27689 — crates/ibcmd-dump/src/mssql_dump/mod.rs:27689-27712 | crates/ibcmd-dump/src/mssql_dump/mod.rs:28534-28557 | crates/ibcmd-dump/src/mssql_dump/mod.rs:30046-30069 | crates/ibcmd-dump/src/mssql_dump/mod.rs:31337-31360 — all 4 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, `crates/ibcmd-dump/src/mssql_dump/mod.rs:27686` calls `clone` and `crates/ibcmd-dump/src/mssql_dump/mod.rs:28533` does not — after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
D4 · Code Duplication · Duplicated block (23–24 lines × 4) · ×1
  • Duplicated block (23–24 lines × 4) crates/ibcmd-dump/src/mssql_dump/mod.rs:27721 — crates/ibcmd-dump/src/mssql_dump/mod.rs:27721-27744 | crates/ibcmd-dump/src/mssql_dump/mod.rs:28566-28589 | crates/ibcmd-dump/src/mssql_dump/mod.rs:30078-30100 | crates/ibcmd-dump/src/mssql_dump/mod.rs:31369-31392 — all 4 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:27721` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (20–24 lines × 2) · ×1
  • Duplicated block (20–24 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:15243 — crates/ibcmd-dump/src/mssql_dump/mod.rs:15243-15262 | crates/ibcmd-dump/src/mssql_dump/mod.rs:27016-27039 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:15243` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (23–24 lines × 2) · ×1
  • Duplicated block (23–24 lines × 2) crates/ibcmd-xml/src/metadata/constant.rs:919 — crates/ibcmd-xml/src/metadata/constant.rs:919-942 | crates/ibcmd-xml/src/metadata/language.rs:495-517 — before extracting anything, compare `crates/ibcmd-xml/src/metadata/constant.rs` and `crates/ibcmd-xml/src/metadata/language.rs` as WHOLE FILES: this scan already matched 19 separate duplicated blocks between them, totalling at least 213 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-xml/src/metadata/constant.rs:919` it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows — the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members' bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run — a one-line delegation has no helper inside it to lift — so generate the run from the set it enumerates, or accept it and keep each member's own documentation with it.
D4 · Code Duplication · Duplicated block (37 lines × 2) · ×1
  • Duplicated block (37 lines × 2) crates/ibcmd-form-writer/src/lib.rs:8370 — crates/ibcmd-form-writer/src/lib.rs:8370-8406 | crates/ibcmd-form-writer/src/lib.rs:8806-8842 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
D4 · Code Duplication · Duplicated block (21–22 lines × 2) · ×1
  • Duplicated block (21–22 lines × 2) crates/ibcmd-compiler-families/src/compiler/families/services.rs:614 — crates/ibcmd-compiler-families/src/compiler/families/services.rs:614-634 | crates/ibcmd-compiler-families/src/compiler/families/services.rs:681-702 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/services.rs:614` it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows — the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members' bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run — a one-line delegation has no helper inside it to lift — so generate the run from the set it enumerates, or accept it and keep each member's own documentation with it. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
D4 · Code Duplication · Duplicated block (10–22 lines × 2) · ×1
  • Duplicated block (10–22 lines × 2) crates/ibcmd-dump/src/mssql_dump/refs.rs:4195 — crates/ibcmd-dump/src/mssql_dump/refs.rs:4195-4204 | crates/ibcmd-dump/src/mssql_dump/refs.rs:4521-4542 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
D4 · Code Duplication · Duplicated block (17–22 lines × 2) · ×1
  • Duplicated block (17–22 lines × 2) REDACTED:8947 — REDACTED:8947-8963 | REDACTED:8979-9000 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
D4 · Code Duplication · Duplicated block (20–21 lines × 5) · ×1
  • Duplicated block (20–21 lines × 5) crates/ibcmd-dump/src/mssql_dump/forms.rs:442 — crates/ibcmd-dump/src/mssql_dump/forms.rs:442-462 | crates/ibcmd-dump/src/mssql_dump/mod.rs:37350-37370 | crates/ibcmd-dump/src/mssql_dump/mod.rs:39259-39278 | crates/ibcmd-dump/src/mssql_dump/mod.rs:42386-42406 | crates/ibcmd-dump/src/mssql_dump/mod.rs:42438-42458 — before extracting anything, compare `crates/ibcmd-dump/src/mssql_dump/forms.rs` and `crates/ibcmd-dump/src/mssql_dump/mod.rs` as WHOLE FILES: this scan already matched 6 separate duplicated blocks between them, totalling at least 99 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/forms.rs:442` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (19–21 lines × 4) · ×1
  • Duplicated block (19–21 lines × 4) crates/ibcmd-compiler-families/src/compiler/bodies/mod.rs:117 — crates/ibcmd-compiler-families/src/compiler/bodies/mod.rs:117-137 | crates/ibcmd-compiler-families/src/compiler/families/commands.rs:193-213 | crates/ibcmd-compiler-families/src/compiler/families/form.rs:206-224 | crates/ibcmd-compiler-families/src/compiler/families/modules.rs:132-150 — before extracting anything, compare `crates/ibcmd-compiler-families/src/compiler/families/commands.rs` and `crates/ibcmd-compiler-families/src/compiler/families/form.rs` as WHOLE FILES: this scan already matched 3 separate duplicated blocks between them, totalling at least 37 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/bodies/mod.rs:117` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
D4 · Code Duplication · Duplicated block (20–21 lines × 3) · ×1
  • Duplicated block (20–21 lines × 3) crates/ibcmd-dump/src/mssql_dump/mod.rs:30604 — crates/ibcmd-dump/src/mssql_dump/mod.rs:30604-30623 | crates/ibcmd-dump/src/mssql_dump/mod.rs:31303-31323 | crates/ibcmd-dump/src/mssql_dump/mod.rs:32325-32345 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:30604` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
D4 · Code Duplication · Duplicated block (13–21 lines × 3) · ×1
  • Duplicated block (13–21 lines × 3) crates/ibcmd-metadata-model/src/metadata_model/registers_export.rs:651 — crates/ibcmd-metadata-model/src/metadata_model/registers_export.rs:651-670 | crates/ibcmd-metadata-model/src/metadata_model/registers_export.rs:752-772 | crates/ibcmd-metadata-model/src/metadata_model/registers_export.rs:1032-1044 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, `crates/ibcmd-metadata-model/src/metadata_model/registers_export.rs:673` calls `child`, `flag`, `slot` and `crates/ibcmd-metadata-model/src/metadata_model/registers_export.rs:1047` does not — after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
D4 · Code Duplication · Duplicated block (18–21 lines × 2) · ×1
  • Duplicated block (18–21 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:3957 — crates/ibcmd-dump/src/mssql_dump/mod.rs:3957-3977 | crates/ibcmd-dump/src/mssql_dump/mod.rs:4836-4853 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
D4 · Code Duplication · Duplicated block (20–21 lines × 2) · ×1
  • Duplicated block (20–21 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:39485 — crates/ibcmd-dump/src/mssql_dump/mod.rs:39485-39505 | crates/ibcmd-dump/src/mssql_dump/mod.rs:39635-39654 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:39485` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, `crates/ibcmd-dump/src/mssql_dump/mod.rs:39654` calls `push_str` and `crates/ibcmd-dump/src/mssql_dump/mod.rs:39505` does not — after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
D4 · Code Duplication · Duplicated block (20 lines × 3) · ×1
  • Duplicated block (20 lines × 3) crates/ibcmd-form-body/src/form_body.rs:26481 — crates/ibcmd-form-body/src/form_body.rs:26481-26500 | crates/ibcmd-form-body/src/form_body.rs:26925-26944 | crates/ibcmd-form-body/src/form_body.rs:27007-27026 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-form-body/src/form_body.rs:26481` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (18–20 lines × 2) · ×1
  • Duplicated block (18–20 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:32379 — crates/ibcmd-dump/src/mssql_dump/mod.rs:32379-32396 | crates/ibcmd-dump/src/mssql_dump/mod.rs:32474-32493 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:32379` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (19–20 lines × 2) · ×1
  • Duplicated block (19–20 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:44872 — crates/ibcmd-dump/src/mssql_dump/mod.rs:44872-44890 | src/dump_sources.rs:716-735 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice.
D4 · Code Duplication · Duplicated block (15–19 lines × 2) · ×1
  • Duplicated block (15–19 lines × 2) crates/ibcmd-compiler-families/src/compiler/families/services.rs:1671 — crates/ibcmd-compiler-families/src/compiler/families/services.rs:1671-1685 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:1941-1959 — before extracting anything, compare `crates/ibcmd-compiler-families/src/compiler/families/services.rs` and `crates/ibcmd-compiler-families/src/compiler/families/simple.rs` as WHOLE FILES: this scan already matched 36 separate duplicated blocks between them, totalling at least 406 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/services.rs:1671` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (17–19 lines × 2) · ×1
  • Duplicated block (17–19 lines × 2) REDACTED:752 — REDACTED:752-770 | REDACTED:798-814 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `REDACTED:752` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (8–19 lines × 2) · ×1
  • Duplicated block (8–19 lines × 2) crates/ibcmd-xml/src/metadata/services.rs:586 — crates/ibcmd-xml/src/metadata/services.rs:586-604 | crates/ibcmd-xml/src/metadata/services.rs:737-744 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-xml/src/metadata/services.rs:737` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (10–18 lines × 4) · ×1
  • Duplicated block (10–18 lines × 4) crates/ibcmd-metadata-model/src/metadata_model/registers_export.rs:532 — crates/ibcmd-metadata-model/src/metadata_model/registers_export.rs:532-549 | crates/ibcmd-metadata-model/src/metadata_model/registers_export.rs:656-672 | crates/ibcmd-metadata-model/src/metadata_model/registers_export.rs:757-774 | crates/ibcmd-metadata-model/src/metadata_model/registers_export.rs:1037-1046 — all 4 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, `crates/ibcmd-metadata-model/src/metadata_model/registers_export.rs:531` calls `modern` and `crates/ibcmd-metadata-model/src/metadata_model/registers_export.rs:756` does not — after which the two agree again for 4 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
D4 · Code Duplication · Duplicated block (14–18 lines × 3) · ×1
  • Duplicated block (14–18 lines × 3) crates/ibcmd-form-body/src/form_body.rs:33876 — crates/ibcmd-form-body/src/form_body.rs:33876-33889 | crates/ibcmd-form-body/src/form_body.rs:34266-34280 | crates/ibcmd-form-body/src/form_body.rs:36042-36059 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-form-body/src/form_body.rs:33876` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (14–18 lines × 2) · ×1
  • Duplicated block (14–18 lines × 2) crates/ibcmd-form-body/src/form_body.rs:4083 — crates/ibcmd-form-body/src/form_body.rs:4083-4096 | crates/ibcmd-form-body/src/form_body.rs:4401-4418 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-form-body/src/form_body.rs:4083` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (15–18 lines × 2) · ×1
  • Duplicated block (15–18 lines × 2) crates/ibcmd-form-body/src/form_body.rs:21168 — crates/ibcmd-form-body/src/form_body.rs:21168-21185 | crates/ibcmd-form-body/src/form_body.rs:21205-21219 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-form-body/src/form_body.rs:21168` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (18–19 lines × 2) · ×1
  • Duplicated block (18–19 lines × 2) crates/ibcmd-xml/src/dcs_template.rs:604 — crates/ibcmd-xml/src/dcs_template.rs:604-622 | crates/ibcmd-xml/src/dcs_template.rs:709-726 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-xml/src/dcs_template.rs:604` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
D4 · Code Duplication · Duplicated block (17–18 lines × 2) · ×1
  • Duplicated block (17–18 lines × 2) src/main.rs:507 — src/main.rs:507-524 | src/main.rs:532-548 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `src/main.rs:507` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (17 lines × 14) · ×1
  • Duplicated block (17 lines × 14) crates/ibcmd-xml/src/metadata/common_objects.rs:428 — crates/ibcmd-xml/src/metadata/common_objects.rs:428-444 | crates/ibcmd-xml/src/metadata/functional_option.rs:358-374 | crates/ibcmd-xml/src/metadata/functional_options_parameter.rs:344-360 | crates/ibcmd-xml/src/metadata/hierarchical_objects.rs:846-862 | crates/ibcmd-xml/src/metadata/register_objects.rs:1033-1049 | crates/ibcmd-xml/src/metadata/services.rs:2543-2559 | crates/ibcmd-xml/src/metadata/services.rs:2587-2603 | crates/ibcmd-xml/src/metadata/services.rs:2630-2646 | crates/ibcmd-xml/src/metadata/services.rs:2673-2689 | crates/ibcmd-xml/src/metadata/services.rs:2716-2732 | crates/ibcmd-xml/src/metadata/services.rs:2759-2775 | crates/ibcmd-xml/src/metadata/services.rs:2803-2819 | crates/ibcmd-xml/src/metadata/session_parameter.rs:744-760 | crates/ibcmd-xml/src/metadata/utility_objects.rs:720-736 — before extracting anything, compare `crates/ibcmd-xml/src/metadata/common_objects.rs` and `crates/ibcmd-xml/src/metadata/functional_option.rs` as WHOLE FILES: this scan already matched 3 separate duplicated blocks between them, totalling at least 37 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-xml/src/metadata/common_objects.rs:428` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (17 lines × 5) · ×1
  • Duplicated block (17 lines × 5) crates/ibcmd-dump/src/mssql_dump/mod.rs:38821 — crates/ibcmd-dump/src/mssql_dump/mod.rs:38821-38837 | crates/ibcmd-dump/src/mssql_dump/mod.rs:39487-39503 | crates/ibcmd-dump/src/mssql_dump/mod.rs:39637-39653 | crates/ibcmd-dump/src/mssql_dump/mod.rs:40029-40045 | crates/ibcmd-dump/src/mssql_dump/mod.rs:40552-40568 — all 5 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:38821` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, `crates/ibcmd-dump/src/mssql_dump/mod.rs:39658` calls `push_str` and `crates/ibcmd-dump/src/mssql_dump/mod.rs:39505` does not — after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
D4 · Code Duplication · Duplicated block (17 lines × 4) · ×1
  • Duplicated block (17 lines × 4) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:1396 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:1396-1412 | crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:1564-1580 | crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:1696-1712 | crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:1829-1845 — all 4 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:1396` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (15–17 lines × 3) · ×1
  • Duplicated block (15–17 lines × 3) crates/ibcmd-dump/src/mssql_dump/mod.rs:32383 — crates/ibcmd-dump/src/mssql_dump/mod.rs:32383-32397 | crates/ibcmd-dump/src/mssql_dump/mod.rs:32478-32494 | crates/ibcmd-dump/src/mssql_dump/mod.rs:33023-33037 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:32383` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, `crates/ibcmd-dump/src/mssql_dump/mod.rs:32381` calls `parse_information_register_non_zero_uuid`, `get` and `crates/ibcmd-dump/src/mssql_dump/mod.rs:33022` does not — after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
D4 · Code Duplication · Duplicated block (16–17 lines × 3) · ×1
  • Duplicated block (16–17 lines × 3) crates/ibcmd-metadata-model/src/metadata_model/registers_export.rs:534 — crates/ibcmd-metadata-model/src/metadata_model/registers_export.rs:534-550 | crates/ibcmd-metadata-model/src/metadata_model/registers_export.rs:658-673 | crates/ibcmd-metadata-model/src/metadata_model/registers_export.rs:868-884 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-metadata-model/src/metadata_model/registers_export.rs:534` it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows — the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members' bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run — a one-line delegation has no helper inside it to lift — so generate the run from the set it enumerates, or accept it and keep each member's own documentation with it. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, `crates/ibcmd-metadata-model/src/metadata_model/registers_export.rs:551` calls `child`, `code`, `slot` and `crates/ibcmd-metadata-model/src/metadata_model/registers_export.rs:885` does not — after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
D4 · Code Duplication · Duplicated block (14–17 lines × 2) · ×1
  • Duplicated block (14–17 lines × 2) crates/ibcmd-dump/src/mssql_dump/command_interface.rs:211 — crates/ibcmd-dump/src/mssql_dump/command_interface.rs:211-227 | crates/ibcmd-dump/src/mssql_dump/command_interface.rs:337-350 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/command_interface.rs:211` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (13–16 lines × 2) · ×1
  • Duplicated block (13–16 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:5871 — crates/ibcmd-dump/src/mssql_dump/mod.rs:5871-5883 | crates/ibcmd-dump/src/mssql_dump/mod.rs:5932-5947 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:5932` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
D4 · Code Duplication · Duplicated block (10–16 lines × 2) · ×1
  • Duplicated block (10–16 lines × 2) crates/ibcmd-schema/src/lib.rs:835 — crates/ibcmd-schema/src/lib.rs:835-850 | crates/ibcmd-schema/src/lib.rs:2444-2453 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-schema/src/lib.rs:835` it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows — the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members' bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run — a one-line delegation has no helper inside it to lift — so generate the run from the set it enumerates, or accept it and keep each member's own documentation with it.
D4 · Code Duplication · Duplicated block (15 lines × 5) · ×1
  • Duplicated block (15 lines × 5) crates/ibcmd-dump/src/mssql_dump/mod.rs:38945 — crates/ibcmd-dump/src/mssql_dump/mod.rs:38945-38959 | crates/ibcmd-dump/src/mssql_dump/mod.rs:39162-39176 | crates/ibcmd-dump/src/mssql_dump/mod.rs:39451-39465 | crates/ibcmd-dump/src/mssql_dump/mod.rs:40173-40187 | crates/ibcmd-dump/src/mssql_dump/mod.rs:40763-40777 — all 5 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:38945` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (15 lines × 4) · ×1
  • Duplicated block (15 lines × 4) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:3719 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:3719-3733 | crates/ibcmd-compiler-families/src/compiler/families/services.rs:3525-3539 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:2542-2556 | crates/ibcmd-compiler-families/src/compiler/families/utility.rs:2058-2072 — before extracting anything, compare `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs` and `crates/ibcmd-compiler-families/src/compiler/families/services.rs` as WHOLE FILES: this scan already matched 10 separate duplicated blocks between them, totalling at least 103 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:3719` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (10–15 lines × 2) · ×1
  • Duplicated block (10–15 lines × 2) crates/ibcmd-form-body/src/form_body.rs:5591 — crates/ibcmd-form-body/src/form_body.rs:5591-5600 | crates/ibcmd-form-body/src/form_body.rs:6737-6751 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-form-body/src/form_body.rs:5591` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
D4 · Code Duplication · Duplicated block (12–15 lines × 2) · ×1
  • Duplicated block (12–15 lines × 2) crates/ibcmd-metadata-blob/src/lib.rs:2454 — crates/ibcmd-metadata-blob/src/lib.rs:2454-2465 | crates/ibcmd-metadata-blob/src/lib.rs:2809-2823 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-metadata-blob/src/lib.rs:2454` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (14 lines × 15) · ×1
  • Duplicated block (14 lines × 15) crates/ibcmd-xml/src/metadata/business_objects.rs:1243 — crates/ibcmd-xml/src/metadata/business_objects.rs:1243-1256 | crates/ibcmd-xml/src/metadata/common_objects.rs:425-438 | crates/ibcmd-xml/src/metadata/functional_option.rs:355-368 | crates/ibcmd-xml/src/metadata/functional_options_parameter.rs:341-354 | crates/ibcmd-xml/src/metadata/hierarchical_objects.rs:843-856 | crates/ibcmd-xml/src/metadata/register_objects.rs:1030-1043 | crates/ibcmd-xml/src/metadata/services.rs:2540-2553 | crates/ibcmd-xml/src/metadata/services.rs:2584-2597 | crates/ibcmd-xml/src/metadata/services.rs:2627-2640 | crates/ibcmd-xml/src/metadata/services.rs:2670-2683 | crates/ibcmd-xml/src/metadata/services.rs:2713-2726 | crates/ibcmd-xml/src/metadata/services.rs:2756-2769 | crates/ibcmd-xml/src/metadata/services.rs:2800-2813 | crates/ibcmd-xml/src/metadata/session_parameter.rs:741-754 | crates/ibcmd-xml/src/metadata/utility_objects.rs:717-730 — before extracting anything, compare `crates/ibcmd-xml/src/metadata/business_objects.rs` and `crates/ibcmd-xml/src/metadata/common_objects.rs` as WHOLE FILES: this scan already matched 4 separate duplicated blocks between them, totalling at least 41 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-xml/src/metadata/business_objects.rs:1243` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (14 lines × 8) · ×1
  • Duplicated block (14 lines × 8) crates/ibcmd-dump/src/mssql_dump/mod.rs:17963 — crates/ibcmd-dump/src/mssql_dump/mod.rs:17963-17976 | crates/ibcmd-dump/src/mssql_dump/mod.rs:18021-18034 | crates/ibcmd-dump/src/mssql_dump/mod.rs:19013-19026 | crates/ibcmd-dump/src/mssql_dump/mod.rs:26470-26483 | crates/ibcmd-dump/src/mssql_dump/mod.rs:27259-27272 | crates/ibcmd-dump/src/mssql_dump/mod.rs:30597-30610 | crates/ibcmd-dump/src/mssql_dump/mod.rs:31296-31309 | crates/ibcmd-dump/src/mssql_dump/mod.rs:32318-32331 — all 8 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited.
D4 · Code Duplication · Duplicated block (14 lines × 5) · ×1
  • Duplicated block (14 lines × 5) crates/ibcmd-dump/src/mssql_dump/mod.rs:26465 — crates/ibcmd-dump/src/mssql_dump/mod.rs:26465-26478 | crates/ibcmd-dump/src/mssql_dump/mod.rs:29018-29031 | crates/ibcmd-dump/src/mssql_dump/mod.rs:30592-30605 | crates/ibcmd-dump/src/mssql_dump/mod.rs:31291-31304 | crates/ibcmd-dump/src/mssql_dump/mod.rs:32313-32326 — all 5 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:26465` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
D4 · Code Duplication · Duplicated block (13–14 lines × 3) · ×1
  • Duplicated block (13–14 lines × 3) crates/ibcmd-form-writer/src/lib.rs:17834 — crates/ibcmd-form-writer/src/lib.rs:17834-17846 | crates/ibcmd-form-writer/src/lib.rs:17998-18011 | crates/ibcmd-form-writer/src/lib.rs:18160-18173 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-form-writer/src/lib.rs:17834` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (8–14 lines × 2) · ×1
  • Duplicated block (8–14 lines × 2) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:1347 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:1347-1360 | crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:1666-1673 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:1347` it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows — the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members' bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run — a one-line delegation has no helper inside it to lift — so generate the run from the set it enumerates, or accept it and keep each member's own documentation with it.
D4 · Code Duplication · Duplicated block (10–14 lines × 2) · ×1
  • Duplicated block (10–14 lines × 2) src/mssql_apply.rs:1397 — src/mssql_apply.rs:1397-1410 | src/mssql_apply.rs:1487-1496 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `src/mssql_apply.rs:1397` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (10–13 lines × 4) · ×1
  • Duplicated block (10–13 lines × 4) crates/ibcmd-dump/src/mssql_dump/mod.rs:14929 — crates/ibcmd-dump/src/mssql_dump/mod.rs:14929-14941 | crates/ibcmd-dump/src/mssql_dump/mod.rs:20980-20991 | crates/ibcmd-dump/src/mssql_dump/mod.rs:34707-34718 | crates/ibcmd-dump/src/mssql_dump/refs.rs:524-533 — before extracting anything, compare `crates/ibcmd-dump/src/mssql_dump/mod.rs` and `crates/ibcmd-dump/src/mssql_dump/refs.rs` as WHOLE FILES: this scan already matched 13 separate duplicated blocks between them, totalling at least 117 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:14929` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
D4 · Code Duplication · Duplicated block (8–13 lines × 2) · ×1
  • Duplicated block (8–13 lines × 2) crates/ibcmd-compiler/src/compiler/bootstrap.rs:363 — crates/ibcmd-compiler/src/compiler/bootstrap.rs:363-370 | crates/ibcmd-compiler/src/compiler/bootstrap.rs:785-797 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler/src/compiler/bootstrap.rs:363` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
D4 · Code Duplication · Duplicated block (4–13 lines × 3) · ×1
  • Duplicated block (4–13 lines × 3) crates/ibcmd-dump/src/mssql_dump/mod.rs:15393 — crates/ibcmd-dump/src/mssql_dump/mod.rs:15393-15405 | crates/ibcmd-dump/src/mssql_dump/mod.rs:26346-26349 | crates/ibcmd-dump/src/mssql_dump/mod.rs:29353-29365 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:15393` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
D4 · Code Duplication · Duplicated block (5–13 lines × 3) · ×1
  • Duplicated block (5–13 lines × 3) crates/ibcmd-metadata-model/src/metadata_model/registers.rs:400 — crates/ibcmd-metadata-model/src/metadata_model/registers.rs:400-412 | crates/ibcmd-metadata-model/src/metadata_model/registers.rs:414-426 | crates/ibcmd-metadata-model/src/metadata_model/registers.rs:427-431 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-metadata-model/src/metadata_model/registers.rs:400` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
D4 · Code Duplication · Duplicated block (12 lines × 40) · ×1
  • Duplicated block (12 lines × 40) REDACTED:4462 — REDACTED:4462-4473 | REDACTED:4578-4589 | REDACTED:4594-4605 | REDACTED:4610-4621 | REDACTED:4626-4637 | REDACTED:4642-4653 | REDACTED:4658-4669 | REDACTED:4674-4685 | REDACTED:4690-4701 | REDACTED:4704-4715 | REDACTED:4720-4731 | REDACTED:4736-4747 | REDACTED:4752-4763 | REDACTED:4768-4779 | REDACTED:4784-4795 | REDACTED:4800-4811 | REDACTED:4816-4827 | REDACTED:4832-4843 | REDACTED:4848-4859 | REDACTED:4864-4875 | REDACTED:4880-4891 | REDACTED:4896-4907 | REDACTED:4912-4923 | REDACTED:4941-4952 | REDACTED:4957-4968 | REDACTED:4973-4984 | REDACTED:4987-4998 | REDACTED:5003-5014 | REDACTED:5019-5030 | REDACTED:5035-5046 | REDACTED:5051-5062 | REDACTED:5067-5078 | REDACTED:5083-5094 | REDACTED:5099-5110 | REDACTED:5115-5126 | REDACTED:5131-5142 | REDACTED:5147-5158 | REDACTED:5163-5174 | REDACTED:5179-5190 | REDACTED:5195-5206 — all 40 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. 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 `return` inside it is the body's own exit and keeps its meaning in the moved unit. Note first that the copies are not typed on the same thing: the declarations holding them bind `args` to `&MssqlStageExchangePlanObjectArgs` in one and `&MssqlStageBusinessProcessObjectArgs` in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH — their common supertype where they have one, or a new abstraction over them where they do not — and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract.
D4 · Code Duplication · Duplicated block (12 lines × 7) · ×1
  • Duplicated block (12 lines × 7) crates/ibcmd-compiler-families/src/compiler/families/services.rs:1479 — crates/ibcmd-compiler-families/src/compiler/families/services.rs:1479-1490 | crates/ibcmd-compiler-families/src/compiler/families/services.rs:1546-1557 | crates/ibcmd-compiler-families/src/compiler/families/services.rs:1712-1723 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:1450-1461 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:1530-1541 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:1733-1744 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:1835-1846 — before extracting anything, compare `crates/ibcmd-compiler-families/src/compiler/families/services.rs` and `crates/ibcmd-compiler-families/src/compiler/families/simple.rs` as WHOLE FILES: this scan already matched 36 separate duplicated blocks between them, totalling at least 406 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. 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.
D4 · Code Duplication · Duplicated block (11–12 lines × 5) · ×1
  • Duplicated block (11–12 lines × 5) src/storage_map.rs:227 — src/storage_map.rs:227-238 | src/storage_map.rs:262-273 | src/storage_map.rs:297-308 | src/storage_map.rs:334-345 | src/storage_map.rs:371-381 — all 5 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `src/storage_map.rs:227` it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows — the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members' bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run — a one-line delegation has no helper inside it to lift — so generate the run from the set it enumerates, or accept it and keep each member's own documentation with it. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
D4 · Code Duplication · Duplicated block (12 lines × 4) · ×1
  • Duplicated block (12 lines × 4) crates/ibcmd-1c-text/src/brace_list.rs:17 — crates/ibcmd-1c-text/src/brace_list.rs:17-28 | crates/ibcmd-dump/src/mssql_dump/legacy_child.rs:21-32 | crates/ibcmd-dump/src/mssql_dump/upgrade.rs:754-765 | crates/ibcmd-metadata-model/src/metadata_model/audit.rs:269-280 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 4 call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made 4 times. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-1c-text/src/brace_list.rs:17` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (9–12 lines × 3) · ×1
  • Duplicated block (9–12 lines × 3) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:1571 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:1571-1582 | crates/ibcmd-compiler-families/src/compiler/families/business_object/register_native.rs:965-973 | crates/ibcmd-compiler-families/src/compiler/families/business_object/register_native.rs:1264-1272 — there are 3 copies across 2 file(s) — more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 3 sites; resolving a subset leaves the remainder to drift apart. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:1571` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
D4 · Code Duplication · Duplicated block (11–12 lines × 2) · ×1
  • Duplicated block (11–12 lines × 2) crates/ibcmd-compiler-families/src/compiler/families/simple.rs:628 — crates/ibcmd-compiler-families/src/compiler/families/simple.rs:628-639 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:3448-3458 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/simple.rs:628` it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows — the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members' bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run — a one-line delegation has no helper inside it to lift — so generate the run from the set it enumerates, or accept it and keep each member's own documentation with it. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
D4 · Code Duplication · Duplicated block (10–12 lines × 2) · ×1
  • Duplicated block (10–12 lines × 2) crates/ibcmd-form-writer/src/lib.rs:2922 — crates/ibcmd-form-writer/src/lib.rs:2922-2931 | crates/ibcmd-form-writer/src/lib.rs:3416-3427 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-form-writer/src/lib.rs:2922` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (3–12 lines × 3) · ×1
  • Duplicated block (3–12 lines × 3) crates/ibcmd-form-writer/src/lib.rs:6051 — crates/ibcmd-form-writer/src/lib.rs:6051-6053 | crates/ibcmd-form-writer/src/lib.rs:6236-6247 | crates/ibcmd-form-writer/src/lib.rs:6273-6284 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately. Note first that the copies are not typed on the same thing: the declarations holding them bind `attribute` to `&str` in one and `&FormXmlAttribute` in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH — their common supertype where they have one, or a new abstraction over them where they do not — and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, `crates/ibcmd-form-writer/src/lib.rs:6051` calls `find`, `ok_or_else` and `crates/ibcmd-form-writer/src/lib.rs:6236` does not — after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
D4 · Code Duplication · Duplicated block (11 lines × 9) · ×1
  • Duplicated block (11 lines × 9) crates/ibcmd-dump/src/mssql_dump/mod.rs:17962 — crates/ibcmd-dump/src/mssql_dump/mod.rs:17962-17972 | crates/ibcmd-dump/src/mssql_dump/mod.rs:18020-18030 | crates/ibcmd-dump/src/mssql_dump/mod.rs:19012-19022 | crates/ibcmd-dump/src/mssql_dump/mod.rs:26469-26479 | crates/ibcmd-dump/src/mssql_dump/mod.rs:27258-27268 | crates/ibcmd-dump/src/mssql_dump/mod.rs:29022-29032 | crates/ibcmd-dump/src/mssql_dump/mod.rs:30596-30606 | crates/ibcmd-dump/src/mssql_dump/mod.rs:31295-31305 | crates/ibcmd-dump/src/mssql_dump/mod.rs:32317-32327 — all 9 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited.
D4 · Code Duplication · Duplicated block (11 lines × 6) · ×1
  • Duplicated block (11 lines × 6) crates/ibcmd-xml/src/metadata/business_objects.rs:1221 — crates/ibcmd-xml/src/metadata/business_objects.rs:1221-1231 | crates/ibcmd-xml/src/metadata/common_objects.rs:403-413 | crates/ibcmd-xml/src/metadata/hierarchical_objects.rs:821-831 | crates/ibcmd-xml/src/metadata/register_objects.rs:1008-1018 | crates/ibcmd-xml/src/metadata/session_parameter.rs:718-728 | crates/ibcmd-xml/src/metadata/utility_objects.rs:695-705 — before extracting anything, compare `crates/ibcmd-xml/src/metadata/business_objects.rs` and `crates/ibcmd-xml/src/metadata/common_objects.rs` as WHOLE FILES: this scan already matched 4 separate duplicated blocks between them, totalling at least 41 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place.
D4 · Code Duplication · Duplicated block (8–11 lines × 5) · ×1
  • Duplicated block (8–11 lines × 5) crates/ibcmd-form-writer/src/lib.rs:18513 — crates/ibcmd-form-writer/src/lib.rs:18513-18520 | crates/ibcmd-form-writer/src/lib.rs:18530-18537 | crates/ibcmd-form-writer/src/lib.rs:18563-18571 | crates/ibcmd-form-writer/src/lib.rs:18608-18618 | crates/ibcmd-form-writer/src/lib.rs:18819-18827 — all 5 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-form-writer/src/lib.rs:18563` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (10–11 lines × 4) · ×1
  • Duplicated block (10–11 lines × 4) crates/ibcmd-xml/src/metadata/services.rs:1627 — crates/ibcmd-xml/src/metadata/services.rs:1627-1636 | crates/ibcmd-xml/src/metadata/services.rs:1650-1660 | crates/ibcmd-xml/src/metadata/services.rs:1913-1923 | crates/ibcmd-xml/src/metadata/session_parameter.rs:614-624 — before extracting anything, compare `crates/ibcmd-xml/src/metadata/services.rs` and `crates/ibcmd-xml/src/metadata/session_parameter.rs` as WHOLE FILES: this scan already matched 12 separate duplicated blocks between them, totalling at least 114 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-xml/src/metadata/services.rs:1627` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
D4 · Code Duplication · Duplicated block (8–11 lines × 3) · ×1
  • Duplicated block (8–11 lines × 3) crates/ibcmd-metadata-model/src/metadata_model/bodies_predefined.rs:278 — crates/ibcmd-metadata-model/src/metadata_model/bodies_predefined.rs:278-285 | crates/ibcmd-metadata-model/src/metadata_model/bodies_predefined.rs:341-351 | crates/ibcmd-metadata-model/src/metadata_model/bodies_predefined.rs:661-668 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-metadata-model/src/metadata_model/bodies_predefined.rs:341` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, `crates/ibcmd-metadata-model/src/metadata_model/bodies_predefined.rs:277` calls `ref_pattern` and `crates/ibcmd-metadata-model/src/metadata_model/bodies_predefined.rs:340` does not — after which the two agree again for 4 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
D4 · Code Duplication · Duplicated block (8–11 lines × 2) · ×1
  • Duplicated block (8–11 lines × 2) crates/ibcmd-compiler-families/src/compiler/families/services.rs:1950 — crates/ibcmd-compiler-families/src/compiler/families/services.rs:1950-1957 | crates/ibcmd-compiler-families/src/compiler/families/services.rs:2121-2131 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/services.rs:1950` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (9–11 lines × 2) · ×1
  • Duplicated block (9–11 lines × 2) crates/ibcmd-dump/src/mssql_dump/mod.rs:25212 — crates/ibcmd-dump/src/mssql_dump/mod.rs:25212-25220 | crates/ibcmd-dump/src/mssql_dump/refs.rs:1762-1772 — before extracting anything, compare `crates/ibcmd-dump/src/mssql_dump/mod.rs` and `crates/ibcmd-dump/src/mssql_dump/refs.rs` as WHOLE FILES: this scan already matched 13 separate duplicated blocks between them, totalling at least 117 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:25212` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (10 lines × 15) · ×1
  • Duplicated block (10 lines × 15) crates/ibcmd-dump/src/mssql_dump/source_assets.rs:2339 — crates/ibcmd-dump/src/mssql_dump/source_assets.rs:2339-2348 | crates/ibcmd-dump/src/mssql_dump/source_assets.rs:2375-2384 | crates/ibcmd-dump/src/mssql_dump/source_assets.rs:2419-2428 | crates/ibcmd-dump/src/mssql_dump/source_assets.rs:2672-2681 | crates/ibcmd-dump/src/mssql_dump/source_assets.rs:2854-2863 | crates/ibcmd-dump/src/mssql_dump/source_assets.rs:2874-2883 | crates/ibcmd-dump/src/mssql_dump/source_assets.rs:2906-2915 | crates/ibcmd-dump/src/mssql_dump/source_assets.rs:2934-2943 | crates/ibcmd-dump/src/mssql_dump/source_assets.rs:2953-2962 | crates/ibcmd-dump/src/mssql_dump/source_assets.rs:3084-3093 | crates/ibcmd-dump/src/mssql_dump/source_assets.rs:3104-3113 | crates/ibcmd-dump/src/mssql_dump/source_assets.rs:3130-3139 | crates/ibcmd-dump/src/mssql_dump/source_assets.rs:3167-3176 | crates/ibcmd-dump/src/mssql_dump/source_assets.rs:3198-3207 | crates/ibcmd-dump/src/mssql_dump/source_assets.rs:3267-3276 — all 15 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/source_assets.rs:2339` it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows — the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members' bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run — a one-line delegation has no helper inside it to lift — so generate the run from the set it enumerates, or accept it and keep each member's own documentation with it. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, `crates/ibcmd-dump/src/mssql_dump/source_assets.rs:2350` calls `join`, `with_extension` and `crates/ibcmd-dump/src/mssql_dump/source_assets.rs:2385` does not — after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
D4 · Code Duplication · Duplicated block (9–10 lines × 8) · ×1
  • Duplicated block (9–10 lines × 8) crates/ibcmd-compiler-families/src/compiler/families/services.rs:1477 — crates/ibcmd-compiler-families/src/compiler/families/services.rs:1477-1486 | crates/ibcmd-compiler-families/src/compiler/families/services.rs:1545-1553 | crates/ibcmd-compiler-families/src/compiler/families/services.rs:1711-1719 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:1226-1234 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:1449-1457 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:1529-1537 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:1731-1740 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:1834-1842 — before extracting anything, compare `crates/ibcmd-compiler-families/src/compiler/families/services.rs` and `crates/ibcmd-compiler-families/src/compiler/families/simple.rs` as WHOLE FILES: this scan already matched 36 separate duplicated blocks between them, totalling at least 406 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/services.rs:1477` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
D4 · Code Duplication · Duplicated block (10 lines × 8) · ×1
  • Duplicated block (10 lines × 8) crates/ibcmd-dump/src/mssql_dump/mod.rs:38233 — crates/ibcmd-dump/src/mssql_dump/mod.rs:38233-38242 | crates/ibcmd-dump/src/mssql_dump/mod.rs:38311-38320 | crates/ibcmd-dump/src/mssql_dump/mod.rs:40402-40411 | crates/ibcmd-dump/src/mssql_dump/mod.rs:40660-40669 | crates/ibcmd-dump/src/mssql_dump/mod.rs:41332-41341 | crates/ibcmd-dump/src/mssql_dump/mod.rs:41422-41431 | crates/ibcmd-dump/src/mssql_dump/mod.rs:44355-44364 | crates/ibcmd-dump/src/mssql_dump/mod.rs:44550-44559 — all 8 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:38233` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note first that the copies are not typed on the same thing: the declarations holding them bind `dimension` to `&SequenceDimension` in one and `&RecalculationDimension` in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH — their common supertype where they have one, or a new abstraction over them where they do not — and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, `crates/ibcmd-dump/src/mssql_dump/mod.rs:40412` calls `is_empty`, `push_str` and `crates/ibcmd-dump/src/mssql_dump/mod.rs:38243` does not — after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
D4 · Code Duplication · Duplicated block (10 lines × 7) · ×1
  • Duplicated block (10 lines × 7) crates/ibcmd-dump/src/mssql_dump/source_assets.rs:2379 — crates/ibcmd-dump/src/mssql_dump/source_assets.rs:2379-2388 | crates/ibcmd-dump/src/mssql_dump/source_assets.rs:2399-2408 | crates/ibcmd-dump/src/mssql_dump/source_assets.rs:2423-2432 | crates/ibcmd-dump/src/mssql_dump/source_assets.rs:2792-2801 | crates/ibcmd-dump/src/mssql_dump/source_assets.rs:2910-2919 | crates/ibcmd-dump/src/mssql_dump/source_assets.rs:3088-3097 | crates/ibcmd-dump/src/mssql_dump/source_assets.rs:3325-3334 — all 7 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/source_assets.rs:2379` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, `crates/ibcmd-dump/src/mssql_dump/source_assets.rs:2390` calls `extract_standalone_content_xml`, `with_context` and `crates/ibcmd-dump/src/mssql_dump/source_assets.rs:2921` does not — after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
D4 · Code Duplication · Duplicated block (19–20 lines × 3) · ×1
  • Duplicated block (19–20 lines × 3) crates/ibcmd-xml/src/dcs.rs:2403 — crates/ibcmd-xml/src/dcs.rs:2403-2422 | crates/ibcmd-xml/src/dcs.rs:2791-2809 | crates/ibcmd-xml/src/dcs.rs:3667-3686 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-xml/src/dcs.rs:2403` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (7–10 lines × 2) · ×1
  • Duplicated block (7–10 lines × 2) crates/ibcmd-compiler/src/compiler/bootstrap.rs:392 — crates/ibcmd-compiler/src/compiler/bootstrap.rs:392-398 | crates/ibcmd-xml/src/metadata/external_named.rs:349-358 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler/src/compiler/bootstrap.rs:392` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (8–10 lines × 2) · ×1
  • Duplicated block (8–10 lines × 2) crates/ibcmd-xml/src/metadata/functional_option.rs:154 — crates/ibcmd-xml/src/metadata/functional_option.rs:154-163 | crates/ibcmd-xml/src/metadata/session_parameter.rs:266-273 — before extracting anything, compare `crates/ibcmd-xml/src/metadata/functional_option.rs` and `crates/ibcmd-xml/src/metadata/session_parameter.rs` as WHOLE FILES: this scan already matched 10 separate duplicated blocks between them, totalling at least 96 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-xml/src/metadata/functional_option.rs:154` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
D4 · Code Duplication · Duplicated block (9 lines × 15) · ×1
  • Duplicated block (9 lines × 15) crates/ibcmd-dump/src/mssql_dump/source_assets.rs:2378 — crates/ibcmd-dump/src/mssql_dump/source_assets.rs:2378-2386 | crates/ibcmd-dump/src/mssql_dump/source_assets.rs:2398-2406 | crates/ibcmd-dump/src/mssql_dump/source_assets.rs:2422-2430 | crates/ibcmd-dump/src/mssql_dump/source_assets.rs:2592-2600 | crates/ibcmd-dump/src/mssql_dump/source_assets.rs:2791-2799 | crates/ibcmd-dump/src/mssql_dump/source_assets.rs:2857-2865 | crates/ibcmd-dump/src/mssql_dump/source_assets.rs:2877-2885 | crates/ibcmd-dump/src/mssql_dump/source_assets.rs:2909-2917 | crates/ibcmd-dump/src/mssql_dump/source_assets.rs:3087-3095 | crates/ibcmd-dump/src/mssql_dump/source_assets.rs:3107-3115 | crates/ibcmd-dump/src/mssql_dump/source_assets.rs:3133-3141 | crates/ibcmd-dump/src/mssql_dump/source_assets.rs:3170-3178 | crates/ibcmd-dump/src/mssql_dump/source_assets.rs:3201-3209 | crates/ibcmd-dump/src/mssql_dump/source_assets.rs:3234-3242 | crates/ibcmd-dump/src/mssql_dump/source_assets.rs:3324-3332 — all 15 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/source_assets.rs:2857` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
D4 · Code Duplication · Duplicated block (9 lines × 8) · ×1
  • Duplicated block (9 lines × 8) crates/ibcmd-schema/src/lib.rs:13311 — crates/ibcmd-schema/src/lib.rs:13311-13319 | crates/ibcmd-schema/src/lib.rs:13553-13561 | crates/ibcmd-schema/src/lib.rs:13585-13593 | crates/ibcmd-schema/src/lib.rs:13622-13630 | crates/ibcmd-schema/src/lib.rs:13657-13665 | crates/ibcmd-schema/src/lib.rs:14147-14155 | crates/ibcmd-schema/src/lib.rs:14678-14686 | crates/ibcmd-schema/src/lib.rs:14723-14731 — all 8 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-schema/src/lib.rs:13311` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (9 lines × 6) · ×1
  • Duplicated block (9 lines × 6) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:1403 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:1403-1413 | crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:1571-1581 | crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:1703-1713 | crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:1836-1846 | crates/ibcmd-compiler-families/src/compiler/families/business_object/register_native.rs:965-973 | crates/ibcmd-compiler-families/src/compiler/families/business_object/register_native.rs:1264-1272 — there are 6 copies across 2 file(s) — more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 6 sites; resolving a subset leaves the remainder to drift apart. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:1403` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
D4 · Code Duplication · Duplicated block (8–9 lines × 5) · ×1
  • Duplicated block (8–9 lines × 5) crates/ibcmd-xml/src/metadata/services.rs:1598 — crates/ibcmd-xml/src/metadata/services.rs:1598-1606 | crates/ibcmd-xml/src/metadata/services.rs:1702-1710 | crates/ibcmd-xml/src/metadata/services.rs:1774-1782 | crates/ibcmd-xml/src/metadata/services.rs:1893-1900 | crates/ibcmd-xml/src/metadata/session_parameter.rs:593-600 — before extracting anything, compare `crates/ibcmd-xml/src/metadata/services.rs` and `crates/ibcmd-xml/src/metadata/session_parameter.rs` as WHOLE FILES: this scan already matched 12 separate duplicated blocks between them, totalling at least 114 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, `crates/ibcmd-xml/src/metadata/services.rs:1713` calls `typed` and `crates/ibcmd-xml/src/metadata/services.rs:1609` does not — after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
D4 · Code Duplication · Duplicated block (8–9 lines × 4) · ×1
  • Duplicated block (8–9 lines × 4) crates/ibcmd-dump/src/mssql_dump/mod.rs:31186 — crates/ibcmd-dump/src/mssql_dump/mod.rs:31186-31193 | crates/ibcmd-dump/src/mssql_dump/mod.rs:32212-32219 | crates/ibcmd-dump/src/mssql_dump/mod.rs:32857-32865 | crates/ibcmd-dump/src/mssql_dump/mod.rs:32952-32960 — all 4 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited.
D4 · Code Duplication · Duplicated block (8–9 lines × 3) · ×1
  • Duplicated block (8–9 lines × 3) crates/ibcmd-metadata-blob/src/lib.rs:2366 — crates/ibcmd-metadata-blob/src/lib.rs:2366-2374 | crates/ibcmd-metadata-blob/src/lib.rs:3256-3263 | crates/ibcmd-metadata-blob/src/lib.rs:3337-3345 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-metadata-blob/src/lib.rs:2366` it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows — the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members' bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run — a one-line delegation has no helper inside it to lift — so generate the run from the set it enumerates, or accept it and keep each member's own documentation with it. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
D4 · Code Duplication · Duplicated block (8 lines × 15) · ×1
  • Duplicated block (8 lines × 15) crates/ibcmd-form-writer/src/lib.rs:8081 — crates/ibcmd-form-writer/src/lib.rs:8081-8088 | crates/ibcmd-form-writer/src/lib.rs:10021-10028 | crates/ibcmd-metadata-blob/src/interface_assets.rs:292-299 | crates/ibcmd-metadata-blob/src/lib.rs:2023-2030 | crates/ibcmd-metadata-blob/src/lib.rs:4523-4530 | crates/ibcmd-metadata-blob/src/lib.rs:5080-5087 | crates/ibcmd-metadata-blob/src/lib.rs:5185-5192 | crates/ibcmd-metadata-blob/src/lib.rs:5243-5250 | crates/ibcmd-metadata-blob/src/lib.rs:5353-5360 | crates/ibcmd-metadata-blob/src/lib.rs:5616-5623 | crates/ibcmd-metadata-blob/src/lib.rs:5727-5734 | crates/ibcmd-metadata-blob/src/lib.rs:5857-5864 | crates/ibcmd-metadata-blob/src/lib.rs:6021-6028 | crates/ibcmd-metadata-blob/src/lib.rs:6171-6178 | crates/ibcmd-metadata-blob/src/lib.rs:6378-6385 — before extracting anything, compare `crates/ibcmd-form-writer/src/lib.rs` and `crates/ibcmd-metadata-blob/src/lib.rs` as WHOLE FILES: this scan already matched 5 separate duplicated blocks between them, totalling at least 33 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. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, `crates/ibcmd-form-writer/src/lib.rs:10029` calls `form_nested_text_element`, `push_str` and `crates/ibcmd-metadata-blob/src/lib.rs:2031` does not — after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
D4 · Code Duplication · Duplicated block (8 lines × 9) · ×1
  • Duplicated block (8 lines × 9) crates/ibcmd-xml/src/metadata/services.rs:1598 — crates/ibcmd-xml/src/metadata/services.rs:1598-1606 | crates/ibcmd-xml/src/metadata/services.rs:1629-1636 | crates/ibcmd-xml/src/metadata/services.rs:1652-1660 | crates/ibcmd-xml/src/metadata/services.rs:1702-1710 | crates/ibcmd-xml/src/metadata/services.rs:1774-1782 | crates/ibcmd-xml/src/metadata/services.rs:1893-1900 | crates/ibcmd-xml/src/metadata/services.rs:1915-1923 | crates/ibcmd-xml/src/metadata/session_parameter.rs:593-600 | crates/ibcmd-xml/src/metadata/session_parameter.rs:616-624 — before extracting anything, compare `crates/ibcmd-xml/src/metadata/services.rs` and `crates/ibcmd-xml/src/metadata/session_parameter.rs` as WHOLE FILES: this scan already matched 12 separate duplicated blocks between them, totalling at least 114 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, `crates/ibcmd-xml/src/metadata/services.rs:1595` calls `reject_attributes`, `root`, `required_child` and `crates/ibcmd-xml/src/metadata/services.rs:1628` does not — after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
D4 · Code Duplication · Duplicated block (6–8 lines × 3) · ×1
  • Duplicated block (6–8 lines × 3) crates/ibcmd-xml/src/metadata/constant.rs:696 — crates/ibcmd-xml/src/metadata/constant.rs:696-701 | crates/ibcmd-xml/src/metadata/external_named.rs:481-488 | crates/ibcmd-xml/src/metadata/language.rs:419-424 — before extracting anything, compare `crates/ibcmd-xml/src/metadata/constant.rs` and `crates/ibcmd-xml/src/metadata/language.rs` as WHOLE FILES: this scan already matched 19 separate duplicated blocks between them, totalling at least 213 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-xml/src/metadata/constant.rs:696` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
D4 · Code Duplication · Duplicated block (6–8 lines × 2) · ×1
  • Duplicated block (6–8 lines × 2) crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:2914 — crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:2914-2921 | crates/ibcmd-compiler-families/src/compiler/families/utility.rs:1495-1500 — before extracting anything, compare `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs` and `crates/ibcmd-compiler-families/src/compiler/families/utility.rs` as WHOLE FILES: this scan already matched 65 separate duplicated blocks between them, totalling at least 934 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/business_object.rs:2914` it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows — the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members' bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run — a one-line delegation has no helper inside it to lift — so generate the run from the set it enumerates, or accept it and keep each member's own documentation with it. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
D4 · Code Duplication · Duplicated block (7 lines × 12) · ×1
  • Duplicated block (7 lines × 12) crates/ibcmd-dump/src/mssql_dump/source_assets.rs:2378 — crates/ibcmd-dump/src/mssql_dump/source_assets.rs:2378-2386 | crates/ibcmd-dump/src/mssql_dump/source_assets.rs:2397-2406 | crates/ibcmd-dump/src/mssql_dump/source_assets.rs:2422-2430 | crates/ibcmd-dump/src/mssql_dump/source_assets.rs:2857-2863 | crates/ibcmd-dump/src/mssql_dump/source_assets.rs:2877-2883 | crates/ibcmd-dump/src/mssql_dump/source_assets.rs:2909-2917 | crates/ibcmd-dump/src/mssql_dump/source_assets.rs:2937-2945 | crates/ibcmd-dump/src/mssql_dump/source_assets.rs:3087-3095 | crates/ibcmd-dump/src/mssql_dump/source_assets.rs:3107-3113 | crates/ibcmd-dump/src/mssql_dump/source_assets.rs:3133-3139 | crates/ibcmd-dump/src/mssql_dump/source_assets.rs:3170-3176 | crates/ibcmd-dump/src/mssql_dump/source_assets.rs:3201-3207 — all 12 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/source_assets.rs:2397` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
D4 · Code Duplication · Duplicated block (6–7 lines × 5) · ×1
  • Duplicated block (6–7 lines × 5) crates/ibcmd-metadata-blob/src/lib.rs:3222 — crates/ibcmd-metadata-blob/src/lib.rs:3222-3227 | crates/ibcmd-metadata-blob/src/lib.rs:5790-5796 | crates/ibcmd-metadata-blob/src/lib.rs:5969-5975 | crates/ibcmd-metadata-blob/src/lib.rs:6098-6104 | crates/ibcmd-metadata-blob/src/lib.rs:6284-6290 — all 5 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited.
D4 · Code Duplication · Duplicated block (4–7 lines × 5) · ×1
  • Duplicated block (4–7 lines × 5) crates/ibcmd-dump/src/mssql_dump/mod.rs:26215 — crates/ibcmd-dump/src/mssql_dump/mod.rs:26215-26218 | crates/ibcmd-dump/src/mssql_dump/mod.rs:28863-28868 | crates/ibcmd-dump/src/mssql_dump/mod.rs:29912-29917 | crates/ibcmd-dump/src/mssql_dump/mod.rs:31156-31162 | crates/ibcmd-dump/src/mssql_dump/mod.rs:31937-31942 — all 5 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:26215` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
D4 · Code Duplication · Duplicated block (6 lines × 17) · ×1
  • Duplicated block (6 lines × 17) crates/ibcmd-xml/src/metadata/business_objects.rs:1220 — crates/ibcmd-xml/src/metadata/business_objects.rs:1220-1225 | crates/ibcmd-xml/src/metadata/common_objects.rs:402-407 | crates/ibcmd-xml/src/metadata/constant.rs:612-617 | crates/ibcmd-xml/src/metadata/functional_option.rs:337-342 | crates/ibcmd-xml/src/metadata/functional_options_parameter.rs:319-324 | crates/ibcmd-xml/src/metadata/hierarchical_objects.rs:820-825 | crates/ibcmd-xml/src/metadata/language.rs:337-342 | crates/ibcmd-xml/src/metadata/register_objects.rs:1007-1012 | crates/ibcmd-xml/src/metadata/services.rs:2522-2527 | crates/ibcmd-xml/src/metadata/services.rs:2565-2570 | crates/ibcmd-xml/src/metadata/services.rs:2609-2614 | crates/ibcmd-xml/src/metadata/services.rs:2652-2657 | crates/ibcmd-xml/src/metadata/services.rs:2695-2700 | crates/ibcmd-xml/src/metadata/services.rs:2738-2743 | crates/ibcmd-xml/src/metadata/services.rs:2781-2786 | crates/ibcmd-xml/src/metadata/session_parameter.rs:717-722 | crates/ibcmd-xml/src/metadata/utility_objects.rs:694-699 — before extracting anything, compare `crates/ibcmd-xml/src/metadata/business_objects.rs` and `crates/ibcmd-xml/src/metadata/common_objects.rs` as WHOLE FILES: this scan already matched 4 separate duplicated blocks between them, totalling at least 41 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place.
D4 · Code Duplication · Duplicated block (6 lines × 6) · ×1
  • Duplicated block (6 lines × 6) crates/ibcmd-dump/src/mssql_dump/mod.rs:32861 — crates/ibcmd-dump/src/mssql_dump/mod.rs:32861-32867 | crates/ibcmd-dump/src/mssql_dump/mod.rs:32956-32962 | crates/ibcmd-dump/src/mssql_dump/mod.rs:35254-35259 | crates/ibcmd-dump/src/mssql_dump/mod.rs:35293-35298 | crates/ibcmd-dump/src/mssql_dump/mod.rs:35319-35324 | crates/ibcmd-dump/src/mssql_dump/mod.rs:35369-35374 — all 6 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/mod.rs:32861` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (5–6 lines × 2) · ×1
  • Duplicated block (5–6 lines × 2) crates/ibcmd-compiler-families/src/compiler/families/simple.rs:1918 — crates/ibcmd-compiler-families/src/compiler/families/simple.rs:1918-1923 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:1975-1979 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/simple.rs:1918` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
D4 · Code Duplication · Duplicated block (3–6 lines × 4) · ×1
  • Duplicated block (3–6 lines × 4) crates/ibcmd-dump/src/mssql_dump/refs.rs:88 — crates/ibcmd-dump/src/mssql_dump/refs.rs:88-90 | crates/ibcmd-dump/src/mssql_dump/refs.rs:2312-2317 | crates/ibcmd-dump/src/mssql_dump/refs.rs:2372-2376 | crates/ibcmd-dump/src/mssql_dump/refs.rs:3061-3063 — all 4 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-dump/src/mssql_dump/refs.rs:88` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, `crates/ibcmd-dump/src/mssql_dump/refs.rs:2377` calls `extend`, `catalog_single_owner_type_entries` and `crates/ibcmd-dump/src/mssql_dump/refs.rs:2317` does not — after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
D4 · Code Duplication · Duplicated block (5 lines × 8) · ×1
  • Duplicated block (5 lines × 8) crates/ibcmd-form-body/src/form_body.rs:2985 — crates/ibcmd-form-body/src/form_body.rs:2985-2989 | crates/ibcmd-form-body/src/form_body.rs:2999-3003 | crates/ibcmd-form-body/src/form_body.rs:3062-3066 | crates/ibcmd-form-body/src/form_body.rs:3105-3109 | crates/ibcmd-form-body/src/form_body.rs:3123-3127 | crates/ibcmd-form-body/src/form_body.rs:3150-3154 | crates/ibcmd-form-body/src/form_body.rs:19567-19571 | crates/ibcmd-form-body/src/form_body.rs:21183-21187 — all 8 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-form-body/src/form_body.rs:2985` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, `crates/ibcmd-form-body/src/form_body.rs:3069` calls `Some` and `crates/ibcmd-form-body/src/form_body.rs:2992` does not — after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
D4 · Code Duplication · Duplicated block (4–5 lines × 5) · ×1
  • Duplicated block (4–5 lines × 5) crates/ibcmd-metadata-model/src/metadata_model/external_data_source_children.rs:341 — crates/ibcmd-metadata-model/src/metadata_model/external_data_source_children.rs:341-344 | crates/ibcmd-metadata-model/src/metadata_model/external_data_source_children.rs:634-638 | crates/ibcmd-metadata-model/src/metadata_model/external_data_source_children.rs:648-652 | crates/ibcmd-metadata-model/src/metadata_model/external_data_source_children.rs:664-668 | crates/ibcmd-metadata-model/src/metadata_model/external_data_source_children.rs:717-720 — all 5 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-metadata-model/src/metadata_model/external_data_source_children.rs:634` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (4–5 lines × 3) · ×1
  • Duplicated block (4–5 lines × 3) REDACTED:460 — REDACTED:460-464 | REDACTED:909-912 | REDACTED:1160-1164 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `REDACTED:460` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (42 lines × 2) · ×1
  • Duplicated block (42 lines × 2) crates/ibcmd-compiler-families/src/compiler/families/form.rs:125 — crates/ibcmd-compiler-families/src/compiler/families/form.rs:125-166 | crates/ibcmd-compiler-families/src/compiler/families/modules.rs:52-93 — before extracting anything, compare `crates/ibcmd-compiler-families/src/compiler/families/form.rs` and `crates/ibcmd-compiler-families/src/compiler/families/modules.rs` as WHOLE FILES: this scan already matched 8 separate duplicated blocks between them, totalling at least 141 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place.
D4 · Code Duplication · Duplicated block (34–35 lines × 2) · ×1
  • Duplicated block (34–35 lines × 2) crates/ibcmd-xml/src/metadata/services.rs:650 — crates/ibcmd-xml/src/metadata/services.rs:650-683 | crates/ibcmd-xml/src/metadata/services.rs:804-838 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-xml/src/metadata/services.rs:650` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (13 lines × 7) · ×1
  • Duplicated block (13 lines × 7) crates/ibcmd-compiler-families/src/compiler/families/services.rs:1451 — crates/ibcmd-compiler-families/src/compiler/families/services.rs:1451-1463 | crates/ibcmd-compiler-families/src/compiler/families/services.rs:1529-1541 | crates/ibcmd-compiler-families/src/compiler/families/services.rs:1695-1707 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:1433-1445 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:1513-1525 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:1709-1721 | crates/ibcmd-compiler-families/src/compiler/families/simple.rs:1818-1830 — before extracting anything, compare `crates/ibcmd-compiler-families/src/compiler/families/services.rs` and `crates/ibcmd-compiler-families/src/compiler/families/simple.rs` as WHOLE FILES: this scan already matched 36 separate duplicated blocks between them, totalling at least 406 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-compiler-families/src/compiler/families/services.rs:1451` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (10 lines × 5) · ×1
  • Duplicated block (10 lines × 5) crates/ibcmd-xml/src/metadata/business_objects.rs:1233 — crates/ibcmd-xml/src/metadata/business_objects.rs:1233-1242 | crates/ibcmd-xml/src/metadata/common_objects.rs:415-424 | crates/ibcmd-xml/src/metadata/hierarchical_objects.rs:833-842 | crates/ibcmd-xml/src/metadata/register_objects.rs:1020-1029 | crates/ibcmd-xml/src/metadata/utility_objects.rs:707-716 — before extracting anything, compare `crates/ibcmd-xml/src/metadata/business_objects.rs` and `crates/ibcmd-xml/src/metadata/common_objects.rs` as WHOLE FILES: this scan already matched 4 separate duplicated blocks between them, totalling at least 41 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-xml/src/metadata/business_objects.rs:1233` it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows — the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members' bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run — a one-line delegation has no helper inside it to lift — so generate the run from the set it enumerates, or accept it and keep each member's own documentation with it. 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.
D4 · Code Duplication · Duplicated block (9 lines × 9) · ×1
  • Duplicated block (9 lines × 9) crates/ibcmd-schema/src/lib.rs:7987 — crates/ibcmd-schema/src/lib.rs:7987-7995 | crates/ibcmd-schema/src/lib.rs:8095-8103 | crates/ibcmd-schema/src/lib.rs:8390-8398 | crates/ibcmd-schema/src/lib.rs:8595-8603 | crates/ibcmd-schema/src/lib.rs:8938-8946 | crates/ibcmd-schema/src/lib.rs:9183-9191 | crates/ibcmd-schema/src/lib.rs:9454-9462 | crates/ibcmd-schema/src/lib.rs:9733-9742 | crates/ibcmd-schema/src/lib.rs:9966-9974 — all 9 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `crates/ibcmd-schema/src/lib.rs:7987` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (5 lines × 7) · ×1
  • Duplicated block (5 lines × 7) crates/ibcmd-dump/src/mssql_dump/mod.rs:8040 — crates/ibcmd-dump/src/mssql_dump/mod.rs:8040-8044 | crates/ibcmd-dump/src/mssql_dump/mod.rs:22906-22910 | crates/ibcmd-dump/src/mssql_dump/mod.rs:23070-23074 | crates/ibcmd-dump/src/mssql_dump/source_assets.rs:4378-4382 | crates/ibcmd-dump/src/mssql_dump/source_assets.rs:4431-4435 | crates/ibcmd-dump/src/mssql_dump/source_assets.rs:4691-4695 | crates/ibcmd-dump/src/mssql_dump/source_assets.rs:4761-4765 — before extracting anything, compare `crates/ibcmd-dump/src/mssql_dump/mod.rs` and `crates/ibcmd-dump/src/mssql_dump/source_assets.rs` as WHOLE FILES: this scan already matched 5 separate duplicated blocks between them, totalling at least 36 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place.
D4 · Code Duplication · Duplicated block (10–13 lines × 3) · ×1
  • Duplicated block (10–13 lines × 3) _onecdec/make_old_root_fixtures.py:38 — _onecdec/make_old_root_fixtures.py:38-50 | _onecdec/make_upgrade_fixtures.py:121-133 | _onecdec/spike_adapter.py:16-25 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from all 3 call sites, so a change lands once.
D4 · Code Duplication · Duplicated block (92 lines × 3) · ×1
  • Duplicated block (92 lines × 3) docs/apply/evidence/live-gate/compact8-runtime-preexec/read_compact8_recovery.py:4 — docs/apply/evidence/live-gate/compact8-runtime-preexec/read_compact8_recovery.py:4-95 | docs/apply/evidence/live-gate/compact9-runtime-preexec/read_compact9_recovery.py:4-95 | docs/apply/evidence/live-gate/compact9-startup-preexec-v2/read_compact9_recovery.py:4-95 — `docs/apply/evidence/live-gate/compact8-runtime-preexec/read_compact8_recovery.py` and `docs/apply/evidence/live-gate/compact9-runtime-preexec/read_compact9_recovery.py` are one unit implemented once per sibling directory, so they are most likely parallel implementations of one contract rather than a copy of each other — this scan matched 1 separate duplicated blocks between them, totalling at least 92 lines. If both are selected at run time, neither can be retired in favour of the other, and the lines that DIFFER between them are the reason both exist. The move that pays here is to hoist the identical part into a shared location the whole family can reach and give what differs a parameter or a seam, so a change lands once instead of once per sibling; extracting one helper per block leaves every sibling to drift on its own. Read the line range as the matched WINDOW rather than a finished unit: at `docs/apply/evidence/live-gate/compact8-runtime-preexec/read_compact8_recovery.py:4` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Edited copies of one member (5 members, 33+ corresponding lines) · ×1
  • Edited copies of one member (5 members, 33+ corresponding lines) _onecdec/make_adopted_exchange_plan_fixture.py:39 — _onecdec/make_adopted_exchange_plan_fixture.py:39-76 | _onecdec/make_adopted_predefined_fixture.py:43-75 | _onecdec/make_adopted_role_fixture.py:51-89 | _onecdec/make_adopted_subscription_fixture.py:40-78 | _onecdec/make_foreign_links_fixture.py:52-87 — These 5 members are one piece of code written 5 times and then edited apart: every two of them correspond over at least 33 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 5 times and the copies will drift further apart.
D4 · Code Duplication · Edited copies of one member (3 members, 25+ corresponding lines) · ×1
  • Edited copies of one member (3 members, 25+ corresponding lines) scripts/apply-trace/lab/s1g-caches/make_cases_n.py:71 — scripts/apply-trace/lab/s1g-caches/make_cases_n.py:71-95 | scripts/import-lab/edits.py:130-174 | scripts/restructure-lab/edit_tree.py:50-94 — These 3 members are one piece of code written 3 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' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart.
D4 · Code Duplication · Edited copy of a member (1 corresponding lines) · ×1
  • Edited copy of a member (1 corresponding lines) scripts/apply-lab/live/workload/analyze_isolated.py:24 — scripts/apply-lab/live/workload/analyze_isolated.py:24-24 | scripts/apply-lab/live/workload/analyze_private4.py:14-14 — These two members are one piece of code written twice and then edited apart: 1 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copies of one member (3 members, 2+ corresponding lines) · ×1
  • Edited copies of one member (3 members, 2+ corresponding lines) scripts/restructure-lab/entries_diff.py:17 — scripts/restructure-lab/entries_diff.py:17-18 | scripts/restructure-lab/s1k/checks56.py:42-43 | scripts/restructure-lab/schemadiff.py:6-7 — These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 2 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart.
D4 · Code Duplication · Edited copy of a member (3 corresponding lines) · ×1
  • Edited copy of a member (3 corresponding lines) scripts/restructure-lab/assemble_evidence.py:29 — scripts/restructure-lab/assemble_evidence.py:29-31 | scripts/restructure-lab/assemble_evidence_run.py:19-21 — These two members are one piece of code written twice and then edited apart: 3 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Duplicated block (41 lines × 2) · ×1
  • Duplicated block (41 lines × 2) scripts/apply-trace/lab/s1g-caches/snapshot.py:74 — scripts/apply-trace/lab/s1g-caches/snapshot.py:74-114 | scripts/restructure-lab/snapshot.py:74-114 — before extracting anything, compare `scripts/apply-trace/lab/s1g-caches/snapshot.py` and `scripts/restructure-lab/snapshot.py` as WHOLE FILES: this scan already matched 5 separate duplicated blocks between them, totalling at least 122 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 `return` at the foot of the matched lines is the enclosing body's own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that `return` occupied — no decision has to be handed back and re-acted on.
D44 · Platform End-of-Life · End-of-life runtime · ×1
  • End-of-life runtime: Rust 1.95 rust-toolchain.toml:1 — rust-toolchain.toml declares Rust 1.95 as this project's toolchain file, and Rust 1.95, superseded by 1.96 on 2026-05-28 (the Rust project patches only the current stable). An unsupported runtime receives no security patches, so every vulnerability disclosed in it since 2026-05-28 is present and unfixable without moving off it. This is a migration rather than an upgrade: there is no newer release of a runtime that has ended.
D5 · Coupling · Unstable project ibcmd-config-apply · ×1
  • Unstable project ibcmd-config-apply — ibcmd-config-apply has instability 0.86 with 2 dependents.
D5 · Coupling · Unstable project ibcmd-dump · ×1
  • Unstable project ibcmd-dump — ibcmd-dump has instability 0.96 with 1 dependents.
P2 · Observability · No structured logging · ×1
  • No structured logging — No logging call was found in the 736 Python, Rust, JavaScript/TypeScript production file(s) this check read across 42 module(s). Each was searched for its ecosystem's logging libraries (Python: logging, structlog, loguru; JavaScript/TypeScript: pino, winston, bunyan, log4js, loglevel, consola, the NestJS Logger; Rust: the log and tracing crates (info!/warn!/error!, #[instrument]), slog, env_logger) and for a call on a receiver named `log`/`logger` (or ending in `Logger`/`_logger`) with a level verb. It cannot see logging through a repo-local wrapper named otherwise, or in source it did not read — this is 'no logging found by this walk', not a verdict that nothing here logs. If it is right, production issues will be hard to diagnose.
R1 · Type Safety · Type Safety · ×1
  • Type Safety — 15 typed · 29 plain JS — the untyped files are editors/vscode/scripts/build.cjs, editors/vscode/scripts/python.cjs, editors/vscode/test/apply.test.js, editors/vscode/test/configuration-tree.test.js, editors/vscode/test/connection.test.js, editors/vscode/test/core.test.js (+23 more).
R10 · Code Duplication · Duplicated block with local edits (23 matched lines × 2 locations) · ×1
  • Duplicated block with local edits (23 matched lines × 2 locations) editors/vscode/src/extension.ts:257 — editors/vscode/src/extension.ts:257 · editors/vscode/src/extension.ts:493 — the two spans are one implementation copied and then locally edited — 110 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's 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 — 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.
R10 · Code Duplication · Duplicated block with local edits (16 matched lines × 2 locations) · ×1
  • Duplicated block with local edits (16 matched lines × 2 locations) editors/vscode/src/configuration-view.ts:32 — editors/vscode/src/configuration-view.ts:32 · editors/vscode/src/database-commands.ts:28 — the two spans are one implementation copied and then locally edited — 77 tokens are still identical, in the same order in both files, with only local edits between them. The copies have already begun to drift, which is this row's 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 — 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.
R10 · Code Duplication · Duplicated block with local edits (11 matched lines × 2 locations) · ×1
  • Duplicated block with local edits (11 matched lines × 2 locations) editors/vscode/src/git-baseline.ts:10 — editors/vscode/src/git-baseline.ts:10 · editors/vscode/src/object-export.ts:91 — the two spans are one implementation copied and then locally edited — 55 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's 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 — 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.
R10 · Code Duplication · Duplicated block (10 lines × 3 locations) · ×1
  • Duplicated block (10 lines × 3 locations) editors/vscode/src/configuration-view.ts:83 — editors/vscode/src/configuration-view.ts:83 · editors/vscode/src/database-commands.ts:95 · editors/vscode/src/object-export.ts:203 — the 3 copies are spread across 3 files, and the CITED SPAN is not a self-contained block — it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead — the whole function, component or branch these lines sit in — and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported.
R10 · Code Duplication · Duplicated block (10 lines × 2 locations) · ×1
  • Duplicated block (10 lines × 2 locations) editors/vscode/src/extension.ts:362 — editors/vscode/src/extension.ts:362 · editors/vscode/src/extension.ts:517 — all 2 copies are in the same file, and the CITED SPAN is not a self-contained block — it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead — the whole function, component or branch these lines sit in — and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported.
R10 · Code Duplication · Duplicated block with local edits (10 matched lines × 2 locations) · ×1
  • Duplicated block with local edits (10 matched lines × 2 locations) editors/vscode/src/object-export.ts:173 — editors/vscode/src/object-export.ts:173 · editors/vscode/src/object-view.ts:164 — the two spans are one implementation copied and then locally edited — 67 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's 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 — 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.
R10 · Code Duplication · Duplicated block with local edits (9 matched lines × 2 locations) · ×1
  • Duplicated block with local edits (9 matched lines × 2 locations) editors/vscode/src/extension.ts:178 — editors/vscode/src/extension.ts:178 · editors/vscode/src/object-view.ts:190 — the two spans are one implementation copied and then locally edited — 59 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's 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 — 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.
R2 · Cyclomatic Complexity · Complex function edit (cyclomatic 43, cognitive 41) · ×1
  • Complex function edit (cyclomatic 43, cognitive 41) editors/vscode/src/extension.ts:697 — edit has cyclomatic complexity 43 and cognitive complexity 41; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth — arms side by side rather than stacked — and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes.
R2 · Cyclomatic Complexity · Complex function (anonymous) (cyclomatic 34, cognitive 44) · ×1
  • Complex function (anonymous) (cyclomatic 34, cognitive 44) editors/vscode/src/object-view.ts:196 — (anonymous) has cyclomatic complexity 34 and cognitive complexity 44; 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 — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes.
R2 · Cyclomatic Complexity · Complex function (anonymous) (cyclomatic 30, cognitive 72) · ×1
  • Complex function (anonymous) (cyclomatic 30, cognitive 72) editors/vscode/test/fake-host-server.js:18 — (anonymous) has cyclomatic complexity 30 and cognitive complexity 72; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes.
R2 · Cyclomatic Complexity · Complex function importFiles (cyclomatic 28, cognitive 26) · ×1
  • Complex function importFiles (cyclomatic 28, cognitive 26) editors/vscode/src/extension.ts:253 — importFiles has cyclomatic complexity 28 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 — arms side by side rather than stacked — and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes.
R2 · Cyclomatic Complexity · Complex function editConfig (cyclomatic 25, cognitive 30) · ×1
  • Complex function editConfig (cyclomatic 25, cognitive 30) editors/vscode/src/config.ts:24 — editConfig has cyclomatic complexity 25 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 — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes.
R2 · Cyclomatic Complexity · Complex function run (cyclomatic 21, cognitive 28) · ×1
  • Complex function run (cyclomatic 21, cognitive 28) editors/vscode/test/host-suite.js:6 — run has cyclomatic complexity 21 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 — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes.
R2 · Cyclomatic Complexity · Complex function (anonymous) (cyclomatic 21, cognitive 26) · ×1
  • Complex function (anonymous) (cyclomatic 21, cognitive 26) editors/vscode/src/object-export.ts:209 — (anonymous) has cyclomatic complexity 21 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 — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes.
R2 · Cyclomatic Complexity · Complex function classifyVersioned (cyclomatic 21, cognitive 10) · ×1
  • Complex function classifyVersioned (cyclomatic 21, cognitive 10) editors/vscode/src/object-status.ts:48 — classifyVersioned has cyclomatic complexity 21 and cognitive complexity 10; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth — arms side by side rather than stacked — and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes.
R2 · Cyclomatic Complexity · Complex function runExport (cyclomatic 19, cognitive 25) · ×1
  • Complex function runExport (cyclomatic 19, cognitive 25) editors/vscode/src/extension.ts:426 — runExport has cyclomatic complexity 19 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 — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes.
R2 · Cyclomatic Complexity · Complex function switchTo (cyclomatic 17, cognitive 29) · ×1
  • Complex function switchTo (cyclomatic 17, cognitive 29) editors/vscode/src/extension.ts:113 — switchTo has cyclomatic complexity 17 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 — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes.
R2 · Cyclomatic Complexity · Complex function children (cyclomatic 17, cognitive 16) · ×1
  • Complex function children (cyclomatic 17, cognitive 16) editors/vscode/src/configuration-tree.ts:505 — children has cyclomatic complexity 17 and cognitive complexity 16; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth — arms side by side rather than stacked — and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes.
R2 · Cyclomatic Complexity · Complex function gitBaseline (cyclomatic 16, cognitive 22) · ×1
  • Complex function gitBaseline (cyclomatic 16, cognitive 22) editors/vscode/src/git-baseline.ts:7 — gitBaseline has cyclomatic complexity 16 and cognitive complexity 22; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes.
R2 · Cyclomatic Complexity · Complex function getTreeItem (cyclomatic 15, cognitive 12) · ×1
  • Complex function getTreeItem (cyclomatic 15, cognitive 12) editors/vscode/src/configuration-view.ts:207 — getTreeItem has cyclomatic complexity 15 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 — arms side by side rather than stacked — and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes.
R2 · Cyclomatic Complexity · Complex function differences (cyclomatic 12, cognitive 26) · ×1
  • Complex function differences (cyclomatic 12, cognitive 26) editors/vscode/src/database-files.ts:134 — differences has cyclomatic complexity 12 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 — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes.
R2 · Cyclomatic Complexity · Complex function ibcmd.refresh (cyclomatic 12, cognitive 19) · ×1
  • Complex function ibcmd.refresh (cyclomatic 12, cognitive 19) editors/vscode/src/extension.ts:652 — ibcmd.refresh 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 — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes.
R2 · Cyclomatic Complexity · Complex function (anonymous) (cyclomatic 12, cognitive 15) · ×1
  • Complex function (anonymous) (cyclomatic 12, cognitive 15) editors/vscode/src/extension.ts:369 — (anonymous) has cyclomatic complexity 12 and cognitive complexity 15; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes.
R2 · Cyclomatic Complexity · Complex function validatePlan (cyclomatic 12, cognitive 13) · ×1
  • Complex function validatePlan (cyclomatic 12, cognitive 13) editors/vscode/src/object-export.ts:143 — validatePlan 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 — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes.
R2 · Cyclomatic Complexity · Complex function contained (cyclomatic 11, cognitive 23) · ×1
  • Complex function contained (cyclomatic 11, cognitive 23) editors/vscode/src/configuration-tree.ts:298 — contained has cyclomatic complexity 11 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 — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes.
R2 · Cyclomatic Complexity · Complex function receive (cyclomatic 11, cognitive 22) · ×1
  • Complex function receive (cyclomatic 11, cognitive 22) editors/vscode/src/rpc.ts:114 — receive has cyclomatic complexity 11 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 — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes.
R2 · Cyclomatic Complexity · Complex function (anonymous) (cyclomatic 11, cognitive 19) · ×1
  • Complex function (anonymous) (cyclomatic 11, cognitive 19) editors/vscode/test/fake-server.js:13 — (anonymous) 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 — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes.
R2 · Cyclomatic Complexity · Complex function (anonymous) (cyclomatic 11, cognitive 13) · ×1
  • Complex function (anonymous) (cyclomatic 11, cognitive 13) editors/vscode/src/extension.ts:184 — (anonymous) 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 — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes.
R2 · Cyclomatic Complexity · Complex function walk (cyclomatic 11, cognitive 12) · ×1
  • Complex function walk (cyclomatic 11, cognitive 12) editors/vscode/src/configuration-tree.ts:431 — walk 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 — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes.
R2 · Cyclomatic Complexity · Complex function (anonymous) (cyclomatic 11, cognitive 12) · ×1
  • Complex function (anonymous) (cyclomatic 11, cognitive 12) editors/vscode/src/object-view.ts:271 — (anonymous) 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 — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes.
R2 · Cyclomatic Complexity · Complex function require (cyclomatic 11, cognitive 10) · ×1
  • Complex function require (cyclomatic 11, cognitive 10) editors/vscode/test/connection.test.js:154 — require has cyclomatic complexity 11 and cognitive complexity 10; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth — arms side by side rather than stacked — and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes.
R3 · Large Files · editors/vscode/src/extension.ts · ×1
  • editors/vscode/src/extension.ts: 928 lines of code editors/vscode/src/extension.ts:1 — editors/vscode/src/extension.ts has 928 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module.
R3 · Large Files · editors/vscode/src/configuration-tree.ts · ×1
  • editors/vscode/src/configuration-tree.ts: 679 lines of code editors/vscode/src/configuration-tree.ts:1 — editors/vscode/src/configuration-tree.ts has 679 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module.
R8 · Dependency Hygiene · Unused dependency '@vscode/vsce' · ×1
  • Unused dependency '@vscode/vsce' editors/vscode/package.json:342 — Declared in editors/vscode/package.json but never imported anywhere in that package or its workspace members — 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.
X18 · Disposal-pattern correctness · Explicit release owed and not made on every path · ×1
  • Explicit release owed and not made on every path crates/ibcmd-edt/src/provenance.rs:38 — `writer` (line 38) is a `BufWriter` this function owns and never releases: no `flush()` (or `into_inner()`) on any path, and it is not handed on. Rust drops it at the end of the scope, and a buffered writer that is dropped flushes and throws the error away, so a failed write reports success. Release it where the work ends.
X2 · Cancellation propagation · Async function without AbortSignal · ×1
  • Async function without AbortSignal: nativeApply editors/vscode/src/apply.ts:75 — `nativeApply` holds an AbortSignal but calls `spawn(…)` without it, so its caller's cancellation never reaches that call and it runs to its end after whatever wanted it has given up. Hand the signal on: `spawn(…, { signal })`.
Minor — 78 finding(s)
X10 · Duplicated predicate · Duplicated predicate · ×40
  • Duplicated predicate editors/vscode/src/object-export.ts:232 — `Number.isInteger(seconds) && seconds >= 30 && seconds <= 3600` appears character-identically in 2 files — editors/vscode/src/object-export.ts, editors/vscode/src/object-view.ts. It is one line, so the duplication detector's token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home.
  • Duplicated predicate scripts/edt-lab/prepare_macos.py:50 — `ancestor.exists() and ancestor.samefile(outer)` appears character-identically in 2 files — scripts/edt-lab/prepare_macos.py, scripts/edt-lab/xml_to_edt_macos.py. It is one line, so the duplication detector's token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home.
  • Duplicated predicate scripts/edt-lab/prepare_macos.py:128 — `args.run.exists() or not args.run.parent.is_dir()` appears character-identically in 2 files — scripts/edt-lab/prepare_macos.py, scripts/edt-lab/xml_to_edt_macos.py. It is one line, so the duplication detector's token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home.
  • Duplicated predicate scripts/edt-lab/prepare_macos.py:139 — `args.run.is_relative_to(args.native) or args.native.is_relative_to(args.run)` appears character-identically in 2 files — scripts/edt-lab/prepare_macos.py, scripts/edt-lab/xml_to_edt_macos.py. It is one line, so the duplication detector's token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home.
  • Duplicated predicate docs/apply/evidence/platform85/extension-baseline-preservation/header-reader-original.py:41 — `backup != BACKUP or output != OUTPUT or not backup.is_file() or output.exists()` appears character-identically in 2 files — docs/apply/evidence/platform85/extension-baseline-preservation/header-reader-original.py, docs/apply/evidence/platform85/extension-baseline-preservation/header-reader-readback.py. It is one line, so the duplication detector's token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home.
  • Duplicated predicate scripts/edt-lab/prepare_macos.py:52 — `contains(bundle, run) or contains(run, bundle)` appears character-identically in 2 files — scripts/edt-lab/prepare_macos.py, scripts/edt-lab/xml_to_edt_macos.py. It is one line, so the duplication detector's token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home.
  • Duplicated predicate _onecdec/big_compare.py:49 — `e.get('message') and e['logical_name'] not in ('root', 'version', 'versions')` appears character-identically in 2 files — _onecdec/big_compare.py, _onecdec/big_compare_v85.py. It is one line, so the duplication detector's token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home.
  • Duplicated predicate scripts/edt-lab/edt_to_xml_macos.py:56 — `edt.name != '1cedtcli' or eclipse.name != 'Eclipse' or contents.name != 'Contents' or bundle.suffix != '.app'` appears character-identically in 2 files — scripts/edt-lab/edt_to_xml_macos.py, scripts/edt-lab/prepare_macos.py. It is one line, so the duplication detector's token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home.
  • Duplicated predicate _onecdec/make_old_root_fixtures.py:42 — `i + 1 < len(text) and text[i + 1] == '"'` appears character-identically in 3 files — _onecdec/make_old_root_fixtures.py, _onecdec/make_upgrade_fixtures.py, _onecdec/upgrade_rules.py. It is one line, so the duplication detector's token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home.
  • Duplicated predicate docs/apply/evidence/live-gate/compact8-runtime-preexec/read_compact8_recovery.py:49 — `isinstance(items,list) and len(items)<=4096` appears character-identically in 3 files — docs/apply/evidence/live-gate/compact8-runtime-preexec/read_compact8_recovery.py, docs/apply/evidence/live-gate/compact9-runtime-preexec/read_compact9_recovery.py, docs/apply/evidence/live-gate/compact9-startup-preexec-v2/read_compact9_recovery.py. It is one line, so the duplication detector's token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home.
  • Duplicated predicate _onecdec/upgrade_rules.py:93 — `isinstance(old, list) and isinstance(new, list)` appears character-identically in 2 files — _onecdec/upgrade_rules.py, _onecdec/upgrade_sim.py. It is one line, so the duplication detector's token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home.
  • Duplicated predicate docs/apply/evidence/live-gate/compact8-runtime-preexec/read_compact8_recovery.py:23 — `isinstance(value,dict) and set(value)==set(keys)` appears character-identically in 3 files — docs/apply/evidence/live-gate/compact8-runtime-preexec/read_compact8_recovery.py, docs/apply/evidence/live-gate/compact9-runtime-preexec/read_compact9_recovery.py, docs/apply/evidence/live-gate/compact9-startup-preexec-v2/read_compact9_recovery.py. It is one line, so the duplication detector's token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home.
  • Duplicated predicate _onecdec/big_compare.py:66 — `l[:1] in '+-' and not l.startswith(('---', '+++'))` appears character-identically in 2 files — _onecdec/big_compare.py, _onecdec/big_compare_v85.py. It is one line, so the duplication detector's token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home.
  • Duplicated predicate docs/apply/evidence/live-gate/compact8-runtime-preexec/read_compact8_recovery.py:54 — `len(b)==r['length'] and sha(b)==r['sha256']` appears character-identically in 3 files — docs/apply/evidence/live-gate/compact8-runtime-preexec/read_compact8_recovery.py, docs/apply/evidence/live-gate/compact9-runtime-preexec/read_compact9_recovery.py, docs/apply/evidence/live-gate/compact9-startup-preexec-v2/read_compact9_recovery.py. It is one line, so the duplication detector's token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home.
  • Duplicated predicate docs/apply/evidence/live-gate/compact8-runtime-preexec/read_compact8_recovery.py:75 — `len(fields)==9 and fields[0] in ('Config','ConfigSave','Params')` appears character-identically in 3 files — docs/apply/evidence/live-gate/compact8-runtime-preexec/read_compact8_recovery.py, docs/apply/evidence/live-gate/compact9-runtime-preexec/read_compact9_recovery.py, docs/apply/evidence/live-gate/compact9-startup-preexec-v2/read_compact9_recovery.py. It is one line, so the duplication detector's token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home.
  • Duplicated predicate docs/apply/evidence/live-gate/compact8-runtime-preexec/read_compact8_recovery.py:68 — `len(pack)==p['pack_bytes'] and sha(pack)==p['pack_sha256']` appears character-identically in 3 files — docs/apply/evidence/live-gate/compact8-runtime-preexec/read_compact8_recovery.py, docs/apply/evidence/live-gate/compact9-runtime-preexec/read_compact9_recovery.py, docs/apply/evidence/live-gate/compact9-startup-preexec-v2/read_compact9_recovery.py. It is one line, so the duplication detector's token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home.
  • Duplicated predicate docs/apply/evidence/live-gate/compact8-runtime-preexec/read_compact8_recovery.py:45 — `len(pack)==q['pack_bytes'] and sha(pack)==q['pack_sha256']` appears character-identically in 3 files — docs/apply/evidence/live-gate/compact8-runtime-preexec/read_compact8_recovery.py, docs/apply/evidence/live-gate/compact9-runtime-preexec/read_compact9_recovery.py, docs/apply/evidence/live-gate/compact9-startup-preexec-v2/read_compact9_recovery.py. It is one line, so the duplication detector's token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home.
  • Duplicated predicate docs/apply/evidence/live-gate/compact8-runtime-preexec/read_compact8_recovery.py:64 — `m['format']==2 and sha(encoded(p))==m['integrity_sha256']` appears character-identically in 3 files — docs/apply/evidence/live-gate/compact8-runtime-preexec/read_compact8_recovery.py, docs/apply/evidence/live-gate/compact9-runtime-preexec/read_compact9_recovery.py, docs/apply/evidence/live-gate/compact9-startup-preexec-v2/read_compact9_recovery.py. It is one line, so the duplication detector's token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home.
  • Duplicated predicate scripts/apply-lab/module_mentions.py:17 — `not name.endswith('.xml') or name == 'ConfigDumpInfo.xml'` appears character-identically in 2 files — scripts/apply-lab/module_mentions.py, scripts/apply-lab/unused_modules.py. It is one line, so the duplication detector's token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home.
  • Duplicated predicate docs/apply/evidence/live-gate/compact8-runtime-preexec/make_compact8_negatives.py:7 — `not p.is_absolute() or not p.resolve().is_relative_to(root.resolve())` appears character-identically in 3 files — docs/apply/evidence/live-gate/compact8-runtime-preexec/make_compact8_negatives.py, docs/apply/evidence/live-gate/compact9-runtime-preexec/make_compact9_negatives.py, docs/apply/evidence/live-gate/compact9-startup-preexec-v2/make_compact9_negatives.py. It is one line, so the duplication detector's token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home.
  • Duplicated predicate scripts/edt-lab/prepare_macos.py:146 — `not tool.is_file() or not os.access(tool, os.X_OK)` appears character-identically in 2 files — scripts/edt-lab/prepare_macos.py, scripts/edt-lab/xml_to_edt_macos.py. It is one line, so the duplication detector's token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home.
  • Duplicated predicate _onecdec/big_compare.py:51 — `p in ours and open(nat[p], 'rb').read() == open(ours[p], 'rb').read()` appears character-identically in 5 files — _onecdec/big_compare.py, _onecdec/big_compare_v85.py, _onecdec/corpus_compare.py, _onecdec/regress_compare.py. It is one line, so the duplication detector's token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home.
  • Duplicated predicate docs/apply/evidence/live-gate/compact8-runtime-preexec/read_compact8_recovery.py:70 — `p['database']==l['identity']['database'] and p['mode']=='live'` appears character-identically in 3 files — docs/apply/evidence/live-gate/compact8-runtime-preexec/read_compact8_recovery.py, docs/apply/evidence/live-gate/compact9-runtime-preexec/read_compact9_recovery.py, docs/apply/evidence/live-gate/compact9-startup-preexec-v2/read_compact9_recovery.py. It is one line, so the duplication detector's token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home.
  • Duplicated predicate docs/apply/evidence/live-gate/compact8-runtime-preexec/read_compact8_recovery.py:93 — `p['old_generation']==l['recovery']['old_generation'] and p['new_generation']==l['recovery']['new_generation']` appears character-identically in 3 files — docs/apply/evidence/live-gate/compact8-runtime-preexec/read_compact8_recovery.py, docs/apply/evidence/live-gate/compact9-runtime-preexec/read_compact9_recovery.py, docs/apply/evidence/live-gate/compact9-startup-preexec-v2/read_compact9_recovery.py. It is one line, so the duplication detector's token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home.
  • Duplicated predicate docs/apply/evidence/live-gate/compact8-runtime-preexec/read_compact8_recovery.py:29 — `p['sql_engine_version']=='17.0.1135.8' and p['verified_platform_profile']=='platform-8.3.27.2214'` appears character-identically in 3 files — docs/apply/evidence/live-gate/compact8-runtime-preexec/read_compact8_recovery.py, docs/apply/evidence/live-gate/compact9-runtime-preexec/read_compact9_recovery.py, docs/apply/evidence/live-gate/compact9-startup-preexec-v2/read_compact9_recovery.py. It is one line, so the duplication detector's token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home.
  • + 15 more in this group — see findings.md.
X7 · Silent fallback defaults · Silent fallback default on Err · ×12
  • Silent fallback default on Err crates/ibcmd-edt/vendor/morph1c/crates/pipeline/src/language_read.rs:170 — `language_sidecars_on_disk` turns every `Err` into `Vec::new()` — a failure becomes a plausible value and a silent behavior change with no trail. Log the error or propagate it with `?`. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the arm or in the doc comment, and the row stops firing.
  • Silent fallback default on Err crates/ibcmd-edt/vendor/morph1c/crates/pipeline/src/preflight.rs:387 — `count_descriptors` turns every `Err` into `0` — a failure becomes a plausible value and a silent behavior change with no trail. Log the error or propagate it with `?`. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the arm or in the doc comment, and the row stops firing.
  • Silent fallback default on Err crates/ibcmd-form-body/src/form_body.rs:4326 — `extract_form_item_assets` turns every `Err` into `Vec::new()` — a failure becomes a plausible value and a silent behavior change with no trail. Log the error or propagate it with `?`. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the arm or in the doc comment, and the row stops firing.
  • Silent fallback default on Err crates/ibcmd-metadata-model/src/metadata_model/attribute.rs:395 — `measure` turns every `Err` into `Ok(Vec::new())` — a failure becomes a plausible value and a silent behavior change with no trail. Log the error or propagate it with `?`. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the arm or in the doc comment, and the row stops firing.
  • Silent fallback default on Err crates/ibcmd-metadata-model/src/metadata_model/common.rs:403 — `compatibility_at_least_8_5` turns every `Err` into `0` — a failure becomes a plausible value and a silent behavior change with no trail. Log the error or propagate it with `?`. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the arm or in the doc comment, and the row stops firing.
  • Silent fallback default on Err crates/ibcmd-metadata-model/src/metadata_model/types.rs:751 — `measure_object` turns every `Err` into `Ok(Vec::new())` — a failure becomes a plausible value and a silent behavior change with no trail. Log the error or propagate it with `?`. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the arm or in the doc comment, and the row stops firing.
  • Silent fallback default on Err crates/ibcmd-xml/src/dcs.rs:6406 — `form_server_state_nil_parameter_names` turns every `Err` into `std::collections::BTreeSet::new()` — a failure becomes a plausible value and a silent behavior change with no trail. Log the error or propagate it with `?`. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the arm or in the doc comment, and the row stops firing.
  • Silent fallback default on Err src/dump_sources.rs:628 — `version_key` turns every `Err` into `0` — a failure becomes a plausible value and a silent behavior change with no trail. Log the error or propagate it with `?`. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the arm or in the doc comment, and the row stops firing.
  • Silent fallback default on Err src/load.rs:471 — `config_versions` turns every `Err` into `BTreeMap::new()` — a failure becomes a plausible value and a silent behavior change with no trail. Log the error or propagate it with `?`. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the arm or in the doc comment, and the row stops firing.
  • Silent fallback default on Err src/load/index.rs:164 — `file_versions` turns every `Err` into `BTreeMap::new()` — a failure becomes a plausible value and a silent behavior change with no trail. Log the error or propagate it with `?`. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the arm or in the doc comment, and the row stops firing.
  • Silent fallback default on Err src/mssql/stage_timing.rs:127 — `report` turns every `Err` into `String::new()` — a failure becomes a plausible value and a silent behavior change with no trail. Log the error or propagate it with `?`. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the arm or in the doc comment, and the row stops firing.
  • Silent fallback default on Err src/source_listing.rs:102 — `walk_folder` turns every `Err` into `WalkPart::default()` — a failure becomes a plausible value and a silent behavior change with no trail. Log the error or propagate it with `?`. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the arm or in the doc comment, and the row stops firing.
D26 · Project Cohesion · Projects may be oversized for their cohesion · ×8
  • Projects may be oversized for their cohesion Cargo.toml:1 — `(repository root)` (128453 LoC, 769 module-visible types across 43 directories) overshoots its size bounds. 8 of 39 build unit(s) (Cargo, npm) overshoot their size bounds, lowering Project Cohesion to 6.0/10. Review these for cohesion — draw the boundary inside the module first (group each responsibility into its own package or directory and keep the cross-boundary members non-public), since splitting a published package moves types between packages and breaks consumers.
  • Projects may be oversized for their cohesion crates/ibcmd-xml/Cargo.toml:1 — `crates/ibcmd-xml` (46489 LoC, 136 module-visible types across 4 directories) overshoots its size bounds. 8 of 39 build unit(s) (Cargo, npm) overshoot their size bounds, lowering Project Cohesion to 6.0/10. Review these for cohesion — draw the boundary inside the module first (group each responsibility into its own package or directory and keep the cross-boundary members non-public), since splitting a published package moves types between packages and breaks consumers.
  • Projects may be oversized for their cohesion crates/ibcmd-edt/Cargo.toml:1 — `crates/ibcmd-edt` (5594 LoC, 891 module-visible types across 25 directories) overshoots its size bounds. 8 of 39 build unit(s) (Cargo, npm) overshoot their size bounds, lowering Project Cohesion to 6.0/10. Review these for cohesion — draw the boundary inside the module first (group each responsibility into its own package or directory and keep the cross-boundary members non-public), since splitting a published package moves types between packages and breaks consumers.
  • Projects may be oversized for their cohesion crates/ibcmd-compiler-families/Cargo.toml:1 — `crates/ibcmd-compiler-families` (31543 LoC, 163 module-visible types across 5 directories) overshoots its size bounds. 8 of 39 build unit(s) (Cargo, npm) overshoot their size bounds, lowering Project Cohesion to 6.0/10. Review these for cohesion — draw the boundary inside the module first (group each responsibility into its own package or directory and keep the cross-boundary members non-public), since splitting a published package moves types between packages and breaks consumers.
  • Projects may be oversized for their cohesion crates/ibcmd-core/Cargo.toml:1 — `crates/ibcmd-core` (26682 LoC, 264 module-visible types across 2 directories) overshoots its size bounds. 8 of 39 build unit(s) (Cargo, npm) overshoot their size bounds, lowering Project Cohesion to 6.0/10. Review these for cohesion — draw the boundary inside the module first (group each responsibility into its own package or directory and keep the cross-boundary members non-public), since splitting a published package moves types between packages and breaks consumers.
  • Projects may be oversized for their cohesion crates/ibcmd-schema/Cargo.toml:1 — `crates/ibcmd-schema` (19700 LoC, 150 module-visible types across 1 directories) overshoots its size bounds. 8 of 39 build unit(s) (Cargo, npm) overshoot their size bounds, lowering Project Cohesion to 6.0/10. Review these for cohesion — draw the boundary inside the module first (group each responsibility into its own package or directory and keep the cross-boundary members non-public), since splitting a published package moves types between packages and breaks consumers.
  • Projects may be oversized for their cohesion crates/ibcmd-restructure-engine/Cargo.toml:1 — `crates/ibcmd-restructure-engine` (19193 LoC, 142 module-visible types across 3 directories) overshoots its size bounds. 8 of 39 build unit(s) (Cargo, npm) overshoot their size bounds, lowering Project Cohesion to 6.0/10. Review these for cohesion — draw the boundary inside the module first (group each responsibility into its own package or directory and keep the cross-boundary members non-public), since splitting a published package moves types between packages and breaks consumers.
  • Projects may be oversized for their cohesion crates/ibcmd-form-schema/Cargo.toml:1 — `crates/ibcmd-form-schema` (9406 LoC, 122 module-visible types across 1 directories) overshoots its size bounds. 8 of 39 build unit(s) (Cargo, npm) overshoot their size bounds, lowering Project Cohesion to 6.0/10. Review these for cohesion — draw the boundary inside the module first (group each responsibility into its own package or directory and keep the cross-boundary members non-public), since splitting a published package moves types between packages and breaks consumers.
X9 · Subsumed condition operand · Subsumed condition operand · ×6
  • Subsumed condition operand src/storage_map.rs:467 — `sample_lower.contains("file_name = n'module'")` can never decide this `||` — every value satisfying `sample_lower.contains("file_name = n'module'")` also satisfies `sample_lower.contains("n'module'")`, so the `||` chain is already decided by the latter. The expression is equivalent to the chain without it, which means it is wider than it reads. Delete the dead operand, or narrow the surviving one if IT is the accident.
  • Subsumed condition operand src/storage_map.rs:470 — `sample_lower.contains("file_name = n'metadata'")` can never decide this `||` — every value satisfying `sample_lower.contains("file_name = n'metadata'")` also satisfies `sample_lower.contains("n'metadata'")`, so the `||` chain is already decided by the latter. The expression is equivalent to the chain without it, which means it is wider than it reads. Delete the dead operand, or narrow the surviving one if IT is the accident.
  • Subsumed condition operand src/storage_map.rs:531 — `sample_lower.contains("file_name = n'module'")` can never decide this `||` — every value satisfying `sample_lower.contains("file_name = n'module'")` also satisfies `sample_lower.contains("n'module'")`, so the `||` chain is already decided by the latter. The expression is equivalent to the chain without it, which means it is wider than it reads. Delete the dead operand, or narrow the surviving one if IT is the accident.
  • Subsumed condition operand src/storage_map.rs:534 — `sample_lower.contains("file_name = n'metadata'")` can never decide this `||` — every value satisfying `sample_lower.contains("file_name = n'metadata'")` also satisfies `sample_lower.contains("n'metadata'")`, so the `||` chain is already decided by the latter. The expression is equivalent to the chain without it, which means it is wider than it reads. Delete the dead operand, or narrow the surviving one if IT is the accident.
  • Subsumed condition operand src/storage_map.rs:584 — `sample_lower.contains("file_name = n'module'")` can never decide this `||` — every value satisfying `sample_lower.contains("file_name = n'module'")` also satisfies `sample_lower.contains("n'module'")`, so the `||` chain is already decided by the latter. The expression is equivalent to the chain without it, which means it is wider than it reads. Delete the dead operand, or narrow the surviving one if IT is the accident.
  • Subsumed condition operand src/storage_map.rs:587 — `sample_lower.contains("file_name = n'metadata'")` can never decide this `||` — every value satisfying `sample_lower.contains("file_name = n'metadata'")` also satisfies `sample_lower.contains("n'metadata'")`, so the `||` chain is already decided by the latter. The expression is equivalent to the chain without it, which means it is wider than it reads. Delete the dead operand, or narrow the surviving one if IT is the accident.
X7 · Silent fallback defaults · Silent fallback default on parse failure · ×2
  • Silent fallback default on parse failure scripts/apply-trace/compare_traces.py:49 — `to_int` returns `0` when `(TypeError, ValueError)` is raised, with no log or raise — a malformed value silently becomes that default. Log the input or fail validation. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing.
  • Silent fallback default on parse failure scripts/restructure-lab/s1k/assemble_checkpoint2.py:40 — `load_json` returns `{}` when `ValueError` is raised, with no log or raise — a malformed value silently becomes that default. Log the input or fail validation. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing.
C3 · Audit Trail · Partial audit-trail evidence · ×1
  • Partial audit-trail evidence — An audit mechanism is present, but the trail is not yet complete — missing: a write-side hook every change flows through (a SeaORM ActiveModelBehavior hook or a database trigger recording each change, or an event-sourced store), per-entity coverage (an event-sourced aggregate, or a hook on each entity that needs a who-changed-what trail).
C4 · Data Retention · Partial data-retention evidence · ×1
  • Partial data-retention evidence — A retention mechanism is present, but the data-lifecycle is not yet complete — missing: a scheduled purge / cleanup job (a scheduled task that deletes rows past their retention — diesel::delete(….filter(created_at.lt(cutoff))), purge_expired… / delete_old…), a documented retention period / data-expiry.
D20 · ADR Quality · No ADRs found · ×1
  • No ADRs found src/main.rs:1 — No ADRs found. No recognised ADR directory (`docs/adr/`, `docs/decisions/`, `adr/`, `docs/rfcs/`, an `ADR0001/` 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 (`docs/adr/use-postgres.md`, `docs/adr/2024/0001-x.md`); or a file anywhere whose name is ADR-shaped (`0001-use-postgres.md`, `adr-012-caching.md`); or, when neither turned anything up, a document carrying the decision-record signature (an "Architecture Decision Record" heading, or Status / Context / Decision / Consequences as section headings). A decision log that clears none of these — unnumbered files outside any recognised directory, without those headings — 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 `docs/adr/`. ADRs are expected here because `src/main.rs` makes this repository a deployable product (line 1).
D28 · Secrets (history) · Rotate the exposed credentials · ×1
  • REDACTED
D36 · Supply-chain Provenance & Signing · REDACTED · ×1
  • REDACTED
D36 · Supply-chain Provenance & Signing · REDACTED · ×1
  • REDACTED
D36 · Supply-chain Provenance & Signing · REDACTED · ×1
  • REDACTED
M2 · Architecture documentation · No ADRs · ×1
  • No ADRs — No Architecture Decision Records found — no conventional ADR directory, no numbered `NNNN-title` documents in any markup this check reads, and nothing ADR-shaped by content. Design rationale recorded elsewhere (a design-notes tree, a mailing list, pull-request discussion) is not visible to this check and is not re-findable per decision, so a future maintainer cannot ask why one choice was made and get an answer.
P3 · Security & performance tooling · No dependency-update automation · ×1
  • No dependency-update automation editors/vscode/package.json:332 — `editors/vscode/package.json` declares packages, and nothing in the repository keeps them current: no Dependabot or Renovate configuration that schedules updates, and no dependency-review gate on pull requests. A pinned dependency stays at the version it was added at until someone notices — including after an advisory is published against it. Add a `.github/dependabot.yml` with one `package-ecosystem` entry per ecosystem the tree uses (or an enabled `renovate.json`), and gate pull requests with `actions/dependency-review-action`.
X2 · Cancellation propagation · Not all async functions that make a request accept an AbortSignal · ×1
  • Not all async functions that make a request accept an AbortSignal — Only 4/5 async functions that make a cancellable request (fetch, axios, ky, ofetch, got, undici, node:http) accept an AbortSignal or pass one on, so a request keeps running after whatever wanted it has given up — a page navigated away from, an unmounted component, a timed-out job. Take a `signal` (or an options object that carries one) and hand it to the request; where nothing could ever cancel the call, omitting it is a deliberate choice — judge against how the function is used.
Minor — 14 finding(s)
D12 · Dependency Hygiene · Outdated · ×12
  • Outdated: anyhow — `anyhow` is locked at 1.0.102 but 1.0.104 is the current stable release on crates.io, and it already satisfies the `"1.0"` requirement declared in Cargo.toml — so the lockfile is behind this repository's own declared range. Run `cargo update -p anyhow` and commit the updated REDACTED.
  • Outdated: clap — `clap` is locked at 4.6.1 but 4.6.7 is the current stable release on crates.io, and it already satisfies the `"4.5"` requirement declared in Cargo.toml — so the lockfile is behind this repository's own declared range. Run `cargo update -p clap` and commit the updated REDACTED.
  • Outdated: flate2 — `flate2` is locked at 1.1.9 but 1.1.11 is the current stable release on crates.io, and it already satisfies the `"1.1"` requirement declared in Cargo.toml — so the lockfile is behind this repository's own declared range. Run `cargo update -p flate2` and commit the updated REDACTED.
  • Outdated: futures-util — `futures-util` is locked at 0.3.32 but 0.3.34 is the current stable release on crates.io, and it already satisfies the `"0.3"` requirement declared in crates/ibcmd-sql/Cargo.toml — so the lockfile is behind this repository's own declared range. Run `cargo update -p futures-util` and commit the updated REDACTED.
  • Outdated: libc — `libc` is locked at 0.2.186 but 0.2.191 is the current stable release on crates.io, and it already satisfies the `"0.2"` requirement declared in crates/ibcmd-filedb/Cargo.toml — so the lockfile is behind this repository's own declared range. Run `cargo update -p libc` and commit the updated REDACTED.
  • Outdated: rustix — `rustix` is locked at 1.1.5 but 1.1.6 is the current stable release on crates.io, and it already satisfies the `"1.1.5"` requirement declared in Cargo.toml — so the lockfile is behind this repository's own declared range. Run `cargo update -p rustix` and commit the updated REDACTED.
  • Outdated: serde — `serde` is locked at 1.0.228 but 1.0.229 is the current stable release on crates.io, and it already satisfies the `"1.0"` requirement declared in Cargo.toml — so the lockfile is behind this repository's own declared range. Run `cargo update -p serde` and commit the updated REDACTED.
  • Outdated: serde_json — `serde_json` is locked at 1.0.150 but 1.0.154 is the current stable release on crates.io, and it already satisfies the `"1.0"` requirement declared in Cargo.toml — so the lockfile is behind this repository's own declared range. Run `cargo update -p serde_json` and commit the updated REDACTED.
  • Outdated: tokio — `tokio` is locked at 1.53.1 but 1.54.1 is the current stable release on crates.io, and it already satisfies the `"1"` requirement declared in Cargo.toml — so the lockfile is behind this repository's own declared range. Run `cargo update -p tokio` and commit the updated REDACTED.
  • Outdated: tokio-util — `tokio-util` is locked at 0.7.19 but 0.7.20 is the current stable release on crates.io, and it already satisfies the `"0.7"` requirement declared in crates/ibcmd-sql/Cargo.toml — so the lockfile is behind this repository's own declared range. Run `cargo update -p tokio-util` and commit the updated REDACTED.
  • Outdated: toml — `toml` is locked at 1.1.6+spec-1.1.0 but 1.2.1+spec-1.1.0 is the current stable release on crates.io, and it already satisfies the `"1.1"` requirement declared in Cargo.toml — so the lockfile is behind this repository's own declared range. Run `cargo update -p toml` and commit the updated REDACTED.
  • Outdated: uuid — `uuid` is locked at 1.23.4 but 1.29.2 is the current stable release on crates.io, and it already satisfies the `"1.19"` requirement declared in Cargo.toml — so the lockfile is behind this repository's own declared range. Run `cargo update -p uuid` and commit the updated REDACTED.
D10 · Test Quality · Skipped (documented) · ×2
  • Skipped (documented): dirty casing aliases are refused on case insensitive source filesystems editors/vscode/test/export.test.js:296 — Skipped with a documented reason — a deferral, not lazy debt: skipped at run time by a this.skip()/t.skip() call
  • Skipped (documented): Git warnings recognize affected casing aliases on insensitive filesystems editors/vscode/test/export.test.js:320 — Skipped with a documented reason — a deferral, not lazy debt: skipped at run time by a this.skip()/t.skip() call

Appendix B — Reproduction & audit trail

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

DimensionToolVersionCommandFindingsRaw output
D28 · Secrets (history)gitleaks—gitleaks detect --no-banner --config /opt/gitleaks-rules/canine-gitleaks.toml --log-opts "--full-history --all --skip=0 --max-count=200" --report-format json --report-path /tmp/watchdog-gitleaks-d3ac8cf8422d4db59608ea1761586354/history.json --exit-code 0 --source .0artifacts/raw/gitleaks-history.json
D28 · Secrets (history)gitleaks—gitleaks detect --no-banner --config /opt/gitleaks-rules/canine-gitleaks.toml --log-opts "--full-history --all --skip=200 --max-count=142" --report-format json --report-path /tmp/watchdog-gitleaks-d3ac8cf8422d4db59608ea1761586354/history-1.json --exit-code 0 --source .0artifacts/raw/gitleaks-history-1.json
D28 · Secrets (history)gitleaks—gitleaks detect --no-banner --config /opt/gitleaks-rules/canine-gitleaks.toml --log-opts "--full-history --all --skip=342 --max-count=185" --report-format json --report-path /tmp/watchdog-gitleaks-d3ac8cf8422d4db59608ea1761586354/history-2.json --exit-code 0 --source .0artifacts/raw/gitleaks-history-2.json
D28 · Secrets (history)gitleaks—gitleaks detect --no-banner --config /opt/gitleaks-rules/canine-gitleaks.toml --log-opts "--full-history --all --skip=527 --max-count=273" --report-format json --report-path /tmp/watchdog-gitleaks-d3ac8cf8422d4db59608ea1761586354/history-3.json --exit-code 0 --source .1artifacts/raw/gitleaks-history-3.json
D28 · Secrets (history)gitleaks—gitleaks detect --no-banner --config /opt/gitleaks-rules/canine-gitleaks.toml --log-opts "--full-history --all --skip=800 --max-count=361" --report-format json --report-path /tmp/watchdog-gitleaks-d3ac8cf8422d4db59608ea1761586354/history-4.json --exit-code 0 --source .1artifacts/raw/gitleaks-history-4.json
D28 · Secrets (history)gitleaks—gitleaks detect --no-banner --config /opt/gitleaks-rules/canine-gitleaks.toml --log-opts "--full-history --all --skip=1161 --max-count=480" --report-format json --report-path /tmp/watchdog-gitleaks-d3ac8cf8422d4db59608ea1761586354/history-5.json --exit-code 0 --source .3artifacts/raw/gitleaks-history-5.json
D28 · Secrets (history)gitleaks—gitleaks detect --no-banner --config /opt/gitleaks-rules/canine-gitleaks.toml --log-opts "--full-history --all --skip=1641 --max-count=551" --report-format json --report-path /tmp/watchdog-gitleaks-d3ac8cf8422d4db59608ea1761586354/history-6.json --exit-code 0 --source .0artifacts/raw/gitleaks-history-6.json
D28 · Secrets (history)gitleaks—gitleaks detect --no-banner --config /opt/gitleaks-rules/canine-gitleaks.toml --log-opts "--full-history --all --skip=2192 --max-count=681" --report-format json --report-path /tmp/watchdog-gitleaks-d3ac8cf8422d4db59608ea1761586354/history-7.json --exit-code 0 --source .0artifacts/raw/gitleaks-history-7.json
D28 · Secrets (history)gitleaks—gitleaks detect --no-banner --config /opt/gitleaks-rules/canine-gitleaks.toml --log-opts "--full-history --all --skip=2873 --max-count=825" --report-format json --report-path /tmp/watchdog-gitleaks-d3ac8cf8422d4db59608ea1761586354/history-8.json --exit-code 0 --source .0artifacts/raw/gitleaks-history-8.json
D28 · Secrets (history)gitleaks—gitleaks detect --no-banner --config /opt/gitleaks-rules/canine-gitleaks.toml --log-opts "--full-history --all --skip=3698 --max-count=827" --report-format json --report-path /tmp/watchdog-gitleaks-d3ac8cf8422d4db59608ea1761586354/history-9.json --exit-code 0 --source .0artifacts/raw/gitleaks-history-9.json
D28 · Secrets (history)gitleaks—gitleaks detect --no-banner --config /opt/gitleaks-rules/canine-gitleaks.toml --log-opts "--full-history --all --skip=4525 --max-count=94" --report-format json --report-path /tmp/watchdog-gitleaks-d3ac8cf8422d4db59608ea1761586354/history-10.json --exit-code 0 --source .0artifacts/raw/gitleaks-history-10.json
D28 · Secrets (history)gitleaks—gitleaks detect --no-git --no-banner --config /opt/gitleaks-rules/canine-gitleaks.toml --report-format json --report-path /tmp/watchdog-gitleaks-d3ac8cf8422d4db59608ea1761586354/tree.json --exit-code 0 --source .5artifacts/raw/gitleaks-tree.json
D29 · Static Analysis (SAST)semgrep—semgrep --config /opt/semgrep-rules/security-audit.yml --config /opt/semgrep-rules/owasp-top-ten.yml --config /opt/semgrep-rules/canine-sast.yml --json --quiet --timeout 10 --timeout-threshold 3 --metrics off --exclude *.arrow --exclude *.avro --exclude *.csv --exclude *.dat --exclude *.db --exclude *.feather --exclude *.geojson --exclude *.h5 --exclude *.hdf5 --exclude *.jsonl --exclude *.log --exclude *.ndjson --exclude *.npy --exclude *.npz --exclude *.orc --exclude *.parquet --exclude *.pickle --exclude *.pkl --exclude *.psv --exclude *.sqlite --exclude *.sqlite3 --exclude *.tfrecord --exclude *.tsv --exclude *.txt .104artifacts/raw/semgrep.json
D30 · Dependency Vulnerabilitiestrivy—trivy fs --scanners vuln --format json --quiet --severity CRITICAL,HIGH,MEDIUM,LOW --skip-dirs **/bin/** --skip-dirs **/obj/** .12artifacts/raw/trivy-fs.json
D31 · IaC & Container Securitytrivy—trivy: not applicable — No Infrastructure-as-Code or container manifests found (Dockerfile, Docker Compose, Terraform, Kubernetes/Helm, CloudFormation, ARM, Bicep, Ansible); nothing to scan.0—
D32 · Data Compliance (PII/GDPR)semgrep—semgrep: not applicable — No personal data was found crossing a boundary the PII/GDPR ruleset checks — nothing written to a log or console sink, placed in a URL or query string, or persisted to browser storage. That is a clean result for the LEAK surface only: this ruleset detects personal data escaping, it does not inventory the personal data a repository holds, so it is not evidence that this repository has no personal-data surface. The personal-data map (Appendix C) and the C1-C5 compliance cards are what speak to that.0—
D37 · Vulnerability-disclosure Policydisclosure—disclosure: not applicable — No vulnerability-disclosure policy file found (SECURITY.md/.markdown/.rst/.txt at root or under .github/.forgejo/.gitea/docs, .well-known/security.txt). A coordinated-disclosure policy may live off-repo, so this is not evidenced rather than failed.0—
D40 · Network Egress Confinementruntime-hardening—runtime-hardening: not applicable — No Kubernetes/orchestration workloads found in the repository manifests; network egress policy is a cluster-native control that may live at the platform/firewall layer, so there is nothing to assess here.0—
D41 · Kernel & Syscall Confinementruntime-hardening—runtime-hardening: not applicable — No Kubernetes/orchestration workloads found in the repository manifests; seccomp/AppArmor/SELinux confinement is a workload-level control, so there is nothing to assess here.0—
D42 · Runtime Threat Enforcementruntime-hardening—runtime-hardening: not applicable — No Kubernetes/orchestration workloads found in the repository manifests; runtime threat-detection and admission-control policy are cluster-level controls, so there is nothing to assess here.0—
D43 · Malicious Dependenciestrivy—trivy fs --scanners vuln --format json --quiet --severity CRITICAL,HIGH,MEDIUM,LOW --skip-dirs **/bin/** --skip-dirs **/obj/** .0artifacts/raw/trivy-fs.json

Run 01a1e596-7597-7557-be1e-276258e6724d · every finding is also locatable in findings.md, and the complete scoring record (with exit codes + durations) in sidecar.json.

Downloadable artifacts

Machine-readable and reproducible from this commit + frozen rubric — drop them straight into a contract appendix, a CRA dossier, or a downstream SCA / VEX tool.

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