<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "https://bugzilla.yoctoproject.org/page.cgi?id=bugzilla.dtd">

<bugzilla version="5.0.6"
          urlbase="https://bugzilla.yoctoproject.org/"
          
          maintainer="it-coreprojects-helpdesk@linuxfoundation.org"
>

    <bug>
          <bug_id>14938</bug_id>
          
          <creation_ts>2022-10-17 12:24:43 +0000</creation_ts>
          <short_desc>gitsm fetcher failure when LFS content is present and git smudge fails</short_desc>
          <delta_ts>2023-09-26 15:55:39 +0000</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>7</classification_id>
          <classification>Build System, Metadata &amp; Runtime</classification>
          <product>BitBake</product>
          <component>bitbake</component>
          <version>4.3</version>
          <rep_platform>x86</rep_platform>
          <op_sys>Multiple</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>WONTFIX</resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>Medium+</priority>
          <bug_severity>normal</bug_severity>
          <target_milestone>Future</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Martin Jansa">Martin.Jansa</reporter>
          <assigned_to name="Martin Jansa">Martin.Jansa</assigned_to>
          <cc>michael.opdenacker</cc>
    
    <cc>poky.bs.watcher</cc>
    
    <cc>poky.watcher</cc>
    
    <cc>randy.macleod</cc>
          
          
          <cf_os>---</cf_os>
          <cf_regression_type>---</cf_regression_type>
          
          <cf_docchange>Don&apos;t know</cf_docchange>

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>94190</commentid>
    <comment_count>0</comment_count>
    <who name="Martin Jansa">Martin.Jansa</who>
    <bug_when>2022-10-17 12:24:43 +0000</bug_when>
    <thetext>I&apos;ve already reported this behavior in:
https://bugzilla.yoctoproject.org/show_bug.cgi?id=14283#c5
but it was already fixed and other people were reporting the same e.g.:
https://lists.openembedded.org/g/openembedded-core/topic/93089137#169500

From the #14283:
Martin Jansa 2022-06-01 07:18:04 UTC
There seems to be similar issue in vulkan-samples in oe-core, it&apos;s failing on LFS content in submodules:

http://errors.yoctoproject.org/Errors/Details/657552/

The actual error (just reformatted):
```
Submodule path \&apos;assets\&apos;: checked out \&apos;db4f7ef1213f159a18b782b60c887210151a9c12\&apos;
Submodule path \&apos;third_party/CTPL\&apos;: checked out \&apos;437e135dbd94eb65b45533d9ce8ee28b5bd37b6d\&apos;
Submodule path \&apos;third_party/astc\&apos;: checked out \&apos;4861c3db1ca50eb5f5767d95d1cd1bacb98ac8a5\&apos;
Submodule path \&apos;third_party/cli11\&apos;: checked out \&apos;4af78beef777e313814b4daff70e2da9171a385a\&apos;
Submodule path \&apos;third_party/glfw\&apos;: checked out \&apos;6876cf8d7e0e70dc3e4d7b0224d08312c9f78099\&apos;
Submodule path \&apos;third_party/glm\&apos;: checked out \&apos;fce2abd01ce21063bd25ba67c9318be83bf48813\&apos;
Submodule path \&apos;third_party/glslang\&apos;: checked out \&apos;6baa85f6ceec5fddd2e13b43dd1edc944dd930af\&apos;
Submodule path \&apos;third_party/hwcpipe\&apos;: checked out \&apos;5a0c3d0b527bea96154998f29177f3b449cebd3a\&apos;
Submodule path \&apos;third_party/imgui\&apos;: checked out \&apos;c23a19c26fa9cc778f755e76799f0cafdcb5a13b\&apos;
Submodule path \&apos;third_party/opencl\&apos;: checked out \&apos;1aa1139b58a515877a923cce6b254e09d1b2fb2c\&apos;
Submodule path \&apos;third_party/spdlog\&apos;: checked out \&apos;7bf8f148795d2571b4ae4aa9c6d2a8111fbb7077\&apos;
Submodule path \&apos;third_party/spirv-cross\&apos;: checked out \&apos;84f56d0b43e5a6874de45e11be2bff9dc336fd7e\&apos;
Submodule path \&apos;third_party/stb\&apos;: checked out \&apos;2c2908f50515dcd939f24be261c3ccbcd277bb49\&apos;
Submodule path \&apos;third_party/tinygltf\&apos;: checked out \&apos;c0d0251e2c7f2273a894aa1b125af9313a88eae4\&apos;
Submodule path \&apos;third_party/vma\&apos;: checked out \&apos;f9921aefddee2437cc2e3303d3175bd8ef23e22c\&apos;
Submodule path \&apos;third_party/volk\&apos;: checked out \&apos;b18f3192886981f28d17f8f41c26c5a53ac3b977\&apos;
Submodule path \&apos;third_party/vulkan\&apos;: checked out \&apos;76f00ef6cbb1886eb1162d1fa39bee8b51e22ee8\&apos;
 
Downloading other_lib/ios/Debug-iphoneos/libSDL2.a (8.2 MB)
Error downloading object: other_lib/ios/Debug-iphoneos/libSDL2.a (5045776):
Smudge error: Error downloading other_lib/ios/Debug-iphoneos/libSDL2.a (5045776556ca57f2f7125d89c37a8b94f79cdebdc040d420513f0491787c4ea7):

batch response: Post &apos;https://github.com/KhronosGroup/KTX-Software.git/info/lfs/objects/batch&apos;: dial tcp: lookup github.com: Temporary failure in name resolution
batch response: Post &apos;https://github.com/KhronosGroup/KTX-Software.git/info/lfs/objects/batch&apos;: dial tcp: lookup github.com: Temporary failure in name resolution
batch response: Post &apos;https://github.com/KhronosGroup/KTX-Software.git/info/lfs/objects/batch&apos;: dial tcp: lookup github.com: Temporary failure in name resolution
batch response: Post &apos;https://github.com/KhronosGroup/KTX-Software.git/info/lfs/objects/batch&apos;: dial tcp: lookup github.com: Temporary failure in name resolution
batch response: Post &apos;https://github.com/KhronosGroup/KTX-Software.git/info/lfs/objects/batch&apos;: dial tcp: lookup github.com: Temporary failure in name resolution
batch response: Post &apos;https://github.com/KhronosGroup/KTX-Software.git/info/lfs/objects/batch&apos;: dial tcp: lookup github.com: Temporary failure in name resolution
batch response: Post &apos;https://github.com/KhronosGroup/KTX-Software.git/info/lfs/objects/batch&apos;: dial tcp: lookup github.com: Temporary failure in name resolution
batch response: Post &apos;https://github.com/KhronosGroup/KTX-Software.git/info/lfs/objects/batch&apos;: dial tcp: lookup github.com: Temporary failure in name resolution
batch response: Post &apos;https://github.com/KhronosGroup/KTX-Software.git/info/lfs/objects/batch&apos;: dial tcp: lookup github.com: Temporary failure in name resolution
 
Errors logged to \&apos;/OE/build/poky/build-st/reproducibleA/tmp/work/core2-64-poky-linux/vulkan-samples/git-r0/git/.git/modules/third_party/ktx/lfs/logs/20220531T194140.927704073.log\&apos;.

Use `git lfs logs last` to view the log.
error: external filter \&apos;git-lfs filter-process\&apos; failed
fatal: other_lib/ios/Debug-iphoneos/libSDL2.a: smudge filter lfs failed
fatal: Unable to checkout \&apos;6a38a0694b4d73d22c5d1e22f865d03545e808ea\&apos; in submodule path \&apos;third_party/ktx\&apos;
```

This was with:
git version 2.35.1
git-lfs/3.1.4 (GitHub; linux amd64; go 1.18.2)

and oe-core/master as of yesterday 18a0c31b33, bitbake 6a346df5

Have anyone else seen this? It should be triggered on autobuilder as well (I triggered it with poky, which I normally don&apos;t use, with just &apos;oe-selftest -r reproducible&apos;, but then reproduced the same with just oe-core), maybe it&apos;s specific to git+git-lfs versions from host? This is from Gentoo. Will retry with some ubuntu as well soon.

Martin Jansa 2022-06-01 10:36:48 UTC
It&apos;s also reproducible in ubuntu-22.10 with:
git version 2.36.1
git-lfs/3.2.0 (GitHub; linux amd64; go 1.18.2)

But it&apos;s somehow related to what I had in .gitconfig (don&apos;t remember when or why I&apos;ve added these, but it was long time ago), looks like first item from https://shuhrat.github.io/programming/git-lfs-tips-and-tricks.html :

[filter &quot;lfs&quot;]
       smudge = git-lfs smudge -- %f
       process = git-lfs filter-process
       required = true
       clean = git-lfs clean -- %f

If I keep only smudge, then the do_unpack takes terribly long, but doesn&apos;t fail:
172.53 seconds vulkan-samples-git-r0/do_fetch
5319.38 seconds vulkan-samples-git-r0/do_unpack

If I remove whole lfs section from .gitconfig then it doesn&apos;t fail and is fast:
13.00 seconds vulkan-samples-git-r0/do_fetch
13.75 seconds vulkan-samples-git-r0/do_unpack

With whole lfs section as shown above (or just smudge+required) it fails after some 90 seconds:
6.94 seconds vulkan-samples-git-r0/do_fetch
84.25 seconds vulkan-samples-git-r0/do_unpack



And today I found that the .gitconfig issue is even worse, because the same &quot;lfs&quot; config is now added automatically to /etc/gitconfig by git-lfst postinst at least in newer ubuntu:

```
root@ljama:~# rm /etc/gitconfig 
root@ljama:~# git lfs install --skip-repo --system
Git LFS initialized.
root@ljama:~# cat /etc/gitconfig 
[filter &quot;lfs&quot;]
        clean = git-lfs clean -- %f
        smudge = git-lfs smudge -- %f
        process = git-lfs filter-process
        required = true
root@ljama:~# cat /var/lib/dpkg/info/git-lfs.postinst
#!/bin/sh

set -e

# Set up /etc/gitconfig for git-lfs. The --skip-repo option prevents failure if
# / is a Git repository with existing non-git-lfs hooks.
git lfs install --skip-repo --system &gt; /dev/null 2&gt;&amp;1
```

according to https://changelogs.ubuntu.com/changelogs/pool/universe/g/git-lfs/git-lfs_3.0.2-1/changelog it was added in:
```
git-lfs (2.6.0-1) unstable; urgency=medium

  * New upstream release
  * Bump standards version to 4.2.1
  * Add postinst/prerm to set up/remove git-lfs gitconfig
```</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>94193</commentid>
    <comment_count>1</comment_count>
    <who name="Martin Jansa">Martin.Jansa</who>
    <bug_when>2022-10-17 13:38:18 +0000</bug_when>
    <thetext>https://patchwork.yoctoproject.org/project/bitbake/patch/20221017132026.88753-1-Martin.Jansa@gmail.com/</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>94195</commentid>
    <comment_count>2</comment_count>
    <who name="Martin Jansa">Martin.Jansa</who>
    <bug_when>2022-10-17 16:20:41 +0000</bug_when>
    <thetext>for vulkan-samples case we can just explicitly disable lfs:
https://patchwork.yoctoproject.org/project/oe-core/patch/20221017140558.632766-1-Martin.Jansa@gmail.com/</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>94245</commentid>
    <comment_count>3</comment_count>
    <who name="Martin Jansa">Martin.Jansa</who>
    <bug_when>2022-10-26 08:10:51 +0000</bug_when>
    <thetext>The bitbake patch itself doesn&apos;t resolve all corner cases as documented by added test:

https://patchwork.yoctoproject.org/project/bitbake/patch/20221018193746.3599845-1-Martin.Jansa@gmail.com/

I don&apos;t know what is expected behavior which would be reproducible (not affected by user&apos;s .gitconfig and git-lfs installed or not-installed).</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>96576</commentid>
    <comment_count>4</comment_count>
    <who name="Martin Jansa">Martin.Jansa</who>
    <bug_when>2023-09-26 15:55:39 +0000</bug_when>
    <thetext>There were some related changes merged recently:
https://git.openembedded.org/bitbake/commit/?id=1f8f21fe024b391d3a6670c64b839db0eee083c3

and as it&apos;s still unknown what&apos;s the expected behavior, I&apos;ll close this as WONTFIX.</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>