Skip to content

Commit e661e33

Browse files
authored
Fix linkcheck issues (#1437)
* Update linkcheck configuration for unavoidable link issues * Update the home of the python-checkins webhook * Fix broken extlink usage (The extlink extension does not handle the `!` prefix.) * Fix renamed PEP-0 section link * Update redirected links * Fix links to labels with spaces * Remove dead link
1 parent 97ad694 commit e661e33

File tree

9 files changed

+22
-16
lines changed

9 files changed

+22
-16
lines changed

conf.py

Lines changed: 11 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -67,6 +67,7 @@
6767
# Login page
6868
r"https://github.com/python/buildmaster-config/issues/new.*": r"https://github.com/login.*", # noqa: E501
6969
r"https://github.com/python/core-workflow/issues/new.*": r"https://github.com/login.*", # noqa: E501
70+
r"https://github.com/orgs/python/teams.*": r"https://github.com/login.*", # noqa: E501
7071
# Archive redirect
7172
r"https://github.com/python/cpython/archive/main.zip": r"https://codeload.github.com/python/cpython/zip/refs/heads/main", # noqa: E501
7273
# Blob to tree
@@ -89,6 +90,13 @@
8990
r'\/.*',
9091
]
9192

93+
# Check the link itself, but ignore anchors that are added by JS
94+
# https://www.sphinx-doc.org/en/master/usage/configuration.html#confval-linkcheck_anchors_ignore_for_url
95+
linkcheck_anchors_ignore_for_url = [
96+
# GitHub
97+
r'https://github.com/.*',
98+
]
99+
92100
linkcheck_ignore = [
93101
# The voters repo is private and appears as a 404
94102
'https://github.com/python/voters',
@@ -98,17 +106,14 @@
98106
'https://discuss.python.org/groups/staff',
99107
'https://discuss.python.org/groups/moderators',
100108
'https://discuss.python.org/groups/admins',
101-
# The crawler gets "Anchor not found" for GitHub anchors
102-
r'https://github.com.+?#L\d+',
103-
r'https://github.com/cli/cli#installation',
104-
r'https://github.com/github/renaming#renaming-existing-branches',
105-
r'https://github.com/python/bedevere/#pr-state-machine',
106109
# "Anchor not found":
107110
r'https://packaging.python.org/.*#',
108111
# "-rate limited-", causing a timeout
109112
r'https://stackoverflow.com/.*',
110113
# Discord doesn't allow robot crawlers: "403 Client Error: Forbidden"
111-
'https://support.discord.com/hc/en-us/articles/219070107-Server-Nicknames',
114+
r'https://support.discord.com/hc/en-us/articles/219070107-Server-Nicknames',
115+
# Patreon also gives 403 to the GHA linkcheck runner
116+
r'https://www.patreon.com/.*',
112117
]
113118

114119
rediraffe_redirects = {

core-developers/motivations.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -261,7 +261,7 @@ participating in the CPython core development process:
261261

262262
.. topic:: Carol Willing (United States)
263263

264-
* Noteable: `<https://noteable.io/about-us/>`__ (VP Engineering)
264+
* Noteable (VP Engineering)
265265
* Personal site: `Willing Consulting <https://www.willingconsulting.com/>`_
266266
* `Extended bio <https://www.willingconsulting.com/about/>`__
267267
* Project Jupyter (Software Council, Core Team for JupyterHub/Binder)

developer-workflow/communication-channels.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -263,7 +263,7 @@ Other core workflow tools are:
263263
* `blurb_it`_
264264
* `miss-islington`_
265265
* `cla-bot`_
266-
* `cpython-emailer-webhook`_
266+
* `webhook-mailer`_
267267

268268
Python `Performance Benchmark`_ project is intended to be an authoritative
269269
source of benchmarks for all Python implementations.
@@ -274,5 +274,5 @@ source of benchmarks for all Python implementations.
274274
.. _blurb_it: https://github.com/python/blurb_it
275275
.. _miss-islington: https://github.com/python/miss-islington
276276
.. _cla-bot: https://github.com/ambv/cla-bot
277-
.. _cpython-emailer-webhook: https://github.com/berkerpeksag/cpython-emailer-webhook
277+
.. _webhook-mailer: https://github.com/python/webhook-mailer
278278
.. _Performance Benchmark: https://github.com/python/pyperformance

developer-workflow/extension-modules.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,7 @@ with the following :func:`!foo.greet` function:
7575
7676
Instead of using the Python implementation of :func:`!foo.greet`, we want to
7777
use its corresponding C extension implementation exposed in the :mod:`!_foo`
78-
module. Ideally, we want to modify :cpy-file:`!Lib/foo.py` as follows:
78+
module. Ideally, we want to modify ``Lib/foo.py`` as follows:
7979

8080
.. code-block:: python
8181
:caption: Lib/foo.py

developer-workflow/lang-changes.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ The `Ideas Discourse category`_
4545
is specifically intended for discussion of new features and language changes.
4646
Please don't be disappointed if your idea isn't met with universal approval:
4747
as the :pep:`long list of Withdrawn and Rejected PEPs
48-
<0#abandoned-withdrawn-and-rejected-peps>`
48+
<0#rejected-superseded-and-withdrawn-peps>`
4949
in the :pep:`PEP Index <0>` attests,
5050
and as befits a reasonably mature programming language,
5151
getting significant changes into Python isn't a simple task.

getting-started/git-boot-camp.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -341,7 +341,7 @@ example, backports to other branches), so this features is only useful if
341341
you know for sure that a single PR is enough to address and close the issue.
342342

343343
.. _bedevere: https://github.com/python/bedevere
344-
.. _special keywords: https://docs.github.com/en/issues/tracking-your-work-with-issues/linking-a-pull-request-to-an-issue#linking-a-pull-request-to-an-issue-using-a-keyword
344+
.. _special keywords: https://docs.github.com/en/issues/tracking-your-work-with-issues/using-issues/linking-a-pull-request-to-an-issue#linking-a-pull-request-to-an-issue-using-a-keyword
345345

346346
Updating your CPython fork
347347
--------------------------

getting-started/setup-building.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ itself. Git is easily available for all common operating systems.
4747
or the `Git project instructions <https://git-scm.com>`_ for step-by-step
4848
installation directions. You may also want to consider a graphical client
4949
such as `TortoiseGit <https://tortoisegit.org/>`_ or
50-
`GitHub Desktop <https://desktop.github.com/>`_.
50+
`GitHub Desktop <https://github.com/apps/desktop>`_.
5151

5252
- **Configure**
5353

triage/issue-tracker.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -159,6 +159,6 @@ reason either as ``complete`` or ``not planned``.
159159
.. _Python Discourse: https://discuss.python.org/
160160
.. _autolinks: https://docs.github.com/en/get-started/writing-on-github/working-with-advanced-formatting/autolinked-references-and-urls
161161
.. _checklists: https://docs.github.com/en/get-started/writing-on-github/working-with-advanced-formatting/about-task-lists
162-
.. _duplicates: https://docs.github.com/en/issues/tracking-your-work-with-issues/marking-issues-or-pull-requests-as-a-duplicate
162+
.. _duplicates: https://docs.github.com/en/issues/tracking-your-work-with-issues/administering-issues/marking-issues-or-pull-requests-as-a-duplicate
163163
.. _Core Development Discourse category: https://discuss.python.org/c/core-dev/23
164164
.. _old bug tracker: https://bugs.python.org/

triage/labels.rst

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -147,9 +147,10 @@ to trigger specific bot behaviors.
147147
by these labels.
148148
See also :ref:`the status of the Python branches <branchstatus>` for a list
149149
of branches and the type of PRs that can be backported to them.
150-
* :gh-label:`skip issue`: for trivial changes (such as typo fixes, comment
150+
* :gh-label:`skip issue <skip%20issue>`: for trivial changes (such as
151+
typo fixes, comment
151152
changes, and section rephrases) that don't require a corresponding issue.
152-
* :gh-label:`skip news`: for PRs that don't need a NEWS entry.
153+
* :gh-label:`skip news <skip%20news>`: for PRs that don't need a NEWS entry.
153154
The :ref:`news-entry` section covers in details in which cases the NEWS entry
154155
can be skipped.
155156
* :gh-label:`test-with-buildbots`: used to test the latest commit with

0 commit comments

Comments
 (0)