From dc86f6f6d571f3ea732bd8f0be299dbbb23afd48 Mon Sep 17 00:00:00 2001 From: Fabio Alessandro Locati Date: Wed, 20 Dec 2017 05:33:11 +0100 Subject: [PATCH] Easier to debug (#30675) --- lib/ansible/modules/net_tools/basics/uri.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/ansible/modules/net_tools/basics/uri.py b/lib/ansible/modules/net_tools/basics/uri.py index 1d778858d2..199f2aa025 100644 --- a/lib/ansible/modules/net_tools/basics/uri.py +++ b/lib/ansible/modules/net_tools/basics/uri.py @@ -489,7 +489,7 @@ def main(): u_content = to_text(content, encoding=content_encoding) if resp['status'] not in status_code: - uresp['msg'] = 'Status code was not %s: %s' % (status_code, uresp.get('msg', '')) + uresp['msg'] = 'Status code was %s and not %s: %s' % (resp['status'], status_code, uresp.get('msg', '')) module.fail_json(content=u_content, **uresp) elif return_content: module.exit_json(changed=changed, content=u_content, **uresp)