Repository navigation
fix(ci): pin settings-registry.generated.json to LF so the Windows build's byte-compare passes - #18751
fix(ci): pin settings-registry.generated.json to LF so the Windows build's byte-compare passes#18751CrysisDeu wants to merge 1 commit into
Conversation
…ild's byte-compare passes
UX Review (Opus 5.5) — ⏭️ skippedRevision |
First Principles Review (Opus 5.5) — ⏭️ skippedRevision |
GPT 6.1 Review — ✅ no blocking findingsGPT 6.1 completed its review of This comment is updated in place on each push. Review detailsNo findings. False positive or not applicable? A repository writer can comment: |
Opus 5.5 Review — ✅ no blocking findingsReviewed Verdict parsed from the review's SHA-scoped output markers for commit False positive or not applicable? A repository writer can comment: |
Design Review (Opus 5.5) — 🟡 CONCERNSDesign-level review of Design-Verdict: CONCERNS The pin covers only the first of two unpinned byte-compares in the Windows build, so the Windows build will most likely still fail, just one check later. Watch
Suggestions
[DESIGN-REVIEWED] f58fb8d Description read[DESCRIPTION-READ] 6d39ca5bea76635938256766de2a7af371267146c031895b3904b48f559f5d33 That sha256 names everything this verdict read: the PR description, plus the 1 evidence file(s) the workflow collected from it and handed this review. It covers that evidence because the media strip replaces every attachment URL with the same placeholder, so an edit swapping one attachment for another would leave the description's captured text identical while what this review judged changed. Recompute it with |
leonlaiyc
left a comment
There was a problem hiding this comment.
Codex Desktop independent review of f58fb8d. CrysisDeu remains the implementation owner; this is a comment review, not code-owner approval or an AI-review override.
The added settings pin works. I reproduced the Design Review's sibling concern on Windows rather than relying on the bot's prediction:
- Created a detached worktree with
git -c core.autocrlf=true worktree add --detach ... <head>; Node v22.23.2,npm ci --ignore-scripts --no-audit --no-fundsucceeded. git ls-files --eolreports settings JSONi/lf w/lf, but UI index JSONi/lf w/crlf; the latter has no text/eol attribute.- The exact checkout's
node scripts/gen-ui-index.mjs --checkpasses the settings comparison, then fails withui-index.generated.json is stale. - Generated a fresh UI index to scratch with
--out, temporarily placed its LF bytes at the compared path, and--checkexited 0. - Changed ONLY those fresh index bytes from LF to CRLF:
--checkexited 1 with the same stale-index error. This isolates the checkout defect from the separately stale committed digest. - A CRLF settings control reproduced the original settings error; restoring both files to LF passed again. All tracked files were restored after the experiment.
The remaining sibling is therefore a concrete incomplete-fix concern for the frozen goal of restoring Windows builds, not a request to audit unrelated generated files. Please also pin src/kiro_crew/docs/ui-index.generated.json to LF (an explicit sibling entry suffices). Keep the independent stale-digest regeneration in #18753.
Current CI is not green: Build Wheel's frontend log also names the stale UI index; E2E and two Linux desktop jobs are red, and readiness is pending. No full application build/test pass is claimed. Required upstream CI and code-owner review still apply.
|
Superseded: #19148 landed the same |
Problem / Motivation
Goal: The Nightly Build's Windows jobs build again, by checking out
settings-registry.generated.jsonwith LF on every platform.Bug fix. The Nightly Build is red on Windows only:
Build Windows Desktop / Build Windows DesktopandPod Scenario E2E (windows-latest)fail innpm run build(website) withFailing run: https://github.com/kirodotdev/KiroCrew/actions/runs/38029978692 (head 8ce11f0). Linux and macOS jobs of the same run pass; the previous nightly (head b6ce813) had Windows green. The committed file is correct;
npm run gen:settingson Linux is a no-op.Why it matters
Every Windows build of the website fails: the nightly's Windows desktop and installer artifacts are not produced, the Windows E2E lane never runs, and every Windows contributor with the Git-for-Windows default
core.autocrlf=truegets a rednpm run buildon an untouched checkout. Left alone, every PR's Windows build jobs are red too, which hides any real Windows regression behind this noise.Not a goal
checkSettingsExtraction()orgen-ui-index.mjs(normalizing line endings in the comparator); the byte-for-byte compare is the intended contract.ui-index.generated.json, which is stale on the currentmaintip for a different reason (see Manual verification).What changed (motivation → approach → change)
Symptom: Windows-only
settings-registry.generated.json does not match the live settings extraction.Root cause: #18443 added
checkSettingsExtraction()(website/scripts/lib/ui-index.mjs), which byte-compares the livegenerateAgentRegistryJson(entries)output (LF) against the committedsrc/kiro_crew/docs/settings-registry.generated.jsonas read from disk bywebsite/scripts/gen-ui-index.mjs.website/.gitattributespins*.json text eol=lf, but only for files underwebsite/. The agent JSON lives atsrc/kiro_crew/docs/, outside that scope, and the root.gitattributesdid not cover it. Undercore.autocrlf=trueit is checked out as CRLF, so the compare fails on Windows and only there. The siblingsettingsRegistry.gen.ts(underwebsite/) is pinned and passes, which is why only one of the two possible errors appears.Change: one new entry in the root
.gitattributes,src/kiro_crew/docs/settings-registry.generated.json text eol=lf, next to the/config-baseline.jsonpin, with a comment in the file's existing style. The blob is already LF in the index (git ls-files --eolreportsi/lf), so this changes only the Windows working-tree checkout; there is no content change.Why
.gitattributesand not the comparator: a byte-for-byte compare against LF output is the point of the check (a renamed Settings label must fail it). Normalizing insidecheckSettingsExtractionwould hide a real CRLF drift in the committed file and be a one-off for a class the repo already handles at checkout: the root.gitattributespins/config-baseline.json,docs/decisions/*.md, the ACP frame corpus and the pi gate extension for exactly this reason, andwebsite/.gitattributessays the same about its*.jsonpin. This entry follows that pattern.Backwards compatibility
Compatible: a
.gitattributeseol=lfpin on a file whose index blob is already LF changes nothing on Linux/macOS and only stops the CRLF rewrite on Windows checkouts; no code, config or data format changes.Removes nothing: the diff adds one attribute line and a comment.
Tests
N/A — no code changes; the fix is a checkout attribute. The existing
npm run buildstep (gen-ui-index.mjs --check→checkSettingsExtraction) on the Windows CI jobs is the regression test and is what this PR's CI exercises.Manual verification
Static only:
git check-attr -a src/kiro_crew/docs/settings-registry.generated.jsonnow reportstext: set,eol: lf;git ls-files --eolshowsi/lf w/lf, so the index blob is unchanged.node scripts/gen-ui-index.mjs --checkinwebsite/on the Nightly head 8ce11f0 exits 0 on Linux with this change.maintip (5b2f8b1) the same--checkreportssrc/kiro_crew/docs/ui-index.generated.json is stale(input_digest only), introduced by fix(sidebar): restore the folder geometry decided in #3905 #18362 (b16b26b). That is independent of this PR and of the Windows CRLF issue, and is why the Build / Wheel / E2E jobs on this PR are red on every platform untilmainregenerates the index.Related Issues
Nightly run https://github.com/kirodotdev/KiroCrew/actions/runs/38029978692; introduced by #18443.
Pattern harvest
Rule candidate: lint
Pattern: a generated file that a script byte-compares against LF output is committed outside the
.gitattributesscope that pinseol=lffor its siblings.Checklist
feat|fix|docs|style|refactor|perf|test|chore|ci|build|revert: ...)Contribution License Agreement
Contributions are accepted under the project's Apache-2.0 license; see the Licensing section of CONTRIBUTING.md.