classification
Title: Documentation fails to build when using Sphinx' texinfo builder
Type: Stage: resolved
Components: Documentation Versions: Python 3.8
process
Status: closed Resolution: fixed
Dependencies: Superseder:
Assigned To: docs@python Nosy List: SilentGhost, docs@python, doko, mdk, mitya57, steve.dower
Priority: normal Keywords: patch

Created on 2019-07-05 09:49 by doko, last changed 2019-09-10 14:52 by steve.dower. This issue is now closed.

Pull Requests
URL Status Linked Edit
PR 14606 merged mitya57, 2019-07-05 19:37
PR 15866 merged miss-islington, 2019-09-10 14:41
Messages (5)
msg347322 - (view) Author: Matthias Klose (doko) * (Python committer) Date: 2019-07-05 09:49
3.8 b2 now requires sphinx2 (according to SilentGhost on IRC), but only has documented 1.8. I'm aware of issue #36007, the last time that the requirements were bumped.

So again, the dependencies were bumped without documenting, and why do we require the latest sphinx again?

It's difficult to provide the documentation as a Linux distro when you always have to provide the latest build tools.  Please compare that to other projects that are usually fine to build with any doxygen, texinfo, or whatever doc tool.

Any hint where the new dependency was introduced, and probably can be backed out?

The actuall error is:
writing... 
Exception occurred:
  File "/usr/lib/python3/dist-packages/docutils/nodes.py", line 567, in __getitem__
    return self.attributes[key]
KeyError: 'cols'



# Sphinx version: 1.8.4
# Python version: 3.7.3 (CPython)
# Docutils version: 0.14 
# Jinja2 version: 2.10
# Last messages:
#   distutils/sourcedist
#   distutils/builtdist
#   distutils/examples
#   distutils/extending
#   distutils/commandref
#   distutils/apiref
#   install/index
#   
#   resolving references...
#   writing...
# Loaded extensions:
#   sphinx.ext.mathjax (1.8.4) from /usr/lib/python3/dist-packages/sphinx/ext/mathjax.py
#   alabaster (0.7.8) from /usr/lib/python3/dist-packages/alabaster/__init__.py
#   sphinx.ext.coverage (1.8.4) from /usr/lib/python3/dist-packages/sphinx/ext/coverage.py
#   sphinx.ext.doctest (1.8.4) from /usr/lib/python3/dist-packages/sphinx/ext/doctest.py
#   pyspecific (1.0) from /home/packages/python/3.8/python3.8-3.8.0~b2/Doc/tools/extensions/pyspecific.py
#   c_annotations (1.0) from /home/packages/python/3.8/python3.8-3.8.0~b2/Doc/tools/extensions/c_annotations.py
#   escape4chm (1.0) from /home/packages/python/3.8/python3.8-3.8.0~b2/Doc/tools/extensions/escape4chm.py
Traceback (most recent call last):
  File "/usr/lib/python3/dist-packages/sphinx/cmd/build.py", line 304, in build_main
    app.build(args.force_all, filenames)
  File "/usr/lib/python3/dist-packages/sphinx/application.py", line 341, in build
    self.builder.build_update()
  File "/usr/lib/python3/dist-packages/sphinx/builders/__init__.py", line 342, in build_update
    self.build(['__all__'], to_build)
  File "/usr/lib/python3/dist-packages/sphinx/builders/__init__.py", line 412, in build
    self.write(docnames, list(updated_docnames), method)
  File "/usr/lib/python3/dist-packages/sphinx/builders/texinfo.py", line 187, in write
    docwriter.write(doctree, destination)
  File "/usr/lib/python3/dist-packages/docutils/writers/__init__.py", line 80, in write
    self.translate()
  File "/usr/lib/python3/dist-packages/sphinx/writers/texinfo.py", line 139, in translate
    self.document.walkabout(visitor)
  File "/usr/lib/python3/dist-packages/docutils/nodes.py", line 174, in walkabout
    if child.walkabout(visitor):
  File "/usr/lib/python3/dist-packages/docutils/nodes.py", line 174, in walkabout
    if child.walkabout(visitor):
  File "/usr/lib/python3/dist-packages/docutils/nodes.py", line 174, in walkabout
    if child.walkabout(visitor):
  [Previous line repeated 9 more times]
  File "/usr/lib/python3/dist-packages/docutils/nodes.py", line 166, in walkabout
    visitor.dispatch_visit(self)
  File "/usr/lib/python3/dist-packages/docutils/nodes.py", line 1882, in dispatch_visit
    return method(node)
  File "/usr/lib/python3/dist-packages/sphinx/writers/texinfo.py", line 1126, in visit_tgroup
    self.n_cols = node['cols']
  File "/usr/lib/python3/dist-packages/docutils/nodes.py", line 567, in __getitem__
    return self.attributes[key]
KeyError: 'cols'
msg347327 - (view) Author: Matthias Klose (doko) * (Python committer) Date: 2019-07-05 10:12
so this might not be a sphinx 2.x issue, the docs build fine for the html output, but the reported error is for building the texinfo files:

make -C Doc texinfo

That worked for 3.8 b1.
msg351678 - (view) Author: Steve Dower (steve.dower) * (Python committer) Date: 2019-09-10 14:40
New changeset c3d679fd398f42a2e489fbe3dab17fac1fb2439c by Steve Dower (Dmitry Shachnev) in branch 'master':
bpo-37504: Fix documentation build with texinfo builder (GH-14606)
https://github.com/python/cpython/commit/c3d679fd398f42a2e489fbe3dab17fac1fb2439c
msg351688 - (view) Author: Steve Dower (steve.dower) * (Python committer) Date: 2019-09-10 14:51
New changeset 313f80192a7396ea3e5ab107175afe4c5a017ab8 by Steve Dower (Miss Islington (bot)) in branch '3.8':
bpo-37504: Fix documentation build with texinfo builder (GH-14606)
https://github.com/python/cpython/commit/313f80192a7396ea3e5ab107175afe4c5a017ab8
msg351689 - (view) Author: Steve Dower (steve.dower) * (Python committer) Date: 2019-09-10 14:52
Thanks for the report and the patch!
History
Date User Action Args
2019-09-10 14:52:06steve.dowersetstatus: open -> closed
resolution: fixed
messages: + msg351689

stage: patch review -> resolved
2019-09-10 14:51:47steve.dowersetmessages: + msg351688
2019-09-10 14:41:02miss-islingtonsetpull_requests: + pull_request15512
2019-09-10 14:40:53steve.dowersetnosy: + steve.dower
messages: + msg351678
2019-07-05 19:39:39mitya57settitle: 3.8 b2 now requires sphinx2, but only has documented 1.8 -> Documentation fails to build when using Sphinx' texinfo builder
2019-07-05 19:37:17mitya57setkeywords: + patch
stage: patch review
pull_requests: + pull_request14421
2019-07-05 17:16:50mitya57setnosy: + mitya57
2019-07-05 10:12:48dokosetmessages: + msg347327
2019-07-05 10:07:35SilentGhostsetnosy: + SilentGhost
2019-07-05 09:51:08vstinnersetnosy: + mdk
2019-07-05 09:49:15dokocreate