Commit ee98373
fix(ci): normalize committed CRLF to LF and name the failure for what it is (#9799)
* fix(ci): normalize committed CRLF to LF and name the failure for what it is
Twenty files were committed with CRLF and the repo had no .gitattributes. The `changes` job runs
`git diff --check`, and git's default core.whitespace is `blank-at-eol` with `cr-at-eol` off, so a
carriage return at end-of-line counts as trailing whitespace. Any PR adding a line to one of those
files failed CI pointing at lines whose visible content is spotless, with nothing in the log saying
"CRLF" — it hit #9787 (run 30436384202) on two lines of inline-suggestion-anchor.ts.
Convert all twenty to LF via `git add --renormalize`, byte-identical otherwise (`git diff -w` reports
only the two new files below), and pin the repo with `* text=auto eol=lf`. `text=auto` rather than a
bare `text` is load-bearing: five .ts files embed NUL bytes as untrusted-text and sanitizer fixtures,
and auto-detection classifies them binary and passes them through untouched.
The whitespace step now names CRLF before falling through to the generic check. .gitattributes stops
CRLF entering through `git add`, but checkin filters don't run on blobs written directly (web editor,
Contents API) or on a merge of a branch cut earlier, so the diagnostic still has a job. It is scoped
to added lines, so it fires on exactly what `git diff --check` already flagged — a relabel, not a new
failure mode.
Closes #9798
* test(engine): cover the package-local buildIssueQualityReport in the engine suite
`buildIssueQualityReport` is re-exported from the engine barrel (src/index.ts) but this package's own
node:test suite never called it. `npm run engine:coverage` therefore saw the module load — top-level
constants only — and reported it LF:313 LH:96 with BRF:0, i.e. no function-level data at all, while
the root vitest suite covered the same file 87/87 lines and 143/143 branches.
Two uploads disagreeing about the same file is invisible while patch coverage only reads changed
lines, because nothing changes all 313 at once. Renormalizing the file's line endings did, and the
merged report capped at ~57%: of the 217 lines the engine flag called uncovered, 84 were rescued by
vitest and 133 were function-signature and closing-brace lines v8 never lists as statements, so
nothing could rescue them.
Cover it where this package is actually graded rather than leaning on the vitest duplicate — the
outcome scripts/engine-coverage.ts (#9064) was written to encourage. The file now reports
313/313 lines and 163/163 branches under the engine model.
17 cases covering the lane arms (issue_discovery / direct_pr / split / unknown), every bounty
lifecycle, duplicate and invalid labelling, self-solved loops, maintainer-authored vs maintainer-WIP,
linkedPrs back-references for both open and merged PRs, collision risk tiers, sort order, the
lifecycle and report caps, and the null-repo / unparseable-date degradation paths.
---------
Co-authored-by: JSONbored <aetherealdev@gmail.com>1 parent ace8d1a commit ee98373
23 files changed
Lines changed: 2437 additions & 2027 deletions
File tree
- .github/workflows
- packages/loopover-engine
- src/signals
- test
- review-enrichment
- src/analyzers
- test
- src/review
- test/unit
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
83 | 83 | | |
84 | 84 | | |
85 | 85 | | |
| 86 | + | |
| 87 | + | |
| 88 | + | |
| 89 | + | |
| 90 | + | |
| 91 | + | |
| 92 | + | |
| 93 | + | |
| 94 | + | |
| 95 | + | |
| 96 | + | |
| 97 | + | |
| 98 | + | |
| 99 | + | |
| 100 | + | |
| 101 | + | |
| 102 | + | |
| 103 | + | |
| 104 | + | |
| 105 | + | |
| 106 | + | |
| 107 | + | |
86 | 108 | | |
87 | 109 | | |
88 | 110 | | |
| |||
Lines changed: 313 additions & 313 deletions
Large diffs are not rendered by default.
0 commit comments