Skip to content

Check pull requests for a changeset or exemption - #998

Merged
keeganwitt merged 1 commit into
jest-community:mainfrom
keeganwitt:ci/require-pr-changeset
Nov 24, 2026
Merged

keeganwitt merged 1 commit into
jest-community:mainfrom
keeganwitt:ci/require-pr-changeset

Conversation

@keeganwitt

Copy link
Copy Markdown
Collaborator

What

Add a Changeset or exemption check for PRs targeting main or next. A PR passes with a new nonempty jest-extended changeset or the maintainer-applied no-changeset label. The check reruns when commits or labels change and reads the PR's changed files through the GitHub API.

Why

A pending changeset from another PR cannot satisfy the check. Contributors get immediate feedback when a release note is missing, and maintainers can explicitly exempt docs, routine version bumps, and internal maintenance.

Rollout

  1. Create the no-changeset repository label and apply it to this CI-only PR.
  2. After a successful run, add Changeset or exemption to the required status checks for main and any protected next branch. Apply the exemption label to generated Changesets version PRs as needed.

Verification

Validated the workflow's script against the actual diff from #995 and mocked GitHub API responses covering label additions and removals, pagination, valid bump types, empty or malformed changesets, and files already present on the base branch. Prettier and git diff --check passed.

@codecov

codecov Bot commented Nov 24, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 100.00%. Comparing base (b0a210b) to head (3ab2f4b).

Additional details and impacted files
@@            Coverage Diff            @@
##              main      #998   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files           80        80           
  Lines          910       910           
  Branches       354       338   -16     
=========================================
  Hits           910       910           

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@keeganwitt
keeganwitt merged commit f8fe1f6 into jest-community:main Nov 24, 2026
26 of 27 checks passed
@keeganwitt
keeganwitt deleted the ci/require-pr-changeset branch November 24, 2026 20:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant