- 31.3k
- 22
- 110
- 134
I've tried looking at stack overflowStack Overflow and blog posts. These helped me learn how to workaround the issue, but I'm still confused on what the root cause could be. I've also looked at what files are considered diverged using this post. I've had issues finding answers due to my current workflow being different than the traditional workflows blogs and stack overflowStack Overflow posts tend to reference.
I've tried looking at stack overflow and blog posts. These helped me learn how to workaround the issue, but I'm still confused on what the root cause could be. I've also looked at what files are considered diverged using this post. I've had issues finding answers due to my current workflow being different than the traditional workflows blogs and stack overflow posts tend to reference.
I've tried looking at Stack Overflow and blog posts. These helped me learn how to workaround the issue, but I'm still confused on what the root cause could be. I've also looked at what files are considered diverged using this post. I've had issues finding answers due to my current workflow being different than the traditional workflows blogs and Stack Overflow posts tend to reference.
- 31.3k
- 22
- 110
- 134
Why do I see divergent branches gitGit errors when merging code?
hint: You have divergent branches and need to specify how to reconcile them.
hint: You can do so by running one of the following commands sometime before
hint: your next pull:
hint:
hint: git config pull.rebase false # merge (the default strategy)
hint: git config pull.rebase true # rebase
hint: git config pull.ff only # fast-forward only
hint:
hint: You can replace "git config" with "git config --global" to set a default
hint: preference for all repositories. You can also pass --rebase, --no-rebase,
hint: or --ff-only on the command line to override the configured default per
hint: invocation.
I've been using Git for about 10 years now. I don't consider myself a true expert, but I'm very comfortable in the command line and can get myself out of most errors I run into, however this issue has stumped me.
Traditionally my office directly merges feature branches into a main branch then deploys that main branch, this is a continuous delivery pattern that the entire company pretty much follows. Due to some constraints my team decided to take a different approach to release our new app. The team has decided to keep the old code frozen on the main branch with 0 merges, unless there is a production bug. Next, we created a release branch off of main, and then mergemerged all feature branches into the release branch. After all features have been developed, the release branch will be merged into the main branch and elevated/deployed. I'm not a huge fan of this approach, it feels like waterfall developmentwaterfall development to me, but it was a team vote, so I'm trying to make the best of it.
My issue is myself and about half the team have started getting "divergent branch" git errors very consistently. These occur when trying to pull release into a feature branch after a different branches pull request has been merged into the release branch. The other half of the team never sees the errors and can merge/pull/push/etc, pull, push, etc... like normal. My hunch is this is due to the non-standardnonstandard workflow we are using, but I don't know how to prove it. I could also be completely wrong on that hunch, but the workflow is the only thing that's changed since I've started seeing these errors.
I understand what the divergent branch error means and I know how to workaround the issue and resolve it in gitGit. This question is more why is this happening and why is this happening to only half the team? I've spent a few weeks wondering about it, but I haven't been able to pinpoint why this is suddenly an issue.
Extra infoinformation that may or may not be useful:
- 1 windows devThere is one Windows developer on the team and they have never seen this issue, the. The other 5 devsfive developers use OS X and 3three of us get the divergent branch issue while the other 2two have never seen it.
I've followed the error message and tried setting my merging strategy to fast forward only and rebase true, but the problem still persists. As for my team, I don't think anyone else has ever touched their git configsGit configurations, so they would all be on the default strategy.
I've tried looking at stack overflow and blog posts. These helped me learn how to workaround the issue, but I'm still confused on what the root cause could be. I've also looked at what files are considered diverged using this post. I've had issues finding answers due to my current workflow being different than the traditional workflows blogs and stack overflow posts tend to reference.
Why do I see divergent branches git errors when merging code?
hint: You have divergent branches and need to specify how to reconcile them.
hint: You can do so by running one of the following commands sometime before
hint: your next pull:
hint:
hint: git config pull.rebase false # merge (the default strategy)
hint: git config pull.rebase true # rebase
hint: git config pull.ff only # fast-forward only
hint:
hint: You can replace "git config" with "git config --global" to set a default
hint: preference for all repositories. You can also pass --rebase, --no-rebase,
hint: or --ff-only on the command line to override the configured default per
hint: invocation.
I've been using Git for about 10 years now. I don't consider myself a true expert but I'm very comfortable in the command line and can get myself out of most errors I run into, however this issue has stumped me.
Traditionally my office directly merges feature branches into a main branch then deploys that main branch, this is a continuous delivery pattern that the entire company pretty much follows. Due to some constraints my team decided to take a different approach to release our new app. The team has decided to keep the old code frozen on the main branch with 0 merges unless there is a production bug. Next we created a release branch off of main, then merge all feature branches into the release branch. After all features have been developed the release branch will be merged into the main branch and elevated/deployed. I'm not a huge fan of this approach, it feels like waterfall development to me, but it was a team vote so I'm trying to make the best of it.
My issue is myself and about half the team have started getting "divergent branch" git errors very consistently. These occur when trying to pull release into a feature branch after a different branches pull request has been merged into the release branch. The other half of the team never sees the errors and can merge/pull/push/etc... like normal. My hunch is this is due to the non-standard workflow we are using but I don't know how to prove it. I could also be completely wrong on that hunch but the workflow is the only thing that's changed since I've started seeing these errors.
I understand what the divergent branch error means and I know how to workaround the issue and resolve it in git. This question is more why is this happening and why is this happening to only half the team? I've spent a few weeks wondering about it but haven't been able to pinpoint why this is suddenly an issue.
Extra info that may or may not be useful:
- 1 windows dev on the team and they have never seen this issue, the other 5 devs use OS X and 3 of us get the divergent branch issue while the other 2 have never seen it.
I've followed the error message and tried setting my merging strategy to fast forward only and rebase true but the problem still persists. As for my team I don't think anyone else has ever touched their git configs so they would all be on the default strategy. I've tried looking at stack overflow and blog posts. These helped me learn how to workaround the issue but I'm still confused on what the root cause could be. I've also looked at what files are considered diverged using this post. I've had issues finding answers due to my current workflow being different than the traditional workflows blogs and stack overflow posts tend to reference.
Why do I see divergent branches Git errors when merging code?
hint: You have divergent branches and need to specify how to reconcile them.
hint: You can do so by running one of the following commands sometime before
hint: your next pull:
hint:
hint: git config pull.rebase false # merge (the default strategy)
hint: git config pull.rebase true # rebase
hint: git config pull.ff only # fast-forward only
hint:
hint: You can replace "git config" with "git config --global" to set a default
hint: preference for all repositories. You can also pass --rebase, --no-rebase,
hint: or --ff-only on the command line to override the configured default per
hint: invocation.
I've been using Git for about 10 years now. I don't consider myself a true expert, but I'm very comfortable in the command line and can get myself out of most errors I run into, however this issue has stumped me.
Traditionally my office directly merges feature branches into a main branch then deploys that main branch, this is a continuous delivery pattern that the entire company pretty much follows. Due to some constraints my team decided to take a different approach to release our new app. The team has decided to keep the old code frozen on the main branch with 0 merges, unless there is a production bug. Next, we created a release branch off of main and then merged all feature branches into the release branch. After all features have been developed, the release branch will be merged into the main branch and elevated/deployed. I'm not a huge fan of this approach, it feels like waterfall development to me, but it was a team vote, so I'm trying to make the best of it.
My issue is myself and about half the team have started getting "divergent branch" git errors very consistently. These occur when trying to pull release into a feature branch after a different branches pull request has been merged into the release branch. The other half of the team never sees the errors and can merge, pull, push, etc... like normal. My hunch is this is due to the nonstandard workflow we are using, but I don't know how to prove it. I could also be completely wrong on that hunch, but the workflow is the only thing that's changed since I've started seeing these errors.
I understand what the divergent branch error means and I know how to workaround the issue and resolve it in Git. This question is more why is this happening and why is this happening to only half the team? I've spent a few weeks wondering about it, but I haven't been able to pinpoint why this is suddenly an issue.
Extra information that may or may not be useful:
- There is one Windows developer on the team and they have never seen this issue. The other five developers use OS X and three of us get the divergent branch issue while the other two have never seen it.
I've followed the error message and tried setting my merging strategy to fast forward only and rebase true, but the problem still persists. As for my team, I don't think anyone else has ever touched their Git configurations, so they would all be on the default strategy.
I've tried looking at stack overflow and blog posts. These helped me learn how to workaround the issue, but I'm still confused on what the root cause could be. I've also looked at what files are considered diverged using this post. I've had issues finding answers due to my current workflow being different than the traditional workflows blogs and stack overflow posts tend to reference.
- Everyone has the same git/laptop/IDE config
- 1 windows dev on the team and they have never seen this issue, the other 5 devs use OS X and 3 of us get the divergent branch issue while the other 2 have never seen it.
- Everyone has the same git/laptop/IDE config
- 1 windows dev on the team and they have never seen this issue, the other 5 devs use OS X and 3 of us get the divergent branch issue while the other 2 have never seen it.
- 1 windows dev on the team and they have never seen this issue, the other 5 devs use OS X and 3 of us get the divergent branch issue while the other 2 have never seen it.