Repository navigation
feat: implement issue #1568 — status=rate-limited is emitted for non-quota holds (reason=blocked) — retires the token half #461 deliberately deferred #1798
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
8e2a8eb
6e5df51
f94d0f4
2b1c785
2da0a35
39c0168
d2c62f5
ba97de5
4528870
a979393
4acb763
9ce3755
7e4dcc2
7d95520
8c3dafb
0a32894
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 | ||||
|---|---|---|---|---|---|---|
|
|
@@ -337,12 +337,15 @@ scan_pr_for_rate_limits() { | |||||
| fi | ||||||
| fi | ||||||
|
|
||||||
| # ── Check for retryable fix-reviews rate-limited markers on HEAD SHA ─────── | ||||||
| # ── Check for retryable fix-reviews hold markers on HEAD SHA ─────────────── | ||||||
| # Only intents that can reconstruct their full context at retry time. | ||||||
| # on-mention and fix-bot-comment are excluded: their USER_INSTRUCTION/COMMENT_BODY | ||||||
| # cannot be recovered from the PR's current state. | ||||||
| # Both hold tokens are retryable (#1568): status=rate-limited (genuine quota) and | ||||||
| # status=blocked (non-quota PR blockers). Matching both keeps re-dispatch behaviour | ||||||
| # unchanged and leaves pre-#1568 status=rate-limited blocked markers parseable. | ||||||
| for intent_type in $RETRYABLE_REVIEW_INTENTS; do | ||||||
| local reviews_pattern="${REVIEWS_MARKER_PREFIX}${pr_number} sha=${head_sha} intent=${intent_type} status=rate-limited" | ||||||
| local reviews_pattern="${REVIEWS_MARKER_PREFIX}${pr_number} sha=${head_sha} intent=${intent_type} status=(rate-limited|blocked)" | ||||||
|
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. Suggestion: The broadened pattern can match multiple hold comments, but reset extraction still uses the oldest ( Assessment: 🟠 Prompt for AI Agent 🤖This is a comment left during a code review.
**Path:** scripts/dev-lead-retry.sh
**Line:** 348:348
**Comment:**
*Logic Error: The broadened pattern can match multiple hold comments, but reset extraction still uses the oldest (`.[0]`); an old future reset can suppress a newer expired hold.
Validate the correctness of the flagged issue. If correct, How can I resolve this? If you propose a fix, implement it and please make it concise.
Once fix is implemented, also check other comments on the same PR, and ask user if the user wants to fix the rest of the comments as well. if said yes, then fetch all the comments validate the correctness and implement a minimal fix |
||||||
| if echo "$comments_json" | jq -e --arg pat "$reviews_pattern" '[.[] | select(. | test($pat))] | length > 0' >/dev/null 2>&1; then | ||||||
|
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. Avoid using
Suggested change
References
|
||||||
| local reset_time | ||||||
|
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. Suggestion: Reset time comes from the oldest matching marker, so a stale future reset can suppress retry even when the newest hold has already expired. [logic error] Assessment: 🟠 Prompt for AI Agent 🤖This is a comment left during a code review.
**Path:** scripts/dev-lead-retry.sh
**Line:** 350:354
**Comment:**
*Logic Error: Reset time comes from the oldest matching marker, so a stale future reset can suppress retry even when the newest hold has already expired.
Validate the correctness of the flagged issue. If correct, How can I resolve this? If you propose a fix, implement it and please make it concise.
Once fix is implemented, also check other comments on the same PR, and ask user if the user wants to fix the rest of the comments as well. if said yes, then fetch all the comments validate the correctness and implement a minimal fix |
||||||
| reset_time=$(echo "$comments_json" | jq -r \ | ||||||
|
|
||||||
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.
🎯 Functional Correctness | 🟡 Minor | ⚡ Quick win
Match legacy blocked markers during deduplication.
When
reason=blocked, this pattern only matchesstatus=blocked. A pre-#1568 blocker marker hasstatus=rate-limited reason=blocked, sohad_prior_rl_markerbecomes false and the next blocked cycle posts a duplicate visible acknowledgment. Matchreason=blockedwith eitherstatus=blockedor legacystatus=rate-limited.🤖 Prompt for AI Agents