aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPaul Eggleton <paul.eggleton@linux.intel.com>2018-03-01 16:33:58 +1300
committerPaul Eggleton <paul.eggleton@linux.intel.com>2018-05-04 23:57:52 +1200
commit0bab50462c583475bc04c222401b982a27d96a63 (patch)
treed60c65f6ab43a72c8f7fff993be8512eaa7d8679
parent687c2b0051140020fc52bf268e532115ab00501a (diff)
downloadopenembedded-core-contrib-0bab50462c583475bc04c222401b982a27d96a63.tar.gz
rrs_upstream_history.py: drop threading
This is never going to work, the only way we can practically do parallel execution is to run these things in a task which would basically amount to distrodata's do_checkpkg; we may move to that in future but for now just drop the threading code. Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
-rwxr-xr-xrrs/tools/rrs_upstream_history.py19
1 files changed, 2 insertions, 17 deletions
diff --git a/rrs/tools/rrs_upstream_history.py b/rrs/tools/rrs_upstream_history.py
index 84355c43e7..b3d47c9969 100755
--- a/rrs/tools/rrs_upstream_history.py
+++ b/rrs/tools/rrs_upstream_history.py
@@ -86,13 +86,11 @@ def set_regexes(d):
d.getVar(var, True)))
break
-def get_upstream_info(thread_worker, arg):
+def get_upstream_info(layerbranch, recipe_data, result):
from bb.utils import vercmp_string
from oe.recipeutils import get_recipe_upstream_version, \
get_recipe_pv_without_srcpv
- (layerbranch, recipe_data, result) = arg
-
pn = recipe_data.getVar('PN', True)
recipe = Recipe.objects.get(layerbranch=layerbranch, pn=pn)
if not recipe:
@@ -179,22 +177,9 @@ if __name__=="__main__":
history = RecipeUpstreamHistory(start_date = datetime.now())
- from oe.utils import ThreadedPool
- import multiprocessing
-
- #nproc = min(multiprocessing.cpu_count(), len(recipes))
- # XXX: The new tinfoil API don't support pythreads so
- # set to 1 while tinfoil have support.
- nproc = 1
- pool = ThreadedPool(nproc, len(recipes))
-
result = []
for recipe_data in recipes:
- pool.add_task(get_upstream_info, (layerbranch,
- recipe_data, result))
-
- pool.start()
- pool.wait_completion()
+ get_upstream_info(layerbranch, recipe_data, result)
history.end_date = datetime.now()
history.save()