py3: fix module imports in tests, as flagged by test-check-module-imports.t
I have no idea why these aren't flagged with python2. I excluded
test-highlight.t for now to make this easier to review- the changed code is
committed to a repo, which has cascading changes on the rest of the test.
There's a mix of bytes and str in the imports dict of contrib/import-checker.py
that crashed it half way through listing out these errors. I couldn't figure
out how to fix that properly, so I was lazy and applied this on py3, to find the
rest of the errors:
diff --git a/contrib/import-checker.py b/contrib/import-checker.py
--- a/contrib/import-checker.py
+++ b/contrib/import-checker.py
@@ -626,7 +626,12 @@ def find_cycles(imports):
top.foo -> top.qux -> top.foo
"""
cycles = set()
- for mod in sorted(imports.keys()):
+ def sort(v):
+ if isinstance(v, bytes):
+ return v.decode('ascii')
+ return v
+
+ for mod in sorted(imports.keys(), key=sort):
try:
checkmod(mod, imports)
except CircularImport as e:
lfs: don't add extension to hgrc after conversion (BC)
This is in the spirit of
bcf72d7b1524.
addremove: add "ui." prefix to message color keys
I don't like fully-colorized status/warning messages, and I want to disable
them at all. If we'd supported a syntax like 'color.ui.*=none', I could
easily turn addremove.added/removed off as well as ui.error. This patch is
just for that.
Since addremove colors aren't released yet, which were added at
ddc1da134772,
there are no compatibility concerns.
update: clarify update() call sites by specifying argument names
merge.update() takes a lot of parameters and I get confused all the
time which is which.
Differential Revision: https://phab.mercurial-scm.org/D5153
debugcommands: avoid stack trace from debugindexstats in pure mode
This has been broken since I added it in
d71e0ba34d9b (debugcommands:
add a debugindexstats command, 2018-08-08). This patch also fixes the
test.
Differential Revision: https://phab.mercurial-scm.org/D5152
tests: fix up pure case of test-sqlitestore.t
This is clearly what the line should read based on the "force to zlib"
section below, so I'm guessing it just got overlooked during development.
Differential Revision: https://phab.mercurial-scm.org/D5151
tests: don't emit false failures when sqlite3 is missing
I'm honestly surprised we have buildbot coverage for this, but we do!
Differential Revision: https://phab.mercurial-scm.org/D5150
py3: don't use traceback.print_exc() in commandserver.py
It doesn't support a bytes stream on Python 3. This makes a traceback being
sent by one frame, but that shouldn't matter.
py3: invalidate repository cache with system-string keys
# skip-blame just a few r'' prefixes