File tree 4 files changed +13
-10
lines changed
4 files changed +13
-10
lines changed Original file line number Diff line number Diff line change @@ -7,6 +7,9 @@ Dependencies
7
7
Incompatible changes
8
8
--------------------
9
9
10
+ * #9435: linkcheck: Disable checking automatically generated anchors on
11
+ github.com (ex. anchors in reST/Markdown documents)
12
+
10
13
Deprecated
11
14
----------
12
15
@@ -16,6 +19,8 @@ Features added
16
19
Bugs fixed
17
20
----------
18
21
22
+ * #9435: linkcheck: Failed to check anchors in github.com
23
+
19
24
Testing
20
25
--------
21
26
Original file line number Diff line number Diff line change @@ -714,7 +714,10 @@ def setup(app: Sphinx) -> Dict[str, Any]:
714
714
app .add_event ('linkcheck-process-uri' )
715
715
716
716
app .connect ('config-inited' , compile_linkcheck_allowed_redirects , priority = 800 )
717
- app .connect ('linkcheck-process-uri' , rewrite_github_anchor )
717
+
718
+ # FIXME: Disable URL rewrite handler for github.com temporarily.
719
+ # ref: https://github.com/sphinx-doc/sphinx/issues/9435
720
+ # app.connect('linkcheck-process-uri', rewrite_github_anchor)
718
721
719
722
return {
720
723
'version' : 'builtin' ,
Original file line number Diff line number Diff line change @@ -13,8 +13,7 @@ Some additional anchors to exercise ignore code
13
13
* `Complete nonsense <https://localhost:7777/doesnotexist>`_
14
14
* `Example valid local file <conf.py>`_
15
15
* `Example invalid local file <path/to/notfound>`_
16
- * https://github.com/sphinx-doc/sphinx#documentation
17
- * https://github.com/sphinx-doc/sphinx#user-content-testing
16
+ * https://github.com/sphinx-doc/sphinx/blob/4.x/sphinx/__init__.py#L2
18
17
19
18
.. image:: https://www.google.com/image.png
20
19
.. figure:: https://www.google.com/image2.png
Original file line number Diff line number Diff line change @@ -66,8 +66,8 @@ def test_defaults_json(app):
66
66
"info" ]:
67
67
assert attr in row
68
68
69
- assert len (content .splitlines ()) == 12
70
- assert len (rows ) == 12
69
+ assert len (content .splitlines ()) == 11
70
+ assert len (rows ) == 11
71
71
# the output order of the rows is not stable
72
72
# due to possible variance in network latency
73
73
rowsby = {row ["uri" ]: row for row in rows }
@@ -88,7 +88,7 @@ def test_defaults_json(app):
88
88
assert dnerow ['uri' ] == 'https://localhost:7777/doesnotexist'
89
89
assert rowsby ['https://www.google.com/image2.png' ] == {
90
90
'filename' : 'links.txt' ,
91
- 'lineno' : 20 ,
91
+ 'lineno' : 19 ,
92
92
'status' : 'broken' ,
93
93
'code' : 0 ,
94
94
'uri' : 'https://www.google.com/image2.png' ,
@@ -102,10 +102,6 @@ def test_defaults_json(app):
102
102
# images should fail
103
103
assert "Not Found for url: https://www.google.com/image.png" in \
104
104
rowsby ["https://www.google.com/image.png" ]["info" ]
105
- # The anchor of the URI for github.com is automatically modified
106
- assert 'https://github.com/sphinx-doc/sphinx#documentation' not in rowsby
107
- assert 'https://github.com/sphinx-doc/sphinx#user-content-documentation' in rowsby
108
- assert 'https://github.com/sphinx-doc/sphinx#user-content-testing' in rowsby
109
105
110
106
111
107
@pytest .mark .sphinx (
You can’t perform that action at this time.
0 commit comments