]> git.ipfire.org Git - thirdparty/openembedded/openembedded-core-contrib.git/commit
lib/oe/lsb: better handle missing fields
authorJoshua Lock <joshua.g.lock@intel.com>
Tue, 15 Nov 2016 22:08:54 +0000 (22:08 +0000)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Wed, 23 Nov 2016 11:10:14 +0000 (11:10 +0000)
commit333d300fba023bfd201f044b52f51d4b13fcd182
treed11440bfe4a8fd66a01afd913599adf9357cf280
parent4bc5353c929cb1a5f33a24c5471a5bde1929a043
lib/oe/lsb: better handle missing fields

Some rolling release distros, such as Arch Linux, don't include a
VERSION_ID field in their os-release file.

Change release_dict_osr() to better handle this optional field
being absent.

Further improve the resilience of the release_dict_*() methods by
always returning a dict and using dict.get() in distro_identifier()
to supply a default, empty string, value when then key is missing.

(From OE-Core rev: e36066dcc3b56cac1c695370ea178b566c0ebfd6)

Signed-off-by: Joshua Lock <joshua.g.lock@intel.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
meta/lib/oe/lsb.py