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

replace hardcoded urls to docs.pytest.org with internal crossrefs, add crossrefs to numpy docs, use sphinx pep role #9158

Merged
merged 2 commits into from Oct 4, 2021

Conversation

hoefling
Copy link
Member

@hoefling hoefling commented Oct 3, 2021

This PR replaces all hardcoded links to https://docs.pytest.org with internal crossreferences (with missing labels being added). Also, hardcoded links to numpy docs were replaced by intersphinx crossrefs. Lastly, all hardcoded references to PEP pages were replaced by usages of Sphinx' :pep: role.

This is the second PR in series, the first one (#9041) replaced hardcoded URLs to stdlib. Also probably #9081 is partially addressed by this.

Apologies for the PR size. This was mostly a semi-automated search-and-replace, with manually fixing broken links afterwards.

…d external crossrefs where possible

Signed-off-by: oleg.hoefling <oleg.hoefling@gmail.com>
Copy link
Member

@Zac-HD Zac-HD left a comment

Choose a reason for hiding this comment

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

I think we should consider leaving the announce changes for later, since they might be used as plain text as well as built with Sphinx.

Otherwise looks good to me 👍

Comment on lines 12 to 16
https://docs.pytest.org/en/stable/changelog.html
:std:doc:`changelog`

For complete documentation, please visit:

https://docs.pytest.org/en/stable/
:std:doc:`../index`
Copy link
Member

Choose a reason for hiding this comment

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

I'm unsure of these ones, since they do render differently.

If we're changing them we should also change the templates https://github.com/pytest-dev/pytest/blob/main/scripts/release.minor.rst and https://github.com/pytest-dev/pytest/blob/main/scripts/release.patch.rst in any case 😄

Signed-off-by: oleg.hoefling <oleg.hoefling@gmail.com>
@hoefling
Copy link
Member Author

hoefling commented Oct 4, 2021

@Zac-HD sure thing, reverted the changes in announce dir!

Copy link
Member

@Zac-HD Zac-HD left a comment

Choose a reason for hiding this comment

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

Looks like a solid improvement on the status quo, so let's merge!

Thanks again @hoefling, we really appreciate your work on this - docs and cleanup are often neglected, but are absolutely essential for users 🥰

@Zac-HD Zac-HD merged commit e763fde into pytest-dev:main Oct 4, 2021
@Zac-HD
Copy link
Member

Zac-HD commented Oct 4, 2021

If you're after a next step, maybe extlinks for issue links (etc)? Here's the setup we use for Hypothesis.

@hoefling hoefling deleted the doc/internal-crossrefs branch October 6, 2021 07:35
@hoefling
Copy link
Member Author

hoefling commented Oct 6, 2021

@Zac-HD yep, this is definitely something I‘d like to tackle on next. Although I haven‘t used extlinks extensively so far, so will look into it first - maybe this extension should also get a checking posttransform similar to what was proposed for intersphinx in Sphinx lately.

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

Successfully merging this pull request may close these issues.

None yet

2 participants