Git LFS problem ? Error 255
Dear all,I’m encountering problems in pushing my model.pkl on my space.Here is the error message after I tried push.gitbatchrequest:git@hf.co: Permission denied (publickey).: exit status 255Uploading LFS objects:   0% (0/1), 0 B | 0 B/s, done.error: failed to push some refs to 'hf.co:spaces/DaijobuAI/spaceNameI am using SSH authentification. If I try  ssh -Tgit@hf.co, I’m authenticated without problem:Hi DaijobuAI, welcome to Hugging Face.All my previous pushes (without the model) worked.I tried this solution :Git LFS fail for Spaces with Github Workflow - #7 by ClatonhThe model.pkl file is removed and pushing works again. If I copy the file again, it fails again.On the first try of pushing my model, I got this error:Remote “origin” does not support the Git LFS locking API. Consider disabling it with:$ git config lfs.https://hf.co/spaces/DaijobuAI/spaceName.git/info/lfs.locksverifyfalseAnd I run the command.Here are the other commands I tried:$ git lfs track .\model.pkl“model.pkl” already supported$ git lfs installUpdated Git hooks.Git LFS initialized.I also tried to restart from scratch with a fresh space/depo.The file is about 110M, I am using VSCode on Windows 11 and the commands are run in VSCode Terminal. I updated Git to its latest version (2.43.0).Any clue to help me ?Thanks !DaijEdited to sanitize
2024-01-05T19:09:47Z
hi@DaijobuAI,Please double check if you haven’t committed the.pklfile to your git repot without LFS, this is a very common error.
2024-01-06T10:28:14Z
Hi Radames,Thanks for your help !The .pkl file is commited with LFS. Here is thegit showresponsecommit 9f86def6ed8c75e55f12b8fadd7c0261dc292f7d (HEAD → main)Author: gotDaijobu141064187+gotDaijobu@users.noreply.github.comDate:   Fri Jan 5 18:20:51 2024 +0100modeldiff --git a/model.pkl b/model.pklnew file mode 100644index 0000000…19010b0— /dev/null+++ b/model.pkl@@ -0,0 +1,3 @@+version http[s]://git-lfs.github.com/spec/v1+oid sha256:2a62e5f45a23cb41bcfbad5d08f3affabb120842d5b66f9afc429a4ac691d91b+size 114828705Also, the response togit-lfs envEndpoint=https://hf.co/spaces/DaijobuAI/spaceName.git/info/lfs(auth=basic)SSH=git@hf.co:spaces/DaijobuAI/spaceNameLocalWorkingDir=C:\Sites\spaceNameLocalGitDir=C:\Sites\spaceName.gitLocalGitStorageDir=C:\Sites\spaceName.gitLocalMediaDir=C:\Sites\spaceName.git\lfs\objectsLocalReferenceDirs=TempDir=C:\Sites\spaceName.git\lfs\tmpConcurrentTransfers=8TusTransfers=falseBasicTransfersOnly=falseSkipDownloadErrors=falseFetchRecentAlways=falseFetchRecentRefsDays=7FetchRecentCommitsDays=0FetchRecentRefsIncludeRemotes=truePruneOffsetDays=3PruneVerifyRemoteAlways=falsePruneRemoteName=originLfsStorageDir=C:\Sites\spaceName.git\lfsAccessDownload=basicAccessUpload=basicDownloadTransfers=basic,lfs-standalone-file,sshUploadTransfers=basic,lfs-standalone-file,sshGIT_LFS_PATH=C:\Program Files\Git LFSGIT_ASKPASS=c:\Users\DaijobuAI\AppData\Local\Programs\Microsoft VS Code\resources\app\extensions\git\dist\askpass.shgit config filter.lfs.process = “git-lfs filter-process”git config filter.lfs.smudge = “git-lfs smudge – %f”git config filter.lfs.clean = “git-lfs clean – %f”It really seem that the authentification problem is only with git-lfs, but I can’t figure why. My guess - from a lot of readings in the past 2 days - is that it has something to do with the terminal’s ssh-agent but I can’t find how to fix it.Alternatively, I tried to used spaces over https instead of ssh but I couldn’t make it work. In my config file, the remote should be:[remote “origin”]url =https://<USERNAME>:<TOKEN>@huggingface.co/spaces/DaijobuAI/spaceNameWhere Username is DaijobuAI and token an access token generated here :Hugging Face – The AI community building the future.. No quotes.Is that right ? When I do, I get a “Repository not found” error TTThanks again for your help.Daij