Search code examples
azure-devopsazure-boardsgithub-integration

How to branch from non-default branch in Azure DevOps GitHub.com integration?


We are currently integrating Azure DevOps Services (Cloud) with GitHub.com. We used the Azure Boards app and now have options in Azure DevOps to create branches on GitHub.com.

The branching works with the default branch only.

Selecting Create GitHub Branch, if I try to select a non-default branch and click Create the Create icons spins and never completes. The branch is not created. I am not seeing any settings for this behavior.

If I select a branch marked as Default this process works.

I'm not seeing any settings to control this behavior.

Of note when the process does complete, I get an error:

The GitHub branch was created successfully, but the link was not added due to an unexpected error. Please add the link manually or retry the operation later.

But the link is successfully created automatically.

  • Tried setting other branches to default and the process completes
  • Tried setting main to non-default and the icon just spins
  • Disabled all rules sets on GitHub side

Create a GitHub branch screen


Solution

  • I was able to replicate the issue when attempting to create a new GitHub branch from a non-default branch. Upon reviewing the network traces, it appeared that no request was being sent during the process.

    enter image description here

    Additionally, when I changed the default branch in my GitHub repository from main to dev, the branch creation worked, however with the error message saying The GitHub branch was created successfully, but the link was not added due to an unexpected error. Please add the link manually or retry the operation later..

    enter image description here

    It's important to note that the functionality for creating GitHub branches directly from work items was released in July 2024 and is currently only available as part of the New Boards Hubs feature. While this behavior is not ideal, it’s worth remembering that the feature is still in preview. I recommend leveraging the feedback options provided in the linked documentation to engage the engineering team, helping them collect and address issues more effectively. Your sharing and efforts are much appreciated.

    Image