Skip to content
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

"default" config broken in sphinx 5 #33

Open
ailin-nemui opened this issue Jun 11, 2022 · 4 comments
Open

"default" config broken in sphinx 5 #33

ailin-nemui opened this issue Jun 11, 2022 · 4 comments

Comments

@ailin-nemui
Copy link

With no language configured, a mono-lingual site sitemap suddenly gains /en/ in the sitemap after updating to sphinx 5, breaking all paths

@kai687
Copy link

kai687 commented Jul 21, 2022

@ailin-nemui not sure if that helps you, but I found this workaround for my single language, single version site. I added this to the conf.py file:

sitemap_url_scheme = "{link}"

@jdillard
Copy link
Owner

I think @kai687 answer is the preferred solution. The default isn't meant to work in all cases here, it is meant as a recommended starting point as everyone has a different preference on URL structure. Since it doesn't seem possible to have a language of "none" on Sphinx 5, it doesn't seem there is a reliable way to test for it.

@ailin-nemui
Copy link
Author

ok thanks, but it was a surprising breakage

jdillard added a commit that referenced this issue Dec 13, 2022
* Use code highlighting

* Split the installation and configuring sections

* Move URL scheme to top of configuration section

* Improve the wording of the URL scheme to mention the changed language behavior in Sphinx 5 (addresses #33)
@jdillard jdillard pinned this issue Dec 14, 2022
@jdillard
Copy link
Owner

I added sitemap_validator_urls and sitemap_validator_required config values, with instructions on how to use them in a PR: #37

It won't help anyone in this situation that doesn't add the new configuration options, and it possibly can't help people that do multi-lingual builds, but it's about as much as I think I can do given the limited view the extension has inside more complex build pipelines.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants