-
Notifications
You must be signed in to change notification settings - Fork 1.7k
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
Workaround for dirhtml builder with wrong canonical URLs #1407
base: master
Are you sure you want to change the base?
Workaround for dirhtml builder with wrong canonical URLs #1407
Conversation
0978285
to
7dfccd0
Compare
7dfccd0
to
b8a4d88
Compare
2f1b2ec
to
55600c0
Compare
…r was used (retry with GPG signature)
55600c0
to
6beecce
Compare
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.
This seems like a reasonable approach, but I'd like to see a test if we're going to implement this. Seems enough enough to have a test case that sets the canonical URL via sphinx?
@ericholscher yes, agreed -- I would think that setting I don't think this needs to be a roadmap item for 1.2.0 but would be nice to publish it sooner or later. |
I'm going to leave this for a little while - but I don't think it's hard to add a test dimension in Tox that parameterizes |
I am noticing that sphinx itself would have the same issue here: https://github.com/sphinx-doc/sphinx/blob/master/sphinx/themes/basic/layout.html#L132 Probably best to use a mixture of https://www.sphinx-doc.org/en/master/development/templating.html#file_suffix |
@Blendify this is just a workaround :) You'll find the upstream issue here: sphinx-doc/sphinx#9730 |
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.
I think this is a good workaround for now. We should merge it and release a patch version.
Thanks for this, @benjaoming, @humitos. This would indeed help with #1303 for now! |
Fix for #1406
index.html
being converted toindex/
(will test manually since canonical URL does not seem to appear in local builds)