# Support for including Misc/NEWS
-issue_re = re.compile('(?:[Ii]ssue #|bpo-)([0-9]+)')
+issue_re = re.compile('(?:[Ii]ssue #|bpo-)([0-9]+)', re.I)
+gh_issue_re = re.compile('(?:gh-issue-|gh-)([0-9]+)', re.I)
whatsnew_re = re.compile(r"(?im)^what's new in (.*?)\??$")
text = 'The NEWS file is not available.'
node = nodes.strong(text, text)
return [node]
- content = issue_re.sub(r'`bpo-\1 <https://bugs.python.org/'
- r'issue?@action=redirect&bpo=\1>`__',
- content)
+ content = issue_re.sub(r':issue:`\1`', content)
+ # Fallback handling for the GitHub issue
+ content = gh_issue_re.sub(r':gh:`\1`', content)
content = whatsnew_re.sub(r'\1', content)
# remove first 3 lines as they are the main heading
lines = ['.. default-role:: obj', ''] + content.splitlines()[3:]
.. section: Library
Fix segfault in :meth:`sqlite3.Connection.backup` if no argument was
-provided. The regression was introduced by GH-23838. Patch by Erlend E.
+provided. The regression was introduced by PR 23838. Patch by Erlend E.
Aasland.
..
.. nonce: t9XEkQ
.. section: Library
-Fix a regression introduced in GH-24562, where an empty bytestring was
+Fix a regression introduced in PR 24562, where an empty bytestring was
fetched as ``None`` instead of ``b''`` in :mod:`sqlite3`. Patch by Mariusz
Felisiak.
..
-.. bpo: 47383
+.. gh: 47383
.. date: 2021-04-08-19-32-26
.. nonce: YI1hdL
.. section: Library
Fix :mod:`sqlite3` regression for zero-sized blobs with converters, where
``b""`` was returned instead of ``None``. The regression was introduced by
-GH-24723. Patch by Erlend E. Aasland.
+PR 24723. Patch by Erlend E. Aasland.
..
.. section: Library
Fix typo: ``importlib.find_loader`` is really slated for removal in Python
-3.12 not 3.10, like the others in GH-25169.
+3.12 not 3.10, like the others in PR 25169.
Patch by Hugo van Kemenade.
..
-.. bpo: 78157
+.. gh: 78157
.. date: 2022-05-05-20-40-45
.. nonce: IA_9na
.. section: Library
..
-.. bpo: 91498
+.. gh: 91498
.. date: 2022-04-10-08-39-44
.. nonce: 8oII92
.. section: Library
..
-.. bpo: 321010
+.. bpo: 32101
.. date: 2017-11-29-00-42-47
.. nonce: -axD5l
.. section: Library
.. section: Library
Remove HMAC default to md5 marked for removal in 3.8 (removal originally
-planned in 3.6, bump to 3.8 in gh-7062).
+planned in 3.6, bump to 3.8 in PR 7062).
..
.. nonce: 9TWMlz
.. section: Library
-Revert GH-15522, which introduces a regression in
+Revert PR 15522, which introduces a regression in
:meth:`mimetypes.guess_type` due to improper handling of filenames as urls.
..