Fix error handling when setting has a parse error
The code was an integer. It needs to be converted to a string in order to be added to other strings. Contributes to issue CURA-2572.
Esse commit está contido em:
+1
-1
@@ -235,7 +235,7 @@ class Setting:
|
||||
tree = ast.parse(code, "eval")
|
||||
compiled = compile(code, self._key, "eval")
|
||||
except (SyntaxError, TypeError) as e:
|
||||
print("Parse error in function (" + code + ") for setting", self._key + ":", str(e))
|
||||
print("Parse error in function (" + str(code) + ") for setting", self._key + ":", str(e))
|
||||
except IllegalMethodError as e:
|
||||
print("Use of illegal method", str(e), "in function (" + code + ") for setting", self._key)
|
||||
except Exception as e:
|
||||
|
||||
Referência em uma Nova Issue
Bloquear um usuário