[Release management] schedule for renaming the default branch
Hi, I am writing on behalf of the Python Release Management team. The Steering Council has requested the RM team to schedule and perform the necessary changes to rename the default branch from master to main. # The changes What follows is the technical description of the changes and the timeline. In order to keep this thread focused on this particular aspect, if you wish to discuss anything related to the change itself, please, open a new email thread or reuse an existing one. - The change will be executed ***when beta 1 is released***, as the beta 1 release requires some branching engineering already to create the 3.10 branch and point 3.11 to the new one as well as changing CI, buildbots...etc ** *This is scheduled for Monday, 2021-05-03**.* - The CI will be adapted to work with the new "main" branch. - The buildbots will be adapted to work with the new "main" branch. - Branch protection rules will be adapted. - The different bots will be adapted by the respective bot maintainer teams. - All the URLs that point to master in the README and other places will be adapted to point to main instead (notice this is not strictly necessary because GitHub redirects automatically). Notice that the renaming will automatically: - Re-target any open pull requests - Update any draft releases based on the branch - Move any branch protection rules that explicitly reference the old name - Show a notice to repository contributors, maintainers, and admins on the repository homepage with instructions to update local copies of the repository - Show a notice to contributors who git push to the old branch - Redirect web requests for the old branch name to the new branch name - Return a "Moved Permanently" response in API requests for the old branch name Check this <https://github.com/github/renaming> for more information. # What you need to do? You just need to update your local clone after the branch name changes. From the local clone of the repository on a computer, run the following commands to update the name of the default branch. $ git branch -m master main $ git fetch origin $ git branch -u origin/main main Apart from that, you should update any local script or command that uses the name "master" to use the name "main". Regards from windy London, Pablo Galindo Salgado
Hi I would be great to read the impact analysis for this change, and understand who the identified impacted parties are, and what the plan is to notify them and help them update within this timescale. Has this analysis been published anywhere? I know there are lots of places where discussions/documentation happens Thanks Steve On Wed, Mar 10, 2021 at 2:10 PM Pablo Galindo Salgado <pablogsal@gmail.com> wrote:
Hi,
I am writing on behalf of the Python Release Management team. The Steering Council has requested the RM team to schedule and perform the necessary changes to rename the default branch from master to main.
# The changes
What follows is the technical description of the changes and the timeline. In order to keep this thread focused on this particular aspect, if you wish to discuss anything related to the change itself, please, open a new email thread or reuse an existing one.
- The change will be executed ***when beta 1 is released***, as the beta 1 release requires some branching engineering already to create the 3.10 branch and point 3.11 to the new one as well as changing CI, buildbots...etc ** *This is scheduled for Monday, 2021-05-03**.* - The CI will be adapted to work with the new "main" branch. - The buildbots will be adapted to work with the new "main" branch. - Branch protection rules will be adapted. - The different bots will be adapted by the respective bot maintainer teams. - All the URLs that point to master in the README and other places will be adapted to point to main instead (notice this is not strictly necessary because GitHub redirects automatically).
Notice that the renaming will automatically:
- Re-target any open pull requests - Update any draft releases based on the branch - Move any branch protection rules that explicitly reference the old name - Show a notice to repository contributors, maintainers, and admins on the repository homepage with instructions to update local copies of the repository - Show a notice to contributors who git push to the old branch - Redirect web requests for the old branch name to the new branch name - Return a "Moved Permanently" response in API requests for the old branch name
Check this <https://github.com/github/renaming> for more information.
# What you need to do?
You just need to update your local clone after the branch name changes. From the local clone of the repository on a computer, run the following commands to update the name of the default branch.
$ git branch -m master main $ git fetch origin $ git branch -u origin/main main
Apart from that, you should update any local script or command that uses the name "master" to use the name "main".
Regards from windy London, Pablo Galindo Salgado _______________________________________________ Python-Dev mailing list -- python-dev@python.org To unsubscribe send an email to python-dev-leave@python.org https://mail.python.org/mailman3/lists/python-dev.python.org/ Message archived at https://mail.python.org/archives/list/python-dev@python.org/message/QWW7KGBW... Code of Conduct: http://python.org/psf/codeofconduct/
I am answering this as a member of the release management team, not as an official response from the SC.
and understand who the identified impacted parties are
All developers that have clones of the repository and any party maintaining any script that interacts with the default CPython branch.
and what the plan is to notify them
These messages on python-dev and python-comitters + messages in the official release announcement and notes.
and help them update within this timescale
For the repositories, execute the commands listed in the previous message. For scrips and other references to the main branch, they need to do the change themselves but in most cases is a simple rename master->main.
Has this analysis been published anywhere
No. It has been discussed by the Steering Council as you can see in the February update: https://github.com/python/steering-council/blob/main/updates/2021-02-steerin... On Wed, 10 Mar 2021 at 14:21, Stestagg <stestagg@gmail.com> wrote:
Hi
I would be great to read the impact analysis for this change, and understand who the identified impacted parties are, and what the plan is to notify them and help them update within this timescale.
Has this analysis been published anywhere? I know there are lots of places where discussions/documentation happens
Thanks
Steve
On Wed, Mar 10, 2021 at 2:10 PM Pablo Galindo Salgado <pablogsal@gmail.com> wrote:
Hi,
I am writing on behalf of the Python Release Management team. The Steering Council has requested the RM team to schedule and perform the necessary changes to rename the default branch from master to main.
# The changes
What follows is the technical description of the changes and the timeline. In order to keep this thread focused on this particular aspect, if you wish to discuss anything related to the change itself, please, open a new email thread or reuse an existing one.
- The change will be executed ***when beta 1 is released***, as the beta 1 release requires some branching engineering already to create the 3.10 branch and point 3.11 to the new one as well as changing CI, buildbots...etc ** *This is scheduled for Monday, 2021-05-03**.* - The CI will be adapted to work with the new "main" branch. - The buildbots will be adapted to work with the new "main" branch. - Branch protection rules will be adapted. - The different bots will be adapted by the respective bot maintainer teams. - All the URLs that point to master in the README and other places will be adapted to point to main instead (notice this is not strictly necessary because GitHub redirects automatically).
Notice that the renaming will automatically:
- Re-target any open pull requests - Update any draft releases based on the branch - Move any branch protection rules that explicitly reference the old name - Show a notice to repository contributors, maintainers, and admins on the repository homepage with instructions to update local copies of the repository - Show a notice to contributors who git push to the old branch - Redirect web requests for the old branch name to the new branch name - Return a "Moved Permanently" response in API requests for the old branch name
Check this <https://github.com/github/renaming> for more information.
# What you need to do?
You just need to update your local clone after the branch name changes. From the local clone of the repository on a computer, run the following commands to update the name of the default branch.
$ git branch -m master main $ git fetch origin $ git branch -u origin/main main
Apart from that, you should update any local script or command that uses the name "master" to use the name "main".
Regards from windy London, Pablo Galindo Salgado _______________________________________________ Python-Dev mailing list -- python-dev@python.org To unsubscribe send an email to python-dev-leave@python.org https://mail.python.org/mailman3/lists/python-dev.python.org/ Message archived at https://mail.python.org/archives/list/python-dev@python.org/message/QWW7KGBW... Code of Conduct: http://python.org/psf/codeofconduct/
_______________________________________________ Python-Dev mailing list -- python-dev@python.org To unsubscribe send an email to python-dev-leave@python.org https://mail.python.org/mailman3/lists/python-dev.python.org/ Message archived at https://mail.python.org/archives/list/python-dev@python.org/message/66RS2S6E... Code of Conduct: http://python.org/psf/codeofconduct/
Thanks for the response! No. It has been discussed by the Steering Council as you can see in the
February update: https://github.com/python/steering-council/blob/main/updates/2021-02-steerin...
Ok, great, I assume the missing bits will be coming in the March update Steve
10.03.21 16:06, Pablo Galindo Salgado пише:
# What you need to do?
You just need to update your local clone after the branch name changes. From the local clone of the repository on a computer, run the following commands to update the name of the default branch.
$ git branch -m master main $ git fetch origin $ git branch -u origin/main main
Apart from that, you should update any local script or command that uses the name "master" to use the name "main".
I have above 200 feature branches in my local repository. Will renaming the master branch cause any problems?
Hi Serhiy, On Thu, Mar 11, 2021 at 8:33 AM Serhiy Storchaka <storchaka@gmail.com> wrote:
I have above 200 feature branches in my local repository. Will renaming the master branch cause any problems?
I don't think that you need to do anything on your machine nor on your open PRs. When I use "git switch -c new_branch" command to create a new branch, the created branch doesn't "track" its parent branch by default. Example: $ git branch -vv (...) * gilstate_init a6959b8971 bpo-43311: Create GIL autoTSSkey ealier master 9a9c11ad41 [upstream/master] bpo-43287: Use PEP 590 vectorcall to speed up filter() (GH-24611) My "gilstate_init" local branch doesn't track any branch, whereas my local "master" branch tracks upstream/master (my upstream remote is git@github.com:python/cpython.git). Usually, when I want to easily see the differences between a local branch and my local master branch (to use my "git out" alias), I type "git branch --set-upstream-to=master": $ git switch gilstate_init $ git branch --set-upstream-to=master $ git out a6959b8971 bpo-43311: Create GIL autoTSSkey ealier where my "git out" alias is the command: $ git log '@{upstream}..' --pretty='format:%Cred%h%Creset %s' --color --reverse You can check that gilstate_init now tracks my local master branch: $ git branch -vv (...) gilstate_init a6959b8971 [master: ahead 1] bpo-43311: Create GIL autoTSSkey ealier master 9a9c11ad41 [upstream/master] bpo-43287: Use PEP 590 vectorcall to speed up filter() (GH-24611) Use "git switch -c new_branch --track master" to create a new branch based on master which tracks the master branch. Maybe I should track upstream/master rather than my local master branch, but when I fetch the upstream remote, I always update my local master branch, so in my case, it's the same in pratice :-) And "master" is shorter to type than "upstream/master". Victor -- Night gathers, and now my watch begins. It shall not end until my death.
I have above 200 feature branches in my local > repository. Will renaming the master branch cause any problems?
It should not be any problem at all. If you have some open PRs from some of those branches, they will be automatically retargeted to the new branch name in GitHub automatically. On Thu, 11 Mar 2021, 07:37 Serhiy Storchaka, <storchaka@gmail.com> wrote:
10.03.21 16:06, Pablo Galindo Salgado пише:
# What you need to do?
You just need to update your local clone after the branch name changes. From the local clone of the repository on a computer, run the following commands to update the name of the default branch.
$ git branch -m master main $ git fetch origin $ git branch -u origin/main main
Apart from that, you should update any local script or command that uses the name "master" to use the name "main".
I have above 200 feature branches in my local repository. Will renaming the master branch cause any problems?
_______________________________________________ Python-Dev mailing list -- python-dev@python.org To unsubscribe send an email to python-dev-leave@python.org https://mail.python.org/mailman3/lists/python-dev.python.org/ Message archived at https://mail.python.org/archives/list/python-dev@python.org/message/G2LLBPJM... Code of Conduct: http://python.org/psf/codeofconduct/
participants (4)
-
Pablo Galindo Salgado
-
Serhiy Storchaka
-
Stestagg
-
Victor Stinner