[Python-Dev] Sphinx version for Python 2.x docs
merwok at netwok.org
Mon Jan 16 16:42:14 CET 2012
Le 14/01/2012 15:31, Sandro Tosi a écrit :
> On Sat, Jan 14, 2012 at 04:24, Éric Araujo <merwok at netwok.org> wrote:
>>> Doc/glossary.rst:520: WARNING: unknown keyword: nonlocal
>> That’s a mistake I did in cefe4f38fa0e. This sentence should be
> Do you mean revert this whole hunk:
> or just "The :keyword:`nonlocal` allows writing to outer scopes."?
My proposal was to remove just that one last sentence, but the only
other change in the diff hunk is the addition of “by default”, which is
connected to the existence of nonlocal. Both changes, i.e. the whole
hunk, should be reverted (I think I’ll have time to do that today).
>>> Doc/library/stdtypes.rst:2372: WARNING: more than one target found
>>> cross-reference u'next':
>> Need to use :meth:`.next` to let Sphinx find the right target (more
>> on request :)
> it seems what it needed to was :meth:`next` (without the dot). The
> current page links all 'next' in file.next() to functions.html#next,
> and using :meth:`next` does that.
I should have given more info, as I wanted the opposite result :)
file.next should not link to the next function but to the file.next
method. Because Sphinx does not differentiate between
meth/func/class/mod roles, :meth:`next` is not resolved to the nearest
next method as one could expect but to the next function, so we have to
use :meth:`~SomeClass.next` or :meth:`.next` (local ref markup) to get
our links to methods.
>>> Doc/reference/datamodel.rst:1942: WARNING: unknown keyword: not in
>>> Doc/reference/expressions.rst:1184: WARNING: unknown keyword: is
Georg fixed them.
More information about the Python-Dev