diff --git a/deal/linter/_extractors/common.py b/deal/linter/_extractors/common.py index 8fe40550..a922c158 100644 --- a/deal/linter/_extractors/common.py +++ b/deal/linter/_extractors/common.py @@ -81,10 +81,11 @@ def _traverse_astroid(node: astroid.NodeNG) -> Iterator[astroid.NodeNG]: todo: deque[astroid.NodeNG] = deque([node]) while todo: node = todo.popleft() - if isinstance(node, astroid.TryExcept): + if isinstance(node, astroid.Try): for h in node.handlers: todo.extend(h.body) todo.extend(node.orelse) + todo.extend(node.finalbody) else: todo.extend(node.get_children()) yield node diff --git a/pyproject.toml b/pyproject.toml index d0500bea..80e85e7c 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -25,16 +25,16 @@ classifiers = [ [tool.flit.metadata.requires-extra] all = [ - "astroid>=2.11.0", # for tyupe inference in linter - "deal-solver", # for formal verification - "hypothesis", # for test generation - "pygments", # for syntax highlighting in exceptions - "typeguard>=3.0.0", # for runtime type checking in tests - "vaa>=0.2.1", # for supporting schemes (like marshmallow) as validators + "astroid>=2.11.0", # for tyupe inference in linter + "deal-solver>=0.1.2", # for formal verification + "hypothesis", # for test generation + "pygments", # for syntax highlighting in exceptions + "typeguard>=3.0.0", # for runtime type checking in tests + "vaa>=0.2.1", # for supporting schemes (like marshmallow) as validators ] integration = [ # integration tests "astroid>=2.11.0", - "deal-solver", + "deal-solver>=0.1.2", "hypothesis", "pygments", "typeguard<4.0.0", @@ -61,7 +61,7 @@ lint = [ "unify", # copy-pasted "all" extra - "deal-solver", + "deal-solver>=0.1.2", "hypothesis", "pygments", "typeguard<4.0.0",