Thu, 02 Jul 2020 04:37:18 +0200 procutil: define LineBufferedWrapper on all Python versions
Manuel Jacob <me@manueljacob.de> [Thu, 02 Jul 2020 04:37:18 +0200] rev 45039
procutil: define LineBufferedWrapper on all Python versions There’s nothing Python 3-only about LineBufferedWrapper. In the future, we may want to use it on Windows, to work around missing line-buffering support.
Sat, 04 Jul 2020 10:47:04 +0200 tests: add tests for buffering behavior of mercurial.utils.procutil.stdout
Manuel Jacob <me@manueljacob.de> [Sat, 04 Jul 2020 10:47:04 +0200] rev 45038
tests: add tests for buffering behavior of mercurial.utils.procutil.stdout
Thu, 02 Jul 2020 02:51:09 +0200 cleanup: use slightly more meaningful name for temporary variable
Manuel Jacob <me@manueljacob.de> [Thu, 02 Jul 2020 02:51:09 +0200] rev 45037
cleanup: use slightly more meaningful name for temporary variable Not that it makes a big difference, but using `p` instead of `x` is clearer to me.
Thu, 02 Jul 2020 02:46:15 +0200 cleanup: use any() instead of checking truthiness of temporary list
Manuel Jacob <me@manueljacob.de> [Thu, 02 Jul 2020 02:46:15 +0200] rev 45036
cleanup: use any() instead of checking truthiness of temporary list It was not immediately obvious to me, when first seeing this, why a list was created. It needed a second look to understand that the purpose was to check whether the condition is true for any of the parents. Using any() for that is clearer.
Fri, 03 Jul 2020 13:45:59 +0530 chg: suppress OSError in _restoreio() and add some logging (issue6330)
Pulkit Goyal <7895pulkit@gmail.com> [Fri, 03 Jul 2020 13:45:59 +0530] rev 45035
chg: suppress OSError in _restoreio() and add some logging (issue6330) According to issue6330, running chg on heavy loaded systems can lead to following error: ``` Traceback (most recent call last): File "path-to-hg/mercurial/commandserver.py", line 650, in _acceptnewconnection self._runworker(conn) File "path-to-hg/mercurial/commandserver.py", line 701, in _runworker prereposetups=[self._reposetup], File "path-to-hg/mercurial/commandserver.py", line 470, in _serverequest sv.cleanup() File "path-to-hg/mercurial/chgserver.py", line 381, in cleanup self._restoreio() File "path-to-hg/mercurial/chgserver.py", line 444, in _restoreio os.dup2(fd, fp.fileno()) OSError: [Errno 16] Device or resource busy ``` [man dup2] indicates that, on Linux, EBUSY comes from a race condition between open() and dup2(). However it's not clear why open() race occurred for newfd=stdin/out/err. We suppress the OSError in _restoreio() since the forked worker process will finish anyway and add some logging. Thanks to Mitchell Plamann for a detailed bug description and Yuya Nishihara for suggesting the fix.
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 45034
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).
Thu, 02 Jul 2020 19:54:44 +0200 ui: fix Python 2.7 support for ui.timestamp-output
Joerg Sonnenberger <joerg@bec.de> [Thu, 02 Jul 2020 19:54:44 +0200] rev 45033
ui: fix Python 2.7 support for ui.timestamp-output Differential Revision: https://phab.mercurial-scm.org/D8675
Wed, 01 Jul 2020 14:28:12 -0400 merge with stable
Augie Fackler <augie@google.com> [Wed, 01 Jul 2020 14:28:12 -0400] rev 45032
merge with stable
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 45031
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
Mon, 29 Jun 2020 16:36:53 +0200 tests: ignore possible diagnostics from gpg 2.2 stable
Joerg Sonnenberger <joerg@bec.de> [Mon, 29 Jun 2020 16:36:53 +0200] rev 45030
tests: ignore possible diagnostics from gpg 2.2 Differential Revision: https://phab.mercurial-scm.org/D8672
(0) -30000 -10000 -3000 -1000 -300 -100 -10 +10 +100 +300 +1000 +3000 tip