python-qube-heatpump 1.16.0__tar.gz → 1.16.1__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {python_qube_heatpump-1.16.0 → python_qube_heatpump-1.16.1}/PKG-INFO +1 -1
- {python_qube_heatpump-1.16.0 → python_qube_heatpump-1.16.1}/pyproject.toml +1 -1
- {python_qube_heatpump-1.16.0 → python_qube_heatpump-1.16.1}/src/python_qube_heatpump/client.py +4 -2
- {python_qube_heatpump-1.16.0 → python_qube_heatpump-1.16.1}/tests/test_client.py +17 -0
- {python_qube_heatpump-1.16.0 → python_qube_heatpump-1.16.1}/.github/ISSUE_TEMPLATE/bug_report.yml +0 -0
- {python_qube_heatpump-1.16.0 → python_qube_heatpump-1.16.1}/.github/ISSUE_TEMPLATE/config.yml +0 -0
- {python_qube_heatpump-1.16.0 → python_qube_heatpump-1.16.1}/.github/ISSUE_TEMPLATE/feature_request.yml +0 -0
- {python_qube_heatpump-1.16.0 → python_qube_heatpump-1.16.1}/.github/workflows/ci.yml +0 -0
- {python_qube_heatpump-1.16.0 → python_qube_heatpump-1.16.1}/.github/workflows/python-publish.yml +0 -0
- {python_qube_heatpump-1.16.0 → python_qube_heatpump-1.16.1}/.gitignore +0 -0
- {python_qube_heatpump-1.16.0 → python_qube_heatpump-1.16.1}/AGENTS.md +0 -0
- {python_qube_heatpump-1.16.0 → python_qube_heatpump-1.16.1}/CLAUDE.md +0 -0
- {python_qube_heatpump-1.16.0 → python_qube_heatpump-1.16.1}/LICENSE +0 -0
- {python_qube_heatpump-1.16.0 → python_qube_heatpump-1.16.1}/README.md +0 -0
- {python_qube_heatpump-1.16.0 → python_qube_heatpump-1.16.1}/docs/modbus-lijst-qube-totaal.pdf +0 -0
- {python_qube_heatpump-1.16.0 → python_qube_heatpump-1.16.1}/pytest.ini +0 -0
- {python_qube_heatpump-1.16.0 → python_qube_heatpump-1.16.1}/src/python_qube_heatpump/__init__.py +0 -0
- {python_qube_heatpump-1.16.0 → python_qube_heatpump-1.16.1}/src/python_qube_heatpump/const.py +0 -0
- {python_qube_heatpump-1.16.0 → python_qube_heatpump-1.16.1}/src/python_qube_heatpump/entities/__init__.py +0 -0
- {python_qube_heatpump-1.16.0 → python_qube_heatpump-1.16.1}/src/python_qube_heatpump/entities/base.py +0 -0
- {python_qube_heatpump-1.16.0 → python_qube_heatpump-1.16.1}/src/python_qube_heatpump/entities/binary_sensors.py +0 -0
- {python_qube_heatpump-1.16.0 → python_qube_heatpump-1.16.1}/src/python_qube_heatpump/entities/sensors.py +0 -0
- {python_qube_heatpump-1.16.0 → python_qube_heatpump-1.16.1}/src/python_qube_heatpump/entities/switches.py +0 -0
- {python_qube_heatpump-1.16.0 → python_qube_heatpump-1.16.1}/src/python_qube_heatpump/mdns.py +0 -0
- {python_qube_heatpump-1.16.0 → python_qube_heatpump-1.16.1}/src/python_qube_heatpump/models.py +0 -0
- {python_qube_heatpump-1.16.0 → python_qube_heatpump-1.16.1}/src/python_qube_heatpump/network.py +0 -0
- {python_qube_heatpump-1.16.0 → python_qube_heatpump-1.16.1}/src/python_qube_heatpump/py.typed +0 -0
- {python_qube_heatpump-1.16.0 → python_qube_heatpump-1.16.1}/tests/conftest.py +0 -0
- {python_qube_heatpump-1.16.0 → python_qube_heatpump-1.16.1}/tests/test_client_batching.py +0 -0
- {python_qube_heatpump-1.16.0 → python_qube_heatpump-1.16.1}/tests/test_client_read_all.py +0 -0
- {python_qube_heatpump-1.16.0 → python_qube_heatpump-1.16.1}/tests/test_client_resilience.py +0 -0
- {python_qube_heatpump-1.16.0 → python_qube_heatpump-1.16.1}/tests/test_client_writes.py +0 -0
- {python_qube_heatpump-1.16.0 → python_qube_heatpump-1.16.1}/tests/test_const.py +0 -0
- {python_qube_heatpump-1.16.0 → python_qube_heatpump-1.16.1}/tests/test_entities.py +0 -0
- {python_qube_heatpump-1.16.0 → python_qube_heatpump-1.16.1}/tests/test_mdns.py +0 -0
- {python_qube_heatpump-1.16.0 → python_qube_heatpump-1.16.1}/tests/test_models.py +0 -0
- {python_qube_heatpump-1.16.0 → python_qube_heatpump-1.16.1}/tests/test_network.py +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.5
|
|
2
2
|
Name: python-qube-heatpump
|
|
3
|
-
Version: 1.16.
|
|
3
|
+
Version: 1.16.1
|
|
4
4
|
Summary: Async Modbus client for Qube Heat Pumps
|
|
5
5
|
Project-URL: Homepage, https://github.com/MattieGit/python-qube-heatpump
|
|
6
6
|
Project-URL: Bug Tracker, https://github.com/MattieGit/python-qube-heatpump/issues
|
{python_qube_heatpump-1.16.0 → python_qube_heatpump-1.16.1}/src/python_qube_heatpump/client.py
RENAMED
|
@@ -394,10 +394,12 @@ class QubeClient:
|
|
|
394
394
|
Reads InputRegister 77 (GeneralMng.Softversion).
|
|
395
395
|
|
|
396
396
|
Returns:
|
|
397
|
-
Version as string (e.g., "2.15"), or None on error
|
|
397
|
+
Version as string (e.g., "2.15"), or None on error or when the
|
|
398
|
+
register reads 0 (it is not populated on some firmware, e.g.
|
|
399
|
+
4.1.00; use ``async_get_device_info`` for the panel version).
|
|
398
400
|
"""
|
|
399
401
|
value = await self.read_value(const.SOFTWARE_VERSION)
|
|
400
|
-
if value
|
|
402
|
+
if not value:
|
|
401
403
|
return None
|
|
402
404
|
return f"{value:.2f}"
|
|
403
405
|
|
|
@@ -246,6 +246,23 @@ async def test_get_software_version(mock_modbus_client):
|
|
|
246
246
|
assert isinstance(result, str)
|
|
247
247
|
|
|
248
248
|
|
|
249
|
+
@pytest.mark.asyncio
|
|
250
|
+
async def test_get_software_version_zero(mock_modbus_client):
|
|
251
|
+
"""Test an unpopulated register (reads 0) returns None, not "0.00"."""
|
|
252
|
+
client = QubeClient("1.2.3.4", 502)
|
|
253
|
+
mock_instance = mock_modbus_client.return_value
|
|
254
|
+
|
|
255
|
+
mock_resp = MagicMock()
|
|
256
|
+
mock_resp.isError.return_value = False
|
|
257
|
+
mock_resp.registers = [0, 0]
|
|
258
|
+
|
|
259
|
+
mock_instance.read_input_registers = AsyncMock(return_value=mock_resp)
|
|
260
|
+
client._client = mock_instance
|
|
261
|
+
|
|
262
|
+
result = await client.async_get_software_version()
|
|
263
|
+
assert result is None
|
|
264
|
+
|
|
265
|
+
|
|
249
266
|
@pytest.mark.asyncio
|
|
250
267
|
async def test_get_software_version_error(mock_modbus_client):
|
|
251
268
|
"""Test software version returns None on error."""
|
{python_qube_heatpump-1.16.0 → python_qube_heatpump-1.16.1}/.github/ISSUE_TEMPLATE/bug_report.yml
RENAMED
|
File without changes
|
{python_qube_heatpump-1.16.0 → python_qube_heatpump-1.16.1}/.github/ISSUE_TEMPLATE/config.yml
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
{python_qube_heatpump-1.16.0 → python_qube_heatpump-1.16.1}/.github/workflows/python-publish.yml
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{python_qube_heatpump-1.16.0 → python_qube_heatpump-1.16.1}/docs/modbus-lijst-qube-totaal.pdf
RENAMED
|
File without changes
|
|
File without changes
|
{python_qube_heatpump-1.16.0 → python_qube_heatpump-1.16.1}/src/python_qube_heatpump/__init__.py
RENAMED
|
File without changes
|
{python_qube_heatpump-1.16.0 → python_qube_heatpump-1.16.1}/src/python_qube_heatpump/const.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{python_qube_heatpump-1.16.0 → python_qube_heatpump-1.16.1}/src/python_qube_heatpump/mdns.py
RENAMED
|
File without changes
|
{python_qube_heatpump-1.16.0 → python_qube_heatpump-1.16.1}/src/python_qube_heatpump/models.py
RENAMED
|
File without changes
|
{python_qube_heatpump-1.16.0 → python_qube_heatpump-1.16.1}/src/python_qube_heatpump/network.py
RENAMED
|
File without changes
|
{python_qube_heatpump-1.16.0 → python_qube_heatpump-1.16.1}/src/python_qube_heatpump/py.typed
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|