summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTristan Van Berkom <tristan.vanberkom@codethink.co.uk>2019-05-09 17:15:55 +0900
committerTristan Van Berkom <tristan.vanberkom@codethink.co.uk>2019-05-09 17:29:15 +0900
commitb17a5e071a5abc76f57aae1f7ab7194f55b40360 (patch)
tree36fe68a00394588b7d0e83e85489635a32c47a80
parent879dca35de4c09a3c05f671ba8cca1aeeb958996 (diff)
downloadbuildstream-b17a5e071a5abc76f57aae1f7ab7194f55b40360.tar.gz
element.py: Update state on reverse dependencies when strict key is resolved.
When calculating the strict key, we do not know for sure yet that the element is required or whether it will ever have a cache key, as we could be tracking elements which will result in resolving an element which is a build-only dependency of the target. This ensures that we process all elements which need to be processed, which is important for cases where we are building in non-strict mode and tracking is also enabled. This fixes issue #1014
-rw-r--r--buildstream/element.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/buildstream/element.py b/buildstream/element.py
index b98675720..3bdf601c1 100644
--- a/buildstream/element.py
+++ b/buildstream/element.py
@@ -2568,9 +2568,11 @@ class Element(Plugin):
element = queue.pop()
old_ready_for_runtime = element.__ready_for_runtime
+ old_strict_cache_key = element.__strict_cache_key
element._update_state()
- if element.__ready_for_runtime != old_ready_for_runtime:
+ if element.__ready_for_runtime != old_ready_for_runtime or \
+ element.__strict_cache_key != old_strict_cache_key:
for rdep in element.__reverse_dependencies:
queue.push(rdep._unique_id, rdep)