mirror of
https://github.com/sphinx-doc/sphinx.git
synced 2025-02-25 18:55:22 -06:00
autodoc: Show full traceback and exception type in warnings
This commit is contained in:
parent
f6b6d753d7
commit
f3dd6c0bfa
@ -397,8 +397,8 @@ class Documenter:
|
||||
# retry without arguments for old documenters
|
||||
args = self.format_args()
|
||||
except Exception as err:
|
||||
logger.warning(__('error while formatting arguments for %s: %s') %
|
||||
(self.fullname, err), type='autodoc')
|
||||
logger.warning(__('error while formatting arguments for %s:') %
|
||||
self.fullname, type='autodoc', exc_info=True)
|
||||
args = None
|
||||
|
||||
retann = self.retann
|
||||
@ -751,7 +751,7 @@ class Documenter:
|
||||
# be cached anyway)
|
||||
self.analyzer.find_attr_docs()
|
||||
except PycodeError as err:
|
||||
logger.debug('[autodoc] module analyzer failed: %s', err)
|
||||
logger.debug('[autodoc] module analyzer failed:', excinfo=True)
|
||||
# no source file -- e.g. for builtin and C modules
|
||||
self.analyzer = None
|
||||
# at least add the module.__file__ as a dependency
|
||||
|
Loading…
Reference in New Issue
Block a user