AttributeError: 'Values' object has no attribute 'tab_width' when running sphinx-build
AttributeError: 'Values' object has no attribute 'tab_width' when running sphinx-build
当运行:
sphinx-build -M html . _build
我收到以下错误:
Running Sphinx v3.0.3
building [mo]: targets for 0 po files that are out of date
building [html]: targets for 9 source files that are out of date
updating environment: [new config] 9 added, 0 changed, 0 removed
/home/vinzee/.pyenv/versions/3.6.14/envs/venv/lib/python3.6/site-packages/recommonmark/parser.py:75: UserWarning: Container node skipped: type=document
warn("Container node skipped: type={0}".format(mdnode.t))
reading sources... [ 66%] api
Exception occurred:
File "/home/vinzee/.pyenv/versions/3.6.14/envs/venv/lib/python3.6/site-packages/sphinx/ext/autodoc/__init__.py", line 440, in get_doc
tab_width = self.directive.state.document.settings.tab_width
AttributeError: 'Values' object has no attribute 'tab_width'
The full traceback has been saved in /tmp/sphinx-err-tm3jn6xm.log, if you want to report the issue to the developers.
Please also report this if it was a user error, so that a better error message can be provided next time.
A bug report can be filed in the tracker at <https://github.com/sphinx-doc/sphinx/issues>. Thanks!
我的版本:
Python: 3.6.14
sphinx-build: 3.0.3
如何解决这个错误?
固定 docutils<=0.16
有效。
我在 Sphinx github repository 上找到了答案。
所有 docutils>0.16
版本都存在该错误。
当运行:
sphinx-build -M html . _build
我收到以下错误:
Running Sphinx v3.0.3
building [mo]: targets for 0 po files that are out of date
building [html]: targets for 9 source files that are out of date
updating environment: [new config] 9 added, 0 changed, 0 removed
/home/vinzee/.pyenv/versions/3.6.14/envs/venv/lib/python3.6/site-packages/recommonmark/parser.py:75: UserWarning: Container node skipped: type=document
warn("Container node skipped: type={0}".format(mdnode.t))
reading sources... [ 66%] api
Exception occurred:
File "/home/vinzee/.pyenv/versions/3.6.14/envs/venv/lib/python3.6/site-packages/sphinx/ext/autodoc/__init__.py", line 440, in get_doc
tab_width = self.directive.state.document.settings.tab_width
AttributeError: 'Values' object has no attribute 'tab_width'
The full traceback has been saved in /tmp/sphinx-err-tm3jn6xm.log, if you want to report the issue to the developers.
Please also report this if it was a user error, so that a better error message can be provided next time.
A bug report can be filed in the tracker at <https://github.com/sphinx-doc/sphinx/issues>. Thanks!
我的版本:
Python: 3.6.14
sphinx-build: 3.0.3
如何解决这个错误?
固定 docutils<=0.16
有效。
我在 Sphinx github repository 上找到了答案。
所有 docutils>0.16
版本都存在该错误。