Files
datawave/.github/workflows/require-labels.yml
MoriartyandClaude Sonnet 5 ad847bd65b Bump actions/github-script and actions/cache to Node 24 runtimes (#3702)
## Summary
- `actions/github-script@v7` and `actions/cache@v4` both still target
the deprecated Node.js 20 runtime, which GitHub now force-runs on Node
24 and flags with a warning annotation on every workflow run (seen
recently on PR #3683's checks).
- Bump both to their minimum Node 24-native releases:
`actions/github-script@v8` and `actions/cache@v5`. Neither introduces
breaking changes relevant to our usage (v8/v5 changelogs are Node
runtime bumps only; v9 of github-script would add breaking API changes
we don't need).

## Test plan
- [x] Confirm the `require-labels.yml` and `compose-tests.yml` workflows
run green on this PR
- [x] Confirm the Node.js 20 deprecation warning annotation no longer
appears on the check runs

Co-authored-by: Claude Sonnet 5 <[email protected]>
2026-07-20 17:22:24 +00:00

27 lines
830 B
YAML

name: Require PR Labels
on:
pull_request:
types: [opened, labeled, unlabeled, synchronize, reopened]
jobs:
require-label:
runs-on: ubuntu-latest
steps:
- name: Check required labels
uses: actions/github-script@v8
with:
script: |
const requiredLabels = ["Integration Tested", "no-downstream-effects", "cherry-pick"];
const labels = context.payload.pull_request.labels.map(label => label.name);
const hasRequired = requiredLabels.some(l => labels.includes(l));
if (!hasRequired) {
core.setFailed(
`This PR must have at least one of the required labels: ${requiredLabels.join(", ")}`
);
} else {
core.info("PR has at least one required label ✅");
}