From 8db8f3e6c4218a29c02e743647883165b9551cf1 Mon Sep 17 00:00:00 2001 From: Fabio Manganiello Date: Sat, 3 Apr 2021 16:12:51 +0200 Subject: [PATCH] Unparseable context variables should be logged on debug, not warning, level. --- platypush/message/request/__init__.py | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/platypush/message/request/__init__.py b/platypush/message/request/__init__.py index f29e56959..f53aea00b 100644 --- a/platypush/message/request/__init__.py +++ b/platypush/message/request/__init__.py @@ -132,9 +132,8 @@ class Request(Message): try: exec('{}="{}"'.format(k, re.sub(r'(^|[^\\])"', '\1\\"', v))) except Exception as e: - logger.warning('Could not set context variable {}={}'.format(k, v)) - logger.warning('Context: {}'.format(context)) - logger.exception(e) + logger.debug('Could not set context variable {}={}: {}'.format(k, v, str(e))) + logger.debug('Context: {}'.format(context)) parsed_value = '' if not isinstance(_value, str):