From d8cfdea704e5eb8350d92ad6a728a652f09d7ae9 Mon Sep 17 00:00:00 2001 From: JonnyWong16 Date: Fri, 4 May 2018 15:52:04 -0700 Subject: [PATCH] Log individual condition evalutation --- plexpy/notification_handler.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/plexpy/notification_handler.py b/plexpy/notification_handler.py index 8ffc42aa..5010c67e 100644 --- a/plexpy/notification_handler.py +++ b/plexpy/notification_handler.py @@ -256,7 +256,7 @@ def notify_custom_conditions(notifier_id=None, parameters=None): elif parameter_type == 'float': values = [helpers.cast_to_float(v) for v in values] - + except ValueError as e: logger.error(u"Tautulli NotificationHandler :: Unable to cast condition '%s', values '%s', to type '%s'." % (parameter, values, parameter_type)) @@ -317,7 +317,9 @@ def notify_custom_conditions(notifier_id=None, parameters=None): else: evaluated_logic = all(evaluated_conditions[1:]) - logger.debug(u"Tautulli NotificationHandler :: Custom condition evaluated to '%s'." % str(evaluated_logic)) + logger.debug(u"Tautulli NotificationHandler :: Custom condition evaluated to '{}'. Conditions: {}.".format( + evaluated_logic, evaluated_conditions[1:])) + return evaluated_logic return True