From ee33f752325463ed996480ed13f032c88035e535 Mon Sep 17 00:00:00 2001 From: Alex Ruddick Date: Mon, 17 Nov 2025 20:48:20 -0600 Subject: [PATCH 1/2] update to pylint 4 --- pymodbus/pdu/device.py | 32 ++++++++++++++++---------------- pyproject.toml | 4 ++-- 2 files changed, 18 insertions(+), 18 deletions(-) diff --git a/pymodbus/pdu/device.py b/pymodbus/pdu/device.py index 9fa5b72e0..952a219d2 100644 --- a/pymodbus/pdu/device.py +++ b/pymodbus/pdu/device.py @@ -223,13 +223,13 @@ def __str__(self): # Properties # -------------------------------------------------------------------------# # fmt: off - VendorName = dict_property(lambda s: s.__data, 0) # pylint: disable=protected-access - ProductCode = dict_property(lambda s: s.__data, 1) # pylint: disable=protected-access - MajorMinorRevision = dict_property(lambda s: s.__data, 2) # pylint: disable=protected-access - VendorUrl = dict_property(lambda s: s.__data, 3) # pylint: disable=protected-access - ProductName = dict_property(lambda s: s.__data, 4) # pylint: disable=protected-access - ModelName = dict_property(lambda s: s.__data, 5) # pylint: disable=protected-access - UserApplicationName = dict_property(lambda s: s.__data, 6) # pylint: disable=protected-access + VendorName = dict_property(lambda s: s.__data, 0) + ProductCode = dict_property(lambda s: s.__data, 1) + MajorMinorRevision = dict_property(lambda s: s.__data, 2) + VendorUrl = dict_property(lambda s: s.__data, 3) + ProductName = dict_property(lambda s: s.__data, 4) + ModelName = dict_property(lambda s: s.__data, 5) + UserApplicationName = dict_property(lambda s: s.__data, 6) # fmt: on @@ -415,15 +415,15 @@ def summary(self): # Properties # -------------------------------------------------------------------------# # fmt: off - BusMessage = dict_property(lambda s: s.__data, 0) # pylint: disable=protected-access - BusCommunicationError = dict_property(lambda s: s.__data, 1) # pylint: disable=protected-access - BusExceptionError = dict_property(lambda s: s.__data, 2) # pylint: disable=protected-access - DeviceMessage = dict_property(lambda s: s.__data, 3) # pylint: disable=protected-access - DeviceNoResponse = dict_property(lambda s: s.__data, 4) # pylint: disable=protected-access - DeviceNAK = dict_property(lambda s: s.__data, 5) # pylint: disable=protected-access - DEVICE_BUSY = dict_property(lambda s: s.__data, 6) # pylint: disable=protected-access - BusCharacterOverrun = dict_property(lambda s: s.__data, 7) # pylint: disable=protected-access - Event = dict_property(lambda s: s.__data, 8) # pylint: disable=protected-access + BusMessage = dict_property(lambda s: s.__data, 0) + BusCommunicationError = dict_property(lambda s: s.__data, 1) + BusExceptionError = dict_property(lambda s: s.__data, 2) + DeviceMessage = dict_property(lambda s: s.__data, 3) + DeviceNoResponse = dict_property(lambda s: s.__data, 4) + DeviceNAK = dict_property(lambda s: s.__data, 5) + DEVICE_BUSY = dict_property(lambda s: s.__data, 6) + BusCharacterOverrun = dict_property(lambda s: s.__data, 7) + Event = dict_property(lambda s: s.__data, 8) # fmt: on diff --git a/pyproject.toml b/pyproject.toml index b9d83246f..551cc98cf 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -59,7 +59,7 @@ development = [ "codespell>=2.3.0", "coverage>=7.10.7", "mypy>=1.18.2", - "pylint>=3.3.0", + "pylint>=4.0.0", "pytest>=8.4.2", "pytest-asyncio>=1.2.0", "pytest-cov>=7.0.0", @@ -125,7 +125,7 @@ load-plugins = [ "pylint.extensions.typing" ] jobs = "0" -py-version = "3.9" +py-version = "3.10" [tool.pylint.messages_control] enable = "all" From b12975df44faf009db45b8746787ca1921493d07 Mon Sep 17 00:00:00 2001 From: Alex Ruddick Date: Mon, 17 Nov 2025 21:05:57 -0600 Subject: [PATCH 2/2] linting can now be done on 3.14 --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 6b073f21f..11fe75043 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -32,7 +32,7 @@ jobs: include: - python: '3.10' run_lint: true - - python: '3.13' + - python: '3.14' run_doc: true run_lint: true - os: macos-latest