The LFS clean filter hashes and stores each large file when it enters the index. On a job that adds or checks out many big files, this serial work can dominate runtime and look like a stall.
What this error means
A commit or checkout step in CI takes far longer than expected while LFS processes files, with little log output between "Filtering content" lines.
git-lfs
Filtering content: 100% (18/40), 3.2 GiB | 6.0 MiB/s
# job appears stalled while the clean filter hashes remaining large files
Common causes
Many large files processed one at a time
The clean filter runs per file; a large batch of big objects serializes the hashing and storage work.
No object cache between runs
Without a cached .git/lfs, every run re-fetches and re-processes the same objects, multiplying the cost.
How to fix it
Cache LFS objects and raise concurrency
Cache .git/lfs so processed objects persist across runs.
Raise lfs.concurrenttransfers so fetches parallelize.
Limit which jobs enable LFS so only those that need it pay the cost.
CI checkouts are shallow and detached by default, which changes the answer this command gives you. Commands that read history, branch names, or tags need the checkout configured for it.
.github/workflows/ci.yml
- uses:actions/checkout@v4with:fetch-depth:0 # history, tags, and git describe all need this- run:|git rev-parse --is-shallow-repository # expect falsegit rev-parse --abbrev-ref HEAD # prints HEAD when detached
How to prevent it
Cache .git/lfs between CI runs.
Scope LFS fetches with include/exclude patterns.
Keep LFS enabled only on jobs that read the binaries.
Frequently asked questions
What causes Git LFS clean filter slow / stalls commit in CI?
There are 2 common causes: many large files processed one at a time and no object cache between runs. The clean filter runs per file; a large batch of big objects serializes the hashing and storage work.
How do I fix Git LFS clean filter slow / stalls commit in CI?
There are 2 fixes depending on which cause you have: cache lfs objects and raise concurrency and fetch only what the job needs. Work through them in order, since the first is the most common.
What does Git LFS clean filter slow / stalls commit in CI actually mean?
A commit or checkout step in CI takes far longer than expected while LFS processes files, with little log output between "Filtering content" lines.
How do I stop Git LFS clean filter slow / stalls commit in CI happening again?
Cache .git/lfs between CI runs. The prevention section lists 3 changes that keep it from recurring.