aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRichard Purdie <richard.purdie@linuxfoundation.org>2016-05-20 12:48:02 +0100
committerRichard Purdie <richard.purdie@linuxfoundation.org>2016-05-21 12:14:31 +0100
commit138329c58e92744c56aae3ab70ceeef09613250c (patch)
tree0c30e40ebfa0a84445ab1f0abd5bf137bb9fb83a
parentacac9bf660ac5939beb64d7b8d55541dea1c7b4e (diff)
downloadbitbake-138329c58e92744c56aae3ab70ceeef09613250c.tar.gz
cooker: Fix parse progress for python3
Under python the type conversions can mean there are float values used for triggering the parse progress events which then fails. Add an explict int() conversion to ensure the parse events are generated under python3. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
-rw-r--r--lib/bb/cooker.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/bb/cooker.py b/lib/bb/cooker.py
index 44aa11e53..fb86446d4 100644
--- a/lib/bb/cooker.py
+++ b/lib/bb/cooker.py
@@ -2020,7 +2020,7 @@ class CookerParser(object):
else:
self.fromcache.append((filename, appends))
self.toparse = self.total - len(self.fromcache)
- self.progress_chunk = max(self.toparse / 100, 1)
+ self.progress_chunk = int(max(self.toparse / 100, 1))
self.num_processes = min(int(self.cfgdata.getVar("BB_NUMBER_PARSE_THREADS", True) or
multiprocessing.cpu_count()), len(self.willparse))