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

ci: run hyperlink checking with quiet mode flag enabled #2476

Merged
merged 3 commits into from Jan 25, 2024
Merged

ci: run hyperlink checking with quiet mode flag enabled #2476

merged 3 commits into from Jan 25, 2024

Conversation

jayaddison
Copy link
Contributor

Description

The Sphinx linkcheck builder supports a -q / --quiet flag that reduces output verbosity while continuing to output warnings and errors.

This change enables the flag for the scheduled Check hyperlinks GitHub Actions worklow.

Motivation and context

For projects like this one that feature large numbers of healthy hyperlinks, the default linkchecker output to stdout can be overly verbose, with broken/problem hyperlink reports interspersed among many reports of healthy links, making it hard to collect and find the set of problems to fix.

Note

The linkcheck builder emits a warning when it encounters an HTTP redirect that doesn't match an entry within the linkcheck_allowed_redirects patterns - PlasmaPy has a few of these at the moment - mostly related to GitHub users. Although allowing valid redirects is generally good practice, it is possible to ignore (skip) checking for link patterns by using linkcheck_ignore if necessary.

Related issues

N/A

This is intended to make it easier to find and fix broken links; in quiet mode, the linkcheck builder suppresses much of its reporting to stdout, including successful (ok) check results -- and so what appears in GitHub Actions console, for example, with the quiet flag in place should be more concise and actionable.
Copy link

Thank you for submitting a pull request (PR) to PlasmaPy! ✨ The future of the project depends on contributors like you, so we deeply appreciate it! 🌱

Our contributor guide has information on:

The bottom of this page shows several checks that are run for every PR. Don't worry if something broke! We break stuff all the time. 😺 Click on "Details" to learn why a check didn't pass. Please also feel free to ask for help. We do that all the time as well. 🌸 You can find us in our chat room or weekly community meeting & office hours. Here are some tips:

  • Try fixing CI / Python 3.11 test failures first.
  • Most pre-commit.ci - pr failures can be automagically fixed by commenting pre-commit.ci autofix below, followed by a git pull to bring the changes back to your computer. Please also see our pre-commit troubleshooting guide.
  • If pre-commit.ci - pr says that a function is too long or complex, try breaking up that function into multiple short functions that each do one thing. See also these tips on writing clean scientific software.
  • If the CI / Documentation check ends with a cryptic error message, check out our documentation troubleshooting guide.
  • For a documentation preview, click on Details next to docs/readthedocs.org:plasmapy.

If this PR is marked as ready for review, someone should stop by to provide a code review and offer suggestions soon. ✅ If you don't get a review within a few days, please feel free to send us a reminder.

Please also use SI units within PlasmaPy, except when there is strong justification otherwise or in some examples.

We thank you once again!

@github-actions github-actions bot added the GitHub Actions A continuous integration platform for automating tests and other tasks (see .github/ directory) label Jan 25, 2024
@jayaddison jayaddison requested a review from a team as a code owner January 25, 2024 15:12
Copy link

codecov bot commented Jan 25, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Comparison is base (46f59fc) 96.93% compared to head (4531afc) 96.93%.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #2476   +/-   ##
=======================================
  Coverage   96.93%   96.93%           
=======================================
  Files         104      104           
  Lines        9163     9163           
=======================================
  Hits         8882     8882           
  Misses        281      281           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Copy link
Member

@namurphy namurphy left a comment

Choose a reason for hiding this comment

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

This is fantastic! Thank you once again!

@namurphy namurphy merged commit 1093e93 into PlasmaPy:main Jan 25, 2024
11 of 13 checks passed
@jayaddison
Copy link
Contributor Author

You're welcome @namurphy - it's a good way for me to learn a bit more about how the linkcheck builder is being used in practice. I'll try to remember to check in on the results of the next scheduled linkcheck here; feel free to tag me on an issue in the Sphinx repo if you have any particular feedback too.

@jayaddison jayaddison deleted the ci/linkcheck-quiet-mode branch January 25, 2024 15:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
GitHub Actions A continuous integration platform for automating tests and other tasks (see .github/ directory) no changelog entry needed
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants