summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJürg Billeter <j@bitron.ch>2017-07-18 12:10:31 +0200
committerJürg Billeter <j@bitron.ch>2017-07-20 07:24:56 +0200
commitfc65bf7ba5ede46f863e59f6b4bb4bc7b60d1735 (patch)
tree9e098bafb9719da7eeb8ef9658d1d4b5dca12e96
parent20392aa3fa0a21b6b559f0f7c65c4b07f27d3ca4 (diff)
downloadbuildstream-fc65bf7ba5ede46f863e59f6b4bb4bc7b60d1735.tar.gz
pullqueue.py: Update skip rules
-rw-r--r--buildstream/_scheduler/pullqueue.py14
1 files changed, 13 insertions, 1 deletions
diff --git a/buildstream/_scheduler/pullqueue.py b/buildstream/_scheduler/pullqueue.py
index 4a6cafc1c..b21267eb3 100644
--- a/buildstream/_scheduler/pullqueue.py
+++ b/buildstream/_scheduler/pullqueue.py
@@ -39,7 +39,19 @@ class PullQueue(Queue):
return element._pull()
def skip(self, element):
- return element._cached(strength=_KeyStrength.STRONG)
+ if element._cached(strength=_KeyStrength.STRONG):
+ return True
+ elif element._remotely_cached(strength=_KeyStrength.STRONG):
+ # pull artifact using strong key
+ return False
+ elif element._cached():
+ return True
+ elif element._remotely_cached():
+ # pull artifact using weak key
+ return False
+ else:
+ # nothing to pull
+ return True
def done(self, element, result, returncode):