[oe-commits] [bitbake] 01/02: bitbake-layers: fix layerindex-fetch for Python 3

git at git.openembedded.org git at git.openembedded.org
Mon Dec 18 17:17:35 UTC 2017


This is an automated email from the git hooks/post-receive script.

rpurdie pushed a commit to branch 1.32
in repository bitbake.

commit e75c68819086788bac1c4ca8a35aebeaf604e624
Author: Paul Eggleton <paul.eggleton at linux.intel.com>
AuthorDate: Wed Nov 29 14:34:56 2017 -0800

    bitbake-layers: fix layerindex-fetch for Python 3
    
    The data we read from an HTTPConnection comes in the form of bytes, but
    we need it as a string, so in Python 3 we need to decode it (missed in
    the Python 3 migration).
    
    Signed-off-by: Paul Eggleton <paul.eggleton at linux.intel.com>
    Signed-off-by: Richard Purdie <richard.purdie at linuxfoundation.org>
---
 lib/bblayers/layerindex.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/lib/bblayers/layerindex.py b/lib/bblayers/layerindex.py
index 10ad718..f53a47f 100644
--- a/lib/bblayers/layerindex.py
+++ b/lib/bblayers/layerindex.py
@@ -56,7 +56,7 @@ class LayerIndexPlugin(ActionPlugin):
         r = conn.getresponse()
         if r.status != 200:
             raise Exception("Failed to read " + path + ": %d %s" % (r.status, r.reason))
-        return json.loads(r.read())
+        return json.loads(r.read().decode())
 
     def get_layer_deps(self, layername, layeritems, layerbranches, layerdependencies, branchnum, selfname=False):
         def layeritems_info_id(items_name, layeritems):

-- 
To stop receiving notification emails like this one, please contact
the administrator of this repository.


More information about the Openembedded-commits mailing list