Skip to content

gh-101100: Silence Sphinx warnings when ntpath or posixpath are referenced - #112833

Merged
AlexWaygood merged 1 commit into
python:mainfrom
AlexWaygood:os-path-nitpicks
Dec 7, 2023
Merged

AlexWaygood merged 1 commit into
python:mainfrom
AlexWaygood:os-path-nitpicks

Conversation

@AlexWaygood

@AlexWaygood AlexWaygood commented Dec 7, 2023 •

Copy link
Copy Markdown
Member

ntpath and posixpath are undocumented modules, and I think they should stay undocumented. The vast majority of users won't need to worry about them; they're implementation details of os.path.

This PR silences Sphinx warnings when these modules are referenced (because Sphinx cannot resolve the references) by adding them to the nitpick_ignore list in Doc/conf.py. Doing this allows us to remove library/os.path.rst from the .nitignore list of files.


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

@barneygale barneygale left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Lovely stuff!

@barneygale

Copy link
Copy Markdown
Contributor

You're going to hit a conflict on backport because PurePath.pathmod is new in 3.13. Enjoy! :]

@AlexWaygood
AlexWaygood merged commit 2c3906b into python:main Dec 7, 2023
@AlexWaygood
AlexWaygood deleted the os-path-nitpicks branch December 7, 2023 20:57
@miss-islington-app

Copy link
Copy Markdown

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

@miss-islington-app

Copy link
Copy Markdown

Sorry, @AlexWaygood, I could not cleanly backport this to 3.12 due to a conflict.
Please backport using cherry_picker on command line.

cherry_picker 2c3906bc4b7ee62bf9d122a6fdd98b6ae330643f 3.12
@miss-islington-app

Copy link
Copy Markdown

Sorry, @AlexWaygood, I could not cleanly backport this to 3.11 due to a conflict.
Please backport using cherry_picker on command line.

cherry_picker 2c3906bc4b7ee62bf9d122a6fdd98b6ae330643f 3.11
@bedevere-app

bedevere-app Bot commented Dec 7, 2023

Copy link
Copy Markdown

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

@bedevere-app bedevere-app Bot removed the needs backport to 3.12 only security fixes label Dec 7, 2023
AlexWaygood added a commit to AlexWaygood/cpython that referenced this pull request Dec 7, 2023
…ixpath` are referenced (python#112833)

(cherry-picked from commit 2c3906b)
@bedevere-app

bedevere-app Bot commented Dec 7, 2023

Copy link
Copy Markdown

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

@bedevere-app bedevere-app Bot removed the needs backport to 3.11 only security fixes label Dec 7, 2023
AlexWaygood added a commit to AlexWaygood/cpython that referenced this pull request Dec 7, 2023
…ixpath` are referenced (python#112833)

(cherry-picked from commit 2c3906b)
AlexWaygood added a commit that referenced this pull request Dec 7, 2023
…` are referenced (#112833) (#112857)

(cherry-picked from commit 2c3906b)
AlexWaygood added a commit that referenced this pull request Dec 7, 2023
…` are referenced (#112833) (#112858)

(cherry-picked from commit 2c3906b)
aisk pushed a commit to aisk/cpython that referenced this pull request Feb 11, 2024
Glyphack pushed a commit to Glyphack/cpython that referenced this pull request Sep 2, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

3 participants