[PATCH 1 of 5] csinfo: add missing `style` argument to `updateItems()`

15 views
Skip to first unread message

Matt Harbison

unread,
Nov 26, 2024, 1:50:52 AM11/26/24
to thg...@googlegroups.com
# HG changeset patch
# User Matt Harbison <matt_h...@yahoo.com>
# Date 1732144073 18000
# Wed Nov 20 18:07:53 2024 -0500
# Branch stable
# Node ID 6b1503251727517e3c1280cc98ca389e8bd20488
# Parent 2dcff69f65638dce6da21041d280a120e76fb804
# EXP-Topic csinfo-pytype-fix
csinfo: add missing `style` argument to `updateItems()`

Pytype was complaining about the extra argument being passed at line 413, since
2dcff69f6563. I was initially going to drop it as it's not used in
`SummaryBase`, however the `SummaryPanel` and `SummaryLabel` do reference the
argument, and cleaning up mismatched overrides was how we got here in the first
place with a015c03d91c6 (which 2dcff69f6563 applied to this module).

The original `update()` method in 2dcff69f6563 lacked this `style` argument (so
it also had a mismatched override signature, which pytype didn't complain about
for some reason), so also drop that here from the compatibility shim- the whole
point of that is to have the same signature and delegate to the new function.
This changed signature may have cause callers to explode with misaligned
arguments.

diff --git a/tortoisehg/hgqt/csinfo.py b/tortoisehg/hgqt/csinfo.py
--- a/tortoisehg/hgqt/csinfo.py
+++ b/tortoisehg/hgqt/csinfo.py
@@ -401,7 +401,7 @@
# method that SummaryPanel and SummaryLabel get through multiple inheritance
# from QWidget and QLabel respectively. That update() method seems related
# to painting the component, or an area of it.
- def update(self, target=None, style=None, custom=None, repo=None): # pytype: disable=signature-mismatch
+ def update(self, target=None, custom=None, repo=None): # pytype: disable=signature-mismatch
import warnings

warnings.warn(
@@ -410,9 +410,9 @@
2,
)
sys.stderr.flush()
- self.updateItems(target, style, custom, repo)
+ self.updateItems(target, None, custom, repo)

- def updateItems(self, target=None, custom=None, repo=None):
+ def updateItems(self, target=None, style=None, custom=None, repo=None):
self.ctx = None
if target is not None:
self.target = target
@@ -452,7 +452,7 @@
self.expand_btn = qtlib.PMButton()

def updateItems(self, target=None, style=None, custom=None, repo=None):
- SummaryBase.updateItems(self, target, custom, repo)
+ SummaryBase.updateItems(self, target, style, custom, repo)

layout = self.layout()
assert isinstance(layout, QHBoxLayout)
@@ -533,7 +533,7 @@
self.csstyle = style

def updateItems(self, target=None, style=None, custom=None, repo=None):
- SummaryBase.updateItems(self, target, custom, repo)
+ SummaryBase.updateItems(self, target, style, custom, repo)

if style is not None:
self.csstyle = style

Matt Harbison

unread,
Nov 26, 2024, 1:50:55 AM11/26/24
to thg...@googlegroups.com
# HG changeset patch
# User Matt Harbison <matt_h...@yahoo.com>
# Date 1732580826 18000
# Mon Nov 25 19:27:06 2024 -0500
# Branch stable
# Node ID 270af3b573d67101a2f485c0a408c42aae8df4c6
# Parent 6b1503251727517e3c1280cc98ca389e8bd20488
# EXP-Topic csinfo-pytype-fix
packaging: update hg-git to 1.1.4 on Windows

This aims to fix a Windows bug that was addressed in 1.1.4. No idea if any
changes in here address compatibility with hg itself- it's been awhile since we
updated.

diff --git a/contrib/packaging/requirements-windows-pyqt5-installer.txt b/contrib/packaging/requirements-windows-pyqt5-installer.txt
--- a/contrib/packaging/requirements-windows-pyqt5-installer.txt
+++ b/contrib/packaging/requirements-windows-pyqt5-installer.txt
@@ -129,9 +129,9 @@
--hash=sha256:45016e92264780e58972dca1b3d939ac864b78437422beecebb3095f8efd00e8 \
--hash=sha256:928244b28db720d1e0ee7587acf660ea49d7e4c632569cad4f1cd7e68a5f0993
# via -r contrib/packaging/requirements-windows-pyqt5-installer.txt.in
-hg-git==1.1.0 \
- --hash=sha256:552fba094cdf34be4e1bf508fe89c3661f6e129940ce9b2063d5fc9db19cdcc3 \
- --hash=sha256:6ed11a9862ea082e4f4628311db7b8f7f6e724d5469ba0b37fce7625a01d077f
+hg-git==1.1.4 \
+ --hash=sha256:5c5f6f02dbd42b9c913f83b166ff37fc00368dd7b9b7bcdade3aa0cae5dce5e5 \
+ --hash=sha256:6e4c3b0998a29f075038de5a3853833f07fe00573866d395535a9cf053b85b40
# via -r contrib/packaging/requirements-windows-pyqt5-installer.txt.in
importlib-metadata==4.12.0 \
--hash=sha256:637245b8bab2b6502fcbc752cc4b7a6f6243bb02b31c5c26156ad103d3d45670 \

Matt Harbison

unread,
Nov 26, 2024, 1:50:55 AM11/26/24
to thg...@googlegroups.com
# HG changeset patch
# User Matt Harbison <matt_h...@yahoo.com>
# Date 1732581572 18000
# Mon Nov 25 19:39:32 2024 -0500
# Branch stable
# Node ID 37bf9d88efc87e0d831c976898a0e7514110b1c8
# Parent 270af3b573d67101a2f485c0a408c42aae8df4c6
# EXP-Topic csinfo-pytype-fix
packaging: bump Mercurial to 6.9 in all requirements files

We finally have binary wheels on all(?) platforms, and 6.2 support got dropped
from the tests in this past cycle.

diff --git a/contrib/packaging/requirements-windows-pyqt5-installer.txt b/contrib/packaging/requirements-windows-pyqt5-installer.txt
--- a/contrib/packaging/requirements-windows-pyqt5-installer.txt
+++ b/contrib/packaging/requirements-windows-pyqt5-installer.txt
@@ -146,8 +146,53 @@
--hash=sha256:782e1cd1132e91bf459fcd243bcf25b326015c1ac0b198e4408f91fa6791062b \
--hash=sha256:e67fc91a7955785fd2efcbccdd72d7dacf136dbc381d27de305b2b660b3de886
# via mercurial-keyring
-mercurial==6.2 \
- --hash=sha256:d382b5e3fab8931126013201731416574b35ae85787404bb2a0819f41bb88972
+mercurial==6.9 \
+ --hash=sha256:0113d58ca9a2b7d41417f24788df21e9793bda5419ab962fd3410266fd32dad9 \
+ --hash=sha256:05f5c42b09ffcabf1bd2a3aae43a30e55ad4fd1f3b4a6853ad2092cb4724e9b5 \
+ --hash=sha256:0861b4c1620c0ed9a7b74795dc2be50535c2d9a883a1408eabc4ec8dee183c6e \
+ --hash=sha256:13ed70c06a9565f5e4074fe03d79df1cffacc7fd7ef93a4ffc77fa71887fdd40 \
+ --hash=sha256:179832de288a3dd95403a02df6a822c40c56fbea93c33c606997ad34f7ccb458 \
+ --hash=sha256:1ecbe95dc6f780d3436ee353daa649c855391dad6a27e72279942d3643267998 \
+ --hash=sha256:22679bbbf374531647aa07c0a2fe86a7e241f0558efbaf7a644537e9788e3abb \
+ --hash=sha256:2654bab75c0a3194b2e62bbc2ce688bbb694a6a54f25e2e5860f8f7f106a72f9 \
+ --hash=sha256:329fcadb626ae05ebf999685b4dc071bf50cf8be600878619bc2d79789d6a096 \
+ --hash=sha256:3a25f67144152032a0d7dbf63ee134c2368e92018dd6d61be35a795f8e81b23e \
+ --hash=sha256:3f3df1cc76c73cd4cbed0e967177d11031b511ecb67c97e3d549571fb2484441 \
+ --hash=sha256:3f4e24ee71b79b4a12428694acc9800c12963fb48d8e9be130dc07360222016b \
+ --hash=sha256:42e6309f679ee9fc331cdf5d16c1dbabb4231aa2dc9d83a8d3c66ac12d82279e \
+ --hash=sha256:440131421808c9a2fc4a4325176838913f41961f63e8fea66e5b53ac11f3d1d8 \
+ --hash=sha256:444b4f1018974343b09c0241982d1dec9ecce83787a448c8ed1c9663a15f70e0 \
+ --hash=sha256:5cd2d3cd0b0a16ac7d9795c0431e09b69ed49a65eaf56c6ee6755f0c902790d0 \
+ --hash=sha256:5cfdbeae6bda05cb8adb7d401f117a708cdab481b7eebae8307aa09a9e28d487 \
+ --hash=sha256:629604293df2be8171ec856bf4f8b4faa8e4305af13607dce0f89f74132836d6 \
+ --hash=sha256:6743ccef3a949b5927bdee78c69ffa567f211ac26d85fabe84043d20cbd3c2f9 \
+ --hash=sha256:69dc2992e3c06ebabf3e237522d7baf370ea144674c9df7be6157e926886d0e1 \
+ --hash=sha256:72f2bed7c2ceadb663efefa1562b2009aab1ba3966ce11a7bd2881e8c44f3518 \
+ --hash=sha256:77264cf06d7ecc9b2a384be65578fccc0b5a585ff2500a7c158077bd09e04725 \
+ --hash=sha256:856e118815017feaccab1137fa12e09178e88174404b1df11a4dc48a7a3ad0ee \
+ --hash=sha256:8dd08a77e402ef97b40b975ae5b23a9aa8016c351b625cfbce87a1b314fc5b19 \
+ --hash=sha256:97462eda40d3a3aa3360261df45e64caf16e8bfb24260a03b6a5e2d8a9c0e665 \
+ --hash=sha256:a098e4cee612e18f7457482f58096c6ad7496700b27774e1f6f82967c8fb9743 \
+ --hash=sha256:a3786faac06a2deca871f2ca93ea10a5baf2ef6431f59151b031ed4354d2a53c \
+ --hash=sha256:a6d4805a87a621443ff374c72cca082b2de698a7acf795001a44d4977dd4c23e \
+ --hash=sha256:a929edc9995e15b0eb17a80f21e4683c51cc4e457fbe9398b82afc3c606cf208 \
+ --hash=sha256:ad01b5d9c62cd441fdc2444a0b227d6f40790325d3fb65930928846f0c509653 \
+ --hash=sha256:ba9c0328845ce0b43b62674d304aeafee6d23f483b48d503db3682aefba3b751 \
+ --hash=sha256:c3e4d0da931de8caea4e71344be4900251c01910628ad456f4c4e010df7206db \
+ --hash=sha256:c4bc16d718f3d12775c5c86c97e64a5409bf4c68a789794040aa43a54039bcfd \
+ --hash=sha256:ceb3937fb4e59756fc9a1930abc423d33a6009c991a30ffb7aa708a6130fc4eb \
+ --hash=sha256:d26ab92a68ff8891717f9f3fe8d3514c4b9d421127a47d93c47c437a9297fa91 \
+ --hash=sha256:dd0ec5344b581386323ad05af0a5bf431857485851fc5054b5f0d846fcb9ce80 \
+ --hash=sha256:df0d5b558396a09b7d7eada50361989e1625c79593361f1e49d835f529446650 \
+ --hash=sha256:e11fc5556c68f1269edb5d04e4c4dd4af20a8cb389e6d2c103d89552dea738ae \
+ --hash=sha256:e2991b93a5c7e25363f73403866ff5ca641a2af9b39fc7397dd6776654be5af1 \
+ --hash=sha256:e35c4efb5cbfe9ef2bc98516b2b798b4c69847d644999b643c45856c47a16f70 \
+ --hash=sha256:e7685ff82cf8589fe240a83347b7ee73765525a5dd8c311bf69f8b187f9ecf40 \
+ --hash=sha256:ec2a00f73da23123c52ec68206b6ebed1a214c569cda37aaab7b343ef539c7c3 \
+ --hash=sha256:f08fa97d6416b93a6b7a900d1bee44701ed30dc84c4a0406c468eb8b4ec4d16a \
+ --hash=sha256:f4d26f3932416c29a052072ba216ba9c31a3d61a8ac80d20996d4e83a0749320 \
+ --hash=sha256:f545c86537f6b542ab7ecae5a4869b716b2d50a58739ab616b1884b0e37cd5c7 \
+ --hash=sha256:f6e0c74b14bb57304992b39a57c40b47189c5bb40bc797d3a6e135388d560133
# via -r contrib/packaging/venv_py3/requirements.txt.in
mercurial-extension-utils==1.5.2 \
--hash=sha256:760188c5eda51e040a20e313cac2abed0eaeed320dfdd3fa4e8ba477fed5f644
diff --git a/contrib/packaging/venv_py3/requirements-rhel.txt b/contrib/packaging/venv_py3/requirements-rhel.txt
--- a/contrib/packaging/venv_py3/requirements-rhel.txt
+++ b/contrib/packaging/venv_py3/requirements-rhel.txt
@@ -1,6 +1,6 @@
#
-# This file is autogenerated by pip-compile with python 3.7
-# To update, run:
+# This file is autogenerated by pip-compile with Python 3.8
+# by the following command:
#
# pip-compile --generate-hashes --output-file=contrib/packaging/venv_py3/requirements-rhel.txt contrib/packaging/venv_py3/requirements-centos7.txt.in contrib/packaging/venv_py3/requirements.txt.in
#
@@ -65,8 +65,53 @@
--hash=sha256:932e5239d526e7acb504017bb707be67019ac428a6932368e6851691093aa842 \
--hash=sha256:db6ef1d8a02395448e0e7b17ac0aa28b8d338b632bbd1ffca08c02ddae32cf97
# via -r contrib/packaging/venv_py3/requirements.txt.in
-mercurial==6.2 \
- --hash=sha256:d382b5e3fab8931126013201731416574b35ae85787404bb2a0819f41bb88972
+mercurial==6.9 \
+ --hash=sha256:0113d58ca9a2b7d41417f24788df21e9793bda5419ab962fd3410266fd32dad9 \
+ --hash=sha256:05f5c42b09ffcabf1bd2a3aae43a30e55ad4fd1f3b4a6853ad2092cb4724e9b5 \
+ --hash=sha256:0861b4c1620c0ed9a7b74795dc2be50535c2d9a883a1408eabc4ec8dee183c6e \
+ --hash=sha256:13ed70c06a9565f5e4074fe03d79df1cffacc7fd7ef93a4ffc77fa71887fdd40 \
+ --hash=sha256:179832de288a3dd95403a02df6a822c40c56fbea93c33c606997ad34f7ccb458 \
+ --hash=sha256:1ecbe95dc6f780d3436ee353daa649c855391dad6a27e72279942d3643267998 \
+ --hash=sha256:22679bbbf374531647aa07c0a2fe86a7e241f0558efbaf7a644537e9788e3abb \
+ --hash=sha256:2654bab75c0a3194b2e62bbc2ce688bbb694a6a54f25e2e5860f8f7f106a72f9 \
+ --hash=sha256:329fcadb626ae05ebf999685b4dc071bf50cf8be600878619bc2d79789d6a096 \
+ --hash=sha256:3a25f67144152032a0d7dbf63ee134c2368e92018dd6d61be35a795f8e81b23e \
+ --hash=sha256:3f3df1cc76c73cd4cbed0e967177d11031b511ecb67c97e3d549571fb2484441 \
+ --hash=sha256:3f4e24ee71b79b4a12428694acc9800c12963fb48d8e9be130dc07360222016b \
+ --hash=sha256:42e6309f679ee9fc331cdf5d16c1dbabb4231aa2dc9d83a8d3c66ac12d82279e \
+ --hash=sha256:440131421808c9a2fc4a4325176838913f41961f63e8fea66e5b53ac11f3d1d8 \
+ --hash=sha256:444b4f1018974343b09c0241982d1dec9ecce83787a448c8ed1c9663a15f70e0 \
+ --hash=sha256:5cd2d3cd0b0a16ac7d9795c0431e09b69ed49a65eaf56c6ee6755f0c902790d0 \
+ --hash=sha256:5cfdbeae6bda05cb8adb7d401f117a708cdab481b7eebae8307aa09a9e28d487 \
+ --hash=sha256:629604293df2be8171ec856bf4f8b4faa8e4305af13607dce0f89f74132836d6 \
+ --hash=sha256:6743ccef3a949b5927bdee78c69ffa567f211ac26d85fabe84043d20cbd3c2f9 \
+ --hash=sha256:69dc2992e3c06ebabf3e237522d7baf370ea144674c9df7be6157e926886d0e1 \
+ --hash=sha256:72f2bed7c2ceadb663efefa1562b2009aab1ba3966ce11a7bd2881e8c44f3518 \
+ --hash=sha256:77264cf06d7ecc9b2a384be65578fccc0b5a585ff2500a7c158077bd09e04725 \
+ --hash=sha256:856e118815017feaccab1137fa12e09178e88174404b1df11a4dc48a7a3ad0ee \
+ --hash=sha256:8dd08a77e402ef97b40b975ae5b23a9aa8016c351b625cfbce87a1b314fc5b19 \
+ --hash=sha256:97462eda40d3a3aa3360261df45e64caf16e8bfb24260a03b6a5e2d8a9c0e665 \
+ --hash=sha256:a098e4cee612e18f7457482f58096c6ad7496700b27774e1f6f82967c8fb9743 \
+ --hash=sha256:a3786faac06a2deca871f2ca93ea10a5baf2ef6431f59151b031ed4354d2a53c \
+ --hash=sha256:a6d4805a87a621443ff374c72cca082b2de698a7acf795001a44d4977dd4c23e \
+ --hash=sha256:a929edc9995e15b0eb17a80f21e4683c51cc4e457fbe9398b82afc3c606cf208 \
+ --hash=sha256:ad01b5d9c62cd441fdc2444a0b227d6f40790325d3fb65930928846f0c509653 \
+ --hash=sha256:ba9c0328845ce0b43b62674d304aeafee6d23f483b48d503db3682aefba3b751 \
+ --hash=sha256:c3e4d0da931de8caea4e71344be4900251c01910628ad456f4c4e010df7206db \
+ --hash=sha256:c4bc16d718f3d12775c5c86c97e64a5409bf4c68a789794040aa43a54039bcfd \
+ --hash=sha256:ceb3937fb4e59756fc9a1930abc423d33a6009c991a30ffb7aa708a6130fc4eb \
+ --hash=sha256:d26ab92a68ff8891717f9f3fe8d3514c4b9d421127a47d93c47c437a9297fa91 \
+ --hash=sha256:dd0ec5344b581386323ad05af0a5bf431857485851fc5054b5f0d846fcb9ce80 \
+ --hash=sha256:df0d5b558396a09b7d7eada50361989e1625c79593361f1e49d835f529446650 \
+ --hash=sha256:e11fc5556c68f1269edb5d04e4c4dd4af20a8cb389e6d2c103d89552dea738ae \
+ --hash=sha256:e2991b93a5c7e25363f73403866ff5ca641a2af9b39fc7397dd6776654be5af1 \
+ --hash=sha256:e35c4efb5cbfe9ef2bc98516b2b798b4c69847d644999b643c45856c47a16f70 \
+ --hash=sha256:e7685ff82cf8589fe240a83347b7ee73765525a5dd8c311bf69f8b187f9ecf40 \
+ --hash=sha256:ec2a00f73da23123c52ec68206b6ebed1a214c569cda37aaab7b343ef539c7c3 \
+ --hash=sha256:f08fa97d6416b93a6b7a900d1bee44701ed30dc84c4a0406c468eb8b4ec4d16a \
+ --hash=sha256:f4d26f3932416c29a052072ba216ba9c31a3d61a8ac80d20996d4e83a0749320 \
+ --hash=sha256:f545c86537f6b542ab7ecae5a4869b716b2d50a58739ab616b1884b0e37cd5c7 \
+ --hash=sha256:f6e0c74b14bb57304992b39a57c40b47189c5bb40bc797d3a6e135388d560133
# via -r contrib/packaging/venv_py3/requirements.txt.in
pycparser==2.21 \
--hash=sha256:8ee45429555515e1f6b185e78100aea234072576aa43ab53aefcae078162fca9 \
diff --git a/contrib/packaging/venv_py3/requirements.txt b/contrib/packaging/venv_py3/requirements.txt
--- a/contrib/packaging/venv_py3/requirements.txt
+++ b/contrib/packaging/venv_py3/requirements.txt
@@ -1,6 +1,6 @@
#
-# This file is autogenerated by pip-compile with python 3.7
-# To update, run:
+# This file is autogenerated by pip-compile with Python 3.8
+# by the following command:
#
# pip-compile --generate-hashes --output-file=contrib/packaging/venv_py3/requirements.txt contrib/packaging/venv_py3/requirements.txt.in
#
@@ -65,8 +65,53 @@
--hash=sha256:932e5239d526e7acb504017bb707be67019ac428a6932368e6851691093aa842 \
--hash=sha256:db6ef1d8a02395448e0e7b17ac0aa28b8d338b632bbd1ffca08c02ddae32cf97
# via -r contrib/packaging/venv_py3/requirements.txt.in
-mercurial==6.2 \
- --hash=sha256:d382b5e3fab8931126013201731416574b35ae85787404bb2a0819f41bb88972
+mercurial==6.9 \
+ --hash=sha256:0113d58ca9a2b7d41417f24788df21e9793bda5419ab962fd3410266fd32dad9 \
+ --hash=sha256:05f5c42b09ffcabf1bd2a3aae43a30e55ad4fd1f3b4a6853ad2092cb4724e9b5 \
+ --hash=sha256:0861b4c1620c0ed9a7b74795dc2be50535c2d9a883a1408eabc4ec8dee183c6e \
+ --hash=sha256:13ed70c06a9565f5e4074fe03d79df1cffacc7fd7ef93a4ffc77fa71887fdd40 \
+ --hash=sha256:179832de288a3dd95403a02df6a822c40c56fbea93c33c606997ad34f7ccb458 \
+ --hash=sha256:1ecbe95dc6f780d3436ee353daa649c855391dad6a27e72279942d3643267998 \
+ --hash=sha256:22679bbbf374531647aa07c0a2fe86a7e241f0558efbaf7a644537e9788e3abb \
+ --hash=sha256:2654bab75c0a3194b2e62bbc2ce688bbb694a6a54f25e2e5860f8f7f106a72f9 \
+ --hash=sha256:329fcadb626ae05ebf999685b4dc071bf50cf8be600878619bc2d79789d6a096 \
+ --hash=sha256:3a25f67144152032a0d7dbf63ee134c2368e92018dd6d61be35a795f8e81b23e \
+ --hash=sha256:3f3df1cc76c73cd4cbed0e967177d11031b511ecb67c97e3d549571fb2484441 \
+ --hash=sha256:3f4e24ee71b79b4a12428694acc9800c12963fb48d8e9be130dc07360222016b \
+ --hash=sha256:42e6309f679ee9fc331cdf5d16c1dbabb4231aa2dc9d83a8d3c66ac12d82279e \
+ --hash=sha256:440131421808c9a2fc4a4325176838913f41961f63e8fea66e5b53ac11f3d1d8 \
+ --hash=sha256:444b4f1018974343b09c0241982d1dec9ecce83787a448c8ed1c9663a15f70e0 \
+ --hash=sha256:5cd2d3cd0b0a16ac7d9795c0431e09b69ed49a65eaf56c6ee6755f0c902790d0 \
+ --hash=sha256:5cfdbeae6bda05cb8adb7d401f117a708cdab481b7eebae8307aa09a9e28d487 \
+ --hash=sha256:629604293df2be8171ec856bf4f8b4faa8e4305af13607dce0f89f74132836d6 \
+ --hash=sha256:6743ccef3a949b5927bdee78c69ffa567f211ac26d85fabe84043d20cbd3c2f9 \
+ --hash=sha256:69dc2992e3c06ebabf3e237522d7baf370ea144674c9df7be6157e926886d0e1 \
+ --hash=sha256:72f2bed7c2ceadb663efefa1562b2009aab1ba3966ce11a7bd2881e8c44f3518 \
+ --hash=sha256:77264cf06d7ecc9b2a384be65578fccc0b5a585ff2500a7c158077bd09e04725 \
+ --hash=sha256:856e118815017feaccab1137fa12e09178e88174404b1df11a4dc48a7a3ad0ee \
+ --hash=sha256:8dd08a77e402ef97b40b975ae5b23a9aa8016c351b625cfbce87a1b314fc5b19 \
+ --hash=sha256:97462eda40d3a3aa3360261df45e64caf16e8bfb24260a03b6a5e2d8a9c0e665 \
+ --hash=sha256:a098e4cee612e18f7457482f58096c6ad7496700b27774e1f6f82967c8fb9743 \
+ --hash=sha256:a3786faac06a2deca871f2ca93ea10a5baf2ef6431f59151b031ed4354d2a53c \
+ --hash=sha256:a6d4805a87a621443ff374c72cca082b2de698a7acf795001a44d4977dd4c23e \
+ --hash=sha256:a929edc9995e15b0eb17a80f21e4683c51cc4e457fbe9398b82afc3c606cf208 \
+ --hash=sha256:ad01b5d9c62cd441fdc2444a0b227d6f40790325d3fb65930928846f0c509653 \
+ --hash=sha256:ba9c0328845ce0b43b62674d304aeafee6d23f483b48d503db3682aefba3b751 \
+ --hash=sha256:c3e4d0da931de8caea4e71344be4900251c01910628ad456f4c4e010df7206db \
+ --hash=sha256:c4bc16d718f3d12775c5c86c97e64a5409bf4c68a789794040aa43a54039bcfd \
+ --hash=sha256:ceb3937fb4e59756fc9a1930abc423d33a6009c991a30ffb7aa708a6130fc4eb \
+ --hash=sha256:d26ab92a68ff8891717f9f3fe8d3514c4b9d421127a47d93c47c437a9297fa91 \
+ --hash=sha256:dd0ec5344b581386323ad05af0a5bf431857485851fc5054b5f0d846fcb9ce80 \
+ --hash=sha256:df0d5b558396a09b7d7eada50361989e1625c79593361f1e49d835f529446650 \
+ --hash=sha256:e11fc5556c68f1269edb5d04e4c4dd4af20a8cb389e6d2c103d89552dea738ae \
+ --hash=sha256:e2991b93a5c7e25363f73403866ff5ca641a2af9b39fc7397dd6776654be5af1 \
+ --hash=sha256:e35c4efb5cbfe9ef2bc98516b2b798b4c69847d644999b643c45856c47a16f70 \
+ --hash=sha256:e7685ff82cf8589fe240a83347b7ee73765525a5dd8c311bf69f8b187f9ecf40 \
+ --hash=sha256:ec2a00f73da23123c52ec68206b6ebed1a214c569cda37aaab7b343ef539c7c3 \
+ --hash=sha256:f08fa97d6416b93a6b7a900d1bee44701ed30dc84c4a0406c468eb8b4ec4d16a \
+ --hash=sha256:f4d26f3932416c29a052072ba216ba9c31a3d61a8ac80d20996d4e83a0749320 \
+ --hash=sha256:f545c86537f6b542ab7ecae5a4869b716b2d50a58739ab616b1884b0e37cd5c7 \
+ --hash=sha256:f6e0c74b14bb57304992b39a57c40b47189c5bb40bc797d3a6e135388d560133
# via -r contrib/packaging/venv_py3/requirements.txt.in
pycparser==2.21 \
--hash=sha256:8ee45429555515e1f6b185e78100aea234072576aa43ab53aefcae078162fca9 \
diff --git a/contrib/packaging/venv_py3/requirements_win32.txt b/contrib/packaging/venv_py3/requirements_win32.txt
--- a/contrib/packaging/venv_py3/requirements_win32.txt
+++ b/contrib/packaging/venv_py3/requirements_win32.txt
@@ -68,8 +68,53 @@
--hash=sha256:932e5239d526e7acb504017bb707be67019ac428a6932368e6851691093aa842 \
--hash=sha256:db6ef1d8a02395448e0e7b17ac0aa28b8d338b632bbd1ffca08c02ddae32cf97
# via -r contrib/packaging/venv_py3/requirements.txt.in
-mercurial==6.2 \
- --hash=sha256:d382b5e3fab8931126013201731416574b35ae85787404bb2a0819f41bb88972
+mercurial==6.9 \
+ --hash=sha256:0113d58ca9a2b7d41417f24788df21e9793bda5419ab962fd3410266fd32dad9 \
+ --hash=sha256:05f5c42b09ffcabf1bd2a3aae43a30e55ad4fd1f3b4a6853ad2092cb4724e9b5 \
+ --hash=sha256:0861b4c1620c0ed9a7b74795dc2be50535c2d9a883a1408eabc4ec8dee183c6e \
+ --hash=sha256:13ed70c06a9565f5e4074fe03d79df1cffacc7fd7ef93a4ffc77fa71887fdd40 \
+ --hash=sha256:179832de288a3dd95403a02df6a822c40c56fbea93c33c606997ad34f7ccb458 \
+ --hash=sha256:1ecbe95dc6f780d3436ee353daa649c855391dad6a27e72279942d3643267998 \
+ --hash=sha256:22679bbbf374531647aa07c0a2fe86a7e241f0558efbaf7a644537e9788e3abb \
+ --hash=sha256:2654bab75c0a3194b2e62bbc2ce688bbb694a6a54f25e2e5860f8f7f106a72f9 \
+ --hash=sha256:329fcadb626ae05ebf999685b4dc071bf50cf8be600878619bc2d79789d6a096 \
+ --hash=sha256:3a25f67144152032a0d7dbf63ee134c2368e92018dd6d61be35a795f8e81b23e \
+ --hash=sha256:3f3df1cc76c73cd4cbed0e967177d11031b511ecb67c97e3d549571fb2484441 \
+ --hash=sha256:3f4e24ee71b79b4a12428694acc9800c12963fb48d8e9be130dc07360222016b \
+ --hash=sha256:42e6309f679ee9fc331cdf5d16c1dbabb4231aa2dc9d83a8d3c66ac12d82279e \
+ --hash=sha256:440131421808c9a2fc4a4325176838913f41961f63e8fea66e5b53ac11f3d1d8 \
+ --hash=sha256:444b4f1018974343b09c0241982d1dec9ecce83787a448c8ed1c9663a15f70e0 \
+ --hash=sha256:5cd2d3cd0b0a16ac7d9795c0431e09b69ed49a65eaf56c6ee6755f0c902790d0 \
+ --hash=sha256:5cfdbeae6bda05cb8adb7d401f117a708cdab481b7eebae8307aa09a9e28d487 \
+ --hash=sha256:629604293df2be8171ec856bf4f8b4faa8e4305af13607dce0f89f74132836d6 \
+ --hash=sha256:6743ccef3a949b5927bdee78c69ffa567f211ac26d85fabe84043d20cbd3c2f9 \
+ --hash=sha256:69dc2992e3c06ebabf3e237522d7baf370ea144674c9df7be6157e926886d0e1 \
+ --hash=sha256:72f2bed7c2ceadb663efefa1562b2009aab1ba3966ce11a7bd2881e8c44f3518 \
+ --hash=sha256:77264cf06d7ecc9b2a384be65578fccc0b5a585ff2500a7c158077bd09e04725 \
+ --hash=sha256:856e118815017feaccab1137fa12e09178e88174404b1df11a4dc48a7a3ad0ee \
+ --hash=sha256:8dd08a77e402ef97b40b975ae5b23a9aa8016c351b625cfbce87a1b314fc5b19 \
+ --hash=sha256:97462eda40d3a3aa3360261df45e64caf16e8bfb24260a03b6a5e2d8a9c0e665 \
+ --hash=sha256:a098e4cee612e18f7457482f58096c6ad7496700b27774e1f6f82967c8fb9743 \
+ --hash=sha256:a3786faac06a2deca871f2ca93ea10a5baf2ef6431f59151b031ed4354d2a53c \
+ --hash=sha256:a6d4805a87a621443ff374c72cca082b2de698a7acf795001a44d4977dd4c23e \
+ --hash=sha256:a929edc9995e15b0eb17a80f21e4683c51cc4e457fbe9398b82afc3c606cf208 \
+ --hash=sha256:ad01b5d9c62cd441fdc2444a0b227d6f40790325d3fb65930928846f0c509653 \
+ --hash=sha256:ba9c0328845ce0b43b62674d304aeafee6d23f483b48d503db3682aefba3b751 \
+ --hash=sha256:c3e4d0da931de8caea4e71344be4900251c01910628ad456f4c4e010df7206db \
+ --hash=sha256:c4bc16d718f3d12775c5c86c97e64a5409bf4c68a789794040aa43a54039bcfd \
+ --hash=sha256:ceb3937fb4e59756fc9a1930abc423d33a6009c991a30ffb7aa708a6130fc4eb \
+ --hash=sha256:d26ab92a68ff8891717f9f3fe8d3514c4b9d421127a47d93c47c437a9297fa91 \
+ --hash=sha256:dd0ec5344b581386323ad05af0a5bf431857485851fc5054b5f0d846fcb9ce80 \
+ --hash=sha256:df0d5b558396a09b7d7eada50361989e1625c79593361f1e49d835f529446650 \
+ --hash=sha256:e11fc5556c68f1269edb5d04e4c4dd4af20a8cb389e6d2c103d89552dea738ae \
+ --hash=sha256:e2991b93a5c7e25363f73403866ff5ca641a2af9b39fc7397dd6776654be5af1 \
+ --hash=sha256:e35c4efb5cbfe9ef2bc98516b2b798b4c69847d644999b643c45856c47a16f70 \
+ --hash=sha256:e7685ff82cf8589fe240a83347b7ee73765525a5dd8c311bf69f8b187f9ecf40 \
+ --hash=sha256:ec2a00f73da23123c52ec68206b6ebed1a214c569cda37aaab7b343ef539c7c3 \
+ --hash=sha256:f08fa97d6416b93a6b7a900d1bee44701ed30dc84c4a0406c468eb8b4ec4d16a \
+ --hash=sha256:f4d26f3932416c29a052072ba216ba9c31a3d61a8ac80d20996d4e83a0749320 \
+ --hash=sha256:f545c86537f6b542ab7ecae5a4869b716b2d50a58739ab616b1884b0e37cd5c7 \
+ --hash=sha256:f6e0c74b14bb57304992b39a57c40b47189c5bb40bc797d3a6e135388d560133
# via -r contrib/packaging/venv_py3/requirements.txt.in
pycparser==2.21 \
--hash=sha256:8ee45429555515e1f6b185e78100aea234072576aa43ab53aefcae078162fca9 \

Matt Harbison

unread,
Nov 26, 2024, 1:50:57 AM11/26/24
to thg...@googlegroups.com
# HG changeset patch
# User Matt Harbison <matt_h...@yahoo.com>
# Date 1732600100 18000
# Tue Nov 26 00:48:20 2024 -0500
# Branch stable
# Node ID c8371847a1d591afad968d1f9475e35353318324
# Parent 37bf9d88efc87e0d831c976898a0e7514110b1c8
# EXP-Topic csinfo-pytype-fix
qt5: ensure a font is set before setting a lexer (fixes #5776)

I have no idea what's going on here. The problem is a weird corruption of the
font display where characters aren't emitted as expected at the caret, and the
font has strange width variations. This wasn't a problem back in the Python 2
days, but is a cross platform problem since updating to more recent Qt5/PyQt5 to
support Python 3.

Denis Matsiusheuski proposed the changes to hgemail.py, phabreview.py,
qscilib.py, rejects.py, and revset.py in the issue tracker. I cargoculted the
rest wherever there was a `setLexer()` call. I can say that this fixes the
preview text for the Email and Phabricator components, as well as the revset
dialog, config settings file editor, and rejects dialog. While I originally had
the issue on the commit widget when porting to py3, that seems to have stopped
misbehaving for some reason, and I see no difference with or without this change
(on Windows, anyway).

There are a few places in the `_FileViewControl` and `_DiffViewControl` classes
of `tortoisehg.hgqt.fileview` that lack an initial `setFont()`- one is in each
`close()` override, which sets a None lexer (presumably that's OK). The other
is in `_DiffViewControl.open()`, but I'm not sure if we have a font for that.

diff --git a/tortoisehg/hgqt/filedialogs.py b/tortoisehg/hgqt/filedialogs.py
--- a/tortoisehg/hgqt/filedialogs.py
+++ b/tortoisehg/hgqt/filedialogs.py
@@ -523,9 +523,8 @@
sci.setMarginLineNumbers(1, True)
sci.SendScintilla(sci.SCI_SETSELEOLFILLED, True)

+ sci.setFont(qtlib.getfont('fontdiff').font())
sci.setLexer(lexer)
- if lexer is None:
- sci.setFont(qtlib.getfont('fontdiff').font())

sci.setReadOnly(True)
sci.setUtf8(True)
diff --git a/tortoisehg/hgqt/fileview.py b/tortoisehg/hgqt/fileview.py
--- a/tortoisehg/hgqt/fileview.py
+++ b/tortoisehg/hgqt/fileview.py
@@ -841,9 +841,8 @@
if fd.contents:
filename = fd.filePath()
lexer = lexers.getlexer(self._ui, filename, fd.contents, self)
+ self._sci.setFont(qtlib.getfont('fontlog').font())
self._sci.setLexer(lexer)
- if lexer is None:
- self._sci.setFont(qtlib.getfont('fontlog').font())
self._sci.setText(fd.fileText())

self._sci.setMarginsFont(self._sci.font())
@@ -923,8 +922,8 @@
self._forceviewindicator = None

def open(self):
+ self._sci.setFont(qtlib.getfont('fontlog').font())
self._sci.setLexer(None)
- self._sci.setFont(qtlib.getfont('fontlog').font())

def close(self):
pass
diff --git a/tortoisehg/hgqt/hgemail.py b/tortoisehg/hgqt/hgemail.py
--- a/tortoisehg/hgqt/hgemail.py
+++ b/tortoisehg/hgqt/hgemail.py
@@ -326,6 +326,7 @@
fh = qtlib.getfont('fontdiff')
fh.changed.connect(self.forwardFont)
lex.setFont(fh.font())
+ w.setFont(fh.font())
w.setLexer(lex)
# TODO: better way to setup diff lexer

diff --git a/tortoisehg/hgqt/messageentry.py b/tortoisehg/hgqt/messageentry.py
--- a/tortoisehg/hgqt/messageentry.py
+++ b/tortoisehg/hgqt/messageentry.py
@@ -76,13 +76,13 @@
def applylexer(self):
font = qtlib.getfont('fontcomment').font()
self.fontHeight = QFontMetrics(font).height()
+ self.setFont(font)
if qtlib.readBool(QSettings(), 'msgentry/lexer', True):
self.setLexer(QsciLexerMakefile(self))
self.lexer().setColor(QColor(Qt.GlobalColor.red), QsciLexerMakefile.Error)
self.lexer().setFont(font)
else:
self.setLexer(None)
- self.setFont(font)

@pyqtSlot(QPoint)
def menuRequested(self, point):
diff --git a/tortoisehg/hgqt/phabreview.py b/tortoisehg/hgqt/phabreview.py
--- a/tortoisehg/hgqt/phabreview.py
+++ b/tortoisehg/hgqt/phabreview.py
@@ -364,6 +364,7 @@
fh = qtlib.getfont('fontdiff')
fh.changed.connect(self.forwardFont)
lex.setFont(fh.font())
+ w.setFont(fh.font())
w.setLexer(lex)
# TODO: better way to setup diff lexer

diff --git a/tortoisehg/hgqt/qscilib.py b/tortoisehg/hgqt/qscilib.py
--- a/tortoisehg/hgqt/qscilib.py
+++ b/tortoisehg/hgqt/qscilib.py
@@ -831,9 +831,10 @@
editor.setMarginLineNumbers(1, True)
editor.setMarginWidth(1, '000')

+ font = qtlib.getfont('fonteditor').font()
lexer = QsciLexerProperties()
- lexer.setFont(qtlib.getfont('fonteditor').font(), -1)
-
+ lexer.setFont(font, -1)
+ editor.setFont(font)
editor.setLexer(lexer)

if opts.get('foldable'):
diff --git a/tortoisehg/hgqt/rejects.py b/tortoisehg/hgqt/rejects.py
--- a/tortoisehg/hgqt/rejects.py
+++ b/tortoisehg/hgqt/rejects.py
@@ -126,9 +126,8 @@
return
earlybytes = hglib.fromunicode(editor.text(), 'replace')[:4096]
lexer = lexers.getlexer(ui, hglib.tounicode(path), earlybytes, self)
+ editor.setFont(qtlib.getfont('fontlog').font())
editor.setLexer(lexer)
- if lexer is None:
- editor.setFont(qtlib.getfont('fontlog').font())
editor.setMarginLineNumbers(1, True)
editor.setMarginWidth(1, str(editor.lines())+'X')

@@ -291,6 +290,7 @@
(1 << self.addedColor) | (1 << self.removedColor)
self.setMarginMarkerMask(1, mask)
lexer = lexers.difflexer(self)
+ self.setFont(qtlib.getfont('fontdiff').font())
self.setLexer(lexer)

def showChunk(self, lines):
diff --git a/tortoisehg/hgqt/revset.py b/tortoisehg/hgqt/revset.py
--- a/tortoisehg/hgqt/revset.py
+++ b/tortoisehg/hgqt/revset.py
@@ -342,8 +342,10 @@
self.setAutoCompletionThreshold(2)
self.setAutoCompletionSource(QsciScintilla.AutoCompletionSource.AcsAPIs)
self.setAutoCompletionFillupsEnabled(True)
+ font = qtlib.getfont('fontcomment').font()
+ self.setFont(font)
self.setLexer(QsciLexerPython(self))
- self.lexer().setFont(qtlib.getfont('fontcomment').font())
+ self.lexer().setFont(font)
self.apis = QsciAPIs(self.lexer())

def addCompletions(self, *lists):

Matt Harbison

unread,
Nov 26, 2024, 1:50:58 AM11/26/24
to thg...@googlegroups.com
# HG changeset patch
# User Matt Harbison <matt_h...@yahoo.com>
# Date 1732602374 18000
# Tue Nov 26 01:26:14 2024 -0500
# Branch stable
# Node ID 2be41a75024f64b9915313c90e4475d2a356fb81
# Parent c8371847a1d591afad968d1f9475e35353318324
# EXP-Topic csinfo-pytype-fix
packaging: bump PyQt5 to 5.15.11 on Windows

No idea if this will help anything, and I don't have time to test macOS or
Linux. Apparently the installer build is already using the latest Qt5 and
QScintilla versions.

diff --git a/contrib/packaging/requirements-windows-pyqt5-installer.txt b/contrib/packaging/requirements-windows-pyqt5-installer.txt
--- a/contrib/packaging/requirements-windows-pyqt5-installer.txt
+++ b/contrib/packaging/requirements-windows-pyqt5-installer.txt
@@ -256,13 +256,13 @@
--hash=sha256:44238f1b60a76d78fc8ca0528ee429702aae011c265fe6a8dd8b63049ae41c65 \
--hash=sha256:4e426f72023d88d03b2fa258de560726ce890ff3b630f88c21cbb8b2503b8c6a
# via -r contrib/packaging/venv_py3/requirements.txt.in
-pyqt5==5.15.10 \
- --hash=sha256:501355f327e9a2c38db0428e1a236d25ebcb99304cd6e668c05d1188d514adec \
- --hash=sha256:862cea3be95b4b0a2b9678003b3a18edf7bd5eafd673860f58820f246d4bf616 \
- --hash=sha256:93288d62ebd47b1933d80c27f5d43c7c435307b84d480af689cef2474e87e4c8 \
- --hash=sha256:b89478d16d4118664ff58ed609e0a804d002703c9420118de7e4e70fa1cb5486 \
- --hash=sha256:d46b7804b1b10a4ff91753f8113e5b5580d2b4462f3226288e2d84497334898a \
- --hash=sha256:ff99b4f91aa8eb60510d5889faad07116d3340041916e46c07d519f7cad344e1
+pyqt5==5.15.11 \
+ --hash=sha256:6cd75628f6e732b1ffcfe709ab833a0716c0445d7aec8046a48d5843352becb6 \
+ --hash=sha256:76be0322ceda5deecd1708a8d628e698089a1cea80d1a49d242a6d579a40babd \
+ --hash=sha256:bdde598a3bb95022131a5c9ea62e0a96bd6fb28932cc1619fd7ba211531b7517 \
+ --hash=sha256:c8b03dd9380bb13c804f0bdb0f4956067f281785b5e12303d529f0462f9afdc2 \
+ --hash=sha256:cd672a6738d1ae33ef7d9efa8e6cb0a1525ecf53ec86da80a9e1b6ec38c8d0f1 \
+ --hash=sha256:fda45743ebb4a27b4b1a51c6d8ef455c4c1b5d610c90d2934c7802b5c1557c52
# via
# -r contrib/packaging/venv_py3/requirements.txt.in
# qscintilla
@@ -272,28 +272,28 @@
--hash=sha256:76980cd3d7ae87e3c7a33bfebfaee84448fd650bad6840471d6cae199b56e154 \
--hash=sha256:9cc7a768b1921f4b982ebc00a318ccb38578e44e45316c7a4a850e953e1dd327
# via pyqt5
-pyqt5-sip==12.13.0 \
- --hash=sha256:0f85fb633a522f04e48008de49dce1ff1d947011b48885b8428838973fbca412 \
- --hash=sha256:108a15f603e1886988c4b0d9d41cb74c9f9815bf05cefc843d559e8c298a10ce \
- --hash=sha256:1c8371682f77852256f1f2d38c41e2e684029f43330f0635870895ab01c02f6c \
- --hash=sha256:205cd449d08a2b024a468fb6100cd7ed03e946b4f49706f508944006f955ae1a \
- --hash=sha256:29fa9cc964517c9fc3f94f072b9a2aeef4e7a2eda1879cb835d9e06971161cdf \
- --hash=sha256:3188a06956aef86f604fb0d14421a110fad70d2a9e943dbacbfc3303f651dade \
- --hash=sha256:3a4498f3b1b15f43f5d12963accdce0fd652b0bcaae6baf8008663365827444c \
- --hash=sha256:5338773bbaedaa4f16a73c142fb23cc18c327be6c338813af70260b756c7bc92 \
- --hash=sha256:6e4ac714252370ca037c7d609da92388057165edd4f94e63354f6d65c3ed9d53 \
- --hash=sha256:773731b1b5ab1a7cf5621249f2379c95e3d2905e9bd96ff3611b119586daa876 \
- --hash=sha256:7f321daf84b9c9dbca61b80e1ef37bdaffc0e93312edae2cd7da25b953971d91 \
- --hash=sha256:7fe3375b508c5bc657d73b9896bba8a768791f1f426c68053311b046bcebdddf \
- --hash=sha256:96414c93f3d33963887cf562d50d88b955121fbfd73f937c8eca46643e77bf61 \
- --hash=sha256:9a8cdd6cb66adcbe5c941723ed1544eba05cf19b6c961851b58ccdae1c894afb \
- --hash=sha256:9b984c2620a7a7eaf049221b09ae50a345317add2624c706c7d2e9e6632a9587 \
- --hash=sha256:a7e3623b2c743753625c4650ec7696362a37fb36433b61824cf257f6d3d43cca \
- --hash=sha256:bbc7cd498bf19e0862097be1ad2243e824dea56726f00c11cff1b547c2d31d01 \
- --hash=sha256:d5032da3fff62da055104926ffe76fd6044c1221f8ad35bb60804bcb422fe866 \
- --hash=sha256:db228cd737f5cbfc66a3c3e50042140cb80b30b52edc5756dbbaa2346ec73137 \
- --hash=sha256:ec60162e034c42fb99859206d62b83b74f987d58937b3a82bdc07b5c3d190dec \
- --hash=sha256:fb4a5271fa3f6bc2feb303269a837a95a6d8dd16be553aa40e530de7fb81bfdf
+pyqt5-sip==12.15.0 \
+ --hash=sha256:0b718a362f4392430903bbb2a4b9bbff9841a16a52f0cfdd5b5bbd9d11457980 \
+ --hash=sha256:0c1c727ede7fdc464a1fe2e46109ba836509b2d7187a46fdeae443148ce51d1c \
+ --hash=sha256:0cd21c3215e3c47fdd5fa7a2dc3dd1e07a7230b0626e905a7217925068c788b9 \
+ --hash=sha256:13f0c6a78e781255863e3e160304648efaf62276b7102741af637b63a6e96930 \
+ --hash=sha256:24a1d4937332bf0a38dd95bb2ce4d89723df449f6e912b52ef0e107e11fefac1 \
+ --hash=sha256:2575f428de584a12009fd29d00c89df16ed101a3b38beba818dfdcbc4a10709c \
+ --hash=sha256:749f7a3ffd6e3d2d5db65ed92c95cbd14490631595c61f0c0672c9238bfb17de \
+ --hash=sha256:7f88c85702dce80ac2e1a162054f688ed394811d6dd03a5574b3fa8111b0a6db \
+ --hash=sha256:83d247cdc43ef224410b14c97413067ea26356dfa39e9ed0fe702a31e25710b0 \
+ --hash=sha256:852b75cf208825602480e95ab63314108f872d0da251e9ad3deaaff5a183a6f5 \
+ --hash=sha256:855563d4d3b59ce7438bbf2dd32fed2707787defa40f3efe94f204a19ef92b25 \
+ --hash=sha256:91b9538458a3a23e033c213bc879ce64f3d0a33d5a49cbd03e1e584efe307a35 \
+ --hash=sha256:97f2d6e8d9b7b3d3e795d576d7f56e6257f524221f6383b33ded7287763e9f06 \
+ --hash=sha256:b4adc529fa4ec05728e14ea55194d907cc51f18d6f2ac5cc9f6eb52ac038aa0f \
+ --hash=sha256:b58eeedc9b2a3037b136bf96915196c391a33be470ed1c0723d7163ef0b727a2 \
+ --hash=sha256:c0c543d604116af26694a8a5ba90f510551ff9124d503ae5ee14bb73a61363a3 \
+ --hash=sha256:c85be433fbafcb3d417581c0e1b67c8198d23858166e4f938e971c2262c13cdb \
+ --hash=sha256:d23fdfcf363b5cedd9d39f8a9c5710e7d52804f5b08a58e91c638b36eafcb702 \
+ --hash=sha256:dd241de9c569c07bbba62bff1049996e5b52478164f61f430073a87bf6d26d33 \
+ --hash=sha256:ed5221c6241981bd98d39504823efb9cbe36841bf8917288f8fe8fc1d5569a41 \
+ --hash=sha256:f600ae6f03e4bff91153c0dc7ebe52f90bd2b6afda58fd580e6990b3b951adc0
# via
# pyqt5
# qscintilla
diff --git a/contrib/packaging/venv_py3/requirements_win32.txt b/contrib/packaging/venv_py3/requirements_win32.txt
--- a/contrib/packaging/venv_py3/requirements_win32.txt
+++ b/contrib/packaging/venv_py3/requirements_win32.txt
@@ -147,12 +147,13 @@
--hash=sha256:b8e67fe6af78f492b3c4b3e2970c0624cbf08beb1e493b2c99b9fa1b67a20380 \
--hash=sha256:f398865f7eb6874156579fdf36bc840a03cab64d1cde9e93d68f46a425ec52c6
# via -r contrib/packaging/venv_py3/requirements.txt.in
-pyqt5==5.15.7 \
- --hash=sha256:08694f0a4c7d4f3d36b2311b1920e6283240ad3b7c09b515e08262e195dcdf37 \
- --hash=sha256:1a793748c60d5aff3850b7abf84d47c1d41edb11231b7d7c16bef602c36be643 \
- --hash=sha256:232fe5b135a095cbd024cf341d928fc672c963f88e6a52b0c605be8177c2fdb5 \
- --hash=sha256:755121a52b3a08cb07275c10ebb96576d36e320e572591db16cfdbc558101594 \
- --hash=sha256:e319c9d8639e0729235c1b09c99afdadad96fa3dbd8392ab561b5ab5946ee6ef
+pyqt5==5.15.11 \
+ --hash=sha256:6cd75628f6e732b1ffcfe709ab833a0716c0445d7aec8046a48d5843352becb6 \
+ --hash=sha256:76be0322ceda5deecd1708a8d628e698089a1cea80d1a49d242a6d579a40babd \
+ --hash=sha256:bdde598a3bb95022131a5c9ea62e0a96bd6fb28932cc1619fd7ba211531b7517 \
+ --hash=sha256:c8b03dd9380bb13c804f0bdb0f4956067f281785b5e12303d529f0462f9afdc2 \
+ --hash=sha256:cd672a6738d1ae33ef7d9efa8e6cb0a1525ecf53ec86da80a9e1b6ec38c8d0f1 \
+ --hash=sha256:fda45743ebb4a27b4b1a51c6d8ef455c4c1b5d610c90d2934c7802b5c1557c52
# via
# -r contrib/packaging/venv_py3/requirements.txt.in
# qscintilla
@@ -162,24 +163,28 @@
--hash=sha256:76980cd3d7ae87e3c7a33bfebfaee84448fd650bad6840471d6cae199b56e154 \
--hash=sha256:9cc7a768b1921f4b982ebc00a318ccb38578e44e45316c7a4a850e953e1dd327
# via pyqt5
-pyqt5-sip==12.11.0 \
- --hash=sha256:0f77655c62ec91d47c2c99143f248624d44dd2d8a12d016e7c020508ad418aca \
- --hash=sha256:205f3e1b3eea3597d8e878936c1a06e04bd23a59e8b179ee806465d72eea3071 \
- --hash=sha256:3126c84568ab341c12e46ded2230f62a9a78752a70fdab13713f89a71cd44f73 \
- --hash=sha256:4031547dfb679be309094bfa79254f5badc5ddbe66b9ad38e319d84a7d612443 \
- --hash=sha256:42320e7a94b1085ed85d49794ed4ccfe86f1cae80b44a894db908a8aba2bc60e \
- --hash=sha256:4e5c1559311515291ea0ab0635529f14536954e3b973a7c7890ab7e4de1c2c23 \
- --hash=sha256:51e377789d59196213eddf458e6927f33ba9d217b614d17d20df16c9a8b2c41c \
- --hash=sha256:686071be054e5be6ca5aaaef7960931d4ba917277e839e2e978c7cbe3f43bb6e \
- --hash=sha256:9356260d4feb60dbac0ab66f8a791a0d2cda1bf98c9dec8e575904a045fbf7c5 \
- --hash=sha256:9bca450c5306890cb002fe36bbca18f979dd9e5b810b766dce8e3ce5e66ba795 \
- --hash=sha256:ad21ca0ee8cae2a41b61fc04949dccfab6fe008749627d94e8c7078cb7a73af1 \
- --hash=sha256:b4710fd85b57edef716cc55fae45bfd5bfac6fc7ba91036f1dcc3f331ca0eb39 \
- --hash=sha256:b69a1911f768b489846335e31e49eb34795c6b5a038ca24d894d751e3b0b44da \
- --hash=sha256:d12b81c3a08abf7657a2ebc7d3649852a1f327eb2146ebadf45930486d32e920 \
- --hash=sha256:ec5e9ef78852e1f96f86d7e15c9215878422b83dde36d44f1539a3062942f19c \
- --hash=sha256:f1f9e312ff8284d6dfebc5366f6f7d103f84eec23a4da0be0482403933e68660 \
- --hash=sha256:f6b72035da4e8fecbb0bc4a972e30a5674a9ad5608dbddaa517e983782dbf3bf
+pyqt5-sip==12.15.0 \
+ --hash=sha256:0b718a362f4392430903bbb2a4b9bbff9841a16a52f0cfdd5b5bbd9d11457980 \
+ --hash=sha256:0c1c727ede7fdc464a1fe2e46109ba836509b2d7187a46fdeae443148ce51d1c \
+ --hash=sha256:0cd21c3215e3c47fdd5fa7a2dc3dd1e07a7230b0626e905a7217925068c788b9 \
+ --hash=sha256:13f0c6a78e781255863e3e160304648efaf62276b7102741af637b63a6e96930 \
+ --hash=sha256:24a1d4937332bf0a38dd95bb2ce4d89723df449f6e912b52ef0e107e11fefac1 \
+ --hash=sha256:2575f428de584a12009fd29d00c89df16ed101a3b38beba818dfdcbc4a10709c \
+ --hash=sha256:749f7a3ffd6e3d2d5db65ed92c95cbd14490631595c61f0c0672c9238bfb17de \
+ --hash=sha256:7f88c85702dce80ac2e1a162054f688ed394811d6dd03a5574b3fa8111b0a6db \
+ --hash=sha256:83d247cdc43ef224410b14c97413067ea26356dfa39e9ed0fe702a31e25710b0 \
+ --hash=sha256:852b75cf208825602480e95ab63314108f872d0da251e9ad3deaaff5a183a6f5 \
+ --hash=sha256:855563d4d3b59ce7438bbf2dd32fed2707787defa40f3efe94f204a19ef92b25 \
+ --hash=sha256:91b9538458a3a23e033c213bc879ce64f3d0a33d5a49cbd03e1e584efe307a35 \
+ --hash=sha256:97f2d6e8d9b7b3d3e795d576d7f56e6257f524221f6383b33ded7287763e9f06 \
+ --hash=sha256:b4adc529fa4ec05728e14ea55194d907cc51f18d6f2ac5cc9f6eb52ac038aa0f \
+ --hash=sha256:b58eeedc9b2a3037b136bf96915196c391a33be470ed1c0723d7163ef0b727a2 \
+ --hash=sha256:c0c543d604116af26694a8a5ba90f510551ff9124d503ae5ee14bb73a61363a3 \
+ --hash=sha256:c85be433fbafcb3d417581c0e1b67c8198d23858166e4f938e971c2262c13cdb \
+ --hash=sha256:d23fdfcf363b5cedd9d39f8a9c5710e7d52804f5b08a58e91c638b36eafcb702 \
+ --hash=sha256:dd241de9c569c07bbba62bff1049996e5b52478164f61f430073a87bf6d26d33 \
+ --hash=sha256:ed5221c6241981bd98d39504823efb9cbe36841bf8917288f8fe8fc1d5569a41 \
+ --hash=sha256:f600ae6f03e4bff91153c0dc7ebe52f90bd2b6afda58fd580e6990b3b951adc0
# via
# pyqt5
# qscintilla
@@ -195,12 +200,13 @@
--hash=sha256:e372e477d938a49266136bff78279ed14445e00718b6c75543334351bf535259 \
--hash=sha256:fe21c2fb332d03dac29de070f191bdbf14095167f8f2165fdc57db59b1ecc006
# via -r contrib/packaging/venv_py3/requirements_win32.txt.in
-qscintilla==2.13.3 \
- --hash=sha256:332147584af3f0f584384cc133e5fb32bafba317cdbfb9b53b944ff28665db9d \
- --hash=sha256:747ea02fc9ac8e9ad1c3c82528e6d5f7d83abad823c221d2a4bcc9f41cf04e5a \
- --hash=sha256:92ae5bf066e0bcb79f0c1df255882189b66c200f92f08ca14f09b82479469dce \
- --hash=sha256:c8db00dc1498e6a86c885bf75c628208dea21ec051eaaeb25946323567959975 \
- --hash=sha256:fa48d5e0684c1183cc41cacacf5b180f22dcf29bcc8bafe2cd373832947e4179
+qscintilla==2.14.1 \
+ --hash=sha256:2c120a56d60363ff4bc73b8a763dc69fae5f84681c24efcb03064c7df103052b \
+ --hash=sha256:31fa0ddd4d61908c903e8c53783338d4d2e312cb2bccdc544fb4c41a8a0580f2 \
+ --hash=sha256:3a0deb6d00251643fbbd0bfd6e7f876477c179313a5fc2a7d7050a1c21b595b0 \
+ --hash=sha256:8dedbfc646669ad7a380497abddcfe1dd8ea08831cdd07ce89538eb75123ceeb \
+ --hash=sha256:9be3cfe39756d94aacdecf8ab8964eaac7223f36eddff62bc74df2128266510f \
+ --hash=sha256:ba3d7ffe5a8610674e9f11c4e69197763bb968e73f06397d4c64d08ffcd5a15e
# via -r contrib/packaging/venv_py3/requirements.txt.in
six==1.16.0 \
--hash=sha256:1e61c37477a1626458e36f7b1d82aa5c9b094fa4802892072e49de9c60c4c926 \

Matt Harbison

unread,
Nov 26, 2024, 1:52:40 AM11/26/24
to TortoiseHg Developers
I think we're ready for the 6.9rc0 tag at this point.  I didn't try building the mac stuff, but x64 Windows builds and runs fine (with very light testing).

Yuya Nishihara

unread,
Nov 26, 2024, 7:43:17 AM11/26/24
to Matt Harbison, thg...@googlegroups.com
On Tue, 26 Nov 2024 01:50:50 -0500, Matt Harbison wrote:
> # HG changeset patch
> # User Matt Harbison <matt_h...@yahoo.com>
> # Date 1732600100 18000
> # Tue Nov 26 00:48:20 2024 -0500
> # Branch stable
> # Node ID c8371847a1d591afad968d1f9475e35353318324
> # Parent 37bf9d88efc87e0d831c976898a0e7514110b1c8
> # EXP-Topic csinfo-pytype-fix
> qt5: ensure a font is set before setting a lexer (fixes #5776)

Queued 2-5, thanks.

> I have no idea what's going on here. The problem is a weird corruption of the
> font display where characters aren't emitted as expected at the caret, and the
> font has strange width variations. This wasn't a problem back in the Python 2
> days, but is a cross platform problem since updating to more recent Qt5/PyQt5 to
> support Python 3.

I have no idea, but setting the default font early should be harmless, and I
generally prefer fewer `if`s.

Yuya Nishihara

unread,
Nov 26, 2024, 7:43:19 AM11/26/24
to Matt Harbison, thg...@googlegroups.com
Suppose update() is a compatibility function for callers who aren't migrated
to updateItem(), removing the style argument doesn't make sense. Can't we use
*args, **kwargs instead?

Matt Harbison

unread,
Nov 27, 2024, 2:52:56 AM11/27/24
to thg...@googlegroups.com
# HG changeset patch
# User Matt Harbison <matt_h...@yahoo.com>
# Date 1732687319 18000
# Wed Nov 27 01:01:59 2024 -0500
# Branch stable
# Node ID 59514ab7f31cfaf662ba91cc6f9eec9bdb7e98d2
# Parent 2dcff69f65638dce6da21041d280a120e76fb804
# EXP-Topic csinfo-pytype-fix
csinfo: add missing `style` argument to `updateItems()`

Since 2dcff69f6563, pytype was failing with:

FAILED: /builds/mercurial/tortoisehg/thg/.pytype/pyi/tortoisehg/hgqt/csinfo.pyi
File "/builds/mercurial/tortoisehg/thg/tortoisehg/hgqt/csinfo.py", line 413,
in update: Function SummaryBase.updateItems expects 1 arg(s), got 5 [wrong-arg-count]
Expected: (self, target, custom, repo)
Actually passed: (self, target, custom, repo, _)

There is indeed a wrong argument count there, because `updateItems()` was a
copy/paste of the original `update()` function in `SummaryBase`, which lacked
the `style` argument, though this call site was providing it. (I have no idea
why the error indicated it expected 1 argument instead of 4.) The overriding
`updateItems()` do have this argument, so add it to the base class and avoid an
error about a [signature-mismatch] too, which is what started the ball rolling
in a015c03d91c6. (I'm not sure why pytype wasn't flagging the signature
mismatch here, but it already seemed confused, and maybe the multiple
inheritance confused it more.)

The thing that was confusing about 2dcff69f6563 was it added the `style` arg to
the original `update()` method in the base class, apparently so that it could
also drop the (bad) overrides in the subclasses that also had it as an argument.
Let's fix the known failure first.

diff --git a/tortoisehg/hgqt/csinfo.py b/tortoisehg/hgqt/csinfo.py
--- a/tortoisehg/hgqt/csinfo.py
+++ b/tortoisehg/hgqt/csinfo.py
@@ -412,7 +412,7 @@
sys.stderr.flush()
self.updateItems(target, style, custom, repo)

Matt Harbison

unread,
Nov 27, 2024, 2:52:58 AM11/27/24
to thg...@googlegroups.com
# HG changeset patch
# User Matt Harbison <matt_h...@yahoo.com>
# Date 1732659357 18000
# Tue Nov 26 17:15:57 2024 -0500
# Branch stable
# Node ID 90ce75c89f382604b812d1175ff988ef576926ae
# Parent 59514ab7f31cfaf662ba91cc6f9eec9bdb7e98d2
# EXP-Topic csinfo-pytype-fix
csinfo: simplify `SummaryBase.update()` to use kwargs

This is a compatibility shim for existing callers. Prior to 2dcff69f6563, this
method lacked the `style` argument, but the subclass overrides had it. All
callers apparently use the subclass methods, but this attempts to be compatible
with both signatures. Additionally, both subclasses also inherit from `QWidget`,
which has its own set of `update()` function overloads that is typed with
`*args`.

diff --git a/tortoisehg/hgqt/csinfo.py b/tortoisehg/hgqt/csinfo.py
--- a/tortoisehg/hgqt/csinfo.py
+++ b/tortoisehg/hgqt/csinfo.py
@@ -401,7 +401,7 @@
# method that SummaryPanel and SummaryLabel get through multiple inheritance
# from QWidget and QLabel respectively. That update() method seems related
# to painting the component, or an area of it.
- def update(self, target=None, style=None, custom=None, repo=None): # pytype: disable=signature-mismatch
+ def update(self, *args, **kwargs): # pytype: disable=signature-mismatch
import warnings

warnings.warn(
@@ -410,7 +410,7 @@
2,
)
sys.stderr.flush()
- self.updateItems(target, style, custom, repo)
+ self.updateItems(*args, **kwargs)

Yuya Nishihara

unread,
Nov 27, 2024, 8:53:16 AM11/27/24
to Matt Harbison, thg...@googlegroups.com
On Wed, 27 Nov 2024 02:52:50 -0500, Matt Harbison wrote:
> # HG changeset patch
> # User Matt Harbison <matt_h...@yahoo.com>
> # Date 1732687319 18000
> # Wed Nov 27 01:01:59 2024 -0500
> # Branch stable
> # Node ID 59514ab7f31cfaf662ba91cc6f9eec9bdb7e98d2
> # Parent 2dcff69f65638dce6da21041d280a120e76fb804
> # EXP-Topic csinfo-pytype-fix
> csinfo: add missing `style` argument to `updateItems()`

Queued, thanks.

> Since 2dcff69f6563, pytype was failing with:
>
> FAILED: /builds/mercurial/tortoisehg/thg/.pytype/pyi/tortoisehg/hgqt/csinfo.pyi
> File "/builds/mercurial/tortoisehg/thg/tortoisehg/hgqt/csinfo.py", line 413,
> in update: Function SummaryBase.updateItems expects 1 arg(s), got 5 [wrong-arg-count]
> Expected: (self, target, custom, repo)
> Actually passed: (self, target, custom, repo, _)
>
> There is indeed a wrong argument count there, because `updateItems()` was a
> copy/paste of the original `update()` function in `SummaryBase`, which lacked
> the `style` argument, though this call site was providing it. (I have no idea
> why the error indicated it expected 1 argument instead of 4.) The overriding
> `updateItems()` do have this argument, so add it to the base class and avoid an
> error about a [signature-mismatch] too, which is what started the ball rolling
> in a015c03d91c6. (I'm not sure why pytype wasn't flagging the signature
> mismatch here, but it already seemed confused, and maybe the multiple
> inheritance confused it more.)
>
> The thing that was confusing about 2dcff69f6563 was it added the `style` arg to
> the original `update()` method in the base class, apparently so that it could
> also drop the (bad) overrides in the subclasses that also had it as an argument.
> Let's fix the known failure first.

Perhaps, updateItems() should be an abstract method, and updateItems() without
style should be renamed to something else. That said, I don't care about that.
Reply all
Reply to author
Forward
0 new messages