summaryrefslogtreecommitdiff
path: root/buildstream/_scheduler/queues/buildqueue.py
diff options
context:
space:
mode:
Diffstat (limited to 'buildstream/_scheduler/queues/buildqueue.py')
-rw-r--r--buildstream/_scheduler/queues/buildqueue.py16
1 files changed, 11 insertions, 5 deletions
diff --git a/buildstream/_scheduler/queues/buildqueue.py b/buildstream/_scheduler/queues/buildqueue.py
index 984a5457a..d05327557 100644
--- a/buildstream/_scheduler/queues/buildqueue.py
+++ b/buildstream/_scheduler/queues/buildqueue.py
@@ -106,10 +106,16 @@ class BuildQueue(Queue):
def done(self, job, element, result, success):
- if success:
- # Inform element in main process that assembly is done
- element._assemble_done()
+ # Inform element in main process that assembly is done
+ element._assemble_done()
- # This has to be done after _assemble_done, such that the
- # element may register its cache key as required
+ # This has to be done after _assemble_done, such that the
+ # element may register its cache key as required
+ #
+ # FIXME: Element._assemble() does not report both the failure state and the
+ # size of the newly cached failed artifact, so we can only adjust the
+ # artifact cache size for a successful build even though we know a
+ # failed build also grows the artifact cache size.
+ #
+ if success:
self._check_cache_size(job, element, result)