Denis Laxalde <denis@laxalde.org> [Sun, 07 Apr 2019 17:16:58 +0200] rev 42086
match: make arguments of _expandsets() optional
Arguments 'ctx', 'listsubrepos' and 'badfn' are optional in function
body.
Denis Laxalde <denis@laxalde.org> [Sun, 07 Apr 2019 17:14:29 +0200] rev 42085
match: make _donormalize's auditor and warn arguments optional
Argument 'warn' is actually non-required, since there's a 'if warn:'
check before usage. Argument 'auditor' is passed to
pathutil.canonpath(), in which it is optional.
Denis Laxalde <denis@laxalde.org> [Mon, 08 Apr 2019 09:34:50 +0200] rev 42084
match: add doctest examples in match()
Make the docstring raw, as it now includes escape characters.
Denis Laxalde <denis@laxalde.org> [Sat, 06 Apr 2019 18:20:49 +0200] rev 42083
match: complete documentation of match() parameters
Denis Laxalde <denis@laxalde.org> [Sat, 06 Apr 2019 17:54:13 +0200] rev 42082
match: add doctest examples for patkind()
Denis Laxalde <denis@laxalde.org> [Sat, 06 Apr 2019 15:21:55 +0200] rev 42081
match: add a docstring with doctest examples to patternmatcher
Doctest examples aim at illustrating how __call__() and exact() are
different, depending on the pattern kind.
Denis Laxalde <denis@laxalde.org> [Sun, 07 Apr 2019 12:21:23 +0200] rev 42080
match: add doctest examples for exactmatcher
Make the docstring raw, since it now includes escape characters.
Martin von Zweigbergk <martinvonz@google.com> [Fri, 05 Apr 2019 11:24:00 -0700] rev 42079
localrepo: don't allow lookup of working directory revision
It seems that repo.lookup(), which is what supports the "lookup" wire
protocol command, should not allow the working copy revision
input.
This fixes both the pull test and the convert test I just added.
Differential Revision: https://phab.mercurial-scm.org/D6215
Martin von Zweigbergk <martinvonz@google.com> [Fri, 05 Apr 2019 11:22:26 -0700] rev 42078
tests: demonstrate broken pull of "
ffffffffffff" revision
Differential Revision: https://phab.mercurial-scm.org/D6214
Martin von Zweigbergk <martinvonz@google.com> [Fri, 05 Apr 2019 11:12:08 -0700] rev 42077
tests: demonstrate broken `hg convert` if "
ffffffffffff" is in description
Differential Revision: https://phab.mercurial-scm.org/D6213
Martin von Zweigbergk <martinvonz@google.com> [Fri, 05 Apr 2019 11:08:17 -0700] rev 42076
tests: add test of for hash reference translation by `hg convert`
The convert extension translates commit references in the commit
message. We didn't have any explicit testing of this before, so let's
add a test.
Differential Revision: https://phab.mercurial-scm.org/D6212
Matt Harbison <matt_harbison@yahoo.com> [Fri, 05 Apr 2019 18:36:43 -0400] rev 42075
py3: write out hgextindex as bytes in setup.py
I hit this trying to build the py2exe target using python3, just to see what
would happen. After commenting out `py2exe.Distribution` in setup.py and
pointing to a local copy of py2exe that supports python3[1], it complained that
`out` was bytes, not str.
[1] https://github.com/albertosottile/py2exe/releases/tag/v0.9.3.0
Philippe Pepiot <philippe.pepiot@logilab.fr> [Thu, 04 Apr 2019 15:40:48 +0200] rev 42074
setup: fix a possible NameError on rust build
File "setup.py", line 975, in rustbuild
"command: %r, environment: %r" % (self.rustsrcdir, cmd, env))
NameError: global name 'cmd' is not defined
Arun Chandrasekaran <aruncxy@gmail.com> [Mon, 01 Apr 2019 22:11:54 -0700] rev 42073
crecord: new keys g & G to navigate to the top and bottom respectively
This patch introduces two new keys 'g' and 'G' that helps to navigate to the
top and bottom of the file/hunk/line respectively. This is inline with the shortcuts
used in man, less, more and such tools that makes it convenient to navigate
swiftly.
'g' or HOME navigates to the top most file in the ncurses window.
'G' or END navigates to the bottom most file/hunk/line depending on the whether
the fold is active or not.
If the bottom most file is folded, it navigates to that file and stops there.
If the bottom most file is unfolded, it navigates to the bottom most hunk in
that file and stops there. If the bottom most hunk is unfolded, it navigates to
the bottom most line in that hunk.
Differential Revision: https://phab.mercurial-scm.org/D6178
Jordi Gutiérrez Hermoso <jordigh@octave.org> [Thu, 04 Apr 2019 10:41:55 -0400] rev 42072
chistedit: properly show verbose diffs
I'm not sure if that ever worked and it's an internal API breakage,
but `"verbose": True` is not correctly parsed, as most of these
options are parsed by diffopts, whereas verbose is a global option.
Setting the UI to verbose instead does work and does show a verbose
patch, with full commit message.
It also shows all files, which unfortunately are a bit hard to read on
a single line in the default verbose template. Thus, we also change
the default template to use the status template, which shows one file
per line as well as its modification state.
Denis Laxalde <denis.laxalde@logilab.fr> [Thu, 04 Apr 2019 11:35:18 +0200] rev 42071
interactive: do not prompt about files given in command line
For commit and revert commands with --interactive and explicit files
given in the command line, we now skip the invite to "examine changes to
<file> ? [Ynesfdaq?]". The reason for this is that, if <file> is
specified by the user, asking for confirmation is redundant.
In patch.filterpatch(), we now use an optional "match" argument to
conditionally call the prompt() function when entering a new "header"
item. We use .exact() method to compare with files from the "header" in
order to only consider (rel)path patterns.
Add tests with glob patterns for commit and revert, to make sure we
still ask to examine files in these cases.
Gregory Szorc <gregory.szorc@gmail.com> [Thu, 04 Apr 2019 17:34:43 -0700] rev 42070
zstandard: vendor python-zstandard 0.11
The upstream source distribution from PyPI was extracted. Unwanted
files were removed.
The clang-format ignore list was updated to reflect the new source
of files.
The project contains a vendored copy of zstandard 1.3.8. The old
version was 1.3.6. This should result in some minor performance wins.
test-check-py3-compat.t was updated to reflect now-passing tests on
Python 3.8.
Some HTTP tests were updated to reflect new zstd compression output.
# no-check-commit because 3rd party code has different style guidelines
Differential Revision: https://phab.mercurial-scm.org/D6199
Gregory Szorc <gregory.szorc@gmail.com> [Thu, 04 Apr 2019 15:24:03 -0700] rev 42069
cext: make osutil.c PY_SSIZE_T_CLEAN
This is needed to avoid a deprecation warning on Python 3.8.
With this change, we no longer see deprecation warnings for
this issue on Python 3.8.
Differential Revision: https://phab.mercurial-scm.org/D6198
Gregory Szorc <gregory.szorc@gmail.com> [Thu, 04 Apr 2019 15:21:30 -0700] rev 42068
cext: make parsers.c PY_SSIZE_T_CLEAN
This is needed to avoid a deprecation warning in Python 3.8. I believe
the conversion of int to Py_ssize_t is harmless in the changed
locations. But this being C code, it should be audited with care.
Differential Revision: https://phab.mercurial-scm.org/D6197
Gregory Szorc <gregory.szorc@gmail.com> [Thu, 04 Apr 2019 15:18:06 -0700] rev 42067
cext: make revlog.c PY_SSIZE_T_CLEAN
Without this, Python 3.8 emits a deprecation warning, as using
int for # values is deprecated. Many existing modules use
PY_SSIZE_T_CLEAN, so this shouldn't be contentious.
I audited the file for all # formatters and verified we are
using Py_ssize_t everywhere now.
Differential Revision: https://phab.mercurial-scm.org/D6196
Gregory Szorc <gregory.szorc@gmail.com> [Thu, 04 Apr 2019 18:20:36 -0700] rev 42066
tests: add optional output for Python 2.7 deprecation
We already had one of these a few lines above. We need it here as
well.
Differential Revision: https://phab.mercurial-scm.org/D6203
Gregory Szorc <gregory.szorc@gmail.com> [Thu, 04 Apr 2019 18:01:48 -0700] rev 42065
setup: use raw string for regular expression
Otherwise Python 3.8 complains about the backslash.
Differential Revision: https://phab.mercurial-scm.org/D6202
Gregory Szorc <gregory.szorc@gmail.com> [Thu, 04 Apr 2019 18:01:02 -0700] rev 42064
automation: use raw strings when there are backslashes
Otherwise Python 3.8 complains.
Differential Revision: https://phab.mercurial-scm.org/D6201
Gregory Szorc <gregory.szorc@gmail.com> [Thu, 04 Apr 2019 17:47:25 -0700] rev 42063
perf: make perf.run-limits code work with Python 3
We need b'' because perf.py isn't run through the source
transformer.
We need to cast the exception to bytes using pycompat.bytestr()
because ValueError can't be %s formatted due to built-in exceptions
lacking __bytes__.
We need to pycompat.sysstr() before the float() and int() cast
so the ValueError message doesn't have b'' in it.
Even with that, it looks like the error message for the ValueError
for float casts added quotes, so we need to account for that in test
output.
Differential Revision: https://phab.mercurial-scm.org/D6200
Martin von Zweigbergk <martinvonz@google.com> [Mon, 25 Dec 2017 05:55:50 -0800] rev 42062
localrepo: rename crev in _filecommit() to cnode, since it's a node
I know we often use "rev" generically, but here's it always a node, so
it helps to be specific.
Differential Revision: https://phab.mercurial-scm.org/D6181
Jerry Montfort <jerry.montfort@fake-box.com> [Fri, 05 Apr 2019 04:09:41 +0530] rev 42061
tests: unset environment variable P in test-revset2.t (
issue6109)
The test tests/test-revset2.t fails the test case
"Test repo.anyrevs with customized revset overrides" (line 1609)
if the environment variable P is set. The test implicitly expects that the
environment, in which it is started, does not export the variable 'P'.
To solve this issue, unset 'P' right before the test commands are run.
Differential Revision: https://phab.mercurial-scm.org/D6195
Philippe Pepiot <philippe.pepiot@logilab.fr> [Thu, 04 Apr 2019 19:08:37 +0200] rev 42060
hgmanpage: use a py2 and py3 compatible iterable protocol
Philippe Pepiot <philippe.pepiot@logilab.fr> [Thu, 04 Apr 2019 19:08:05 +0200] rev 42059
hgmanpage: use range instead of xrange
Philippe Pepiot <philippe.pepiot@logilab.fr> [Thu, 04 Apr 2019 19:06:48 +0200] rev 42058
packaging: allow to run make with python3
Use "?=", otherwise the variable cannot be set from environment.
Martin von Zweigbergk <martinvonz@google.com> [Wed, 03 Apr 2019 11:21:27 -0700] rev 42057
cleanup: use set literals where possible
Differential Revision: https://phab.mercurial-scm.org/D6192