-
Notifications
You must be signed in to change notification settings - Fork 1
review: stop recommending gh aw update in the consumer README #371
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from all commits
Commits
Show all changes
10 commits
Select commit
Hold shift + click to select a range
96c2fbc
[jwbron/review-readme-manual-merge] review: stop recommending gh aw u…
jwbron 9c901e3
[jwbron/review-readme-manual-merge] review: ban gh aw update everywhe…
jwbron b1ec70d
Merge remote-tracking branch 'origin/main' into HEAD
jwbron 5c6893e
review: sweep the last runtime gh aw update mention; give the update …
jwbron 7d260c3
Merge remote-tracking branch 'origin/main' into HEAD
jwbron 6954124
Merge remote-tracking branch 'origin/main' into HEAD
jwbron bb9af89
review: rewrite the changeset for the post-#357 diff; make the stop l…
jwbron 1410e5b
Merge remote-tracking branch 'origin/main' into HEAD
jwbron ccfbda9
review: soften the stop-comment claim, put the revisit condition in t…
jwbron fa9ee8f
review: the ban sweep scans every tracked file and spares the CHANGELOG
jwbron File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Some comments aren't visible on the classic Files Changed page.
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,5 @@ | ||
| --- | ||
| "review": patch | ||
| --- | ||
|
|
||
| Docs only, following up on the `gh aw update` ban Khan/actions#357 landed. The consumer-facing README now names the gh-aw version both failures were observed on (v0.85.4) and the condition for revisiting the ban: neither failure is filed upstream yet, so re-test both on a scratch install before trusting a newer gh-aw release. The consumer-config checker's `source-missing` warning no longer frames `gh aw update` as the update mechanism; it now cites the reason `source:` still matters (the manual bump flow reads it to tell which release the install was copied from). The onboarding skill's update block gains an explicit stop comment between the merge instructions and `gh aw compile`, telling the reader to run the 3-way merge and commit it before compiling (advisory: a shell comment cannot stop a straight paste, but the prior `<STOP: ...>` pseudo-tag was not valid shell at all). This repo's own installed `review.md` changes only in a frontmatter comment (the observability local-edit note no longer names `gh aw update` as the merger; lock recompiled); no behavior change. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,81 @@ | ||
| /** | ||
| * CI backstop for the `gh aw update` ban (the tool repins `review-v*` tags to | ||
| * main's head SHA and once emptied an installed `review.md` to 0 bytes; see | ||
| * `.claude/skills/review-consumer-bump/SKILL.md`). The ban lives entirely in | ||
| * prose, which no automation touches, so nothing but this test stops a future | ||
| * doc edit from recommending the tool again. Same shape as the repo's other | ||
| * untouched-by-automation backstops (review-pins.test.ts, the cache-miss | ||
| * guard): every tracked mention must sit in a file known to talk ABOUT the | ||
| * ban, and a mention anywhere else fails red so the author reads the skill | ||
| * before re-recommending. | ||
| * | ||
| * Known limit: the allowlist is file-granular. It catches the ban RELOCATING | ||
| * (a mention appearing in a new file) but not a recommending sentence added | ||
| * to a file already allowed to mention the tool; that stays a review-time | ||
| * judgment. Excluded from the sweep entirely: `.changeset/` and the package | ||
| * CHANGELOG.md files (changeset bodies describing the ban are copied | ||
| * verbatim into the CHANGELOG at `changeset version`, so both carry the | ||
| * phrase legitimately and transiently grow), and the eval corpus (case | ||
| * fixtures quote arbitrary text; vitest.config.ts already carves out its | ||
| * tree/ dirs for the same reason). | ||
| */ | ||
| import {spawnSync} from "node:child_process"; | ||
| import * as fs from "fs"; | ||
| import * as path from "path"; | ||
| import {describe, expect, it} from "vitest"; | ||
|
|
||
| const repoRoot = path.resolve(new URL(".", import.meta.url).pathname, "../.."); | ||
|
|
||
| /** | ||
| * Files allowed to mention the tool: the ban's own section in the bump skill, | ||
| * the two onboarding-skill warnings, the consumer README's warning, | ||
| * review-pins.test.ts's doc comments about why the pins need a backstop at | ||
| * all, and this file, which carries the search string itself (the one | ||
| * non-prohibitive mention). | ||
| */ | ||
| const ALLOWED = new Set([ | ||
|
khan-actions-bot marked this conversation as resolved.
|
||
| ".claude/skills/review-consumer-bump/SKILL.md", | ||
| ".claude/skills/review-onboarding/SKILL.md", | ||
| ".github/workflows/review-pins.test.ts", | ||
| "workflows/review/README.md", | ||
| "workflows/review/gh-aw-update-ban.test.ts", | ||
| ]); | ||
|
|
||
| describe("the gh aw update ban", () => { | ||
| it("is mentioned only where it is being banned", () => { | ||
| // Every tracked file, not an extension list: the ban's residue has | ||
| // already turned up in .md prose, .ts warning strings, and a | ||
| // compiled .lock.yml, so an extension filter is just a bet on where | ||
| // the next one lands. Reading a binary as utf8 cannot match the | ||
| // phrase, so no file type needs excluding for safety. | ||
| const ls = spawnSync("git", ["ls-files"], { | ||
| cwd: repoRoot, | ||
| encoding: "utf8", | ||
| }); | ||
| expect(ls.status).toBe(0); | ||
| const offenders = ls.stdout.split("\n").filter( | ||
| (file) => | ||
| file !== "" && | ||
| !file.startsWith(".changeset/") && | ||
| // `changeset version` copies each changeset body verbatim | ||
| // into the package CHANGELOG.md, so the released notes | ||
| // inherit whatever mentions .changeset/ was excused for. | ||
| !file.endsWith("CHANGELOG.md") && | ||
| !file.startsWith("workflows/review/eval/corpus/") && | ||
| !ALLOWED.has(file) && | ||
| fs | ||
| .readFileSync(path.join(repoRoot, file), "utf8") | ||
| .includes("gh aw update"), | ||
| ); | ||
| expect(offenders).toEqual([]); | ||
| }); | ||
|
|
||
| it("keeps every allowlisted file actually mentioning it (stale allowlist detector)", () => { | ||
| for (const file of ALLOWED) { | ||
| expect( | ||
| fs.readFileSync(path.join(repoRoot, file), "utf8"), | ||
| `${file} no longer mentions the tool; prune it from ALLOWED`, | ||
| ).toContain("gh aw update"); | ||
| } | ||
| }); | ||
| }); | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.