summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBenjamin Schubert <ben.c.schubert@gmail.com>2019-01-15 11:38:40 +0000
committerTristan Van Berkom <tristan.vanberkom@codethink.co.uk>2019-03-24 21:24:24 +0900
commit1b8d04f33bb9b51bdd4655252fc26a569ae45006 (patch)
treed1381a7501e212cecc80df6ae299fe4a05d88245
parent565b6ee77806c2b6cc7ca5545b45518a818a5e2e (diff)
downloadbuildstream-1b8d04f33bb9b51bdd4655252fc26a569ae45006.tar.gz
Don't update state before summary. It should be consistent
Since we know when an object's state can change, we don't need to update the state of all objects for consistency.
-rw-r--r--buildstream/_stream.py13
1 files changed, 1 insertions, 12 deletions
diff --git a/buildstream/_stream.py b/buildstream/_stream.py
index 5d862de91..de3ae464c 100644
--- a/buildstream/_stream.py
+++ b/buildstream/_stream.py
@@ -28,7 +28,7 @@ import tarfile
from contextlib import contextmanager
from tempfile import TemporaryDirectory
-from ._exceptions import StreamError, ImplError, BstError, set_last_task_error
+from ._exceptions import StreamError, ImplError, BstError
from ._message import Message, MessageType
from ._scheduler import Scheduler, SchedStatus, TrackQueue, FetchQueue, BuildQueue, PullQueue, PushQueue
from ._pipeline import Pipeline, PipelineSelection
@@ -1007,17 +1007,6 @@ class Stream():
_, status = self._scheduler.run(self.queues)
- # Force update element states after a run, such that the summary
- # is more coherent
- try:
- for element in self.total_elements:
- element._update_state()
- except BstError as e:
- self._message(MessageType.ERROR, "Error resolving final state", detail=str(e))
- set_last_task_error(e.domain, e.reason)
- except Exception as e: # pylint: disable=broad-except
- self._message(MessageType.BUG, "Unhandled exception while resolving final state", detail=str(e))
-
if status == SchedStatus.ERROR:
raise StreamError()
elif status == SchedStatus.TERMINATED: