From 6fbbf3614356474d81395c88d5a43e5e57460fb8 Mon Sep 17 00:00:00 2001 From: Lex Berezhny Date: Fri, 7 Feb 2020 18:44:30 -0500 Subject: [PATCH] pylint --- lbry/error/generate.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/lbry/error/generate.py b/lbry/error/generate.py index 677cad8c2..1752e8452 100644 --- a/lbry/error/generate.py +++ b/lbry/error/generate.py @@ -52,7 +52,7 @@ class ErrorClass: def get_arguments(self): args = ['self'] - for arg in re.findall('{([a-z0-1_\(\)]+)}', self.message): + for arg in re.findall('{([a-z0-1_()]+)}', self.message): for func in FUNCTIONS: if arg.startswith(f'{func}('): arg = arg[len(f'{func}('):-1] @@ -60,7 +60,8 @@ class ErrorClass: args.append(arg) return args - def get_fields(self, args): + @staticmethod + def get_fields(args): if len(args) > 1: return f''.join(f'\n{INDENT*2}self.{field} = {field}' for field in args[1:]) return ''