From 2f64d6fcfb016ecfe0c640c01f930a58929fb20c Mon Sep 17 00:00:00 2001 From: Brian Coca Date: Wed, 11 Apr 2018 11:52:12 -0400 Subject: Ensure non ansilbe exceptions keep tracebacks (#37523) (cherry picked from commit d9430b79f99362731282d675640057808abd79c9) --- lib/ansible/inventory/manager.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/ansible/inventory/manager.py b/lib/ansible/inventory/manager.py index 133809e5b8..719a333e9b 100644 --- a/lib/ansible/inventory/manager.py +++ b/lib/ansible/inventory/manager.py @@ -270,7 +270,7 @@ class InventoryManager(object): failures.append({'src': source, 'plugin': plugin_name, 'exc': e}) except Exception as e: display.debug('%s failed to parse %s' % (plugin_name, to_text(source))) - failures.append({'src': source, 'plugin': plugin_name, 'exc': e}) + failures.append({'src': source, 'plugin': plugin_name, 'exc': AnsibleError(e)}) else: display.debug('%s did not meet %s requirements' % (to_text(source), plugin_name)) else: -- cgit v1.2.1