Skip to content

Run Bite's free check as a GitHub pull request check - #33

Merged
connabyss merged 1 commit into
mainfrom
claude/project-thread-siupu2
Oct 30, 2026
Merged

connabyss merged 1 commit into
mainfrom
claude/project-thread-siupu2

Conversation

@connabyss

Copy link
Copy Markdown
Owner

Requested by CH · project thread

Any repo can now add a few lines and get Bite's free check on every pull request, as a normal pass/fail check.

What's in it

  • action.yml (composite action): installs Bite with pipx, counts the PR's commits (base..HEAD, no merges, max 20), and runs bite --free on them. It fails when a commit's change can be taken out and the tests still pass. The free report goes on the job's summary page. Inputs: args (default --all), max-commits (20), fail-on-gap (true).
  • Bite is installed on its own with pipx, not into the project's Python, so the project's tests import each copy's code (this avoids the trap in Free check is fooled when the project is pip-installed #28).
  • .github/workflows/bite.yml: tries the action on Bite's own PRs (Ubuntu only). It is not one of the 6 required checks.
  • README: a short "Run it on every pull request" section with the lines to copy.
  • selftest: one check that action.yml runs the free pass and the README shows how to add it.

Checked locally

  • On Bite's last 4 commits: 2 code commits, both guarded, step exits 0.
  • On a tiny repo with an untested "Fix clamp" commit: flagged unguarded, step exits 1 with the error line and the summary.
  • python -m pytest: 62/62 selftest checks pass.

PR comments are a later step.

AI helped write this (Claude Code); the commit carries an Assisted-by: line.


Generated by Claude Code

action.yml is a composite action: it installs Bite with pipx (on its own,
so the project's tests import each copy's code, not an installed Bite),
counts the pull request's commits, and runs bite --free on them. The
check fails when a commit's change can be taken out and the tests still
pass, and the free report goes on the job's summary page. Inputs: args
(default --all), max-commits (20) and fail-on-gap (true).

.github/workflows/bite.yml tries it on Bite's own pull requests. The
README shows the few lines another repo adds, and the selftest checks
that both stay in place.

Assisted-by: Claude Code
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_0175Q8iCvMrHYVQGhoif8oRX
@connabyss connabyss self-assigned this Oct 30, 2026
@connabyss
connabyss merged commit 0affc86 into main Oct 30, 2026
7 checks passed
@connabyss
connabyss deleted the claude/project-thread-siupu2 branch October 30, 2026 04:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant