Tue, 18 Dec 2018 10:21:25 -0500 merge with stable
Augie Fackler <augie@google.com> [Tue, 18 Dec 2018 10:21:25 -0500] rev 40989
merge with stable
Tue, 11 Dec 2018 22:34:07 +0900 worker: do not swallow exception occurred in main process stable
Yuya Nishihara <yuya@tcha.org> [Tue, 11 Dec 2018 22:34:07 +0900] rev 40988
worker: do not swallow exception occurred in main process Before, SystemExit(255) would be most likely raised since the worker processes were terminated by the main process and the status would be set to 255 in response. We should instead re-raise the exception occurred first. It's pretty hard to debug problems like the issue 6035 with no traceback.
Mon, 17 Dec 2018 20:46:09 +0900 run-tests: fix permission to clean up unreadable directories stable
Yuya Nishihara <yuya@tcha.org> [Mon, 17 Dec 2018 20:46:09 +0900] rev 40987
run-tests: fix permission to clean up unreadable directories I found many hgtests.* directories left in $TMPDIR, which couldn't be deleted because test-ssh-repoerror.t created some directories with a-rx mode.
Sun, 16 Dec 2018 17:08:46 +0900 context: reimplement memfilectx.cmp() stable
Yuya Nishihara <yuya@tcha.org> [Sun, 16 Dec 2018 17:08:46 +0900] rev 40986
context: reimplement memfilectx.cmp() If I added a sanity check to basefilectx, test-context.py exploded. This patch copies the naive implementation from overlayworkingfilectx.
Mon, 17 Dec 2018 15:05:52 +0100 rust-cpython: build and support for Python3
Georges Racinet <gracinet@anybox.fr> [Mon, 17 Dec 2018 15:05:52 +0100] rev 40985
rust-cpython: build and support for Python3 Defined Cargo features for Python3, making them overall simpler to use, hooked them in build and made mercurial.rustext importable. This is tested with Python 3.6.7. Differential Revision: https://phab.mercurial-scm.org/D5446
Tue, 18 Dec 2018 00:54:32 -0500 py3: convert popen() command arguments in hgclient to str on Windows
Matt Harbison <matt_harbison@yahoo.com> [Tue, 18 Dec 2018 00:54:32 -0500] rev 40984
py3: convert popen() command arguments in hgclient to str on Windows This fixes test-commandserver.t and test-keyword.t, which was previously complaining TypeError("a bytes-like object is required, not 'str'")
Mon, 17 Dec 2018 23:08:26 -0500 py3: byteify tests/pullext.py
Matt Harbison <matt_harbison@yahoo.com> [Mon, 17 Dec 2018 23:08:26 -0500] rev 40983
py3: byteify tests/pullext.py # skip-blame for b'' prepending
Mon, 17 Dec 2018 21:27:37 -0500 py3: byteify the fakeversion extension in test-http-bad-server.t
Matt Harbison <matt_harbison@yahoo.com> [Mon, 17 Dec 2018 21:27:37 -0500] rev 40982
py3: byteify the fakeversion extension in test-http-bad-server.t # skip-blame for b'' prefixing
Mon, 17 Dec 2018 18:25:18 -0500 py3: spawn all python instances with legacy stdio enabled on Windows
Matt Harbison <matt_harbison@yahoo.com> [Mon, 17 Dec 2018 18:25:18 -0500] rev 40981
py3: spawn all python instances with legacy stdio enabled on Windows This fixes 6 more tests. See ef7119cd4965.
Mon, 17 Dec 2018 17:44:45 -0500 setup: avoid attempting to invoke the system-wide hg.exe on Windows
Matt Harbison <matt_harbison@yahoo.com> [Mon, 17 Dec 2018 17:44:45 -0500] rev 40980
setup: avoid attempting to invoke the system-wide hg.exe on Windows On Windows, the executable in the current directory gets priority over anything in $PATH (both for cmd.exe and MSYS). That means, the former code was launching the local hg.exe instead of the system-wide one, if it was previously built. If that failed, it then fell back to the local hg code, but run through python.exe. I'm not sure what it is about ef7119cd4965, but that started throwing up a messagebox that python37.dll couldn't be loaded. (And indeed, python37 is not in $PATH by default.) Invoking the local hg via the current python avoids that.
Mon, 17 Dec 2018 10:46:37 +0100 delta: ignore base whose chains already don't match expectations
Boris Feld <boris.feld@octobus.net> [Mon, 17 Dec 2018 10:46:37 +0100] rev 40979
delta: ignore base whose chains already don't match expectations If we know the existing chain does not match our criteria, there is no point to build a delta to append. This is especially useful when dealing with a full text much smaller than its parent. In that case, the parent chain is probably already too large. example affected manifest write before: 1.421005s after: 0.815520s (-42%)
Mon, 17 Dec 2018 10:42:19 +0100 delta: exclude base candidate much smaller than the target
Boris Feld <boris.feld@octobus.net> [Mon, 17 Dec 2018 10:42:19 +0100] rev 40978
delta: exclude base candidate much smaller than the target If a revision's full text is that much bigger than a base candidate full text, we no longer consider that candidate. This solves a pathological case we encountered on a very specify repository. It contains a long series of changesets with a very small manifest (one file) co-existing with others changesets using a very large manifest. Without this filtering, we ended up considering a large number of tiny full snapshots as a potential base. It resulted in very large delta (the size of the full text) and mercurial spending 99% of its time compressing these deltas. The timing of a commit moved from about 400s to about 10s (still slow, but not ridiculously slow).
Mon, 17 Dec 2018 10:37:22 +0100 perfrevflogwrite: clear revlog cache between each write
Boris Feld <boris.feld@octobus.net> [Mon, 17 Dec 2018 10:37:22 +0100] rev 40977
perfrevflogwrite: clear revlog cache between each write We want to measure write time from a cold cache (similar to commit). So we need to clear the cache to prevent computation from rev N-1 to interfere with rev N.
Sun, 16 Dec 2018 17:42:45 -0500 py3: enable legacy stdio mode in exewrapper
Matt Harbison <matt_harbison@yahoo.com> [Sun, 16 Dec 2018 17:42:45 -0500] rev 40976
py3: enable legacy stdio mode in exewrapper This drops the test failure count from 166 to 117. The failures were typically in the form of `hg serve -d` spawning but crashing immediately, leaving clients with "bad http status" lines, connection refusals, and so forth. The underlying message on the server side was either "OSError: [WinError 6] The handle is invalid" or "OSError: [WinError 1] Incorrect function". Additionally, no output was rendered if the pager was activated. Thanks to Yuya for diagnosing the problem. The failure count drops to 107 when PYTHONLEGACYWINDOWSSTDIO=1 is defined in the environment. These failures seem to revolve around the dummyssh server process, and dumbhttp.py. So I'll probably add that to the test runner. One small regression here (only in py3) is that if hg.exe is already built, a messagebox appears when building it again saying that python37.dll can't be loaded. Python3 isn't in PATH by default, and setup.py tries running bare `hg` first. But MSYS prepends '.' to PATH, so it runs the local hg, but can't find the library. It falls back to the python used to invoke setup.py, so ultimately it works. I'm not sure if it's better to strip '.' from PATH or just skip right to `sys.executable hg` on Windows. Also, something seems to be wrong with run-tests._usecorrectpython(). I accidentially left off the 'PYTHON="py -3"' when building (thus making py2 stuff), and yet managed to invoke run-tests.py with "py -3". (And that only had 67 failures.)
Sun, 16 Dec 2018 17:36:51 -0500 run-tests: alias hg to hg.exe on Windows
Matt Harbison <matt_harbison@yahoo.com> [Sun, 16 Dec 2018 17:36:51 -0500] rev 40975
run-tests: alias hg to hg.exe on Windows To enable legacy stdio mode on Windows, hg.exe needs to be updated. But before that, we actually have to use it when running the tests. I *think* what was happening before was when MSYS invoked `hg`, it looked at the shbang line and ran python.exe found there. The test harness must be updating $PATH to include the python used to launch it, and therefore it ran py3. As a side note, this also fixed `py -3 run-tests.py` (without --local), which complained about the space in the shbang line before this. This should also help in WSL, because the explicit '.exe' is needed to invoke a Windows app instead of invoking the Linux app. I have no idea why this change capitalizes Lib in the tests, as it was previously lowercase for both py2 and py3.
Sun, 16 Dec 2018 15:47:08 -0500 py3: conditionalize the python version in test-install.t
Matt Harbison <matt_harbison@yahoo.com> [Sun, 16 Dec 2018 15:47:08 -0500] rev 40974
py3: conditionalize the python version in test-install.t
Sun, 16 Dec 2018 18:51:48 +0000 tests: followup on network related errors on Debian 9
Boris Feld <boris.feld@octobus.net> [Sun, 16 Dec 2018 18:51:48 +0000] rev 40973
tests: followup on network related errors on Debian 9 First, update test-clonebundles.t which was failing since the introduction of the `$EADDRNOTAVAIL$` common pattern. Also update two tests from 8695fbe17f7c with a more compact condition line. Differential Revision: https://phab.mercurial-scm.org/D5445
Sun, 16 Dec 2018 17:55:08 +0900 py3: unimplement RevlogError.__str__()
Yuya Nishihara <yuya@tcha.org> [Sun, 16 Dec 2018 17:55:08 +0900] rev 40972
py3: unimplement RevlogError.__str__() On Python 2, str(exc) would crash if __str__() returned a unicode containing non-ASCII characters.
Sun, 16 Dec 2018 17:53:17 +0900 py3: use forcebytestr() to stringify hook exception
Yuya Nishihara <yuya@tcha.org> [Sun, 16 Dec 2018 17:53:17 +0900] rev 40971
py3: use forcebytestr() to stringify hook exception This fixes test-narrow-exchange.t.
Sat, 15 Dec 2018 23:14:03 -0500 color: fix a documentation typo
Matt Harbison <matt_harbison@yahoo.com> [Sat, 15 Dec 2018 23:14:03 -0500] rev 40970
color: fix a documentation typo
Sat, 15 Dec 2018 22:31:54 -0500 py3: quote $PYTHON in test-patchbomb.t for Windows
Matt Harbison <matt_harbison@yahoo.com> [Sat, 15 Dec 2018 22:31:54 -0500] rev 40969
py3: quote $PYTHON in test-patchbomb.t for Windows I couldn't get the quoting right in the environment variable, so now it's a function.
Tue, 16 Oct 2018 19:58:27 +0200 rust-cpython: testing the bindings from Python
Georges Racinet <gracinet@anybox.fr> [Tue, 16 Oct 2018 19:58:27 +0200] rev 40968
rust-cpython: testing the bindings from Python This is easier and more convincing than doing the same tests from a Rust tests module. Differential Revision: https://phab.mercurial-scm.org/D5437
Thu, 06 Dec 2018 16:34:22 +0100 rust-cpython: build via HGWITHRUSTEXT=cpython
Georges Racinet <gracinet@anybox.fr> [Thu, 06 Dec 2018 16:34:22 +0100] rev 40967
rust-cpython: build via HGWITHRUSTEXT=cpython The existing behaviour, building the direct ffi bindings if HGIWTHRUSTEXT is just set is unchanged, but if HGWITHRUSTEXT is cpython, then the cpython bindings (aka mercurial/rustext.so) are built. Differential Revision: https://phab.mercurial-scm.org/D5436
Thu, 06 Dec 2018 16:23:20 +0100 rust: better treatment of cargo/rustc errors
Georges Racinet <gracinet@anybox.fr> [Thu, 06 Dec 2018 16:23:20 +0100] rev 40966
rust: better treatment of cargo/rustc errors Differential Revision: https://phab.mercurial-scm.org/D5435
Mon, 03 Dec 2018 06:52:17 +0100 rust-cpython: start cpython crate bindings
Georges Racinet <gracinet@anybox.fr> [Mon, 03 Dec 2018 06:52:17 +0100] rev 40965
rust-cpython: start cpython crate bindings This changeset introduces the hg-cpython crate, that compiles as a shared library holding a whole Python package (mercurial.rustext), with only the empty 'ancestor' submodule for now. Such bindings will be easier and safer to develop and maintain that those of `hg-direct-ffi`. They don't involve C code, only unsafe Rust that's mostly isolated within the cpython crate. The long-term goal would be to import the provided modules, such as rustext.ancestor with mercurial.policy.importmod, same as we already do with cext modules. Differential Revision: https://phab.mercurial-scm.org/D5434
Mon, 03 Dec 2018 06:54:19 +0100 rust-cpython: exclude hgcli from workspace
Georges Racinet <gracinet@anybox.fr> [Mon, 03 Dec 2018 06:54:19 +0100] rev 40964
rust-cpython: exclude hgcli from workspace hgcli uses a specific rust-cpython commit by indygreg, of which a PR has been derived which is not merged nor released yet. But we can't use several versions of the sys-python2.7 crate in a single workspace: it makes for a build error. Since hgcli does not at the time being need anything from hg-core, whereas the upcoming hg-cpython will. So for now we're moving hgcli aside, hoping we could base all of them on the same version of rust-cpython again in the future. Differential Revision: https://phab.mercurial-scm.org/D5433
Fri, 14 Dec 2018 17:25:41 +0100 sparse-revlog: protect C code against delta chain including nullrev
Boris Feld <boris.feld@octobus.net> [Fri, 14 Dec 2018 17:25:41 +0100] rev 40963
sparse-revlog: protect C code against delta chain including nullrev For unclear reasons, some repositories include nullrev (-1). Re-computing delta for such repo remove nullrev from all chain, so some older versions have been creating them. This currently raise an IndexError with the new C code doing chain slicing as it expect all item to be positive. Both python and C code for reading delta chain preserve nullrev, and the Python code for chain slicing handle the case fine. So we take the safe route and make the new C code works fine in that case.
Fri, 14 Dec 2018 17:24:44 +0100 sparse-revlog: handle nullrev in index_get_length
Boris Feld <boris.feld@octobus.net> [Fri, 14 Dec 2018 17:24:44 +0100] rev 40962
sparse-revlog: handle nullrev in index_get_length The more generic index_get method handle nullrev fine, we apply the same logic here.
Fri, 14 Dec 2018 17:23:41 +0100 sparse-revlog: handle nullrev in index_get_start
Boris Feld <boris.feld@octobus.net> [Fri, 14 Dec 2018 17:23:41 +0100] rev 40961
sparse-revlog: handle nullrev in index_get_start The more generic index_get method handle nullrev fine, we apply the same logic here.
Fri, 14 Dec 2018 17:22:42 +0100 revlog: introduce a constant for nullrev in `revlog.c`
Boris Feld <boris.feld@octobus.net> [Fri, 14 Dec 2018 17:22:42 +0100] rev 40960
revlog: introduce a constant for nullrev in `revlog.c` The value is important enough to be explicitly tracked.
(0) -30000 -10000 -3000 -1000 -300 -100 -50 -30 +30 +50 +100 +300 +1000 +3000 +10000 tip