##// END OF EJS Templates
wireproto: provide accessors for client capabilities...
Joerg Sonnenberger -
r37411:afcfdf53 default
parent child Browse files
Show More
@@ -451,6 +451,10 b' response.'
451 451
452 452 The server terminates if it receives an empty command (a ``\n`` character).
453 453
454 If the server announces support for the ``protocaps`` capability, the client
455 should issue a ``protocaps`` command after the initial handshake to annonunce
456 its own capabilities. The client capabilities are persistent.
457
454 458 SSH Version 2 Transport
455 459 -----------------------
456 460
@@ -1121,6 +1125,13 b' 2006).'
1121 1125 This capability was introduced at the same time as the ``changegroupsubset``
1122 1126 capability/command.
1123 1127
1128 protocaps
1129 ---------
1130
1131 Whether the server supports the ``protocaps`` command for SSH V1 transport.
1132
1133 This capability was introduced in Mercurial 4.6.
1134
1124 1135 pushkey
1125 1136 -------
1126 1137
@@ -1530,6 +1541,16 b' will be present at byte offset N.'
1530 1541
1531 1542 There is no trailing newline.
1532 1543
1544 protocaps
1545 ---------
1546
1547 Notify the server about the client capabilities in the SSH V1 transport
1548 protocol.
1549
1550 The ``caps`` argument is a space-delimited list of capabilities.
1551
1552 The server will reply with the string ``OK``.
1553
1533 1554 pushkey
1534 1555 -------
1535 1556
@@ -163,6 +163,17 b' def _makeconnection(ui, sshcmd, args, re'
163 163
164 164 return proc, stdin, stdout, stderr
165 165
166 def _clientcapabilities():
167 """Return list of capabilities of this client.
168
169 Returns a list of capabilities that are supported by this client.
170 """
171 protoparams = []
172 comps = [e.wireprotosupport().name for e in
173 util.compengines.supportedwireengines(util.CLIENTROLE)]
174 protoparams.append('comp=%s' % ','.join(comps))
175 return protoparams
176
166 177 def _performhandshake(ui, stdin, stdout, stderr):
167 178 def badresponse():
168 179 # Flush any output on stderr.
@@ -609,4 +620,15 b' def instance(ui, path, create):'
609 620 proc, stdin, stdout, stderr = _makeconnection(ui, sshcmd, args, remotecmd,
610 621 remotepath, sshenv)
611 622
612 return makepeer(ui, path, proc, stdin, stdout, stderr)
623 peer = makepeer(ui, path, proc, stdin, stdout, stderr)
624
625 # Finally, if supported by the server, notify it about our own
626 # capabilities.
627 if 'protocaps' in peer.capabilities():
628 try:
629 peer._call("protocaps", caps=' '.join(_clientcapabilities()))
630 except IOError:
631 peer._cleanup()
632 raise error.RepoError(_('capability exchange failed'))
633
634 return peer
@@ -159,6 +159,18 b' def encodebatchcmds(req):'
159 159
160 160 return ';'.join(cmds)
161 161
162 def clientcompressionsupport(proto):
163 """Returns a list of compression methods supported by the client.
164
165 Returns a list of the compression methods supported by the client
166 according to the protocol capabilities. If no such capability has
167 been announced, fallback to the default of zlib and uncompressed.
168 """
169 for cap in proto.getprotocaps():
170 if cap.startswith('comp='):
171 return cap[5:].split(',')
172 return ['zlib', 'none']
173
162 174 # mapping of options accepted by getbundle and their types
163 175 #
164 176 # Meant to be extended by extensions. It is extensions responsibility to ensure
@@ -1027,6 +1039,13 b' def known(repo, proto, nodes, others):'
1027 1039 v = ''.join(b and '1' or '0' for b in repo.known(decodelist(nodes)))
1028 1040 return wireprototypes.bytesresponse(v)
1029 1041
1042 @wireprotocommand('protocaps', 'caps', permission='pull',
1043 transportpolicy=POLICY_V1_ONLY)
1044 def protocaps(repo, proto, caps):
1045 if proto.name == wireprototypes.SSHV1:
1046 proto._protocaps = set(caps.split(' '))
1047 return wireprototypes.bytesresponse('OK')
1048
1030 1049 @wireprotocommand('pushkey', 'namespace key old new', permission='push')
1031 1050 def pushkey(repo, proto, namespace, key, old, new):
1032 1051 # compatibility with pre-1.8 clients which were accidentally
@@ -67,6 +67,7 b' class httpv1protocolhandler(object):'
67 67 self._req = req
68 68 self._ui = ui
69 69 self._checkperm = checkperm
70 self._protocaps = None
70 71
71 72 @property
72 73 def name(self):
@@ -99,6 +100,12 b' class httpv1protocolhandler(object):'
99 100 args.update(urlreq.parseqs(argvalue, keep_blank_values=True))
100 101 return args
101 102
103 def getprotocaps(self):
104 if self._protocaps is None:
105 value = decodevaluefromheaders(self._req, r'X-HgProto')
106 self._protocaps = set(value.split(' '))
107 return self._protocaps
108
102 109 def forwardpayload(self, fp):
103 110 # Existing clients *always* send Content-Length.
104 111 length = int(self._req.headers[b'Content-Length'])
@@ -599,6 +606,10 b' class httpv2protocolhandler(object):'
599 606
600 607 return [data[k] for k in args.split()]
601 608
609 def getprotocaps(self):
610 # Protocol capabilities are currently not implemented for HTTP V2.
611 return set()
612
602 613 def forwardpayload(self, fp):
603 614 raise NotImplementedError
604 615
@@ -615,28 +626,21 b' class httpv2protocolhandler(object):'
615 626 def checkperm(self, perm):
616 627 raise NotImplementedError
617 628
618 def _httpresponsetype(ui, req, prefer_uncompressed):
629 def _httpresponsetype(ui, proto, prefer_uncompressed):
619 630 """Determine the appropriate response type and compression settings.
620 631
621 632 Returns a tuple of (mediatype, compengine, engineopts).
622 633 """
623 634 # Determine the response media type and compression engine based
624 635 # on the request parameters.
625 protocaps = decodevaluefromheaders(req, 'X-HgProto').split(' ')
626 636
627 if '0.2' in protocaps:
637 if '0.2' in proto.getprotocaps():
628 638 # All clients are expected to support uncompressed data.
629 639 if prefer_uncompressed:
630 640 return HGTYPE2, util._noopengine(), {}
631 641
632 # Default as defined by wire protocol spec.
633 compformats = ['zlib', 'none']
634 for cap in protocaps:
635 if cap.startswith('comp='):
636 compformats = cap[5:].split(',')
637 break
638
639 642 # Now find an agreed upon compression format.
643 compformats = wireproto.clientcompressionsupport(proto)
640 644 for engine in wireproto.supportedcompengines(ui, util.SERVERROLE):
641 645 if engine.wireprotosupport().name in compformats:
642 646 opts = {}
@@ -705,7 +709,7 b' def _callhttp(repo, req, res, proto, cmd'
705 709 # This code for compression should not be streamres specific. It
706 710 # is here because we only compress streamres at the moment.
707 711 mediatype, engine, engineopts = _httpresponsetype(
708 repo.ui, req, rsp.prefer_uncompressed)
712 repo.ui, proto, rsp.prefer_uncompressed)
709 713 gen = engine.compressstream(gen, engineopts)
710 714
711 715 if mediatype == HGTYPE2:
@@ -749,6 +753,7 b' class sshv1protocolhandler(object):'
749 753 self._ui = ui
750 754 self._fin = fin
751 755 self._fout = fout
756 self._protocaps = set()
752 757
753 758 @property
754 759 def name(self):
@@ -775,6 +780,9 b' class sshv1protocolhandler(object):'
775 780 data[arg] = val
776 781 return [data[k] for k in keys]
777 782
783 def getprotocaps(self):
784 return self._protocaps
785
778 786 def forwardpayload(self, fpout):
779 787 # We initially send an empty response. This tells the client it is
780 788 # OK to start sending data. If a client sees any other response, it
@@ -800,6 +808,8 b' class sshv1protocolhandler(object):'
800 808 return 'remote:ssh:' + client
801 809
802 810 def addcapabilities(self, repo, caps):
811 if self.name == wireprototypes.SSHV1:
812 caps.append(b'protocaps')
803 813 caps.append(b'batch')
804 814 return caps
805 815
@@ -117,6 +117,12 b' class baseprotocolhandler(zi.Interface):'
117 117
118 118 returns a list of values (same order as <args>)"""
119 119
120 def getprotocaps():
121 """Returns the list of protocol-level capabilities of client
122
123 Returns a list of capabilities as declared by the client for
124 the current request (or connection for stateful protocol handlers)."""
125
120 126 def forwardpayload(fp):
121 127 """Read the raw payload and forward to a file.
122 128
@@ -407,9 +407,12 b' Test debugpeer'
407 407 devel-peer-request: between
408 408 devel-peer-request: pairs: 81 bytes
409 409 sending between command
410 remote: 403
411 remote: capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch
410 remote: 413
411 remote: capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch
412 412 remote: 1
413 devel-peer-request: protocaps
414 devel-peer-request: caps: * bytes (glob)
415 sending protocaps command
413 416 url: ssh://user@dummy/debugrevlog
414 417 local: no
415 418 pushable: yes
@@ -480,10 +480,11 b' debug output'
480 480 sending upgrade request: * proto=exp-ssh-v2-0001 (glob) (sshv2 !)
481 481 sending hello command
482 482 sending between command
483 remote: 403 (sshv1 !)
483 remote: 413 (sshv1 !)
484 484 protocol upgraded to exp-ssh-v2-0001 (sshv2 !)
485 remote: capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch
485 remote: capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch
486 486 remote: 1 (sshv1 !)
487 sending protocaps command
487 488 preparing listkeys for "bookmarks"
488 489 sending listkeys command
489 490 received listkey for "bookmarks": 45 bytes
@@ -56,9 +56,9 b' Test pushing bundle1 payload to a server'
56 56 i> 0000000000000000000000000000000000000000-0000000000000000000000000000000000000000
57 57 i> flush() -> None
58 58 o> readline() -> 4:
59 o> 403\n
60 o> readline() -> 403:
61 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch\n
59 o> 413\n
60 o> readline() -> 413:
61 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch\n
62 62 o> readline() -> 2:
63 63 o> 1\n
64 64 o> readline() -> 1:
@@ -110,8 +110,8 b' Test pushing bundle1 payload to a server'
110 110 o> readline() -> 62:
111 111 o> upgraded * exp-ssh-v2-0001\n (glob)
112 112 o> readline() -> 4:
113 o> 402\n
114 o> read(402) -> 402: capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch
113 o> 412\n
114 o> read(412) -> 412: capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch
115 115 o> read(1) -> 1:
116 116 o> \n
117 117 sending unbundle command
@@ -225,9 +225,9 b' ui.write() in hook is redirected to stde'
225 225 i> 0000000000000000000000000000000000000000-0000000000000000000000000000000000000000
226 226 i> flush() -> None
227 227 o> readline() -> 4:
228 o> 403\n
229 o> readline() -> 403:
230 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch\n
228 o> 413\n
229 o> readline() -> 413:
230 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch\n
231 231 o> readline() -> 2:
232 232 o> 1\n
233 233 o> readline() -> 1:
@@ -285,8 +285,8 b' ui.write() in hook is redirected to stde'
285 285 o> readline() -> 62:
286 286 o> upgraded * exp-ssh-v2-0001\n (glob)
287 287 o> readline() -> 4:
288 o> 402\n
289 o> read(402) -> 402: capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch
288 o> 412\n
289 o> read(412) -> 412: capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch
290 290 o> read(1) -> 1:
291 291 o> \n
292 292 sending unbundle command
@@ -353,9 +353,9 b' And a variation that writes multiple lin'
353 353 i> 0000000000000000000000000000000000000000-0000000000000000000000000000000000000000
354 354 i> flush() -> None
355 355 o> readline() -> 4:
356 o> 403\n
357 o> readline() -> 403:
358 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch\n
356 o> 413\n
357 o> readline() -> 413:
358 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch\n
359 359 o> readline() -> 2:
360 360 o> 1\n
361 361 o> readline() -> 1:
@@ -414,8 +414,8 b' And a variation that writes multiple lin'
414 414 o> readline() -> 62:
415 415 o> upgraded * exp-ssh-v2-0001\n (glob)
416 416 o> readline() -> 4:
417 o> 402\n
418 o> read(402) -> 402: capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch
417 o> 412\n
418 o> read(412) -> 412: capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch
419 419 o> read(1) -> 1:
420 420 o> \n
421 421 sending unbundle command
@@ -483,9 +483,9 b' And a variation that does a ui.flush() a'
483 483 i> 0000000000000000000000000000000000000000-0000000000000000000000000000000000000000
484 484 i> flush() -> None
485 485 o> readline() -> 4:
486 o> 403\n
487 o> readline() -> 403:
488 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch\n
486 o> 413\n
487 o> readline() -> 413:
488 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch\n
489 489 o> readline() -> 2:
490 490 o> 1\n
491 491 o> readline() -> 1:
@@ -543,8 +543,8 b' And a variation that does a ui.flush() a'
543 543 o> readline() -> 62:
544 544 o> upgraded * exp-ssh-v2-0001\n (glob)
545 545 o> readline() -> 4:
546 o> 402\n
547 o> read(402) -> 402: capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch
546 o> 412\n
547 o> read(412) -> 412: capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch
548 548 o> read(1) -> 1:
549 549 o> \n
550 550 sending unbundle command
@@ -611,9 +611,9 b' Multiple writes + flush'
611 611 i> 0000000000000000000000000000000000000000-0000000000000000000000000000000000000000
612 612 i> flush() -> None
613 613 o> readline() -> 4:
614 o> 403\n
615 o> readline() -> 403:
616 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch\n
614 o> 413\n
615 o> readline() -> 413:
616 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch\n
617 617 o> readline() -> 2:
618 618 o> 1\n
619 619 o> readline() -> 1:
@@ -672,8 +672,8 b' Multiple writes + flush'
672 672 o> readline() -> 62:
673 673 o> upgraded * exp-ssh-v2-0001\n (glob)
674 674 o> readline() -> 4:
675 o> 402\n
676 o> read(402) -> 402: capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch
675 o> 412\n
676 o> read(412) -> 412: capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch
677 677 o> read(1) -> 1:
678 678 o> \n
679 679 sending unbundle command
@@ -741,9 +741,9 b' ui.write() + ui.write_err() output is ca'
741 741 i> 0000000000000000000000000000000000000000-0000000000000000000000000000000000000000
742 742 i> flush() -> None
743 743 o> readline() -> 4:
744 o> 403\n
745 o> readline() -> 403:
746 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch\n
744 o> 413\n
745 o> readline() -> 413:
746 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch\n
747 747 o> readline() -> 2:
748 748 o> 1\n
749 749 o> readline() -> 1:
@@ -804,8 +804,8 b' ui.write() + ui.write_err() output is ca'
804 804 o> readline() -> 62:
805 805 o> upgraded * exp-ssh-v2-0001\n (glob)
806 806 o> readline() -> 4:
807 o> 402\n
808 o> read(402) -> 402: capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch
807 o> 412\n
808 o> read(412) -> 412: capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch
809 809 o> read(1) -> 1:
810 810 o> \n
811 811 sending unbundle command
@@ -875,9 +875,9 b' print() output is captured'
875 875 i> 0000000000000000000000000000000000000000-0000000000000000000000000000000000000000
876 876 i> flush() -> None
877 877 o> readline() -> 4:
878 o> 403\n
879 o> readline() -> 403:
880 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch\n
878 o> 413\n
879 o> readline() -> 413:
880 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch\n
881 881 o> readline() -> 2:
882 882 o> 1\n
883 883 o> readline() -> 1:
@@ -935,8 +935,8 b' print() output is captured'
935 935 o> readline() -> 62:
936 936 o> upgraded * exp-ssh-v2-0001\n (glob)
937 937 o> readline() -> 4:
938 o> 402\n
939 o> read(402) -> 402: capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch
938 o> 412\n
939 o> read(412) -> 412: capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch
940 940 o> read(1) -> 1:
941 941 o> \n
942 942 sending unbundle command
@@ -1003,9 +1003,9 b' Mixed print() and ui.write() are both ca'
1003 1003 i> 0000000000000000000000000000000000000000-0000000000000000000000000000000000000000
1004 1004 i> flush() -> None
1005 1005 o> readline() -> 4:
1006 o> 403\n
1007 o> readline() -> 403:
1008 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch\n
1006 o> 413\n
1007 o> readline() -> 413:
1008 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch\n
1009 1009 o> readline() -> 2:
1010 1010 o> 1\n
1011 1011 o> readline() -> 1:
@@ -1066,8 +1066,8 b' Mixed print() and ui.write() are both ca'
1066 1066 o> readline() -> 62:
1067 1067 o> upgraded * exp-ssh-v2-0001\n (glob)
1068 1068 o> readline() -> 4:
1069 o> 402\n
1070 o> read(402) -> 402: capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch
1069 o> 412\n
1070 o> read(412) -> 412: capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch
1071 1071 o> read(1) -> 1:
1072 1072 o> \n
1073 1073 sending unbundle command
@@ -1137,9 +1137,9 b' print() to stdout and stderr both get ca'
1137 1137 i> 0000000000000000000000000000000000000000-0000000000000000000000000000000000000000
1138 1138 i> flush() -> None
1139 1139 o> readline() -> 4:
1140 o> 403\n
1141 o> readline() -> 403:
1142 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch\n
1140 o> 413\n
1141 o> readline() -> 413:
1142 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch\n
1143 1143 o> readline() -> 2:
1144 1144 o> 1\n
1145 1145 o> readline() -> 1:
@@ -1200,8 +1200,8 b' print() to stdout and stderr both get ca'
1200 1200 o> readline() -> 62:
1201 1201 o> upgraded * exp-ssh-v2-0001\n (glob)
1202 1202 o> readline() -> 4:
1203 o> 402\n
1204 o> read(402) -> 402: capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch
1203 o> 412\n
1204 o> read(412) -> 412: capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch
1205 1205 o> read(1) -> 1:
1206 1206 o> \n
1207 1207 sending unbundle command
@@ -1277,9 +1277,9 b' Shell hook writing to stdout has output '
1277 1277 i> 0000000000000000000000000000000000000000-0000000000000000000000000000000000000000
1278 1278 i> flush() -> None
1279 1279 o> readline() -> 4:
1280 o> 403\n
1281 o> readline() -> 403:
1282 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch\n
1280 o> 413\n
1281 o> readline() -> 413:
1282 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch\n
1283 1283 o> readline() -> 2:
1284 1284 o> 1\n
1285 1285 o> readline() -> 1:
@@ -1338,8 +1338,8 b' Shell hook writing to stdout has output '
1338 1338 o> readline() -> 62:
1339 1339 o> upgraded * exp-ssh-v2-0001\n (glob)
1340 1340 o> readline() -> 4:
1341 o> 402\n
1342 o> read(402) -> 402: capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch
1341 o> 412\n
1342 o> read(412) -> 412: capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch
1343 1343 o> read(1) -> 1:
1344 1344 o> \n
1345 1345 sending unbundle command
@@ -1408,9 +1408,9 b' Shell hook writing to stderr has output '
1408 1408 i> 0000000000000000000000000000000000000000-0000000000000000000000000000000000000000
1409 1409 i> flush() -> None
1410 1410 o> readline() -> 4:
1411 o> 403\n
1412 o> readline() -> 403:
1413 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch\n
1411 o> 413\n
1412 o> readline() -> 413:
1413 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch\n
1414 1414 o> readline() -> 2:
1415 1415 o> 1\n
1416 1416 o> readline() -> 1:
@@ -1469,8 +1469,8 b' Shell hook writing to stderr has output '
1469 1469 o> readline() -> 62:
1470 1470 o> upgraded * exp-ssh-v2-0001\n (glob)
1471 1471 o> readline() -> 4:
1472 o> 402\n
1473 o> read(402) -> 402: capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch
1472 o> 412\n
1473 o> read(412) -> 412: capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch
1474 1474 o> read(1) -> 1:
1475 1475 o> \n
1476 1476 sending unbundle command
@@ -1541,9 +1541,9 b' Shell hook writing to stdout and stderr '
1541 1541 i> 0000000000000000000000000000000000000000-0000000000000000000000000000000000000000
1542 1542 i> flush() -> None
1543 1543 o> readline() -> 4:
1544 o> 403\n
1545 o> readline() -> 403:
1546 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch\n
1544 o> 413\n
1545 o> readline() -> 413:
1546 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch\n
1547 1547 o> readline() -> 2:
1548 1548 o> 1\n
1549 1549 o> readline() -> 1:
@@ -1604,8 +1604,8 b' Shell hook writing to stdout and stderr '
1604 1604 o> readline() -> 62:
1605 1605 o> upgraded * exp-ssh-v2-0001\n (glob)
1606 1606 o> readline() -> 4:
1607 o> 402\n
1608 o> read(402) -> 402: capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch
1607 o> 412\n
1608 o> read(412) -> 412: capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch
1609 1609 o> read(1) -> 1:
1610 1610 o> \n
1611 1611 sending unbundle command
@@ -1684,9 +1684,9 b' Shell and Python hooks writing to stdout'
1684 1684 i> 0000000000000000000000000000000000000000-0000000000000000000000000000000000000000
1685 1685 i> flush() -> None
1686 1686 o> readline() -> 4:
1687 o> 403\n
1688 o> readline() -> 403:
1689 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch\n
1687 o> 413\n
1688 o> readline() -> 413:
1689 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch\n
1690 1690 o> readline() -> 2:
1691 1691 o> 1\n
1692 1692 o> readline() -> 1:
@@ -1751,8 +1751,8 b' Shell and Python hooks writing to stdout'
1751 1751 o> readline() -> 62:
1752 1752 o> upgraded * exp-ssh-v2-0001\n (glob)
1753 1753 o> readline() -> 4:
1754 o> 402\n
1755 o> read(402) -> 402: capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch
1754 o> 412\n
1755 o> read(412) -> 412: capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch
1756 1756 o> read(1) -> 1:
1757 1757 o> \n
1758 1758 sending unbundle command
@@ -1826,9 +1826,9 b' Pushing a bundle1 with no output'
1826 1826 i> 0000000000000000000000000000000000000000-0000000000000000000000000000000000000000
1827 1827 i> flush() -> None
1828 1828 o> readline() -> 4:
1829 o> 403\n
1830 o> readline() -> 403:
1831 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch\n
1829 o> 413\n
1830 o> readline() -> 413:
1831 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch\n
1832 1832 o> readline() -> 2:
1833 1833 o> 1\n
1834 1834 o> readline() -> 1:
@@ -1882,8 +1882,8 b' Pushing a bundle1 with no output'
1882 1882 o> readline() -> 62:
1883 1883 o> upgraded * exp-ssh-v2-0001\n (glob)
1884 1884 o> readline() -> 4:
1885 o> 402\n
1886 o> read(402) -> 402: capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch
1885 o> 412\n
1886 o> read(412) -> 412: capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch
1887 1887 o> read(1) -> 1:
1888 1888 o> \n
1889 1889 sending unbundle command
@@ -1958,9 +1958,9 b' Pushing a bundle1 with ui.write() and ui'
1958 1958 i> 0000000000000000000000000000000000000000-0000000000000000000000000000000000000000
1959 1959 i> flush() -> None
1960 1960 o> readline() -> 4:
1961 o> 403\n
1962 o> readline() -> 403:
1963 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch\n
1961 o> 413\n
1962 o> readline() -> 413:
1963 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch\n
1964 1964 o> readline() -> 2:
1965 1965 o> 1\n
1966 1966 o> readline() -> 1:
@@ -2018,8 +2018,8 b' Pushing a bundle1 with ui.write() and ui'
2018 2018 o> readline() -> 62:
2019 2019 o> upgraded * exp-ssh-v2-0001\n (glob)
2020 2020 o> readline() -> 4:
2021 o> 402\n
2022 o> read(402) -> 402: capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch
2021 o> 412\n
2022 o> read(412) -> 412: capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch
2023 2023 o> read(1) -> 1:
2024 2024 o> \n
2025 2025 sending unbundle command
@@ -63,9 +63,12 b' Test a normal behaving server, for sanit'
63 63 devel-peer-request: between
64 64 devel-peer-request: pairs: 81 bytes
65 65 sending between command
66 remote: 403
67 remote: capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch
66 remote: 413
67 remote: capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch
68 68 remote: 1
69 devel-peer-request: protocaps
70 devel-peer-request: caps: * bytes (glob)
71 sending protocaps command
69 72 url: ssh://user@dummy/server
70 73 local: no
71 74 pushable: yes
@@ -82,9 +85,9 b' Server should answer the "hello" command'
82 85 i> write(6) -> 6:
83 86 i> hello\n
84 87 o> readline() -> 4:
85 o> 403\n
86 o> readline() -> 403:
87 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch\n
88 o> 413\n
89 o> readline() -> 413:
90 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch\n
88 91
89 92 `hg debugserve --sshstdio` works
90 93
@@ -92,8 +95,8 b' Server should answer the "hello" command'
92 95 $ hg debugserve --sshstdio << EOF
93 96 > hello
94 97 > EOF
95 403
96 capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch
98 413
99 capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch
97 100
98 101 I/O logging works
99 102
@@ -101,24 +104,24 b' I/O logging works'
101 104 > hello
102 105 > EOF
103 106 o> write(4) -> 4:
104 o> 403\n
105 o> write(403) -> 403:
106 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch\n
107 403
108 capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch
107 o> 413\n
108 o> write(413) -> 413:
109 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch\n
110 413
111 capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch
109 112 o> flush() -> None
110 113
111 114 $ hg debugserve --sshstdio --logiofile $TESTTMP/io << EOF
112 115 > hello
113 116 > EOF
114 403
115 capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch
117 413
118 capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch
116 119
117 120 $ cat $TESTTMP/io
118 121 o> write(4) -> 4:
119 o> 403\n
120 o> write(403) -> 403:
121 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch\n
122 o> 413\n
123 o> write(413) -> 413:
124 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch\n
122 125 o> flush() -> None
123 126
124 127 $ cd ..
@@ -143,9 +146,9 b' reply with empty response to the "betwee'
143 146 i> write(6) -> 6:
144 147 i> hello\n
145 148 o> readline() -> 4:
146 o> 403\n
147 o> readline() -> 403:
148 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch\n
149 o> 413\n
150 o> readline() -> 413:
151 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch\n
149 152 i> write(98) -> 98:
150 153 i> between\n
151 154 i> pairs 81\n
@@ -182,9 +185,12 b' SSH banner is not printed by default, ig'
182 185 remote: banner: line 7
183 186 remote: banner: line 8
184 187 remote: banner: line 9
185 remote: 403
186 remote: capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch
188 remote: 413
189 remote: capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch
187 190 remote: 1
191 devel-peer-request: protocaps
192 devel-peer-request: caps: * bytes (glob)
193 sending protocaps command
188 194 url: ssh://user@dummy/server
189 195 local: no
190 196 pushable: yes
@@ -237,9 +243,9 b' And test the banner with the raw protoco'
237 243 o> readline() -> 15:
238 244 o> banner: line 9\n
239 245 o> readline() -> 4:
240 o> 403\n
241 o> readline() -> 403:
242 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch\n
246 o> 413\n
247 o> readline() -> 413:
248 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch\n
243 249 i> write(98) -> 98:
244 250 i> between\n
245 251 i> pairs 81\n
@@ -290,13 +296,13 b' Sending an unknown command to the server'
290 296 i> write(6) -> 6:
291 297 i> hello\n
292 298 o> readline() -> 4:
293 o> 403\n
299 o> 413\n
294 300 i> write(98) -> 98:
295 301 i> between\n
296 302 i> pairs 81\n
297 303 i> 0000000000000000000000000000000000000000-0000000000000000000000000000000000000000
298 o> readline() -> 403:
299 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch\n
304 o> readline() -> 413:
305 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch\n
300 306 o> readline() -> 2:
301 307 o> 1\n
302 308
@@ -310,9 +316,12 b' Sending an unknown command to the server'
310 316 devel-peer-request: pairs: 81 bytes
311 317 sending between command
312 318 remote: 0
313 remote: 403
314 remote: capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch
319 remote: 413
320 remote: capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch
315 321 remote: 1
322 devel-peer-request: protocaps
323 devel-peer-request: caps: * bytes (glob)
324 sending protocaps command
316 325 url: ssh://user@dummy/server
317 326 local: no
318 327 pushable: yes
@@ -356,9 +365,9 b' Send multiple unknown commands before he'
356 365 i> write(6) -> 6:
357 366 i> hello\n
358 367 o> readline() -> 4:
359 o> 403\n
360 o> readline() -> 403:
361 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch\n
368 o> 413\n
369 o> readline() -> 413:
370 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch\n
362 371 i> write(98) -> 98:
363 372 i> between\n
364 373 i> pairs 81\n
@@ -382,9 +391,12 b' Send multiple unknown commands before he'
382 391 remote: 0
383 392 remote: 0
384 393 remote: 0
385 remote: 403
386 remote: capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch
394 remote: 413
395 remote: capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch
387 396 remote: 1
397 devel-peer-request: protocaps
398 devel-peer-request: caps: * bytes (glob)
399 sending protocaps command
388 400 url: ssh://user@dummy/server
389 401 local: no
390 402 pushable: yes
@@ -436,9 +448,9 b' Send an unknown command before hello tha'
436 448 i> write(6) -> 6:
437 449 i> hello\n
438 450 o> readline() -> 4:
439 o> 403\n
440 o> readline() -> 403:
441 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch\n
451 o> 413\n
452 o> readline() -> 413:
453 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch\n
442 454 i> write(98) -> 98:
443 455 i> between\n
444 456 i> pairs 81\n
@@ -483,9 +495,9 b' Send an unknown command having an argume'
483 495 i> write(6) -> 6:
484 496 i> hello\n
485 497 o> readline() -> 4:
486 o> 403\n
487 o> readline() -> 403:
488 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch\n
498 o> 413\n
499 o> readline() -> 413:
500 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch\n
489 501 i> write(98) -> 98:
490 502 i> between\n
491 503 i> pairs 81\n
@@ -528,9 +540,9 b' Send an unknown command having an argume'
528 540 i> write(6) -> 6:
529 541 i> hello\n
530 542 o> readline() -> 4:
531 o> 403\n
532 o> readline() -> 403:
533 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch\n
543 o> 413\n
544 o> readline() -> 413:
545 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch\n
534 546 i> write(98) -> 98:
535 547 i> between\n
536 548 i> pairs 81\n
@@ -598,9 +610,9 b' Dictionary value for unknown command'
598 610 i> write(6) -> 6:
599 611 i> hello\n
600 612 o> readline() -> 4:
601 o> 403\n
602 o> readline() -> 403:
603 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch\n
613 o> 413\n
614 o> readline() -> 413:
615 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch\n
604 616
605 617 Incomplete dictionary send
606 618
@@ -680,9 +692,9 b' Send a command line with spaces'
680 692 i> write(6) -> 6:
681 693 i> hello\n
682 694 o> readline() -> 4:
683 o> 403\n
684 o> readline() -> 403:
685 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch\n
695 o> 413\n
696 o> readline() -> 413:
697 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch\n
686 698 i> write(98) -> 98:
687 699 i> between\n
688 700 i> pairs 81\n
@@ -714,9 +726,9 b' Send a command line with spaces'
714 726 i> write(6) -> 6:
715 727 i> hello\n
716 728 o> readline() -> 4:
717 o> 403\n
718 o> readline() -> 403:
719 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch\n
729 o> 413\n
730 o> readline() -> 413:
731 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch\n
720 732 i> write(98) -> 98:
721 733 i> between\n
722 734 i> pairs 81\n
@@ -757,9 +769,9 b' Send a command line with spaces'
757 769 i> write(6) -> 6:
758 770 i> hello\n
759 771 o> readline() -> 4:
760 o> 403\n
761 o> readline() -> 403:
762 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch\n
772 o> 413\n
773 o> readline() -> 413:
774 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch\n
763 775 i> write(98) -> 98:
764 776 i> between\n
765 777 i> pairs 81\n
@@ -786,9 +798,9 b' Send an unknown command after the "betwe'
786 798 i> write(6) -> 6:
787 799 i> hello\n
788 800 o> readline() -> 4:
789 o> 403\n
790 o> readline() -> 403:
791 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch\n
801 o> 413\n
802 o> readline() -> 413:
803 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch\n
792 804 i> write(105) -> 105:
793 805 i> between\n
794 806 i> pairs 81\n
@@ -827,9 +839,9 b' And one with arguments'
827 839 i> pairs 81\n
828 840 i> 0000000000000000000000000000000000000000-0000000000000000000000000000000000000000
829 841 o> readline() -> 4:
830 o> 403\n
831 o> readline() -> 403:
832 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch\n
842 o> 413\n
843 o> readline() -> 413:
844 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch\n
833 845 o> readline() -> 2:
834 846 o> 1\n
835 847 o> readline() -> 1:
@@ -876,9 +888,9 b' Send a valid command before the handshak'
876 888 o> readline() -> 41:
877 889 o> 68986213bd4485ea51533535e3fc9e78007a711f\n
878 890 o> readline() -> 4:
879 o> 403\n
880 o> readline() -> 403:
881 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch\n
891 o> 413\n
892 o> readline() -> 413:
893 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch\n
882 894 o> readline() -> 2:
883 895 o> 1\n
884 896
@@ -903,7 +915,7 b" And a variation that doesn't send the be"
903 915 o> readline() -> 41:
904 916 o> 68986213bd4485ea51533535e3fc9e78007a711f\n
905 917 o> readline() -> 4:
906 o> 403\n
918 o> 413\n
907 919
908 920 Send an upgrade request to a server that doesn't support that command
909 921
@@ -932,9 +944,9 b' Send an upgrade request to a server that'
932 944 i> pairs 81\n
933 945 i> 0000000000000000000000000000000000000000-0000000000000000000000000000000000000000
934 946 o> readline() -> 4:
935 o> 403\n
936 o> readline() -> 403:
937 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch\n
947 o> 413\n
948 o> readline() -> 413:
949 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch\n
938 950 o> readline() -> 2:
939 951 o> 1\n
940 952 o> readline() -> 1:
@@ -952,9 +964,12 b' Send an upgrade request to a server that'
952 964 devel-peer-request: pairs: 81 bytes
953 965 sending between command
954 966 remote: 0
955 remote: 403
956 remote: capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch
967 remote: 413
968 remote: capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch
957 969 remote: 1
970 devel-peer-request: protocaps
971 devel-peer-request: caps: * bytes (glob)
972 sending protocaps command
958 973 url: ssh://user@dummy/server
959 974 local: no
960 975 pushable: yes
@@ -992,9 +1007,9 b' Send an upgrade request to a server that'
992 1007 o> readline() -> 44:
993 1008 o> upgraded this-is-some-token exp-ssh-v2-0001\n
994 1009 o> readline() -> 4:
995 o> 402\n
996 o> readline() -> 403:
997 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch\n
1010 o> 412\n
1011 o> readline() -> 413:
1012 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch\n
998 1013
999 1014 $ cd ..
1000 1015
@@ -1008,7 +1023,10 b' Send an upgrade request to a server that'
1008 1023 devel-peer-request: pairs: 81 bytes
1009 1024 sending between command
1010 1025 protocol upgraded to exp-ssh-v2-0001
1011 remote: capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch
1026 remote: capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch
1027 devel-peer-request: protocaps
1028 devel-peer-request: caps: * bytes (glob)
1029 sending protocaps command
1012 1030 url: ssh://user@dummy/server
1013 1031 local: no
1014 1032 pushable: yes
@@ -1025,7 +1043,10 b' Verify the peer has capabilities'
1025 1043 devel-peer-request: pairs: 81 bytes
1026 1044 sending between command
1027 1045 protocol upgraded to exp-ssh-v2-0001
1028 remote: capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch
1046 remote: capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch
1047 devel-peer-request: protocaps
1048 devel-peer-request: caps: * bytes (glob)
1049 sending protocaps command
1029 1050 Main capabilities:
1030 1051 batch
1031 1052 branchmap
@@ -1034,6 +1055,7 b' Verify the peer has capabilities'
1034 1055 getbundle
1035 1056 known
1036 1057 lookup
1058 protocaps
1037 1059 pushkey
1038 1060 streamreqs=generaldelta,revlogv1
1039 1061 unbundle=HG10GZ,HG10BZ,HG10UN
@@ -1092,9 +1114,9 b' Command after upgrade to version 2 is pr'
1092 1114 o> readline() -> 44:
1093 1115 o> upgraded this-is-some-token exp-ssh-v2-0001\n
1094 1116 o> readline() -> 4:
1095 o> 402\n
1096 o> readline() -> 403:
1097 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch\n
1117 o> 412\n
1118 o> readline() -> 413:
1119 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch\n
1098 1120 i> write(6) -> 6:
1099 1121 i> hello\n
1100 1122 o> readline() -> 4:
@@ -1130,9 +1152,9 b' Multiple upgrades is not allowed'
1130 1152 o> readline() -> 44:
1131 1153 o> upgraded this-is-some-token exp-ssh-v2-0001\n
1132 1154 o> readline() -> 4:
1133 o> 402\n
1134 o> readline() -> 403:
1135 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch\n
1155 o> 412\n
1156 o> readline() -> 413:
1157 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch\n
1136 1158 i> write(45) -> 45:
1137 1159 i> upgrade another-token proto=irrelevant\n
1138 1160 i> hello\n
@@ -1203,9 +1225,9 b' Upgrade request to unsupported protocol '
1203 1225 i> write(6) -> 6:
1204 1226 i> hello\n
1205 1227 o> readline() -> 4:
1206 o> 403\n
1207 o> readline() -> 403:
1208 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch\n
1228 o> 413\n
1229 o> readline() -> 413:
1230 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch\n
1209 1231 i> write(98) -> 98:
1210 1232 i> between\n
1211 1233 i> pairs 81\n
@@ -1325,9 +1347,9 b' Test listkeys for listing namespaces'
1325 1347 i> 0000000000000000000000000000000000000000-0000000000000000000000000000000000000000
1326 1348 i> flush() -> None
1327 1349 o> readline() -> 4:
1328 o> 403\n
1329 o> readline() -> 403:
1330 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch\n
1350 o> 413\n
1351 o> readline() -> 413:
1352 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch\n
1331 1353 o> readline() -> 2:
1332 1354 o> 1\n
1333 1355 o> readline() -> 1:
@@ -1359,8 +1381,8 b' Test listkeys for listing namespaces'
1359 1381 o> readline() -> 62:
1360 1382 o> upgraded * exp-ssh-v2-0001\n (glob)
1361 1383 o> readline() -> 4:
1362 o> 402\n
1363 o> read(402) -> 402: capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch
1384 o> 412\n
1385 o> read(412) -> 412: capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch
1364 1386 o> read(1) -> 1:
1365 1387 o> \n
1366 1388 sending listkeys command
@@ -1405,9 +1427,9 b' With no bookmarks set'
1405 1427 i> 0000000000000000000000000000000000000000-0000000000000000000000000000000000000000
1406 1428 i> flush() -> None
1407 1429 o> readline() -> 4:
1408 o> 403\n
1409 o> readline() -> 403:
1410 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch\n
1430 o> 413\n
1431 o> readline() -> 413:
1432 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch\n
1411 1433 o> readline() -> 2:
1412 1434 o> 1\n
1413 1435 o> readline() -> 1:
@@ -1435,8 +1457,8 b' With no bookmarks set'
1435 1457 o> readline() -> 62:
1436 1458 o> upgraded * exp-ssh-v2-0001\n (glob)
1437 1459 o> readline() -> 4:
1438 o> 402\n
1439 o> read(402) -> 402: capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch
1460 o> 412\n
1461 o> read(412) -> 412: capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch
1440 1462 o> read(1) -> 1:
1441 1463 o> \n
1442 1464 sending listkeys command
@@ -1466,9 +1488,9 b' With a single bookmark set'
1466 1488 i> 0000000000000000000000000000000000000000-0000000000000000000000000000000000000000
1467 1489 i> flush() -> None
1468 1490 o> readline() -> 4:
1469 o> 403\n
1470 o> readline() -> 403:
1471 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch\n
1491 o> 413\n
1492 o> readline() -> 413:
1493 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch\n
1472 1494 o> readline() -> 2:
1473 1495 o> 1\n
1474 1496 o> readline() -> 1:
@@ -1497,8 +1519,8 b' With a single bookmark set'
1497 1519 o> readline() -> 62:
1498 1520 o> upgraded * exp-ssh-v2-0001\n (glob)
1499 1521 o> readline() -> 4:
1500 o> 402\n
1501 o> read(402) -> 402: capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch
1522 o> 412\n
1523 o> read(412) -> 412: capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch
1502 1524 o> read(1) -> 1:
1503 1525 o> \n
1504 1526 sending listkeys command
@@ -1529,9 +1551,9 b' With multiple bookmarks set'
1529 1551 i> 0000000000000000000000000000000000000000-0000000000000000000000000000000000000000
1530 1552 i> flush() -> None
1531 1553 o> readline() -> 4:
1532 o> 403\n
1533 o> readline() -> 403:
1534 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch\n
1554 o> 413\n
1555 o> readline() -> 413:
1556 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch\n
1535 1557 o> readline() -> 2:
1536 1558 o> 1\n
1537 1559 o> readline() -> 1:
@@ -1562,8 +1584,8 b' With multiple bookmarks set'
1562 1584 o> readline() -> 62:
1563 1585 o> upgraded * exp-ssh-v2-0001\n (glob)
1564 1586 o> readline() -> 4:
1565 o> 402\n
1566 o> read(402) -> 402: capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch
1587 o> 412\n
1588 o> read(412) -> 412: capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch
1567 1589 o> read(1) -> 1:
1568 1590 o> \n
1569 1591 sending listkeys command
@@ -1598,9 +1620,9 b' Test pushkey for bookmarks'
1598 1620 i> 0000000000000000000000000000000000000000-0000000000000000000000000000000000000000
1599 1621 i> flush() -> None
1600 1622 o> readline() -> 4:
1601 o> 403\n
1602 o> readline() -> 403:
1603 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch\n
1623 o> 413\n
1624 o> readline() -> 413:
1625 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch\n
1604 1626 o> readline() -> 2:
1605 1627 o> 1\n
1606 1628 o> readline() -> 1:
@@ -1638,8 +1660,8 b' Test pushkey for bookmarks'
1638 1660 o> readline() -> 62:
1639 1661 o> upgraded * exp-ssh-v2-0001\n (glob)
1640 1662 o> readline() -> 4:
1641 o> 402\n
1642 o> read(402) -> 402: capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch
1663 o> 412\n
1664 o> read(412) -> 412: capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch
1643 1665 o> read(1) -> 1:
1644 1666 o> \n
1645 1667 sending pushkey command
@@ -1690,9 +1712,9 b' Phases on empty repo'
1690 1712 i> 0000000000000000000000000000000000000000-0000000000000000000000000000000000000000
1691 1713 i> flush() -> None
1692 1714 o> readline() -> 4:
1693 o> 403\n
1694 o> readline() -> 403:
1695 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch\n
1715 o> 413\n
1716 o> readline() -> 413:
1717 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch\n
1696 1718 o> readline() -> 2:
1697 1719 o> 1\n
1698 1720 o> readline() -> 1:
@@ -1721,8 +1743,8 b' Phases on empty repo'
1721 1743 o> readline() -> 62:
1722 1744 o> upgraded * exp-ssh-v2-0001\n (glob)
1723 1745 o> readline() -> 4:
1724 o> 402\n
1725 o> read(402) -> 402: capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch
1746 o> 412\n
1747 o> read(412) -> 412: capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch
1726 1748 o> read(1) -> 1:
1727 1749 o> \n
1728 1750 sending listkeys command
@@ -1769,9 +1791,9 b' Two draft heads'
1769 1791 i> 0000000000000000000000000000000000000000-0000000000000000000000000000000000000000
1770 1792 i> flush() -> None
1771 1793 o> readline() -> 4:
1772 o> 403\n
1773 o> readline() -> 403:
1774 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch\n
1794 o> 413\n
1795 o> readline() -> 413:
1796 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch\n
1775 1797 o> readline() -> 2:
1776 1798 o> 1\n
1777 1799 o> readline() -> 1:
@@ -1803,8 +1825,8 b' Two draft heads'
1803 1825 o> readline() -> 62:
1804 1826 o> upgraded * exp-ssh-v2-0001\n (glob)
1805 1827 o> readline() -> 4:
1806 o> 402\n
1807 o> read(402) -> 402: capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch
1828 o> 412\n
1829 o> read(412) -> 412: capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch
1808 1830 o> read(1) -> 1:
1809 1831 o> \n
1810 1832 sending listkeys command
@@ -1838,9 +1860,9 b' Single draft head'
1838 1860 i> 0000000000000000000000000000000000000000-0000000000000000000000000000000000000000
1839 1861 i> flush() -> None
1840 1862 o> readline() -> 4:
1841 o> 403\n
1842 o> readline() -> 403:
1843 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch\n
1863 o> 413\n
1864 o> readline() -> 413:
1865 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch\n
1844 1866 o> readline() -> 2:
1845 1867 o> 1\n
1846 1868 o> readline() -> 1:
@@ -1871,8 +1893,8 b' Single draft head'
1871 1893 o> readline() -> 62:
1872 1894 o> upgraded * exp-ssh-v2-0001\n (glob)
1873 1895 o> readline() -> 4:
1874 o> 402\n
1875 o> read(402) -> 402: capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch
1896 o> 412\n
1897 o> read(412) -> 412: capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch
1876 1898 o> read(1) -> 1:
1877 1899 o> \n
1878 1900 sending listkeys command
@@ -1905,9 +1927,9 b' All public heads'
1905 1927 i> 0000000000000000000000000000000000000000-0000000000000000000000000000000000000000
1906 1928 i> flush() -> None
1907 1929 o> readline() -> 4:
1908 o> 403\n
1909 o> readline() -> 403:
1910 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch\n
1930 o> 413\n
1931 o> readline() -> 413:
1932 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch\n
1911 1933 o> readline() -> 2:
1912 1934 o> 1\n
1913 1935 o> readline() -> 1:
@@ -1936,8 +1958,8 b' All public heads'
1936 1958 o> readline() -> 62:
1937 1959 o> upgraded * exp-ssh-v2-0001\n (glob)
1938 1960 o> readline() -> 4:
1939 o> 402\n
1940 o> read(402) -> 402: capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch
1961 o> 412\n
1962 o> read(412) -> 412: capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch
1941 1963 o> read(1) -> 1:
1942 1964 o> \n
1943 1965 sending listkeys command
@@ -1972,9 +1994,9 b' Setting public phase via pushkey'
1972 1994 i> 0000000000000000000000000000000000000000-0000000000000000000000000000000000000000
1973 1995 i> flush() -> None
1974 1996 o> readline() -> 4:
1975 o> 403\n
1976 o> readline() -> 403:
1977 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch\n
1997 o> 413\n
1998 o> readline() -> 413:
1999 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch\n
1978 2000 o> readline() -> 2:
1979 2001 o> 1\n
1980 2002 o> readline() -> 1:
@@ -2013,8 +2035,8 b' Setting public phase via pushkey'
2013 2035 o> readline() -> 62:
2014 2036 o> upgraded * exp-ssh-v2-0001\n (glob)
2015 2037 o> readline() -> 4:
2016 o> 402\n
2017 o> read(402) -> 402: capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch
2038 o> 412\n
2039 o> read(412) -> 412: capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch
2018 2040 o> read(1) -> 1:
2019 2041 o> \n
2020 2042 sending pushkey command
@@ -2079,9 +2101,9 b' Test batching of requests'
2079 2101 i> 0000000000000000000000000000000000000000-0000000000000000000000000000000000000000
2080 2102 i> flush() -> None
2081 2103 o> readline() -> 4:
2082 o> 403\n
2083 o> readline() -> 403:
2084 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch\n
2104 o> 413\n
2105 o> readline() -> 413:
2106 o> capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch\n
2085 2107 o> readline() -> 2:
2086 2108 o> 1\n
2087 2109 o> readline() -> 1:
@@ -2119,8 +2141,8 b' Test batching of requests'
2119 2141 o> readline() -> 62:
2120 2142 o> upgraded * exp-ssh-v2-0001\n (glob)
2121 2143 o> readline() -> 4:
2122 o> 402\n
2123 o> read(402) -> 402: capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch
2144 o> 412\n
2145 o> read(412) -> 412: capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch
2124 2146 o> read(1) -> 1:
2125 2147 o> \n
2126 2148 sending batch with 3 sub-commands
@@ -495,10 +495,13 b' debug output'
495 495 devel-peer-request: between
496 496 devel-peer-request: pairs: 81 bytes
497 497 sending between command
498 remote: 403 (sshv1 !)
498 remote: 413 (sshv1 !)
499 499 protocol upgraded to exp-ssh-v2-0001 (sshv2 !)
500 remote: capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN batch
500 remote: capabilities: lookup branchmap pushkey known getbundle unbundlehash changegroupsubset streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN protocaps batch
501 501 remote: 1 (sshv1 !)
502 devel-peer-request: protocaps
503 devel-peer-request: caps: * bytes (glob)
504 sending protocaps command
502 505 query 1; heads
503 506 devel-peer-request: batched-content
504 507 devel-peer-request: - heads (0 arguments)
General Comments 0
You need to be logged in to leave comments. Login now