Uploaded image for project: 'Bitbucket Data Center'
  1. Bitbucket Data Center
  2. BSERV-5282

MergeException: New changes were pushed to master in PROJECT/repo while the merge was being performed

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Handled by Support
    • Icon: Low Low
    • None
    • 3.2.4
    • None
    • None

      This error shows up when trying to merge PR

      2014-09-23 17:51:56,514 DEBUG [http-bio-7990-exec-13] username @1KHFC1Ux1071x447x0 1b6hse4 10.231.40.88,127.0.0.1 "POST /rest/api/latest/projects/PROJECT/repos/repo/pull-requests/308/merge HTTP/1.1" c.a.s.r.e.ServiceExceptionMapper
      Mapping ServiceException to REST response 409
      com.atlassian.stash.scm.MergeException: New changes were pushed to master in PROJECT/repo while the merge was being performed. Please retry the merge.
              at com.atlassian.stash.internal.scm.git.merge.MergeCommand.newMergeException(MergeCommand.java:132) ~[na:na]
              at com.atlassian.stash.internal.scm.git.merge.MergeCommand.doWithWorkTree(MergeCommand.java:112) ~[na:na]
              at com.atlassian.stash.internal.scm.git.merge.MergeCommand.doWithWorkTree(MergeCommand.java:29) ~[na:na]
              at com.atlassian.stash.internal.scm.git.porcelain.AbstractWorkTreeCommand.call(AbstractWorkTreeCommand.java:37) ~[na:na]
              at com.atlassian.stash.internal.pull.PullRequestServiceImpl$MergeAndUpdatePullRequestOperation.perform(PullRequestServiceImpl.java:1646) ~[stash-service-impl-3.2.4.jar:na]
              at com.atlassian.stash.internal.pull.PullRequestServiceImpl$MergeAndUpdatePullRequestOperation.perform(PullRequestServiceImpl.java:1618) ~[stash-service-impl-3.2.4.jar:na]
              at com.atlassian.stash.internal.concurrent.DefaultLockService.doWithLock(DefaultLockService.java:102) ~[stash-service-impl-3.2.4.jar:na]
              at com.atlassian.stash.internal.concurrent.DefaultLockService.doWithLock(DefaultLockService.java:68) ~[stash-service-impl-3.2.4.jar:na]
              at com.atlassian.stash.internal.pull.PullRequestServiceImpl.merge(PullRequestServiceImpl.java:623) ~[stash-service-impl-3.2.4.jar:na]
              at com.atlassian.stash.internal.rest.pull.PullRequestResource.mergePullRequest(PullRequestResource.java:425) ~[stash-rest-3.2.4.jar:na]
              at com.atlassian.applinks.core.rest.context.ContextFilter.doFilter(ContextFilter.java:25) ~[na:na]
              at com.atlassian.stash.internal.spring.security.StashAuthenticationFilter.doFilter(StashAuthenticationFilter.java:86) ~[StashAuthenticationFilter.class:na]
              at com.atlassian.stash.internal.web.auth.BeforeLoginPluginAuthenticationFilter.doInsideSpringSecurityChain(BeforeLoginPluginAuthenticationFilter.java:111) ~[BeforeLoginPluginAuthenticationFilter.class:na]
              at com.atlassian.stash.internal.web.auth.BeforeLoginPluginAuthenticationFilter.doFilter(BeforeLoginPluginAuthenticationFilter.java:77) ~[BeforeLoginPluginAuthenticationFilter.class:na]
              at com.atlassian.security.auth.trustedapps.filter.TrustedApplicationsFilter.doFilter(TrustedApplicationsFilter.java:100) ~[atlassian-trusted-apps-core-3.0.6.jar:na]
              at com.atlassian.oauth.serviceprovider.internal.servlet.OAuthFilter.doFilter(OAuthFilter.java:69) ~[na:na]
              at com.atlassian.analytics.client.filter.DefaultAnalyticsFilter.doFilter(DefaultAnalyticsFilter.java:33) ~[na:na]
              at com.atlassian.core.filters.AbstractHttpFilter.doFilter(AbstractHttpFilter.java:31) ~[atlassian-core-4.6.15.jar:na]
              at com.atlassian.stash.internal.web.auth.BeforeLoginPluginAuthenticationFilter.doBeforeBeforeLoginFilters(BeforeLoginPluginAuthenticationFilter.java:89) ~[BeforeLoginPluginAuthenticationFilter.class:na]
              at com.atlassian.stash.internal.web.auth.BeforeLoginPluginAuthenticationFilter.doFilter(BeforeLoginPluginAuthenticationFilter.java:75) ~[BeforeLoginPluginAuthenticationFilter.class:na]
              at com.atlassian.stash.internal.request.DefaultRequestManager.doAsRequest(DefaultRequestManager.java:84) ~[stash-service-impl-3.2.4.jar:na]
              at com.hazelcast.web.WebFilter.doFilter(WebFilter.java:446) ~[hazelcast-wm-3.3-RC2.jar:3.3-RC2]
              at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) ~[na:1.7.0_25]
              at java.lang.Thread.run(Thread.java:724) ~[na:1.7.0_25]
              ... 275 frames trimmed
      Caused by: com.atlassian.stash.scm.git.push.NonFastForwardUpdateRejectedException: The merge could not be completed because the target ref was updated mid-merge.
              at com.atlassian.stash.internal.scm.git.command.merge.UpdateRefCommandExitHandler.evaluateStdErr(UpdateRefCommandExitHandler.java:27) ~[na:na]
              at com.atlassian.stash.scm.git.common.command.GitCommandExitHandler.onError(GitCommandExitHandler.java:144) ~[na:na]
              at com.atlassian.stash.scm.DefaultCommandExitHandler.onExit(DefaultCommandExitHandler.java:33) ~[stash-spi-3.2.4.jar:na]
              at com.atlassian.stash.scm.BaseCommand.callExitHandler(BaseCommand.java:138) ~[stash-spi-3.2.4.jar:na]
              at com.atlassian.stash.scm.BaseCommand$CommandFuture.internalGet(BaseCommand.java:251) ~[stash-spi-3.2.4.jar:na]
              at com.atlassian.stash.scm.BaseCommand$CommandFuture.get(BaseCommand.java:220) ~[stash-spi-3.2.4.jar:na]
              at com.atlassian.stash.scm.BaseCommand.call(BaseCommand.java:75) ~[stash-spi-3.2.4.jar:na]
              at com.atlassian.stash.internal.scm.git.porcelain.AbstractTimedRequest.configureAndCall(AbstractTimedRequest.java:30) ~[na:na]
              at com.atlassian.stash.internal.scm.git.merge.TwoStepFetchStrategy.updateRef(TwoStepFetchStrategy.java:66) ~[na:na]
              at com.atlassian.stash.internal.scm.git.merge.CancelableTwoStepFetchStrategy.updateRef(CancelableTwoStepFetchStrategy.java:71) ~[na:na]
              at com.atlassian.stash.internal.scm.git.merge.TwoStepFetchStrategy.fetch(TwoStepFetchStrategy.java:53) ~[na:na]
              at com.atlassian.stash.internal.scm.git.merge.TimedFetchStrategy.fetch(TimedFetchStrategy.java:30) ~[na:na]
              at com.atlassian.stash.internal.scm.git.merge.MergeCommand.doFetch(MergeCommand.java:71) ~[na:na]
              at com.atlassian.stash.internal.scm.git.merge.MergeCommand.doWithWorkTree(MergeCommand.java:97) ~[na:na]
              ... 23 common frames omitted

              Unassigned Unassigned
              dlee@atlassian.com Deric Lee (Inactive)
              Votes:
              1 Vote for this issue
              Watchers:
              10 Start watching this issue

                Created:
                Updated:
                Resolved: