Discussion:
What has changed regarding pending_xref() and refdomain?
(too old to reply)
Matthias Geier
2017-05-02 19:30:24 UTC
Permalink
Dear list.

Until now, I'm using something like this in my Sphinx extension
(http://nbsphinx.readthedocs.io/):

sphinx.addnodes.pending_xref(reftype='doc', refdomain=None, ...)

Using the master branch, I recently started to get warning messages of
this kind:

WARNING: 'doc' reference target not found: ...

... and my pending references were not turned into actual references
in the output.

Now I found an easy work-around by just using refdomain='std' instead
of refdomain=None.
This works fine, but I'm wondering if this is backwards compatible and
if it is actually the right thing to do.

Is it?

cheers,
Matthias
--
You received this message because you are subscribed to the Google Groups "sphinx-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to sphinx-dev+***@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Komiya Takeshi
2017-05-03 02:31:10 UTC
Permalink
Hi Matthias,

Now the implementation of :doc: role is moved into std domain. So it
generates and resolves the pending_xref node under std domain. It
works fine by sphinx itself. but, as you said, it does not work fine
if 3rd party extensions generate it with refdomain=None. it's my
wrong.
I agree this is breaking compatibility. Could you file this as an
issue? then I'll fix it before final release.

Thanks,
Takeshi KOMIYA
Post by Matthias Geier
Dear list.
Until now, I'm using something like this in my Sphinx extension
sphinx.addnodes.pending_xref(reftype='doc', refdomain=None, ...)
Using the master branch, I recently started to get warning messages of
WARNING: 'doc' reference target not found: ...
... and my pending references were not turned into actual references
in the output.
Now I found an easy work-around by just using refdomain='std' instead
of refdomain=None.
This works fine, but I'm wondering if this is backwards compatible and
if it is actually the right thing to do.
Is it?
cheers,
Matthias
--
You received this message because you are subscribed to the Google Groups "sphinx-dev" group.
For more options, visit https://groups.google.com/d/optout.
--
You received this message because you are subscribed to the Google Groups "sphinx-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to sphinx-dev+***@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Matthias Geier
2017-05-03 08:43:32 UTC
Permalink
Thanks Takeshi!

Here's the issue: https://github.com/sphinx-doc/sphinx/issues/3698

cheers,
Matthias
Post by Komiya Takeshi
Hi Matthias,
Now the implementation of :doc: role is moved into std domain. So it
generates and resolves the pending_xref node under std domain. It
works fine by sphinx itself. but, as you said, it does not work fine
if 3rd party extensions generate it with refdomain=None. it's my
wrong.
I agree this is breaking compatibility. Could you file this as an
issue? then I'll fix it before final release.
Thanks,
Takeshi KOMIYA
Post by Matthias Geier
Dear list.
Until now, I'm using something like this in my Sphinx extension
sphinx.addnodes.pending_xref(reftype='doc', refdomain=None, ...)
Using the master branch, I recently started to get warning messages of
WARNING: 'doc' reference target not found: ...
... and my pending references were not turned into actual references
in the output.
Now I found an easy work-around by just using refdomain='std' instead
of refdomain=None.
This works fine, but I'm wondering if this is backwards compatible and
if it is actually the right thing to do.
Is it?
cheers,
Matthias
--
You received this message because you are subscribed to the Google Groups "sphinx-dev" group.
For more options, visit https://groups.google.com/d/optout.
--
You received this message because you are subscribed to the Google Groups "sphinx-dev" group.
For more options, visit https://groups.google.com/d/optout.
--
You received this message because you are subscribed to the Google Groups "sphinx-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to sphinx-dev+***@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Loading...