Skip to content

Docs: Avoid a DeprecationWarning in pyspecific.py when running with Sphinx >=6.1 #105886

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

Merged
merged 2 commits into from
Jun 23, 2023

Conversation

AlexWaygood
Copy link
Member

@AlexWaygood AlexWaygood commented Jun 17, 2023

Importing status_iterator from sphinx.util rather than sphinx.util.display causes a DeprecationWarning to be emitted if you're running with Sphinx >= 6.1. We still support the CPython docs being built with older versions of Sphinx that don't yet have sphinx.util.display, however, hence the try/except ImportError block. You can see this deprecation warning here (though the doctest is also failing on that job, I think for unrelated reasons): https://github.com/python/cpython/actions/runs/5297276975/jobs/9588952949?pr=105882


📚 Documentation preview 📚: https://cpython-previews--105886.org.readthedocs.build/

@hugovk
Copy link
Member

hugovk commented Jun 17, 2023

Please could you add comments similar to hugovk@c4a84f6 so we know when to remove the old bit?

And shall we tidy up some older imports that weren't commented, like in hugovk@fb4e1cc?

(I forgot to open a PR for these!)

@AlexWaygood
Copy link
Member Author

Please could you add comments similar to hugovk@c4a84f6 so we know when to remove the old bit?

And shall we tidy up some older imports that weren't commented, like in hugovk@fb4e1cc?

(I forgot to open a PR for these!)

Oh, yours is better than mine, do you just want to open a PR (or two) with your patch(es)? :)

@hugovk
Copy link
Member

hugovk commented Jun 17, 2023

It's fine, we can do it here, we don't want to run out of PR numbers! 🙃

You could add a Co-authored-by if you like, but I don't mind either way.

Co-authored-by: Hugo van Kemenade <[email protected]>
@JelleZijlstra
Copy link
Member

Should we backport this? Might make us run out of PR numbers sooner.

@hugovk
Copy link
Member

hugovk commented Jun 20, 2023

Yes, let's backport it. (We've saved one PR number, so can invest in two more.)

@arhadthedev
Copy link
Member

Might make us run out of PR numbers sooner.

We rather need to waste IDs on an industrial scale to get cpython#666666 faster 😉

@AlexWaygood AlexWaygood added needs backport to 3.11 only security fixes needs backport to 3.12 only security fixes labels Jun 20, 2023
@AlexWaygood AlexWaygood merged commit a72683b into python:main Jun 23, 2023
@miss-islington
Copy link
Contributor

Thanks @AlexWaygood for the PR 🌮🎉.. I'm working now to backport this PR to: 3.11, 3.12.
🐍🍒⛏🤖

@AlexWaygood AlexWaygood deleted the sphinx-depr branch June 23, 2023 07:58
@bedevere-bot
Copy link

GH-106010 is a backport of this pull request to the 3.12 branch.

@bedevere-bot bedevere-bot removed the needs backport to 3.12 only security fixes label Jun 23, 2023
miss-islington pushed a commit to miss-islington/cpython that referenced this pull request Jun 23, 2023
… Sphinx >=6.1 (pythonGH-105886)

(cherry picked from commit a72683b)

Co-authored-by: Alex Waygood <[email protected]>
Co-authored-by: Hugo van Kemenade <[email protected]>
@bedevere-bot
Copy link

GH-106011 is a backport of this pull request to the 3.11 branch.

miss-islington pushed a commit to miss-islington/cpython that referenced this pull request Jun 23, 2023
… Sphinx >=6.1 (pythonGH-105886)

(cherry picked from commit a72683b)

Co-authored-by: Alex Waygood <[email protected]>
Co-authored-by: Hugo van Kemenade <[email protected]>
@bedevere-bot bedevere-bot removed the needs backport to 3.11 only security fixes label Jun 23, 2023
AlexWaygood added a commit that referenced this pull request Jun 23, 2023
…ng with Sphinx >=6.1 (GH-105886) (#106010)

Docs: Avoid a DeprecationWarning in `pyspecific.py` when running with Sphinx >=6.1 (GH-105886)
(cherry picked from commit a72683b)

Co-authored-by: Alex Waygood <[email protected]>
Co-authored-by: Hugo van Kemenade <[email protected]>
AlexWaygood added a commit that referenced this pull request Jun 23, 2023
…ng with Sphinx >=6.1 (GH-105886) (#106011)

Docs: Avoid a DeprecationWarning in `pyspecific.py` when running with Sphinx >=6.1 (GH-105886)
(cherry picked from commit a72683b)

Co-authored-by: Alex Waygood <[email protected]>
Co-authored-by: Hugo van Kemenade <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants