diff options
author | Jürg Billeter <j@bitron.ch> | 2018-01-23 11:01:34 +0000 |
---|---|---|
committer | Jürg Billeter <j@bitron.ch> | 2018-01-23 12:03:37 +0000 |
commit | a9f72b71a946b9b92cf8e4538e5d7e21a12dae47 (patch) | |
tree | 582c94f05f978bc2f42c84a9dbea259efadfa67b | |
parent | 68cef134a22f1df01f0c33c024a99555319f86df (diff) | |
download | buildstream-a9f72b71a946b9b92cf8e4538e5d7e21a12dae47.tar.gz |
pullqueue.py: Wait for cache to become queryable
Wait for cache to become queryable instead of simply skipping the
element.
-rw-r--r-- | buildstream/_scheduler/pullqueue.py | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/buildstream/_scheduler/pullqueue.py b/buildstream/_scheduler/pullqueue.py index 3ab5ab7f4..38de9cf09 100644 --- a/buildstream/_scheduler/pullqueue.py +++ b/buildstream/_scheduler/pullqueue.py @@ -39,6 +39,13 @@ class PullQueue(Queue): return element._pull() def status(self, element): + # state of dependencies may have changed, recalculate element state + element._update_state() + + # cache cannot be queried until strict cache key is available + if element._get_strict_cache_key() is None: + return QueueStatus.WAIT + if element._cached(strength=_KeyStrength.STRONG): return QueueStatus.SKIP elif element._remotely_cached(strength=_KeyStrength.STRONG): |