From patchwork Thu Oct 16 21:29:47 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: [2, of, 2, V2] bundle2: add a comment about addchangegroup source and url From: Pierre-Yves David X-Patchwork-Id: 6347 Message-Id: <25973c9b697f0220b642.1413494987@marginatus.alto.octopoid.net> To: mercurial-devel@selenic.com Cc: Pierre-Yves David Date: Thu, 16 Oct 2014 14:29:47 -0700 # HG changeset patch # User Pierre-Yves David # Date 1413275245 25200 # Tue Oct 14 01:27:25 2014 -0700 # Node ID 25973c9b697f0220b642747a5b8f68fe49fa24d5 # Parent cc7276a5a10ebf94ad1d742a6ad79a51ede6c6aa bundle2: add a comment about addchangegroup source and url diff --git a/mercurial/bundle2.py b/mercurial/bundle2.py --- a/mercurial/bundle2.py +++ b/mercurial/bundle2.py @@ -819,10 +819,12 @@ def handlechangegroup(op, inpart): # The addchangegroup function will get a transaction object by itself, but # we need to make sure we trigger the creation of a transaction object used # for the whole processing scope. op.gettransaction() cg = changegroup.cg1unpacker(inpart, 'UN') + # the source and url passed here are overwritten by the one contained in + # the transaction.hookargs argument. So 'bundle2' is a place holder ret = changegroup.addchangegroup(op.repo, cg, 'bundle2', 'bundle2') op.records.add('changegroup', {'return': ret}) if op.reply is not None: # This is definitly not the final form of this # return. But one need to start somewhere.