tests/test-ssh-proto-unbundle.t
author Gregory Szorc <gregory.szorc@gmail.com>
Fri, 02 Mar 2018 18:50:49 -0500
changeset 36608 1151c731686e
parent 36534 5faeabb07cf5
child 36612 e89959970a08
permissions -rw-r--r--
sshpeer: don't read from stderr when that behavior is disabled We previously prevented the creation of doublepipe instances when we're not supposed to automatically read from stderr. However, there were other automatic calls to read from stderr that were undermining this effort. This commit prevents all automatic reads from stderr from occurring when they are supposed to be disabled. Because stderr is no longer being read, we need to call "readavailable" from tests so stderr is read from. Test output changes because stderr is now always (manually) read after stdout. And, since sshpeer no longer automatically tends to stderr, no "remote: " messages are printed. This should fix non-deterministic test output. FWIW, doublepipe automatically reads from stderr when reading from stdout, so I'm not sure some of these calls to self._readerr() are even needed. Differential Revision: https://phab.mercurial-scm.org/D2571
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
36534
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
     1
  $ cat > hgrc-sshv2 << EOF
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
     2
  > %include $HGRCPATH
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
     3
  > [experimental]
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
     4
  > sshpeer.advertise-v2 = true
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
     5
  > sshserver.support-v2 = true
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
     6
  > EOF
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
     7
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
     8
  $ debugwireproto() {
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
     9
  >   commands=`cat -`
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    10
  >   echo 'testing ssh1'
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    11
  >   tip=`hg log -r tip -T '{node}'`
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    12
  >   echo "${commands}" | hg --verbose debugwireproto --localssh --noreadstderr
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    13
  >   if [ -n "$1" ]; then
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    14
  >       hg --config extensions.strip= strip --no-backup -r "all() - ::${tip}"
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    15
  >   fi
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    16
  >   echo ""
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    17
  >   echo 'testing ssh2'
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    18
  >   echo "${commands}" | HGRCPATH=$TESTTMP/hgrc-sshv2 hg --verbose debugwireproto --localssh --noreadstderr
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    19
  >   if [ -n "$1" ]; then
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    20
  >       hg --config extensions.strip= strip --no-backup -r "all() - ::${tip}"
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    21
  >   fi
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    22
  > }
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    23
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    24
Generate some bundle files
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    25
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    26
  $ hg init repo
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    27
  $ cd repo
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    28
  $ echo 0 > foo
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    29
  $ hg -q commit -A -m initial
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    30
  $ hg bundle --all -t none-v1 ../initial.v1.hg
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    31
  1 changesets found
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    32
  $ cd ..
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    33
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    34
Test pushing bundle1 payload to a server with bundle1 disabled
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    35
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    36
  $ hg init no-bundle1
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    37
  $ cd no-bundle1
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    38
  $ cat > .hg/hgrc << EOF
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    39
  > [server]
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    40
  > bundle1 = false
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    41
  > EOF
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    42
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    43
  $ debugwireproto << EOF
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    44
  > command unbundle
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    45
  > # This is "force" in hex.
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    46
  >     heads 666f726365
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    47
  >     PUSHFILE ../initial.v1.hg
36608
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
    48
  > readavailable
36534
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    49
  > EOF
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    50
  testing ssh1
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    51
  creating ssh peer from handshake results
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    52
  i> write(104) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    53
  i>     hello\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    54
  i>     between\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    55
  i>     pairs 81\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    56
  i>     0000000000000000000000000000000000000000-0000000000000000000000000000000000000000
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    57
  i> flush() -> None
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    58
  o> readline() -> 4:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    59
  o>     384\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    60
  o> readline() -> 384:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    61
  o>     capabilities: lookup changegroupsubset branchmap pushkey known getbundle unbundlehash batch streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    62
  o> readline() -> 2:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    63
  o>     1\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    64
  o> readline() -> 1:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    65
  o>     \n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    66
  sending unbundle command
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    67
  i> write(9) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    68
  i>     unbundle\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    69
  i> write(9) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    70
  i>     heads 10\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    71
  i> write(10) -> None: 666f726365
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    72
  i> flush() -> None
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    73
  o> readline() -> 2:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    74
  o>     0\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    75
  i> write(4) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    76
  i>     426\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    77
  i> write(426) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    78
  i>     HG10UN\x00\x00\x00\x9eh\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00h\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00>cba485ca3678256e044428f70f58291196f6e9de\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    79
  i>     test\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    80
  i>     0 0\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    81
  i>     foo\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    82
  i>     \n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    83
  i>     initial\x00\x00\x00\x00\x00\x00\x00\x8d\xcb\xa4\x85\xca6x%n\x04D(\xf7\x0fX)\x11\x96\xf6\xe9\xde\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00h\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00-foo\x00362fef284ce2ca02aecc8de6d5e8a1c3af0556fe\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    84
  i>     \x00\x00\x00\x00\x00\x00\x00\x07foo\x00\x00\x00b6/\xef(L\xe2\xca\x02\xae\xcc\x8d\xe6\xd5\xe8\xa1\xc3\xaf\x05V\xfe\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00h\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x020\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    85
  i>     \x00\x00\x00\x00\x00\x00\x00\x00
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    86
  i> write(2) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    87
  i>     0\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    88
  i> flush() -> None
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    89
  o> readline() -> 2:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    90
  o>     0\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    91
  o> read(0) -> 0: 
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    92
  o> readline() -> 2:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    93
  o>     1\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    94
  o> read(1) -> 1: 0
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    95
  result: 0
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
    96
  remote output: 
36608
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
    97
  e> read(-1) -> 115:
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
    98
  e>     abort: incompatible Mercurial client; bundle2 required\n
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
    99
  e>     (see https://www.mercurial-scm.org/wiki/IncompatibleClient)\n
36534
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   100
  
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   101
  testing ssh2
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   102
  creating ssh peer from handshake results
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   103
  i> write(171) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   104
  i>     upgrade * proto=exp-ssh-v2-0001\n (glob)
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   105
  i>     hello\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   106
  i>     between\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   107
  i>     pairs 81\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   108
  i>     0000000000000000000000000000000000000000-0000000000000000000000000000000000000000
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   109
  i> flush() -> None
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   110
  o> readline() -> 62:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   111
  o>     upgraded * exp-ssh-v2-0001\n (glob)
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   112
  o> readline() -> 4:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   113
  o>     383\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   114
  o> read(383) -> 383: capabilities: lookup changegroupsubset branchmap pushkey known getbundle unbundlehash batch streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   115
  o> read(1) -> 1:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   116
  o>     \n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   117
  sending unbundle command
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   118
  i> write(9) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   119
  i>     unbundle\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   120
  i> write(9) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   121
  i>     heads 10\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   122
  i> write(10) -> None: 666f726365
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   123
  i> flush() -> None
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   124
  o> readline() -> 2:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   125
  o>     0\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   126
  i> write(4) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   127
  i>     426\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   128
  i> write(426) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   129
  i>     HG10UN\x00\x00\x00\x9eh\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00h\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00>cba485ca3678256e044428f70f58291196f6e9de\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   130
  i>     test\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   131
  i>     0 0\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   132
  i>     foo\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   133
  i>     \n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   134
  i>     initial\x00\x00\x00\x00\x00\x00\x00\x8d\xcb\xa4\x85\xca6x%n\x04D(\xf7\x0fX)\x11\x96\xf6\xe9\xde\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00h\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00-foo\x00362fef284ce2ca02aecc8de6d5e8a1c3af0556fe\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   135
  i>     \x00\x00\x00\x00\x00\x00\x00\x07foo\x00\x00\x00b6/\xef(L\xe2\xca\x02\xae\xcc\x8d\xe6\xd5\xe8\xa1\xc3\xaf\x05V\xfe\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00h\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x020\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   136
  i>     \x00\x00\x00\x00\x00\x00\x00\x00
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   137
  i> write(2) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   138
  i>     0\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   139
  i> flush() -> None
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   140
  o> readline() -> 2:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   141
  o>     0\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   142
  o> read(0) -> 0: 
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   143
  o> readline() -> 2:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   144
  o>     1\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   145
  o> read(1) -> 1: 0
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   146
  result: 0
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   147
  remote output: 
36608
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
   148
  e> read(-1) -> 115:
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
   149
  e>     abort: incompatible Mercurial client; bundle2 required\n
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
   150
  e>     (see https://www.mercurial-scm.org/wiki/IncompatibleClient)\n
36534
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   151
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   152
  $ cd ..
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   153
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   154
Create a pretxnchangegroup hook that fails. Give it multiple modes of printing
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   155
output so we can test I/O capture and behavior.
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   156
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   157
Test pushing to a server that has a pretxnchangegroup Python hook that fails
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   158
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   159
  $ cat > $TESTTMP/failhook << EOF
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   160
  > from __future__ import print_function
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   161
  > import sys
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   162
  > def hook1line(ui, repo, **kwargs):
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   163
  >     ui.write('ui.write 1 line\n')
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   164
  >     return 1
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   165
  > def hook2lines(ui, repo, **kwargs):
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   166
  >     ui.write('ui.write 2 lines 1\n')
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   167
  >     ui.write('ui.write 2 lines 2\n')
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   168
  >     return 1
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   169
  > def hook1lineflush(ui, repo, **kwargs):
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   170
  >     ui.write('ui.write 1 line flush\n')
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   171
  >     ui.flush()
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   172
  >     return 1
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   173
  > def hookmultiflush(ui, repo, **kwargs):
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   174
  >     ui.write('ui.write 1st\n')
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   175
  >     ui.flush()
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   176
  >     ui.write('ui.write 2nd\n')
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   177
  >     ui.flush()
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   178
  >     return 1
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   179
  > def hookwriteandwriteerr(ui, repo, **kwargs):
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   180
  >     ui.write('ui.write 1\n')
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   181
  >     ui.write_err('ui.write_err 1\n')
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   182
  >     ui.write('ui.write 2\n')
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   183
  >     ui.write_err('ui.write_err 2\n')
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   184
  >     return 1
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   185
  > def hookprintstdout(ui, repo, **kwargs):
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   186
  >     print('printed line')
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   187
  >     return 1
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   188
  > def hookprintandwrite(ui, repo, **kwargs):
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   189
  >     print('print 1')
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   190
  >     ui.write('ui.write 1\n')
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   191
  >     print('print 2')
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   192
  >     ui.write('ui.write 2\n')
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   193
  >     return 1
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   194
  > def hookprintstderrandstdout(ui, repo, **kwargs):
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   195
  >     print('stdout 1')
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   196
  >     print('stderr 1', file=sys.stderr)
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   197
  >     print('stdout 2')
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   198
  >     print('stderr 2', file=sys.stderr)
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   199
  >     return 1
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   200
  > EOF
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   201
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   202
  $ hg init failrepo
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   203
  $ cd failrepo
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   204
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   205
ui.write() in hook is redirected to stderr
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   206
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   207
  $ cat > .hg/hgrc << EOF
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   208
  > [hooks]
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   209
  > pretxnchangegroup.fail = python:$TESTTMP/failhook:hook1line
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   210
  > EOF
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   211
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   212
  $ debugwireproto << EOF
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   213
  > command unbundle
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   214
  > # This is "force" in hex.
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   215
  >     heads 666f726365
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   216
  >     PUSHFILE ../initial.v1.hg
36608
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
   217
  > readavailable
36534
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   218
  > EOF
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   219
  testing ssh1
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   220
  creating ssh peer from handshake results
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   221
  i> write(104) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   222
  i>     hello\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   223
  i>     between\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   224
  i>     pairs 81\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   225
  i>     0000000000000000000000000000000000000000-0000000000000000000000000000000000000000
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   226
  i> flush() -> None
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   227
  o> readline() -> 4:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   228
  o>     384\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   229
  o> readline() -> 384:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   230
  o>     capabilities: lookup changegroupsubset branchmap pushkey known getbundle unbundlehash batch streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   231
  o> readline() -> 2:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   232
  o>     1\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   233
  o> readline() -> 1:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   234
  o>     \n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   235
  sending unbundle command
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   236
  i> write(9) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   237
  i>     unbundle\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   238
  i> write(9) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   239
  i>     heads 10\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   240
  i> write(10) -> None: 666f726365
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   241
  i> flush() -> None
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   242
  o> readline() -> 2:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   243
  o>     0\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   244
  i> write(4) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   245
  i>     426\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   246
  i> write(426) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   247
  i>     HG10UN\x00\x00\x00\x9eh\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00h\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00>cba485ca3678256e044428f70f58291196f6e9de\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   248
  i>     test\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   249
  i>     0 0\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   250
  i>     foo\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   251
  i>     \n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   252
  i>     initial\x00\x00\x00\x00\x00\x00\x00\x8d\xcb\xa4\x85\xca6x%n\x04D(\xf7\x0fX)\x11\x96\xf6\xe9\xde\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00h\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00-foo\x00362fef284ce2ca02aecc8de6d5e8a1c3af0556fe\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   253
  i>     \x00\x00\x00\x00\x00\x00\x00\x07foo\x00\x00\x00b6/\xef(L\xe2\xca\x02\xae\xcc\x8d\xe6\xd5\xe8\xa1\xc3\xaf\x05V\xfe\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00h\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x020\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   254
  i>     \x00\x00\x00\x00\x00\x00\x00\x00
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   255
  i> write(2) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   256
  i>     0\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   257
  i> flush() -> None
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   258
  o> readline() -> 2:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   259
  o>     0\n
36608
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
   260
  o> read(0) -> 0: 
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
   261
  o> readline() -> 2:
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
   262
  o>     1\n
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
   263
  o> read(1) -> 1: 0
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
   264
  result: 0
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
   265
  remote output: 
36534
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   266
  e> read(-1) -> 196:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   267
  e>     adding changesets\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   268
  e>     adding manifests\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   269
  e>     adding file changes\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   270
  e>     added 1 changesets with 1 changes to 1 files\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   271
  e>     ui.write 1 line\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   272
  e>     transaction abort!\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   273
  e>     rollback completed\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   274
  e>     abort: pretxnchangegroup.fail hook failed\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   275
  
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   276
  testing ssh2
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   277
  creating ssh peer from handshake results
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   278
  i> write(171) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   279
  i>     upgrade * proto=exp-ssh-v2-0001\n (glob)
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   280
  i>     hello\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   281
  i>     between\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   282
  i>     pairs 81\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   283
  i>     0000000000000000000000000000000000000000-0000000000000000000000000000000000000000
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   284
  i> flush() -> None
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   285
  o> readline() -> 62:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   286
  o>     upgraded * exp-ssh-v2-0001\n (glob)
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   287
  o> readline() -> 4:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   288
  o>     383\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   289
  o> read(383) -> 383: capabilities: lookup changegroupsubset branchmap pushkey known getbundle unbundlehash batch streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   290
  o> read(1) -> 1:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   291
  o>     \n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   292
  sending unbundle command
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   293
  i> write(9) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   294
  i>     unbundle\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   295
  i> write(9) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   296
  i>     heads 10\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   297
  i> write(10) -> None: 666f726365
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   298
  i> flush() -> None
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   299
  o> readline() -> 2:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   300
  o>     0\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   301
  i> write(4) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   302
  i>     426\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   303
  i> write(426) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   304
  i>     HG10UN\x00\x00\x00\x9eh\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00h\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00>cba485ca3678256e044428f70f58291196f6e9de\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   305
  i>     test\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   306
  i>     0 0\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   307
  i>     foo\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   308
  i>     \n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   309
  i>     initial\x00\x00\x00\x00\x00\x00\x00\x8d\xcb\xa4\x85\xca6x%n\x04D(\xf7\x0fX)\x11\x96\xf6\xe9\xde\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00h\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00-foo\x00362fef284ce2ca02aecc8de6d5e8a1c3af0556fe\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   310
  i>     \x00\x00\x00\x00\x00\x00\x00\x07foo\x00\x00\x00b6/\xef(L\xe2\xca\x02\xae\xcc\x8d\xe6\xd5\xe8\xa1\xc3\xaf\x05V\xfe\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00h\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x020\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   311
  i>     \x00\x00\x00\x00\x00\x00\x00\x00
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   312
  i> write(2) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   313
  i>     0\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   314
  i> flush() -> None
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   315
  o> readline() -> 2:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   316
  o>     0\n
36608
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
   317
  o> read(0) -> 0: 
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
   318
  o> readline() -> 2:
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
   319
  o>     1\n
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
   320
  o> read(1) -> 1: 0
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
   321
  result: 0
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
   322
  remote output: 
36534
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   323
  e> read(-1) -> 196:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   324
  e>     adding changesets\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   325
  e>     adding manifests\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   326
  e>     adding file changes\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   327
  e>     added 1 changesets with 1 changes to 1 files\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   328
  e>     ui.write 1 line\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   329
  e>     transaction abort!\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   330
  e>     rollback completed\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   331
  e>     abort: pretxnchangegroup.fail hook failed\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   332
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   333
And a variation that writes multiple lines using ui.write
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   334
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   335
  $ cat > .hg/hgrc << EOF
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   336
  > [hooks]
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   337
  > pretxnchangegroup.fail = python:$TESTTMP/failhook:hook2lines
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   338
  > EOF
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   339
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   340
  $ debugwireproto << EOF
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   341
  > command unbundle
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   342
  > # This is "force" in hex.
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   343
  >     heads 666f726365
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   344
  >     PUSHFILE ../initial.v1.hg
36608
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
   345
  > readavailable
36534
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   346
  > EOF
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   347
  testing ssh1
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   348
  creating ssh peer from handshake results
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   349
  i> write(104) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   350
  i>     hello\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   351
  i>     between\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   352
  i>     pairs 81\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   353
  i>     0000000000000000000000000000000000000000-0000000000000000000000000000000000000000
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   354
  i> flush() -> None
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   355
  o> readline() -> 4:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   356
  o>     384\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   357
  o> readline() -> 384:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   358
  o>     capabilities: lookup changegroupsubset branchmap pushkey known getbundle unbundlehash batch streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   359
  o> readline() -> 2:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   360
  o>     1\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   361
  o> readline() -> 1:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   362
  o>     \n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   363
  sending unbundle command
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   364
  i> write(9) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   365
  i>     unbundle\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   366
  i> write(9) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   367
  i>     heads 10\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   368
  i> write(10) -> None: 666f726365
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   369
  i> flush() -> None
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   370
  o> readline() -> 2:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   371
  o>     0\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   372
  i> write(4) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   373
  i>     426\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   374
  i> write(426) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   375
  i>     HG10UN\x00\x00\x00\x9eh\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00h\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00>cba485ca3678256e044428f70f58291196f6e9de\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   376
  i>     test\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   377
  i>     0 0\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   378
  i>     foo\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   379
  i>     \n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   380
  i>     initial\x00\x00\x00\x00\x00\x00\x00\x8d\xcb\xa4\x85\xca6x%n\x04D(\xf7\x0fX)\x11\x96\xf6\xe9\xde\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00h\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00-foo\x00362fef284ce2ca02aecc8de6d5e8a1c3af0556fe\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   381
  i>     \x00\x00\x00\x00\x00\x00\x00\x07foo\x00\x00\x00b6/\xef(L\xe2\xca\x02\xae\xcc\x8d\xe6\xd5\xe8\xa1\xc3\xaf\x05V\xfe\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00h\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x020\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   382
  i>     \x00\x00\x00\x00\x00\x00\x00\x00
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   383
  i> write(2) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   384
  i>     0\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   385
  i> flush() -> None
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   386
  o> readline() -> 2:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   387
  o>     0\n
36608
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
   388
  o> read(0) -> 0: 
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
   389
  o> readline() -> 2:
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
   390
  o>     1\n
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
   391
  o> read(1) -> 1: 0
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
   392
  result: 0
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
   393
  remote output: 
36534
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   394
  e> read(-1) -> 218:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   395
  e>     adding changesets\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   396
  e>     adding manifests\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   397
  e>     adding file changes\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   398
  e>     added 1 changesets with 1 changes to 1 files\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   399
  e>     ui.write 2 lines 1\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   400
  e>     ui.write 2 lines 2\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   401
  e>     transaction abort!\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   402
  e>     rollback completed\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   403
  e>     abort: pretxnchangegroup.fail hook failed\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   404
  
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   405
  testing ssh2
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   406
  creating ssh peer from handshake results
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   407
  i> write(171) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   408
  i>     upgrade * proto=exp-ssh-v2-0001\n (glob)
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   409
  i>     hello\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   410
  i>     between\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   411
  i>     pairs 81\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   412
  i>     0000000000000000000000000000000000000000-0000000000000000000000000000000000000000
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   413
  i> flush() -> None
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   414
  o> readline() -> 62:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   415
  o>     upgraded * exp-ssh-v2-0001\n (glob)
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   416
  o> readline() -> 4:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   417
  o>     383\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   418
  o> read(383) -> 383: capabilities: lookup changegroupsubset branchmap pushkey known getbundle unbundlehash batch streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   419
  o> read(1) -> 1:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   420
  o>     \n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   421
  sending unbundle command
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   422
  i> write(9) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   423
  i>     unbundle\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   424
  i> write(9) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   425
  i>     heads 10\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   426
  i> write(10) -> None: 666f726365
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   427
  i> flush() -> None
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   428
  o> readline() -> 2:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   429
  o>     0\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   430
  i> write(4) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   431
  i>     426\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   432
  i> write(426) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   433
  i>     HG10UN\x00\x00\x00\x9eh\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00h\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00>cba485ca3678256e044428f70f58291196f6e9de\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   434
  i>     test\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   435
  i>     0 0\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   436
  i>     foo\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   437
  i>     \n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   438
  i>     initial\x00\x00\x00\x00\x00\x00\x00\x8d\xcb\xa4\x85\xca6x%n\x04D(\xf7\x0fX)\x11\x96\xf6\xe9\xde\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00h\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00-foo\x00362fef284ce2ca02aecc8de6d5e8a1c3af0556fe\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   439
  i>     \x00\x00\x00\x00\x00\x00\x00\x07foo\x00\x00\x00b6/\xef(L\xe2\xca\x02\xae\xcc\x8d\xe6\xd5\xe8\xa1\xc3\xaf\x05V\xfe\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00h\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x020\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   440
  i>     \x00\x00\x00\x00\x00\x00\x00\x00
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   441
  i> write(2) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   442
  i>     0\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   443
  i> flush() -> None
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   444
  o> readline() -> 2:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   445
  o>     0\n
36608
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
   446
  o> read(0) -> 0: 
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
   447
  o> readline() -> 2:
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
   448
  o>     1\n
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
   449
  o> read(1) -> 1: 0
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
   450
  result: 0
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
   451
  remote output: 
36534
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   452
  e> read(-1) -> 218:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   453
  e>     adding changesets\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   454
  e>     adding manifests\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   455
  e>     adding file changes\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   456
  e>     added 1 changesets with 1 changes to 1 files\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   457
  e>     ui.write 2 lines 1\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   458
  e>     ui.write 2 lines 2\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   459
  e>     transaction abort!\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   460
  e>     rollback completed\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   461
  e>     abort: pretxnchangegroup.fail hook failed\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   462
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   463
And a variation that does a ui.flush() after writing output
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   464
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   465
  $ cat > .hg/hgrc << EOF
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   466
  > [hooks]
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   467
  > pretxnchangegroup.fail = python:$TESTTMP/failhook:hook1lineflush
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   468
  > EOF
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   469
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   470
  $ debugwireproto << EOF
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   471
  > command unbundle
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   472
  > # This is "force" in hex.
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   473
  >     heads 666f726365
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   474
  >     PUSHFILE ../initial.v1.hg
36608
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
   475
  > readavailable
36534
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   476
  > EOF
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   477
  testing ssh1
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   478
  creating ssh peer from handshake results
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   479
  i> write(104) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   480
  i>     hello\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   481
  i>     between\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   482
  i>     pairs 81\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   483
  i>     0000000000000000000000000000000000000000-0000000000000000000000000000000000000000
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   484
  i> flush() -> None
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   485
  o> readline() -> 4:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   486
  o>     384\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   487
  o> readline() -> 384:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   488
  o>     capabilities: lookup changegroupsubset branchmap pushkey known getbundle unbundlehash batch streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   489
  o> readline() -> 2:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   490
  o>     1\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   491
  o> readline() -> 1:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   492
  o>     \n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   493
  sending unbundle command
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   494
  i> write(9) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   495
  i>     unbundle\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   496
  i> write(9) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   497
  i>     heads 10\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   498
  i> write(10) -> None: 666f726365
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   499
  i> flush() -> None
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   500
  o> readline() -> 2:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   501
  o>     0\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   502
  i> write(4) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   503
  i>     426\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   504
  i> write(426) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   505
  i>     HG10UN\x00\x00\x00\x9eh\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00h\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00>cba485ca3678256e044428f70f58291196f6e9de\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   506
  i>     test\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   507
  i>     0 0\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   508
  i>     foo\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   509
  i>     \n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   510
  i>     initial\x00\x00\x00\x00\x00\x00\x00\x8d\xcb\xa4\x85\xca6x%n\x04D(\xf7\x0fX)\x11\x96\xf6\xe9\xde\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00h\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00-foo\x00362fef284ce2ca02aecc8de6d5e8a1c3af0556fe\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   511
  i>     \x00\x00\x00\x00\x00\x00\x00\x07foo\x00\x00\x00b6/\xef(L\xe2\xca\x02\xae\xcc\x8d\xe6\xd5\xe8\xa1\xc3\xaf\x05V\xfe\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00h\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x020\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   512
  i>     \x00\x00\x00\x00\x00\x00\x00\x00
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   513
  i> write(2) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   514
  i>     0\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   515
  i> flush() -> None
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   516
  o> readline() -> 2:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   517
  o>     0\n
36608
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
   518
  o> read(0) -> 0: 
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
   519
  o> readline() -> 2:
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
   520
  o>     1\n
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
   521
  o> read(1) -> 1: 0
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
   522
  result: 0
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
   523
  remote output: 
36534
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   524
  e> read(-1) -> 202:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   525
  e>     adding changesets\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   526
  e>     adding manifests\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   527
  e>     adding file changes\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   528
  e>     added 1 changesets with 1 changes to 1 files\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   529
  e>     ui.write 1 line flush\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   530
  e>     transaction abort!\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   531
  e>     rollback completed\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   532
  e>     abort: pretxnchangegroup.fail hook failed\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   533
  
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   534
  testing ssh2
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   535
  creating ssh peer from handshake results
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   536
  i> write(171) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   537
  i>     upgrade * proto=exp-ssh-v2-0001\n (glob)
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   538
  i>     hello\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   539
  i>     between\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   540
  i>     pairs 81\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   541
  i>     0000000000000000000000000000000000000000-0000000000000000000000000000000000000000
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   542
  i> flush() -> None
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   543
  o> readline() -> 62:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   544
  o>     upgraded * exp-ssh-v2-0001\n (glob)
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   545
  o> readline() -> 4:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   546
  o>     383\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   547
  o> read(383) -> 383: capabilities: lookup changegroupsubset branchmap pushkey known getbundle unbundlehash batch streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   548
  o> read(1) -> 1:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   549
  o>     \n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   550
  sending unbundle command
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   551
  i> write(9) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   552
  i>     unbundle\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   553
  i> write(9) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   554
  i>     heads 10\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   555
  i> write(10) -> None: 666f726365
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   556
  i> flush() -> None
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   557
  o> readline() -> 2:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   558
  o>     0\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   559
  i> write(4) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   560
  i>     426\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   561
  i> write(426) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   562
  i>     HG10UN\x00\x00\x00\x9eh\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00h\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00>cba485ca3678256e044428f70f58291196f6e9de\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   563
  i>     test\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   564
  i>     0 0\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   565
  i>     foo\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   566
  i>     \n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   567
  i>     initial\x00\x00\x00\x00\x00\x00\x00\x8d\xcb\xa4\x85\xca6x%n\x04D(\xf7\x0fX)\x11\x96\xf6\xe9\xde\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00h\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00-foo\x00362fef284ce2ca02aecc8de6d5e8a1c3af0556fe\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   568
  i>     \x00\x00\x00\x00\x00\x00\x00\x07foo\x00\x00\x00b6/\xef(L\xe2\xca\x02\xae\xcc\x8d\xe6\xd5\xe8\xa1\xc3\xaf\x05V\xfe\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00h\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x020\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   569
  i>     \x00\x00\x00\x00\x00\x00\x00\x00
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   570
  i> write(2) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   571
  i>     0\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   572
  i> flush() -> None
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   573
  o> readline() -> 2:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   574
  o>     0\n
36608
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
   575
  o> read(0) -> 0: 
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
   576
  o> readline() -> 2:
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
   577
  o>     1\n
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
   578
  o> read(1) -> 1: 0
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
   579
  result: 0
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
   580
  remote output: 
36534
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   581
  e> read(-1) -> 202:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   582
  e>     adding changesets\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   583
  e>     adding manifests\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   584
  e>     adding file changes\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   585
  e>     added 1 changesets with 1 changes to 1 files\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   586
  e>     ui.write 1 line flush\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   587
  e>     transaction abort!\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   588
  e>     rollback completed\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   589
  e>     abort: pretxnchangegroup.fail hook failed\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   590
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   591
Multiple writes + flush
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   592
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   593
  $ cat > .hg/hgrc << EOF
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   594
  > [hooks]
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   595
  > pretxnchangegroup.fail = python:$TESTTMP/failhook:hookmultiflush
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   596
  > EOF
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   597
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   598
  $ debugwireproto << EOF
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   599
  > command unbundle
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   600
  > # This is "force" in hex.
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   601
  >     heads 666f726365
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   602
  >     PUSHFILE ../initial.v1.hg
36608
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
   603
  > readavailable
36534
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   604
  > EOF
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   605
  testing ssh1
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   606
  creating ssh peer from handshake results
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   607
  i> write(104) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   608
  i>     hello\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   609
  i>     between\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   610
  i>     pairs 81\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   611
  i>     0000000000000000000000000000000000000000-0000000000000000000000000000000000000000
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   612
  i> flush() -> None
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   613
  o> readline() -> 4:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   614
  o>     384\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   615
  o> readline() -> 384:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   616
  o>     capabilities: lookup changegroupsubset branchmap pushkey known getbundle unbundlehash batch streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   617
  o> readline() -> 2:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   618
  o>     1\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   619
  o> readline() -> 1:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   620
  o>     \n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   621
  sending unbundle command
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   622
  i> write(9) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   623
  i>     unbundle\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   624
  i> write(9) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   625
  i>     heads 10\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   626
  i> write(10) -> None: 666f726365
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   627
  i> flush() -> None
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   628
  o> readline() -> 2:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   629
  o>     0\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   630
  i> write(4) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   631
  i>     426\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   632
  i> write(426) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   633
  i>     HG10UN\x00\x00\x00\x9eh\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00h\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00>cba485ca3678256e044428f70f58291196f6e9de\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   634
  i>     test\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   635
  i>     0 0\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   636
  i>     foo\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   637
  i>     \n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   638
  i>     initial\x00\x00\x00\x00\x00\x00\x00\x8d\xcb\xa4\x85\xca6x%n\x04D(\xf7\x0fX)\x11\x96\xf6\xe9\xde\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00h\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00-foo\x00362fef284ce2ca02aecc8de6d5e8a1c3af0556fe\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   639
  i>     \x00\x00\x00\x00\x00\x00\x00\x07foo\x00\x00\x00b6/\xef(L\xe2\xca\x02\xae\xcc\x8d\xe6\xd5\xe8\xa1\xc3\xaf\x05V\xfe\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00h\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x020\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   640
  i>     \x00\x00\x00\x00\x00\x00\x00\x00
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   641
  i> write(2) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   642
  i>     0\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   643
  i> flush() -> None
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   644
  o> readline() -> 2:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   645
  o>     0\n
36608
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
   646
  o> read(0) -> 0: 
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
   647
  o> readline() -> 2:
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
   648
  o>     1\n
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
   649
  o> read(1) -> 1: 0
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
   650
  result: 0
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
   651
  remote output: 
36534
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   652
  e> read(-1) -> 206:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   653
  e>     adding changesets\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   654
  e>     adding manifests\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   655
  e>     adding file changes\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   656
  e>     added 1 changesets with 1 changes to 1 files\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   657
  e>     ui.write 1st\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   658
  e>     ui.write 2nd\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   659
  e>     transaction abort!\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   660
  e>     rollback completed\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   661
  e>     abort: pretxnchangegroup.fail hook failed\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   662
  
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   663
  testing ssh2
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   664
  creating ssh peer from handshake results
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   665
  i> write(171) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   666
  i>     upgrade * proto=exp-ssh-v2-0001\n (glob)
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   667
  i>     hello\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   668
  i>     between\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   669
  i>     pairs 81\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   670
  i>     0000000000000000000000000000000000000000-0000000000000000000000000000000000000000
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   671
  i> flush() -> None
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   672
  o> readline() -> 62:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   673
  o>     upgraded * exp-ssh-v2-0001\n (glob)
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   674
  o> readline() -> 4:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   675
  o>     383\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   676
  o> read(383) -> 383: capabilities: lookup changegroupsubset branchmap pushkey known getbundle unbundlehash batch streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   677
  o> read(1) -> 1:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   678
  o>     \n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   679
  sending unbundle command
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   680
  i> write(9) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   681
  i>     unbundle\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   682
  i> write(9) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   683
  i>     heads 10\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   684
  i> write(10) -> None: 666f726365
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   685
  i> flush() -> None
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   686
  o> readline() -> 2:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   687
  o>     0\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   688
  i> write(4) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   689
  i>     426\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   690
  i> write(426) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   691
  i>     HG10UN\x00\x00\x00\x9eh\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00h\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00>cba485ca3678256e044428f70f58291196f6e9de\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   692
  i>     test\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   693
  i>     0 0\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   694
  i>     foo\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   695
  i>     \n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   696
  i>     initial\x00\x00\x00\x00\x00\x00\x00\x8d\xcb\xa4\x85\xca6x%n\x04D(\xf7\x0fX)\x11\x96\xf6\xe9\xde\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00h\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00-foo\x00362fef284ce2ca02aecc8de6d5e8a1c3af0556fe\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   697
  i>     \x00\x00\x00\x00\x00\x00\x00\x07foo\x00\x00\x00b6/\xef(L\xe2\xca\x02\xae\xcc\x8d\xe6\xd5\xe8\xa1\xc3\xaf\x05V\xfe\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00h\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x020\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   698
  i>     \x00\x00\x00\x00\x00\x00\x00\x00
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   699
  i> write(2) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   700
  i>     0\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   701
  i> flush() -> None
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   702
  o> readline() -> 2:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   703
  o>     0\n
36608
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
   704
  o> read(0) -> 0: 
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
   705
  o> readline() -> 2:
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
   706
  o>     1\n
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
   707
  o> read(1) -> 1: 0
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
   708
  result: 0
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
   709
  remote output: 
36534
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   710
  e> read(-1) -> 206:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   711
  e>     adding changesets\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   712
  e>     adding manifests\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   713
  e>     adding file changes\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   714
  e>     added 1 changesets with 1 changes to 1 files\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   715
  e>     ui.write 1st\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   716
  e>     ui.write 2nd\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   717
  e>     transaction abort!\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   718
  e>     rollback completed\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   719
  e>     abort: pretxnchangegroup.fail hook failed\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   720
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   721
ui.write() + ui.write_err() output is captured
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   722
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   723
  $ cat > .hg/hgrc << EOF
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   724
  > [hooks]
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   725
  > pretxnchangegroup.fail = python:$TESTTMP/failhook:hookwriteandwriteerr
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   726
  > EOF
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   727
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   728
  $ debugwireproto << EOF
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   729
  > command unbundle
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   730
  > # This is "force" in hex.
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   731
  >     heads 666f726365
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   732
  >     PUSHFILE ../initial.v1.hg
36608
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
   733
  > readavailable
36534
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   734
  > EOF
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   735
  testing ssh1
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   736
  creating ssh peer from handshake results
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   737
  i> write(104) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   738
  i>     hello\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   739
  i>     between\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   740
  i>     pairs 81\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   741
  i>     0000000000000000000000000000000000000000-0000000000000000000000000000000000000000
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   742
  i> flush() -> None
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   743
  o> readline() -> 4:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   744
  o>     384\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   745
  o> readline() -> 384:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   746
  o>     capabilities: lookup changegroupsubset branchmap pushkey known getbundle unbundlehash batch streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   747
  o> readline() -> 2:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   748
  o>     1\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   749
  o> readline() -> 1:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   750
  o>     \n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   751
  sending unbundle command
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   752
  i> write(9) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   753
  i>     unbundle\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   754
  i> write(9) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   755
  i>     heads 10\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   756
  i> write(10) -> None: 666f726365
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   757
  i> flush() -> None
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   758
  o> readline() -> 2:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   759
  o>     0\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   760
  i> write(4) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   761
  i>     426\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   762
  i> write(426) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   763
  i>     HG10UN\x00\x00\x00\x9eh\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00h\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00>cba485ca3678256e044428f70f58291196f6e9de\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   764
  i>     test\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   765
  i>     0 0\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   766
  i>     foo\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   767
  i>     \n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   768
  i>     initial\x00\x00\x00\x00\x00\x00\x00\x8d\xcb\xa4\x85\xca6x%n\x04D(\xf7\x0fX)\x11\x96\xf6\xe9\xde\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00h\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00-foo\x00362fef284ce2ca02aecc8de6d5e8a1c3af0556fe\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   769
  i>     \x00\x00\x00\x00\x00\x00\x00\x07foo\x00\x00\x00b6/\xef(L\xe2\xca\x02\xae\xcc\x8d\xe6\xd5\xe8\xa1\xc3\xaf\x05V\xfe\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00h\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x020\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   770
  i>     \x00\x00\x00\x00\x00\x00\x00\x00
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   771
  i> write(2) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   772
  i>     0\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   773
  i> flush() -> None
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   774
  o> readline() -> 2:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   775
  o>     0\n
36608
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
   776
  o> read(0) -> 0: 
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
   777
  o> readline() -> 2:
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
   778
  o>     1\n
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
   779
  o> read(1) -> 1: 0
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
   780
  result: 0
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
   781
  remote output: 
36534
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   782
  e> read(-1) -> 232:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   783
  e>     adding changesets\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   784
  e>     adding manifests\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   785
  e>     adding file changes\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   786
  e>     added 1 changesets with 1 changes to 1 files\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   787
  e>     ui.write 1\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   788
  e>     ui.write_err 1\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   789
  e>     ui.write 2\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   790
  e>     ui.write_err 2\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   791
  e>     transaction abort!\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   792
  e>     rollback completed\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   793
  e>     abort: pretxnchangegroup.fail hook failed\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   794
  
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   795
  testing ssh2
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   796
  creating ssh peer from handshake results
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   797
  i> write(171) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   798
  i>     upgrade * proto=exp-ssh-v2-0001\n (glob)
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   799
  i>     hello\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   800
  i>     between\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   801
  i>     pairs 81\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   802
  i>     0000000000000000000000000000000000000000-0000000000000000000000000000000000000000
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   803
  i> flush() -> None
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   804
  o> readline() -> 62:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   805
  o>     upgraded * exp-ssh-v2-0001\n (glob)
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   806
  o> readline() -> 4:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   807
  o>     383\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   808
  o> read(383) -> 383: capabilities: lookup changegroupsubset branchmap pushkey known getbundle unbundlehash batch streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   809
  o> read(1) -> 1:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   810
  o>     \n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   811
  sending unbundle command
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   812
  i> write(9) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   813
  i>     unbundle\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   814
  i> write(9) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   815
  i>     heads 10\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   816
  i> write(10) -> None: 666f726365
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   817
  i> flush() -> None
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   818
  o> readline() -> 2:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   819
  o>     0\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   820
  i> write(4) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   821
  i>     426\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   822
  i> write(426) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   823
  i>     HG10UN\x00\x00\x00\x9eh\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00h\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00>cba485ca3678256e044428f70f58291196f6e9de\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   824
  i>     test\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   825
  i>     0 0\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   826
  i>     foo\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   827
  i>     \n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   828
  i>     initial\x00\x00\x00\x00\x00\x00\x00\x8d\xcb\xa4\x85\xca6x%n\x04D(\xf7\x0fX)\x11\x96\xf6\xe9\xde\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00h\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00-foo\x00362fef284ce2ca02aecc8de6d5e8a1c3af0556fe\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   829
  i>     \x00\x00\x00\x00\x00\x00\x00\x07foo\x00\x00\x00b6/\xef(L\xe2\xca\x02\xae\xcc\x8d\xe6\xd5\xe8\xa1\xc3\xaf\x05V\xfe\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00h\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x020\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   830
  i>     \x00\x00\x00\x00\x00\x00\x00\x00
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   831
  i> write(2) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   832
  i>     0\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   833
  i> flush() -> None
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   834
  o> readline() -> 2:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   835
  o>     0\n
36608
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
   836
  o> read(0) -> 0: 
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
   837
  o> readline() -> 2:
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
   838
  o>     1\n
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
   839
  o> read(1) -> 1: 0
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
   840
  result: 0
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
   841
  remote output: 
36534
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   842
  e> read(-1) -> 232:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   843
  e>     adding changesets\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   844
  e>     adding manifests\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   845
  e>     adding file changes\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   846
  e>     added 1 changesets with 1 changes to 1 files\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   847
  e>     ui.write 1\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   848
  e>     ui.write_err 1\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   849
  e>     ui.write 2\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   850
  e>     ui.write_err 2\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   851
  e>     transaction abort!\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   852
  e>     rollback completed\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   853
  e>     abort: pretxnchangegroup.fail hook failed\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   854
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   855
print() output is captured
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   856
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   857
  $ cat > .hg/hgrc << EOF
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   858
  > [hooks]
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   859
  > pretxnchangegroup.fail = python:$TESTTMP/failhook:hookprintstdout
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   860
  > EOF
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   861
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   862
  $ debugwireproto << EOF
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   863
  > command unbundle
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   864
  > # This is "force" in hex.
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   865
  >     heads 666f726365
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   866
  >     PUSHFILE ../initial.v1.hg
36608
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
   867
  > readavailable
36534
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   868
  > EOF
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   869
  testing ssh1
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   870
  creating ssh peer from handshake results
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   871
  i> write(104) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   872
  i>     hello\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   873
  i>     between\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   874
  i>     pairs 81\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   875
  i>     0000000000000000000000000000000000000000-0000000000000000000000000000000000000000
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   876
  i> flush() -> None
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   877
  o> readline() -> 4:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   878
  o>     384\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   879
  o> readline() -> 384:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   880
  o>     capabilities: lookup changegroupsubset branchmap pushkey known getbundle unbundlehash batch streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   881
  o> readline() -> 2:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   882
  o>     1\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   883
  o> readline() -> 1:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   884
  o>     \n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   885
  sending unbundle command
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   886
  i> write(9) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   887
  i>     unbundle\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   888
  i> write(9) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   889
  i>     heads 10\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   890
  i> write(10) -> None: 666f726365
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   891
  i> flush() -> None
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   892
  o> readline() -> 2:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   893
  o>     0\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   894
  i> write(4) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   895
  i>     426\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   896
  i> write(426) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   897
  i>     HG10UN\x00\x00\x00\x9eh\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00h\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00>cba485ca3678256e044428f70f58291196f6e9de\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   898
  i>     test\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   899
  i>     0 0\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   900
  i>     foo\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   901
  i>     \n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   902
  i>     initial\x00\x00\x00\x00\x00\x00\x00\x8d\xcb\xa4\x85\xca6x%n\x04D(\xf7\x0fX)\x11\x96\xf6\xe9\xde\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00h\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00-foo\x00362fef284ce2ca02aecc8de6d5e8a1c3af0556fe\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   903
  i>     \x00\x00\x00\x00\x00\x00\x00\x07foo\x00\x00\x00b6/\xef(L\xe2\xca\x02\xae\xcc\x8d\xe6\xd5\xe8\xa1\xc3\xaf\x05V\xfe\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00h\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x020\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   904
  i>     \x00\x00\x00\x00\x00\x00\x00\x00
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   905
  i> write(2) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   906
  i>     0\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   907
  i> flush() -> None
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   908
  o> readline() -> 2:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   909
  o>     0\n
36608
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
   910
  o> read(0) -> 0: 
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
   911
  o> readline() -> 2:
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
   912
  o>     1\n
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
   913
  o> read(1) -> 1: 0
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
   914
  result: 0
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
   915
  remote output: 
36534
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   916
  e> read(-1) -> 193:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   917
  e>     adding changesets\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   918
  e>     adding manifests\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   919
  e>     adding file changes\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   920
  e>     added 1 changesets with 1 changes to 1 files\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   921
  e>     printed line\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   922
  e>     transaction abort!\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   923
  e>     rollback completed\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   924
  e>     abort: pretxnchangegroup.fail hook failed\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   925
  
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   926
  testing ssh2
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   927
  creating ssh peer from handshake results
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   928
  i> write(171) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   929
  i>     upgrade * proto=exp-ssh-v2-0001\n (glob)
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   930
  i>     hello\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   931
  i>     between\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   932
  i>     pairs 81\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   933
  i>     0000000000000000000000000000000000000000-0000000000000000000000000000000000000000
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   934
  i> flush() -> None
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   935
  o> readline() -> 62:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   936
  o>     upgraded * exp-ssh-v2-0001\n (glob)
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   937
  o> readline() -> 4:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   938
  o>     383\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   939
  o> read(383) -> 383: capabilities: lookup changegroupsubset branchmap pushkey known getbundle unbundlehash batch streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   940
  o> read(1) -> 1:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   941
  o>     \n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   942
  sending unbundle command
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   943
  i> write(9) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   944
  i>     unbundle\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   945
  i> write(9) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   946
  i>     heads 10\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   947
  i> write(10) -> None: 666f726365
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   948
  i> flush() -> None
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   949
  o> readline() -> 2:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   950
  o>     0\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   951
  i> write(4) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   952
  i>     426\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   953
  i> write(426) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   954
  i>     HG10UN\x00\x00\x00\x9eh\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00h\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00>cba485ca3678256e044428f70f58291196f6e9de\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   955
  i>     test\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   956
  i>     0 0\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   957
  i>     foo\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   958
  i>     \n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   959
  i>     initial\x00\x00\x00\x00\x00\x00\x00\x8d\xcb\xa4\x85\xca6x%n\x04D(\xf7\x0fX)\x11\x96\xf6\xe9\xde\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00h\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00-foo\x00362fef284ce2ca02aecc8de6d5e8a1c3af0556fe\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   960
  i>     \x00\x00\x00\x00\x00\x00\x00\x07foo\x00\x00\x00b6/\xef(L\xe2\xca\x02\xae\xcc\x8d\xe6\xd5\xe8\xa1\xc3\xaf\x05V\xfe\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00h\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x020\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   961
  i>     \x00\x00\x00\x00\x00\x00\x00\x00
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   962
  i> write(2) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   963
  i>     0\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   964
  i> flush() -> None
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   965
  o> readline() -> 2:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   966
  o>     0\n
36608
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
   967
  o> read(0) -> 0: 
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
   968
  o> readline() -> 2:
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
   969
  o>     1\n
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
   970
  o> read(1) -> 1: 0
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
   971
  result: 0
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
   972
  remote output: 
36534
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   973
  e> read(-1) -> 193:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   974
  e>     adding changesets\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   975
  e>     adding manifests\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   976
  e>     adding file changes\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   977
  e>     added 1 changesets with 1 changes to 1 files\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   978
  e>     printed line\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   979
  e>     transaction abort!\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   980
  e>     rollback completed\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   981
  e>     abort: pretxnchangegroup.fail hook failed\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   982
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   983
Mixed print() and ui.write() are both captured
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   984
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   985
  $ cat > .hg/hgrc << EOF
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   986
  > [hooks]
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   987
  > pretxnchangegroup.fail = python:$TESTTMP/failhook:hookprintandwrite
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   988
  > EOF
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   989
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   990
  $ debugwireproto << EOF
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   991
  > command unbundle
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   992
  > # This is "force" in hex.
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   993
  >     heads 666f726365
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   994
  >     PUSHFILE ../initial.v1.hg
36608
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
   995
  > readavailable
36534
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   996
  > EOF
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   997
  testing ssh1
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   998
  creating ssh peer from handshake results
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
   999
  i> write(104) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1000
  i>     hello\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1001
  i>     between\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1002
  i>     pairs 81\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1003
  i>     0000000000000000000000000000000000000000-0000000000000000000000000000000000000000
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1004
  i> flush() -> None
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1005
  o> readline() -> 4:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1006
  o>     384\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1007
  o> readline() -> 384:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1008
  o>     capabilities: lookup changegroupsubset branchmap pushkey known getbundle unbundlehash batch streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1009
  o> readline() -> 2:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1010
  o>     1\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1011
  o> readline() -> 1:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1012
  o>     \n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1013
  sending unbundle command
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1014
  i> write(9) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1015
  i>     unbundle\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1016
  i> write(9) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1017
  i>     heads 10\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1018
  i> write(10) -> None: 666f726365
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1019
  i> flush() -> None
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1020
  o> readline() -> 2:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1021
  o>     0\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1022
  i> write(4) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1023
  i>     426\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1024
  i> write(426) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1025
  i>     HG10UN\x00\x00\x00\x9eh\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00h\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00>cba485ca3678256e044428f70f58291196f6e9de\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1026
  i>     test\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1027
  i>     0 0\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1028
  i>     foo\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1029
  i>     \n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1030
  i>     initial\x00\x00\x00\x00\x00\x00\x00\x8d\xcb\xa4\x85\xca6x%n\x04D(\xf7\x0fX)\x11\x96\xf6\xe9\xde\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00h\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00-foo\x00362fef284ce2ca02aecc8de6d5e8a1c3af0556fe\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1031
  i>     \x00\x00\x00\x00\x00\x00\x00\x07foo\x00\x00\x00b6/\xef(L\xe2\xca\x02\xae\xcc\x8d\xe6\xd5\xe8\xa1\xc3\xaf\x05V\xfe\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00h\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x020\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1032
  i>     \x00\x00\x00\x00\x00\x00\x00\x00
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1033
  i> write(2) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1034
  i>     0\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1035
  i> flush() -> None
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1036
  o> readline() -> 2:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1037
  o>     0\n
36608
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
  1038
  o> read(0) -> 0: 
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
  1039
  o> readline() -> 2:
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
  1040
  o>     1\n
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
  1041
  o> read(1) -> 1: 0
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
  1042
  result: 0
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
  1043
  remote output: 
36534
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1044
  e> read(-1) -> 218:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1045
  e>     adding changesets\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1046
  e>     adding manifests\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1047
  e>     adding file changes\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1048
  e>     added 1 changesets with 1 changes to 1 files\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1049
  e>     ui.write 1\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1050
  e>     ui.write 2\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1051
  e>     print 1\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1052
  e>     print 2\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1053
  e>     transaction abort!\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1054
  e>     rollback completed\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1055
  e>     abort: pretxnchangegroup.fail hook failed\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1056
  
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1057
  testing ssh2
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1058
  creating ssh peer from handshake results
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1059
  i> write(171) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1060
  i>     upgrade * proto=exp-ssh-v2-0001\n (glob)
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1061
  i>     hello\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1062
  i>     between\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1063
  i>     pairs 81\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1064
  i>     0000000000000000000000000000000000000000-0000000000000000000000000000000000000000
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1065
  i> flush() -> None
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1066
  o> readline() -> 62:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1067
  o>     upgraded * exp-ssh-v2-0001\n (glob)
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1068
  o> readline() -> 4:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1069
  o>     383\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1070
  o> read(383) -> 383: capabilities: lookup changegroupsubset branchmap pushkey known getbundle unbundlehash batch streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1071
  o> read(1) -> 1:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1072
  o>     \n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1073
  sending unbundle command
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1074
  i> write(9) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1075
  i>     unbundle\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1076
  i> write(9) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1077
  i>     heads 10\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1078
  i> write(10) -> None: 666f726365
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1079
  i> flush() -> None
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1080
  o> readline() -> 2:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1081
  o>     0\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1082
  i> write(4) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1083
  i>     426\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1084
  i> write(426) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1085
  i>     HG10UN\x00\x00\x00\x9eh\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00h\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00>cba485ca3678256e044428f70f58291196f6e9de\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1086
  i>     test\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1087
  i>     0 0\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1088
  i>     foo\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1089
  i>     \n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1090
  i>     initial\x00\x00\x00\x00\x00\x00\x00\x8d\xcb\xa4\x85\xca6x%n\x04D(\xf7\x0fX)\x11\x96\xf6\xe9\xde\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00h\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00-foo\x00362fef284ce2ca02aecc8de6d5e8a1c3af0556fe\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1091
  i>     \x00\x00\x00\x00\x00\x00\x00\x07foo\x00\x00\x00b6/\xef(L\xe2\xca\x02\xae\xcc\x8d\xe6\xd5\xe8\xa1\xc3\xaf\x05V\xfe\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00h\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x020\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1092
  i>     \x00\x00\x00\x00\x00\x00\x00\x00
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1093
  i> write(2) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1094
  i>     0\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1095
  i> flush() -> None
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1096
  o> readline() -> 2:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1097
  o>     0\n
36608
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
  1098
  o> read(0) -> 0: 
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
  1099
  o> readline() -> 2:
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
  1100
  o>     1\n
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
  1101
  o> read(1) -> 1: 0
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
  1102
  result: 0
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
  1103
  remote output: 
36534
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1104
  e> read(-1) -> 218:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1105
  e>     adding changesets\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1106
  e>     adding manifests\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1107
  e>     adding file changes\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1108
  e>     added 1 changesets with 1 changes to 1 files\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1109
  e>     ui.write 1\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1110
  e>     ui.write 2\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1111
  e>     print 1\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1112
  e>     print 2\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1113
  e>     transaction abort!\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1114
  e>     rollback completed\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1115
  e>     abort: pretxnchangegroup.fail hook failed\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1116
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1117
print() to stdout and stderr both get captured
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1118
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1119
  $ cat > .hg/hgrc << EOF
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1120
  > [hooks]
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1121
  > pretxnchangegroup.fail = python:$TESTTMP/failhook:hookprintstderrandstdout
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1122
  > EOF
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1123
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1124
  $ debugwireproto << EOF
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1125
  > command unbundle
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1126
  > # This is "force" in hex.
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1127
  >     heads 666f726365
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1128
  >     PUSHFILE ../initial.v1.hg
36608
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
  1129
  > readavailable
36534
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1130
  > EOF
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1131
  testing ssh1
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1132
  creating ssh peer from handshake results
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1133
  i> write(104) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1134
  i>     hello\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1135
  i>     between\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1136
  i>     pairs 81\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1137
  i>     0000000000000000000000000000000000000000-0000000000000000000000000000000000000000
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1138
  i> flush() -> None
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1139
  o> readline() -> 4:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1140
  o>     384\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1141
  o> readline() -> 384:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1142
  o>     capabilities: lookup changegroupsubset branchmap pushkey known getbundle unbundlehash batch streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1143
  o> readline() -> 2:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1144
  o>     1\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1145
  o> readline() -> 1:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1146
  o>     \n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1147
  sending unbundle command
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1148
  i> write(9) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1149
  i>     unbundle\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1150
  i> write(9) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1151
  i>     heads 10\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1152
  i> write(10) -> None: 666f726365
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1153
  i> flush() -> None
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1154
  o> readline() -> 2:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1155
  o>     0\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1156
  i> write(4) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1157
  i>     426\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1158
  i> write(426) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1159
  i>     HG10UN\x00\x00\x00\x9eh\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00h\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00>cba485ca3678256e044428f70f58291196f6e9de\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1160
  i>     test\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1161
  i>     0 0\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1162
  i>     foo\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1163
  i>     \n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1164
  i>     initial\x00\x00\x00\x00\x00\x00\x00\x8d\xcb\xa4\x85\xca6x%n\x04D(\xf7\x0fX)\x11\x96\xf6\xe9\xde\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00h\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00-foo\x00362fef284ce2ca02aecc8de6d5e8a1c3af0556fe\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1165
  i>     \x00\x00\x00\x00\x00\x00\x00\x07foo\x00\x00\x00b6/\xef(L\xe2\xca\x02\xae\xcc\x8d\xe6\xd5\xe8\xa1\xc3\xaf\x05V\xfe\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00h\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x020\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1166
  i>     \x00\x00\x00\x00\x00\x00\x00\x00
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1167
  i> write(2) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1168
  i>     0\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1169
  i> flush() -> None
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1170
  o> readline() -> 2:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1171
  o>     0\n
36608
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
  1172
  o> read(0) -> 0: 
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
  1173
  o> readline() -> 2:
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
  1174
  o>     1\n
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
  1175
  o> read(1) -> 1: 0
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
  1176
  result: 0
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
  1177
  remote output: 
36534
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1178
  e> read(-1) -> 216:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1179
  e>     adding changesets\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1180
  e>     adding manifests\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1181
  e>     adding file changes\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1182
  e>     added 1 changesets with 1 changes to 1 files\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1183
  e>     stderr 1\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1184
  e>     stderr 2\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1185
  e>     stdout 1\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1186
  e>     stdout 2\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1187
  e>     transaction abort!\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1188
  e>     rollback completed\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1189
  e>     abort: pretxnchangegroup.fail hook failed\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1190
  
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1191
  testing ssh2
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1192
  creating ssh peer from handshake results
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1193
  i> write(171) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1194
  i>     upgrade * proto=exp-ssh-v2-0001\n (glob)
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1195
  i>     hello\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1196
  i>     between\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1197
  i>     pairs 81\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1198
  i>     0000000000000000000000000000000000000000-0000000000000000000000000000000000000000
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1199
  i> flush() -> None
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1200
  o> readline() -> 62:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1201
  o>     upgraded * exp-ssh-v2-0001\n (glob)
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1202
  o> readline() -> 4:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1203
  o>     383\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1204
  o> read(383) -> 383: capabilities: lookup changegroupsubset branchmap pushkey known getbundle unbundlehash batch streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1205
  o> read(1) -> 1:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1206
  o>     \n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1207
  sending unbundle command
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1208
  i> write(9) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1209
  i>     unbundle\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1210
  i> write(9) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1211
  i>     heads 10\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1212
  i> write(10) -> None: 666f726365
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1213
  i> flush() -> None
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1214
  o> readline() -> 2:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1215
  o>     0\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1216
  i> write(4) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1217
  i>     426\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1218
  i> write(426) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1219
  i>     HG10UN\x00\x00\x00\x9eh\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00h\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00>cba485ca3678256e044428f70f58291196f6e9de\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1220
  i>     test\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1221
  i>     0 0\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1222
  i>     foo\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1223
  i>     \n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1224
  i>     initial\x00\x00\x00\x00\x00\x00\x00\x8d\xcb\xa4\x85\xca6x%n\x04D(\xf7\x0fX)\x11\x96\xf6\xe9\xde\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00h\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00-foo\x00362fef284ce2ca02aecc8de6d5e8a1c3af0556fe\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1225
  i>     \x00\x00\x00\x00\x00\x00\x00\x07foo\x00\x00\x00b6/\xef(L\xe2\xca\x02\xae\xcc\x8d\xe6\xd5\xe8\xa1\xc3\xaf\x05V\xfe\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00h\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x020\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1226
  i>     \x00\x00\x00\x00\x00\x00\x00\x00
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1227
  i> write(2) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1228
  i>     0\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1229
  i> flush() -> None
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1230
  o> readline() -> 2:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1231
  o>     0\n
36608
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
  1232
  o> read(0) -> 0: 
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
  1233
  o> readline() -> 2:
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
  1234
  o>     1\n
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
  1235
  o> read(1) -> 1: 0
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
  1236
  result: 0
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
  1237
  remote output: 
36534
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1238
  e> read(-1) -> 216:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1239
  e>     adding changesets\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1240
  e>     adding manifests\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1241
  e>     adding file changes\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1242
  e>     added 1 changesets with 1 changes to 1 files\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1243
  e>     stderr 1\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1244
  e>     stderr 2\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1245
  e>     stdout 1\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1246
  e>     stdout 2\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1247
  e>     transaction abort!\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1248
  e>     rollback completed\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1249
  e>     abort: pretxnchangegroup.fail hook failed\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1250
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1251
  $ cd ..
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1252
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1253
Pushing a bundle1 with no output
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1254
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1255
  $ hg init simplerepo
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1256
  $ cd simplerepo
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1257
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1258
  $ debugwireproto 1 << EOF
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1259
  > command unbundle
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1260
  > # This is "force" in hex.
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1261
  >     heads 666f726365
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1262
  >     PUSHFILE ../initial.v1.hg
36608
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
  1263
  > readavailable
36534
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1264
  > EOF
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1265
  testing ssh1
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1266
  creating ssh peer from handshake results
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1267
  i> write(104) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1268
  i>     hello\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1269
  i>     between\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1270
  i>     pairs 81\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1271
  i>     0000000000000000000000000000000000000000-0000000000000000000000000000000000000000
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1272
  i> flush() -> None
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1273
  o> readline() -> 4:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1274
  o>     384\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1275
  o> readline() -> 384:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1276
  o>     capabilities: lookup changegroupsubset branchmap pushkey known getbundle unbundlehash batch streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1277
  o> readline() -> 2:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1278
  o>     1\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1279
  o> readline() -> 1:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1280
  o>     \n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1281
  sending unbundle command
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1282
  i> write(9) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1283
  i>     unbundle\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1284
  i> write(9) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1285
  i>     heads 10\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1286
  i> write(10) -> None: 666f726365
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1287
  i> flush() -> None
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1288
  o> readline() -> 2:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1289
  o>     0\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1290
  i> write(4) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1291
  i>     426\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1292
  i> write(426) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1293
  i>     HG10UN\x00\x00\x00\x9eh\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00h\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00>cba485ca3678256e044428f70f58291196f6e9de\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1294
  i>     test\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1295
  i>     0 0\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1296
  i>     foo\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1297
  i>     \n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1298
  i>     initial\x00\x00\x00\x00\x00\x00\x00\x8d\xcb\xa4\x85\xca6x%n\x04D(\xf7\x0fX)\x11\x96\xf6\xe9\xde\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00h\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00-foo\x00362fef284ce2ca02aecc8de6d5e8a1c3af0556fe\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1299
  i>     \x00\x00\x00\x00\x00\x00\x00\x07foo\x00\x00\x00b6/\xef(L\xe2\xca\x02\xae\xcc\x8d\xe6\xd5\xe8\xa1\xc3\xaf\x05V\xfe\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00h\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x020\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1300
  i>     \x00\x00\x00\x00\x00\x00\x00\x00
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1301
  i> write(2) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1302
  i>     0\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1303
  i> flush() -> None
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1304
  o> readline() -> 2:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1305
  o>     0\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1306
  o> read(0) -> 0: 
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1307
  o> readline() -> 2:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1308
  o>     1\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1309
  o> read(1) -> 1: 1
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1310
  result: 1
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1311
  remote output: 
36608
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
  1312
  e> read(-1) -> 100:
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
  1313
  e>     adding changesets\n
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
  1314
  e>     adding manifests\n
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
  1315
  e>     adding file changes\n
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
  1316
  e>     added 1 changesets with 1 changes to 1 files\n
36534
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1317
  
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1318
  testing ssh2
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1319
  creating ssh peer from handshake results
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1320
  i> write(171) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1321
  i>     upgrade * proto=exp-ssh-v2-0001\n (glob)
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1322
  i>     hello\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1323
  i>     between\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1324
  i>     pairs 81\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1325
  i>     0000000000000000000000000000000000000000-0000000000000000000000000000000000000000
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1326
  i> flush() -> None
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1327
  o> readline() -> 62:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1328
  o>     upgraded * exp-ssh-v2-0001\n (glob)
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1329
  o> readline() -> 4:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1330
  o>     383\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1331
  o> read(383) -> 383: capabilities: lookup changegroupsubset branchmap pushkey known getbundle unbundlehash batch streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1332
  o> read(1) -> 1:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1333
  o>     \n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1334
  sending unbundle command
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1335
  i> write(9) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1336
  i>     unbundle\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1337
  i> write(9) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1338
  i>     heads 10\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1339
  i> write(10) -> None: 666f726365
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1340
  i> flush() -> None
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1341
  o> readline() -> 2:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1342
  o>     0\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1343
  i> write(4) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1344
  i>     426\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1345
  i> write(426) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1346
  i>     HG10UN\x00\x00\x00\x9eh\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00h\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00>cba485ca3678256e044428f70f58291196f6e9de\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1347
  i>     test\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1348
  i>     0 0\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1349
  i>     foo\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1350
  i>     \n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1351
  i>     initial\x00\x00\x00\x00\x00\x00\x00\x8d\xcb\xa4\x85\xca6x%n\x04D(\xf7\x0fX)\x11\x96\xf6\xe9\xde\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00h\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00-foo\x00362fef284ce2ca02aecc8de6d5e8a1c3af0556fe\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1352
  i>     \x00\x00\x00\x00\x00\x00\x00\x07foo\x00\x00\x00b6/\xef(L\xe2\xca\x02\xae\xcc\x8d\xe6\xd5\xe8\xa1\xc3\xaf\x05V\xfe\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00h\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x020\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1353
  i>     \x00\x00\x00\x00\x00\x00\x00\x00
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1354
  i> write(2) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1355
  i>     0\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1356
  i> flush() -> None
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1357
  o> readline() -> 2:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1358
  o>     0\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1359
  o> read(0) -> 0: 
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1360
  o> readline() -> 2:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1361
  o>     1\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1362
  o> read(1) -> 1: 1
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1363
  result: 1
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1364
  remote output: 
36608
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
  1365
  e> read(-1) -> 100:
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
  1366
  e>     adding changesets\n
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
  1367
  e>     adding manifests\n
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
  1368
  e>     adding file changes\n
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
  1369
  e>     added 1 changesets with 1 changes to 1 files\n
36534
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1370
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1371
  $ cd ..
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1372
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1373
Pushing a bundle1 with ui.write() and ui.write_err()
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1374
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1375
  $ cat > $TESTTMP/hook << EOF
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1376
  > def hookuiwrite(ui, repo, **kwargs):
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1377
  >     ui.write('ui.write 1\n')
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1378
  >     ui.write_err('ui.write_err 1\n')
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1379
  >     ui.write('ui.write 2\n')
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1380
  >     ui.write_err('ui.write_err 2\n')
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1381
  > EOF
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1382
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1383
  $ hg init uiwriterepo
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1384
  $ cd uiwriterepo
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1385
  $ cat > .hg/hgrc << EOF
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1386
  > [hooks]
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1387
  > pretxnchangegroup.hook = python:$TESTTMP/hook:hookuiwrite
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1388
  > EOF
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1389
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1390
  $ debugwireproto 1 << EOF
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1391
  > command unbundle
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1392
  > # This is "force" in hex.
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1393
  >     heads 666f726365
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1394
  >     PUSHFILE ../initial.v1.hg
36608
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
  1395
  > readavailable
36534
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1396
  > EOF
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1397
  testing ssh1
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1398
  creating ssh peer from handshake results
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1399
  i> write(104) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1400
  i>     hello\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1401
  i>     between\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1402
  i>     pairs 81\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1403
  i>     0000000000000000000000000000000000000000-0000000000000000000000000000000000000000
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1404
  i> flush() -> None
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1405
  o> readline() -> 4:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1406
  o>     384\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1407
  o> readline() -> 384:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1408
  o>     capabilities: lookup changegroupsubset branchmap pushkey known getbundle unbundlehash batch streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1409
  o> readline() -> 2:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1410
  o>     1\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1411
  o> readline() -> 1:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1412
  o>     \n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1413
  sending unbundle command
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1414
  i> write(9) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1415
  i>     unbundle\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1416
  i> write(9) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1417
  i>     heads 10\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1418
  i> write(10) -> None: 666f726365
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1419
  i> flush() -> None
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1420
  o> readline() -> 2:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1421
  o>     0\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1422
  i> write(4) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1423
  i>     426\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1424
  i> write(426) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1425
  i>     HG10UN\x00\x00\x00\x9eh\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00h\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00>cba485ca3678256e044428f70f58291196f6e9de\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1426
  i>     test\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1427
  i>     0 0\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1428
  i>     foo\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1429
  i>     \n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1430
  i>     initial\x00\x00\x00\x00\x00\x00\x00\x8d\xcb\xa4\x85\xca6x%n\x04D(\xf7\x0fX)\x11\x96\xf6\xe9\xde\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00h\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00-foo\x00362fef284ce2ca02aecc8de6d5e8a1c3af0556fe\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1431
  i>     \x00\x00\x00\x00\x00\x00\x00\x07foo\x00\x00\x00b6/\xef(L\xe2\xca\x02\xae\xcc\x8d\xe6\xd5\xe8\xa1\xc3\xaf\x05V\xfe\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00h\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x020\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1432
  i>     \x00\x00\x00\x00\x00\x00\x00\x00
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1433
  i> write(2) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1434
  i>     0\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1435
  i> flush() -> None
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1436
  o> readline() -> 2:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1437
  o>     0\n
36608
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
  1438
  o> read(0) -> 0: 
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
  1439
  o> readline() -> 2:
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
  1440
  o>     1\n
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
  1441
  o> read(1) -> 1: 1
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
  1442
  result: 1
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
  1443
  remote output: 
36534
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1444
  e> read(-1) -> 152:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1445
  e>     adding changesets\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1446
  e>     adding manifests\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1447
  e>     adding file changes\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1448
  e>     added 1 changesets with 1 changes to 1 files\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1449
  e>     ui.write 1\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1450
  e>     ui.write_err 1\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1451
  e>     ui.write 2\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1452
  e>     ui.write_err 2\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1453
  
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1454
  testing ssh2
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1455
  creating ssh peer from handshake results
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1456
  i> write(171) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1457
  i>     upgrade * proto=exp-ssh-v2-0001\n (glob)
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1458
  i>     hello\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1459
  i>     between\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1460
  i>     pairs 81\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1461
  i>     0000000000000000000000000000000000000000-0000000000000000000000000000000000000000
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1462
  i> flush() -> None
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1463
  o> readline() -> 62:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1464
  o>     upgraded * exp-ssh-v2-0001\n (glob)
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1465
  o> readline() -> 4:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1466
  o>     383\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1467
  o> read(383) -> 383: capabilities: lookup changegroupsubset branchmap pushkey known getbundle unbundlehash batch streamreqs=generaldelta,revlogv1 $USUAL_BUNDLE2_CAPS_SERVER$ unbundle=HG10GZ,HG10BZ,HG10UN
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1468
  o> read(1) -> 1:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1469
  o>     \n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1470
  sending unbundle command
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1471
  i> write(9) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1472
  i>     unbundle\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1473
  i> write(9) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1474
  i>     heads 10\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1475
  i> write(10) -> None: 666f726365
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1476
  i> flush() -> None
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1477
  o> readline() -> 2:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1478
  o>     0\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1479
  i> write(4) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1480
  i>     426\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1481
  i> write(426) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1482
  i>     HG10UN\x00\x00\x00\x9eh\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00h\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00>cba485ca3678256e044428f70f58291196f6e9de\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1483
  i>     test\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1484
  i>     0 0\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1485
  i>     foo\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1486
  i>     \n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1487
  i>     initial\x00\x00\x00\x00\x00\x00\x00\x8d\xcb\xa4\x85\xca6x%n\x04D(\xf7\x0fX)\x11\x96\xf6\xe9\xde\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00h\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00-foo\x00362fef284ce2ca02aecc8de6d5e8a1c3af0556fe\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1488
  i>     \x00\x00\x00\x00\x00\x00\x00\x07foo\x00\x00\x00b6/\xef(L\xe2\xca\x02\xae\xcc\x8d\xe6\xd5\xe8\xa1\xc3\xaf\x05V\xfe\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00h\x98b\x13\xbdD\x85\xeaQS55\xe3\xfc\x9ex\x00zq\x1f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x020\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1489
  i>     \x00\x00\x00\x00\x00\x00\x00\x00
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1490
  i> write(2) -> None:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1491
  i>     0\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1492
  i> flush() -> None
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1493
  o> readline() -> 2:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1494
  o>     0\n
36608
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
  1495
  o> read(0) -> 0: 
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
  1496
  o> readline() -> 2:
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
  1497
  o>     1\n
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
  1498
  o> read(1) -> 1: 1
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
  1499
  result: 1
1151c731686e sshpeer: don't read from stderr when that behavior is disabled
Gregory Szorc <gregory.szorc@gmail.com>
parents: 36534
diff changeset
  1500
  remote output: 
36534
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1501
  e> read(-1) -> 152:
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1502
  e>     adding changesets\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1503
  e>     adding manifests\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1504
  e>     adding file changes\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1505
  e>     added 1 changesets with 1 changes to 1 files\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1506
  e>     ui.write 1\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1507
  e>     ui.write_err 1\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1508
  e>     ui.write 2\n
5faeabb07cf5 debugcommands: support for triggering push protocol
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff changeset
  1509
  e>     ui.write_err 2\n