From 14d03c2971723ed5100e847ba5c82bd924432196 Mon Sep 17 00:00:00 2001 From: Justin Drew <2396364+jdrew82@users.noreply.github.com> Date: Wed, 20 Mar 2024 14:42:36 -0500 Subject: [PATCH] Try the other two options --- nornir_nautobot/plugins/tasks/dispatcher/default.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/nornir_nautobot/plugins/tasks/dispatcher/default.py b/nornir_nautobot/plugins/tasks/dispatcher/default.py index 7296121..0fbc55f 100644 --- a/nornir_nautobot/plugins/tasks/dispatcher/default.py +++ b/nornir_nautobot/plugins/tasks/dispatcher/default.py @@ -173,7 +173,7 @@ def generate_config( )[0].result except NornirSubTaskError as exc: if isinstance(exc.result.exception, jinja2.exceptions.UndefinedError): # pylint: disable=no-else-raise - error_msg = f"`E1010:` There was a jinja2.exceptions.UndefinedError error: ``{str(exc.result.exception)}`` and ``{str(exc.result.exception.__traceback__.tb_lasti)}``" + error_msg = f"`E1010:` There was a jinja2.exceptions.UndefinedError error: ``{str(exc.result.exception)}`` and ``{str(exc.result.exception.__traceback__.tb_frame)}`` and ``{str(exc.result.exception.__traceback__.tb_lineno)}``" logger.error(error_msg, extra={"object": obj, "exc_info": True}) raise NornirNautobotException(error_msg)