From ba24d4cac220183fefac64314afc5fd8d19ab671 Mon Sep 17 00:00:00 2001 From: tierno Date: Tue, 22 Sep 2020 10:38:22 +0000 Subject: [PATCH] Providing output info when exec_primitive fails Change-Id: I5d35e524acf89eaa4a15e468a00c0d3e818f9a93 Signed-off-by: tierno --- n2vc/k8s_juju_conn.py | 2 +- n2vc/n2vc_juju_conn.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/n2vc/k8s_juju_conn.py b/n2vc/k8s_juju_conn.py index e3f3267..c8be80c 100644 --- a/n2vc/k8s_juju_conn.py +++ b/n2vc/k8s_juju_conn.py @@ -604,7 +604,7 @@ class K8sJujuConnector(K8sConnector): if status != "completed": raise K8sException( - "status is not completed: {} output: {}".format(status, output) + "status: {}, output: {}".format(status, output) ) return output diff --git a/n2vc/n2vc_juju_conn.py b/n2vc/n2vc_juju_conn.py index 690d3be..951ac6c 100644 --- a/n2vc/n2vc_juju_conn.py +++ b/n2vc/n2vc_juju_conn.py @@ -922,7 +922,7 @@ class N2VCJujuConnector(N2VCConnector): if status == "completed": return output else: - raise Exception("status is not completed: {}".format(status)) + raise Exception("status: {}, output: {}".format(status, output)) except Exception as e: self.log.error( "Error executing primitive {}: {}".format(primitive_name, e) -- 2.25.1