question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Protected branch restrictions ignored when merging from desktop app

See original GitHub issue

Description

I am able to merge code directly into master from the desktop tool, despite master being a protected branch in our repo that requires both a code review and passing ci tests.

Version

GitHub Desktop version: 1.0.11 OS version: MacOS

Steps to Reproduce

  1. Create a branch that tracks an upstream protected branch
  2. From the GitHub desktop UI, push to origin
  3. Branch bypasses protections and merges into upstream branch

Expected behavior: Fail, or warn about protected branch restrictions

Actual behavior: Merges branch automatically into protected upstream branch

Reproduces how often: 100%

Logs

NA

Additional Information

I have admin permissions in the repo, however in the website UI I am forced to opt-in to override branch protections in order by bypass them with privilege. From the desktop application, I am not warned or restricted from merging into protected branches, regardless of CI states or reviewer status.

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Comments:7 (5 by maintainers)

github_iconTop GitHub Comments

1reaction
shiftkeycommented, Apr 15, 2018

@workobots reported in #4444 that even committing to master may be covered by branch protections, and while pushes are blocked this is a chance for the app to catch and warn users at commit time and guide them to the ideal workflow.

1reaction
shiftkeycommented, Dec 26, 2017

This idea is interesting for the future, but this is beyond the scope of our current roadmap.

I added the future-proposal label to this issue and closed it so that we won’t get overwhelmed with our backlog! We will revisit this in our next planning session.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Set Up Branch and Merge Restrictions | JetBrains Space ...
Open the Repository Settings page and go to the Protected Branches tab: · Click New rule to open the form. · Specify main...
Read more >
Sourcetree seems to ignore protected branch rules
Now, in SourceTree, I can still merge a feature branch into both develop and main without a pull request, using the [right click...
Read more >
Best Practices for Branch Protection - YouTube
Branch protection is part of a powerful set of configuration options that give repository administrators the ability to enforce security ...
Read more >
Merge conflicts - GitLab Docs
GitLab does not detect conflicts when both branches rename a file to different names. For example, these changes don't create a conflict: On...
Read more >
Git branch policies and settings - Azure Repos - Microsoft Learn
Branch policies help teams protect their important branches of development. ... For more information, see Set Git repository permissions.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found