git.latest smudge filter failed to update lfs tracked objects
See original GitHub issueDescription of Issue/Question
git.latest is failed to download the latest version or the file tracked by LFS.
- First download of LFS tracked file works.
- Other text file are updated as per repo.
ERROR:
Downloading test_binary_file (24 B)
Error downloading object: test_binary_file (4cf7033): Smudge error: Error downloading test_binary_file (4cf7033562783a50dc185a66bd535eb66002b3aad946e255c1d458b6d04694d6): batch request: Permission denied (publickey).: exit status 255
Errors logged to /opt/management-agent/.git/lfs/logs/20190121T004633.928000968.log
Use
git lfs logs last
to view the log. error: external filter git-lfs smudge – %f failed 2 error: external filter git-lfs smudge – %f failed fatal: test_binary_file: smudge filter lfs failed
Errors out as Permission denied (publickey), but the same key is used to update the files when manually run. sudo ssh-agent sh -c 'ssh-add /root/.ssh/gitlab_id_rsa; git fetch; git reset --hard; git pull'
Setup
git.latest:
- name: {{ iotransit.management_agent_repo }}
- rev: {{ iotransit.branch_commit }}
- branch: {{ iotransit.branch_commit }}
- target: /opt/management-agent
- force_reset: True
- force_checkout: True
- force_fetch: True
- fetch_tags: True
- identity: {{ iotransit.gitlab_id_rsa }}
- require:
- file: iotransit_private_key
- pkg: iotransit_gitlfs_install
- cmd: iotransit_initialize_gitlfs
Steps to Reproduce Issue
update the binary file in the repo and the above salt state fails as it couldnt update the LFS tracked files
Versions Report
salt-master versions report:
Salt Version:
Salt: 2018.3.2
Dependency Versions:
cffi: Not Installed
cherrypy: Not Installed
dateutil: 2.4.2
docker-py: Not Installed
gitdb: 0.6.4
gitpython: 1.0.1
ioflo: Not Installed
Jinja2: 2.8
libgit2: Not Installed
libnacl: Not Installed
M2Crypto: Not Installed
Mako: 1.0.3
msgpack-pure: Not Installed
msgpack-python: 0.4.6
mysql-python: Not Installed
pycparser: Not Installed
pycrypto: 2.6.1
pycryptodome: Not Installed
pygit2: Not Installed
Python: 2.7.12 (default, Nov 12 2018, 14:36:49)
python-gnupg: 0.3.8
PyYAML: 3.11
PyZMQ: 15.2.0
RAET: Not Installed
smmap: 0.9.0
timelib: Not Installed
Tornado: 4.2.1
ZMQ: 4.1.4
System Versions:
dist: Ubuntu 16.04 xenial
locale: ANSI_X3.4-1968
machine: x86_64
release: 4.4.0-1065-aws
system: Linux
version: Ubuntu 16.04 xenial
salt-minion version:
salt-minion 2018.3.3 (Oxygen)
Issue Analytics
- State:
- Created 5 years ago
- Comments:6 (2 by maintainers)
Top Results From Across the Web
Smudge filter failed with a fresh new clone · Issue #911 · git-lfs ...
In my case I've got 'Smudge filter failed' because I've changed the lfs-objects path. Since I'm running Gitlab CE on one of my...
Read more >github - Git pull - smudge filter lfs failed - Stack Overflow
In my case the SSH-authenticated repository was updated to use LFS from another client and on my side Git-LFS didn't know about the...
Read more >Git LFS Fail- smudge error - Atlassian Community
Im seeing the following error when I try to pull an image to our live server (git-lfs/3.0.2 (GitHub; linux amd64; go 1.17)).
Read more >Git LFS in GitKraken Client | Store Binary Files
The smudge filter puts a file into your working directory. LFS reads the SHA stored in Git, then uses that to find the...
Read more >Smudge Error: Smudge Filter LFS Failed during Git Pull - Reddit
I am a part of a Game Development Team. We are developing an Unreal Engine 4 game for PC. We have a private...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
OK, so I was able to fix this by simply telling the
git merge
command to use an identity file. So when thegit merge
command is run, the wrapper first does the authentication, and we’re already auth’ed when the git LFS filters run their commands. Merges and resets don’t typically need authentication since we always make sure we’ve fetched the targeted revision before we make any changes to the local HEAD.I should have a PR ready soon.
This PR has been merged and the fix will be available in 2018.3.5, 2019.2.1, and the Neon release. If the problem persists, please let us know and we can re-open the issue. Thanks!