From 5f672e3f00980f12b866ac1b225a72e77f12123a Mon Sep 17 00:00:00 2001 From: jce Date: Sat, 14 Dec 2024 17:33:48 +0100 Subject: [PATCH 1/3] Update hyperlinks --- README.rst | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/README.rst b/README.rst index a4608bec..901ef796 100644 --- a/README.rst +++ b/README.rst @@ -1,5 +1,5 @@ .. image:: https://img.shields.io/hexpm/l/plug.svg - :target: http://www.apache.org/licenses/LICENSE-2.0 + :target: https://www.apache.org/licenses/LICENSE-2.0 :alt: Apache2 License .. image:: https://github.com/melexis/warnings-plugin/actions/workflows/python-package.yml/badge.svg?branch=master @@ -7,8 +7,8 @@ :alt: Build status .. image:: https://badge.fury.io/py/mlx.warnings.svg - :target: https://badge.fury.io/py/mlx.warnings - :alt: Pypi packaged release + :target: https://pypi.org/project/mlx.warnings + :alt: PyPI packaged release .. image:: https://img.shields.io/badge/Documentation-published-brightgreen.svg :target: https://melexis.github.io/warnings-plugin/ @@ -19,7 +19,7 @@ :alt: Coverity Scan Build Status .. image:: https://codecov.io/gh/melexis/warnings-plugin/branch/master/graph/badge.svg - :target: https://codecov.io/gh/melexis/warnings-plugin + :target: https://app.codecov.io/gh/melexis/warnings-plugin :alt: Code Coverage .. image:: https://codeclimate.com/github/melexis/warnings-plugin/badges/gpa.svg @@ -27,15 +27,15 @@ :alt: Code Climate Status .. image:: https://codeclimate.com/github/melexis/warnings-plugin/badges/issue_count.svg - :target: https://codeclimate.com/github/melexis/warnings-plugin + :target: https://codeclimate.com/github/melexis/warnings-plugin/issues :alt: Issue Count .. image:: https://img.shields.io/badge/contributions-welcome-brightgreen.svg?style=flat :target: https://github.com/melexis/warnings-plugin/issues :alt: Contributions welcome -.. image:: https://bestpractices.coreinfrastructure.org/projects/4368/badge - :target: https://bestpractices.coreinfrastructure.org/projects/4368 +.. image:: https://www.bestpractices.dev/projects/4368/badge + :target: https://www.bestpractices.dev/projects/4368 :alt: CII Best Practices @@ -379,7 +379,7 @@ These statuses indicate that you have given due consideration and justified that in `Polyspace's documentation about results`_. The status "No Action Planned" is not treated differently because this is the default status for annotations. -.. _`Polyspace's documentation about results`: https://nl.mathworks.com/help/polyspace_access/ug/fix-or-comment-polyspace-results-web-browser.html +.. _`Polyspace's documentation about results`: https://www.mathworks.com/help/polyspace_access/ug/fix-or-comment-polyspace-results-web-browser.html Example Checks ^^^^^^^^^^^^^^ From 88b1a7d82d98bb41ef8a0ec1c6421537ec2684ed Mon Sep 17 00:00:00 2001 From: jce Date: Sat, 14 Dec 2024 17:39:57 +0100 Subject: [PATCH 2/3] let linkcheck ignore URL to mathworks, to fix CI failure --- docs/conf.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/docs/conf.py b/docs/conf.py index a0147020..afa7fbf3 100644 --- a/docs/conf.py +++ b/docs/conf.py @@ -64,6 +64,8 @@ napoleon_use_rtype = False napoleon_use_param = False +linkcheck_ignore = [r'https://www\.mathworks\.com.+'] + # Point to plantuml jar file # confirm we have plantuml in the path if 'nt' in os.name: From 4e4e704c06a741c4cacc939f7a08c941dda77ed8 Mon Sep 17 00:00:00 2001 From: jce Date: Sat, 14 Dec 2024 17:58:25 +0100 Subject: [PATCH 3/3] only run Sphinx' linkcheck with Python 3.10 to prevent failure by DDOS protection services --- .github/workflows/python-package.yml | 3 +++ tox.ini | 5 +++++ 2 files changed, 8 insertions(+) diff --git a/.github/workflows/python-package.yml b/.github/workflows/python-package.yml index 4dad7372..cc8eccdc 100644 --- a/.github/workflows/python-package.yml +++ b/.github/workflows/python-package.yml @@ -27,6 +27,9 @@ jobs: run: tox -e py - name: Build HTML documentation run: tox -e docs + - name: Checks hyperlinks in documentation + if: matrix.python-version == '3.10' + run: tox -e docs_linkcheck - name: Calculate coverage run: tox -e coverage - name: Codecov uploader diff --git a/tox.ini b/tox.ini index fcf87437..d8d95bad 100644 --- a/tox.ini +++ b/tox.ini @@ -67,6 +67,11 @@ deps = commands = sphinx-build {posargs:-E} -b doctest docs docs/_build sphinx-build {posargs:-E} -b html docs docs/_build + +[testenv:docs_linkcheck] +deps = + -r{toxinidir}/docs/requirements.txt +commands = sphinx-build -b linkcheck docs docs/_build [testenv:check]