From 7873e6d800d75119730c7cd8ff1152fe08aa1c49 Mon Sep 17 00:00:00 2001 From: "Gael Chamoulaud (Strider)" Date: Tue, 20 Oct 2020 15:21:54 +0200 Subject: [PATCH] [Validator Show Run] Display simplified results by default This patch is displaying the content of the validation_output dictionary which is a simplified output content (the former validation_output) instead of dumping the entire log file in the stdout. It also fixes the --full argument which was True forever! Change-Id: Id94132d23d272d383b65a839a75b08f855fb6be3 Signed-off-by: Gael Chamoulaud (Strider) (cherry picked from commit 4229bee94016ad5a78dd8455f282a8e7f4a3d28e) --- tripleoclient/v1/tripleo_validator.py | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/tripleoclient/v1/tripleo_validator.py b/tripleoclient/v1/tripleo_validator.py index b6c1fbf99..77440def3 100644 --- a/tripleoclient/v1/tripleo_validator.py +++ b/tripleoclient/v1/tripleo_validator.py @@ -408,7 +408,6 @@ class TripleOValidatorShowRun(command.Command): parser.add_argument('--full', action='store_true', - default=True, help='Show Full Details for the run') return parser @@ -422,8 +421,10 @@ class TripleOValidatorShowRun(command.Command): print(json.dumps(d, indent=4, sort_keys=True)) else: for d in data: - for p in d['plays']: - print(json.dumps(p['tasks'], indent=4, sort_keys=True)) + for p in d.get('validation_output', []): + print(json.dumps(p['tasks'], + indent=4, + sort_keys=True)) else: raise exceptions.CommandError( "Could not find the log file linked to this UUID: %s" %