##// END OF EJS Templates
tests: show that debugrebuilddirstate is broken with narrow+sparse...
Pulkit Goyal -
r41184:76dcf795 default
parent child Browse files
Show More
@@ -1,67 +1,109 b''
1 1 Testing interaction of sparse and narrow when both are enabled on the client
2 2 side and we do a non-ellipsis clone
3 3
4 4 #testcases tree flat
5 5 $ . "$TESTDIR/narrow-library.sh"
6 6 $ cat << EOF >> $HGRCPATH
7 7 > [extensions]
8 8 > sparse =
9 9 > EOF
10 10
11 11 #if tree
12 12 $ cat << EOF >> $HGRCPATH
13 13 > [experimental]
14 14 > treemanifest = 1
15 15 > EOF
16 16 #endif
17 17
18 18 $ hg init master
19 19 $ cd master
20 20
21 21 $ mkdir inside
22 22 $ echo 'inside' > inside/f
23 23 $ hg add inside/f
24 24 $ hg commit -m 'add inside'
25 25
26 26 $ mkdir widest
27 27 $ echo 'widest' > widest/f
28 28 $ hg add widest/f
29 29 $ hg commit -m 'add widest'
30 30
31 31 $ mkdir outside
32 32 $ echo 'outside' > outside/f
33 33 $ hg add outside/f
34 34 $ hg commit -m 'add outside'
35 35
36 36 $ cd ..
37 37
38 38 narrow clone the inside file
39 39
40 40 $ hg clone --narrow ssh://user@dummy/master narrow --include inside/f
41 41 requesting all changes
42 42 adding changesets
43 43 adding manifests
44 44 adding file changes
45 45 added 3 changesets with 1 changes to 1 files
46 46 new changesets *:* (glob)
47 47 updating to branch default
48 48 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
49 49 $ cd narrow
50 50 $ hg tracked
51 51 I path:inside/f
52 52 $ hg files
53 53 inside/f
54 54
55 55 XXX: we should have a flag in `hg debugsparse` to list the sparse profile
56 56 $ test -f .hg/sparse
57 57 [1]
58 58
59 59 $ cat .hg/requires
60 60 dotencode
61 61 fncache
62 62 generaldelta
63 63 narrowhg-experimental
64 64 revlogv1
65 65 sparserevlog
66 66 store
67 67 treemanifest (tree !)
68
69 $ hg debugrebuilddirstate
70 ** unknown exception encountered, please report by visiting
71 ** https://mercurial-scm.org/wiki/BugTracker
72 ** Python 2.7.12 (default, Nov 12 2018, 14:36:49) [GCC 5.4.0 20160609]
73 ** Mercurial Distributed SCM (version 4.8.1+588-479a5ea51ccc+20181224)
74 ** Extensions loaded: narrow, sparse
75 Traceback (most recent call last):
76 File "/place/vartmp/hgtests.zMelCK/install/bin/hg", line 43, in <module>
77 dispatch.run()
78 File "/place/vartmp/hgtests.zMelCK/install/lib/python/mercurial/dispatch.py", line 99, in run
79 status = dispatch(req)
80 File "/place/vartmp/hgtests.zMelCK/install/lib/python/mercurial/dispatch.py", line 225, in dispatch
81 ret = _runcatch(req) or 0
82 File "/place/vartmp/hgtests.zMelCK/install/lib/python/mercurial/dispatch.py", line 376, in _runcatch
83 return _callcatch(ui, _runcatchfunc)
84 File "/place/vartmp/hgtests.zMelCK/install/lib/python/mercurial/dispatch.py", line 384, in _callcatch
85 return scmutil.callcatch(ui, func)
86 File "/place/vartmp/hgtests.zMelCK/install/lib/python/mercurial/scmutil.py", line 166, in callcatch
87 return func()
88 File "/place/vartmp/hgtests.zMelCK/install/lib/python/mercurial/dispatch.py", line 367, in _runcatchfunc
89 return _dispatch(req)
90 File "/place/vartmp/hgtests.zMelCK/install/lib/python/mercurial/dispatch.py", line 1021, in _dispatch
91 cmdpats, cmdoptions)
92 File "/place/vartmp/hgtests.zMelCK/install/lib/python/mercurial/dispatch.py", line 756, in runcommand
93 ret = _runcommand(ui, options, cmd, d)
94 File "/place/vartmp/hgtests.zMelCK/install/lib/python/mercurial/dispatch.py", line 1030, in _runcommand
95 return cmdfunc()
96 File "/place/vartmp/hgtests.zMelCK/install/lib/python/mercurial/dispatch.py", line 1018, in <lambda>
97 d = lambda: util.checksignature(func)(ui, *args, **strcmdopt)
98 File "/place/vartmp/hgtests.zMelCK/install/lib/python/mercurial/util.py", line 1670, in check
99 return func(*args, **kwargs)
100 File "/place/vartmp/hgtests.zMelCK/install/lib/python/mercurial/debugcommands.py", line 1998, in debugrebuilddirstate
101 dirstate.rebuild(ctx.node(), ctx.manifest(), changedfiles)
102 File "/place/vartmp/hgtests.zMelCK/install/lib/python/hgext/narrow/narrowdirstate.py", line 60, in rebuild
103 super(narrowdirstate, self).rebuild(parent, allfiles, changedfiles)
104 File "/place/vartmp/hgtests.zMelCK/install/lib/python/mercurial/extensions.py", line 437, in closure
105 return func(*(args + a), **kw)
106 File "/place/vartmp/hgtests.zMelCK/install/lib/python/hgext/sparse.py", line 213, in _rebuild
107 allfiles = allfiles.matches(matcher)
108 AttributeError: 'list' object has no attribute 'matches'
109 [1]
General Comments 0
You need to be logged in to leave comments. Login now