EasyP

Breaking checks in CI

Run the EasyP v1 breaking checker against a locally available Git baseline in CI.

The v1 breaking checker compares current .proto files with a Git revision. For a repository with schemas under proto, put this policy in the root easyp.yaml:

version: v1
breaking:
  baseline: git:origin/main
  categories: [FILE]
  ignore_unstable: false
  ignore: [proto/experimental]

FILE adds declaration-move checks; existing compatibility checks stay enabled. Other categories are unsupported. Set ignore_unstable: true only if you intend to skip packages with supported unstable version suffixes; see the breaking checker for the exact forms.

The ignore path is relative to the file defining the effective breaking section. In proto/easyp.yaml, the same directory would be ignore: [experimental]. Changing --root does not change that base.

Run the checks

From the repository root, with the dependency lock prepared:

easyp mod download
easyp lint --path proto
easyp breaking --path proto

mod download verifies the commits and content hashes recorded in protobuf.lock. The breaking checker uses each revision's own manifests, locks, and dependency context; the baseline may need additional downloads. Keep manifests and locks committed and resolve dependency updates before the CI check.

Make the baseline available

The baseline can be a branch, lightweight or annotated tag, full commit SHA, or another locally resolvable Git revision such as HEAD. Fetch the required refs and objects first. Bare branch names take precedence over identically named tags; use refs/tags/v1.2.0 to select a tag explicitly.

An explicit --against overrides breaking.baseline; without either, the default is master. Pass the ref directly to the flag, without git: or git-ref=.

After provisioning a v1-capable EasyP binary, these GitHub Actions steps compare with the pull request's base commit:

- uses: actions/checkout@v4
  with:
    fetch-depth: 0
- name: Check protobuf compatibility
  env:
    BASE_REF: ${{ github.event.pull_request.base.sha }}
  run: easyp breaking --path proto --against "$BASE_REF"

Use this snippet in a pull_request job. Full history makes the baseline available in ordinary PR checkouts; a missing revision fails the check instead of selecting a different baseline. See the complete GitHub Actions workflow.

On this page