Skip to content

Commit

Permalink
Fix #7727: autosummary raises PycodeError for namespace python package
Browse files Browse the repository at this point in the history
  • Loading branch information
tk0miya committed Nov 8, 2020
1 parent 1193d83 commit 787444f
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
2 changes: 2 additions & 0 deletions CHANGES
Expand Up @@ -16,6 +16,8 @@ Features added
Bugs fixed
----------

* #7727: autosummary: raise PycodeError when documenting python package
without __init__.py
* #8364: C, properly initialize attributes in empty symbols.

Testing
Expand Down
2 changes: 1 addition & 1 deletion sphinx/ext/autosummary/__init__.py
Expand Up @@ -691,7 +691,7 @@ def import_ivar_by_name(name: str, prefixes: List[str] = [None]) -> Tuple[str, A
analyzer = ModuleAnalyzer.for_module(modname)
if (qualname, attr) in analyzer.find_attr_docs():
return real_name + "." + attr, INSTANCEATTR, obj, modname
except (ImportError, ValueError):
except (ImportError, ValueError, PycodeError):
pass

raise ImportError
Expand Down

0 comments on commit 787444f

Please sign in to comment.