From 45e0822fe25a925ca1f0b1c793b53ad089e0fcf4 Mon Sep 17 00:00:00 2001 From: NannoSilver Date: Sun, 17 Nov 2024 14:21:31 -0300 Subject: [PATCH] Removes a new line (\n) symbol that is messing the logged Exception error message Logs should be recorded in a single line, but this Exceptions is generating error messages with the new line symbol, that is breaking the message, leading to 2 lines error messages in the logs. --- func_timeout/exceptions.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/func_timeout/exceptions.py b/func_timeout/exceptions.py index cd0d130..0a3a3ae 100644 --- a/func_timeout/exceptions.py +++ b/func_timeout/exceptions.py @@ -73,7 +73,7 @@ def getMsg(self): else: timedOutAfterStr = "Unknown" - return 'Function %s (args=%s) (kwargs=%s) timed out after %s seconds.\n' %(timedOutFuncName, repr(self.timedOutArgs), repr(self.timedOutKwargs), timedOutAfterStr) + return 'Function %s (args=%s) (kwargs=%s) timed out after %s seconds. ' %(timedOutFuncName, repr(self.timedOutArgs), repr(self.timedOutKwargs), timedOutAfterStr) def retry(self, timeout=RETRY_SAME_TIMEOUT): '''