Show More
@@ -775,6 +775,12 b' class unbundlepart(unpackermixin):' | |||
|
775 | 775 | self.consumed = True |
|
776 | 776 | return data |
|
777 | 777 | |
|
778 | capabilities = {'HG2X': (), | |
|
779 | 'b2x:listkeys': (), | |
|
780 | 'b2x:pushkey': (), | |
|
781 | 'b2x:changegroup': (), | |
|
782 | } | |
|
783 | ||
|
778 | 784 | def bundle2caps(remote): |
|
779 | 785 | """return the bundlecapabilities of a peer as dict""" |
|
780 | 786 | raw = remote.capable('bundle2-exp') |
@@ -465,7 +465,7 b' def _pushbundle2(pushop):' | |||
|
465 | 465 | evolve in the future.""" |
|
466 | 466 | bundler = bundle2.bundle20(pushop.ui, bundle2.bundle2caps(pushop.remote)) |
|
467 | 467 | # create reply capability |
|
468 |
capsblob = bundle2.encodecaps( |
|
|
468 | capsblob = bundle2.encodecaps(bundle2.capabilities) | |
|
469 | 469 | bundler.newpart('b2x:replycaps', data=capsblob) |
|
470 | 470 | replyhandlers = [] |
|
471 | 471 | for partgenname in b2partsgenorder: |
@@ -922,7 +922,7 b' def _pullobsolete(pullop):' | |||
|
922 | 922 | def caps20to10(repo): |
|
923 | 923 | """return a set with appropriate options to use bundle20 during getbundle""" |
|
924 | 924 | caps = set(['HG2X']) |
|
925 |
capsblob = bundle2.encodecaps( |
|
|
925 | capsblob = bundle2.encodecaps(bundle2.capabilities) | |
|
926 | 926 | caps.add('bundle2=' + urllib.quote(capsblob)) |
|
927 | 927 | return caps |
|
928 | 928 |
@@ -180,12 +180,6 b' class localrepository(object):' | |||
|
180 | 180 | requirements = ['revlogv1'] |
|
181 | 181 | filtername = None |
|
182 | 182 | |
|
183 | bundle2caps = {'HG2X': (), | |
|
184 | 'b2x:listkeys': (), | |
|
185 | 'b2x:pushkey': (), | |
|
186 | 'b2x:changegroup': (), | |
|
187 | } | |
|
188 | ||
|
189 | 183 | # a list of (ui, featureset) functions. |
|
190 | 184 | # only functions defined in module of enabled extensions are invoked |
|
191 | 185 | featuresetupfuncs = set() |
@@ -311,7 +305,7 b' class localrepository(object):' | |||
|
311 | 305 | # required by the tests (or some brave tester) |
|
312 | 306 | if self.ui.configbool('experimental', 'bundle2-exp', False): |
|
313 | 307 | caps = set(caps) |
|
314 |
capsblob = bundle2.encodecaps( |
|
|
308 | capsblob = bundle2.encodecaps(bundle2.capabilities) | |
|
315 | 309 | caps.add('bundle2-exp=' + urllib.quote(capsblob)) |
|
316 | 310 | return caps |
|
317 | 311 |
@@ -609,7 +609,7 b' def _capabilities(repo, proto):' | |||
|
609 | 609 | else: |
|
610 | 610 | caps.append('streamreqs=%s' % ','.join(requiredformats)) |
|
611 | 611 | if repo.ui.configbool('experimental', 'bundle2-exp', False): |
|
612 |
capsblob = bundle2.encodecaps( |
|
|
612 | capsblob = bundle2.encodecaps(bundle2.capabilities) | |
|
613 | 613 | caps.append('bundle2-exp=' + urllib.quote(capsblob)) |
|
614 | 614 | caps.append('unbundle=%s' % ','.join(changegroupmod.bundlepriority)) |
|
615 | 615 | caps.append('httpheader=1024') |
General Comments 0
You need to be logged in to leave comments.
Login now