-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
use pathlib path in sitemap plugin for sphinx compatibility #4215
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.
Thanks for the fix.
I'm somewhat hesitant to put this in as-is. While this definitely works for Sphinx 7 and newer, it does not work for older versions of Sphinx. While that won't affect our deployment (we use Sphinx 7.2.6 currently), it could make the documentation more difficult for people to build locally. If there is a way we can discover the sphinx version and only conditionally do this for sphinx >= 7, that would make me feel better about it.
it seems to work with sphinx 6 at least, but i added a conditional on sphinx >=7, so even older versions will not be broken by this 👍 |
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 tested this with Sphinx 7, 6, and 4, and it seems to work with all of them. Thanks!
* use pathlib paths for sphinx compatibility * conditionally use pathlib if sphinx >=7 (cherry picked from commit 3ec513d)
* use pathlib paths for sphinx compatibility * conditionally use pathlib if sphinx >=7 (cherry picked from commit 3ec513d)
…4227) * use pathlib paths for sphinx compatibility * conditionally use pathlib if sphinx >=7 (cherry picked from commit 3ec513d) Co-authored-by: Jonas Otto <[email protected]>
…4228) * use pathlib paths for sphinx compatibility * conditionally use pathlib if sphinx >=7 (cherry picked from commit 3ec513d) Co-authored-by: Jonas Otto <[email protected]>
fixes this sphinx warning: