-
-
Notifications
You must be signed in to change notification settings - Fork 452
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
wrong cross-referencing in modindex of documentation #21044
Comments
comment:3
As I found on the mailing list, I encountered this problem in the doctests, with an incorrect link being generated for This behavior can be explained in part by this comment in the
In my specific case, entries for
Since these are stored as keys in a dict the order can nondeterministic. In my case What's still mysterious is why |
comment:4
Incidentally when I run my serial docs build, If I understand the build system right, however, each sub-document should be built in its own sphinx environment. Yet it seems as if there's some "leaking" between the environments during the initial pass, and this shouldn't happen. |
comment:5
oh, good point! that could explain why those wrong links show up at all. my wild guess: sphinx generates "temporary" files to cache some data-structures. on the next pass, sphinx doesn't clean up but somehow loads and reuses these caches. Maybe it's already enough to use |
comment:6
It's also resulting in huge It could also be the reason for some other issues I've had (for which it seems I haven't posted a ticket) with duplicate labels between some documents. The duplicate labels really shouldn't matter as long as they're not within the same document. |
comment:7
Ah, I've found it. This is a bug in Sphinx. A nasty case of " |
Upstream: Reported upstream. No feedback yet. |
comment:8
Reported upstream: sphinx-doc/sphinx#2816 I have a fix in the sage end (via monkey patching) that I'm testing now. |
Changed upstream from Reported upstream. No feedback yet. to Reported upstream. Developers acknowledge bug. |
comment:10
Here's a workaround for this bug in the meantime. It's ugly, but that's to be expected. I've had this patch in my working branch for some time now and it has been well-tested. New commits:
|
Commit: |
Author: Erik Bray |
Branch: u/embray/patch-domain-init |
comment:11
Also a nice side-effect is that it results in smaller |
Changed upstream from Reported upstream. Developers acknowledge bug. to Fixed upstream, in a later stable release. |
comment:12
The fix will be upstream in Sphinx 1.4.6, though that doesn't do us any immediate good since we're a ways from being able to upgrade Sphinx IIUC. |
comment:14
After building Sage and the documentation with this branch, I randomly tested links in I don't know enough about this part of Sage to comment on whether this is the best way to fix the problem, but it certainly does appear to deal with the issue. This should really get into 7.4 so that the next version of the documentation will look better to Google. What else needs to be tested for that to happen? |
Reviewer: Paul Masson |
comment:16
In addition to fixing the specific issue in the ticket description, this fixes many other problems with building the docs in a single process that arose due to labels being shared between documents, resulting in "duplicate label" errors and similar. |
comment:17
If there are no objections from other potential reviewers, setting this to positive review. |
Changed branch from u/embray/patch-domain-init to |
comment:19
Replying to @embray:
Why not? Did you actually try it? |
Changed commit from |
comment:20
I don't know why I wrote that 3 months ago. Last I recall I wasn't sure who was working on what w.r.t. Sphinx support or what the progress was on that. |
comment:21
Note: I will revert this in #22252. |
comment:22
Sounds good--thanks! |
The Sphinx-generated documentation has index files for modules. E.g. looking at http://doc.sagemath.org/html/en/a_tour_of_sage/py-modindex.html
Checking upon the first link in this list, it points to a non-existing page. It seems like as if sphinx doesn't correctly cross link to a sibling. I.e. instead of
/html/en/a_tour_of_sage/...
http://doc.sagemath.org/html/en/a_tour_of_sage/algebras/sage/algebras/affine_nil_temperley_lieb.html#module-sage.algebras.affine_nil_temperley_lieb
it should be
/html/en/reference/...
http://doc.sagemath.org/html/en/reference/algebras/sage/algebras/affine_nil_temperley_lieb.html#module-sage.algebras.affine_nil_temperley_lieb
Upstream (Sphinx) fix:
Upstream: Fixed upstream, in a later stable release.
CC: @paulmasson @embray @jdemeyer @hivert @egourgoulhon @slel
Component: documentation
Author: Erik Bray
Branch:
dbfb2d6
Reviewer: Paul Masson
Issue created by migration from https://trac.sagemath.org/ticket/21044
The text was updated successfully, but these errors were encountered: