Mercurial > hg
annotate tests/test-http-protocol.t @ 47043:12450fbea288
manifests: push down expected node length into the parser
This strictly enforces the node length in the manifest lines according
to what the repository expects. One test case moves large hash testing
into the non-treemanifest part as treemanifests don't provide an
interface for overriding just the node length for now.
Differential Revision: https://phab.mercurial-scm.org/D10533
author | Joerg Sonnenberger <joerg@bec.de> |
---|---|
date | Fri, 30 Apr 2021 02:11:58 +0200 |
parents | 1a85c5d75d53 |
children | 04688c51f81f |
rev | line source |
---|---|
38021
538e850ae737
tests: mark tests that fail when using chg as #require no-chg
Kyle Lippincott <spectral@google.com>
parents:
37832
diff
changeset
|
1 #require no-chg |
538e850ae737
tests: mark tests that fail when using chg as #require no-chg
Kyle Lippincott <spectral@google.com>
parents:
37832
diff
changeset
|
2 |
46877
1a85c5d75d53
persistent-nodemap: disable it unconditionally for test-http-protocol.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
46633
diff
changeset
|
3 persistent-nodemap is not enabled by default. It is not relevant for this test |
1a85c5d75d53
persistent-nodemap: disable it unconditionally for test-http-protocol.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
46633
diff
changeset
|
4 so disable it. |
1a85c5d75d53
persistent-nodemap: disable it unconditionally for test-http-protocol.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
46633
diff
changeset
|
5 |
37558
8a73132214a3
httppeer: support protocol upgrade
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37556
diff
changeset
|
6 $ . $TESTDIR/wireprotohelpers.sh |
8a73132214a3
httppeer: support protocol upgrade
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37556
diff
changeset
|
7 |
30762
35b516f800e0
wireproto: advertise supported media types and compression formats
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff
changeset
|
8 $ cat >> $HGRCPATH << EOF |
46877
1a85c5d75d53
persistent-nodemap: disable it unconditionally for test-http-protocol.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
46633
diff
changeset
|
9 > [format] |
1a85c5d75d53
persistent-nodemap: disable it unconditionally for test-http-protocol.t
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
46633
diff
changeset
|
10 > use-persistent-nodemap = no |
30762
35b516f800e0
wireproto: advertise supported media types and compression formats
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff
changeset
|
11 > [web] |
35b516f800e0
wireproto: advertise supported media types and compression formats
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff
changeset
|
12 > push_ssl = false |
35b516f800e0
wireproto: advertise supported media types and compression formats
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff
changeset
|
13 > allow_push = * |
35b516f800e0
wireproto: advertise supported media types and compression formats
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff
changeset
|
14 > EOF |
35b516f800e0
wireproto: advertise supported media types and compression formats
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff
changeset
|
15 |
35b516f800e0
wireproto: advertise supported media types and compression formats
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff
changeset
|
16 $ hg init server |
35b516f800e0
wireproto: advertise supported media types and compression formats
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff
changeset
|
17 $ cd server |
35b516f800e0
wireproto: advertise supported media types and compression formats
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff
changeset
|
18 $ touch a |
35b516f800e0
wireproto: advertise supported media types and compression formats
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff
changeset
|
19 $ hg -q commit -A -m initial |
35b516f800e0
wireproto: advertise supported media types and compression formats
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff
changeset
|
20 $ cd .. |
35b516f800e0
wireproto: advertise supported media types and compression formats
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff
changeset
|
21 |
34483
a6d95a8b7243
serve: make tests compatible with chg
Saurabh Singh <singhsrb@fb.com>
parents:
31008
diff
changeset
|
22 $ hg serve -R server -p $HGPORT -d --pid-file hg.pid |
30762
35b516f800e0
wireproto: advertise supported media types and compression formats
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff
changeset
|
23 $ cat hg.pid >> $DAEMON_PIDS |
35b516f800e0
wireproto: advertise supported media types and compression formats
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff
changeset
|
24 |
35b516f800e0
wireproto: advertise supported media types and compression formats
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff
changeset
|
25 compression formats are advertised in compression capability |
35b516f800e0
wireproto: advertise supported media types and compression formats
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff
changeset
|
26 |
35b516f800e0
wireproto: advertise supported media types and compression formats
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff
changeset
|
27 #if zstd |
31008 | 28 $ get-with-headers.py $LOCALIP:$HGPORT '?cmd=capabilities' | tr ' ' '\n' | grep '^compression=zstd,zlib$' > /dev/null |
30762
35b516f800e0
wireproto: advertise supported media types and compression formats
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff
changeset
|
29 #else |
31008 | 30 $ get-with-headers.py $LOCALIP:$HGPORT '?cmd=capabilities' | tr ' ' '\n' | grep '^compression=zlib$' > /dev/null |
30762
35b516f800e0
wireproto: advertise supported media types and compression formats
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff
changeset
|
31 #endif |
35b516f800e0
wireproto: advertise supported media types and compression formats
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff
changeset
|
32 |
35b516f800e0
wireproto: advertise supported media types and compression formats
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff
changeset
|
33 $ killdaemons.py |
35b516f800e0
wireproto: advertise supported media types and compression formats
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff
changeset
|
34 |
35b516f800e0
wireproto: advertise supported media types and compression formats
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff
changeset
|
35 server.compressionengines can replace engines list wholesale |
35b516f800e0
wireproto: advertise supported media types and compression formats
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff
changeset
|
36 |
34483
a6d95a8b7243
serve: make tests compatible with chg
Saurabh Singh <singhsrb@fb.com>
parents:
31008
diff
changeset
|
37 $ hg serve --config server.compressionengines=none -R server -p $HGPORT -d --pid-file hg.pid |
30762
35b516f800e0
wireproto: advertise supported media types and compression formats
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff
changeset
|
38 $ cat hg.pid > $DAEMON_PIDS |
31008 | 39 $ get-with-headers.py $LOCALIP:$HGPORT '?cmd=capabilities' | tr ' ' '\n' | grep '^compression=none$' > /dev/null |
30762
35b516f800e0
wireproto: advertise supported media types and compression formats
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff
changeset
|
40 |
35b516f800e0
wireproto: advertise supported media types and compression formats
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff
changeset
|
41 $ killdaemons.py |
35b516f800e0
wireproto: advertise supported media types and compression formats
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff
changeset
|
42 |
35b516f800e0
wireproto: advertise supported media types and compression formats
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff
changeset
|
43 Order of engines can also change |
35b516f800e0
wireproto: advertise supported media types and compression formats
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff
changeset
|
44 |
34483
a6d95a8b7243
serve: make tests compatible with chg
Saurabh Singh <singhsrb@fb.com>
parents:
31008
diff
changeset
|
45 $ hg serve --config server.compressionengines=none,zlib -R server -p $HGPORT -d --pid-file hg.pid |
30762
35b516f800e0
wireproto: advertise supported media types and compression formats
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff
changeset
|
46 $ cat hg.pid > $DAEMON_PIDS |
31008 | 47 $ get-with-headers.py $LOCALIP:$HGPORT '?cmd=capabilities' | tr ' ' '\n' | grep '^compression=none,zlib$' > /dev/null |
30762
35b516f800e0
wireproto: advertise supported media types and compression formats
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff
changeset
|
48 |
35b516f800e0
wireproto: advertise supported media types and compression formats
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff
changeset
|
49 $ killdaemons.py |
30764
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
50 |
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
51 Start a default server again |
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
52 |
34483
a6d95a8b7243
serve: make tests compatible with chg
Saurabh Singh <singhsrb@fb.com>
parents:
31008
diff
changeset
|
53 $ hg serve -R server -p $HGPORT -d --pid-file hg.pid |
30764
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
54 $ cat hg.pid > $DAEMON_PIDS |
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
55 |
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
56 Server should send application/mercurial-0.1 to clients if no Accept is used |
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
57 |
31008 | 58 $ get-with-headers.py --headeronly $LOCALIP:$HGPORT '?cmd=getbundle&heads=e93700bd72895c5addab234c56d4024b487a362f&common=0000000000000000000000000000000000000000' - |
30764
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
59 200 Script output follows |
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
60 content-type: application/mercurial-0.1 |
37008
16203c6079e7
tests: use $HTTP_DATE$ for Date header
Gregory Szorc <gregory.szorc@gmail.com>
parents:
34483
diff
changeset
|
61 date: $HTTP_DATE$ |
37009
5890e5872f36
hgweb: allow defining Server response header for HTTP server
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37008
diff
changeset
|
62 server: testing stub value |
30764
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
63 transfer-encoding: chunked |
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
64 |
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
65 Server should send application/mercurial-0.1 when client says it wants it |
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
66 |
31008 | 67 $ get-with-headers.py --hgproto '0.1' --headeronly $LOCALIP:$HGPORT '?cmd=getbundle&heads=e93700bd72895c5addab234c56d4024b487a362f&common=0000000000000000000000000000000000000000' - |
30764
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
68 200 Script output follows |
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
69 content-type: application/mercurial-0.1 |
37008
16203c6079e7
tests: use $HTTP_DATE$ for Date header
Gregory Szorc <gregory.szorc@gmail.com>
parents:
34483
diff
changeset
|
70 date: $HTTP_DATE$ |
37009
5890e5872f36
hgweb: allow defining Server response header for HTTP server
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37008
diff
changeset
|
71 server: testing stub value |
30764
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
72 transfer-encoding: chunked |
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
73 |
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
74 Server should send application/mercurial-0.2 when client says it wants it |
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
75 |
31008 | 76 $ get-with-headers.py --hgproto '0.2' --headeronly $LOCALIP:$HGPORT '?cmd=getbundle&heads=e93700bd72895c5addab234c56d4024b487a362f&common=0000000000000000000000000000000000000000' - |
30764
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
77 200 Script output follows |
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
78 content-type: application/mercurial-0.2 |
37008
16203c6079e7
tests: use $HTTP_DATE$ for Date header
Gregory Szorc <gregory.szorc@gmail.com>
parents:
34483
diff
changeset
|
79 date: $HTTP_DATE$ |
37009
5890e5872f36
hgweb: allow defining Server response header for HTTP server
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37008
diff
changeset
|
80 server: testing stub value |
30764
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
81 transfer-encoding: chunked |
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
82 |
31008 | 83 $ get-with-headers.py --hgproto '0.1 0.2' --headeronly $LOCALIP:$HGPORT '?cmd=getbundle&heads=e93700bd72895c5addab234c56d4024b487a362f&common=0000000000000000000000000000000000000000' - |
30764
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
84 200 Script output follows |
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
85 content-type: application/mercurial-0.2 |
37008
16203c6079e7
tests: use $HTTP_DATE$ for Date header
Gregory Szorc <gregory.szorc@gmail.com>
parents:
34483
diff
changeset
|
86 date: $HTTP_DATE$ |
37009
5890e5872f36
hgweb: allow defining Server response header for HTTP server
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37008
diff
changeset
|
87 server: testing stub value |
30764
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
88 transfer-encoding: chunked |
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
89 |
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
90 Requesting a compression format that server doesn't support results will fall back to 0.1 |
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
91 |
31008 | 92 $ get-with-headers.py --hgproto '0.2 comp=aa' --headeronly $LOCALIP:$HGPORT '?cmd=getbundle&heads=e93700bd72895c5addab234c56d4024b487a362f&common=0000000000000000000000000000000000000000' - |
30764
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
93 200 Script output follows |
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
94 content-type: application/mercurial-0.1 |
37008
16203c6079e7
tests: use $HTTP_DATE$ for Date header
Gregory Szorc <gregory.szorc@gmail.com>
parents:
34483
diff
changeset
|
95 date: $HTTP_DATE$ |
37009
5890e5872f36
hgweb: allow defining Server response header for HTTP server
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37008
diff
changeset
|
96 server: testing stub value |
30764
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
97 transfer-encoding: chunked |
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
98 |
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
99 #if zstd |
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
100 zstd is used if available |
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
101 |
31008 | 102 $ get-with-headers.py --hgproto '0.2 comp=zstd' $LOCALIP:$HGPORT '?cmd=getbundle&heads=e93700bd72895c5addab234c56d4024b487a362f&common=0000000000000000000000000000000000000000' > resp |
30764
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
103 $ f --size --hexdump --bytes 36 --sha1 resp |
42070
675775c33ab6
zstandard: vendor python-zstandard 0.11
Gregory Szorc <gregory.szorc@gmail.com>
parents:
41502
diff
changeset
|
104 resp: size=248, sha1=f11b5c098c638068b3d5fe2f9e6241bf5228 |
30764
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
105 0000: 32 30 30 20 53 63 72 69 70 74 20 6f 75 74 70 75 |200 Script outpu| |
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
106 0010: 74 20 66 6f 6c 6c 6f 77 73 0a 0a 04 7a 73 74 64 |t follows...zstd| |
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
107 0020: 28 b5 2f fd |(./.| |
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
108 |
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
109 #endif |
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
110 |
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
111 application/mercurial-0.2 is not yet used on non-streaming responses |
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
112 |
31008 | 113 $ get-with-headers.py --hgproto '0.2' $LOCALIP:$HGPORT '?cmd=heads' - |
30764
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
114 200 Script output follows |
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
115 content-length: 41 |
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
116 content-type: application/mercurial-0.1 |
37008
16203c6079e7
tests: use $HTTP_DATE$ for Date header
Gregory Szorc <gregory.szorc@gmail.com>
parents:
34483
diff
changeset
|
117 date: $HTTP_DATE$ |
37009
5890e5872f36
hgweb: allow defining Server response header for HTTP server
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37008
diff
changeset
|
118 server: testing stub value |
30764
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
119 |
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
120 e93700bd72895c5addab234c56d4024b487a362f |
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
121 |
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
122 Now test protocol preference usage |
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
123 |
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
124 $ killdaemons.py |
34483
a6d95a8b7243
serve: make tests compatible with chg
Saurabh Singh <singhsrb@fb.com>
parents:
31008
diff
changeset
|
125 $ hg serve --config server.compressionengines=none,zlib -R server -p $HGPORT -d --pid-file hg.pid |
30764
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
126 $ cat hg.pid > $DAEMON_PIDS |
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
127 |
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
128 No Accept will send 0.1+zlib, even though "none" is preferred b/c "none" isn't supported on 0.1 |
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
129 |
31008 | 130 $ get-with-headers.py --headeronly $LOCALIP:$HGPORT '?cmd=getbundle&heads=e93700bd72895c5addab234c56d4024b487a362f&common=0000000000000000000000000000000000000000' Content-Type |
30764
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
131 200 Script output follows |
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
132 content-type: application/mercurial-0.1 |
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
133 |
31008 | 134 $ get-with-headers.py $LOCALIP:$HGPORT '?cmd=getbundle&heads=e93700bd72895c5addab234c56d4024b487a362f&common=0000000000000000000000000000000000000000' > resp |
30764
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
135 $ f --size --hexdump --bytes 28 --sha1 resp |
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
136 resp: size=227, sha1=35a4c074da74f32f5440da3cbf04 |
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
137 0000: 32 30 30 20 53 63 72 69 70 74 20 6f 75 74 70 75 |200 Script outpu| |
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
138 0010: 74 20 66 6f 6c 6c 6f 77 73 0a 0a 78 |t follows..x| |
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
139 |
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
140 Explicit 0.1 will send zlib because "none" isn't supported on 0.1 |
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
141 |
31008 | 142 $ get-with-headers.py --hgproto '0.1' $LOCALIP:$HGPORT '?cmd=getbundle&heads=e93700bd72895c5addab234c56d4024b487a362f&common=0000000000000000000000000000000000000000' > resp |
30764
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
143 $ f --size --hexdump --bytes 28 --sha1 resp |
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
144 resp: size=227, sha1=35a4c074da74f32f5440da3cbf04 |
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
145 0000: 32 30 30 20 53 63 72 69 70 74 20 6f 75 74 70 75 |200 Script outpu| |
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
146 0010: 74 20 66 6f 6c 6c 6f 77 73 0a 0a 78 |t follows..x| |
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
147 |
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
148 0.2 with no compression will get "none" because that is server's preference |
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
149 (spec says ZL and UN are implicitly supported) |
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
150 |
31008 | 151 $ get-with-headers.py --hgproto '0.2' $LOCALIP:$HGPORT '?cmd=getbundle&heads=e93700bd72895c5addab234c56d4024b487a362f&common=0000000000000000000000000000000000000000' > resp |
30764
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
152 $ f --size --hexdump --bytes 32 --sha1 resp |
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
153 resp: size=432, sha1=ac931b412ec185a02e0e5bcff98dac83 |
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
154 0000: 32 30 30 20 53 63 72 69 70 74 20 6f 75 74 70 75 |200 Script outpu| |
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
155 0010: 74 20 66 6f 6c 6c 6f 77 73 0a 0a 04 6e 6f 6e 65 |t follows...none| |
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
156 |
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
157 Client receives server preference even if local order doesn't match |
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
158 |
31008 | 159 $ get-with-headers.py --hgproto '0.2 comp=zlib,none' $LOCALIP:$HGPORT '?cmd=getbundle&heads=e93700bd72895c5addab234c56d4024b487a362f&common=0000000000000000000000000000000000000000' > resp |
30764
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
160 $ f --size --hexdump --bytes 32 --sha1 resp |
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
161 resp: size=432, sha1=ac931b412ec185a02e0e5bcff98dac83 |
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
162 0000: 32 30 30 20 53 63 72 69 70 74 20 6f 75 74 70 75 |200 Script outpu| |
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
163 0010: 74 20 66 6f 6c 6c 6f 77 73 0a 0a 04 6e 6f 6e 65 |t follows...none| |
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
164 |
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
165 Client receives only supported format even if not server preferred format |
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
166 |
31008 | 167 $ get-with-headers.py --hgproto '0.2 comp=zlib' $LOCALIP:$HGPORT '?cmd=getbundle&heads=e93700bd72895c5addab234c56d4024b487a362f&common=0000000000000000000000000000000000000000' > resp |
30764
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
168 $ f --size --hexdump --bytes 33 --sha1 resp |
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
169 resp: size=232, sha1=a1c727f0c9693ca15742a75c30419bc36 |
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
170 0000: 32 30 30 20 53 63 72 69 70 74 20 6f 75 74 70 75 |200 Script outpu| |
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
171 0010: 74 20 66 6f 6c 6c 6f 77 73 0a 0a 04 7a 6c 69 62 |t follows...zlib| |
e75463e3179f
protocol: send application/mercurial-0.2 responses to capable clients
Gregory Szorc <gregory.szorc@gmail.com>
parents:
30762
diff
changeset
|
172 0020: 78 |x| |
37012
fc8939825632
debugcommands: support connecting to HTTP peers
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37009
diff
changeset
|
173 |
fc8939825632
debugcommands: support connecting to HTTP peers
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37009
diff
changeset
|
174 $ killdaemons.py |
fc8939825632
debugcommands: support connecting to HTTP peers
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37009
diff
changeset
|
175 $ cd .. |
fc8939825632
debugcommands: support connecting to HTTP peers
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37009
diff
changeset
|
176 |
fc8939825632
debugcommands: support connecting to HTTP peers
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37009
diff
changeset
|
177 Test listkeys for listing namespaces |
fc8939825632
debugcommands: support connecting to HTTP peers
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37009
diff
changeset
|
178 |
fc8939825632
debugcommands: support connecting to HTTP peers
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37009
diff
changeset
|
179 $ hg init empty |
fc8939825632
debugcommands: support connecting to HTTP peers
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37009
diff
changeset
|
180 $ hg -R empty serve -p $HGPORT -d --pid-file hg.pid |
fc8939825632
debugcommands: support connecting to HTTP peers
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37009
diff
changeset
|
181 $ cat hg.pid > $DAEMON_PIDS |
fc8939825632
debugcommands: support connecting to HTTP peers
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37009
diff
changeset
|
182 |
fc8939825632
debugcommands: support connecting to HTTP peers
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37009
diff
changeset
|
183 $ hg --verbose debugwireproto http://$LOCALIP:$HGPORT << EOF |
fc8939825632
debugcommands: support connecting to HTTP peers
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37009
diff
changeset
|
184 > command listkeys |
fc8939825632
debugcommands: support connecting to HTTP peers
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37009
diff
changeset
|
185 > namespace namespaces |
fc8939825632
debugcommands: support connecting to HTTP peers
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37009
diff
changeset
|
186 > EOF |
41502
2f7408b7d247
tests: give up and make setsockopt() calls optional in the output
Augie Fackler <augie@google.com>
parents:
41383
diff
changeset
|
187 s> setsockopt(6, 1, 1) -> None (?) |
37012
fc8939825632
debugcommands: support connecting to HTTP peers
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37009
diff
changeset
|
188 s> GET /?cmd=capabilities HTTP/1.1\r\n |
fc8939825632
debugcommands: support connecting to HTTP peers
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37009
diff
changeset
|
189 s> Accept-Encoding: identity\r\n |
fc8939825632
debugcommands: support connecting to HTTP peers
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37009
diff
changeset
|
190 s> accept: application/mercurial-0.1\r\n |
fc8939825632
debugcommands: support connecting to HTTP peers
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37009
diff
changeset
|
191 s> host: $LOCALIP:$HGPORT\r\n (glob) |
37483
61e405fb6372
wireproto: crude support for version 2 HTTP peer
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37413
diff
changeset
|
192 s> user-agent: Mercurial debugwireproto\r\n |
37012
fc8939825632
debugcommands: support connecting to HTTP peers
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37009
diff
changeset
|
193 s> \r\n |
fc8939825632
debugcommands: support connecting to HTTP peers
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37009
diff
changeset
|
194 s> makefile('rb', None) |
fc8939825632
debugcommands: support connecting to HTTP peers
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37009
diff
changeset
|
195 s> HTTP/1.1 200 Script output follows\r\n |
fc8939825632
debugcommands: support connecting to HTTP peers
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37009
diff
changeset
|
196 s> Server: testing stub value\r\n |
fc8939825632
debugcommands: support connecting to HTTP peers
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37009
diff
changeset
|
197 s> Date: $HTTP_DATE$\r\n |
fc8939825632
debugcommands: support connecting to HTTP peers
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37009
diff
changeset
|
198 s> Content-Type: application/mercurial-0.1\r\n |
fc8939825632
debugcommands: support connecting to HTTP peers
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37009
diff
changeset
|
199 s> Content-Length: *\r\n (glob) |
fc8939825632
debugcommands: support connecting to HTTP peers
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37009
diff
changeset
|
200 s> \r\n |
40893
4062ba2deb4e
test: enable sparse-revlog for test-http-protocol.t
Boris Feld <boris.feld@octobus.net>
parents:
40391
diff
changeset
|
201 s> batch branchmap $USUAL_BUNDLE2_CAPS$ changegroupsubset compression=$BUNDLE2_COMPRESSIONS$ getbundle httpheader=1024 httpmediatype=0.1rx,0.1tx,0.2tx known lookup pushkey streamreqs=generaldelta,revlogv1,sparserevlog unbundle=HG10GZ,HG10BZ,HG10UN unbundlehash |
37012
fc8939825632
debugcommands: support connecting to HTTP peers
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37009
diff
changeset
|
202 sending listkeys command |
41502
2f7408b7d247
tests: give up and make setsockopt() calls optional in the output
Augie Fackler <augie@google.com>
parents:
41383
diff
changeset
|
203 s> setsockopt(6, 1, 1) -> None (?) |
37012
fc8939825632
debugcommands: support connecting to HTTP peers
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37009
diff
changeset
|
204 s> GET /?cmd=listkeys HTTP/1.1\r\n |
fc8939825632
debugcommands: support connecting to HTTP peers
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37009
diff
changeset
|
205 s> Accept-Encoding: identity\r\n |
fc8939825632
debugcommands: support connecting to HTTP peers
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37009
diff
changeset
|
206 s> vary: X-HgArg-1,X-HgProto-1\r\n |
fc8939825632
debugcommands: support connecting to HTTP peers
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37009
diff
changeset
|
207 s> x-hgarg-1: namespace=namespaces\r\n |
37498
aacfca6f9767
wireproto: support for pullbundles
Joerg Sonnenberger <joerg@bec.de>
parents:
37483
diff
changeset
|
208 s> x-hgproto-1: 0.1 0.2 comp=$USUAL_COMPRESSIONS$ partial-pull\r\n |
37012
fc8939825632
debugcommands: support connecting to HTTP peers
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37009
diff
changeset
|
209 s> accept: application/mercurial-0.1\r\n |
fc8939825632
debugcommands: support connecting to HTTP peers
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37009
diff
changeset
|
210 s> host: $LOCALIP:$HGPORT\r\n (glob) |
37483
61e405fb6372
wireproto: crude support for version 2 HTTP peer
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37413
diff
changeset
|
211 s> user-agent: Mercurial debugwireproto\r\n |
37012
fc8939825632
debugcommands: support connecting to HTTP peers
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37009
diff
changeset
|
212 s> \r\n |
fc8939825632
debugcommands: support connecting to HTTP peers
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37009
diff
changeset
|
213 s> makefile('rb', None) |
fc8939825632
debugcommands: support connecting to HTTP peers
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37009
diff
changeset
|
214 s> HTTP/1.1 200 Script output follows\r\n |
fc8939825632
debugcommands: support connecting to HTTP peers
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37009
diff
changeset
|
215 s> Server: testing stub value\r\n |
fc8939825632
debugcommands: support connecting to HTTP peers
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37009
diff
changeset
|
216 s> Date: $HTTP_DATE$\r\n |
fc8939825632
debugcommands: support connecting to HTTP peers
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37009
diff
changeset
|
217 s> Content-Type: application/mercurial-0.1\r\n |
fc8939825632
debugcommands: support connecting to HTTP peers
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37009
diff
changeset
|
218 s> Content-Length: 30\r\n |
fc8939825632
debugcommands: support connecting to HTTP peers
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37009
diff
changeset
|
219 s> \r\n |
37322
a67fd1fe5109
stringutil: drop escapedata() in favor of escapestr()
Yuya Nishihara <yuya@tcha.org>
parents:
37300
diff
changeset
|
220 s> bookmarks\t\n |
a67fd1fe5109
stringutil: drop escapedata() in favor of escapestr()
Yuya Nishihara <yuya@tcha.org>
parents:
37300
diff
changeset
|
221 s> namespaces\t\n |
a67fd1fe5109
stringutil: drop escapedata() in favor of escapestr()
Yuya Nishihara <yuya@tcha.org>
parents:
37300
diff
changeset
|
222 s> phases\t |
39378
0f549da54379
stringutil: teach pprint() to indent
Gregory Szorc <gregory.szorc@gmail.com>
parents:
38021
diff
changeset
|
223 response: { |
0f549da54379
stringutil: teach pprint() to indent
Gregory Szorc <gregory.szorc@gmail.com>
parents:
38021
diff
changeset
|
224 b'bookmarks': b'', |
0f549da54379
stringutil: teach pprint() to indent
Gregory Szorc <gregory.szorc@gmail.com>
parents:
38021
diff
changeset
|
225 b'namespaces': b'', |
0f549da54379
stringutil: teach pprint() to indent
Gregory Szorc <gregory.szorc@gmail.com>
parents:
38021
diff
changeset
|
226 b'phases': b'' |
0f549da54379
stringutil: teach pprint() to indent
Gregory Szorc <gregory.szorc@gmail.com>
parents:
38021
diff
changeset
|
227 } |
40034
393e44324037
httppeer: report http statistics
Gregory Szorc <gregory.szorc@gmail.com>
parents:
39815
diff
changeset
|
228 (sent 2 HTTP requests and * bytes; received * bytes in responses) (glob) |
37012
fc8939825632
debugcommands: support connecting to HTTP peers
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37009
diff
changeset
|
229 |
37013
b6a7070e7663
debugcommands: support sending HTTP requests with debugwireproto
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37012
diff
changeset
|
230 Same thing, but with "httprequest" command |
b6a7070e7663
debugcommands: support sending HTTP requests with debugwireproto
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37012
diff
changeset
|
231 |
b6a7070e7663
debugcommands: support sending HTTP requests with debugwireproto
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37012
diff
changeset
|
232 $ hg --verbose debugwireproto --peer raw http://$LOCALIP:$HGPORT << EOF |
b6a7070e7663
debugcommands: support sending HTTP requests with debugwireproto
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37012
diff
changeset
|
233 > httprequest GET ?cmd=listkeys |
37045
a708e1e4d7a8
url: support suppressing Accept header
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37044
diff
changeset
|
234 > user-agent: test |
37013
b6a7070e7663
debugcommands: support sending HTTP requests with debugwireproto
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37012
diff
changeset
|
235 > x-hgarg-1: namespace=namespaces |
b6a7070e7663
debugcommands: support sending HTTP requests with debugwireproto
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37012
diff
changeset
|
236 > EOF |
b6a7070e7663
debugcommands: support sending HTTP requests with debugwireproto
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37012
diff
changeset
|
237 using raw connection to peer |
41502
2f7408b7d247
tests: give up and make setsockopt() calls optional in the output
Augie Fackler <augie@google.com>
parents:
41383
diff
changeset
|
238 s> setsockopt(6, 1, 1) -> None (?) |
37013
b6a7070e7663
debugcommands: support sending HTTP requests with debugwireproto
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37012
diff
changeset
|
239 s> GET /?cmd=listkeys HTTP/1.1\r\n |
b6a7070e7663
debugcommands: support sending HTTP requests with debugwireproto
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37012
diff
changeset
|
240 s> Accept-Encoding: identity\r\n |
37045
a708e1e4d7a8
url: support suppressing Accept header
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37044
diff
changeset
|
241 s> user-agent: test\r\n |
37013
b6a7070e7663
debugcommands: support sending HTTP requests with debugwireproto
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37012
diff
changeset
|
242 s> x-hgarg-1: namespace=namespaces\r\n |
b6a7070e7663
debugcommands: support sending HTTP requests with debugwireproto
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37012
diff
changeset
|
243 s> host: $LOCALIP:$HGPORT\r\n (glob) |
b6a7070e7663
debugcommands: support sending HTTP requests with debugwireproto
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37012
diff
changeset
|
244 s> \r\n |
b6a7070e7663
debugcommands: support sending HTTP requests with debugwireproto
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37012
diff
changeset
|
245 s> makefile('rb', None) |
b6a7070e7663
debugcommands: support sending HTTP requests with debugwireproto
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37012
diff
changeset
|
246 s> HTTP/1.1 200 Script output follows\r\n |
b6a7070e7663
debugcommands: support sending HTTP requests with debugwireproto
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37012
diff
changeset
|
247 s> Server: testing stub value\r\n |
b6a7070e7663
debugcommands: support sending HTTP requests with debugwireproto
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37012
diff
changeset
|
248 s> Date: $HTTP_DATE$\r\n |
b6a7070e7663
debugcommands: support sending HTTP requests with debugwireproto
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37012
diff
changeset
|
249 s> Content-Type: application/mercurial-0.1\r\n |
b6a7070e7663
debugcommands: support sending HTTP requests with debugwireproto
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37012
diff
changeset
|
250 s> Content-Length: 30\r\n |
b6a7070e7663
debugcommands: support sending HTTP requests with debugwireproto
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37012
diff
changeset
|
251 s> \r\n |
37322
a67fd1fe5109
stringutil: drop escapedata() in favor of escapestr()
Yuya Nishihara <yuya@tcha.org>
parents:
37300
diff
changeset
|
252 s> bookmarks\t\n |
a67fd1fe5109
stringutil: drop escapedata() in favor of escapestr()
Yuya Nishihara <yuya@tcha.org>
parents:
37300
diff
changeset
|
253 s> namespaces\t\n |
a67fd1fe5109
stringutil: drop escapedata() in favor of escapestr()
Yuya Nishihara <yuya@tcha.org>
parents:
37300
diff
changeset
|
254 s> phases\t |
37013
b6a7070e7663
debugcommands: support sending HTTP requests with debugwireproto
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37012
diff
changeset
|
255 |
37558
8a73132214a3
httppeer: support protocol upgrade
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37556
diff
changeset
|
256 Client with HTTPv2 enabled advertises that and gets old capabilities response from old server |
8a73132214a3
httppeer: support protocol upgrade
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37556
diff
changeset
|
257 |
8a73132214a3
httppeer: support protocol upgrade
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37556
diff
changeset
|
258 $ hg --config experimental.httppeer.advertise-v2=true --verbose debugwireproto http://$LOCALIP:$HGPORT << EOF |
8a73132214a3
httppeer: support protocol upgrade
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37556
diff
changeset
|
259 > command heads |
8a73132214a3
httppeer: support protocol upgrade
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37556
diff
changeset
|
260 > EOF |
41502
2f7408b7d247
tests: give up and make setsockopt() calls optional in the output
Augie Fackler <augie@google.com>
parents:
41383
diff
changeset
|
261 s> setsockopt(6, 1, 1) -> None (?) |
37558
8a73132214a3
httppeer: support protocol upgrade
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37556
diff
changeset
|
262 s> GET /?cmd=capabilities HTTP/1.1\r\n |
8a73132214a3
httppeer: support protocol upgrade
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37556
diff
changeset
|
263 s> Accept-Encoding: identity\r\n |
8a73132214a3
httppeer: support protocol upgrade
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37556
diff
changeset
|
264 s> vary: X-HgProto-1,X-HgUpgrade-1\r\n |
8a73132214a3
httppeer: support protocol upgrade
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37556
diff
changeset
|
265 s> x-hgproto-1: cbor\r\n |
40176
41263df08109
wireprotov2: change how revisions are specified to changesetdata
Gregory Szorc <gregory.szorc@gmail.com>
parents:
40172
diff
changeset
|
266 s> x-hgupgrade-1: exp-http-v2-0003\r\n |
37558
8a73132214a3
httppeer: support protocol upgrade
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37556
diff
changeset
|
267 s> accept: application/mercurial-0.1\r\n |
8a73132214a3
httppeer: support protocol upgrade
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37556
diff
changeset
|
268 s> host: $LOCALIP:$HGPORT\r\n (glob) |
8a73132214a3
httppeer: support protocol upgrade
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37556
diff
changeset
|
269 s> user-agent: Mercurial debugwireproto\r\n |
8a73132214a3
httppeer: support protocol upgrade
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37556
diff
changeset
|
270 s> \r\n |
8a73132214a3
httppeer: support protocol upgrade
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37556
diff
changeset
|
271 s> makefile('rb', None) |
8a73132214a3
httppeer: support protocol upgrade
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37556
diff
changeset
|
272 s> HTTP/1.1 200 Script output follows\r\n |
8a73132214a3
httppeer: support protocol upgrade
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37556
diff
changeset
|
273 s> Server: testing stub value\r\n |
8a73132214a3
httppeer: support protocol upgrade
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37556
diff
changeset
|
274 s> Date: $HTTP_DATE$\r\n |
8a73132214a3
httppeer: support protocol upgrade
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37556
diff
changeset
|
275 s> Content-Type: application/mercurial-0.1\r\n |
37820
143632f82479
tests: glob away content-length changes relating to missing zstd bindings
Augie Fackler <augie@google.com>
parents:
37725
diff
changeset
|
276 s> Content-Length: *\r\n (glob) |
37558
8a73132214a3
httppeer: support protocol upgrade
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37556
diff
changeset
|
277 s> \r\n |
40893
4062ba2deb4e
test: enable sparse-revlog for test-http-protocol.t
Boris Feld <boris.feld@octobus.net>
parents:
40391
diff
changeset
|
278 s> batch branchmap $USUAL_BUNDLE2_CAPS$ changegroupsubset compression=$BUNDLE2_COMPRESSIONS$ getbundle httpheader=1024 httpmediatype=0.1rx,0.1tx,0.2tx known lookup pushkey streamreqs=generaldelta,revlogv1,sparserevlog unbundle=HG10GZ,HG10BZ,HG10UN unbundlehash |
37558
8a73132214a3
httppeer: support protocol upgrade
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37556
diff
changeset
|
279 sending heads command |
41502
2f7408b7d247
tests: give up and make setsockopt() calls optional in the output
Augie Fackler <augie@google.com>
parents:
41383
diff
changeset
|
280 s> setsockopt(6, 1, 1) -> None (?) |
37558
8a73132214a3
httppeer: support protocol upgrade
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37556
diff
changeset
|
281 s> GET /?cmd=heads HTTP/1.1\r\n |
8a73132214a3
httppeer: support protocol upgrade
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37556
diff
changeset
|
282 s> Accept-Encoding: identity\r\n |
8a73132214a3
httppeer: support protocol upgrade
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37556
diff
changeset
|
283 s> vary: X-HgProto-1\r\n |
8a73132214a3
httppeer: support protocol upgrade
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37556
diff
changeset
|
284 s> x-hgproto-1: 0.1 0.2 comp=$USUAL_COMPRESSIONS$ partial-pull\r\n |
8a73132214a3
httppeer: support protocol upgrade
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37556
diff
changeset
|
285 s> accept: application/mercurial-0.1\r\n |
8a73132214a3
httppeer: support protocol upgrade
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37556
diff
changeset
|
286 s> host: $LOCALIP:$HGPORT\r\n (glob) |
8a73132214a3
httppeer: support protocol upgrade
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37556
diff
changeset
|
287 s> user-agent: Mercurial debugwireproto\r\n |
8a73132214a3
httppeer: support protocol upgrade
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37556
diff
changeset
|
288 s> \r\n |
8a73132214a3
httppeer: support protocol upgrade
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37556
diff
changeset
|
289 s> makefile('rb', None) |
8a73132214a3
httppeer: support protocol upgrade
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37556
diff
changeset
|
290 s> HTTP/1.1 200 Script output follows\r\n |
8a73132214a3
httppeer: support protocol upgrade
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37556
diff
changeset
|
291 s> Server: testing stub value\r\n |
8a73132214a3
httppeer: support protocol upgrade
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37556
diff
changeset
|
292 s> Date: $HTTP_DATE$\r\n |
8a73132214a3
httppeer: support protocol upgrade
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37556
diff
changeset
|
293 s> Content-Type: application/mercurial-0.1\r\n |
8a73132214a3
httppeer: support protocol upgrade
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37556
diff
changeset
|
294 s> Content-Length: 41\r\n |
8a73132214a3
httppeer: support protocol upgrade
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37556
diff
changeset
|
295 s> \r\n |
8a73132214a3
httppeer: support protocol upgrade
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37556
diff
changeset
|
296 s> 0000000000000000000000000000000000000000\n |
39378
0f549da54379
stringutil: teach pprint() to indent
Gregory Szorc <gregory.szorc@gmail.com>
parents:
38021
diff
changeset
|
297 response: [ |
0f549da54379
stringutil: teach pprint() to indent
Gregory Szorc <gregory.szorc@gmail.com>
parents:
38021
diff
changeset
|
298 b'\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00' |
0f549da54379
stringutil: teach pprint() to indent
Gregory Szorc <gregory.szorc@gmail.com>
parents:
38021
diff
changeset
|
299 ] |
40034
393e44324037
httppeer: report http statistics
Gregory Szorc <gregory.szorc@gmail.com>
parents:
39815
diff
changeset
|
300 (sent 2 HTTP requests and * bytes; received * bytes in responses) (glob) |
37558
8a73132214a3
httppeer: support protocol upgrade
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37556
diff
changeset
|
301 |
37012
fc8939825632
debugcommands: support connecting to HTTP peers
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37009
diff
changeset
|
302 $ killdaemons.py |
37558
8a73132214a3
httppeer: support protocol upgrade
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37556
diff
changeset
|
303 $ enablehttpv2 empty |
37822
da07c781aba9
tests: explicitly define compression engines for tests
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37820
diff
changeset
|
304 $ hg --config server.compressionengines=zlib -R empty serve -p $HGPORT -d --pid-file hg.pid |
37558
8a73132214a3
httppeer: support protocol upgrade
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37556
diff
changeset
|
305 $ cat hg.pid > $DAEMON_PIDS |
8a73132214a3
httppeer: support protocol upgrade
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37556
diff
changeset
|
306 |
8a73132214a3
httppeer: support protocol upgrade
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37556
diff
changeset
|
307 Client with HTTPv2 enabled automatically upgrades if the server supports it |
8a73132214a3
httppeer: support protocol upgrade
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37556
diff
changeset
|
308 |
40133
762ef19a07e3
wireprotov2: send protocol settings frame from client
Gregory Szorc <gregory.szorc@gmail.com>
parents:
40122
diff
changeset
|
309 $ hg --config experimental.httppeer.advertise-v2=true --config experimental.httppeer.v2-encoder-order=identity --verbose debugwireproto http://$LOCALIP:$HGPORT << EOF |
37558
8a73132214a3
httppeer: support protocol upgrade
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37556
diff
changeset
|
310 > command heads |
8a73132214a3
httppeer: support protocol upgrade
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37556
diff
changeset
|
311 > EOF |
41502
2f7408b7d247
tests: give up and make setsockopt() calls optional in the output
Augie Fackler <augie@google.com>
parents:
41383
diff
changeset
|
312 s> setsockopt(6, 1, 1) -> None (?) |
37558
8a73132214a3
httppeer: support protocol upgrade
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37556
diff
changeset
|
313 s> GET /?cmd=capabilities HTTP/1.1\r\n |
8a73132214a3
httppeer: support protocol upgrade
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37556
diff
changeset
|
314 s> Accept-Encoding: identity\r\n |
8a73132214a3
httppeer: support protocol upgrade
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37556
diff
changeset
|
315 s> vary: X-HgProto-1,X-HgUpgrade-1\r\n |
8a73132214a3
httppeer: support protocol upgrade
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37556
diff
changeset
|
316 s> x-hgproto-1: cbor\r\n |
40176
41263df08109
wireprotov2: change how revisions are specified to changesetdata
Gregory Szorc <gregory.szorc@gmail.com>
parents:
40172
diff
changeset
|
317 s> x-hgupgrade-1: exp-http-v2-0003\r\n |
37558
8a73132214a3
httppeer: support protocol upgrade
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37556
diff
changeset
|
318 s> accept: application/mercurial-0.1\r\n |
8a73132214a3
httppeer: support protocol upgrade
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37556
diff
changeset
|
319 s> host: $LOCALIP:$HGPORT\r\n (glob) |
8a73132214a3
httppeer: support protocol upgrade
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37556
diff
changeset
|
320 s> user-agent: Mercurial debugwireproto\r\n |
8a73132214a3
httppeer: support protocol upgrade
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37556
diff
changeset
|
321 s> \r\n |
8a73132214a3
httppeer: support protocol upgrade
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37556
diff
changeset
|
322 s> makefile('rb', None) |
8a73132214a3
httppeer: support protocol upgrade
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37556
diff
changeset
|
323 s> HTTP/1.1 200 OK\r\n |
8a73132214a3
httppeer: support protocol upgrade
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37556
diff
changeset
|
324 s> Server: testing stub value\r\n |
8a73132214a3
httppeer: support protocol upgrade
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37556
diff
changeset
|
325 s> Date: $HTTP_DATE$\r\n |
8a73132214a3
httppeer: support protocol upgrade
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37556
diff
changeset
|
326 s> Content-Type: application/mercurial-cbor\r\n |
37645
72b0982cd509
debugcommands: perform handshake when obtaining httpv2 peer
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37558
diff
changeset
|
327 s> Content-Length: *\r\n (glob) |
37558
8a73132214a3
httppeer: support protocol upgrade
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37556
diff
changeset
|
328 s> \r\n |
46633
7015b0232c5e
exchange: stop advertising rev-branch-cache bundle capability
Joerg Sonnenberger <joerg@bec.de>
parents:
44412
diff
changeset
|
329 s> \xa3GapibaseDapi/Dapis\xa1Pexp-http-v2-0003\xa4Hcommands\xacIbranchmap\xa2Dargs\xa0Kpermissions\x81DpullLcapabilities\xa2Dargs\xa0Kpermissions\x81DpullMchangesetdata\xa2Dargs\xa2Ffields\xa4Gdefault\xd9\x01\x02\x80Hrequired\xf4DtypeCsetKvalidvalues\xd9\x01\x02\x84IbookmarksGparentsEphaseHrevisionIrevisions\xa2Hrequired\xf5DtypeDlistKpermissions\x81DpullHfiledata\xa2Dargs\xa4Ffields\xa4Gdefault\xd9\x01\x02\x80Hrequired\xf4DtypeCsetKvalidvalues\xd9\x01\x02\x83HlinknodeGparentsHrevisionKhaveparents\xa3Gdefault\xf4Hrequired\xf4DtypeDboolEnodes\xa2Hrequired\xf5DtypeDlistDpath\xa2Hrequired\xf5DtypeEbytesKpermissions\x81DpullIfilesdata\xa3Dargs\xa4Ffields\xa4Gdefault\xd9\x01\x02\x80Hrequired\xf4DtypeCsetKvalidvalues\xd9\x01\x02\x84NfirstchangesetHlinknodeGparentsHrevisionKhaveparents\xa3Gdefault\xf4Hrequired\xf4DtypeDboolJpathfilter\xa3Gdefault\xf6Hrequired\xf4DtypeDdictIrevisions\xa2Hrequired\xf5DtypeDlistKpermissions\x81DpullTrecommendedbatchsize\x19\xc3PEheads\xa2Dargs\xa1Jpubliconly\xa3Gdefault\xf4Hrequired\xf4DtypeDboolKpermissions\x81DpullEknown\xa2Dargs\xa1Enodes\xa3Gdefault\x80Hrequired\xf4DtypeDlistKpermissions\x81DpullHlistkeys\xa2Dargs\xa1Inamespace\xa2Hrequired\xf5DtypeEbytesKpermissions\x81DpullFlookup\xa2Dargs\xa1Ckey\xa2Hrequired\xf5DtypeEbytesKpermissions\x81DpullLmanifestdata\xa3Dargs\xa4Ffields\xa4Gdefault\xd9\x01\x02\x80Hrequired\xf4DtypeCsetKvalidvalues\xd9\x01\x02\x82GparentsHrevisionKhaveparents\xa3Gdefault\xf4Hrequired\xf4DtypeDboolEnodes\xa2Hrequired\xf5DtypeDlistDtree\xa2Hrequired\xf5DtypeEbytesKpermissions\x81DpullTrecommendedbatchsize\x1a\x00\x01\x86\xa0Gpushkey\xa2Dargs\xa4Ckey\xa2Hrequired\xf5DtypeEbytesInamespace\xa2Hrequired\xf5DtypeEbytesCnew\xa2Hrequired\xf5DtypeEbytesCold\xa2Hrequired\xf5DtypeEbytesKpermissions\x81DpushPrawstorefiledata\xa2Dargs\xa2Efiles\xa2Hrequired\xf5DtypeDlistJpathfilter\xa3Gdefault\xf6Hrequired\xf4DtypeDlistKpermissions\x81DpullQframingmediatypes\x81X&application/mercurial-exp-framing-0006Rpathfilterprefixes\xd9\x01\x02\x82Epath:Lrootfilesin:Nrawrepoformats\x83LgeneraldeltaHrevlogv1LsparserevlogNv1capabilitiesY\x01\xe4batch branchmap $USUAL_BUNDLE2_CAPS$ changegroupsubset compression=$BUNDLE2_COMPRESSIONS$ getbundle httpheader=1024 httpmediatype=0.1rx,0.1tx,0.2tx known lookup pushkey streamreqs=generaldelta,revlogv1,sparserevlog unbundle=HG10GZ,HG10BZ,HG10UN unbundlehash |
37558
8a73132214a3
httppeer: support protocol upgrade
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37556
diff
changeset
|
330 sending heads command |
41502
2f7408b7d247
tests: give up and make setsockopt() calls optional in the output
Augie Fackler <augie@google.com>
parents:
41383
diff
changeset
|
331 s> setsockopt(6, 1, 1) -> None (?) |
40176
41263df08109
wireprotov2: change how revisions are specified to changesetdata
Gregory Szorc <gregory.szorc@gmail.com>
parents:
40172
diff
changeset
|
332 s> POST /api/exp-http-v2-0003/ro/heads HTTP/1.1\r\n |
37558
8a73132214a3
httppeer: support protocol upgrade
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37556
diff
changeset
|
333 s> Accept-Encoding: identity\r\n |
40133
762ef19a07e3
wireprotov2: send protocol settings frame from client
Gregory Szorc <gregory.szorc@gmail.com>
parents:
40122
diff
changeset
|
334 s> accept: application/mercurial-exp-framing-0006\r\n |
762ef19a07e3
wireprotov2: send protocol settings frame from client
Gregory Szorc <gregory.szorc@gmail.com>
parents:
40122
diff
changeset
|
335 s> content-type: application/mercurial-exp-framing-0006\r\n |
762ef19a07e3
wireprotov2: send protocol settings frame from client
Gregory Szorc <gregory.szorc@gmail.com>
parents:
40122
diff
changeset
|
336 s> content-length: 56\r\n |
37558
8a73132214a3
httppeer: support protocol upgrade
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37556
diff
changeset
|
337 s> host: $LOCALIP:$HGPORT\r\n (glob) |
8a73132214a3
httppeer: support protocol upgrade
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37556
diff
changeset
|
338 s> user-agent: Mercurial debugwireproto\r\n |
8a73132214a3
httppeer: support protocol upgrade
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37556
diff
changeset
|
339 s> \r\n |
40133
762ef19a07e3
wireprotov2: send protocol settings frame from client
Gregory Szorc <gregory.szorc@gmail.com>
parents:
40122
diff
changeset
|
340 s> \x1c\x00\x00\x01\x00\x01\x01\x82\xa1Pcontentencodings\x81Hidentity\x0c\x00\x00\x01\x00\x01\x00\x11\xa1DnameEheads |
37558
8a73132214a3
httppeer: support protocol upgrade
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37556
diff
changeset
|
341 s> makefile('rb', None) |
8a73132214a3
httppeer: support protocol upgrade
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37556
diff
changeset
|
342 s> HTTP/1.1 200 OK\r\n |
8a73132214a3
httppeer: support protocol upgrade
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37556
diff
changeset
|
343 s> Server: testing stub value\r\n |
8a73132214a3
httppeer: support protocol upgrade
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37556
diff
changeset
|
344 s> Date: $HTTP_DATE$\r\n |
40133
762ef19a07e3
wireprotov2: send protocol settings frame from client
Gregory Szorc <gregory.szorc@gmail.com>
parents:
40122
diff
changeset
|
345 s> Content-Type: application/mercurial-exp-framing-0006\r\n |
37558
8a73132214a3
httppeer: support protocol upgrade
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37556
diff
changeset
|
346 s> Transfer-Encoding: chunked\r\n |
8a73132214a3
httppeer: support protocol upgrade
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37556
diff
changeset
|
347 s> \r\n |
40138
b5bf3dd6ec5b
wireprotov2: send content encoded frames from server
Gregory Szorc <gregory.szorc@gmail.com>
parents:
40133
diff
changeset
|
348 s> 11\r\n |
b5bf3dd6ec5b
wireprotov2: send content encoded frames from server
Gregory Szorc <gregory.szorc@gmail.com>
parents:
40133
diff
changeset
|
349 s> \t\x00\x00\x01\x00\x02\x01\x92 |
b5bf3dd6ec5b
wireprotov2: send content encoded frames from server
Gregory Szorc <gregory.szorc@gmail.com>
parents:
40133
diff
changeset
|
350 s> Hidentity |
b5bf3dd6ec5b
wireprotov2: send content encoded frames from server
Gregory Szorc <gregory.szorc@gmail.com>
parents:
40133
diff
changeset
|
351 s> \r\n |
39559
07b58266bce3
wireprotov2: implement commands as a generator of objects
Gregory Szorc <gregory.szorc@gmail.com>
parents:
39447
diff
changeset
|
352 s> 13\r\n |
40138
b5bf3dd6ec5b
wireprotov2: send content encoded frames from server
Gregory Szorc <gregory.szorc@gmail.com>
parents:
40133
diff
changeset
|
353 s> \x0b\x00\x00\x01\x00\x02\x041 |
39559
07b58266bce3
wireprotov2: implement commands as a generator of objects
Gregory Szorc <gregory.szorc@gmail.com>
parents:
39447
diff
changeset
|
354 s> \xa1FstatusBok |
37558
8a73132214a3
httppeer: support protocol upgrade
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37556
diff
changeset
|
355 s> \r\n |
39559
07b58266bce3
wireprotov2: implement commands as a generator of objects
Gregory Szorc <gregory.szorc@gmail.com>
parents:
39447
diff
changeset
|
356 s> 1e\r\n |
40138
b5bf3dd6ec5b
wireprotov2: send content encoded frames from server
Gregory Szorc <gregory.szorc@gmail.com>
parents:
40133
diff
changeset
|
357 s> \x16\x00\x00\x01\x00\x02\x041 |
39559
07b58266bce3
wireprotov2: implement commands as a generator of objects
Gregory Szorc <gregory.szorc@gmail.com>
parents:
39447
diff
changeset
|
358 s> \x81T\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00 |
07b58266bce3
wireprotov2: implement commands as a generator of objects
Gregory Szorc <gregory.szorc@gmail.com>
parents:
39447
diff
changeset
|
359 s> \r\n |
07b58266bce3
wireprotov2: implement commands as a generator of objects
Gregory Szorc <gregory.szorc@gmail.com>
parents:
39447
diff
changeset
|
360 s> 8\r\n |
07b58266bce3
wireprotov2: implement commands as a generator of objects
Gregory Szorc <gregory.szorc@gmail.com>
parents:
39447
diff
changeset
|
361 s> \x00\x00\x00\x01\x00\x02\x002 |
07b58266bce3
wireprotov2: implement commands as a generator of objects
Gregory Szorc <gregory.szorc@gmail.com>
parents:
39447
diff
changeset
|
362 s> \r\n |
37558
8a73132214a3
httppeer: support protocol upgrade
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37556
diff
changeset
|
363 s> 0\r\n |
8a73132214a3
httppeer: support protocol upgrade
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37556
diff
changeset
|
364 s> \r\n |
39378
0f549da54379
stringutil: teach pprint() to indent
Gregory Szorc <gregory.szorc@gmail.com>
parents:
38021
diff
changeset
|
365 response: [ |
0f549da54379
stringutil: teach pprint() to indent
Gregory Szorc <gregory.szorc@gmail.com>
parents:
38021
diff
changeset
|
366 b'\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00' |
0f549da54379
stringutil: teach pprint() to indent
Gregory Szorc <gregory.szorc@gmail.com>
parents:
38021
diff
changeset
|
367 ] |
40034
393e44324037
httppeer: report http statistics
Gregory Szorc <gregory.szorc@gmail.com>
parents:
39815
diff
changeset
|
368 (sent 2 HTTP requests and * bytes; received * bytes in responses) (glob) |
37558
8a73132214a3
httppeer: support protocol upgrade
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37556
diff
changeset
|
369 |
8a73132214a3
httppeer: support protocol upgrade
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37556
diff
changeset
|
370 $ killdaemons.py |
37832
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
371 |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
372 HTTP client follows HTTP redirect on handshake to new repo |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
373 |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
374 $ cd $TESTTMP |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
375 |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
376 $ hg init redirector |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
377 $ hg init redirected |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
378 $ cd redirected |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
379 $ touch foo |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
380 $ hg -q commit -A -m initial |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
381 $ cd .. |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
382 |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
383 $ cat > paths.conf << EOF |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
384 > [paths] |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
385 > / = $TESTTMP/* |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
386 > EOF |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
387 |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
388 $ cat > redirectext.py << EOF |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
389 > from mercurial import extensions, wireprotoserver |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
390 > def wrappedcallhttp(orig, repo, req, res, proto, cmd): |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
391 > path = req.advertisedurl[len(req.advertisedbaseurl):] |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
392 > if not path.startswith(b'/redirector'): |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
393 > return orig(repo, req, res, proto, cmd) |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
394 > relpath = path[len(b'/redirector'):] |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
395 > res.status = b'301 Redirect' |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
396 > newurl = b'%s/redirected%s' % (req.baseurl, relpath) |
41383
0cfbe78fc13e
tests: add b'' prefixes to ui.configbool() call
Gregory Szorc <gregory.szorc@gmail.com>
parents:
41380
diff
changeset
|
397 > if not repo.ui.configbool(b'testing', b'redirectqs', True) and b'?' in newurl: |
37832
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
398 > newurl = newurl[0:newurl.index(b'?')] |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
399 > res.headers[b'Location'] = newurl |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
400 > res.headers[b'Content-Type'] = b'text/plain' |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
401 > res.setbodybytes(b'redirected') |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
402 > return True |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
403 > |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
404 > extensions.wrapfunction(wireprotoserver, '_callhttp', wrappedcallhttp) |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
405 > EOF |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
406 |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
407 $ hg --config extensions.redirect=$TESTTMP/redirectext.py \ |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
408 > --config server.compressionengines=zlib \ |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
409 > serve --web-conf paths.conf --pid-file hg.pid -p $HGPORT -d |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
410 $ cat hg.pid > $DAEMON_PIDS |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
411 |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
412 Verify our HTTP 301 is served properly |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
413 |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
414 $ hg --verbose debugwireproto --peer raw http://$LOCALIP:$HGPORT << EOF |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
415 > httprequest GET /redirector?cmd=capabilities |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
416 > user-agent: test |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
417 > EOF |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
418 using raw connection to peer |
41502
2f7408b7d247
tests: give up and make setsockopt() calls optional in the output
Augie Fackler <augie@google.com>
parents:
41383
diff
changeset
|
419 s> setsockopt(6, 1, 1) -> None (?) |
37832
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
420 s> GET /redirector?cmd=capabilities HTTP/1.1\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
421 s> Accept-Encoding: identity\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
422 s> user-agent: test\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
423 s> host: $LOCALIP:$HGPORT\r\n (glob) |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
424 s> \r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
425 s> makefile('rb', None) |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
426 s> HTTP/1.1 301 Redirect\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
427 s> Server: testing stub value\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
428 s> Date: $HTTP_DATE$\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
429 s> Location: http://$LOCALIP:$HGPORT/redirected?cmd=capabilities\r\n (glob) |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
430 s> Content-Type: text/plain\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
431 s> Content-Length: 10\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
432 s> \r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
433 s> redirected |
41502
2f7408b7d247
tests: give up and make setsockopt() calls optional in the output
Augie Fackler <augie@google.com>
parents:
41383
diff
changeset
|
434 s> setsockopt(6, 1, 1) -> None (?) |
37832
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
435 s> GET /redirected?cmd=capabilities HTTP/1.1\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
436 s> Accept-Encoding: identity\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
437 s> user-agent: test\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
438 s> host: $LOCALIP:$HGPORT\r\n (glob) |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
439 s> \r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
440 s> makefile('rb', None) |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
441 s> HTTP/1.1 200 Script output follows\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
442 s> Server: testing stub value\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
443 s> Date: $HTTP_DATE$\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
444 s> Content-Type: application/mercurial-0.1\r\n |
46633
7015b0232c5e
exchange: stop advertising rev-branch-cache bundle capability
Joerg Sonnenberger <joerg@bec.de>
parents:
44412
diff
changeset
|
445 s> Content-Length: 484\r\n |
37832
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
446 s> \r\n |
40893
4062ba2deb4e
test: enable sparse-revlog for test-http-protocol.t
Boris Feld <boris.feld@octobus.net>
parents:
40391
diff
changeset
|
447 s> batch branchmap $USUAL_BUNDLE2_CAPS$ changegroupsubset compression=$BUNDLE2_COMPRESSIONS$ getbundle httpheader=1024 httpmediatype=0.1rx,0.1tx,0.2tx known lookup pushkey streamreqs=generaldelta,revlogv1,sparserevlog unbundle=HG10GZ,HG10BZ,HG10UN unbundlehash |
37832
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
448 |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
449 Test with the HTTP peer |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
450 |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
451 $ hg --verbose debugwireproto http://$LOCALIP:$HGPORT/redirector << EOF |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
452 > command heads |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
453 > EOF |
41502
2f7408b7d247
tests: give up and make setsockopt() calls optional in the output
Augie Fackler <augie@google.com>
parents:
41383
diff
changeset
|
454 s> setsockopt(6, 1, 1) -> None (?) |
37832
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
455 s> GET /redirector?cmd=capabilities HTTP/1.1\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
456 s> Accept-Encoding: identity\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
457 s> accept: application/mercurial-0.1\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
458 s> host: $LOCALIP:$HGPORT\r\n (glob) |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
459 s> user-agent: Mercurial debugwireproto\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
460 s> \r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
461 s> makefile('rb', None) |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
462 s> HTTP/1.1 301 Redirect\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
463 s> Server: testing stub value\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
464 s> Date: $HTTP_DATE$\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
465 s> Location: http://$LOCALIP:$HGPORT/redirected?cmd=capabilities\r\n (glob) |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
466 s> Content-Type: text/plain\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
467 s> Content-Length: 10\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
468 s> \r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
469 s> redirected |
41502
2f7408b7d247
tests: give up and make setsockopt() calls optional in the output
Augie Fackler <augie@google.com>
parents:
41383
diff
changeset
|
470 s> setsockopt(6, 1, 1) -> None (?) |
37832
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
471 s> GET /redirected?cmd=capabilities HTTP/1.1\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
472 s> Accept-Encoding: identity\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
473 s> accept: application/mercurial-0.1\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
474 s> host: $LOCALIP:$HGPORT\r\n (glob) |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
475 s> user-agent: Mercurial debugwireproto\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
476 s> \r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
477 s> makefile('rb', None) |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
478 s> HTTP/1.1 200 Script output follows\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
479 s> Server: testing stub value\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
480 s> Date: $HTTP_DATE$\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
481 s> Content-Type: application/mercurial-0.1\r\n |
46633
7015b0232c5e
exchange: stop advertising rev-branch-cache bundle capability
Joerg Sonnenberger <joerg@bec.de>
parents:
44412
diff
changeset
|
482 s> Content-Length: 484\r\n |
37832
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
483 s> \r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
484 real URL is http://$LOCALIP:$HGPORT/redirected (glob) |
40893
4062ba2deb4e
test: enable sparse-revlog for test-http-protocol.t
Boris Feld <boris.feld@octobus.net>
parents:
40391
diff
changeset
|
485 s> batch branchmap $USUAL_BUNDLE2_CAPS$ changegroupsubset compression=$BUNDLE2_COMPRESSIONS$ getbundle httpheader=1024 httpmediatype=0.1rx,0.1tx,0.2tx known lookup pushkey streamreqs=generaldelta,revlogv1,sparserevlog unbundle=HG10GZ,HG10BZ,HG10UN unbundlehash |
37832
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
486 sending heads command |
41502
2f7408b7d247
tests: give up and make setsockopt() calls optional in the output
Augie Fackler <augie@google.com>
parents:
41383
diff
changeset
|
487 s> setsockopt(6, 1, 1) -> None (?) |
37832
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
488 s> GET /redirected?cmd=heads HTTP/1.1\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
489 s> Accept-Encoding: identity\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
490 s> vary: X-HgProto-1\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
491 s> x-hgproto-1: 0.1 0.2 comp=$USUAL_COMPRESSIONS$ partial-pull\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
492 s> accept: application/mercurial-0.1\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
493 s> host: $LOCALIP:$HGPORT\r\n (glob) |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
494 s> user-agent: Mercurial debugwireproto\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
495 s> \r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
496 s> makefile('rb', None) |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
497 s> HTTP/1.1 200 Script output follows\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
498 s> Server: testing stub value\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
499 s> Date: $HTTP_DATE$\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
500 s> Content-Type: application/mercurial-0.1\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
501 s> Content-Length: 41\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
502 s> \r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
503 s> 96ee1d7354c4ad7372047672c36a1f561e3a6a4c\n |
39378
0f549da54379
stringutil: teach pprint() to indent
Gregory Szorc <gregory.szorc@gmail.com>
parents:
38021
diff
changeset
|
504 response: [ |
0f549da54379
stringutil: teach pprint() to indent
Gregory Szorc <gregory.szorc@gmail.com>
parents:
38021
diff
changeset
|
505 b'\x96\xee\x1dsT\xc4\xadsr\x04vr\xc3j\x1fV\x1e:jL' |
0f549da54379
stringutil: teach pprint() to indent
Gregory Szorc <gregory.szorc@gmail.com>
parents:
38021
diff
changeset
|
506 ] |
40034
393e44324037
httppeer: report http statistics
Gregory Szorc <gregory.szorc@gmail.com>
parents:
39815
diff
changeset
|
507 (sent 3 HTTP requests and * bytes; received * bytes in responses) (glob) |
37832
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
508 |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
509 $ killdaemons.py |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
510 |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
511 Now test a variation where we strip the query string from the redirect URL. |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
512 (SCM Manager apparently did this and clients would recover from it) |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
513 |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
514 $ hg --config extensions.redirect=$TESTTMP/redirectext.py \ |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
515 > --config server.compressionengines=zlib \ |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
516 > --config testing.redirectqs=false \ |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
517 > serve --web-conf paths.conf --pid-file hg.pid -p $HGPORT -d |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
518 $ cat hg.pid > $DAEMON_PIDS |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
519 |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
520 $ hg --verbose debugwireproto --peer raw http://$LOCALIP:$HGPORT << EOF |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
521 > httprequest GET /redirector?cmd=capabilities |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
522 > user-agent: test |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
523 > EOF |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
524 using raw connection to peer |
41502
2f7408b7d247
tests: give up and make setsockopt() calls optional in the output
Augie Fackler <augie@google.com>
parents:
41383
diff
changeset
|
525 s> setsockopt(6, 1, 1) -> None (?) |
37832
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
526 s> GET /redirector?cmd=capabilities HTTP/1.1\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
527 s> Accept-Encoding: identity\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
528 s> user-agent: test\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
529 s> host: $LOCALIP:$HGPORT\r\n (glob) |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
530 s> \r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
531 s> makefile('rb', None) |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
532 s> HTTP/1.1 301 Redirect\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
533 s> Server: testing stub value\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
534 s> Date: $HTTP_DATE$\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
535 s> Location: http://$LOCALIP:$HGPORT/redirected\r\n (glob) |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
536 s> Content-Type: text/plain\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
537 s> Content-Length: 10\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
538 s> \r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
539 s> redirected |
41502
2f7408b7d247
tests: give up and make setsockopt() calls optional in the output
Augie Fackler <augie@google.com>
parents:
41383
diff
changeset
|
540 s> setsockopt(6, 1, 1) -> None (?) |
37832
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
541 s> GET /redirected HTTP/1.1\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
542 s> Accept-Encoding: identity\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
543 s> user-agent: test\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
544 s> host: $LOCALIP:$HGPORT\r\n (glob) |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
545 s> \r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
546 s> makefile('rb', None) |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
547 s> HTTP/1.1 200 Script output follows\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
548 s> Server: testing stub value\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
549 s> Date: $HTTP_DATE$\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
550 s> ETag: W/"*"\r\n (glob) |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
551 s> Content-Type: text/html; charset=ascii\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
552 s> Transfer-Encoding: chunked\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
553 s> \r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
554 s> 414\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
555 s> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
556 s> <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en-US">\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
557 s> <head>\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
558 s> <link rel="icon" href="/redirected/static/hgicon.png" type="image/png" />\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
559 s> <meta name="robots" content="index, nofollow" />\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
560 s> <link rel="stylesheet" href="/redirected/static/style-paper.css" type="text/css" />\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
561 s> <script type="text/javascript" src="/redirected/static/mercurial.js"></script>\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
562 s> \n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
563 s> <title>redirected: log</title>\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
564 s> <link rel="alternate" type="application/atom+xml"\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
565 s> href="/redirected/atom-log" title="Atom feed for redirected" />\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
566 s> <link rel="alternate" type="application/rss+xml"\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
567 s> href="/redirected/rss-log" title="RSS feed for redirected" />\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
568 s> </head>\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
569 s> <body>\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
570 s> \n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
571 s> <div class="container">\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
572 s> <div class="menu">\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
573 s> <div class="logo">\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
574 s> <a href="https://mercurial-scm.org/">\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
575 s> <img src="/redirected/static/hglogo.png" alt="mercurial" /></a>\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
576 s> </div>\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
577 s> <ul>\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
578 s> <li class="active">log</li>\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
579 s> <li><a href="/redirected/graph/tip">graph</a></li>\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
580 s> <li><a href="/redirected/tags">tags</a></li>\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
581 s> <li><a href=" |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
582 s> \r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
583 s> 810\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
584 s> /redirected/bookmarks">bookmarks</a></li>\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
585 s> <li><a href="/redirected/branches">branches</a></li>\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
586 s> </ul>\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
587 s> <ul>\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
588 s> <li><a href="/redirected/rev/tip">changeset</a></li>\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
589 s> <li><a href="/redirected/file/tip">browse</a></li>\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
590 s> </ul>\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
591 s> <ul>\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
592 s> \n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
593 s> </ul>\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
594 s> <ul>\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
595 s> <li><a href="/redirected/help">help</a></li>\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
596 s> </ul>\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
597 s> <div class="atom-logo">\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
598 s> <a href="/redirected/atom-log" title="subscribe to atom feed">\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
599 s> <img class="atom-logo" src="/redirected/static/feed-icon-14x14.png" alt="atom feed" />\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
600 s> </a>\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
601 s> </div>\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
602 s> </div>\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
603 s> \n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
604 s> <div class="main">\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
605 s> <h2 class="breadcrumb"><a href="/">Mercurial</a> > <a href="/redirected">redirected</a> </h2>\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
606 s> <h3>log</h3>\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
607 s> \n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
608 s> \n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
609 s> <form class="search" action="/redirected/log">\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
610 s> \n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
611 s> <p><input name="rev" id="search1" type="text" size="30" value="" /></p>\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
612 s> <div id="hint">Find changesets by keywords (author, files, the commit message), revision\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
613 s> number or hash, or <a href="/redirected/help/revsets">revset expression</a>.</div>\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
614 s> </form>\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
615 s> \n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
616 s> <div class="navigate">\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
617 s> <a href="/redirected/shortlog/tip?revcount=30">less</a>\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
618 s> <a href="/redirected/shortlog/tip?revcount=120">more</a>\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
619 s> | rev 0: <a href="/redirected/shortlog/96ee1d7354c4">(0)</a> <a href="/redirected/shortlog/tip">tip</a> \n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
620 s> </div>\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
621 s> \n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
622 s> <table class="bigtable">\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
623 s> <thead>\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
624 s> <tr>\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
625 s> <th class="age">age</th>\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
626 s> <th class="author">author</th>\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
627 s> <th class="description">description</th>\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
628 s> </tr>\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
629 s> </thead>\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
630 s> <tbody class="stripes2">\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
631 s> <tr>\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
632 s> <td class="age">Thu, 01 Jan 1970 00:00:00 +0000</td>\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
633 s> <td class="author">test</td>\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
634 s> <td class="description">\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
635 s> <a href="/redirected/rev/96ee1d7354c4">initial</a>\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
636 s> <span class="phase">draft</span> <span class="branchhead">default</span> <span class="tag">tip</span> \n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
637 s> </td>\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
638 s> </tr>\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
639 s> \n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
640 s> </tbody>\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
641 s> </table>\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
642 s> \n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
643 s> <div class="navigate">\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
644 s> <a href="/redirected/shortlog/tip?revcount=30">less</a>\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
645 s> <a href="/redirected/shortlog/tip?revcount=120">more</a>\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
646 s> | rev 0: <a href="/redirected/shortlog/96ee1d7354c4">(0)</a> <a href="/redirected/shortlog/tip">tip</a> \n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
647 s> </div>\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
648 s> \n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
649 s> <script type="text/javascript">\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
650 s> ajaxScrollInit(\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
651 s> \'/redirected/shortlog/%next%\',\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
652 s> \'\', <!-- NEXTHASH\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
653 s> function (htmlText) { |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
654 s> \r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
655 s> 14a\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
656 s> \n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
657 s> var m = htmlText.match(/\'(\\w+)\', <!-- NEXTHASH/);\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
658 s> return m ? m[1] : null;\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
659 s> },\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
660 s> \'.bigtable > tbody\',\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
661 s> \'<tr class="%class%">\\\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
662 s> <td colspan="3" style="text-align: center;">%text%</td>\\\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
663 s> </tr>\'\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
664 s> );\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
665 s> </script>\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
666 s> \n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
667 s> </div>\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
668 s> </div>\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
669 s> \n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
670 s> \n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
671 s> \n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
672 s> </body>\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
673 s> </html>\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
674 s> \n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
675 s> \r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
676 s> 0\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
677 s> \r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
678 |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
679 $ hg --verbose debugwireproto http://$LOCALIP:$HGPORT/redirector << EOF |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
680 > command heads |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
681 > EOF |
41502
2f7408b7d247
tests: give up and make setsockopt() calls optional in the output
Augie Fackler <augie@google.com>
parents:
41383
diff
changeset
|
682 s> setsockopt(6, 1, 1) -> None (?) |
37832
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
683 s> GET /redirector?cmd=capabilities HTTP/1.1\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
684 s> Accept-Encoding: identity\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
685 s> accept: application/mercurial-0.1\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
686 s> host: $LOCALIP:$HGPORT\r\n (glob) |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
687 s> user-agent: Mercurial debugwireproto\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
688 s> \r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
689 s> makefile('rb', None) |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
690 s> HTTP/1.1 301 Redirect\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
691 s> Server: testing stub value\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
692 s> Date: $HTTP_DATE$\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
693 s> Location: http://$LOCALIP:$HGPORT/redirected\r\n (glob) |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
694 s> Content-Type: text/plain\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
695 s> Content-Length: 10\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
696 s> \r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
697 s> redirected |
41502
2f7408b7d247
tests: give up and make setsockopt() calls optional in the output
Augie Fackler <augie@google.com>
parents:
41383
diff
changeset
|
698 s> setsockopt(6, 1, 1) -> None (?) |
37832
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
699 s> GET /redirected HTTP/1.1\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
700 s> Accept-Encoding: identity\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
701 s> accept: application/mercurial-0.1\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
702 s> host: $LOCALIP:$HGPORT\r\n (glob) |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
703 s> user-agent: Mercurial debugwireproto\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
704 s> \r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
705 s> makefile('rb', None) |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
706 s> HTTP/1.1 200 Script output follows\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
707 s> Server: testing stub value\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
708 s> Date: $HTTP_DATE$\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
709 s> ETag: W/"*"\r\n (glob) |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
710 s> Content-Type: text/html; charset=ascii\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
711 s> Transfer-Encoding: chunked\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
712 s> \r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
713 real URL is http://$LOCALIP:$HGPORT/redirected (glob) |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
714 s> 414\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
715 s> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
716 s> <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en-US">\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
717 s> <head>\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
718 s> <link rel="icon" href="/redirected/static/hgicon.png" type="image/png" />\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
719 s> <meta name="robots" content="index, nofollow" />\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
720 s> <link rel="stylesheet" href="/redirected/static/style-paper.css" type="text/css" />\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
721 s> <script type="text/javascript" src="/redirected/static/mercurial.js"></script>\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
722 s> \n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
723 s> <title>redirected: log</title>\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
724 s> <link rel="alternate" type="application/atom+xml"\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
725 s> href="/redirected/atom-log" title="Atom feed for redirected" />\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
726 s> <link rel="alternate" type="application/rss+xml"\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
727 s> href="/redirected/rss-log" title="RSS feed for redirected" />\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
728 s> </head>\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
729 s> <body>\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
730 s> \n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
731 s> <div class="container">\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
732 s> <div class="menu">\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
733 s> <div class="logo">\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
734 s> <a href="https://mercurial-scm.org/">\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
735 s> <img src="/redirected/static/hglogo.png" alt="mercurial" /></a>\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
736 s> </div>\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
737 s> <ul>\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
738 s> <li class="active">log</li>\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
739 s> <li><a href="/redirected/graph/tip">graph</a></li>\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
740 s> <li><a href="/redirected/tags">tags</a |
41502
2f7408b7d247
tests: give up and make setsockopt() calls optional in the output
Augie Fackler <augie@google.com>
parents:
41383
diff
changeset
|
741 s> setsockopt(6, 1, 1) -> None (?) |
37832
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
742 s> GET /redirected?cmd=capabilities HTTP/1.1\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
743 s> Accept-Encoding: identity\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
744 s> accept: application/mercurial-0.1\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
745 s> host: $LOCALIP:$HGPORT\r\n (glob) |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
746 s> user-agent: Mercurial debugwireproto\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
747 s> \r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
748 s> makefile('rb', None) |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
749 s> HTTP/1.1 200 Script output follows\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
750 s> Server: testing stub value\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
751 s> Date: $HTTP_DATE$\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
752 s> Content-Type: application/mercurial-0.1\r\n |
46633
7015b0232c5e
exchange: stop advertising rev-branch-cache bundle capability
Joerg Sonnenberger <joerg@bec.de>
parents:
44412
diff
changeset
|
753 s> Content-Length: 484\r\n |
37832
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
754 s> \r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
755 real URL is http://$LOCALIP:$HGPORT/redirected (glob) |
40893
4062ba2deb4e
test: enable sparse-revlog for test-http-protocol.t
Boris Feld <boris.feld@octobus.net>
parents:
40391
diff
changeset
|
756 s> batch branchmap $USUAL_BUNDLE2_CAPS$ changegroupsubset compression=$BUNDLE2_COMPRESSIONS$ getbundle httpheader=1024 httpmediatype=0.1rx,0.1tx,0.2tx known lookup pushkey streamreqs=generaldelta,revlogv1,sparserevlog unbundle=HG10GZ,HG10BZ,HG10UN unbundlehash |
37832
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
757 sending heads command |
41502
2f7408b7d247
tests: give up and make setsockopt() calls optional in the output
Augie Fackler <augie@google.com>
parents:
41383
diff
changeset
|
758 s> setsockopt(6, 1, 1) -> None (?) |
37832
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
759 s> GET /redirected?cmd=heads HTTP/1.1\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
760 s> Accept-Encoding: identity\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
761 s> vary: X-HgProto-1\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
762 s> x-hgproto-1: 0.1 0.2 comp=$USUAL_COMPRESSIONS$ partial-pull\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
763 s> accept: application/mercurial-0.1\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
764 s> host: $LOCALIP:$HGPORT\r\n (glob) |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
765 s> user-agent: Mercurial debugwireproto\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
766 s> \r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
767 s> makefile('rb', None) |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
768 s> HTTP/1.1 200 Script output follows\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
769 s> Server: testing stub value\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
770 s> Date: $HTTP_DATE$\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
771 s> Content-Type: application/mercurial-0.1\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
772 s> Content-Length: 41\r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
773 s> \r\n |
6169d95dce3b
httppeer: detect redirect to URL without query string (issue5860)
Gregory Szorc <gregory.szorc@gmail.com>
parents:
37822
diff
changeset
|
774 s> 96ee1d7354c4ad7372047672c36a1f561e3a6a4c\n |
39378
0f549da54379
stringutil: teach pprint() to indent
Gregory Szorc <gregory.szorc@gmail.com>
parents:
38021
diff
changeset
|
775 response: [ |
0f549da54379
stringutil: teach pprint() to indent
Gregory Szorc <gregory.szorc@gmail.com>
parents:
38021
diff
changeset
|
776 b'\x96\xee\x1dsT\xc4\xadsr\x04vr\xc3j\x1fV\x1e:jL' |
0f549da54379
stringutil: teach pprint() to indent
Gregory Szorc <gregory.szorc@gmail.com>
parents:
38021
diff
changeset
|
777 ] |
40034
393e44324037
httppeer: report http statistics
Gregory Szorc <gregory.szorc@gmail.com>
parents:
39815
diff
changeset
|
778 (sent 4 HTTP requests and * bytes; received * bytes in responses) (glob) |