rtyley / bfg-repo-cleaner

Removes large or troublesome blobs like git-filter-branch does, but faster. And written in Scala
https://rtyley.github.io/bfg-repo-cleaner/
GNU General Public License v3.0
10.86k stars 535 forks source link

invalid id error on misssing LFS objects #353

Open dwsail opened 4 years ago

dwsail commented 4 years ago

When trying to remove a specific version of a Git LFS file by its OID, I always get the following error:

java -jar bfg-1.13.0.jar -bi del_ids my_repo_folder
Error: Option --strip-blobs-with-ids failed when given 'del_ids'. MainException: class org.eclipse.jgit.errors.InvalidObjectIdException(Invalid id: 3cc47cf37608f1e833aaadfd7ad2df6adc2e13d11b29f3f026c260f6a82cf0d7

The file del_ids just consists of a single line where the OID (3cc47cf...blahblahblah) is listed which I wanted to remove. If I do a git log -p -S 3cc47cf37608f1e833aaadfd7ad2df6adc2e13d11b29f3f026c260f6a82cf0d7 --all I get the commits listed where this file was added and later removed (replaced by a newer version).

I'm desperately trying to get a few Git LFS OIDs out of the history of my git repo to have it clean again.

dangbert commented 3 years ago

I am also experiencing this issue when trying to delete a list of files from a folder as in this example