Skip to content

Commit

Permalink
Fix mypy
Browse files Browse the repository at this point in the history
  • Loading branch information
tristanlatr committed Apr 3, 2024
1 parent 943092a commit 011ebcf
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions pydoctor/astbuilder.py
Original file line number Diff line number Diff line change
Expand Up @@ -186,6 +186,10 @@ def _handleReExport(info:'ReExport', elsewhere:Collection['ReExport']) -> None:
as_name = info.as_name
target_parent = target.parent

if target_parent is None:
# TODO: warn because we can't reparent a root module
return None

Check warning on line 191 in pydoctor/astbuilder.py

View check run for this annotation

Codecov / codecov/patch

pydoctor/astbuilder.py#L191

Added line #L191 was not covered by tests

# Remember that this name is re-exported
target_parent.exported[target.name] = target

Expand Down

0 comments on commit 011ebcf

Please sign in to comment.