Skip to content

Commit 08d197f

Browse files
IGNITE-28821 Protected Classes CI check: report as warning instead of failing the PR build (#13279)
## What The `Protected Classes` workflow no longer fails the PR build when a change touches `@Order`-annotated (protected) classes. Instead it publishes a separate, non-blocking check `Rolling upgrade compatibility` with the `neutral` conclusion, keeping the existing PR comment and `compatibility` label. ## Why A hard failure (`exit 1`) red-flagged PRs even for intentional, compatible changes, creating friction (the check was disabled manually on 2026-05-27 for this reason). A non-blocking advisory check surfaces the rolling-upgrade risk for reviewer attention without failing the build. ## Why `neutral` (and not `action_required`) GitHub's Checks API has no dedicated "warning" conclusion. `action_required` is intended for GitHub Apps that attach a remediation action: it renders as a red ✕ with a "Resolve" button in the Checks tab and is dropped from the PR merge-box rollup entirely (so the warning becomes invisible there). `neutral` is the proper primitive for an advisory result — it shows in its own non-blocking "neutral" group in the merge box and as a grey marker in the Checks tab, and it never blocks merging. ## Notes - The `Rolling Upgrade check` job now always succeeds. - The new check is non-blocking unless added to required status checks. - `checks: write` permission added for the Checks API call. Jira: https://issues.apache.org/jira/browse/IGNITE-28821 🤖 Generated with [Claude Code](https://claude.com/claude-code) --------- Co-authored-by: Claude Opus 4.8 <noreply@anthropic.com>
1 parent a90f44a commit 08d197f

1 file changed

Lines changed: 25 additions & 3 deletions

File tree

.github/workflows/check-protected-classes.yml

Lines changed: 25 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,7 @@ jobs:
2828
permissions:
2929
issues: write
3030
pull-requests: write
31+
checks: write
3132
steps:
3233
- uses: actions/checkout@v6
3334
with:
@@ -123,7 +124,28 @@ jobs:
123124
labels: ['compatibility'],
124125
});
125126
126-
- name: Fail on affected check
127+
- name: Warning check on affected
127128
if: steps.check.outputs.affected == 'true'
128-
run: |
129-
exit 1
129+
uses: actions/github-script@v8
130+
with:
131+
script: |
132+
const fs = require('fs');
133+
const hits = fs.readFileSync('/tmp/protected-hits.txt', 'utf8').trim();
134+
await github.rest.checks.create({
135+
owner: context.repo.owner,
136+
repo: context.repo.repo,
137+
name: 'Rolling upgrade compatibility',
138+
head_sha: context.payload.pull_request.head.sha,
139+
status: 'completed',
140+
conclusion: 'neutral',
141+
output: {
142+
title: 'Possible compatibility issues',
143+
summary: [
144+
'This PR modifies protected classes (with **Order** annotation).',
145+
'Changes to these classes can break rolling upgrade compatibility.',
146+
'',
147+
'**Affected files:**',
148+
hits.split('\n').map(f => '- `' + f.trim() + '`').join('\n'),
149+
].join('\n'),
150+
},
151+
});

0 commit comments

Comments
 (0)