fallow 3.34.1 → 3.36.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -149,6 +149,11 @@ export type ElapsedMs = number
149
149
  * Value of `audit.gate`: which findings drive the `fallow audit` verdict.
150
150
  */
151
151
  export type AuditGate = ("new-only" | "all")
152
+ /**
153
+ * Value of `audit.worsened`: how a worsened complexity finding affects the
154
+ * `fallow audit` verdict.
155
+ */
156
+ export type AuditWorsened = ("warn" | "error" | "off")
152
157
  /**
153
158
  * What a gate concluded on this run.
154
159
  *
@@ -159,6 +164,10 @@ export type AuditGate = ("new-only" | "all")
159
164
  * is decided here.
160
165
  */
161
166
  export type GateStatus = ("pass" | "warn" | "fail" | "skipped")
167
+ /**
168
+ * Why a file counts for the `parse-error` gate, other than a parser error.
169
+ */
170
+ export type GateFileReason = "nesting-too-deep"
162
171
  /**
163
172
  * Analysis mode stored with baselines, snapshots, audit sides, and impact data.
164
173
  */
@@ -406,6 +415,7 @@ export type PolicyViolationSeverity = ("error" | "warn")
406
415
  * The origin of a stale suppression: inline comment or JSDoc tag.
407
416
  */
408
417
  export type SuppressionOrigin = ({
418
+ type: "comment"
409
419
  /**
410
420
  * The issue kind token from the comment (e.g., "unused-exports"), or None for blanket.
411
421
  */
@@ -427,8 +437,8 @@ is_file_level: boolean
427
437
  * adopted the field stay byte-compatible. See issue #449.
428
438
  */
429
439
  kind_known?: boolean
430
- type: "comment"
431
440
  } | {
441
+ type: "jsdoc_tag"
432
442
  /**
433
443
  * The name of the export that was tagged.
434
444
  */
@@ -437,7 +447,6 @@ export_name: string
437
447
  * Human-authored reason after `--`, when present.
438
448
  */
439
449
  reason?: (string | null)
440
- type: "jsdoc_tag"
441
450
  })
442
451
  /**
443
452
  * Where an override entry was declared. Serialized as the filename label
@@ -559,58 +568,67 @@ degrades_analysis?: boolean
559
568
  export type WorkspaceDiagnostic1 = ({
560
569
  kind: "undeclared-workspace"
561
570
  } | {
571
+ kind: "malformed-package-json"
562
572
  /**
563
573
  * `serde_json` parse error text.
564
574
  */
565
575
  error: string
566
- kind: "malformed-package-json"
567
576
  } | {
577
+ kind: "glob-matched-no-package-json"
568
578
  /**
569
579
  * The glob pattern that matched the directory.
570
580
  */
571
581
  pattern: string
572
- kind: "glob-matched-no-package-json"
573
582
  } | {
583
+ kind: "workspace-glob-outside-root"
574
584
  /**
575
585
  * The workspace entry, as written in the file.
576
586
  */
577
587
  pattern: string
578
- kind: "workspace-glob-outside-root"
579
588
  } | {
589
+ kind: "workspace-pattern-dir-missing"
590
+ /**
591
+ * The workspace pattern, as written in the file.
592
+ */
593
+ pattern: string
594
+ } | {
595
+ kind: "nested-project-root"
596
+ } | {
597
+ kind: "malformed-tsconfig"
580
598
  /**
581
599
  * JSONC parse error text.
582
600
  */
583
601
  error: string
584
- kind: "malformed-tsconfig"
585
602
  } | {
586
603
  kind: "tsconfig-reference-dir-missing"
587
604
  } | {
605
+ kind: "malformed-pnpm-workspace-yaml"
588
606
  /**
589
607
  * YAML parse error text.
590
608
  */
591
609
  error: string
592
- kind: "malformed-pnpm-workspace-yaml"
593
610
  } | {
611
+ kind: "skipped-large-file"
594
612
  /**
595
613
  * On-disk size of the skipped file in bytes.
596
614
  */
597
615
  size_bytes: number
598
- kind: "skipped-large-file"
599
616
  } | {
617
+ kind: "skipped-minified-file"
600
618
  /**
601
619
  * On-disk size of the skipped file in bytes.
602
620
  */
603
621
  size_bytes: number
604
- kind: "skipped-minified-file"
605
622
  } | {
606
623
  kind: "skipped-source-dotdir"
607
624
  } | {
625
+ kind: "source-read-failure"
608
626
  /**
609
627
  * Filesystem or UTF-8 decoding error from `read_to_string`.
610
628
  */
611
629
  error: string
612
- kind: "source-read-failure"
613
630
  } | {
631
+ kind: "source-parse-degraded"
614
632
  /**
615
633
  * Number of parser diagnostics reported for the file.
616
634
  */
@@ -620,7 +638,12 @@ error_count: number
620
638
  * the extracted module is a fragment at best.
621
639
  */
622
640
  panicked: boolean
623
- kind: "source-parse-degraded"
641
+ } | {
642
+ kind: "source-nesting-too-deep"
643
+ /**
644
+ * The bracket nesting cap of the pre-parse scan.
645
+ */
646
+ limit: number
624
647
  } | {
625
648
  kind: "bun-lockb-override-resolution-skipped"
626
649
  } | {
@@ -632,8 +655,8 @@ kind: "npm-lock-override-resolution-skipped"
632
655
  } | {
633
656
  kind: "bun-resolutions-shadowed-by-overrides"
634
657
  } | {
635
- cause: PnpmWorkspaceOverridesIgnoredCause
636
658
  kind: "pnpm-workspace-overrides-ignored"
659
+ cause: PnpmWorkspaceOverridesIgnoredCause
637
660
  } | {
638
661
  kind: "node-modules-missing"
639
662
  } | {
@@ -641,6 +664,7 @@ kind: "boundaries-not-configured"
641
664
  } | {
642
665
  kind: "rule-packs-not-configured"
643
666
  } | {
667
+ kind: "excluded-by-default-ignore"
644
668
  /**
645
669
  * The built-in glob that matched, verbatim (for example
646
670
  * `** /build/**`).
@@ -664,22 +688,22 @@ file_count: number
664
688
  * one matched location out of several.
665
689
  */
666
690
  directory_count: number
667
- kind: "excluded-by-default-ignore"
668
691
  } | {
692
+ kind: "no-source-files-analyzed"
669
693
  /**
670
694
  * Candidate source files the built-in ignore patterns removed from
671
695
  * this walk, summed across every pattern. `0` when the walk found no
672
696
  * candidate to exclude in the first place.
673
697
  */
674
698
  excluded_file_count: number
675
- kind: "no-source-files-analyzed"
676
699
  } | {
700
+ kind: "file-scores-unavailable"
677
701
  /**
678
702
  * Scoring error text.
679
703
  */
680
704
  error: string
681
- kind: "file-scores-unavailable"
682
705
  } | {
706
+ kind: "hotspots-skipped"
683
707
  /**
684
708
  * Which input stopped it, as a kebab-case token: `not-a-repository`,
685
709
  * `no-commits`, `invalid-since` or `churn-file-unreadable`. The set is
@@ -693,25 +717,25 @@ kind: "file-scores-unavailable"
693
717
  * remedy for all four.
694
718
  */
695
719
  cause: string
696
- kind: "hotspots-skipped"
697
720
  } | {
721
+ kind: "change-coupling-skipped"
698
722
  /**
699
723
  * Kebab-case token: `shallow-clone` (the fetched history is
700
724
  * incomplete) or `too-few-commits` (fewer analyzed commits than the
701
725
  * minimum revisions of one file). The set is open.
702
726
  */
703
727
  cause: string
704
- kind: "change-coupling-skipped"
705
728
  } | {
729
+ kind: "shallow-clone"
706
730
  /**
707
731
  * `true` when the run also asked for ownership attribution, which a
708
732
  * shallow clone skews further by inflating single-author dominance.
709
733
  */
710
734
  ownership_requested: boolean
711
- kind: "shallow-clone"
712
735
  } | {
713
736
  kind: "unpinned-clock"
714
737
  } | {
738
+ kind: "ownership-unavailable"
715
739
  /**
716
740
  * Which input failed, as a kebab-case token: `invalid-bot-pattern` or
717
741
  * `codeowners-parse-failed`. The set is open.
@@ -721,21 +745,21 @@ cause: string
721
745
  * Underlying error text.
722
746
  */
723
747
  error: string
724
- kind: "ownership-unavailable"
725
748
  } | {
749
+ kind: "trend-snapshot-unreadable"
726
750
  /**
727
751
  * Filesystem or JSON error text.
728
752
  */
729
753
  error: string
730
- kind: "trend-snapshot-unreadable"
731
754
  } | {
755
+ kind: "trend-group-baseline-unavailable"
732
756
  /**
733
757
  * Why the groups have no baseline, as a kebab-case token:
734
758
  * `snapshot-has-no-groups` or `grouped-by-mismatch`. The set is open.
735
759
  */
736
760
  cause: string
737
- kind: "trend-group-baseline-unavailable"
738
761
  } | {
762
+ kind: "plugin-config-unreadable"
739
763
  /**
740
764
  * The plugin that read the config, as it labels itself:
741
765
  * `module-federation` for a standalone `module-federation.config.*`,
@@ -762,8 +786,8 @@ key: string
762
786
  * option the message points at.
763
787
  */
764
788
  reason: string
765
- kind: "plugin-config-unreadable"
766
789
  } | {
790
+ kind: "plugin-effect-not-modeled"
767
791
  /**
768
792
  * The plugin that read the config, as it labels itself (`nuxt`).
769
793
  */
@@ -782,36 +806,64 @@ key: string
782
806
  * be classified at all. The set is open.
783
807
  */
784
808
  reason: string
785
- kind: "plugin-effect-not-modeled"
786
809
  } | {
787
810
  kind: "coverage-auto-detected"
788
811
  } | {
789
812
  kind: "flag-age-shallow-clone"
790
813
  } | {
814
+ kind: "flag-age-unavailable"
791
815
  /**
792
816
  * Why no history is available, as a kebab-case token:
793
817
  * `not-a-repository` or `no-commits`. The set is open.
794
818
  */
795
819
  cause: string
796
- kind: "flag-age-unavailable"
797
820
  } | {
821
+ kind: "ignore-dependencies-glob-unmatched"
798
822
  /**
799
823
  * The `ignoreDependencies` entry, as written in the config.
800
824
  */
801
825
  pattern: string
802
- kind: "ignore-dependencies-glob-unmatched"
803
826
  } | {
827
+ kind: "ignore-findings-pattern-unmatched"
804
828
  /**
805
829
  * The `ignoreFindings` entry, as written in the config.
806
830
  */
807
831
  pattern: string
808
- kind: "ignore-findings-pattern-unmatched"
832
+ } | {
833
+ kind: "entry-pattern-redundant"
834
+ /**
835
+ * The `entry` pattern, as written in the config.
836
+ */
837
+ pattern: string
838
+ } | {
839
+ kind: "ignore-dependencies-entry-redundant"
840
+ /**
841
+ * The `ignoreDependencies` entry, as written in the config.
842
+ */
843
+ pattern: string
844
+ } | {
845
+ kind: "ignore-patterns-entry-redundant"
846
+ /**
847
+ * The `ignorePatterns` glob, as written in the config.
848
+ */
849
+ pattern: string
850
+ } | {
851
+ kind: "baseline-install-state-mismatch"
852
+ baseline_node_modules: NodeModulesState
853
+ run_node_modules: NodeModulesState
809
854
  })
810
855
  /**
811
856
  * Why the declared pnpm version ignores the `overrides` section of
812
857
  * `pnpm-workspace.yaml`.
813
858
  */
814
859
  export type PnpmWorkspaceOverridesIgnoredCause = ("package-json-overrides" | "pnpm-version")
860
+ /**
861
+ * Whether the project had a `node_modules` directory at a point in time.
862
+ *
863
+ * A dead-code baseline records this when it is saved, so a later run in a
864
+ * different install state can say that its results can differ.
865
+ */
866
+ export type NodeModulesState = ("present" | "missing")
815
867
  /**
816
868
  * Discriminant for [`CloneGroupAction::kind`]. Mirrors the action types
817
869
  * emitted by the legacy `build_clone_group_actions` walker.
@@ -886,6 +938,27 @@ export type ThresholdSource = "override"
886
938
  * `suppress-line`.
887
939
  */
888
940
  export type HealthFindingActionType = ("refactor-function" | "add-tests" | "increase-coverage" | "suppress-file" | "suppress-line")
941
+ /**
942
+ * Audit-mode class of a complexity finding against the base snapshot.
943
+ */
944
+ export type AuditFindingAttribution = ("introduced" | "worsened" | "inherited")
945
+ /**
946
+ * A measured metric of a complexity finding.
947
+ */
948
+ export type WorsenedMetricKind = ("cyclomatic" | "cognitive" | "crap" | "line_count")
949
+ /**
950
+ * Audit-mode reason why a complexity finding does not gate the verdict.
951
+ */
952
+ export type AuditGateExemption = "test-file"
953
+ /**
954
+ * How `fallow health` counts cyclomatic complexity for its gates.
955
+ *
956
+ * The policy changes the cyclomatic value that the `maxCyclomatic` gate reads
957
+ * and the cyclomatic value in every CRAP score. It does not change the health
958
+ * score, the complexity density, or the hotspot ranking: those keep the
959
+ * standard count so that grades stay comparable across projects.
960
+ */
961
+ export type CyclomaticPolicy = ("standard" | "literal-membership")
889
962
  /**
890
963
  * Coverage model used for CRAP score computation.
891
964
  */
@@ -1153,12 +1226,13 @@ export type DiffRiskActionType = ("suppress-line" | "suppress-file" | "suppress-
1153
1226
  * `target` block of [`InspectOutput`], tagged by `type`.
1154
1227
  */
1155
1228
  export type InspectTargetDescriptor = ({
1229
+ type: "file"
1156
1230
  /**
1157
1231
  * File path relative to the analysed root.
1158
1232
  */
1159
1233
  file: string
1160
- type: "file"
1161
1234
  } | {
1235
+ type: "symbol"
1162
1236
  /**
1163
1237
  * File path relative to the analysed root.
1164
1238
  */
@@ -1167,7 +1241,6 @@ file: string
1167
1241
  * Name of the inspected export.
1168
1242
  */
1169
1243
  export_name: string
1170
- type: "symbol"
1171
1244
  })
1172
1245
  /**
1173
1246
  * `identity` block of [`InspectOutput`]; shape follows the target type.
@@ -1691,7 +1764,7 @@ export type MutationSchemaVersion = "1"
1691
1764
  /**
1692
1765
  * Why a run is partial.
1693
1766
  */
1694
- export type MutationIncompleteReason = ("runtime-error" | "mutant-limit" | "time-budget" | "skipped-files" | "unloaded-files" | "baseline-failure" | "worktree-changed" | "typecheck-failed" | "worktree-unchecked")
1767
+ export type MutationIncompleteReason = ("runtime-error" | "mutant-limit" | "time-budget" | "skipped-files" | "unloaded-files" | "test-files-not-discovered" | "baseline-failure" | "worktree-changed" | "typecheck-failed" | "worktree-unchecked")
1695
1768
  /**
1696
1769
  * Which code a run mutates.
1697
1770
  */
@@ -1700,6 +1773,10 @@ export type MutationScopeKind = ("changed" | "all" | "paths")
1700
1773
  * The result of one mutant.
1701
1774
  */
1702
1775
  export type MutantStatus = ("killed" | "timeout" | "survived" | "no_coverage" | "runtime_error" | "flaky" | "pruned" | "pending" | "equivalent" | "compile_error")
1776
+ /**
1777
+ * How a run detected a mutant.
1778
+ */
1779
+ export type MutantFailureKind = ("assertion" | "error" | "timeout")
1703
1780
  /**
1704
1781
  * Why the type check did not check a survivor.
1705
1782
  */
@@ -1864,6 +1941,7 @@ duplication_clone_groups: number
1864
1941
  */
1865
1942
  export interface AuditAttribution {
1866
1943
  gate: AuditGate
1944
+ worsened?: AuditWorsened
1867
1945
  /**
1868
1946
  * Dead-code findings absent from the base snapshot.
1869
1947
  */
@@ -1880,6 +1958,12 @@ complexity_introduced: number
1880
1958
  * Complexity findings already present in the base snapshot.
1881
1959
  */
1882
1960
  complexity_inherited: number
1961
+ /**
1962
+ * Complexity findings whose `attribution` is `worsened`. These findings
1963
+ * are in the base snapshot, and a measured value is higher now. They are
1964
+ * also counted in `complexity_inherited`.
1965
+ */
1966
+ complexity_worsened?: number
1883
1967
  /**
1884
1968
  * Clone groups absent from the base snapshot.
1885
1969
  */
@@ -1984,7 +2068,8 @@ files?: GateFile[]
1984
2068
  *
1985
2069
  * Today only `parse-error` emits it. The item carries the same facts as the
1986
2070
  * `source-parse-degraded` entry in `workspace_diagnostics[]` for that file,
1987
- * so a consumer can act on the gate without a join.
2071
+ * so a consumer can act on the gate without a join. With `reason` set, the
2072
+ * count and the parser outcome are placeholders.
1988
2073
  */
1989
2074
  export interface GateFile {
1990
2075
  /**
@@ -1992,14 +2077,19 @@ export interface GateFile {
1992
2077
  */
1993
2078
  path: string
1994
2079
  /**
1995
- * The number of parser errors for the file.
2080
+ * The number of parser errors for the file. `1` when `reason` is set.
1996
2081
  */
1997
2082
  error_count: number
1998
2083
  /**
1999
2084
  * True when the parser stopped in the file instead of recovering, so the
2000
- * analysis saw only the part before the error.
2085
+ * analysis saw only the part before the error. `true` when `reason` is set.
2001
2086
  */
2002
2087
  panicked: boolean
2088
+ /**
2089
+ * Why the file counts when it is not a parser error. Absent for a parser
2090
+ * error, the only reason before this field existed.
2091
+ */
2092
+ reason?: (GateFileReason | null)
2003
2093
  }
2004
2094
  /**
2005
2095
  * Metric and rule definitions emitted under `_meta` when `--explain` is
@@ -3378,12 +3468,13 @@ _meta?: (Meta | null)
3378
3468
  *
3379
3469
  * - workspace discovery, at config load: `undeclared-workspace`,
3380
3470
  * `malformed-package-json`, `glob-matched-no-package-json`,
3381
- * `workspace-glob-outside-root`, `malformed-tsconfig`,
3471
+ * `workspace-glob-outside-root`, `workspace-pattern-dir-missing`,
3472
+ * `nested-project-root`, `malformed-tsconfig`,
3382
3473
  * `tsconfig-reference-dir-missing`;
3383
3474
  * - source discovery, during the file walk: `skipped-large-file`,
3384
3475
  * `skipped-minified-file`, `skipped-source-dotdir`,
3385
3476
  * `excluded-by-default-ignore`, `source-read-failure`,
3386
- * `source-parse-degraded`;
3477
+ * `source-parse-degraded`, `source-nesting-too-deep`;
3387
3478
  * - dead-code analysis, from the dependency-catalog and override
3388
3479
  * detectors: `malformed-pnpm-workspace-yaml`,
3389
3480
  * `bun-lockb-override-resolution-skipped`;
@@ -3402,10 +3493,11 @@ _meta?: (Meta | null)
3402
3493
  *
3403
3494
  * A diagnostic here is advisory and never withholds a finding. Where an
3404
3495
  * entry reports a source file this run never fully analyzed
3405
- * (`source-parse-degraded`, `source-read-failure`, `skipped-large-file`,
3406
- * `skipped-minified-file`, `skipped-source-dotdir`) it can distort a
3407
- * verdict, so the affected `unused_files[]`, `unused_exports[]`, and
3408
- * dependency entries additionally carry the caveat themselves in their own
3496
+ * (`source-parse-degraded`, `source-nesting-too-deep`,
3497
+ * `source-read-failure`, `skipped-large-file`, `skipped-minified-file`,
3498
+ * `skipped-source-dotdir`) it can distort a verdict, so the affected
3499
+ * `unused_files[]`, `unused_exports[]`, and dependency entries
3500
+ * additionally carry the caveat themselves in their own
3409
3501
  * optional `reachability_caveats[]` array, and a reader who never scrolls
3410
3502
  * back up to this list still sees it. `fallow fix` reads the same array
3411
3503
  * and withholds the removal while a caveat stands.
@@ -7939,9 +8031,17 @@ line: number
7939
8031
  */
7940
8032
  col: number
7941
8033
  /**
7942
- * Cyclomatic complexity of the function.
8034
+ * Cyclomatic complexity of the function, as the cyclomatic gate and the
8035
+ * CRAP score read it. Under the `literal-membership` value of
8036
+ * `health.cyclomaticPolicy`, this is the value after literal membership
8037
+ * chains count as one predicate.
7943
8038
  */
7944
8039
  cyclomatic: number
8040
+ /**
8041
+ * Standard `McCabe` cyclomatic complexity, present only when the
8042
+ * `health.cyclomaticPolicy` value gave `cyclomatic` a different value.
8043
+ */
8044
+ standard_cyclomatic?: (number | null)
7945
8045
  /**
7946
8046
  * Cognitive complexity of the function.
7947
8047
  */
@@ -7985,7 +8085,9 @@ severity: FindingSeverity
7985
8085
  * `overrides[].rules` entries: `error` fails the run, `warn` does not.
7986
8086
  * The most severe rule of the kinds in `exceeded` wins. It is separate
7987
8087
  * from the band in `severity`, which ranks the finding and does not gate
7988
- * it. Absent in reports from older versions.
8088
+ * it. Under `audit --gate new-only`, a finding that exceeds only CRAP
8089
+ * from estimated coverage has `warn`. Absent in reports from older
8090
+ * versions.
7989
8091
  */
7990
8092
  effective_severity?: (EffectiveSeverity | null)
7991
8093
  /**
@@ -8048,10 +8150,33 @@ actions: HealthFindingAction[]
8048
8150
  /**
8049
8151
  * Audit-mode flag indicating whether the finding is new versus the base
8050
8152
  * snapshot. A complexity finding is new when no base finding has the same
8051
- * path and function name, or when a metric that it exceeds has a higher
8052
- * value than in that base finding.
8153
+ * path and function name, when a grown metric exceeds a threshold that
8154
+ * the base finding did not exceed, or when the growth of an exceeded
8155
+ * metric moves it to a higher severity tier. A CRAP score from estimated
8156
+ * coverage, or a CRAP score that the base finding does not have, is not
8157
+ * growth.
8053
8158
  */
8054
8159
  introduced?: (boolean | null)
8160
+ /**
8161
+ * Audit-mode class of the finding against the base snapshot:
8162
+ * `introduced`, `worsened` or `inherited`. A worsened finding matches a
8163
+ * base finding, is not introduced, and has a higher value in at least one
8164
+ * measured metric. Absent outside an audit with a base snapshot.
8165
+ */
8166
+ attribution?: (AuditFindingAttribution | null)
8167
+ /**
8168
+ * Audit-mode list of the measured metrics that are higher than in the
8169
+ * matched base finding, with the base value and the head value. Present
8170
+ * on a worsened finding, and on an introduced finding that matches a base
8171
+ * finding. Absent when no metric grew.
8172
+ */
8173
+ worsened_metrics?: WorsenedMetric[]
8174
+ /**
8175
+ * Audit-mode reason why the finding does not gate the verdict. With
8176
+ * `test-file`, the finding is in a test file and `effective_severity` is
8177
+ * `warn`. Absent outside `audit`, and on a finding that gates.
8178
+ */
8179
+ gate_exemption?: (AuditGateExemption | null)
8055
8180
  }
8056
8181
  /**
8057
8182
  * Per-component React hook profile derived from the cached `hook_uses` IR at
@@ -8232,6 +8357,15 @@ weight: number
8232
8357
  * consumer explain a cognitive `+3` as "+1 base, +2 nesting".
8233
8358
  */
8234
8359
  nesting: number
8360
+ /**
8361
+ * This cyclomatic `||` increment is part of a literal membership chain:
8362
+ * strict equality checks of one identifier against primitive literals
8363
+ * (`kind === "a" || kind === "b"`). The `literal-membership` value of
8364
+ * `health.cyclomaticPolicy` removes these increments from the effective
8365
+ * cyclomatic value. Omitted when `false`, and always `false` under the
8366
+ * default `standard` policy.
8367
+ */
8368
+ literal_membership?: boolean
8235
8369
  }
8236
8370
  /**
8237
8371
  * Resolved thresholds used to evaluate a health finding.
@@ -8323,6 +8457,21 @@ placement?: (string | null)
8323
8457
  */
8324
8458
  target_path?: (string | null)
8325
8459
  }
8460
+ /**
8461
+ * One measured metric that is higher at head than in the matched base
8462
+ * finding.
8463
+ */
8464
+ export interface WorsenedMetric {
8465
+ metric: WorsenedMetricKind
8466
+ /**
8467
+ * Value in the matched base finding.
8468
+ */
8469
+ base: number
8470
+ /**
8471
+ * Value in the head finding. Always higher than `base`.
8472
+ */
8473
+ head: number
8474
+ }
8326
8475
  /**
8327
8476
  * Summary statistics for the health report.
8328
8477
  */
@@ -8347,6 +8496,11 @@ functions_above_threshold: number
8347
8496
  * Global cyclomatic-complexity ceiling for this run.
8348
8497
  */
8349
8498
  max_cyclomatic_threshold: number
8499
+ /**
8500
+ * Cyclomatic policy of the gates (`health.cyclomaticPolicy`). Absent
8501
+ * under the default `standard` policy.
8502
+ */
8503
+ cyclomatic_policy?: (CyclomaticPolicy | null)
8350
8504
  /**
8351
8505
  * Global cognitive-complexity ceiling for this run.
8352
8506
  */
@@ -12178,6 +12332,13 @@ star_export_ambiguity?: (StarExportAmbiguity | null)
12178
12332
  * Re-export chains that pass through this export.
12179
12333
  */
12180
12334
  re_export_chains: ReExportChain[]
12335
+ /**
12336
+ * The framework plugin rules that mark this export as used. The
12337
+ * framework calls or reads the export, so no import is necessary. A
12338
+ * credit sets `is_used` when the file is reachable. Absent when no
12339
+ * plugin credits the export.
12340
+ */
12341
+ plugin_credits?: PluginExportCredit[]
12181
12342
  /**
12182
12343
  * Human-readable reason summary.
12183
12344
  */
@@ -12270,6 +12431,19 @@ exported_as: string
12270
12431
  */
12271
12432
  reference_count: number
12272
12433
  }
12434
+ /**
12435
+ * A framework plugin rule that marks an export as used.
12436
+ */
12437
+ export interface PluginExportCredit {
12438
+ /**
12439
+ * The plugin that gives the rule, for example `nextjs`.
12440
+ */
12441
+ plugin: string
12442
+ /**
12443
+ * The project-relative file pattern of the rule.
12444
+ */
12445
+ pattern: string
12446
+ }
12273
12447
  /**
12274
12448
  * Result of tracing a class / enum / store MEMBER: the `--trace FILE:NAME`
12275
12449
  * fallback when `NAME` is not a top-level export but a member declared on one
@@ -12389,6 +12563,11 @@ reference_count: number
12389
12563
  * Files that reference this export.
12390
12564
  */
12391
12565
  referenced_by: ExportReference[]
12566
+ /**
12567
+ * The framework plugin rules that mark this export as used. Absent when
12568
+ * no plugin credits the export.
12569
+ */
12570
+ plugin_credits?: PluginExportCredit[]
12392
12571
  }
12393
12572
  /**
12394
12573
  * A re-export with source information.
@@ -16650,12 +16829,13 @@ _meta?: (Meta | null)
16650
16829
  *
16651
16830
  * - workspace discovery, at config load: `undeclared-workspace`,
16652
16831
  * `malformed-package-json`, `glob-matched-no-package-json`,
16653
- * `workspace-glob-outside-root`, `malformed-tsconfig`,
16832
+ * `workspace-glob-outside-root`, `workspace-pattern-dir-missing`,
16833
+ * `nested-project-root`, `malformed-tsconfig`,
16654
16834
  * `tsconfig-reference-dir-missing`;
16655
16835
  * - source discovery, during the file walk: `skipped-large-file`,
16656
16836
  * `skipped-minified-file`, `skipped-source-dotdir`,
16657
16837
  * `excluded-by-default-ignore`, `source-read-failure`,
16658
- * `source-parse-degraded`;
16838
+ * `source-parse-degraded`, `source-nesting-too-deep`;
16659
16839
  * - dead-code analysis, from the dependency-catalog and override
16660
16840
  * detectors: `malformed-pnpm-workspace-yaml`,
16661
16841
  * `bun-lockb-override-resolution-skipped`;
@@ -16674,10 +16854,11 @@ _meta?: (Meta | null)
16674
16854
  *
16675
16855
  * A diagnostic here is advisory and never withholds a finding. Where an
16676
16856
  * entry reports a source file this run never fully analyzed
16677
- * (`source-parse-degraded`, `source-read-failure`, `skipped-large-file`,
16678
- * `skipped-minified-file`, `skipped-source-dotdir`) it can distort a
16679
- * verdict, so the affected `unused_files[]`, `unused_exports[]`, and
16680
- * dependency entries additionally carry the caveat themselves in their own
16857
+ * (`source-parse-degraded`, `source-nesting-too-deep`,
16858
+ * `source-read-failure`, `skipped-large-file`, `skipped-minified-file`,
16859
+ * `skipped-source-dotdir`) it can distort a verdict, so the affected
16860
+ * `unused_files[]`, `unused_exports[]`, and dependency entries
16861
+ * additionally carry the caveat themselves in their own
16681
16862
  * optional `reachability_caveats[]` array, and a reader who never scrolls
16682
16863
  * back up to this list still sees it. `fallow fix` reads the same array
16683
16864
  * and withholds the removal while a caveat stands.
@@ -16715,10 +16896,12 @@ elapsed_ms: ElapsedMs
16715
16896
  /**
16716
16897
  * The verdict of every gate this run evaluated, keyed by name. The CLI
16717
16898
  * always emits it, with the default exit rule of each section that ran
16718
- * (`error-severity-findings`, `health-findings`). Without
16899
+ * (`error-severity-findings`, `health-findings`). A `coverage-gaps` rule
16900
+ * at `error` adds `health-coverage-gaps`. Without
16719
16901
  * `--fail-on-issues` or `--ci`, the machine formats of the combined run
16720
16902
  * exit 0 for findings, so most entries have `enforced: false`. With one of
16721
- * these flags, the findings rules and `duplication-threshold` are
16903
+ * these flags, the findings rules, `health-coverage-gaps` and
16904
+ * `duplication-threshold` are
16722
16905
  * `enforced`, the dupes section adds an enforced `duplication-findings`
16723
16906
  * entry, and every format exits 1 when one fails. For the default
16724
16907
  * exit rules (`error-severity-findings`,
@@ -16870,8 +17053,8 @@ total_flags: number
16870
17053
  * A flags run walks and parses the project like every other analysis, so
16871
17054
  * it records the same discovery kinds: a `skipped-large-file`,
16872
17055
  * `skipped-minified-file`, or `source-read-failure` file was never
16873
- * scanned for flags, and a `source-parse-degraded` file was scanned from
16874
- * a partial module. Each is a reason a flag can be missing from
17056
+ * scanned for flags, a `source-parse-degraded` file was scanned from a
17057
+ * partial module, and a `source-nesting-too-deep` file was not scanned. Each is a reason a flag can be missing from
16875
17058
  * `feature_flags[]`, which is exactly what a consumer reading a
16876
17059
  * zero-result run needs to know. The analysis-stage kinds appear here
16877
17060
  * too: the scan correlates flags with dead exports, so it runs the
@@ -19931,6 +20114,11 @@ function_line?: (number | null)
19931
20114
  * The 1-based execution rank of a planned mutant.
19932
20115
  */
19933
20116
  rank?: (number | null)
20117
+ /**
20118
+ * The edit of the mutant, without project text. Absent in a report
20119
+ * that an older version wrote.
20120
+ */
20121
+ change?: (MutantChange | null)
19934
20122
  status: MutantStatus
19935
20123
  /**
19936
20124
  * The static rule of a `pruned` mutant, kebab-case.
@@ -19944,6 +20132,9 @@ prune_reason?: (string | null)
19944
20132
  * first failing test, and it runs the fastest covering test first, so a
19945
20133
  * second run on the same code can name another covering test. No
19946
20134
  * fingerprint or baseline comparison uses this field.
20135
+ *
20136
+ * The retry of a survivor also runs the other tests of its test files,
20137
+ * so this test can be absent from `covering_tests`.
19947
20138
  */
19948
20139
  killed_by?: (string | null)
19949
20140
  /**
@@ -19970,6 +20161,13 @@ test_reach?: (MutantTestReach | null)
19970
20161
  * retry, because the time budget ended first.
19971
20162
  */
19972
20163
  retried?: boolean
20164
+ /**
20165
+ * The runs that gave the status of a `retried` mutant: the first run,
20166
+ * then the retry. Absent when the mutant got no retry, and absent for a
20167
+ * `cached` mutant. Each duration is evidence of one run, so no
20168
+ * fingerprint or baseline comparison uses this field.
20169
+ */
20170
+ attempts?: MutantAttempt[]
19973
20171
  /**
19974
20172
  * True when the status comes from the result cache of an earlier run.
19975
20173
  * The mutant did not run in this run. `--no-cache` runs each mutant.
@@ -19981,6 +20179,25 @@ cached?: boolean
19981
20179
  */
19982
20180
  type_error_codes?: number[]
19983
20181
  }
20182
+ /**
20183
+ * The edit of a mutant, without project text.
20184
+ *
20185
+ * Each side is an operator token (for example `??` or `<=`), a fixed literal
20186
+ * (`true`, `undefined`, `""`, `"fallow"`, `void 0`), a regular expression
20187
+ * token (`^`, `$`, `[`, `[^`, `\d`), or a placeholder for a side that is
20188
+ * project code: `<condition>`, `<call>`, `<expression>` or `<string>`. An
20189
+ * empty side means that the edit removes the token.
20190
+ */
20191
+ export interface MutantChange {
20192
+ /**
20193
+ * The token or placeholder before the edit.
20194
+ */
20195
+ from: string
20196
+ /**
20197
+ * The token or placeholder after the edit.
20198
+ */
20199
+ to: string
20200
+ }
19984
20201
  /**
19985
20202
  * How tests reach the code of one mutant in the module graph. The class
19986
20203
  * gives a static reason why no test covers the mutant.
@@ -20009,6 +20226,30 @@ tests?: string[]
20009
20226
  */
20010
20227
  mocked_targets?: string[]
20011
20228
  }
20229
+ /**
20230
+ * One run of a retried mutant.
20231
+ */
20232
+ export interface MutantAttempt {
20233
+ status: MutantStatus
20234
+ /**
20235
+ * The duration of this run in milliseconds. A watchdog timeout reports
20236
+ * the wait of the watchdog.
20237
+ */
20238
+ duration_ms?: (number | null)
20239
+ /**
20240
+ * The test that killed the mutant in this run.
20241
+ */
20242
+ killed_by?: (string | null)
20243
+ /**
20244
+ * How the run detected the mutant. Absent for a run that did not detect
20245
+ * it, and absent when the runner did not state the kind.
20246
+ */
20247
+ failure_kind?: (MutantFailureKind | null)
20248
+ /**
20249
+ * The first line of the reason of a `runtime_error` run.
20250
+ */
20251
+ detail?: (string | null)
20252
+ }
20012
20253
  /**
20013
20254
  * The results of the mutants of one function.
20014
20255
  */
@@ -20364,6 +20605,11 @@ function_line?: (number | null)
20364
20605
  * The 1-based execution rank of a planned mutant.
20365
20606
  */
20366
20607
  rank?: (number | null)
20608
+ /**
20609
+ * The edit of the mutant, without project text. Absent in a report
20610
+ * that an older version wrote.
20611
+ */
20612
+ change?: (MutantChange | null)
20367
20613
  disposition: MutationPlanDisposition
20368
20614
  /**
20369
20615
  * The static rule of a `pruned` mutant, kebab-case.
@@ -20425,6 +20671,11 @@ function_line?: (number | null)
20425
20671
  * The 1-based execution rank of a planned mutant.
20426
20672
  */
20427
20673
  rank?: (number | null)
20674
+ /**
20675
+ * The edit of the mutant, without project text. Absent in a report
20676
+ * that an older version wrote.
20677
+ */
20678
+ change?: (MutantChange | null)
20428
20679
  /**
20429
20680
  * The status of the mutant in the report. Absent for a plan.
20430
20681
  */