Comments
Patch
@@ -111,6 +111,8 @@
self.outdatedphases = None
# phases changes that must be pushed if changeset push fails
self.fallbackoutdatedphases = None
+ # phases returned from server in bundle2 response
+ self.remotephases = None
# outgoing obsmarkers
self.outobsmarkers = set()
# outgoing bookmarks
@@ -664,6 +666,9 @@
pushop.pkfailcb[partid](pushop, exc)
for rephand in replyhandlers:
rephand(op)
+ for namespace, value in op.records['listkeys']:
+ if namespace == 'phases':
+ pushop.remotephases = value
def _pushchangeset(pushop):
"""Make the actual push of changeset bundle to remote repo"""
@@ -718,7 +723,11 @@
"""synchronise phase information locally and remotely"""
cheads = pushop.commonheads
# even when we don't push, exchanging phase data is useful
- remotephases = pushop.remote.listkeys('phases')
+ if pushop.remotephases is not None:
+ # phase data received in bundle2 part reply
+ remotephases = pushop.remotephases
+ else:
+ remotephases = pushop.remote.listkeys('phases')
if (pushop.ui.configbool('ui', '_usedassubrepo', False)
and remotephases # server supports phases
and pushop.cgresult is None # nothing was pushed