diff options
Diffstat (limited to 'sphinx/ext/autodoc.py')
-rw-r--r-- | sphinx/ext/autodoc.py | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/sphinx/ext/autodoc.py b/sphinx/ext/autodoc.py index 1800861ea..70d03f59f 100644 --- a/sphinx/ext/autodoc.py +++ b/sphinx/ext/autodoc.py @@ -322,7 +322,9 @@ class Documenter(object): obj = self.get_attr(obj, part) self.object = obj return True - except (SyntaxError, ImportError, AttributeError), err: + # this used to only catch SyntaxError, ImportError and AttributeError, + # but importing modules with side effects can raise all kinds of errors + except Exception, err: self.directive.warn( 'autodoc can\'t import/find %s %r, it reported error: ' '"%s", please check your spelling and sys.path' % |