@autotelic/joggle 0.4.2 → 0.4.4
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.
- package/JOGGLE.md +7 -0
- package/dist/check.js +18 -1
- package/package.json +1 -1
package/JOGGLE.md
CHANGED
|
@@ -483,6 +483,13 @@ writes the file as this run alone, which for a scoped run would truncate the
|
|
|
483
483
|
ledger. `--allow-unjudged-baseline` is not the shortcut here: it ratifies the
|
|
484
484
|
thousands nobody looked at, which is a commit nobody can defend.
|
|
485
485
|
|
|
486
|
+
A scoped accept is necessary, not sufficient. Cross-file rules only fire over the
|
|
487
|
+
whole repository, and a scoped run folds some findings into another rule at the same
|
|
488
|
+
site (the note counts them), so an identity CI fails on can be one this run never had.
|
|
489
|
+
Use the scoped accept to keep a stack moving and treat the full run as the authority:
|
|
490
|
+
when CI names an identity the scoped ledger lacks, accept that one and move on. Budget
|
|
491
|
+
one full judged run for the stack's head, not one per branch.
|
|
492
|
+
|
|
486
493
|
### The cascade, not the conflicts
|
|
487
494
|
|
|
488
495
|
In a deep stack the conflicts are the easy half. Every one of them is a committed
|
package/dist/check.js
CHANGED
|
@@ -250,6 +250,17 @@ export const checkRepository = Effect.fn("joggle.check")(function* (options) {
|
|
|
250
250
|
reason: `wrote 0 identities to ${target}: nothing new to accept`,
|
|
251
251
|
});
|
|
252
252
|
}
|
|
253
|
+
// A finding with no identity is one no baseline can ever hold: it survives every run
|
|
254
|
+
// and no accept quiets it. Saying so is the difference between "accepted" and
|
|
255
|
+
// "accepted, and these will be back".
|
|
256
|
+
const unnameable = report.diagnostics.filter((entry) => entry.identity === undefined).length;
|
|
257
|
+
if (unnameable > 0) {
|
|
258
|
+
notes.push({
|
|
259
|
+
ruleId: "joggle",
|
|
260
|
+
reason: unnameable +
|
|
261
|
+
" finding(s) declare no identity, so no baseline can accept them; they will appear in every run",
|
|
262
|
+
});
|
|
263
|
+
}
|
|
253
264
|
}
|
|
254
265
|
return notes.length === 0
|
|
255
266
|
? { ...report, diagnostics }
|
|
@@ -827,7 +838,13 @@ export const checkRepository = Effect.fn("joggle.check")(function* (options) {
|
|
|
827
838
|
notes.push({
|
|
828
839
|
ruleId: "joggle",
|
|
829
840
|
reason: folded.folded +
|
|
830
|
-
" finding(s) reported a site another rule already reported with more evidence, and were folded into it"
|
|
841
|
+
" finding(s) reported a site another rule already reported with more evidence, and were folded into it" +
|
|
842
|
+
// In a scoped run the fold is a ledger hazard, not just a readability note: the folded
|
|
843
|
+
// finding has no identity in this run, so an accept written from a scoped run can be
|
|
844
|
+
// missing exactly the identity a full run reports (and CI fails on).
|
|
845
|
+
(options.changedPaths === undefined
|
|
846
|
+
? ""
|
|
847
|
+
: "; a folded finding's identity is not in this run, so an accept taken from a scoped run can miss one a full run reports"),
|
|
831
848
|
});
|
|
832
849
|
}
|
|
833
850
|
// The workspace's own phases, alongside the per-rule timings. A run that says
|