<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux/poky.git/bitbake/lib/bb/fetch2/git.py, branch yocto-3.4.3</title>
<subtitle>Mirror of git.yoctoproject.org/poky</subtitle>
<id>https://git.enea.com/cgit/linux/poky.git/atom?h=yocto-3.4.3</id>
<link rel='self' href='https://git.enea.com/cgit/linux/poky.git/atom?h=yocto-3.4.3'/>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/'/>
<updated>2021-11-03T11:31:21+00:00</updated>
<entry>
<title>bitbake: fetch/git: Handle github dropping git:// support</title>
<updated>2021-11-03T11:31:21+00:00</updated>
<author>
<name>Richard Purdie</name>
<email>richard.purdie@linuxfoundation.org</email>
</author>
<published>2021-11-02T12:40:59+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=13a4588253d5f69c23829d43a4ee7790e1ae456a'/>
<id>urn:sha1:13a4588253d5f69c23829d43a4ee7790e1ae456a</id>
<content type='text'>
github is dropping support for git protocol in Git urls. Add code to remap
this to https in a way that could be used in older bitbake versions.

(Bitbake rev: f19eefdaa5b43460f00d79d002f96112a6aa3c9a)

Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>bitbake: fetch2/git: Use os.rename instead of mv</title>
<updated>2021-09-21T22:44:08+00:00</updated>
<author>
<name>Richard Purdie</name>
<email>richard.purdie@linuxfoundation.org</email>
</author>
<published>2021-09-19T10:27:16+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=435bce9bf96dfa18e2c8167420aa4032a02afb66'/>
<id>urn:sha1:435bce9bf96dfa18e2c8167420aa4032a02afb66</id>
<content type='text'>
os.rename will overwrite the destination file if present so we can use this
instead of the process call overhead.

(Bitbake rev: b3cccaa6a896c41d8c9be5eebc327f726542d16b)

Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>bitbake: fetch2/git: Avoid races over mirror tarball creation</title>
<updated>2021-09-17T06:26:23+00:00</updated>
<author>
<name>Richard Purdie</name>
<email>richard.purdie@linuxfoundation.org</email>
</author>
<published>2021-09-16T12:51:30+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=626e949292a4d21cc828fcc6c8d5f62a93622f61'/>
<id>urn:sha1:626e949292a4d21cc828fcc6c8d5f62a93622f61</id>
<content type='text'>
There is a potential race over the mirror tarballs where a partial git repo
could be extracted causing fetcher failures if the tarball is being rewritten
whilst another build accesses it.

Create the mirror tarball atomically to avoid this.

[YOCTO #14441]

(Bitbake rev: 3250bc950c56bd7dd2114df26e5a8e13b04ceac8)

Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>bitbake: fetch/git: run gc in foreground to avoid race with tar</title>
<updated>2021-07-10T21:43:41+00:00</updated>
<author>
<name>Adam Romanek</name>
<email>romanek.adam@gmail.com</email>
</author>
<published>2021-07-07T10:40:04+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=6cd8032e359932d46b3dd8351b7a77f0270a0c7d'/>
<id>urn:sha1:6cd8032e359932d46b3dd8351b7a77f0270a0c7d</id>
<content type='text'>
It looks like git gc can interrupts the package creation when
BB_GENERATE_MIRRORS_TARBALL is in use.

Log excerpts:

tar -czf TOPDIR/../downloads/git2_bitbucket.name-hidden.git.tar.gz . failed with exit code 1, output:
tar: ./objects/pack/pack-89a1d76f6c08f53172ef1d02ff851d90564362c4.pack: file changed as we read it
tar: ./objects/pack/pack-b4a48ada355d333630fdf6b4f67205b7c264dc2c.idx: File removed before we read it

Auto packing the repository in background for optimum performance.
See "git help gc" for manual housekeeping.

(Bitbake rev: a8d8cb847063862d1a7998963dd8b767ff73d877)

Signed-off-by: Adam Romanek &lt;romanek.adam@gmail.com&gt;
Signed-off-by: Damian Wrobel &lt;dwrobel@ertelnet.rybnik.pl&gt;
Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>bitbake: fetch/gitsm: Fix crash when using git LFS and submodules</title>
<updated>2021-04-20T12:57:50+00:00</updated>
<author>
<name>Niels Avonds</name>
<email>niels@codebits.be</email>
</author>
<published>2021-04-19T10:41:26+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=d12a06cd49b6cc13fcd15e56b5034de5ced642ee'/>
<id>urn:sha1:d12a06cd49b6cc13fcd15e56b5034de5ced642ee</id>
<content type='text'>
Gitsm fetcher crashes when cloning a repository that contains LFS files.
This happens because the unpack method is called during download, but the
submodules have not been downloaded yet at this point.

This issue was introduced in this
commit: 977b7268bf4fd425cb86d4a57500350c9b829162

[YOCTO #14283]

(Bitbake rev: 26caedc4d2e9b5a0f1d57f9291754a7f6c5e437e)

Signed-off-by: Niels Avonds &lt;niels@codebits.be&gt;
Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>bitbake: fetch/git: add support for disabling shared clones on unpack</title>
<updated>2021-04-18T10:38:22+00:00</updated>
<author>
<name>Henning Schild</name>
<email>henning.schild@siemens.com</email>
</author>
<published>2021-04-14T06:32:39+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=2cb6ce778804deb9666cf09a7ada787c9f7936cf'/>
<id>urn:sha1:2cb6ce778804deb9666cf09a7ada787c9f7936cf</id>
<content type='text'>
By default the unpacker will create a "shared" clone when cloning from
the DL_DIR to the WORKDIR. This patch introduces an option to control
that behaviour.

Imagine some recipe steps are executed in a namespace that is different
from the one your downloader and unpacker ran in. (chroot) Because a
"shared" clone has an absolute reference to its "alternate" you now
have to make that "alternate" visible in that new namespace (chroot) at
the exact place.

With this patch you can unpack "noshared" and get a stand-alone copy.
This copy will also work if the "alternate" is not visible or existant.

The switch is a global bitbake switch and will affect all git urls.
Build systems that need "noshared" most likely need it for everything
they do with git.

(Bitbake rev: 6ae6f1865d5e666ebc670f70b7401a7b41648102)

Signed-off-by: Henning Schild &lt;henning.schild@siemens.com&gt;
Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>bitbake: fetch/git: download LFS content too during do_fetch</title>
<updated>2021-01-23T17:10:46+00:00</updated>
<author>
<name>Matt Hoosier</name>
<email>matt.hoosier@garmin.com</email>
</author>
<published>2021-01-22T16:55:13+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=45c02843d181b5f1872ad30f4d847c395233a676'/>
<id>urn:sha1:45c02843d181b5f1872ad30f4d847c395233a676</id>
<content type='text'>
Insert an explicit pass to fetch all blobs needed by Git LFS, during the
fetch() function. This avoids the default behavior of Git LFS to wait
until 'git checkout' to begin downloading the blobs pointed to by LFS records.
Network access is not allowed at that point in the recipe's lifecycle.

[YOCTO #14191]

(Bitbake rev: 0efac66043662e7a2027192f50e92e982db2ba1c)

Signed-off-by: Matt Hoosier &lt;matt.hoosier@garmin.com&gt;
Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>bitbake: fetch/git: Fix usehead for non-default names</title>
<updated>2021-01-08T10:11:42+00:00</updated>
<author>
<name>Joey Degges</name>
<email>jdegges@gmail.com</email>
</author>
<published>2020-12-14T08:30:02+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=10c69538c0cb8708c7eff9e8dc05ca7c669cb61c'/>
<id>urn:sha1:10c69538c0cb8708c7eff9e8dc05ca7c669cb61c</id>
<content type='text'>
The usehead url parameter for git repositories causes bitbake to use
whatever commit the repository HEAD is pointing to if the repository
happens to have the name 'default'. This is the default name so in many
cases it works just fine, but if a different name is specified with the
url parameter 'name=newName' then it will fail to parse the recipe with
an error along the lines of:

ERROR: ExpansionError during parsing /path/to/my/recipe.bb
Traceback (most recent call last):
  File "/path/to/poky/bitbake/lib/bb/fetch2/git.py", line 235, in Git.urldata_init:
    &gt;        ud.setup_revisions(d)
  File "/path/to/poky/bitbake/lib/bb/fetch2/__init__.py", line 1302, in FetchData.setup_revisions:
             for name in self.names:
    &gt;            self.revisions[name] = srcrev_internal_helper(self, d, name)
  File "/path/to/poky/bitbake/lib/bb/fetch2/__init__.py", line 1167, in srcrev_internal_helper(name='newName'):
         if srcrev == "AUTOINC":
    &gt;        srcrev = ud.method.latest_revision(ud, d, name)
  File "/path/to/poky/bitbake/lib/bb/fetch2/__init__.py", line 1562, in Git.latest_revision(name='newName'):
             except KeyError:
    &gt;            revs[key] = rev = self._latest_revision(ud, d, name)
                 return rev
  File "/path/to/poky/bitbake/lib/bb/fetch2/git.py", line 650, in Git._latest_revision(name='newName'):
             raise bb.fetch2.FetchError("Unable to resolve '%s' in upstream git repository in git ls-remote output for %s" % \
    &gt;            (ud.unresolvedrev[name], ud.host+ud.path))
bb.data_smart.ExpansionError: Failure expanding variable SRCPV, expression was ${@bb.fetch2.get_srcrev(d)} which triggered exception FetchError: Fetcher failure: Unable to resolve 'master' in upstream git repository in git ls-remote output for /path/to/local/git/repo

Let's fix this by setting the unresolved rev of _all_ repository names
to 'HEAD' when the usehead url parameter is specified. Update the
currently failing test, test_local_gitfetch_usehead_withname, to now
expect success.

This change preserves existing behavior that allows usehead to be
overridden by a valid looking revision if one happens to be specified
instead of AUTOREV.

(Bitbake rev: 01e901c44ab0f496606b1d45c8953dc54970204c)

Signed-off-by: Joey Degges &lt;jdegges@gmail.com&gt;
Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>bitbake: fetch2/git: Document that we won't support passwords in git urls</title>
<updated>2020-11-03T08:21:10+00:00</updated>
<author>
<name>Richard Purdie</name>
<email>richard.purdie@linuxfoundation.org</email>
</author>
<published>2020-11-02T11:50:18+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=bd98ef572df3ed89e9aa0c414a0c622b58659b64'/>
<id>urn:sha1:bd98ef572df3ed89e9aa0c414a0c622b58659b64</id>
<content type='text'>
This keeps coming up, document why we don't do this and the alternatives.

(Bitbake rev: aded964eed4ce5a725ed1ab477efabc86b1aa481)

Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>bitbake: bitbake: fetch/git: use shlex.quote() to support spaces in SRC_URI url</title>
<updated>2020-10-17T11:36:14+00:00</updated>
<author>
<name>Charlie Davies</name>
<email>charles.davies@whitetree.xyz</email>
</author>
<published>2020-10-14T09:48:38+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=b50b6007e5fab1b2f7634836dcaa775c8836edce'/>
<id>urn:sha1:b50b6007e5fab1b2f7634836dcaa775c8836edce</id>
<content type='text'>
This commit replaces the instances where escaped double quotes
are used to support SRC_URI url containing spaces with the more
pythonic shlex.quote().

(Bitbake rev: 4f9ba9c794de55bea0343267467bddea99844374)

Signed-off-by: Charlie Davies &lt;charles.davies@whitetree.xyz&gt;
Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
</entry>
</feed>
