changeset 20467:ef880ced6d07

push: move `commonheads` into the push object The phase synchronisation start by computing the new set of common head between local and remote and then do the phase synchronisation on this set. This new common set logic will eventually be used by the obsolescence markers exchange. So we are going to split the long phase synchronisation in two.
author Pierre-Yves David <pierre-yves.david@logilab.fr>
date Thu, 30 Jan 2014 23:16:43 -0800
parents 233623d58c9a
children 7d0bbb6dd730
files mercurial/exchange.py
diffstat 1 files changed, 3 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/mercurial/exchange.py	Thu Jan 30 21:05:29 2014 -0800
+++ b/mercurial/exchange.py	Thu Jan 30 23:16:43 2014 -0800
@@ -48,6 +48,8 @@
         self.remoteheads = None
         # testable as a boolean indicating if any nodes are missing locally.
         self.incoming = None
+        # set of all heads common after changeset bundle push
+        self.commonheads = None
 
 def push(repo, remote, force=False, revs=None, newbranch=False):
     '''Push outgoing changesets (limited by revs) from a local
@@ -238,6 +240,7 @@
                          pushop.outgoing.commonheads,
                          pushop.outgoing.missing)
         cheads.extend(c.node() for c in revset)
+    pushop.commonheads = cheads
     # even when we don't push, exchanging phase data is useful
     remotephases = pushop.remote.listkeys('phases')
     if (pushop.ui.configbool('ui', '_usedassubrepo', False)