Error during git lfs fetch: "Git LFS is disabled for this repository"
Reminder
- [x] I have read the above rules and searched the existing issues.
System Info
System Info*
- OS: Windows 10 Home (64-bit)
- Git Client: Git Bash (MINGW64)
- Git Version: 2.45.2.windows.1
- Git LFS Version: git-lfs/3.5.1 (GitHub; windows amd64; go 1.21.7; git e237bb3a)
Note: Cannot provide llamafactory-cli env output as the llama-factory Python package is not installed yet. The issue occurs during basic git lfs fetch operations against the remote repository before package installation.
Reproduction
- Add the LLaMA-Factory repository as a remote (e.g., named
upstream2):git remote add upstream2 https://github.com/hiyouga/LLaMA-Factory.git git fetch upstream2 # Fetching Git history succeeds - Attempt to fetch the associated LFS objects:
git lfs fetch upstream2 --all - The
git lfs fetchcommand fails with the following error message:fetch: 18 objects found, done. fetch: Fetching all references... batch response: Git LFS is disabled for this repository. error: failed to fetch some objects from 'https://github.com/hiyouga/LLaMA-Factory.git/info/lfs'
Others
I am trying to fetch the LFS objects associated with the repository's history. This is necessary for creating a full local mirror or when attempting to push the LFS-dependent history to another Git remote (like a private GitLab instance) which requires the actual LFS objects for integrity checks.
The Git history itself seems to contain LFS pointers (implying LFS was used previously), but fetching the objects now fails with the "LFS is disabled" message from the GitHub LFS endpoint for this repository.
Could you please clarify the current status of Git LFS for the hiyouga/LLaMA-Factory repository?
- Is Git LFS intentionally disabled?
- If so, is this due to reasons like GitHub LFS quota limits?
- Is there an alternative way to obtain the necessary LFS objects?
- If it's temporary, is there an estimated time for when LFS might be re-enabled?
Any information or guidance would be greatly appreciated. Thank you for your great work on LLaMA-Factory!
try git lfs install
Hi @hiyouga,
Thank you for the suggestion.
I ran git lfs install as you recommended, and it completed successfully, initializing LFS for my local repository:
$ git lfs install
Updated Git hooks.
Git LFS initialized.
However, this unfortunately did not resolve the underlying issue. The problem seems to be specifically with fetching the LFS objects from the hiyouga/LLaMA-Factory remote repository.
After running git lfs install, I tried to push a branch (which contains history referencing LFS objects from your repository) to my own private remote (origin). The push failed because the LFS objects are not present locally, as expected if they cannot be fetched from the source:
$ git push origin <my-branch-name>
# [...] (omitting potential lock messages)
Uploading LFS objects: 0% (0/17), 0 B | 0 B/s, done.
Unable to find source for object 2332abe0be6cdf177f8cfc746952c6827068d5a809ff49a6322d508fd6e84d34 (try running `git lfs fetch --all`)
error: failed to push some refs to '<my-private-remote-url>'
Following the error message's advice, I then tried git lfs fetch --all again against the remote pointing to hiyouga/LLaMA-Factory. It still fails with the exact same error as before, indicating LFS is disabled for your repository on GitHub's side:
$ git lfs fetch <remote-pointing-to-llama-factory> --all
fetch: 18 objects found, done.
fetch: Fetching all references...
batch response: Git LFS is disabled for this repository.
error: failed to fetch some objects from 'https://github.com/hiyouga/LLaMA-Factory.git/info/lfs'
So, it seems the core problem persists: the LFS objects cannot be downloaded from https://github.com/hiyouga/LLaMA-Factory.git because the LFS service appears to be disabled for the repository according to the GitHub LFS endpoint.
Could you please double-check the Git LFS status for the repository? Any further guidance would be appreciated.
Thanks again!
same problem
same
그냥 푸쉬하려는 깃랩 설정에서 lfs기능을 해제하면 해결됩니다. 감사합니다.