Skip to content

Commit 8c3e25a

Browse files
Reinstate #backport-pr-title anchor and add explicit backport PR title guidance (#1855)
Co-authored-by: Stan Ulbrych <stan@python.org>
1 parent 8996911 commit 8c3e25a

2 files changed

Lines changed: 16 additions & 0 deletions

File tree

core-team/committing.rst

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -149,6 +149,8 @@ bug fixes or security fixes. In almost all cases the fixes should first
149149
originate on ``main`` and then be ported back to older branches.
150150

151151

152+
.. _backport-pr-title:
153+
152154
Backporting changes to an older version
153155
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
154156

getting-started/git-boot-camp.rst

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -622,6 +622,9 @@ The format of a correct backport commit message is:
622622
623623
(cherry picked from commit <commit_sha1>)
624624
625+
Here ``gh-XXXXX`` is the GitHub *issue* number, and ``(GH-XXXXX)`` is the
626+
original *pull request* number.
627+
625628
An example of a bad backport commit message:
626629

627630
.. code-block:: text
@@ -631,6 +634,17 @@ An example of a bad backport commit message:
631634
632635
* Custom message
633636
637+
.. _backport-pr:
638+
639+
When opening the backport PR, its title PR must follow the same format as the
640+
commit title, beginning with the ``[<branch>]`` prefix and referencing the
641+
original PR with a ``(GH-XXXXX)`` suffix. For example:
642+
643+
.. code-block:: text
644+
:class: good
645+
646+
[3.15] gh-12345: Fix the spam module (GH-24680)
647+
634648
After the backport PR is opened, ``miss-islington`` will link it to the original
635649
PR and remove the corresponding backport label.
636650

0 commit comments

Comments
 (0)