Benjamin Schubert pushed to branch bschubert/pipeline at BuildStream / buildstream
Commits:
-
f8c1117c
by Benjamin Schubert at 2019-01-08T21:42:18Z
2 changed files:
Changes:
... | ... | @@ -106,9 +106,10 @@ class BuildQueue(Queue): |
106 | 106 |
# Inform element in main process that assembly is done
|
107 | 107 |
element._assemble_done()
|
108 | 108 |
|
109 |
- # Update the state of all reverse dependencies
|
|
110 |
- for reverse_dependency in element.reverse_build_dependencies():
|
|
111 |
- reverse_dependency._update_state()
|
|
109 |
+ if self.__is_workspaced:
|
|
110 |
+ # Update the state of all reverse dependencies
|
|
111 |
+ for reverse_dependency in element.reverse_build_dependencies(recurse=True):
|
|
112 |
+ reverse_dependency._update_state()
|
|
112 | 113 |
|
113 | 114 |
# This has to be done after _assemble_done, such that the
|
114 | 115 |
# element may register its cache key as required
|
... | ... | @@ -228,6 +228,8 @@ class Element(Plugin): |
228 | 228 |
self.__metadata_workspaced = {} # Boolean of whether it's workspaced
|
229 | 229 |
self.__metadata_workspaced_dependencies = {} # List of which dependencies are workspaced
|
230 | 230 |
|
231 |
+ self.__is_workspaced = None
|
|
232 |
+ |
|
231 | 233 |
# Ensure we have loaded this class's defaults
|
232 | 234 |
self.__init_defaults(plugin_conf)
|
233 | 235 |
|
... | ... | @@ -371,6 +373,13 @@ class Element(Plugin): |
371 | 373 |
#############################################################
|
372 | 374 |
# Public Methods #
|
373 | 375 |
#############################################################
|
376 |
+ @property
|
|
377 |
+ def is_workspaced(self):
|
|
378 |
+ if self.__is_workspaced is None:
|
|
379 |
+ self.__is_workspaced = self._get_workspace() is not None
|
|
380 |
+ |
|
381 |
+ return self.__is_workspaced
|
|
382 |
+
|
|
374 | 383 |
def sources(self):
|
375 | 384 |
"""A generator function to enumerate the element sources
|
376 | 385 |
|