-
Notifications
You must be signed in to change notification settings - Fork 122
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
Sphinx 9 deprecations #37887
base: main
Are you sure you want to change the base?
Sphinx 9 deprecations #37887
Conversation
2bb4d12
to
bb0eb80
Compare
Given you are putting this in now is it likely to be merged into main before code freeze? Thats still about 2 weeks away. |
Yes should be done by then |
Maybe change the milestone? |
08c4d8d
to
1a86be6
Compare
db5b040
to
6fc75eb
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.
Unfortunately when viewing the index pages for, Algorithms, Concepts, etc. I'm not seeting any css
I did get a failure when building the docs 43>C:\Program Files\Microsoft Visual Studio\2022\Community\MSBuild\Microsoft\VC\v160\Microsoft.CppCommon.targets(241,5): error MSB8066: Custom build for 'C:\Users\bya67386\work\mantid\build\CMakeFiles\a174ffb83d39874e18c7afe905d635e0\docs-html.rule;C:\Users\bya67386\work\mantid\docs\CMakeLists.txt' exited with code 1.
And some warnings (although not the deprecation warnings.) but this might be to do with my weird build problems.
From Sphinx 9 onwards it will not be possible to use a string to represent a file path, so I've replaced all such occurrences with pathlib.Path.
From Sphinx 9 onwards tags.tags will be removed.
pathlib.Path.relative_to() apparently will not traverse the file hierarchy both up then down again, so if you want to find the relative path between two locations in that case you need os.path.relpath().
The name can contain backslashes that need converting to posix format before going into the subsequent code. Otherwise the backslashes will break the documentation folder structure.
6fc75eb
to
80da950
Compare
Sphinx wants us to use pathlib.Path to represent filesystem paths, but on Windows Sphinx can't handle the backslashes that come out of Path. Hence if we use PurePosixPath we can make sure we get forward slashes.
19dac48
to
9261945
Compare
At the time of writing we are using Sphinx 8, but generating the docs gives warnings about the use of strings to represent file paths not being allowed in Sphinx 9.
pathlib.Path
objectstags.tags
withtags
Fixes #37804.
To test:
amalgamate.py
)This does not require release notes because it has no effect on the user.
Reviewer
Please comment on the points listed below (full description).
Your comments will be used as part of the gatekeeper process, so please comment clearly on what you have checked during your review. If changes are made to the PR during the review process then your final comment will be the most important for gatekeepers. In this comment you should make it clear why any earlier review is still valid, or confirm that all requested changes have been addressed.
Code Review
Functional Tests
Does everything look good? Mark the review as Approve. A member of
@mantidproject/gatekeepers
will take care of it.Gatekeeper
If you need to request changes to a PR then please add a comment and set the review status to "Request changes". This will stop the PR from showing up in the list for other gatekeepers.