changeset 35818:d334afc585e2 stable 4.5

merge with i18n
author Augie Fackler <augie@google.com>
date Thu, 01 Feb 2018 14:11:18 -0500
parents f6ca1e11d8b4 (diff) 91c8d2e763d1 (current diff)
children 56a0da11bde5
files
diffstat 15 files changed, 180 insertions(+), 86 deletions(-) [+]
line wrap: on
line diff
--- a/Makefile	Wed Jan 31 19:41:34 2018 -0200
+++ b/Makefile	Thu Feb 01 14:11:18 2018 -0500
@@ -246,6 +246,12 @@
 docker-ubuntu-zesty-ppa: contrib/docker/ubuntu-zesty
 	contrib/dockerdeb ubuntu zesty --source-only
 
+docker-ubuntu-artful: contrib/docker/ubuntu-artful
+	contrib/dockerdeb ubuntu artful
+
+docker-ubuntu-artful-ppa: contrib/docker/ubuntu-artful
+	contrib/dockerdeb ubuntu artful --source-only
+
 fedora20:
 	mkdir -p packages/fedora20
 	contrib/buildrpm
@@ -314,6 +320,7 @@
 	docker-ubuntu-xenial docker-ubuntu-xenial-ppa \
 	docker-ubuntu-yakkety docker-ubuntu-yakkety-ppa \
 	docker-ubuntu-zesty docker-ubuntu-zesty-ppa \
+	docker-ubuntu-artful docker-ubuntu-artful-ppa \
 	fedora20 docker-fedora20 fedora21 docker-fedora21 \
 	centos5 docker-centos5 centos6 docker-centos6 centos7 docker-centos7 \
 	linux-wheels
--- a/hgext/lfs/__init__.py	Wed Jan 31 19:41:34 2018 -0200
+++ b/hgext/lfs/__init__.py	Thu Feb 01 14:11:18 2018 -0500
@@ -25,14 +25,15 @@
 not be able to communicate with each other unless the extension is
 enabled on both.
 
-To start a new repository, or add new LFS files, just create and add
-an ``.hglfs`` file as described below.  Because the file is tracked in
-the repository, all clones will use the same selection policy.  During
-subsequent commits, Mercurial will consult this file to determine if
-an added or modified file should be stored externally.  The type of
-storage depends on the characteristics of the file at each commit.  A
-file that is near a size threshold may switch back and forth between
-LFS and normal storage, as needed.
+To start a new repository, or to add LFS files to an existing one, just
+create an ``.hglfs`` file as described below in the root directory of
+the repository.  Typically, this file should be put under version
+control, so that the settings will propagate to other repositories with
+push and pull.  During any commit, Mercurial will consult this file to
+determine if an added or modified file should be stored externally.  The
+type of storage depends on the characteristics of the file at each
+commit.  A file that is near a size threshold may switch back and forth
+between LFS and normal storage, as needed.
 
 Alternately, both normal repositories and largefile controlled
 repositories can be converted to LFS by using :hg:`convert` and the
@@ -240,29 +241,19 @@
 def _trackedmatcher(repo, ctx):
     """Return a function (path, size) -> bool indicating whether or not to
     track a given file with lfs."""
-    data = ''
-
-    if '.hglfs' in ctx.added() or '.hglfs' in ctx.modified():
-        data = ctx['.hglfs'].data()
-    elif '.hglfs' not in ctx.removed():
-        p1 = repo['.']
-
-        if '.hglfs' not in p1:
-            # No '.hglfs' in wdir or in parent.  Fallback to config
-            # for now.
-            trackspec = repo.ui.config('lfs', 'track')
+    if not repo.wvfs.exists('.hglfs'):
+        # No '.hglfs' in wdir.  Fallback to config for now.
+        trackspec = repo.ui.config('lfs', 'track')
 
-            # deprecated config: lfs.threshold
-            threshold = repo.ui.configbytes('lfs', 'threshold')
-            if threshold:
-                fileset.parse(trackspec)  # make sure syntax errors are confined
-                trackspec = "(%s) | size('>%d')" % (trackspec, threshold)
+        # deprecated config: lfs.threshold
+        threshold = repo.ui.configbytes('lfs', 'threshold')
+        if threshold:
+            fileset.parse(trackspec)  # make sure syntax errors are confined
+            trackspec = "(%s) | size('>%d')" % (trackspec, threshold)
 
-            return minifileset.compile(trackspec)
+        return minifileset.compile(trackspec)
 
-        data = p1['.hglfs'].data()
-
-    # In removed, or not in parent
+    data = repo.wvfs.tryread('.hglfs')
     if not data:
         return lambda p, s: False
 
--- a/hgext/uncommit.py	Wed Jan 31 19:41:34 2018 -0200
+++ b/hgext/uncommit.py	Thu Feb 01 14:11:18 2018 -0500
@@ -193,8 +193,7 @@
 
 @command('^unamend', [])
 def unamend(ui, repo, **opts):
-    """
-    undo the most recent amend operation on a current changeset
+    """undo the most recent amend operation on a current changeset
 
     This command will roll back to the previous version of a changeset,
     leaving working directory in state in which it was before running
--- a/mercurial/bundle2.py	Wed Jan 31 19:41:34 2018 -0200
+++ b/mercurial/bundle2.py	Thu Feb 01 14:11:18 2018 -0500
@@ -2033,7 +2033,7 @@
             for book, node in changes:
                 hookargs = tr.hookargs.copy()
                 hookargs['pushkeycompat'] = '1'
-                hookargs['namespace'] = 'bookmark'
+                hookargs['namespace'] = 'bookmarks'
                 hookargs['key'] = book
                 hookargs['old'] = nodemod.hex(bookstore.get(book, ''))
                 hookargs['new'] = nodemod.hex(node if node is not None else '')
@@ -2143,7 +2143,7 @@
 @parthandler('stream2', ('requirements', 'filecount', 'bytecount'))
 def handlestreamv2bundle(op, part):
 
-    requirements = part.params['requirements'].split()
+    requirements = urlreq.unquote(part.params['requirements']).split(',')
     filecount = int(part.params['filecount'])
     bytecount = int(part.params['bytecount'])
 
--- a/mercurial/cext/manifest.c	Wed Jan 31 19:41:34 2018 -0200
+++ b/mercurial/cext/manifest.c	Thu Feb 01 14:11:18 2018 -0500
@@ -778,11 +778,11 @@
 		PyObject *outer;
 		/* If we're looking at a deleted entry and it's not
 		 * the end of the manifest, just skip it. */
-		if (left->deleted && sneedle < self->numlines) {
+		if (sneedle < self->numlines && left->deleted) {
 			sneedle++;
 			continue;
 		}
-		if (right->deleted && oneedle < other->numlines) {
+		if (oneedle < other->numlines && right->deleted) {
 			oneedle++;
 			continue;
 		}
--- a/mercurial/configitems.py	Wed Jan 31 19:41:34 2018 -0200
+++ b/mercurial/configitems.py	Thu Feb 01 14:11:18 2018 -0500
@@ -17,7 +17,7 @@
 
 def loadconfigtable(ui, extname, configtable):
     """update config item known to the ui with the extension ones"""
-    for section, items in configtable.items():
+    for section, items in sorted(configtable.items()):
         knownitems = ui._knownconfig.setdefault(section, itemregister())
         knownkeys = set(knownitems)
         newkeys = set(items)
--- a/mercurial/exchange.py	Wed Jan 31 19:41:34 2018 -0200
+++ b/mercurial/exchange.py	Thu Feb 01 14:11:18 2018 -0500
@@ -199,6 +199,14 @@
     else:
         raise error.Abort(_('%s: unknown bundle version %s') % (fname, version))
 
+def _formatrequirementsspec(requirements):
+    return urlreq.quote(','.join(sorted(requirements)))
+
+def _formatrequirementsparams(requirements):
+    requirements = _formatrequirementsspec(requirements)
+    params = "%s%s" % (urlreq.quote("requirements="), requirements)
+    return params
+
 def getbundlespec(ui, fh):
     """Infer the bundlespec from a bundle file handle.
 
@@ -247,8 +255,7 @@
         return '%s-%s' % (comp, version)
     elif isinstance(b, streamclone.streamcloneapplier):
         requirements = streamclone.readbundle1header(fh)[2]
-        params = 'requirements=%s' % ','.join(sorted(requirements))
-        return 'none-packed1;%s' % urlreq.quote(params)
+        return 'none-packed1;%s' % _formatrequirementsparams(requirements)
     else:
         raise error.Abort(_('unknown bundle type: %s') % b)
 
@@ -1786,7 +1793,7 @@
     bundler.prefercompressed = False
 
     filecount, bytecount, it = streamclone.generatev2(repo)
-    requirements = ' '.join(sorted(repo.requirements))
+    requirements = _formatrequirementsspec(repo.requirements)
     part = bundler.newpart('stream2', data=it)
     part.addparam('bytecount', '%d' % bytecount, mandatory=True)
     part.addparam('filecount', '%d' % filecount, mandatory=True)
--- a/mercurial/revset.py	Wed Jan 31 19:41:34 2018 -0200
+++ b/mercurial/revset.py	Thu Feb 01 14:11:18 2018 -0500
@@ -1065,7 +1065,9 @@
             if rev is not None:
                 raise error.ParseError('_matchfiles expected at most one '
                                        'revision')
-            if value != '': # empty means working directory; leave rev as None
+            if value == '': # empty means working directory
+                rev = node.wdirrev
+            else:
                 rev = value
         elif prefix == 'd:':
             if default is not None:
@@ -1076,9 +1078,9 @@
             raise error.ParseError('invalid _matchfiles prefix: %s' % prefix)
     if not default:
         default = 'glob'
+    hasset = any(matchmod.patkind(p) == 'set' for p in pats + inc + exc)
 
-    m = matchmod.match(repo.root, repo.getcwd(), pats, include=inc,
-                       exclude=exc, ctx=repo[rev], default=default)
+    mcache = [None]
 
     # This directly read the changelog data as creating changectx for all
     # revisions is quite expensive.
@@ -1089,6 +1091,14 @@
             files = repo[x].files()
         else:
             files = getfiles(x)
+
+        if not mcache[0] or (hasset and rev is None):
+            r = x if rev is None else rev
+            mcache[0] = matchmod.match(repo.root, repo.getcwd(), pats,
+                                       include=inc, exclude=exc, ctx=repo[r],
+                                       default=default)
+        m = mcache[0]
+
         for f in files:
             if m(f):
                 return True
--- a/tests/test-bookmarks-pushpull.t	Wed Jan 31 19:41:34 2018 -0200
+++ b/tests/test-bookmarks-pushpull.t	Thu Feb 01 14:11:18 2018 -0500
@@ -1173,3 +1173,76 @@
 
   $ hg -R ../issue4455-dest/ bookmarks
   no bookmarks set
+
+  $ cd ..
+
+Test that pre-pushkey compat for bookmark works as expected (issue5777)
+
+  $ cat << EOF >> $HGRCPATH
+  > [ui]
+  > ssh="$PYTHON" "$TESTDIR/dummyssh"
+  > [server]
+  > bookmarks-pushkey-compat = yes
+  > EOF
+
+  $ hg init server
+  $ echo foo > server/a
+  $ hg -R server book foo
+  $ hg -R server commit -Am a
+  adding a
+  $ hg clone ssh://user@dummy/server client
+  requesting all changes
+  adding changesets
+  adding manifests
+  adding file changes
+  added 1 changesets with 1 changes to 1 files
+  new changesets 79513d0d7716
+  updating to branch default
+  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
+
+Forbid bookmark move on the server
+
+  $ cat << EOF >> $TESTDIR/no-bm-move.sh
+  > #!/bin/sh
+  > echo \$HG_NAMESPACE | grep -v bookmarks
+  > EOF
+  $ cat << EOF >> server/.hg/hgrc
+  > [hooks]
+  > prepushkey.no-bm-move= sh $TESTDIR/no-bm-move.sh
+  > EOF
+
+pushing changeset is okay
+
+  $ echo bar >> client/a
+  $ hg -R client commit -m b
+  $ hg -R client push
+  pushing to ssh://user@dummy/server
+  searching for changes
+  remote: adding changesets
+  remote: adding manifests
+  remote: adding file changes
+  remote: added 1 changesets with 1 changes to 1 files
+
+attempt to move the bookmark is rejected
+
+  $ hg -R client book foo -r .
+  moving bookmark 'foo' forward from 79513d0d7716
+
+#if b2-pushkey
+  $ hg -R client push
+  pushing to ssh://user@dummy/server
+  searching for changes
+  no changes found
+  remote: pushkey-abort: prepushkey.no-bm-move hook exited with status 1
+  abort: updating bookmark foo failed!
+  [255]
+#endif
+#if b2-binary
+  $ hg -R client push
+  pushing to ssh://user@dummy/server
+  searching for changes
+  no changes found
+  remote: prepushkey.no-bm-move hook exited with status 1
+  abort: push failed on remote
+  [255]
+#endif
--- a/tests/test-bundle2-exchange.t	Wed Jan 31 19:41:34 2018 -0200
+++ b/tests/test-bundle2-exchange.t	Thu Feb 01 14:11:18 2018 -0500
@@ -253,7 +253,7 @@
   remote: added 1 changesets with 0 changes to 0 files (-1 heads)
   remote: 1 new obsolescence markers
   remote: pre-close-tip:eea13746799a public book_eea1
-  remote: pushkey: lock state after "bookmark"
+  remote: pushkey: lock state after "bookmarks"
   remote: lock:  free
   remote: wlock: free
   remote: postclose-tip:eea13746799a public book_eea1
@@ -339,7 +339,7 @@
   remote: added 1 changesets with 1 changes to 1 files
   remote: 1 new obsolescence markers
   remote: pre-close-tip:5fddd98957c8 draft book_5fdd
-  remote: pushkey: lock state after "bookmark"
+  remote: pushkey: lock state after "bookmarks"
   remote: lock:  free
   remote: wlock: free
   remote: postclose-tip:5fddd98957c8 draft book_5fdd
@@ -390,7 +390,7 @@
   remote: added 1 changesets with 1 changes to 1 files
   remote: 1 new obsolescence markers
   remote: pre-close-tip:32af7686d403 public book_32af
-  remote: pushkey: lock state after "bookmark"
+  remote: pushkey: lock state after "bookmarks"
   remote: lock:  free
   remote: wlock: free
   remote: postclose-tip:32af7686d403 public book_32af
--- a/tests/test-clone-uncompressed.t	Wed Jan 31 19:41:34 2018 -0200
+++ b/tests/test-clone-uncompressed.t	Thu Feb 01 14:11:18 2018 -0500
@@ -199,23 +199,23 @@
   
 
   $ f --size --hex --bytes 256 body
-  body: size=112222
+  body: size=112230
   0000: 04 6e 6f 6e 65 48 47 32 30 00 00 00 00 00 00 00 |.noneHG20.......|
-  0010: 68 07 53 54 52 45 41 4d 32 00 00 00 00 03 00 09 |h.STREAM2.......|
-  0020: 05 09 04 0c 2d 62 79 74 65 63 6f 75 6e 74 39 38 |....-bytecount98|
+  0010: 70 07 53 54 52 45 41 4d 32 00 00 00 00 03 00 09 |p.STREAM2.......|
+  0020: 05 09 04 0c 35 62 79 74 65 63 6f 75 6e 74 39 38 |....5bytecount98|
   0030: 37 35 38 66 69 6c 65 63 6f 75 6e 74 31 30 33 30 |758filecount1030|
   0040: 72 65 71 75 69 72 65 6d 65 6e 74 73 64 6f 74 65 |requirementsdote|
-  0050: 6e 63 6f 64 65 20 66 6e 63 61 63 68 65 20 67 65 |ncode fncache ge|
-  0060: 6e 65 72 61 6c 64 65 6c 74 61 20 72 65 76 6c 6f |neraldelta revlo|
-  0070: 67 76 31 20 73 74 6f 72 65 00 00 80 00 73 08 42 |gv1 store....s.B|
-  0080: 64 61 74 61 2f 30 2e 69 00 03 00 01 00 00 00 00 |data/0.i........|
-  0090: 00 00 00 02 00 00 00 01 00 00 00 00 00 00 00 01 |................|
-  00a0: ff ff ff ff ff ff ff ff 80 29 63 a0 49 d3 23 87 |.........)c.I.#.|
-  00b0: bf ce fe 56 67 92 67 2c 69 d1 ec 39 00 00 00 00 |...Vg.g,i..9....|
-  00c0: 00 00 00 00 00 00 00 00 75 30 73 08 42 64 61 74 |........u0s.Bdat|
-  00d0: 61 2f 31 2e 69 00 03 00 01 00 00 00 00 00 00 00 |a/1.i...........|
-  00e0: 02 00 00 00 01 00 00 00 00 00 00 00 01 ff ff ff |................|
-  00f0: ff ff ff ff ff f9 76 da 1d 0d f2 25 6c de 08 db |......v....%l...|
+  0050: 6e 63 6f 64 65 25 32 43 66 6e 63 61 63 68 65 25 |ncode%2Cfncache%|
+  0060: 32 43 67 65 6e 65 72 61 6c 64 65 6c 74 61 25 32 |2Cgeneraldelta%2|
+  0070: 43 72 65 76 6c 6f 67 76 31 25 32 43 73 74 6f 72 |Crevlogv1%2Cstor|
+  0080: 65 00 00 80 00 73 08 42 64 61 74 61 2f 30 2e 69 |e....s.Bdata/0.i|
+  0090: 00 03 00 01 00 00 00 00 00 00 00 02 00 00 00 01 |................|
+  00a0: 00 00 00 00 00 00 00 01 ff ff ff ff ff ff ff ff |................|
+  00b0: 80 29 63 a0 49 d3 23 87 bf ce fe 56 67 92 67 2c |.)c.I.#....Vg.g,|
+  00c0: 69 d1 ec 39 00 00 00 00 00 00 00 00 00 00 00 00 |i..9............|
+  00d0: 75 30 73 08 42 64 61 74 61 2f 31 2e 69 00 03 00 |u0s.Bdata/1.i...|
+  00e0: 01 00 00 00 00 00 00 00 02 00 00 00 01 00 00 00 |................|
+  00f0: 00 00 00 00 01 ff ff ff ff ff ff ff ff f9 76 da |..............v.|
 
 --uncompressed is an alias to --stream
 
--- a/tests/test-glog.t	Wed Jan 31 19:41:34 2018 -0200
+++ b/tests/test-glog.t	Thu Feb 01 14:11:18 2018 -0500
@@ -1675,7 +1675,7 @@
       (string 'p:c')))
   <filteredset
     <spanset- 0:5>,
-    <matchfiles patterns=['a', 'c'], include=[] exclude=[], default='relpath', rev=None>>
+    <matchfiles patterns=['a', 'c'], include=[] exclude=[], default='relpath', rev=2147483647>>
 
 Test multiple --include/--exclude/paths
 
@@ -1694,7 +1694,7 @@
       (string 'x:e')))
   <filteredset
     <spanset- 0:5>,
-    <matchfiles patterns=['a', 'e'], include=['a', 'e'] exclude=['b', 'e'], default='relpath', rev=None>>
+    <matchfiles patterns=['a', 'e'], include=['a', 'e'] exclude=['b', 'e'], default='relpath', rev=2147483647>>
 
 Test glob expansion of pats
 
@@ -1732,7 +1732,7 @@
       (string 'p:dir')))
   <filteredset
     <generatorsetdesc->,
-    <matchfiles patterns=['dir'], include=[] exclude=[], default='relpath', rev=None>>
+    <matchfiles patterns=['dir'], include=[] exclude=[], default='relpath', rev=2147483647>>
   $ hg up -q tip
 
 Test --follow on file not in parent revision
@@ -1754,7 +1754,7 @@
       (string 'p:glob:*')))
   <filteredset
     <generatorsetdesc->,
-    <matchfiles patterns=['glob:*'], include=[] exclude=[], default='relpath', rev=None>>
+    <matchfiles patterns=['glob:*'], include=[] exclude=[], default='relpath', rev=2147483647>>
 
 Test --follow on a single rename
 
@@ -1875,7 +1875,7 @@
       (string 'p:set:copied()')))
   <filteredset
     <spanset- 0:7>,
-    <matchfiles patterns=['set:copied()'], include=[] exclude=[], default='relpath', rev=None>>
+    <matchfiles patterns=['set:copied()'], include=[] exclude=[], default='relpath', rev=2147483647>>
   $ testlog --include "set:copied()"
   []
   (func
@@ -1886,11 +1886,13 @@
       (string 'i:set:copied()')))
   <filteredset
     <spanset- 0:7>,
-    <matchfiles patterns=[], include=['set:copied()'] exclude=[], default='relpath', rev=None>>
+    <matchfiles patterns=[], include=['set:copied()'] exclude=[], default='relpath', rev=2147483647>>
   $ testlog -r "sort(file('set:copied()'), -rev)"
   ["sort(file('set:copied()'), -rev)"]
   []
-  <baseset []>
+  <filteredset
+    <fullreposet- 0:7>,
+    <matchfiles patterns=['set:copied()'], include=[] exclude=[], default='glob', rev=None>>
 
 Test --removed
 
@@ -1908,7 +1910,7 @@
       (string 'p:a')))
   <filteredset
     <spanset- 0:7>,
-    <matchfiles patterns=['a'], include=[] exclude=[], default='relpath', rev=None>>
+    <matchfiles patterns=['a'], include=[] exclude=[], default='relpath', rev=2147483647>>
   $ testlog --removed --follow a
   []
   (func
@@ -1919,7 +1921,7 @@
       (string 'p:a')))
   <filteredset
     <generatorsetdesc->,
-    <matchfiles patterns=['a'], include=[] exclude=[], default='relpath', rev=None>>
+    <matchfiles patterns=['a'], include=[] exclude=[], default='relpath', rev=2147483647>>
 
 Test --patch and --stat with --follow and --follow-first
 
@@ -2290,7 +2292,7 @@
       (string 'p:.')))
   <filteredset
     <spanset- 0:9>,
-    <matchfiles patterns=['.'], include=[] exclude=[], default='relpath', rev=None>>
+    <matchfiles patterns=['.'], include=[] exclude=[], default='relpath', rev=2147483647>>
   $ testlog ../b
   []
   (func
--- a/tests/test-hook.t	Wed Jan 31 19:41:34 2018 -0200
+++ b/tests/test-hook.t	Thu Feb 01 14:11:18 2018 -0500
@@ -244,7 +244,7 @@
   no changes found
   pretxnopen hook: HG_HOOKNAME=pretxnopen HG_HOOKTYPE=pretxnopen HG_TXNID=TXN:$ID$ HG_TXNNAME=push
   pretxnclose hook: HG_BOOKMARK_MOVED=1 HG_BUNDLE2=1 HG_HOOKNAME=pretxnclose HG_HOOKTYPE=pretxnclose HG_PENDING=$TESTTMP/a HG_SOURCE=push HG_TXNID=TXN:$ID$ HG_TXNNAME=push HG_URL=file:$TESTTMP/a
-  pushkey hook: HG_BUNDLE2=1 HG_HOOKNAME=pushkey HG_HOOKTYPE=pushkey HG_KEY=foo HG_NAMESPACE=bookmark HG_NEW=0000000000000000000000000000000000000000 HG_PUSHKEYCOMPAT=1 HG_SOURCE=push HG_TXNID=TXN:$ID$ HG_URL=file:$TESTTMP/a
+  pushkey hook: HG_BUNDLE2=1 HG_HOOKNAME=pushkey HG_HOOKTYPE=pushkey HG_KEY=foo HG_NAMESPACE=bookmarks HG_NEW=0000000000000000000000000000000000000000 HG_PUSHKEYCOMPAT=1 HG_SOURCE=push HG_TXNID=TXN:$ID$ HG_URL=file:$TESTTMP/a
   txnclose hook: HG_BOOKMARK_MOVED=1 HG_BUNDLE2=1 HG_HOOKNAME=txnclose HG_HOOKTYPE=txnclose HG_SOURCE=push HG_TXNID=TXN:$ID$ HG_TXNNAME=push HG_URL=file:$TESTTMP/a
   exporting bookmark foo
   [1]
@@ -281,7 +281,7 @@
   listkeys hook: HG_HOOKNAME=listkeys HG_HOOKTYPE=listkeys HG_NAMESPACE=bookmarks HG_VALUES={'bar': '0000000000000000000000000000000000000000', 'foo': '0000000000000000000000000000000000000000'}
   no changes found
   pretxnopen hook: HG_HOOKNAME=pretxnopen HG_HOOKTYPE=pretxnopen HG_TXNID=TXN:$ID$ HG_TXNNAME=push
-  prepushkey.forbid hook: HG_BUNDLE2=1 HG_HOOKNAME=prepushkey HG_HOOKTYPE=prepushkey HG_KEY=baz HG_NAMESPACE=bookmark HG_NEW=0000000000000000000000000000000000000000 HG_PUSHKEYCOMPAT=1 HG_SOURCE=push HG_TXNID=TXN:$ID$ HG_URL=file:$TESTTMP/a
+  prepushkey.forbid hook: HG_BUNDLE2=1 HG_HOOKNAME=prepushkey HG_HOOKTYPE=prepushkey HG_KEY=baz HG_NAMESPACE=bookmarks HG_NEW=0000000000000000000000000000000000000000 HG_PUSHKEYCOMPAT=1 HG_SOURCE=push HG_TXNID=TXN:$ID$ HG_URL=file:$TESTTMP/a
   abort: prepushkey hook exited with status 1
   [255]
   $ cd ../a
--- a/tests/test-largefiles-update.t	Wed Jan 31 19:41:34 2018 -0200
+++ b/tests/test-largefiles-update.t	Thu Feb 01 14:11:18 2018 -0500
@@ -726,6 +726,20 @@
 
 #endif
 
+The fileset revset is evaluated for each revision, instead of once on wdir(),
+and then patterns matched on each revision.  Here, no exec bits are set in
+wdir(), but a matching revision is detected.
+
+(Teach large2 is not an executable. Maybe this is a bug of largefiles.)
+#if execbit
+  $ chmod -x .hglf/large2
+#endif
+
+  $ hg files 'set:exec()'
+  [1]
+  $ hg log -qr 'file("set:exec()")'
+  9:be1b433a65b1
+
 Test a fatal error interrupting an update. Verify that status report dirty
 files correctly after an interrupted update. Also verify that checking all
 hashes reveals it isn't clean.
--- a/tests/test-lfs.t	Wed Jan 31 19:41:34 2018 -0200
+++ b/tests/test-lfs.t	Thu Feb 01 14:11:18 2018 -0500
@@ -984,27 +984,28 @@
   > ** = size(">10B")
   > EOF
 
-The LFS policy takes effect as the .hglfs file is committed
+The LFS policy takes effect without tracking the .hglfs file
 
   $ echo 'largefile' > lfs.test
   $ echo '012345678901234567890' > nolfs.exclude
   $ echo '01234567890123456' > lfs.catchall
-  $ hg ci -Aqm 'added .hglfs'
+  $ hg add *
+  $ hg ci -qm 'before add .hglfs'
   $ hg log -r . -T '{rev}: {lfs_files % "{file}: {lfsoid}\n"}\n'
   2: lfs.catchall: d4ec46c2869ba22eceb42a729377432052d9dd75d82fc40390ebaadecee87ee9
   lfs.test: 5489e6ced8c36a7b267292bde9fd5242a5f80a7482e8f23fa0477393dfaa4d6c
   
-The existing .hglfs file is used even when it is not in the 'A' or 'M' states
+The .hglfs file works when tracked
 
   $ echo 'largefile2' > lfs.test
   $ echo '012345678901234567890a' > nolfs.exclude
   $ echo '01234567890123456a' > lfs.catchall
-  $ hg ci -qm 'unmodified .hglfs'
+  $ hg ci -Aqm 'after adding .hglfs'
   $ hg log -r . -T '{rev}: {lfs_files % "{file}: {lfsoid}\n"}\n'
   3: lfs.catchall: 31f43b9c62b540126b0ad5884dc013d21a61c9329b77de1fceeae2fc58511573
   lfs.test: 8acd23467967bc7b8cc5a280056589b0ba0b17ff21dbd88a7b6474d6290378a6
   
-Excluding the .hglfs file from the commit postpones the policy change
+The LFS policy stops when the .hglfs is gone
 
   $ hg rm .hglfs
   $ echo 'largefile3' > lfs.test
@@ -1012,17 +1013,7 @@
   $ echo '01234567890123456abc' > lfs.catchall
   $ hg ci -qm 'file test' -X .hglfs
   $ hg log -r . -T '{rev}: {lfs_files % "{file}: {lfsoid}\n"}\n'
-  4: lfs.catchall: 6747cfb1b83965b4a884e7a6061813ae31e4122028bc6a88d2ac5e5f9e05c5af
-  lfs.test: 3f40b70c2294e91e0fa789ebcf73c5a1d1c7aef270f83e477e40cb0513237e8c
-  
-The policy change takes effect when the .hglfs is committed
-
-  $ echo 'largefile4' > lfs.test
-  $ echo '012345678901234567890abcdef' > nolfs.exclude
-  $ echo '01234567890123456abcdef' > lfs.catchall
-  $ hg ci -qm 'file test'
-  $ hg log -r . -T '{rev}: {lfs_files % "{file}: {lfsoid}\n"}\n'
-  5: 
+  4: 
 
   $ cd ..