diff options
author | Tristan Van Berkom <tristan.van.berkom@gmail.com> | 2018-07-31 06:32:15 +0000 |
---|---|---|
committer | Tristan Van Berkom <tristan.van.berkom@gmail.com> | 2018-07-31 06:32:15 +0000 |
commit | 5171cb0ebc9f5d372820e33463b4192fbbc6ec64 (patch) | |
tree | 2d892ad81c7de2ae4f112d125e5b266ae918eef0 | |
parent | a4c9e5b2c1032eaebecc59a7ebf455bcabd7f0f6 (diff) | |
parent | 58cfe019e484a755b9ecebabb8a9eb49070807eb (diff) | |
download | buildstream-5171cb0ebc9f5d372820e33463b4192fbbc6ec64.tar.gz |
Merge branch 'tpollard/386-cherrypick' into 'bst-1.2'
widget.py: Limit failure summary to currently failing elements (#386)
See merge request BuildStream/buildstream!589
-rw-r--r-- | buildstream/_frontend/widget.py | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/buildstream/_frontend/widget.py b/buildstream/_frontend/widget.py index dab8cab56..1bae73ca0 100644 --- a/buildstream/_frontend/widget.py +++ b/buildstream/_frontend/widget.py @@ -522,12 +522,15 @@ class LogLine(Widget): text += "\n\n" if self._failure_messages: - text += self.content_profile.fmt("Failure Summary\n", bold=True) values = OrderedDict() for element, messages in sorted(self._failure_messages.items(), key=lambda x: x[0].name): - values[element.name] = ''.join(self._render(v) for v in messages) - text += self._format_values(values, style_value=False) + for queue in stream.queues: + if any(el.name == element.name for el in queue.failed_elements): + values[element.name] = ''.join(self._render(v) for v in messages) + if values: + text += self.content_profile.fmt("Failure Summary\n", bold=True) + text += self._format_values(values, style_value=False) text += self.content_profile.fmt("Pipeline Summary\n", bold=True) values = OrderedDict() |