tests: fix http-bad-server expected errors for python 3.10 (
issue6643)
The format of the error message changed with this version of Python.
This also removes obsolete Python 3 checks.
run-tests: display the time it took to install Mercurial
It will help make people aware of this critical step and to assess the time it
takes in various options (like a CI run for example).
run-tests: deal with distutil deprecation
PEP 632 recommend the use of `packaging.version` to replace the deprecated
`distutil.version`. So lets do it.
fsmonitor: migrate Python ABCs from collections to collections.abc
The Collections Abstract Base Classes in the collections module are
deprecated since Python 3.3 in favor of collections.abc, and removed
in Python 3.10.
templates: add filter to reverse list
The filter supports only lists because for lists, it’s straightforward to
implement. Reversing text doesn’t seem very useful and is hard to implement.
Reversing the bytes would break multi-bytes encodings. Reversing the code
points would break characters consisting of multiple code points. Reversing
graphemes is non-trivial without using a library not included in the standard
library.
requires: re-use vfs.tryread for simplicity
Avoids calling `set` twice or having to re-raise an exception and implements the routine with a single return expression.
tests: fix the flaky test test-logtoprocess.t
The main change is that we're waiting for the [touched] file to appear for 5 seconds instead of 0.1 seconds. Also, instead of implementing wait-on-file from scratch, we use the existing one from testlib/ that works well.