diff options
author | dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> | 2022-12-27 00:13:13 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-12-27 00:13:13 +0100 |
commit | a96e05bf73b6fbba8edf78aa9adde3e1faa16b66 (patch) | |
tree | 9256f4b7f9756fcba52263036e087c19179d4aed /astroid/nodes/as_string.py | |
parent | 3894c593f5266d8692b8b5b4ebe83c0c9ae4c946 (diff) | |
download | astroid-git-a96e05bf73b6fbba8edf78aa9adde3e1faa16b66.tar.gz |
Bump pylint from 2.15.8 to 2.15.9 (#1907)
Diffstat (limited to 'astroid/nodes/as_string.py')
-rw-r--r-- | astroid/nodes/as_string.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/astroid/nodes/as_string.py b/astroid/nodes/as_string.py index ace70909..cbd5ee17 100644 --- a/astroid/nodes/as_string.py +++ b/astroid/nodes/as_string.py @@ -588,7 +588,7 @@ class AsStringVisitor: def visit_matchclass(self, node: MatchClass) -> str: """Return an astroid.MatchClass node as string.""" if node.cls is None: - raise Exception(f"{node} does not have a 'cls' node") + raise AssertionError(f"{node} does not have a 'cls' node") class_strings: list[str] = [] if node.patterns: class_strings.extend(p.accept(self) for p in node.patterns) @@ -617,7 +617,7 @@ class AsStringVisitor: def visit_matchor(self, node: MatchOr) -> str: """Return an astroid.MatchOr node as string.""" if node.patterns is None: - raise Exception(f"{node} does not have pattern nodes") + raise AssertionError(f"{node} does not have pattern nodes") return " | ".join(p.accept(self) for p in node.patterns) # These aren't for real AST nodes, but for inference objects. |