Repository navigation
ci: cut review workflow latency - #114
Conversation
Add per-PR concurrency with cancel-in-progress, skip docs/asset-only PRs and drafts, and ignore non-command comments. Cap ai_timeout and max output tokens so stuck runs fail fast.
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
Review: PR #114 — ci: cut review workflow latencyOverall the changes are reasonable and the YAML is valid. One functional regression and a couple of config mislabels worth addressing. Blocking1. Draft PRs will never be reviewed by The workflow only triggers on types: [opened, synchronize, ready_for_review, reopened]
Should fix2. In PR-Agent, 3. Any comment containing a slash (URLs, Minor / notes
The |
[Medium impact] The PR appears safe to merge; no new actionable issues were found.
|
PR Reviewer Guide 🔍(Review updated until commit e0c8e78)Here are some key observations to aid the review process:
✅ Resolved findings.github/workflows/pr-agent.yml:20Comment Filter
.github/workflows/opencode-review2.yaml:5-17Draft PR Gap The workflow only triggers on |
Trigger opencode-review on ready_for_review/reopened so draft PRs are reviewed once promoted. Use max_output_tokens (completion cap) instead of custom_model_max_tokens (total budget), skip same-model retries on timeout, and only treat comments starting with / as commands.
|
Reviewed the two workflow files at HEAD ( BlockingOrdinary comments can cancel an in-flight PR Agent review
Move concurrency:
group: pr-agent-${{ github.event.pull_request.number || github.event.issue.number }}-${{ github.event_name }}
cancel-in-progress: ${{ github.event_name == 'pull_request_target' }}The second form also prevents a push from cancelling a user-requested Minor
Everything else checks out: |
|
Persistent review updated to latest commit b97ea62 |
A skipped workflow run (non-command comment, draft PR) acquired the workflow-level group and cancelled an in-flight review. Skipped jobs do not acquire job-level concurrency groups.
|
Persistent review updated to latest commit ca51a46 |
The 15-minute cap cancelled a real review at the limit.
Dismissed because a newer commit was pushed; Greptile will re-review the current head.
|
Reviewed HEAD ( Should fix1. Job-level concurrency still cancels explicit commands — Now that
For user-requested commands that's probably not desired. Scope cancellation to push events: concurrency:
group: pr-agent-${{ github.event.pull_request.number || github.event.issue.number }}
cancel-in-progress: ${{ github.event_name == 'pull_request_target' }}(or append 2.
startsWith(github.event.comment.body, '/review') ||
startsWith(github.event.comment.body, '/describe') ||
startsWith(github.event.comment.body, '/improve') ||
startsWith(github.event.comment.body, '/ask')Notes / verify before merge
Looks correct
Verdict: non-blocking; items 1–2 are the ones I'd change before merge. |
|
Persistent review updated to latest commit b1fa9bb |
Only push events cancel in-flight work, and /oc comments stay with the opencode workflow.
Dismissed because a newer commit was pushed; Greptile will re-review the current head.
|
Persistent review updated to latest commit e0c8e78 |
User description
Speeds up the two PR review workflows.
cancel-in-progresskills stale runs on new pushes (both workflows).review_requested(intentional behavior change: requesting a review no longer re-triggers PR Agent).ai_timeout600s -> 180s, completion cap 16k tokens viamax_output_tokens, no same-model retry on timeout, jobtimeout-minutes: 15.opencode-review2now also triggers onready_for_review/reopened, so draft PRs still get reviewed once promoted.Kept
synchronizeon both: dropping it would make cancel-in-progress pointless and stop follow-up commits from being reviewed.Verified: both files parse as YAML and pass
prettier --check.PR Type
Enhancement, Other
Description
Add job-level per-PR concurrency with cancel-in-progress to both review workflows
Skip docs/asset-only PRs, draft PRs, and non-command comments
Fail fast:
ai_timeout180s,max_output_tokens16384, job timeouts 15/30 minTrigger
opencode-reviewonready_for_review/reopened; dropreview_requestedDiagram Walkthrough
File Walkthrough
opencode-review2.yaml
Speed up opencode-review with concurrency, filters, and timeout.github/workflows/opencode-review2.yaml
ready_for_reviewandreopenedto pull_request trigger typespaths-ignorefor**.md,public/images/**,public/flash/**concurrencyto job level withcancel-in-progress: true, keyed byPR number
ifguard and addtimeout-minutes: 30pr-agent.yml
Tighten PR Agent triggers, concurrency, and token limits.github/workflows/pr-agent.yml
review_requestedtrigger and addpaths-ignorefor docs/assetpaths
concurrencythat cancels only onpull_request_targetpushes
ifto skip bot senders, draft PRs, and comments not startingwith
/(excluding/oc,/opencode)custom_model_max_tokens131072 withmax_output_tokens16384,lower
ai_timeoutto 180s, disable same-model retry, addtimeout-minutes: 15