So, I have a Pull Request (PR) that someone had submitted that didn't bother to pull before submitting and therefore has conflicts.
I recieve the following message at the top of the PR.
----
Bitbucket cannot automatically merge this request due to conflicts.
Review the conflicts on the Overview tab below. You can then either decline the request or merge it manually on your local system using the following commands:
----
I understand the option of declining the request and making the other dude fix it, but if I follow the steps and merge the changes in locally. I still have to decline the conflicting PR and handle the changes like I normally would from my local machine, correct? If that is the case, the wording on the message seems to fall a bit short. I mean, it won't let me Edit the PR and change the source account to come from my own.
Ned,
Along with this message, Bitbucket presents you with a list of basic commands for manually merging. If you follow the steps, the second step is to pull the incoming request from the requestors repo. So, after you pull their request and merge it (3 step), you push it (4th) step.
The push to Bitbucket resolves the pull request as well. No need to decline...the request gets marked accepted.
I'll see about clarifying the message, I can see where this could be confusing.
Mary
Mary,
Thanks for your response.
I didn't realize that I had permission to push to their repository. Since they had forked off mine, I guess it does make sense that I would have write privileges.
I was pushing the changes to my account and that's where my confusion was coming from. The missing 4th step of pushing back to their remote would've made this a little clearer for me.
Thanks again,
Ned
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
We've developed a plugin, Power Editor for Bitbucket, that allows you to resolve conflicts on a pull request in the UI. You can check out out here.
It also supports:
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Okay, looking at that and trying a few different commands (I'm still new to Git) resolved it. I believe that these were the steps necessary to resolve my error:
Step 4 resulted in a conflict (as it did on BitBucket), which I resolved locally, committed, and pushed. All seems well now. So maybe the command-line instructions on the BitBucket pull request conflict notice need to be updated?
It would also be great to be able to fix a conflict within the pull request itself on the BitBucket website.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Michael,
Glad you got that resolved! The instructions on the PR dialog are generic; they are the most comon way to resolve the most common conflict; it would not be possible for us to anticipate all the possible conflicts users could find themselves in. Maybe we need to clarify the instructions are generic?
Good luck in your Git adventures!
Mary
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Michael,
That message is coming from Git. I've not seen it before. This stack overflow looks pertinent.
http://stackoverflow.com/questions/16862933/how-to-resolve-gits-not-something-we-can-merge-error
Mary
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I have run into this issue as well. When I try to execute the statements listed on BitBucket, I get this output (error in bold):
$ git checkout master
Already on 'master'
$ git merge --no-ff -m 'Merged in development-branch (pull request #7)' remotes/my-company/my-repo/development-branch
fatal: remotes/my-company/my-repo/development-branch - not something we can merge
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Michael,
That message is coming from Git. I've not seen it before. This stack overflow looks pertinent.
http://stackoverflow.com/questions/16862933/how-to-resolve-gits-not-something-we-can-merge-error
Mary
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.