-
Notifications
You must be signed in to change notification settings - Fork 1.1k
test(hygiene): fail on duplicate test basenames, and close out the 429 unit #3527
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
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -55,3 +55,35 @@ resource pressure that was timing the job out. Rebasing onto it turned macOS gre | |
|
|
||
| **Rule:** when a rerun fails the same way twice, stop rerunning and check whether the base | ||
| branch already carries the fix. A stale branch point is a cause, not a flake. | ||
|
|
||
| ## A merge I should not have made | ||
|
|
||
| I merged #3523 on `gh pr checks` reporting five passes. The test and macOS jobs were still | ||
| **queued** — that command lists only the check runs GitHub has reported so far, so a partial set | ||
| reads exactly like a complete green one. A count of passes is not a statement that anything | ||
| finished. | ||
|
|
||
| The post-merge run on `dev` then showed `ci failure`, which was a genuinely alarming way to find | ||
| out. It turned out to be cancellation by the maintainer's next merge two minutes later, not a | ||
| real failure — every job read `cancelled`, not `failure`. | ||
|
|
||
| **Rule:** verify with the check-runs API and require zero `null` conclusions, not a pass count: | ||
|
|
||
| ```bash | ||
| gh api repos/<owner>/<repo>/commits/<sha>/check-runs \ | ||
| --jq '[.check_runs[] | .conclusion] | group_by(.) | map({(.[0]//"null"): length}) | add' | ||
|
Comment on lines
+70
to
+74
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
When some workflow jobs have not created check runs yet—the exact state described above—this query sees only the existing Useful? React with 👍 / 👎.
Comment on lines
+73
to
+74
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🎯 Functional Correctness | 🟠 Major | ⚡ Quick win 🔎 Supported by static analysis🤖 get_repo_knowledge executed:
Length of output: 15795 🏁 Script executed: #!/bin/bash
set -eu
file='devlog/_fin/260905_always_on_429_failover/091_post_merge_audit.md'
printf '%s\n' '--- target file ---'
cat -n "$file" | sed -n '55,90p'
printf '%s\n' '--- nearby repository guidance ---'
find devlog -maxdepth 3 -type f \( -iname '*readme*' -o -iname '*contribut*' -o -iname '*review*' \) -print
rg -n --glob '!*node_modules*' 'check-runs|gh api.*paginate|--slurp' devlog README.md .github 2>/dev/null | head -80Repository: lidge-jun/opencodex Length of output: 9624 Paginate the check-runs query before using the null check. At Use 🤖 Prompt for AI AgentsSource: MCP tools |
||
| ``` | ||
|
|
||
| A clean result looks like `{"skipped":3,"success":24}` — no `null` key at all. | ||
|
|
||
| The near-miss paid for itself: sweeping `dev` afterwards found a real defect. #3511 and #3513 | ||
| landed concurrently, one moving `anthropic-quorum-cache.test.ts` into `tests/routing/` and the | ||
| other placing a copy in `tests/adapters/anthropic/`. Different paths, so git saw no conflict and | ||
| both survived — a byte-identical duplicate running the same six tests twice. Removed in #3526. | ||
|
|
||
| ## Reviewer credit | ||
|
|
||
| CodeRabbit caught that the first Claude Code guide assertion was too weak: requiring the intro to | ||
| mention `429` and carry emphasis is satisfied by the **original stale sentence**, so a revert | ||
| would have passed. Each locale now bans the phrase pattern that actually attributed failover to | ||
| the pool, and the test was driven red against the restored sentence before committing. | ||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
📐 Maintainability & Code Quality | 🟡 Minor | ⚡ Quick win
Align the cross-file audit claim.
091_post_merge_audit.mddoes not identify PRs#3499,#3512,#3517, or#3520in the supplied file. This makes “All are recorded in091” inaccurate. Add those records to091_post_merge_audit.md, or narrow this sentence to the findings and pull requests that it covers.🤖 Prompt for AI Agents