Unable to git push LFS files to remote branch, received error: GH008 instead

I normally able to push LFS object by using git push command in the cli. However, I got error: GH008

Uploading LFS objects: 100% (2/2), 199 KB | 0 B/s, done.
Enumerating objects: 18, done.
Counting objects: 100% (16/16), done.
Delta compression using up to 12 threads
Compressing objects: 100% (12/12), done.
Writing objects: 100% (12/12), 1.42 KiB | 1.42 MiB/s, done.
Total 12 (delta 6), reused 0 (delta 0)
remote: Resolving deltas: 100% (6/6), completed with 4 local objects.
remote: error: GH008: Your push referenced at least 2 unknown Git LFS objects:
remote:     fec397bef974389e09f46f8b0ae49528bc1f9fe8e2b5be986aa159692a431186
remote:     0d7adaaa8f18f4b90ddb2b4c70e1ba6520728d2e0701260ac0500c93c19b0dce
remote: Try to push them with 'git lfs push --all'.
To github.com:username/repo-name.git
 ! [remote rejected]   master -> master (pre-receive hook declined)
error: failed to push some refs to 'git@github.com:{username}/{repo-name}.git'

I am not able to push to remote master branch from my local.

I have also run git lfs push --all and it works fine, the CLI showed that all files can be uploaded successfully

I am assuming that there’s something wrong with either git LFS or NLM because my teammate also faced the same issue and the Forestry CMS app is not pushing the uploaded image to git.

Please help

1 Like

Hi @shafiemukhre

This is not (to my understanding) a Netlify issue. Here’s a (hopefully handy) blog post from GitHub Git LFS integrity check | GitHub Changelog. It seems you are referencing (local) files that do not exist.

1 Like

I just want to add that I’m receiving this issue today as well. Unclear why.

1 Like

Same here. Seems like an odd coincidence that it would start happening for all three of us on the same day.

Hi folks!

Thanks so much for sharing this with us. Sorry to hear you are encountering obstacles.

I have notified the Support team, and we just need a bit more information to look into this further. Would you please share the following information with us?

  1. Your netlify site name
  2. The contents of the following two files:
    • .gitattributes
    • .lfsconfig
  3. Any relevant screenshots or troublshooting steps you have taken

Thank you!
Hillary

Thanks @hillary

site-name: chips-and-bits

git attributes

static/audio/*.mp3 filter=lfs diff=lfs merge=lfs -text
static/images/*.{jpg,png} filter=lfs diff=lfs merge=lfs -text

lfs config

[lfs]
	url = https://5645193a-78af-4341-8aa4-ba6d2dafe0c6.netlify.app/.netlify/large-media

I have tried repushing all objects, removing and re-adding all files.

I also tried reverting the branch and pushing without the file, no complaints from Github.

This is specifically to a Github repo and it’s when trying to add a new file to track (which I use Netlify las for).

Site name:

happyhourfm

.gitattributes:

public/media/* filter=lfs diff=lfs merge=lfs -text

.lfsconfig:

[lfs]
	url = https://844123f3-5a38-4a31-b03b-b2e596b5a244.netlify.app/.netlify/large-media

Steps taken:

Same as @furiouskj. Removing, re-addding, pushing, force pushing. Including reinstalling Netlify CLI, and going through the whole setup process again. Still broken.

Same error here

sitename: mamazilla

.gitattributes

*.jpg filter=lfs diff=lfs merge=lfs -text

.lsconfig:

[lfs]
	url = https://40f7c62a-a6ac-4a4d-b26e-bbbd9eb5b840.netlify.app/.netlify/large-media

Hello @shafiemukhre, @furiouskj, @happyhourdotfm, and @idroulia. More information would help us to troubleshoot this. In @shafiemukhre’s case, there is an open support ticket where I have asked for this information already.

The information is the output of these commands:

netlify status
netlify lm:info
git lfs ls-files
GIT_TRACE=true GIT_CURL_VERBOSE=true git lfs push --all origin

Note, that last command’s output might contain information that shouldn’t be posted publicly.

You can post that information publicly if you check it to confirm it doesn’t contain secure information. You can also private message (PM) that to one of our support staff if you prefer. I’ve confirmed that PMs are enabled for your community logins. Please keep in mind that only one person can see the PM and this will likely mean a slower reply than posting the information publicly. Please feel free to reply to however you prefer though.

 $ netlify lm:info                             2883ms  Mon Aug  9 12:42:38 2021
  ✔ Checking Git version [2.31.0]
  ✔ Checking Git LFS version [2.7.0]
  ✔ Checking Git LFS filters
  ✖ Checking Netlify's Git Credentials version
    → Invalid Netlify's Git Credential version 0.1.9. Please update to version 0.1.10 or above by ru

Fixed it with:

brew tap netlify/git-credential-netlify
brew install git-credential-netlify
netlify lm:install

I’m not even sure if the brew commands were needed.

Thanks!

It started working for me this morning magically. I haven’t done anything lfs related so I assumed it was something from netlify’s side

Thanks @idroulia for sharing! It’s working for me as well just this morning without me doing anything. So, I’m assuming this was issue from the Netlify side and they resolved it over the weekend. So, thank you Netlify team!

Hi all,
Our backend team did dig into this over the weekend, but didn’t see anything broken so didn’t ship a fix. Github’s status page doesn’t mention any outages. We were going to request a bit more info (the details Luke asked for here: Unable to git push LFS files to remote branch, received error: GH008 instead - #11 by luke) from folks in this thread but the issue now seems to be resolved? Please let us know if that’s not the case for you!

1 Like

About the comments above, we didn’t make any changes on our side and the error itself was coming from GitHub not from Netlify. My best guess is that GitHub fixed the issue as nothing changed here.

2 Likes

It magically worked for me today. Thanks @jen!

1 Like

Thanks for letting us know, @furiouskj :netliconfetti: