Skip to content

request: Add Reusable copyright boilerplate check CI action #1069

Description

@jaiakash

Why we need it?

Every Kubeflow repo needs the same Apache 2.0 header check, and right now each one vendors its own copy of boilerplate.py from this repo. That copy immediately drifts — each repo runs its own ruff/lint config over it, so the "downloaded from kubeflow/testing @ " comment stops being verifiable the moment the file lands.

Creating this issue to add a reusable composite action (.github/actions/verify-boilerplate) that runs the boilerplate check against a repo's changed files, so repos can call it directly instead of vendoring and maintaining a divergent script.

Already vendored / being vendored in:

Source of truth: hack/boilerplate/boilerplate.py in this repo.

Requirement

  • Composite action wrapping hack/boilerplate/boilerplate.py, with the script sourced
    from this repo so callers never vendor it.
  • Input for the base ref to diff against, defaulting to the PR base branch
    (github.base_ref), so only changed/new files are checked.
  • Input for the boilerplate template directory, for repos that keep custom templates.
  • Sets up Python itself so callers don't each add a setup-python step.
  • Non-zero exit with the existing remediation output on failure.

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions