Change default branch name to 'rolling' in ROS 2 core

Hello ROS community,

As anyone who has worked in the ROS 2 core knows, we have a myriad of different names for the default branches in the core. These range from ‘master’, to ‘main’, to ‘rolling’, to ‘rolling-devel’, to even ‘crystal-devel’.

In an effort to make this easier to script and explain, we are going to change the default branch on most repositories listed in ros2/ros2.repos at master · ros2/ros2 · GitHub to ‘rolling’. Note that certain repositories will be exempt from this renaming:

In order to not break any downstream scripts, we’ll also be installing a bot that automatically syncs commits from the new ‘rolling’ branch to whatever the old default branch was.

Roughly what we are going to do on every repository is:

  1. Create a ‘rolling’ branch.
  2. Add the GitHub action to automatically sync between the new ‘rolling’ branch and the old default branch.
  3. Change the default to the ‘rolling’ branch.
  4. Retarget existing PRs that target the default branch to target the ‘rolling’ branch.

We’ll also be updating ros2/ros2.repos at master · ros2/ros2 · GitHub to point the repositories at the ‘rolling’ branch, as well as updating the documentation at GitHub - ros2/ros2_documentation: ROS 2 docs repository to do the same.

Assuming all goes to plan, downstream consumers won’t really notice the change, except for the fact that new PRs will start targeting the ‘rolling’ branch instead of the old default. That said, once the transition is complete we will encourage all downstream consumers to use the ‘rolling’ branch.

Please let us know any feedback you have about this change, and if you think we’ve missed any major steps that need to be completed for this to work smoothly. If there are no major obstacles or objections, we’ll start doing this transition the week of June 27th, 2022.

15 Likes

:clap: very nice move!

However, when we release a new version of our webots_ros2 package for different ROS 2 distros using bloom, it seems that the rosdistro repo has CI tests that require the existence of the “foxy”, “galactic”, “humble” and “rolling” branches on the package repo. In our case, we managed to handle the differences between the ROS 2 distros at compile time and runtime mainly using the ROS_DISTRO environment variable, which is great for maintenance. Thus it makes no sense for us to maintain several branches on our package repo (e.g., “foxy”, “galactic”, “humble” and “rolling”) as they hold basically the exact same content, it is confusing contributors and is a pain to maintain them in sync. So my question is:

Do you have any plan to fix the CI tests on rosdistro to remove the requirements for the “foxy”, “galactic” and “humble” branches and allow us to maintain a single branch, e.g., “rolling” on our package repo?

There is no such requirement. You can use any branching scheme you like on your downstream repositories. For instance, I know that PlotJuggler uses the same branch (main) for ROS 1 Melodic, ROS 1 Noetic, ROS 2 Foxy, ROS 2 Galactic, ROS 2 Humble, and ROS 2 Rolling.

The only requirement is that it is a branch, not a tag.

@clalancette sounds good to me.

quick question though. how about the existed PRs to be targeted to current default branch in each repository? Contributors need to change the target branch once the default is changed?

best,
Tomoya

We’ll have a script that automatically retargets all of the existing PRs to the new ‘rolling’ branch. The contributors shouldn’t have to do anything.

1 Like

Since there have been no major objections to this, we are going to go ahead with this renaming tomorrow, June 27th. We request that all maintainers of ROS 2 repositories (any repos listed in ros2/ros2.repos at master · ros2/ros2 · GitHub) refrain from merging PRs starting 2022-06-28T12:00:00Z, as it will be easier for us to keep things in sync that way. We’ll notify here again when it is safe to start merging again (likely later in the day).

FYI @tomoyafujita @MichaelOrlov @jhdcs @christophebedard @iuhilnehc-ynos @smac @emersonknapp

5 Likes

Hi all,
We’ve now done this branching, and merged in the relevant PRs:

As mentioned previously, we also retargeted all existing PRs to ‘rolling’, and also have a bot that automatically syncs ‘rolling’ to the old default branch (we may eventually get rid of that bot, but not for quite a while). One thing we have not done is to create a new branch on GitHub - ros2/ros2: The Robot Operating System, is a meta operating system for robots. , as there is some additional work that goes along with that. That’s work for another day.

At this point, all ROS 2 repositories are open for new commits and PRs. Happy merging!

4 Likes

As a follow-up to this, we are also going to be branching GitHub - ros2/ros2: The Robot Operating System, is a meta operating system for robots. to have a rolling branch by default as well. As with the branches to the main repositories, we’ll keep a bot around to make sure ‘rolling’ and ‘master’ are in sync for the foreseeable future. We’ll also be going through the documentation and CI/build scripts to make sure they point to the new ‘rolling’ branch.

As before, if you have any concerns about this, please let us know here. If there are no objections, we’ll go ahead and do this on July 14th.

1 Like

We’ve heard no objections, so we are going ahead with this today. There should be no disruption to normal service, but if you do see a problem please let us know in this thread.

This is now done, and all of the relevant PRs merged and deployed.

Hopefully there will be no fallout from this, but if you see anything that might be related please let us know.

1 Like