From: Simon Marchi Date: Mon, 2 Dec 2019 16:35:11 +0000 (-0500) Subject: bt2: reverse order of printed causes in _Error.__str__ X-Git-Tag: v2.0.0~50 X-Git-Url: http://git.efficios.com/?p=babeltrace.git;a=commitdiff_plain;h=701698c8de3db89105f62ad3008f55db665c2059 bt2: reverse order of printed causes in _Error.__str__ To match how the CLI prints them. Change-Id: Ief913b119b169bf9f620531f8763db93e19bda27 Reviewed-on: https://review.lttng.org/c/babeltrace/+/2556 CI-Build: Simon Marchi Tested-by: jenkins Reviewed-by: Simon Marchi --- diff --git a/src/bindings/python/bt2/bt2/error.py b/src/bindings/python/bt2/bt2/error.py index 4e3e53f0..a50827a8 100644 --- a/src/bindings/python/bt2/bt2/error.py +++ b/src/bindings/python/bt2/bt2/error.py @@ -213,6 +213,6 @@ class _Error(Exception, abc.Sequence): def __str__(self): s = self._msg + '\n' - for c in self: + for c in reversed(self): s += str(c) + '\n' return s