Skip to content

fix(ci-status): filter own-checks by workflowName (consumer formats) (#536) - #539

Merged
don-petry merged 2 commits into
mainfrom
fix/own-check-by-workflowname
Jun 10, 2026
Merged

don-petry merged 2 commits into
mainfrom
fix/own-check-by-workflowname

Conversation

@don-petry

Copy link
Copy Markdown
Collaborator

Ring-1 (markets) found that a consumer's old pr-review check is named pr-review / review with workflowName: PR Review Agent — the job-name filter missed it, so a stale failed own-check made the agent skip clean consumer PRs as ci-failing.

Fix: filter any check whose workflowName starts with PR Review (the cascade workflows) — robust to any job-name format. Falls back to name patterns when workflowName is absent (unit tests), preserving the external Build / review guard. +2 tests (37/37). Promote via pr-review/stable. Part of #536.

…rmats) (#536)

Ring-1 (markets) surfaced that a consumer's OLD pr-review check appears as
'pr-review / review' with workflowName 'PR Review Agent' — not matched by the
job-name patterns, so a stale failed own-check classified the PR ci-failing and
the agent skipped it.

Add a robust primary signal: filter any check whose workflowName starts with
'PR Review' (the cascade workflows), regardless of job-name format. Falls back
to the existing name patterns when workflowName is absent (e.g. in unit tests),
so the external 'Build / review' guard still holds. +2 tests (consumer format
filtered; external 'Backend CI' still fails the gate).

Promote via pr-review/stable. Part of #536 · #497 · epic #495.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@don-petry
don-petry requested a review from a team as a code owner June 10, 2026 04:10
Copilot AI review requested due to automatic review settings June 10, 2026 04:10
@don-petry don-petry added the initiative Epic / initiative tracking issue label Jun 10, 2026
@chatgpt-codex-connector

Copy link
Copy Markdown

You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard.

@coderabbitai

coderabbitai Bot commented Jun 10, 2026 •

Copy link
Copy Markdown

Warning

Review limit reached

@don-petry, we couldn't start this review because you've reached your PR review rate limit.

More reviews will be available in 43 minutes and 16 seconds. Learn how PR review limits work.

Your organization has run out of usage credits. Purchase more in the billing tab.

⌛ How to resolve this issue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

We recommend that you space out your commits to avoid hitting the rate limit.

🚦 How do rate limits work?

CodeRabbit enforces hourly rate limits for each developer per organization.

Our paid plans include higher PR review limits than trial, open-source, and free plans. In all cases, reviews become available again over time. During sustained high-volume PR review activity, CodeRabbit may temporarily slow when the next review becomes available.

Please see our Fair Usage Limits Policy for further information.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: ASSERTIVE

Plan: Pro

Run ID: 8d1a6a8e-5b34-402f-a639-2b8bd5d35712

📥 Commits

Reviewing files that changed from the base of the PR and between 69e0da4 and da8fc29.

📒 Files selected for processing (2)
  • scripts/lib/ci-status.sh
  • tests/test_ci_status.bats
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch fix/own-check-by-workflowname

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@don-petry

Copy link
Copy Markdown
Collaborator Author

Dev-Lead — fix-bot-comment (no-changes)

Agent reasoning
Issues addressed: 0
Files changed: none
Skipped (informational): 1
  - "You have reached your Codex usage limits for code reviews" — this is a service quota notification, not a code finding. No specific files, line numbers, or issues were identified. Nothing to fix or resolve.
```
**CI state:** No Tier 1 blockers. Several checks are still `in_progress` (Analyze actions/python, SonarCloud, copilot-pull-request-reviewer, unit) but none have a failing conclusion. The PR is not blocked.

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request updates the CI status check logic in scripts/lib/ci-status.sh to filter out own-checks based on the workflowName property, and adds corresponding tests in tests/test_ci_status.bats. Feedback on the changes suggests narrowing down the regex pattern ^PR Review to prevent it from matching and incorrectly filtering out other external workflows that start with the same prefix.

Comment thread scripts/lib/ci-status.sh
# (#536: a consumer old check "pr-review / review" had workflowName
# "PR Review Agent"). Falls back to name patterns when the rollup does
# not expose workflowName.
($wf | test("^PR Review")) or

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

high

The prefix regex ^PR Review is too broad and will match any workflow name starting with those words, such as PR Reviewer, PR Review Gate, PR Review Lint, or PR Review CI. If a consumer has a workflow with such a name and it fails, it will be incorrectly filtered out as an "own-check", causing the agent to falsely treat the CI status as passing.

To prevent this, use a more precise regex that only matches the specific known cascade workflows (e.g., PR Review, PR Review Agent, PR Review Reusable, PR Review — Mention Trigger, PR Review Trigger).

Suggested change
($wf | test("^PR Review")) or
($wf | test("^PR Review( Agent| Reusable| — Mention Trigger| Trigger)?$")) or

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Updates CI gating logic to more reliably ignore the PR Review agent’s own check runs across varying consumer check-name formats, preventing stale “own-check” failures from causing clean PRs to be classified as ci-failing (issue #536 fan-out).

Changes:

  • Extend compute_ci_status own-check detection to treat any check with workflowName starting with PR Review as an own-check (with existing name-based fallbacks).
  • Add Bats helpers/tests covering the consumer legacy format (pr-review / review + workflowName: PR Review Agent) and a regression guard ensuring external failures still surface.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.

File Description
scripts/lib/ci-status.sh Enhances own-check filtering by adding a workflowName-prefix match for PR Review cascade workflows, while preserving existing name-pattern fallbacks.
tests/test_ci_status.bats Adds new rollup builders and regression tests to validate filtering behavior for legacy consumer check-name formats without swallowing external failing checks.

@sonarqubecloud

Copy link
Copy Markdown

@don-petry
don-petry merged commit 3a59ea4 into main Jun 10, 2026
33 of 40 checks passed
@don-petry
don-petry deleted the fix/own-check-by-workflowname branch June 10, 2026 04:12
don-petry added a commit that referenced this pull request Jun 12, 2026
…rmats) (#536) (#539)

Ring-1 (markets) surfaced that a consumer's OLD pr-review check appears as
'pr-review / review' with workflowName 'PR Review Agent' — not matched by the
job-name patterns, so a stale failed own-check classified the PR ci-failing and
the agent skipped it.

Add a robust primary signal: filter any check whose workflowName starts with
'PR Review' (the cascade workflows), regardless of job-name format. Falls back
to the existing name patterns when workflowName is absent (e.g. in unit tests),
so the external 'Build / review' guard still holds. +2 tests (consumer format
filtered; external 'Backend CI' still fails the gate).

Promote via pr-review/stable. Part of #536 · #497 · epic #495.

Co-authored-by: donpetry-bot <{}+donpetry-bot@users.noreply.github.com>
Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
don-petry added a commit that referenced this pull request Jun 14, 2026
…rmats) (#536) (#539)

Ring-1 (markets) surfaced that a consumer's OLD pr-review check appears as
'pr-review / review' with workflowName 'PR Review Agent' — not matched by the
job-name patterns, so a stale failed own-check classified the PR ci-failing and
the agent skipped it.

Add a robust primary signal: filter any check whose workflowName starts with
'PR Review' (the cascade workflows), regardless of job-name format. Falls back
to the existing name patterns when workflowName is absent (e.g. in unit tests),
so the external 'Build / review' guard still holds. +2 tests (consumer format
filtered; external 'Backend CI' still fails the gate).

Promote via pr-review/stable. Part of #536 · #497 · epic #495.

Co-authored-by: donpetry-bot <{}+donpetry-bot@users.noreply.github.com>
Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
don-petry added a commit that referenced this pull request Jun 18, 2026
…rmats) (#536) (#539)

Ring-1 (markets) surfaced that a consumer's OLD pr-review check appears as
'pr-review / review' with workflowName 'PR Review Agent' — not matched by the
job-name patterns, so a stale failed own-check classified the PR ci-failing and
the agent skipped it.

Add a robust primary signal: filter any check whose workflowName starts with
'PR Review' (the cascade workflows), regardless of job-name format. Falls back
to the existing name patterns when workflowName is absent (e.g. in unit tests),
so the external 'Build / review' guard still holds. +2 tests (consumer format
filtered; external 'Backend CI' still fails the gate).

Promote via pr-review/stable. Part of #536 · #497 · epic #495.

Co-authored-by: donpetry-bot <{}+donpetry-bot@users.noreply.github.com>
Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
don-petry added a commit that referenced this pull request Jun 25, 2026
…rmats) (#536) (#539)

Ring-1 (markets) surfaced that a consumer's OLD pr-review check appears as
'pr-review / review' with workflowName 'PR Review Agent' — not matched by the
job-name patterns, so a stale failed own-check classified the PR ci-failing and
the agent skipped it.

Add a robust primary signal: filter any check whose workflowName starts with
'PR Review' (the cascade workflows), regardless of job-name format. Falls back
to the existing name patterns when workflowName is absent (e.g. in unit tests),
so the external 'Build / review' guard still holds. +2 tests (consumer format
filtered; external 'Backend CI' still fails the gate).

Promote via pr-review/stable. Part of #536 · #497 · epic #495.

Co-authored-by: donpetry-bot <{}+donpetry-bot@users.noreply.github.com>
Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
don-petry added a commit that referenced this pull request Jun 25, 2026
…rmats) (#536) (#539)

Ring-1 (markets) surfaced that a consumer's OLD pr-review check appears as
'pr-review / review' with workflowName 'PR Review Agent' — not matched by the
job-name patterns, so a stale failed own-check classified the PR ci-failing and
the agent skipped it.

Add a robust primary signal: filter any check whose workflowName starts with
'PR Review' (the cascade workflows), regardless of job-name format. Falls back
to the existing name patterns when workflowName is absent (e.g. in unit tests),
so the external 'Build / review' guard still holds. +2 tests (consumer format
filtered; external 'Backend CI' still fails the gate).

Promote via pr-review/stable. Part of #536 · #497 · epic #495.

Co-authored-by: donpetry-bot <{}+donpetry-bot@users.noreply.github.com>
Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

initiative Epic / initiative tracking issue

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants