-
Notifications
You must be signed in to change notification settings - Fork 49
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
avoid duplicate label warnings for .. include::'ed files #136
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM though a comment explaining why the special case is needed would be great.
@svenevs thoughts?
Good call, done in 21ff1af |
I'm in the process of re-tooling a new OS, but not having a link may present issues with the tree view links (when using rst lists). My impression is one of the tests cases for pages should produce the warning we are discussing here, I think it's better to stuff Line 2435 in 0d1a8a8
|
117a05a
to
43ce3c1
Compare
Turned out to be a slightly different problem, uncovered by the duplicate label. The index page is the first one that is being included that had a label that was therefore being duplicated, good catch! I've pushed some revert commits (and rebased for the updated testing matrix) with the final commit being the proposed fix. Anything that is
If things are working as expected I'll squash this soon 🙃 |
Sphinx does not like it when a file that is later included (via .. include directive) has the very same link label inside of it. To avoid a Sphinx warning, skip link label generation for the pageindex. Signed-off-by: Chris Lalancette <clalancette@openrobotics.org>
Signed-off-by: Chris Lalancette <clalancette@openrobotics.org>
This reverts commit 21ff1af.
This reverts commit 3523899.
Sphinx will process any generated `.rst` file independently of if it is being included somewhere. Generated files that are going to be `.. include::`'ed are renamed to `.rst.include` to avoid sphinx processing the file separately.
5d37b53
to
bdd8073
Compare
Merging as resolved, the warning is gone for me. Can revisit in followup if it is still a problem, preventing sphinx from processing the documents twice independently (once for the document it is |
I have some questions about this. |
Opened #176 to discuss, it should be easy to have our cake and eat it too 🙂 |
Sphinx does not like it when a file that is later included
(via .. include directive) has the very same link label inside of
it. To avoid a Sphinx warning, skip link label generation for
the pageindex.
Signed-off-by: Chris Lalancette clalancette@openrobotics.org