<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux/poky.git/bitbake/lib/bb/utils.py, branch honister-3.4.4</title>
<subtitle>Mirror of git.yoctoproject.org/poky</subtitle>
<id>https://git.enea.com/cgit/linux/poky.git/atom?h=honister-3.4.4</id>
<link rel='self' href='https://git.enea.com/cgit/linux/poky.git/atom?h=honister-3.4.4'/>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/'/>
<updated>2022-03-14T13:33:35+00:00</updated>
<entry>
<title>bitbake: utils: Ensure shell function failure in python logging is correct</title>
<updated>2022-03-14T13:33:35+00:00</updated>
<author>
<name>Richard Purdie</name>
<email>richard.purdie@linuxfoundation.org</email>
</author>
<published>2022-03-14T02:13:56+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=b0f3d3b3655fa7ef0f349318a50f7947cb40c26c'/>
<id>urn:sha1:b0f3d3b3655fa7ef0f349318a50f7947cb40c26c</id>
<content type='text'>
If a python function exec_func() calls a shell task, the logging wasn't working
correctly in all cases since the exception was turned into a BBHandledException()
and the logfile piece was lost which is handled at the top task level.

The easiest way to avoid this is to allow the ExecutionError exceptions to
be raised to a higher level, we don't need the traceback for them.

(Bitbake rev: 23a6f11b089b14382c21d431edf34fa7224c66bf)

Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
(cherry picked from commit 7cae11f558f9ff5fd05ef23b789aaef92fb5a327)
Signed-off-by: Anuj Mittal &lt;anuj.mittal@intel.com&gt;
Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>bitbake: utils: Update to use exec_module() instead of load_module()</title>
<updated>2022-01-11T21:34:11+00:00</updated>
<author>
<name>Richard Purdie</name>
<email>richard.purdie@linuxfoundation.org</email>
</author>
<published>2022-01-10T04:25:29+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=6f86ba22e897df335bd2e6bd20bad7ca55d01cf0'/>
<id>urn:sha1:6f86ba22e897df335bd2e6bd20bad7ca55d01cf0</id>
<content type='text'>
This is deprecated in python 3.12 and Fedora 35 is throwing warnings so
move to the new functions.

(Bitbake rev: c039182c79e2ccc54fff5d7f4f266340014ca6e0)

Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
(cherry picked from commit 68a18fbcb5959e334cf307d7fa8dc63832edb942)
Signed-off-by: Anuj Mittal &lt;anuj.mittal@intel.com&gt;
Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>bitbake: utils: Handle lockfile filenames that are too long for filesystems</title>
<updated>2021-11-24T10:08:23+00:00</updated>
<author>
<name>Richard Purdie</name>
<email>richard.purdie@linuxfoundation.org</email>
</author>
<published>2021-11-22T08:36:47+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=c4f08fc43da0658fadd585790736c47a18228f5c'/>
<id>urn:sha1:c4f08fc43da0658fadd585790736c47a18228f5c</id>
<content type='text'>
The fetcher mirror code can go crazy creating lock filenames which exceed the
filesystem limits. When this happens, the code will loop/hang.

Handle the filename too long exception correctly but also truncate lockfile
lengths to under 256 since the worst case situation is lockfile overlap
and lack of parallelism.

(Bitbake rev: 64498ecb094b7911d10b07c098d5a966e79f95b3)

Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
(cherry picked from commit 63baf3440b16e41ac6601de21ced94a94bdf1509)
Signed-off-by: Anuj Mittal &lt;anuj.mittal@intel.com&gt;
Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>bitbake: utils: add environment updating context manager</title>
<updated>2021-08-12T05:28:01+00:00</updated>
<author>
<name>Ross Burton</name>
<email>ross@burtonini.com</email>
</author>
<published>2021-08-10T16:55:06+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=62098f90411ca6775d3d7d70a8a641ce35dc9f84'/>
<id>urn:sha1:62098f90411ca6775d3d7d70a8a641ce35dc9f84</id>
<content type='text'>
bb.utils.environment() is a context manager to alter os.environ inside
a specific block, restoring it after the block is closed.

(Bitbake rev: 9974848f67581ff7d76cef52a94f505af99b4932)

Signed-off-by: Ross Burton &lt;ross.burton@arm.com&gt;
Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>bitbake: fetch/tests/toaster: Override conversion fixups</title>
<updated>2021-08-06T05:34:58+00:00</updated>
<author>
<name>Richard Purdie</name>
<email>richard.purdie@linuxfoundation.org</email>
</author>
<published>2021-08-04T09:55:04+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=7f0f1179eb02c3bb84ffe01f102375dc1186136e'/>
<id>urn:sha1:7f0f1179eb02c3bb84ffe01f102375dc1186136e</id>
<content type='text'>
Fix some references that missed during the overrides syntax migration or
were incorrect. Thanks to Quentin Schulz &lt;foss@0leil.net&gt; for the patch.

(Bitbake rev: 6184cb07dfa44f5f76f1c423533b4547d80b20ab)

Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>bitbake: lib/bb: Add bb.utils.rename() helper function and use for renaming</title>
<updated>2021-05-06T10:04:59+00:00</updated>
<author>
<name>Devendra Tewari</name>
<email>devendra.tewari@gmail.com</email>
</author>
<published>2021-04-19T14:23:58+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=581233a798434f178898f12fa35bbcccb92e7768'/>
<id>urn:sha1:581233a798434f178898f12fa35bbcccb92e7768</id>
<content type='text'>
os.rename can fail for example an incremental build in Docker fails with:

OSError: [Errno 18] Invalid cross-device link

when source and destination are on different overlay filesystems.

Rather than trying to fix every call site, add a wrapper in bb.utils
for renames. We can then handle cross device failures and
fall back to shutil.move. The reason os.rename is still used is
because shutil.move is too slow for speed sensitive sections of code.

[YOCTO #14301]

(Bitbake rev: c5c4e49574ab2a65e06298a0a77bb98b041cf56b)

Signed-off-by: Devendra Tewari &lt;devendra.tewari@gmail.com&gt;
Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>bitbake: logging: Make bitbake logger compatible with python logger</title>
<updated>2021-02-10T23:48:16+00:00</updated>
<author>
<name>Joshua Watt</name>
<email>JPEWhacker@gmail.com</email>
</author>
<published>2021-02-09T15:50:21+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=75f87db413f3659fee18eff389b7b339b01cce15'/>
<id>urn:sha1:75f87db413f3659fee18eff389b7b339b01cce15</id>
<content type='text'>
The bitbake logger overrode the definition of the debug() logging call
to include a debug level, but this causes problems with code that may
be using standard python logging, since the extra argument is
interpreted differently.

Instead, change the bitbake loggers debug() call to match the python
logger call and add a debug2() and debug3() API to replace calls that
were logging to a different debug level.

[RP: Small fix to ensure bb.debug calls bbdebug()]
(Bitbake rev: f68682a79d83e6399eb403f30a1f113516575f51)

Signed-off-by: Joshua Watt &lt;JPEWhacker@gmail.com&gt;
Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>bitbake: utils: add docstrings to functions</title>
<updated>2021-01-08T10:11:42+00:00</updated>
<author>
<name>Milan Shah</name>
<email>mshah@mvista.com</email>
</author>
<published>2021-01-05T09:31:58+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=0fa7258d27e64984c41e03580921ebd48eba5a64'/>
<id>urn:sha1:0fa7258d27e64984c41e03580921ebd48eba5a64</id>
<content type='text'>
A list of functions that now has a docstring.
* vercmp_string
* explode_dep_versions
* prunedir
* prune_suffix
* to_boolean
* contains_any
* export_proxies

See [YOCTO #9725] for details.

(Bitbake rev: b61ba4a18693a9e553d2a93161feb0bcc1c82384)

Signed-off-by: Milan Shah &lt;mshah@mvista.com&gt;
Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>bitbake: utils: add umask changing context manager</title>
<updated>2020-09-30T14:03:30+00:00</updated>
<author>
<name>Ross Burton</name>
<email>ross@burtonini.com</email>
</author>
<published>2020-09-28T16:18:58+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=f3b0d3eeaefa4ecbc1c31406201ebc03e5bf1588'/>
<id>urn:sha1:f3b0d3eeaefa4ecbc1c31406201ebc03e5bf1588</id>
<content type='text'>
Add a umask context manager which can be used to temporarily change the
umask in a 'with' block.

(Bitbake rev: 6c601e68a27e1c60b04c2a61830d1812cc883e09)

Signed-off-by: Ross Burton &lt;ross.burton@arm.com&gt;
Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>bitbake: utils: fix UnboundLocalError when _print_exception raises</title>
<updated>2020-09-10T12:49:21+00:00</updated>
<author>
<name>Chris Laplante</name>
<email>chris.laplante@agilent.com</email>
</author>
<published>2020-09-08T23:31:50+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/poky.git/commit/?id=9b2b23d5ec4c9b0031ad9c002ab40e70a49fe71e'/>
<id>urn:sha1:9b2b23d5ec4c9b0031ad9c002ab40e70a49fe71e</id>
<content type='text'>
PEP 3110 changed how exceptions work. 'e' is unbound
after the 'except' clause. See: https://www.python.org/dev/peps/pep-3110/#semantic-changes

(Bitbake rev: b69e97de53eb172ed730993e3b755debaa26f30d)

Signed-off-by: Chris Laplante &lt;chris.laplante@agilent.com&gt;
Signed-off-by: Richard Purdie &lt;richard.purdie@linuxfoundation.org&gt;
</content>
</entry>
</feed>
