Mercurial > hg
annotate tests/test-lfs-serve.t @ 40131:535fc8a22365 stable
lfs: avoid a potential variable reference before assignment error in cmdserver
A coworker hit this once yesterday when pulling in thg (a retry worked), and
then I hit it with strip after a pull. I had a difficult time recreating a test
for this (at least one of the tricks was to not use '-R', which seems to cause
reposetup() to be called for each command), so I'm not sure how large of a
window there actually is for this. Calling reposetup() *after* the requirement
is added will skip the hook entirely.
The other issue I had was adding a couple `ui.status()` lines around the check
that installs the hook. On Windows, the cmdserver process ballooned to 1.6GB
and hung. Changing that to `ui.warn()` avoided the hang. It also hung on
macOS, but without the large memory usage.
author | Matt Harbison <matt_harbison@yahoo.com> |
---|---|
date | Wed, 10 Oct 2018 12:25:28 -0400 |
parents | ead71b15efd5 |
children | ef0baff11aea |
rev | line source |
---|---|
35503
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
1 #testcases lfsremote-on lfsremote-off |
38021
538e850ae737
tests: mark tests that fail when using chg as #require no-chg
Kyle Lippincott <spectral@google.com>
parents:
37765
diff
changeset
|
2 #require serve no-reposimplestore no-chg |
35503
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
3 |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
4 This test splits `hg serve` with and without using the extension into separate |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
5 tests cases. The tests are broken down as follows, where "LFS"/"No-LFS" |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
6 indicates whether or not there are commits that use an LFS file, and "D"/"E" |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
7 indicates whether or not the extension is loaded. The "X" cases are not tested |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
8 individually, because the lfs requirement causes the process to bail early if |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
9 the extension is disabled. |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
10 |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
11 . Server |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
12 . |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
13 . No-LFS LFS |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
14 . +----------------------------+ |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
15 . | || D | E | D | E | |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
16 . |---++=======================| |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
17 . C | D || N/A | #1 | X | #4 | |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
18 . l No +---++-----------------------| |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
19 . i LFS | E || #2 | #2 | X | #5 | |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
20 . e +---++-----------------------| |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
21 . n | D || X | X | X | X | |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
22 . t LFS |---++-----------------------| |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
23 . | E || #3 | #3 | X | #6 | |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
24 . |---++-----------------------+ |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
25 |
38178
3790efb388ca
lfs: bypass wrapped functions when reposetup() hasn't been called (issue5902)
Matt Harbison <matt_harbison@yahoo.com>
parents:
37765
diff
changeset
|
26 make command server magic visible |
3790efb388ca
lfs: bypass wrapped functions when reposetup() hasn't been called (issue5902)
Matt Harbison <matt_harbison@yahoo.com>
parents:
37765
diff
changeset
|
27 |
3790efb388ca
lfs: bypass wrapped functions when reposetup() hasn't been called (issue5902)
Matt Harbison <matt_harbison@yahoo.com>
parents:
37765
diff
changeset
|
28 #if windows |
3790efb388ca
lfs: bypass wrapped functions when reposetup() hasn't been called (issue5902)
Matt Harbison <matt_harbison@yahoo.com>
parents:
37765
diff
changeset
|
29 $ PYTHONPATH="$TESTDIR/../contrib;$PYTHONPATH" |
3790efb388ca
lfs: bypass wrapped functions when reposetup() hasn't been called (issue5902)
Matt Harbison <matt_harbison@yahoo.com>
parents:
37765
diff
changeset
|
30 #else |
3790efb388ca
lfs: bypass wrapped functions when reposetup() hasn't been called (issue5902)
Matt Harbison <matt_harbison@yahoo.com>
parents:
37765
diff
changeset
|
31 $ PYTHONPATH="$TESTDIR/../contrib:$PYTHONPATH" |
3790efb388ca
lfs: bypass wrapped functions when reposetup() hasn't been called (issue5902)
Matt Harbison <matt_harbison@yahoo.com>
parents:
37765
diff
changeset
|
32 #endif |
3790efb388ca
lfs: bypass wrapped functions when reposetup() hasn't been called (issue5902)
Matt Harbison <matt_harbison@yahoo.com>
parents:
37765
diff
changeset
|
33 $ export PYTHONPATH |
3790efb388ca
lfs: bypass wrapped functions when reposetup() hasn't been called (issue5902)
Matt Harbison <matt_harbison@yahoo.com>
parents:
37765
diff
changeset
|
34 |
35503
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
35 $ hg init server |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
36 $ SERVER_REQUIRES="$TESTTMP/server/.hg/requires" |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
37 |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
38 Skip the experimental.changegroup3=True config. Failure to agree on this comes |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
39 first, and causes a "ValueError: no common changegroup version" or "abort: |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
40 HTTP Error 500: Internal Server Error", if the extension is only loaded on one |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
41 side. If that *is* enabled, the subsequent failure is "abort: missing processor |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
42 for flag '0x2000'!" if the extension is only loaded on one side (possibly also |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
43 masked by the Internal Server Error message). |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
44 $ cat >> $HGRCPATH <<EOF |
37562
e5cd8d1a094d
lfs: special case the null:// usercache instead of treating it as a url
Matt Harbison <matt_harbison@yahoo.com>
parents:
37518
diff
changeset
|
45 > [experimental] |
e5cd8d1a094d
lfs: special case the null:// usercache instead of treating it as a url
Matt Harbison <matt_harbison@yahoo.com>
parents:
37518
diff
changeset
|
46 > lfs.disableusercache = True |
35503
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
47 > [lfs] |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
48 > threshold=10 |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
49 > [web] |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
50 > allow_push=* |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
51 > push_ssl=False |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
52 > EOF |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
53 |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
54 #if lfsremote-on |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
55 $ hg --config extensions.lfs= -R server \ |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
56 > serve -p $HGPORT -d --pid-file=hg.pid --errorlog=$TESTTMP/errors.log |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
57 #else |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
58 $ hg --config extensions.lfs=! -R server \ |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
59 > serve -p $HGPORT -d --pid-file=hg.pid --errorlog=$TESTTMP/errors.log |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
60 #endif |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
61 |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
62 $ cat hg.pid >> $DAEMON_PIDS |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
63 $ hg clone -q http://localhost:$HGPORT client |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
64 $ grep 'lfs' client/.hg/requires $SERVER_REQUIRES |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
65 [1] |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
66 |
38178
3790efb388ca
lfs: bypass wrapped functions when reposetup() hasn't been called (issue5902)
Matt Harbison <matt_harbison@yahoo.com>
parents:
37765
diff
changeset
|
67 This trivial repo will force commandserver to load the extension, but not call |
3790efb388ca
lfs: bypass wrapped functions when reposetup() hasn't been called (issue5902)
Matt Harbison <matt_harbison@yahoo.com>
parents:
37765
diff
changeset
|
68 reposetup() on another repo actually being operated on. This gives coverage |
3790efb388ca
lfs: bypass wrapped functions when reposetup() hasn't been called (issue5902)
Matt Harbison <matt_harbison@yahoo.com>
parents:
37765
diff
changeset
|
69 that wrapper functions are not assuming reposetup() was called. |
3790efb388ca
lfs: bypass wrapped functions when reposetup() hasn't been called (issue5902)
Matt Harbison <matt_harbison@yahoo.com>
parents:
37765
diff
changeset
|
70 |
3790efb388ca
lfs: bypass wrapped functions when reposetup() hasn't been called (issue5902)
Matt Harbison <matt_harbison@yahoo.com>
parents:
37765
diff
changeset
|
71 $ hg init $TESTTMP/cmdservelfs |
3790efb388ca
lfs: bypass wrapped functions when reposetup() hasn't been called (issue5902)
Matt Harbison <matt_harbison@yahoo.com>
parents:
37765
diff
changeset
|
72 $ cat >> $TESTTMP/cmdservelfs/.hg/hgrc << EOF |
3790efb388ca
lfs: bypass wrapped functions when reposetup() hasn't been called (issue5902)
Matt Harbison <matt_harbison@yahoo.com>
parents:
37765
diff
changeset
|
73 > [extensions] |
3790efb388ca
lfs: bypass wrapped functions when reposetup() hasn't been called (issue5902)
Matt Harbison <matt_harbison@yahoo.com>
parents:
37765
diff
changeset
|
74 > lfs = |
3790efb388ca
lfs: bypass wrapped functions when reposetup() hasn't been called (issue5902)
Matt Harbison <matt_harbison@yahoo.com>
parents:
37765
diff
changeset
|
75 > EOF |
3790efb388ca
lfs: bypass wrapped functions when reposetup() hasn't been called (issue5902)
Matt Harbison <matt_harbison@yahoo.com>
parents:
37765
diff
changeset
|
76 |
35503
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
77 -------------------------------------------------------------------------------- |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
78 Case #1: client with non-lfs content and the extension disabled; server with |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
79 non-lfs content, and the extension enabled. |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
80 |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
81 $ cd client |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
82 $ echo 'non-lfs' > nonlfs.txt |
38178
3790efb388ca
lfs: bypass wrapped functions when reposetup() hasn't been called (issue5902)
Matt Harbison <matt_harbison@yahoo.com>
parents:
37765
diff
changeset
|
83 >>> from __future__ import absolute_import |
3790efb388ca
lfs: bypass wrapped functions when reposetup() hasn't been called (issue5902)
Matt Harbison <matt_harbison@yahoo.com>
parents:
37765
diff
changeset
|
84 >>> from hgclient import check, readchannel, runcommand |
3790efb388ca
lfs: bypass wrapped functions when reposetup() hasn't been called (issue5902)
Matt Harbison <matt_harbison@yahoo.com>
parents:
37765
diff
changeset
|
85 >>> @check |
3790efb388ca
lfs: bypass wrapped functions when reposetup() hasn't been called (issue5902)
Matt Harbison <matt_harbison@yahoo.com>
parents:
37765
diff
changeset
|
86 ... def diff(server): |
3790efb388ca
lfs: bypass wrapped functions when reposetup() hasn't been called (issue5902)
Matt Harbison <matt_harbison@yahoo.com>
parents:
37765
diff
changeset
|
87 ... readchannel(server) |
3790efb388ca
lfs: bypass wrapped functions when reposetup() hasn't been called (issue5902)
Matt Harbison <matt_harbison@yahoo.com>
parents:
37765
diff
changeset
|
88 ... # run an arbitrary command in the repo with the extension loaded |
3790efb388ca
lfs: bypass wrapped functions when reposetup() hasn't been called (issue5902)
Matt Harbison <matt_harbison@yahoo.com>
parents:
37765
diff
changeset
|
89 ... runcommand(server, ['id', '-R', '../cmdservelfs']) |
3790efb388ca
lfs: bypass wrapped functions when reposetup() hasn't been called (issue5902)
Matt Harbison <matt_harbison@yahoo.com>
parents:
37765
diff
changeset
|
90 ... # now run a command in a repo without the extension to ensure that |
3790efb388ca
lfs: bypass wrapped functions when reposetup() hasn't been called (issue5902)
Matt Harbison <matt_harbison@yahoo.com>
parents:
37765
diff
changeset
|
91 ... # files are added safely.. |
3790efb388ca
lfs: bypass wrapped functions when reposetup() hasn't been called (issue5902)
Matt Harbison <matt_harbison@yahoo.com>
parents:
37765
diff
changeset
|
92 ... runcommand(server, ['ci', '-Aqm', 'non-lfs']) |
3790efb388ca
lfs: bypass wrapped functions when reposetup() hasn't been called (issue5902)
Matt Harbison <matt_harbison@yahoo.com>
parents:
37765
diff
changeset
|
93 ... # .. and that scmutil.prefetchfiles() safely no-ops.. |
3790efb388ca
lfs: bypass wrapped functions when reposetup() hasn't been called (issue5902)
Matt Harbison <matt_harbison@yahoo.com>
parents:
37765
diff
changeset
|
94 ... runcommand(server, ['diff', '-r', '.~1']) |
3790efb388ca
lfs: bypass wrapped functions when reposetup() hasn't been called (issue5902)
Matt Harbison <matt_harbison@yahoo.com>
parents:
37765
diff
changeset
|
95 ... # .. and that debugupgraderepo safely no-ops. |
3790efb388ca
lfs: bypass wrapped functions when reposetup() hasn't been called (issue5902)
Matt Harbison <matt_harbison@yahoo.com>
parents:
37765
diff
changeset
|
96 ... runcommand(server, ['debugupgraderepo', '-q', '--run']) |
3790efb388ca
lfs: bypass wrapped functions when reposetup() hasn't been called (issue5902)
Matt Harbison <matt_harbison@yahoo.com>
parents:
37765
diff
changeset
|
97 *** runcommand id -R ../cmdservelfs |
3790efb388ca
lfs: bypass wrapped functions when reposetup() hasn't been called (issue5902)
Matt Harbison <matt_harbison@yahoo.com>
parents:
37765
diff
changeset
|
98 000000000000 tip |
3790efb388ca
lfs: bypass wrapped functions when reposetup() hasn't been called (issue5902)
Matt Harbison <matt_harbison@yahoo.com>
parents:
37765
diff
changeset
|
99 *** runcommand ci -Aqm non-lfs |
3790efb388ca
lfs: bypass wrapped functions when reposetup() hasn't been called (issue5902)
Matt Harbison <matt_harbison@yahoo.com>
parents:
37765
diff
changeset
|
100 *** runcommand diff -r .~1 |
3790efb388ca
lfs: bypass wrapped functions when reposetup() hasn't been called (issue5902)
Matt Harbison <matt_harbison@yahoo.com>
parents:
37765
diff
changeset
|
101 diff -r 000000000000 nonlfs.txt |
3790efb388ca
lfs: bypass wrapped functions when reposetup() hasn't been called (issue5902)
Matt Harbison <matt_harbison@yahoo.com>
parents:
37765
diff
changeset
|
102 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 |
3790efb388ca
lfs: bypass wrapped functions when reposetup() hasn't been called (issue5902)
Matt Harbison <matt_harbison@yahoo.com>
parents:
37765
diff
changeset
|
103 +++ b/nonlfs.txt Thu Jan 01 00:00:00 1970 +0000 |
3790efb388ca
lfs: bypass wrapped functions when reposetup() hasn't been called (issue5902)
Matt Harbison <matt_harbison@yahoo.com>
parents:
37765
diff
changeset
|
104 @@ -0,0 +1,1 @@ |
3790efb388ca
lfs: bypass wrapped functions when reposetup() hasn't been called (issue5902)
Matt Harbison <matt_harbison@yahoo.com>
parents:
37765
diff
changeset
|
105 +non-lfs |
3790efb388ca
lfs: bypass wrapped functions when reposetup() hasn't been called (issue5902)
Matt Harbison <matt_harbison@yahoo.com>
parents:
37765
diff
changeset
|
106 *** runcommand debugupgraderepo -q --run |
3790efb388ca
lfs: bypass wrapped functions when reposetup() hasn't been called (issue5902)
Matt Harbison <matt_harbison@yahoo.com>
parents:
37765
diff
changeset
|
107 upgrade will perform the following actions: |
3790efb388ca
lfs: bypass wrapped functions when reposetup() hasn't been called (issue5902)
Matt Harbison <matt_harbison@yahoo.com>
parents:
37765
diff
changeset
|
108 |
3790efb388ca
lfs: bypass wrapped functions when reposetup() hasn't been called (issue5902)
Matt Harbison <matt_harbison@yahoo.com>
parents:
37765
diff
changeset
|
109 requirements |
3790efb388ca
lfs: bypass wrapped functions when reposetup() hasn't been called (issue5902)
Matt Harbison <matt_harbison@yahoo.com>
parents:
37765
diff
changeset
|
110 preserved: dotencode, fncache, generaldelta, revlogv1, store |
3790efb388ca
lfs: bypass wrapped functions when reposetup() hasn't been called (issue5902)
Matt Harbison <matt_harbison@yahoo.com>
parents:
37765
diff
changeset
|
111 |
3790efb388ca
lfs: bypass wrapped functions when reposetup() hasn't been called (issue5902)
Matt Harbison <matt_harbison@yahoo.com>
parents:
37765
diff
changeset
|
112 beginning upgrade... |
3790efb388ca
lfs: bypass wrapped functions when reposetup() hasn't been called (issue5902)
Matt Harbison <matt_harbison@yahoo.com>
parents:
37765
diff
changeset
|
113 repository locked and read-only |
3790efb388ca
lfs: bypass wrapped functions when reposetup() hasn't been called (issue5902)
Matt Harbison <matt_harbison@yahoo.com>
parents:
37765
diff
changeset
|
114 creating temporary repository to stage migrated data: * (glob) |
3790efb388ca
lfs: bypass wrapped functions when reposetup() hasn't been called (issue5902)
Matt Harbison <matt_harbison@yahoo.com>
parents:
37765
diff
changeset
|
115 (it is safe to interrupt this process any time before data migration completes) |
3790efb388ca
lfs: bypass wrapped functions when reposetup() hasn't been called (issue5902)
Matt Harbison <matt_harbison@yahoo.com>
parents:
37765
diff
changeset
|
116 migrating 3 total revisions (1 in filelogs, 1 in manifests, 1 in changelog) |
3790efb388ca
lfs: bypass wrapped functions when reposetup() hasn't been called (issue5902)
Matt Harbison <matt_harbison@yahoo.com>
parents:
37765
diff
changeset
|
117 migrating 132 bytes in store; 129 bytes tracked data |
3790efb388ca
lfs: bypass wrapped functions when reposetup() hasn't been called (issue5902)
Matt Harbison <matt_harbison@yahoo.com>
parents:
37765
diff
changeset
|
118 migrating 1 filelogs containing 1 revisions (9 bytes in store; 8 bytes tracked data) |
3790efb388ca
lfs: bypass wrapped functions when reposetup() hasn't been called (issue5902)
Matt Harbison <matt_harbison@yahoo.com>
parents:
37765
diff
changeset
|
119 finished migrating 1 filelog revisions across 1 filelogs; change in size: 0 bytes |
3790efb388ca
lfs: bypass wrapped functions when reposetup() hasn't been called (issue5902)
Matt Harbison <matt_harbison@yahoo.com>
parents:
37765
diff
changeset
|
120 migrating 1 manifests containing 1 revisions (53 bytes in store; 52 bytes tracked data) |
3790efb388ca
lfs: bypass wrapped functions when reposetup() hasn't been called (issue5902)
Matt Harbison <matt_harbison@yahoo.com>
parents:
37765
diff
changeset
|
121 finished migrating 1 manifest revisions across 1 manifests; change in size: 0 bytes |
3790efb388ca
lfs: bypass wrapped functions when reposetup() hasn't been called (issue5902)
Matt Harbison <matt_harbison@yahoo.com>
parents:
37765
diff
changeset
|
122 migrating changelog containing 1 revisions (70 bytes in store; 69 bytes tracked data) |
3790efb388ca
lfs: bypass wrapped functions when reposetup() hasn't been called (issue5902)
Matt Harbison <matt_harbison@yahoo.com>
parents:
37765
diff
changeset
|
123 finished migrating 1 changelog revisions; change in size: 0 bytes |
3790efb388ca
lfs: bypass wrapped functions when reposetup() hasn't been called (issue5902)
Matt Harbison <matt_harbison@yahoo.com>
parents:
37765
diff
changeset
|
124 finished migrating 3 total revisions; total change in store size: 0 bytes |
3790efb388ca
lfs: bypass wrapped functions when reposetup() hasn't been called (issue5902)
Matt Harbison <matt_harbison@yahoo.com>
parents:
37765
diff
changeset
|
125 copying phaseroots |
3790efb388ca
lfs: bypass wrapped functions when reposetup() hasn't been called (issue5902)
Matt Harbison <matt_harbison@yahoo.com>
parents:
37765
diff
changeset
|
126 data fully migrated to temporary repository |
3790efb388ca
lfs: bypass wrapped functions when reposetup() hasn't been called (issue5902)
Matt Harbison <matt_harbison@yahoo.com>
parents:
37765
diff
changeset
|
127 marking source repository as being upgraded; clients will be unable to read from repository |
3790efb388ca
lfs: bypass wrapped functions when reposetup() hasn't been called (issue5902)
Matt Harbison <matt_harbison@yahoo.com>
parents:
37765
diff
changeset
|
128 starting in-place swap of repository data |
3790efb388ca
lfs: bypass wrapped functions when reposetup() hasn't been called (issue5902)
Matt Harbison <matt_harbison@yahoo.com>
parents:
37765
diff
changeset
|
129 replaced files will be backed up at * (glob) |
3790efb388ca
lfs: bypass wrapped functions when reposetup() hasn't been called (issue5902)
Matt Harbison <matt_harbison@yahoo.com>
parents:
37765
diff
changeset
|
130 replacing store... |
3790efb388ca
lfs: bypass wrapped functions when reposetup() hasn't been called (issue5902)
Matt Harbison <matt_harbison@yahoo.com>
parents:
37765
diff
changeset
|
131 store replacement complete; repository was inconsistent for *s (glob) |
3790efb388ca
lfs: bypass wrapped functions when reposetup() hasn't been called (issue5902)
Matt Harbison <matt_harbison@yahoo.com>
parents:
37765
diff
changeset
|
132 finalizing requirements file and making repository readable again |
3790efb388ca
lfs: bypass wrapped functions when reposetup() hasn't been called (issue5902)
Matt Harbison <matt_harbison@yahoo.com>
parents:
37765
diff
changeset
|
133 removing temporary repository * (glob) |
3790efb388ca
lfs: bypass wrapped functions when reposetup() hasn't been called (issue5902)
Matt Harbison <matt_harbison@yahoo.com>
parents:
37765
diff
changeset
|
134 copy of old repository backed up at * (glob) |
3790efb388ca
lfs: bypass wrapped functions when reposetup() hasn't been called (issue5902)
Matt Harbison <matt_harbison@yahoo.com>
parents:
37765
diff
changeset
|
135 the old repository will not be deleted; remove it to free up disk space once the upgraded repository is verified |
3790efb388ca
lfs: bypass wrapped functions when reposetup() hasn't been called (issue5902)
Matt Harbison <matt_harbison@yahoo.com>
parents:
37765
diff
changeset
|
136 |
35503
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
137 $ grep 'lfs' .hg/requires $SERVER_REQUIRES |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
138 [1] |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
139 |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
140 #if lfsremote-on |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
141 |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
142 $ hg push -q |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
143 $ grep 'lfs' .hg/requires $SERVER_REQUIRES |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
144 [1] |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
145 |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
146 $ hg clone -q http://localhost:$HGPORT $TESTTMP/client1_clone |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
147 $ grep 'lfs' $TESTTMP/client1_clone/.hg/requires $SERVER_REQUIRES |
35505
2526579a30e0
lfs: allow non-lfs exchanges when the extension is only enabled on one side
Matt Harbison <matt_harbison@yahoo.com>
parents:
35504
diff
changeset
|
148 [1] |
35503
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
149 |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
150 $ hg init $TESTTMP/client1_pull |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
151 $ hg -R $TESTTMP/client1_pull pull -q http://localhost:$HGPORT |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
152 $ grep 'lfs' $TESTTMP/client1_pull/.hg/requires $SERVER_REQUIRES |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
153 [1] |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
154 |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
155 $ hg identify http://localhost:$HGPORT |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
156 d437e1d24fbd |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
157 |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
158 #endif |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
159 |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
160 -------------------------------------------------------------------------------- |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
161 Case #2: client with non-lfs content and the extension enabled; server with |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
162 non-lfs content, and the extension state controlled by #testcases. |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
163 |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
164 $ cat >> $HGRCPATH <<EOF |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
165 > [extensions] |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
166 > lfs = |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
167 > EOF |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
168 $ echo 'non-lfs' > nonlfs2.txt |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
169 $ hg ci -Aqm 'non-lfs file with lfs client' |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
170 |
35505
2526579a30e0
lfs: allow non-lfs exchanges when the extension is only enabled on one side
Matt Harbison <matt_harbison@yahoo.com>
parents:
35504
diff
changeset
|
171 Since no lfs content has been added yet, the push is allowed, even when the |
2526579a30e0
lfs: allow non-lfs exchanges when the extension is only enabled on one side
Matt Harbison <matt_harbison@yahoo.com>
parents:
35504
diff
changeset
|
172 extension is not enabled remotely. |
2526579a30e0
lfs: allow non-lfs exchanges when the extension is only enabled on one side
Matt Harbison <matt_harbison@yahoo.com>
parents:
35504
diff
changeset
|
173 |
2526579a30e0
lfs: allow non-lfs exchanges when the extension is only enabled on one side
Matt Harbison <matt_harbison@yahoo.com>
parents:
35504
diff
changeset
|
174 $ hg push -q |
35503
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
175 $ grep 'lfs' .hg/requires $SERVER_REQUIRES |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
176 [1] |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
177 |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
178 $ hg clone -q http://localhost:$HGPORT $TESTTMP/client2_clone |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
179 $ grep 'lfs' $TESTTMP/client2_clone/.hg/requires $SERVER_REQUIRES |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
180 [1] |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
181 |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
182 $ hg init $TESTTMP/client2_pull |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
183 $ hg -R $TESTTMP/client2_pull pull -q http://localhost:$HGPORT |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
184 $ grep 'lfs' $TESTTMP/client2_pull/.hg/requires $SERVER_REQUIRES |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
185 [1] |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
186 |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
187 $ hg identify http://localhost:$HGPORT |
35505
2526579a30e0
lfs: allow non-lfs exchanges when the extension is only enabled on one side
Matt Harbison <matt_harbison@yahoo.com>
parents:
35504
diff
changeset
|
188 1477875038c6 |
35503
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
189 |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
190 -------------------------------------------------------------------------------- |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
191 Case #3: client with lfs content and the extension enabled; server with |
35504
6bb940de4c4c
lfs: add the 'lfs' requirement in the changegroup transaction introducing lfs
Matt Harbison <matt_harbison@yahoo.com>
parents:
35503
diff
changeset
|
192 non-lfs content, and the extension state controlled by #testcases. The server |
6bb940de4c4c
lfs: add the 'lfs' requirement in the changegroup transaction introducing lfs
Matt Harbison <matt_harbison@yahoo.com>
parents:
35503
diff
changeset
|
193 should have an 'lfs' requirement after it picks up its first commit with a blob. |
35503
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
194 |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
195 $ echo 'this is a big lfs file' > lfs.bin |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
196 $ hg ci -Aqm 'lfs' |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
197 $ grep 'lfs' .hg/requires $SERVER_REQUIRES |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
198 .hg/requires:lfs |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
199 |
35506
fa865878a849
lfs: show a friendly message when pushing lfs to a server without lfs enabled
Matt Harbison <matt_harbison@yahoo.com>
parents:
35505
diff
changeset
|
200 #if lfsremote-off |
fa865878a849
lfs: show a friendly message when pushing lfs to a server without lfs enabled
Matt Harbison <matt_harbison@yahoo.com>
parents:
35505
diff
changeset
|
201 $ hg push -q |
fa865878a849
lfs: show a friendly message when pushing lfs to a server without lfs enabled
Matt Harbison <matt_harbison@yahoo.com>
parents:
35505
diff
changeset
|
202 abort: required features are not supported in the destination: lfs |
fa865878a849
lfs: show a friendly message when pushing lfs to a server without lfs enabled
Matt Harbison <matt_harbison@yahoo.com>
parents:
35505
diff
changeset
|
203 (enable the lfs extension on the server) |
fa865878a849
lfs: show a friendly message when pushing lfs to a server without lfs enabled
Matt Harbison <matt_harbison@yahoo.com>
parents:
35505
diff
changeset
|
204 [255] |
fa865878a849
lfs: show a friendly message when pushing lfs to a server without lfs enabled
Matt Harbison <matt_harbison@yahoo.com>
parents:
35505
diff
changeset
|
205 #else |
fa865878a849
lfs: show a friendly message when pushing lfs to a server without lfs enabled
Matt Harbison <matt_harbison@yahoo.com>
parents:
35505
diff
changeset
|
206 $ hg push -q |
fa865878a849
lfs: show a friendly message when pushing lfs to a server without lfs enabled
Matt Harbison <matt_harbison@yahoo.com>
parents:
35505
diff
changeset
|
207 #endif |
35503
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
208 $ grep 'lfs' .hg/requires $SERVER_REQUIRES |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
209 .hg/requires:lfs |
35504
6bb940de4c4c
lfs: add the 'lfs' requirement in the changegroup transaction introducing lfs
Matt Harbison <matt_harbison@yahoo.com>
parents:
35503
diff
changeset
|
210 $TESTTMP/server/.hg/requires:lfs (lfsremote-on !) |
35503
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
211 |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
212 $ hg clone -q http://localhost:$HGPORT $TESTTMP/client3_clone |
35504
6bb940de4c4c
lfs: add the 'lfs' requirement in the changegroup transaction introducing lfs
Matt Harbison <matt_harbison@yahoo.com>
parents:
35503
diff
changeset
|
213 $ grep 'lfs' $TESTTMP/client3_clone/.hg/requires $SERVER_REQUIRES || true |
6bb940de4c4c
lfs: add the 'lfs' requirement in the changegroup transaction introducing lfs
Matt Harbison <matt_harbison@yahoo.com>
parents:
35503
diff
changeset
|
214 $TESTTMP/client3_clone/.hg/requires:lfs (lfsremote-on !) |
6bb940de4c4c
lfs: add the 'lfs' requirement in the changegroup transaction introducing lfs
Matt Harbison <matt_harbison@yahoo.com>
parents:
35503
diff
changeset
|
215 $TESTTMP/server/.hg/requires:lfs (lfsremote-on !) |
35503
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
216 |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
217 $ hg init $TESTTMP/client3_pull |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
218 $ hg -R $TESTTMP/client3_pull pull -q http://localhost:$HGPORT |
35504
6bb940de4c4c
lfs: add the 'lfs' requirement in the changegroup transaction introducing lfs
Matt Harbison <matt_harbison@yahoo.com>
parents:
35503
diff
changeset
|
219 $ grep 'lfs' $TESTTMP/client3_pull/.hg/requires $SERVER_REQUIRES || true |
6bb940de4c4c
lfs: add the 'lfs' requirement in the changegroup transaction introducing lfs
Matt Harbison <matt_harbison@yahoo.com>
parents:
35503
diff
changeset
|
220 $TESTTMP/client3_pull/.hg/requires:lfs (lfsremote-on !) |
6bb940de4c4c
lfs: add the 'lfs' requirement in the changegroup transaction introducing lfs
Matt Harbison <matt_harbison@yahoo.com>
parents:
35503
diff
changeset
|
221 $TESTTMP/server/.hg/requires:lfs (lfsremote-on !) |
35503
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
222 |
40131
535fc8a22365
lfs: avoid a potential variable reference before assignment error in cmdserver
Matt Harbison <matt_harbison@yahoo.com>
parents:
38239
diff
changeset
|
223 Test that the commit/changegroup requirement check hook can be run multiple |
535fc8a22365
lfs: avoid a potential variable reference before assignment error in cmdserver
Matt Harbison <matt_harbison@yahoo.com>
parents:
38239
diff
changeset
|
224 times. |
535fc8a22365
lfs: avoid a potential variable reference before assignment error in cmdserver
Matt Harbison <matt_harbison@yahoo.com>
parents:
38239
diff
changeset
|
225 |
535fc8a22365
lfs: avoid a potential variable reference before assignment error in cmdserver
Matt Harbison <matt_harbison@yahoo.com>
parents:
38239
diff
changeset
|
226 $ hg clone -qr 0 http://localhost:$HGPORT $TESTTMP/cmdserve_client3 |
535fc8a22365
lfs: avoid a potential variable reference before assignment error in cmdserver
Matt Harbison <matt_harbison@yahoo.com>
parents:
38239
diff
changeset
|
227 |
535fc8a22365
lfs: avoid a potential variable reference before assignment error in cmdserver
Matt Harbison <matt_harbison@yahoo.com>
parents:
38239
diff
changeset
|
228 $ cd ../cmdserve_client3 |
535fc8a22365
lfs: avoid a potential variable reference before assignment error in cmdserver
Matt Harbison <matt_harbison@yahoo.com>
parents:
38239
diff
changeset
|
229 |
535fc8a22365
lfs: avoid a potential variable reference before assignment error in cmdserver
Matt Harbison <matt_harbison@yahoo.com>
parents:
38239
diff
changeset
|
230 >>> from __future__ import absolute_import |
535fc8a22365
lfs: avoid a potential variable reference before assignment error in cmdserver
Matt Harbison <matt_harbison@yahoo.com>
parents:
38239
diff
changeset
|
231 >>> from hgclient import check, readchannel, runcommand |
535fc8a22365
lfs: avoid a potential variable reference before assignment error in cmdserver
Matt Harbison <matt_harbison@yahoo.com>
parents:
38239
diff
changeset
|
232 >>> @check |
535fc8a22365
lfs: avoid a potential variable reference before assignment error in cmdserver
Matt Harbison <matt_harbison@yahoo.com>
parents:
38239
diff
changeset
|
233 ... def addrequirement(server): |
535fc8a22365
lfs: avoid a potential variable reference before assignment error in cmdserver
Matt Harbison <matt_harbison@yahoo.com>
parents:
38239
diff
changeset
|
234 ... readchannel(server) |
535fc8a22365
lfs: avoid a potential variable reference before assignment error in cmdserver
Matt Harbison <matt_harbison@yahoo.com>
parents:
38239
diff
changeset
|
235 ... # change the repo in a way that adds the lfs requirement |
535fc8a22365
lfs: avoid a potential variable reference before assignment error in cmdserver
Matt Harbison <matt_harbison@yahoo.com>
parents:
38239
diff
changeset
|
236 ... runcommand(server, ['pull', '-qu']) |
535fc8a22365
lfs: avoid a potential variable reference before assignment error in cmdserver
Matt Harbison <matt_harbison@yahoo.com>
parents:
38239
diff
changeset
|
237 ... # Now cause the requirement adding hook to fire again, without going |
535fc8a22365
lfs: avoid a potential variable reference before assignment error in cmdserver
Matt Harbison <matt_harbison@yahoo.com>
parents:
38239
diff
changeset
|
238 ... # through reposetup() again. |
535fc8a22365
lfs: avoid a potential variable reference before assignment error in cmdserver
Matt Harbison <matt_harbison@yahoo.com>
parents:
38239
diff
changeset
|
239 ... with open('file.txt', 'wb') as fp: |
535fc8a22365
lfs: avoid a potential variable reference before assignment error in cmdserver
Matt Harbison <matt_harbison@yahoo.com>
parents:
38239
diff
changeset
|
240 ... fp.write('data') |
535fc8a22365
lfs: avoid a potential variable reference before assignment error in cmdserver
Matt Harbison <matt_harbison@yahoo.com>
parents:
38239
diff
changeset
|
241 ... runcommand(server, ['ci', '-Aqm', 'non-lfs']) |
535fc8a22365
lfs: avoid a potential variable reference before assignment error in cmdserver
Matt Harbison <matt_harbison@yahoo.com>
parents:
38239
diff
changeset
|
242 *** runcommand pull -qu |
535fc8a22365
lfs: avoid a potential variable reference before assignment error in cmdserver
Matt Harbison <matt_harbison@yahoo.com>
parents:
38239
diff
changeset
|
243 *** runcommand ci -Aqm non-lfs |
535fc8a22365
lfs: avoid a potential variable reference before assignment error in cmdserver
Matt Harbison <matt_harbison@yahoo.com>
parents:
38239
diff
changeset
|
244 |
535fc8a22365
lfs: avoid a potential variable reference before assignment error in cmdserver
Matt Harbison <matt_harbison@yahoo.com>
parents:
38239
diff
changeset
|
245 $ cd ../client |
535fc8a22365
lfs: avoid a potential variable reference before assignment error in cmdserver
Matt Harbison <matt_harbison@yahoo.com>
parents:
38239
diff
changeset
|
246 |
35505
2526579a30e0
lfs: allow non-lfs exchanges when the extension is only enabled on one side
Matt Harbison <matt_harbison@yahoo.com>
parents:
35504
diff
changeset
|
247 The difference here is the push failed above when the extension isn't |
2526579a30e0
lfs: allow non-lfs exchanges when the extension is only enabled on one side
Matt Harbison <matt_harbison@yahoo.com>
parents:
35504
diff
changeset
|
248 enabled on the server. |
35503
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
249 $ hg identify http://localhost:$HGPORT |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
250 8374dc4052cb (lfsremote-on !) |
35505
2526579a30e0
lfs: allow non-lfs exchanges when the extension is only enabled on one side
Matt Harbison <matt_harbison@yahoo.com>
parents:
35504
diff
changeset
|
251 1477875038c6 (lfsremote-off !) |
35503
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
252 |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
253 Don't bother testing the lfsremote-off cases- the server won't be able |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
254 to launch if there's lfs content and the extension is disabled. |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
255 |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
256 #if lfsremote-on |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
257 |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
258 -------------------------------------------------------------------------------- |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
259 Case #4: client with non-lfs content and the extension disabled; server with |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
260 lfs content, and the extension enabled. |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
261 |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
262 $ cat >> $HGRCPATH <<EOF |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
263 > [extensions] |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
264 > lfs = ! |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
265 > EOF |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
266 |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
267 $ hg init $TESTTMP/client4 |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
268 $ cd $TESTTMP/client4 |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
269 $ cat >> .hg/hgrc <<EOF |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
270 > [paths] |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
271 > default = http://localhost:$HGPORT |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
272 > EOF |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
273 $ echo 'non-lfs' > nonlfs2.txt |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
274 $ hg ci -Aqm 'non-lfs' |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
275 $ grep 'lfs' .hg/requires $SERVER_REQUIRES |
35504
6bb940de4c4c
lfs: add the 'lfs' requirement in the changegroup transaction introducing lfs
Matt Harbison <matt_harbison@yahoo.com>
parents:
35503
diff
changeset
|
276 $TESTTMP/server/.hg/requires:lfs |
35503
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
277 |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
278 $ hg push -q --force |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
279 warning: repository is unrelated |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
280 $ grep 'lfs' .hg/requires $SERVER_REQUIRES |
35504
6bb940de4c4c
lfs: add the 'lfs' requirement in the changegroup transaction introducing lfs
Matt Harbison <matt_harbison@yahoo.com>
parents:
35503
diff
changeset
|
281 $TESTTMP/server/.hg/requires:lfs |
35503
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
282 |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
283 TODO: fail more gracefully. |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
284 |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
285 $ hg clone -q http://localhost:$HGPORT $TESTTMP/client4_clone |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
286 abort: HTTP Error 500: Internal Server Error |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
287 [255] |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
288 $ grep 'lfs' $TESTTMP/client4_clone/.hg/requires $SERVER_REQUIRES |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
289 grep: $TESTTMP/client4_clone/.hg/requires: $ENOENT$ |
35504
6bb940de4c4c
lfs: add the 'lfs' requirement in the changegroup transaction introducing lfs
Matt Harbison <matt_harbison@yahoo.com>
parents:
35503
diff
changeset
|
290 $TESTTMP/server/.hg/requires:lfs |
35503
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
291 [2] |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
292 |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
293 TODO: fail more gracefully. |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
294 |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
295 $ hg init $TESTTMP/client4_pull |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
296 $ hg -R $TESTTMP/client4_pull pull -q http://localhost:$HGPORT |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
297 abort: HTTP Error 500: Internal Server Error |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
298 [255] |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
299 $ grep 'lfs' $TESTTMP/client4_pull/.hg/requires $SERVER_REQUIRES |
35504
6bb940de4c4c
lfs: add the 'lfs' requirement in the changegroup transaction introducing lfs
Matt Harbison <matt_harbison@yahoo.com>
parents:
35503
diff
changeset
|
300 $TESTTMP/server/.hg/requires:lfs |
35503
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
301 |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
302 $ hg identify http://localhost:$HGPORT |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
303 03b080fa9d93 |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
304 |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
305 -------------------------------------------------------------------------------- |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
306 Case #5: client with non-lfs content and the extension enabled; server with |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
307 lfs content, and the extension enabled. |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
308 |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
309 $ cat >> $HGRCPATH <<EOF |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
310 > [extensions] |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
311 > lfs = |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
312 > EOF |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
313 $ echo 'non-lfs' > nonlfs3.txt |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
314 $ hg ci -Aqm 'non-lfs file with lfs client' |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
315 |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
316 $ hg push -q |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
317 $ grep 'lfs' .hg/requires $SERVER_REQUIRES |
35504
6bb940de4c4c
lfs: add the 'lfs' requirement in the changegroup transaction introducing lfs
Matt Harbison <matt_harbison@yahoo.com>
parents:
35503
diff
changeset
|
318 $TESTTMP/server/.hg/requires:lfs |
35503
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
319 |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
320 $ hg clone -q http://localhost:$HGPORT $TESTTMP/client5_clone |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
321 $ grep 'lfs' $TESTTMP/client5_clone/.hg/requires $SERVER_REQUIRES |
35504
6bb940de4c4c
lfs: add the 'lfs' requirement in the changegroup transaction introducing lfs
Matt Harbison <matt_harbison@yahoo.com>
parents:
35503
diff
changeset
|
322 $TESTTMP/client5_clone/.hg/requires:lfs |
6bb940de4c4c
lfs: add the 'lfs' requirement in the changegroup transaction introducing lfs
Matt Harbison <matt_harbison@yahoo.com>
parents:
35503
diff
changeset
|
323 $TESTTMP/server/.hg/requires:lfs |
35503
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
324 |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
325 $ hg init $TESTTMP/client5_pull |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
326 $ hg -R $TESTTMP/client5_pull pull -q http://localhost:$HGPORT |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
327 $ grep 'lfs' $TESTTMP/client5_pull/.hg/requires $SERVER_REQUIRES |
35504
6bb940de4c4c
lfs: add the 'lfs' requirement in the changegroup transaction introducing lfs
Matt Harbison <matt_harbison@yahoo.com>
parents:
35503
diff
changeset
|
328 $TESTTMP/client5_pull/.hg/requires:lfs |
6bb940de4c4c
lfs: add the 'lfs' requirement in the changegroup transaction introducing lfs
Matt Harbison <matt_harbison@yahoo.com>
parents:
35503
diff
changeset
|
329 $TESTTMP/server/.hg/requires:lfs |
35503
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
330 |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
331 $ hg identify http://localhost:$HGPORT |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
332 c729025cc5e3 |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
333 |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
334 -------------------------------------------------------------------------------- |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
335 Case #6: client with lfs content and the extension enabled; server with |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
336 lfs content, and the extension enabled. |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
337 |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
338 $ echo 'this is another lfs file' > lfs2.txt |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
339 $ hg ci -Aqm 'lfs file with lfs client' |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
340 |
37564
31a4ea773369
lfs: infer the blob store URL from an explicit push dest or default-push
Matt Harbison <matt_harbison@yahoo.com>
parents:
37563
diff
changeset
|
341 $ hg --config paths.default= push -v http://localhost:$HGPORT |
31a4ea773369
lfs: infer the blob store URL from an explicit push dest or default-push
Matt Harbison <matt_harbison@yahoo.com>
parents:
37563
diff
changeset
|
342 pushing to http://localhost:$HGPORT/ |
31a4ea773369
lfs: infer the blob store URL from an explicit push dest or default-push
Matt Harbison <matt_harbison@yahoo.com>
parents:
37563
diff
changeset
|
343 lfs: assuming remote store: http://localhost:$HGPORT/.git/info/lfs |
31a4ea773369
lfs: infer the blob store URL from an explicit push dest or default-push
Matt Harbison <matt_harbison@yahoo.com>
parents:
37563
diff
changeset
|
344 searching for changes |
31a4ea773369
lfs: infer the blob store URL from an explicit push dest or default-push
Matt Harbison <matt_harbison@yahoo.com>
parents:
37563
diff
changeset
|
345 remote has heads on branch 'default' that are not known locally: 8374dc4052cb |
31a4ea773369
lfs: infer the blob store URL from an explicit push dest or default-push
Matt Harbison <matt_harbison@yahoo.com>
parents:
37563
diff
changeset
|
346 lfs: uploading a82f1c5cea0d40e3bb3a849686bb4e6ae47ca27e614de55c1ed0325698ef68de (25 bytes) |
31a4ea773369
lfs: infer the blob store URL from an explicit push dest or default-push
Matt Harbison <matt_harbison@yahoo.com>
parents:
37563
diff
changeset
|
347 lfs: processed: a82f1c5cea0d40e3bb3a849686bb4e6ae47ca27e614de55c1ed0325698ef68de |
31a4ea773369
lfs: infer the blob store URL from an explicit push dest or default-push
Matt Harbison <matt_harbison@yahoo.com>
parents:
37563
diff
changeset
|
348 lfs: uploaded 1 files (25 bytes) |
31a4ea773369
lfs: infer the blob store URL from an explicit push dest or default-push
Matt Harbison <matt_harbison@yahoo.com>
parents:
37563
diff
changeset
|
349 1 changesets found |
31a4ea773369
lfs: infer the blob store URL from an explicit push dest or default-push
Matt Harbison <matt_harbison@yahoo.com>
parents:
37563
diff
changeset
|
350 uncompressed size of bundle content: |
31a4ea773369
lfs: infer the blob store URL from an explicit push dest or default-push
Matt Harbison <matt_harbison@yahoo.com>
parents:
37563
diff
changeset
|
351 206 (changelog) |
31a4ea773369
lfs: infer the blob store URL from an explicit push dest or default-push
Matt Harbison <matt_harbison@yahoo.com>
parents:
37563
diff
changeset
|
352 172 (manifests) |
31a4ea773369
lfs: infer the blob store URL from an explicit push dest or default-push
Matt Harbison <matt_harbison@yahoo.com>
parents:
37563
diff
changeset
|
353 275 lfs2.txt |
31a4ea773369
lfs: infer the blob store URL from an explicit push dest or default-push
Matt Harbison <matt_harbison@yahoo.com>
parents:
37563
diff
changeset
|
354 remote: adding changesets |
31a4ea773369
lfs: infer the blob store URL from an explicit push dest or default-push
Matt Harbison <matt_harbison@yahoo.com>
parents:
37563
diff
changeset
|
355 remote: adding manifests |
31a4ea773369
lfs: infer the blob store URL from an explicit push dest or default-push
Matt Harbison <matt_harbison@yahoo.com>
parents:
37563
diff
changeset
|
356 remote: adding file changes |
31a4ea773369
lfs: infer the blob store URL from an explicit push dest or default-push
Matt Harbison <matt_harbison@yahoo.com>
parents:
37563
diff
changeset
|
357 remote: added 1 changesets with 1 changes to 1 files |
35503
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
358 $ grep 'lfs' .hg/requires $SERVER_REQUIRES |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
359 .hg/requires:lfs |
35504
6bb940de4c4c
lfs: add the 'lfs' requirement in the changegroup transaction introducing lfs
Matt Harbison <matt_harbison@yahoo.com>
parents:
35503
diff
changeset
|
360 $TESTTMP/server/.hg/requires:lfs |
35503
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
361 |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
362 $ hg clone -q http://localhost:$HGPORT $TESTTMP/client6_clone |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
363 $ grep 'lfs' $TESTTMP/client6_clone/.hg/requires $SERVER_REQUIRES |
35504
6bb940de4c4c
lfs: add the 'lfs' requirement in the changegroup transaction introducing lfs
Matt Harbison <matt_harbison@yahoo.com>
parents:
35503
diff
changeset
|
364 $TESTTMP/client6_clone/.hg/requires:lfs |
6bb940de4c4c
lfs: add the 'lfs' requirement in the changegroup transaction introducing lfs
Matt Harbison <matt_harbison@yahoo.com>
parents:
35503
diff
changeset
|
365 $TESTTMP/server/.hg/requires:lfs |
35503
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
366 |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
367 $ hg init $TESTTMP/client6_pull |
37563
be1cc65bdb1c
lfs: infer the blob store URL from an explicit pull source
Matt Harbison <matt_harbison@yahoo.com>
parents:
37562
diff
changeset
|
368 $ hg -R $TESTTMP/client6_pull pull -u -v http://localhost:$HGPORT |
be1cc65bdb1c
lfs: infer the blob store URL from an explicit pull source
Matt Harbison <matt_harbison@yahoo.com>
parents:
37562
diff
changeset
|
369 pulling from http://localhost:$HGPORT/ |
be1cc65bdb1c
lfs: infer the blob store URL from an explicit pull source
Matt Harbison <matt_harbison@yahoo.com>
parents:
37562
diff
changeset
|
370 requesting all changes |
be1cc65bdb1c
lfs: infer the blob store URL from an explicit pull source
Matt Harbison <matt_harbison@yahoo.com>
parents:
37562
diff
changeset
|
371 adding changesets |
be1cc65bdb1c
lfs: infer the blob store URL from an explicit pull source
Matt Harbison <matt_harbison@yahoo.com>
parents:
37562
diff
changeset
|
372 adding manifests |
be1cc65bdb1c
lfs: infer the blob store URL from an explicit pull source
Matt Harbison <matt_harbison@yahoo.com>
parents:
37562
diff
changeset
|
373 adding file changes |
be1cc65bdb1c
lfs: infer the blob store URL from an explicit pull source
Matt Harbison <matt_harbison@yahoo.com>
parents:
37562
diff
changeset
|
374 added 6 changesets with 5 changes to 5 files (+1 heads) |
be1cc65bdb1c
lfs: infer the blob store URL from an explicit pull source
Matt Harbison <matt_harbison@yahoo.com>
parents:
37562
diff
changeset
|
375 calling hook pretxnchangegroup.lfs: hgext.lfs.checkrequireslfs |
be1cc65bdb1c
lfs: infer the blob store URL from an explicit pull source
Matt Harbison <matt_harbison@yahoo.com>
parents:
37562
diff
changeset
|
376 new changesets d437e1d24fbd:d3b84d50eacb |
be1cc65bdb1c
lfs: infer the blob store URL from an explicit pull source
Matt Harbison <matt_harbison@yahoo.com>
parents:
37562
diff
changeset
|
377 resolving manifests |
be1cc65bdb1c
lfs: infer the blob store URL from an explicit pull source
Matt Harbison <matt_harbison@yahoo.com>
parents:
37562
diff
changeset
|
378 lfs: assuming remote store: http://localhost:$HGPORT/.git/info/lfs |
be1cc65bdb1c
lfs: infer the blob store URL from an explicit pull source
Matt Harbison <matt_harbison@yahoo.com>
parents:
37562
diff
changeset
|
379 lfs: downloading a82f1c5cea0d40e3bb3a849686bb4e6ae47ca27e614de55c1ed0325698ef68de (25 bytes) |
be1cc65bdb1c
lfs: infer the blob store URL from an explicit pull source
Matt Harbison <matt_harbison@yahoo.com>
parents:
37562
diff
changeset
|
380 lfs: processed: a82f1c5cea0d40e3bb3a849686bb4e6ae47ca27e614de55c1ed0325698ef68de |
37765
ab04972a33ef
lfs: enable the final download count status message
Matt Harbison <matt_harbison@yahoo.com>
parents:
37764
diff
changeset
|
381 lfs: downloaded 1 files (25 bytes) |
37563
be1cc65bdb1c
lfs: infer the blob store URL from an explicit pull source
Matt Harbison <matt_harbison@yahoo.com>
parents:
37562
diff
changeset
|
382 getting lfs2.txt |
be1cc65bdb1c
lfs: infer the blob store URL from an explicit pull source
Matt Harbison <matt_harbison@yahoo.com>
parents:
37562
diff
changeset
|
383 lfs: found a82f1c5cea0d40e3bb3a849686bb4e6ae47ca27e614de55c1ed0325698ef68de in the local lfs store |
be1cc65bdb1c
lfs: infer the blob store URL from an explicit pull source
Matt Harbison <matt_harbison@yahoo.com>
parents:
37562
diff
changeset
|
384 getting nonlfs2.txt |
be1cc65bdb1c
lfs: infer the blob store URL from an explicit pull source
Matt Harbison <matt_harbison@yahoo.com>
parents:
37562
diff
changeset
|
385 getting nonlfs3.txt |
be1cc65bdb1c
lfs: infer the blob store URL from an explicit pull source
Matt Harbison <matt_harbison@yahoo.com>
parents:
37562
diff
changeset
|
386 3 files updated, 0 files merged, 0 files removed, 0 files unresolved |
be1cc65bdb1c
lfs: infer the blob store URL from an explicit pull source
Matt Harbison <matt_harbison@yahoo.com>
parents:
37562
diff
changeset
|
387 updated to "d3b84d50eacb: lfs file with lfs client" |
be1cc65bdb1c
lfs: infer the blob store URL from an explicit pull source
Matt Harbison <matt_harbison@yahoo.com>
parents:
37562
diff
changeset
|
388 1 other heads for branch "default" |
35503
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
389 $ grep 'lfs' $TESTTMP/client6_pull/.hg/requires $SERVER_REQUIRES |
35504
6bb940de4c4c
lfs: add the 'lfs' requirement in the changegroup transaction introducing lfs
Matt Harbison <matt_harbison@yahoo.com>
parents:
35503
diff
changeset
|
390 $TESTTMP/client6_pull/.hg/requires:lfs |
6bb940de4c4c
lfs: add the 'lfs' requirement in the changegroup transaction introducing lfs
Matt Harbison <matt_harbison@yahoo.com>
parents:
35503
diff
changeset
|
391 $TESTTMP/server/.hg/requires:lfs |
35503
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
392 |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
393 $ hg identify http://localhost:$HGPORT |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
394 d3b84d50eacb |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
395 |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
396 -------------------------------------------------------------------------------- |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
397 Misc: process dies early if a requirement exists and the extension is disabled |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
398 |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
399 $ hg --config extensions.lfs=! summary |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
400 abort: repository requires features unknown to this Mercurial: lfs! |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
401 (see https://mercurial-scm.org/wiki/MissingRequirement for more information) |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
402 [255] |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
403 |
37763
b54404d66f7e
export: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37564
diff
changeset
|
404 $ echo 'this is an lfs file' > $TESTTMP/client6_clone/lfspair1.bin |
b54404d66f7e
export: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37564
diff
changeset
|
405 $ echo 'this is an lfs file too' > $TESTTMP/client6_clone/lfspair2.bin |
b54404d66f7e
export: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37564
diff
changeset
|
406 $ hg -R $TESTTMP/client6_clone ci -Aqm 'add lfs pair' |
b54404d66f7e
export: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37564
diff
changeset
|
407 $ hg -R $TESTTMP/client6_clone push -q |
b54404d66f7e
export: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37564
diff
changeset
|
408 |
b54404d66f7e
export: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37564
diff
changeset
|
409 $ hg clone -qU http://localhost:$HGPORT $TESTTMP/bulkfetch |
b54404d66f7e
export: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37564
diff
changeset
|
410 |
b54404d66f7e
export: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37564
diff
changeset
|
411 Export will prefetch all needed files across all needed revisions |
b54404d66f7e
export: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37564
diff
changeset
|
412 |
b54404d66f7e
export: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37564
diff
changeset
|
413 $ hg -R $TESTTMP/bulkfetch -v export -r 0:tip -o all.export |
b54404d66f7e
export: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37564
diff
changeset
|
414 lfs: assuming remote store: http://localhost:$HGPORT/.git/info/lfs |
b54404d66f7e
export: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37564
diff
changeset
|
415 exporting patches: |
b54404d66f7e
export: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37564
diff
changeset
|
416 lfs: assuming remote store: http://localhost:$HGPORT/.git/info/lfs |
b54404d66f7e
export: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37564
diff
changeset
|
417 lfs: need to transfer 4 objects (92 bytes) |
b54404d66f7e
export: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37564
diff
changeset
|
418 lfs: downloading a82f1c5cea0d40e3bb3a849686bb4e6ae47ca27e614de55c1ed0325698ef68de (25 bytes) |
b54404d66f7e
export: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37564
diff
changeset
|
419 lfs: processed: a82f1c5cea0d40e3bb3a849686bb4e6ae47ca27e614de55c1ed0325698ef68de |
b54404d66f7e
export: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37564
diff
changeset
|
420 lfs: downloading bed80f00180ac404b843628ab56a1c1984d6145c391cd1628a7dd7d2598d71fc (23 bytes) |
b54404d66f7e
export: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37564
diff
changeset
|
421 lfs: processed: bed80f00180ac404b843628ab56a1c1984d6145c391cd1628a7dd7d2598d71fc |
b54404d66f7e
export: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37564
diff
changeset
|
422 lfs: downloading cf1b2787b74e66547d931b6ebe28ff63303e803cb2baa14a8f57c4383d875782 (20 bytes) |
b54404d66f7e
export: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37564
diff
changeset
|
423 lfs: processed: cf1b2787b74e66547d931b6ebe28ff63303e803cb2baa14a8f57c4383d875782 |
b54404d66f7e
export: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37564
diff
changeset
|
424 lfs: downloading d96eda2c74b56e95cfb5ffb66b6503e198cc6fc4a09dc877de925feebc65786e (24 bytes) |
b54404d66f7e
export: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37564
diff
changeset
|
425 lfs: processed: d96eda2c74b56e95cfb5ffb66b6503e198cc6fc4a09dc877de925feebc65786e |
37765
ab04972a33ef
lfs: enable the final download count status message
Matt Harbison <matt_harbison@yahoo.com>
parents:
37764
diff
changeset
|
426 lfs: downloaded 4 files (92 bytes) |
37763
b54404d66f7e
export: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37564
diff
changeset
|
427 all.export |
b54404d66f7e
export: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37564
diff
changeset
|
428 lfs: found bed80f00180ac404b843628ab56a1c1984d6145c391cd1628a7dd7d2598d71fc in the local lfs store |
b54404d66f7e
export: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37564
diff
changeset
|
429 lfs: found a82f1c5cea0d40e3bb3a849686bb4e6ae47ca27e614de55c1ed0325698ef68de in the local lfs store |
b54404d66f7e
export: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37564
diff
changeset
|
430 lfs: found cf1b2787b74e66547d931b6ebe28ff63303e803cb2baa14a8f57c4383d875782 in the local lfs store |
b54404d66f7e
export: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37564
diff
changeset
|
431 lfs: found d96eda2c74b56e95cfb5ffb66b6503e198cc6fc4a09dc877de925feebc65786e in the local lfs store |
b54404d66f7e
export: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37564
diff
changeset
|
432 |
b54404d66f7e
export: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37564
diff
changeset
|
433 Export with selected files is used with `extdiff --patch` |
b54404d66f7e
export: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37564
diff
changeset
|
434 |
b54404d66f7e
export: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37564
diff
changeset
|
435 $ rm -r $TESTTMP/bulkfetch/.hg/store/lfs |
b54404d66f7e
export: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37564
diff
changeset
|
436 $ hg --config extensions.extdiff= \ |
b54404d66f7e
export: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37564
diff
changeset
|
437 > -R $TESTTMP/bulkfetch -v extdiff -r 2:tip --patch $TESTTMP/bulkfetch/lfs.bin |
b54404d66f7e
export: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37564
diff
changeset
|
438 lfs: assuming remote store: http://localhost:$HGPORT/.git/info/lfs |
b54404d66f7e
export: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37564
diff
changeset
|
439 lfs: assuming remote store: http://localhost:$HGPORT/.git/info/lfs |
b54404d66f7e
export: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37564
diff
changeset
|
440 lfs: downloading bed80f00180ac404b843628ab56a1c1984d6145c391cd1628a7dd7d2598d71fc (23 bytes) |
b54404d66f7e
export: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37564
diff
changeset
|
441 lfs: processed: bed80f00180ac404b843628ab56a1c1984d6145c391cd1628a7dd7d2598d71fc |
37765
ab04972a33ef
lfs: enable the final download count status message
Matt Harbison <matt_harbison@yahoo.com>
parents:
37764
diff
changeset
|
442 lfs: downloaded 1 files (23 bytes) |
37763
b54404d66f7e
export: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37564
diff
changeset
|
443 */hg-8374dc4052cb.patch (glob) |
b54404d66f7e
export: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37564
diff
changeset
|
444 lfs: found bed80f00180ac404b843628ab56a1c1984d6145c391cd1628a7dd7d2598d71fc in the local lfs store |
b54404d66f7e
export: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37564
diff
changeset
|
445 */hg-9640b57e77b1.patch (glob) |
b54404d66f7e
export: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37564
diff
changeset
|
446 --- */hg-8374dc4052cb.patch * (glob) |
b54404d66f7e
export: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37564
diff
changeset
|
447 +++ */hg-9640b57e77b1.patch * (glob) |
b54404d66f7e
export: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37564
diff
changeset
|
448 @@ -2,12 +2,7 @@ |
b54404d66f7e
export: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37564
diff
changeset
|
449 # User test |
b54404d66f7e
export: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37564
diff
changeset
|
450 # Date 0 0 |
b54404d66f7e
export: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37564
diff
changeset
|
451 # Thu Jan 01 00:00:00 1970 +0000 |
b54404d66f7e
export: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37564
diff
changeset
|
452 -# Node ID 8374dc4052cbd388e79d9dc4ddb29784097aa354 |
b54404d66f7e
export: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37564
diff
changeset
|
453 -# Parent 1477875038c60152e391238920a16381c627b487 |
b54404d66f7e
export: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37564
diff
changeset
|
454 -lfs |
b54404d66f7e
export: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37564
diff
changeset
|
455 +# Node ID 9640b57e77b14c3a0144fb4478b6cc13e13ea0d1 |
b54404d66f7e
export: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37564
diff
changeset
|
456 +# Parent d3b84d50eacbd56638e11abce6b8616aaba54420 |
b54404d66f7e
export: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37564
diff
changeset
|
457 +add lfs pair |
b54404d66f7e
export: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37564
diff
changeset
|
458 |
b54404d66f7e
export: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37564
diff
changeset
|
459 -diff -r 1477875038c6 -r 8374dc4052cb lfs.bin |
b54404d66f7e
export: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37564
diff
changeset
|
460 ---- /dev/null Thu Jan 01 00:00:00 1970 +0000 |
b54404d66f7e
export: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37564
diff
changeset
|
461 -+++ b/lfs.bin Thu Jan 01 00:00:00 1970 +0000 |
b54404d66f7e
export: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37564
diff
changeset
|
462 -@@ -0,0 +1,1 @@ |
b54404d66f7e
export: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37564
diff
changeset
|
463 -+this is a big lfs file |
b54404d66f7e
export: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37564
diff
changeset
|
464 cleaning up temp directory |
b54404d66f7e
export: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37564
diff
changeset
|
465 [1] |
b54404d66f7e
export: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37564
diff
changeset
|
466 |
37764
5e67c20915a7
diff: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37763
diff
changeset
|
467 Diff will prefetch files |
5e67c20915a7
diff: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37763
diff
changeset
|
468 |
5e67c20915a7
diff: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37763
diff
changeset
|
469 $ rm -r $TESTTMP/bulkfetch/.hg/store/lfs |
5e67c20915a7
diff: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37763
diff
changeset
|
470 $ hg -R $TESTTMP/bulkfetch -v diff -r 2:tip |
5e67c20915a7
diff: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37763
diff
changeset
|
471 lfs: assuming remote store: http://localhost:$HGPORT/.git/info/lfs |
5e67c20915a7
diff: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37763
diff
changeset
|
472 lfs: assuming remote store: http://localhost:$HGPORT/.git/info/lfs |
5e67c20915a7
diff: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37763
diff
changeset
|
473 lfs: need to transfer 4 objects (92 bytes) |
5e67c20915a7
diff: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37763
diff
changeset
|
474 lfs: downloading a82f1c5cea0d40e3bb3a849686bb4e6ae47ca27e614de55c1ed0325698ef68de (25 bytes) |
5e67c20915a7
diff: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37763
diff
changeset
|
475 lfs: processed: a82f1c5cea0d40e3bb3a849686bb4e6ae47ca27e614de55c1ed0325698ef68de |
5e67c20915a7
diff: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37763
diff
changeset
|
476 lfs: downloading bed80f00180ac404b843628ab56a1c1984d6145c391cd1628a7dd7d2598d71fc (23 bytes) |
5e67c20915a7
diff: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37763
diff
changeset
|
477 lfs: processed: bed80f00180ac404b843628ab56a1c1984d6145c391cd1628a7dd7d2598d71fc |
5e67c20915a7
diff: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37763
diff
changeset
|
478 lfs: downloading cf1b2787b74e66547d931b6ebe28ff63303e803cb2baa14a8f57c4383d875782 (20 bytes) |
5e67c20915a7
diff: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37763
diff
changeset
|
479 lfs: processed: cf1b2787b74e66547d931b6ebe28ff63303e803cb2baa14a8f57c4383d875782 |
5e67c20915a7
diff: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37763
diff
changeset
|
480 lfs: downloading d96eda2c74b56e95cfb5ffb66b6503e198cc6fc4a09dc877de925feebc65786e (24 bytes) |
5e67c20915a7
diff: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37763
diff
changeset
|
481 lfs: processed: d96eda2c74b56e95cfb5ffb66b6503e198cc6fc4a09dc877de925feebc65786e |
37765
ab04972a33ef
lfs: enable the final download count status message
Matt Harbison <matt_harbison@yahoo.com>
parents:
37764
diff
changeset
|
482 lfs: downloaded 4 files (92 bytes) |
37764
5e67c20915a7
diff: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37763
diff
changeset
|
483 lfs: found bed80f00180ac404b843628ab56a1c1984d6145c391cd1628a7dd7d2598d71fc in the local lfs store |
5e67c20915a7
diff: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37763
diff
changeset
|
484 lfs: found a82f1c5cea0d40e3bb3a849686bb4e6ae47ca27e614de55c1ed0325698ef68de in the local lfs store |
5e67c20915a7
diff: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37763
diff
changeset
|
485 lfs: found cf1b2787b74e66547d931b6ebe28ff63303e803cb2baa14a8f57c4383d875782 in the local lfs store |
5e67c20915a7
diff: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37763
diff
changeset
|
486 lfs: found d96eda2c74b56e95cfb5ffb66b6503e198cc6fc4a09dc877de925feebc65786e in the local lfs store |
5e67c20915a7
diff: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37763
diff
changeset
|
487 diff -r 8374dc4052cb -r 9640b57e77b1 lfs.bin |
5e67c20915a7
diff: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37763
diff
changeset
|
488 --- a/lfs.bin Thu Jan 01 00:00:00 1970 +0000 |
5e67c20915a7
diff: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37763
diff
changeset
|
489 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 |
5e67c20915a7
diff: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37763
diff
changeset
|
490 @@ -1,1 +0,0 @@ |
5e67c20915a7
diff: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37763
diff
changeset
|
491 -this is a big lfs file |
5e67c20915a7
diff: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37763
diff
changeset
|
492 diff -r 8374dc4052cb -r 9640b57e77b1 lfs2.txt |
5e67c20915a7
diff: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37763
diff
changeset
|
493 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 |
5e67c20915a7
diff: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37763
diff
changeset
|
494 +++ b/lfs2.txt Thu Jan 01 00:00:00 1970 +0000 |
5e67c20915a7
diff: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37763
diff
changeset
|
495 @@ -0,0 +1,1 @@ |
5e67c20915a7
diff: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37763
diff
changeset
|
496 +this is another lfs file |
5e67c20915a7
diff: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37763
diff
changeset
|
497 diff -r 8374dc4052cb -r 9640b57e77b1 lfspair1.bin |
5e67c20915a7
diff: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37763
diff
changeset
|
498 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 |
5e67c20915a7
diff: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37763
diff
changeset
|
499 +++ b/lfspair1.bin Thu Jan 01 00:00:00 1970 +0000 |
5e67c20915a7
diff: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37763
diff
changeset
|
500 @@ -0,0 +1,1 @@ |
5e67c20915a7
diff: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37763
diff
changeset
|
501 +this is an lfs file |
5e67c20915a7
diff: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37763
diff
changeset
|
502 diff -r 8374dc4052cb -r 9640b57e77b1 lfspair2.bin |
5e67c20915a7
diff: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37763
diff
changeset
|
503 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 |
5e67c20915a7
diff: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37763
diff
changeset
|
504 +++ b/lfspair2.bin Thu Jan 01 00:00:00 1970 +0000 |
5e67c20915a7
diff: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37763
diff
changeset
|
505 @@ -0,0 +1,1 @@ |
5e67c20915a7
diff: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37763
diff
changeset
|
506 +this is an lfs file too |
5e67c20915a7
diff: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37763
diff
changeset
|
507 diff -r 8374dc4052cb -r 9640b57e77b1 nonlfs.txt |
5e67c20915a7
diff: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37763
diff
changeset
|
508 --- a/nonlfs.txt Thu Jan 01 00:00:00 1970 +0000 |
5e67c20915a7
diff: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37763
diff
changeset
|
509 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 |
5e67c20915a7
diff: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37763
diff
changeset
|
510 @@ -1,1 +0,0 @@ |
5e67c20915a7
diff: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37763
diff
changeset
|
511 -non-lfs |
5e67c20915a7
diff: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37763
diff
changeset
|
512 diff -r 8374dc4052cb -r 9640b57e77b1 nonlfs3.txt |
5e67c20915a7
diff: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37763
diff
changeset
|
513 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 |
5e67c20915a7
diff: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37763
diff
changeset
|
514 +++ b/nonlfs3.txt Thu Jan 01 00:00:00 1970 +0000 |
5e67c20915a7
diff: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37763
diff
changeset
|
515 @@ -0,0 +1,1 @@ |
5e67c20915a7
diff: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37763
diff
changeset
|
516 +non-lfs |
5e67c20915a7
diff: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37763
diff
changeset
|
517 |
5e67c20915a7
diff: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37763
diff
changeset
|
518 Only the files required by diff are prefetched |
5e67c20915a7
diff: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37763
diff
changeset
|
519 |
5e67c20915a7
diff: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37763
diff
changeset
|
520 $ rm -r $TESTTMP/bulkfetch/.hg/store/lfs |
5e67c20915a7
diff: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37763
diff
changeset
|
521 $ hg -R $TESTTMP/bulkfetch -v diff -r 2:tip $TESTTMP/bulkfetch/lfspair2.bin |
5e67c20915a7
diff: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37763
diff
changeset
|
522 lfs: assuming remote store: http://localhost:$HGPORT/.git/info/lfs |
5e67c20915a7
diff: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37763
diff
changeset
|
523 lfs: assuming remote store: http://localhost:$HGPORT/.git/info/lfs |
5e67c20915a7
diff: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37763
diff
changeset
|
524 lfs: downloading d96eda2c74b56e95cfb5ffb66b6503e198cc6fc4a09dc877de925feebc65786e (24 bytes) |
5e67c20915a7
diff: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37763
diff
changeset
|
525 lfs: processed: d96eda2c74b56e95cfb5ffb66b6503e198cc6fc4a09dc877de925feebc65786e |
37765
ab04972a33ef
lfs: enable the final download count status message
Matt Harbison <matt_harbison@yahoo.com>
parents:
37764
diff
changeset
|
526 lfs: downloaded 1 files (24 bytes) |
37764
5e67c20915a7
diff: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37763
diff
changeset
|
527 lfs: found d96eda2c74b56e95cfb5ffb66b6503e198cc6fc4a09dc877de925feebc65786e in the local lfs store |
5e67c20915a7
diff: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37763
diff
changeset
|
528 diff -r 8374dc4052cb -r 9640b57e77b1 lfspair2.bin |
5e67c20915a7
diff: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37763
diff
changeset
|
529 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 |
5e67c20915a7
diff: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37763
diff
changeset
|
530 +++ b/lfspair2.bin Thu Jan 01 00:00:00 1970 +0000 |
5e67c20915a7
diff: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37763
diff
changeset
|
531 @@ -0,0 +1,1 @@ |
5e67c20915a7
diff: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37763
diff
changeset
|
532 +this is an lfs file too |
5e67c20915a7
diff: invoke the file prefetch hook
Matt Harbison <matt_harbison@yahoo.com>
parents:
37763
diff
changeset
|
533 |
35503
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
534 #endif |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
535 |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
536 $ $PYTHON $TESTDIR/killdaemons.py $DAEMON_PIDS |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
537 |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
538 #if lfsremote-on |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
539 $ cat $TESTTMP/errors.log | grep '^[A-Z]' |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
540 Traceback (most recent call last): |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
541 ValueError: no common changegroup version |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
542 Traceback (most recent call last): |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
543 ValueError: no common changegroup version |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
544 #else |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
545 $ cat $TESTTMP/errors.log |
bbcd2e478391
test-lfs: add tests covering http exchanges
Matt Harbison <matt_harbison@yahoo.com>
parents:
diff
changeset
|
546 #endif |