Skip to content
Latchkey

pre-commit SKIP env silently skips hooks in CI

pre-commit reads the SKIP environment variable and skips any hook id listed in it. A SKIP value set at the workflow or org level can silently disable the hooks you rely on in CI.

What this error means

A specific hook prints "Skipped" while others run, and the job passes. The hook is not disabled in the config; a SKIP env value names it.

pre-commit
flake8...............................................(SKIP=flake8)Skipped
black....................................................................Passed

Common causes

A SKIP value is set in the environment

A workflow env, a job env, or an organization-level variable sets SKIP to a comma-separated list of hook ids, and pre-commit honours it.

A debugging SKIP was left in place

Someone set SKIP to bypass a hook temporarily and the value persisted into CI.

How to fix it

Unset or correct SKIP in CI

  1. Search workflow and org env for a SKIP value.
  2. Remove it, or narrow it to hooks you truly want skipped.
  3. Re-run and confirm the previously skipped hook now executes.
.github/workflows/ci.yml
env:
  SKIP: ""

Gate on the SKIP value explicitly

Fail the job if a critical hook id appears in SKIP so it cannot be silently bypassed.

.github/workflows/ci.yml
- run: |
    case ",$SKIP," in *,flake8,*) echo "flake8 must not be skipped"; exit 1;; esac

How to prevent it

  • Do not set SKIP at the workflow or org level.
  • Audit env for leftover SKIP values that disable gates.
  • Fail CI if a required hook id is present in SKIP.

Related guides

Tired of flaky CI? Latchkey auto-heals failed jobs and retries them for you. Start free →