diff options
author | Takeshi KOMIYA <i.tkomiya@gmail.com> | 2022-06-03 02:29:39 +0900 |
---|---|---|
committer | Takeshi KOMIYA <i.tkomiya@gmail.com> | 2022-06-03 02:29:39 +0900 |
commit | ce345a2f28f46e75e493ce5c35e7f991437f817d (patch) | |
tree | 8c2f1abaad91ac6d092448793a58a45aaad8e148 /sphinx/ext/autosummary/generate.py | |
parent | ab58bbaed71293bf8f5738f386b853b17b4190eb (diff) | |
download | sphinx-git-ce345a2f28f46e75e493ce5c35e7f991437f817d.tar.gz |
Fix #10509: autosummary: autosummary fails with a shared library
Diffstat (limited to 'sphinx/ext/autosummary/generate.py')
-rw-r--r-- | sphinx/ext/autosummary/generate.py | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/sphinx/ext/autosummary/generate.py b/sphinx/ext/autosummary/generate.py index 5ef7b0352..3db7eb989 100644 --- a/sphinx/ext/autosummary/generate.py +++ b/sphinx/ext/autosummary/generate.py @@ -155,8 +155,12 @@ class ModuleScanner: def scan(self, imported_members: bool) -> List[str]: members = [] - analyzer = ModuleAnalyzer.for_module(self.object.__name__) - attr_docs = analyzer.find_attr_docs() + try: + analyzer = ModuleAnalyzer.for_module(self.object.__name__) + attr_docs = analyzer.find_attr_docs() + except PycodeError: + attr_docs = {} + for name in members_of(self.object, self.app.config): try: value = safe_getattr(self.object, name) |