diff --git a/pre_commit_hooks/debug_statement_hook.py b/pre_commit_hooks/debug_statement_hook.py index 7f64a23..a083bb3 100644 --- a/pre_commit_hooks/debug_statement_hook.py +++ b/pre_commit_hooks/debug_statement_hook.py @@ -22,7 +22,7 @@ DEBUG_STATEMENTS = { DEBUG_CALL_STATEMENTS = { 'breakpoint', - 'print' + 'print', } @@ -50,7 +50,10 @@ class DebugStatementParser(ast.NodeVisitor): def visit_Call(self, node: ast.Call) -> None: """python3.7+ breakpoint()""" - if isinstance(node.func, ast.Name) and node.func.id in DEBUG_CALL_STATEMENTS: + if ( + isinstance(node.func, ast.Name) and + node.func.id in DEBUG_CALL_STATEMENTS + ): st = Debug(node.lineno, node.col_offset, node.func.id, 'called') self.breakpoints.append(st) self.generic_visit(node)