<?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>11698</bug_id>
          
          <creation_ts>2017-06-21 14:41:12 +0000</creation_ts>
          <short_desc>Git shallow fetcher sometimes fails selftest</short_desc>
          <delta_ts>2017-07-30 10:28:47 +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>unspecified</version>
          <rep_platform>x86</rep_platform>
          <op_sys>Multiple</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>FIXED</resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>Medium+</priority>
          <bug_severity>normal</bug_severity>
          <target_milestone>2.4 M2</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Ross Burton">ross.burton</reporter>
          <assigned_to name="Christopher Larson">kergoth</assigned_to>
          <cc>joshuagloe</cc>
    
    <cc>poky.bs.watcher</cc>
    
    <cc>poky.watcher</cc>
    
    <cc>randy.macleod</cc>
    
    <cc>richard.purdie</cc>
          
          
          <cf_os>---</cf_os>
          <cf_regression_type>---</cf_regression_type>
          
          <cf_docchange>No (bug/feature does not impact docs)</cf_docchange>

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>74432</commentid>
    <comment_count>0</comment_count>
    <who name="Ross Burton">ross.burton</who>
    <bug_when>2017-06-21 14:41:12 +0000</bug_when>
    <thetext>Sometimes but not always the git shallow fetcher selftest fails:

ERROR: test_bitbake (bb.tests.fetch.GitShallowTest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File &quot;/home/pokybuild/yocto-autobuilder/yocto-worker/nightly/build/bitbake/lib/bb/fetch2/__init__.py&quot;, line 1534, in latest_revision
    return revs[key]
  File &quot;/home/pokybuild/yocto-autobuilder/yocto-worker/nightly/build/bitbake/lib/bb/persist_data.py&quot;, line 83, in __getitem__
    raise KeyError(key)
KeyError: &apos;git:.tmp.tmpgwkjmxuk.gitsourcemaster-&apos;

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File &quot;/home/pokybuild/yocto-autobuilder/yocto-worker/nightly/build/bitbake/lib/bb/tests/fetch.py&quot;, line 1450, in test_bitbake
    self.fetch_shallow()
  File &quot;/home/pokybuild/yocto-autobuilder/yocto-worker/nightly/build/bitbake/lib/bb/tests/fetch.py&quot;, line 1063, in fetch_shallow
    fetcher, ud = self.fetch_and_unpack(uri)
  File &quot;/home/pokybuild/yocto-autobuilder/yocto-worker/nightly/build/bitbake/lib/bb/tests/fetch.py&quot;, line 1056, in fetch_and_unpack
    fetcher, ud = self.fetch(uri)
  File &quot;/home/pokybuild/yocto-autobuilder/yocto-worker/nightly/build/bitbake/lib/bb/tests/fetch.py&quot;, line 1050, in fetch
    fetcher = bb.fetch2.Fetch(uris, d)
  File &quot;/home/pokybuild/yocto-autobuilder/yocto-worker/nightly/build/bitbake/lib/bb/fetch2/__init__.py&quot;, line 1567, in __init__
    self.ud[url] = FetchData(url, d, localonly)
  File &quot;/home/pokybuild/yocto-autobuilder/yocto-worker/nightly/build/bitbake/lib/bb/fetch2/__init__.py&quot;, line 1246, in __init__
    self.method.urldata_init(self, d)
  File &quot;/home/pokybuild/yocto-autobuilder/yocto-worker/nightly/build/bitbake/lib/bb/fetch2/git.py&quot;, line 239, in urldata_init
    ud.setup_revisions(d)
  File &quot;/home/pokybuild/yocto-autobuilder/yocto-worker/nightly/build/bitbake/lib/bb/fetch2/__init__.py&quot;, line 1276, in setup_revisions
    self.revisions[name] = srcrev_internal_helper(self, d, name)
  File &quot;/home/pokybuild/yocto-autobuilder/yocto-worker/nightly/build/bitbake/lib/bb/fetch2/__init__.py&quot;, line 1141, in srcrev_internal_helper
    srcrev = ud.method.latest_revision(ud, d, name)
  File &quot;/home/pokybuild/yocto-autobuilder/yocto-worker/nightly/build/bitbake/lib/bb/fetch2/__init__.py&quot;, line 1536, in latest_revision
    revs[key] = rev = self._latest_revision(ud, d, name)
  File &quot;/home/pokybuild/yocto-autobuilder/yocto-worker/nightly/build/bitbake/lib/bb/fetch2/git.py&quot;, line 581, in _latest_revision
    (ud.unresolvedrev[name], ud.host+ud.path))
bb.fetch2.FetchError: Fetcher failure: Unable to resolve &apos;master&apos; in upstream git repository in git ls-remote output for /tmp/tmpgwkjmxuk/gitsource

Stdout:
Running git -c core.fsyncobjectfiles=0 ls-remote file:///tmp/tmpgwkjmxuk/gitsource</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>75067</commentid>
    <comment_count>1</comment_count>
    <who name="Joshua Lock">joshuagloe</who>
    <bug_when>2017-07-17 14:35:18 +0000</bug_when>
    <thetext>Not sure if the host OS is useful, but this just failed on CentOS 7</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>75397</commentid>
    <comment_count>2</comment_count>
    <who name="Richard Purdie">richard.purdie</who>
    <bug_when>2017-07-28 16:57:37 +0000</bug_when>
    <thetext>This only seems to happen on centos 7. Easy/fast way to make it fail:

bitbake-selftest bb.tests.fetch.GitShallowTest.test_bitbake

$ git --version
git version 1.8.3.1

I&apos;m told git 2.11.0 works.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>75412</commentid>
    <comment_count>3</comment_count>
    <who name="Christopher Larson">kergoth</who>
    <bug_when>2017-07-28 19:48:57 +0000</bug_when>
    <thetext>Patch sent to the bitbake-devel list.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>75430</commentid>
    <comment_count>4</comment_count>
    <who name="Richard Purdie">richard.purdie</who>
    <bug_when>2017-07-30 10:28:47 +0000</bug_when>
    <thetext>http://git.yoctoproject.org/cgit.cgi/poky/commit/?id=e75639f85ab7d92ff4637049c2c8af389fb2c50b</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>