Fri, 10 Apr 2020 22:07:11 +0900 rust-chg: reimplement attach_io operation as async function
Yuya Nishihara <yuya@tcha.org> [Fri, 10 Apr 2020 22:07:11 +0900] rev 44848
rust-chg: reimplement attach_io operation as async function In short, MessageLoop<Connection> was redesigned as Protocol<Connection>, and the protocol methods no longer consume self. API changes are briefly documented in the following page: https://docs.rs/tokio-hglib/0.3.0/tokio_hglib/struct.Protocol.html Differential Revision: https://phab.mercurial-scm.org/D8442
Fri, 10 Apr 2020 21:54:03 +0900 rust-chg: upgrade to futures-0.3 based libraries
Yuya Nishihara <yuya@tcha.org> [Fri, 10 Apr 2020 21:54:03 +0900] rev 44847
rust-chg: upgrade to futures-0.3 based libraries And do some trivial fixes: - BytesMut::put_u32_be() -> put_u32() - tokio_process -> tokio::process, CommandExt -> Command, spawn_async() -> spawn(), stdin() -> stdin - tokio_timer::sleep() -> tokio::time::delay_for() Differential Revision: https://phab.mercurial-scm.org/D8441
Fri, 10 Apr 2020 21:44:46 +0900 rust-chg: exclude futures-dependent modules from build and break things
Yuya Nishihara <yuya@tcha.org> [Fri, 10 Apr 2020 21:44:46 +0900] rev 44846
rust-chg: exclude futures-dependent modules from build and break things It's impractical to upgrade the codebase incrementally since futures 0.1 and 0.3 APIs are fundamentally different. So this patch temporarily excludes futures-dependent modules from the build. These modules will be upgraded and re-enabled one by one. Differential Revision: https://phab.mercurial-scm.org/D8440
Mon, 20 Apr 2020 14:37:10 -0700 commit: tell user what to do with .hg/last-message.txt
Martin von Zweigbergk <martinvonz@google.com> [Mon, 20 Apr 2020 14:37:10 -0700] rev 44845
commit: tell user what to do with .hg/last-message.txt I have always assumed that the message will be reused by the next `hg commit`, but it seems it's just silently dropped on the next commit. Let's try to be more helpful by telling the user that they have to manually tell hg to reuse it. The file will still be lost if the user runs some other operation in between (like a non-in-memory rebase). That will be fixed once we've switched all operations to be in-memory :) I didn't include `$(hg root)/` in the path in the message to the user because that would have made the message too long. Hopefully the user will figure that part out themselves. Differential Revision: https://phab.mercurial-scm.org/D8463
Fri, 17 Apr 2020 19:35:18 +0900 test-check-rust-format: specify --edition=2018
Yuya Nishihara <yuya@tcha.org> [Fri, 17 Apr 2020 19:35:18 +0900] rev 44844
test-check-rust-format: specify --edition=2018 rustfmt doesn't read Cargo.toml unless it's executed by cargo. https://github.com/rust-lang/rustfmt#rusts-editions
Tue, 14 Jul 2020 10:25:41 +0200 convert: use bytes for value in extra dict stable
Manuel Jacob <me@manueljacob.de> [Tue, 14 Jul 2020 10:25:41 +0200] rev 44843
convert: use bytes for value in extra dict The keys and values of the extra dict are expected to be bytes. Before this fix, there was a crash in mercurial.changelog.encodeextra().
Wed, 08 Jul 2020 08:57:21 +0200 archival: abort if compression method is unavailable stable
Manuel Jacob <me@manueljacob.de> [Wed, 08 Jul 2020 08:57:21 +0200] rev 44842
archival: abort if compression method is unavailable `tarfile.CompressionError` is documented to be the "exception for unavailable compression methods". Also, make tests conditional on whether the lzma module is available or not.
Wed, 08 Jul 2020 08:25:30 +0200 demandimport: ignore `lzma` module for demandimport stable
Manuel Jacob <me@manueljacob.de> [Wed, 08 Jul 2020 08:25:30 +0200] rev 44841
demandimport: ignore `lzma` module for demandimport This makes importing the module fail if the `_lzma` module is not present. This makes e.g. tarfile correctly recognize if LZMA support is not present. It changes the exception File "/usr/lib/python3.6/tarfile.py", line 1694, in xzopen fileobj = lzma.LZMAFile(fileobj or name, mode, preset=preset) AttributeError: module 'lzma' has no attribute 'LZMAFile' to the more correct exception File "/usr/lib/python3.6/tarfile.py", line 1692, in xzopen raise CompressionError("lzma module is not available") tarfile.CompressionError: lzma module is not available Also, it prevents that the error "abort: No module named '_lzma'!" is shown when a development warning is to be shown. The reason why that happened is that for showing the warning, we get information about the stack frames from the inspect module, which accesses the `__file__` attribute of all modules in `sys.modules` to build some cache, causing all modules (including `lzma`) to be imported.
Fri, 03 Jul 2020 23:25:19 +0200 py3: fix crash when server address is 0.0.0.0 (issue6362) stable
Manuel Jacob <me@manueljacob.de> [Fri, 03 Jul 2020 23:25:19 +0200] rev 44840
py3: fix crash when server address is 0.0.0.0 (issue6362) `socket.getfqdn()` assumes that the name is passed as `str` on Python 3 and always returns `str` in this case. Mercurial passed `bytes` (but still expected a `str` result), which worked by chance in many cases, except for e.g. b'0.0.0.0', which was returned unchanged, breaking later code. Instead of calling `socket.getfqdn()`, we can also use `self.server_name` from the base `HTTPServer` class, which already stores the FQDN of the locally-bound socket name (see `BaseHTTPServer.py` in the Python 2 stdlib and `http/server.py` in the Python 3 stdlib).
Wed, 01 Jul 2020 15:43:15 +0200 run-tests: find python binary on Python 3 (issue6361) stable
Axel Hecht <axel@pike.org> [Wed, 01 Jul 2020 15:43:15 +0200] rev 44839
run-tests: find python binary on Python 3 (issue6361) Return strings from _findprogram as all callers expect unicode strings. Previously the check in _usecorrectpython agains sysexecutable was always false on Python 3. Differential Revision: https://phab.mercurial-scm.org/D8674
(0) -30000 -10000 -3000 -1000 -300 -100 -10 +10 +100 +300 +1000 +3000 tip