hyxi-cloud-api 1.3.2__tar.gz → 1.3.4__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.
- {hyxi_cloud_api-1.3.2/src/hyxi_cloud_api.egg-info → hyxi_cloud_api-1.3.4}/PKG-INFO +2 -2
- {hyxi_cloud_api-1.3.2 → hyxi_cloud_api-1.3.4}/pyproject.toml +2 -2
- {hyxi_cloud_api-1.3.2 → hyxi_cloud_api-1.3.4}/src/hyxi_cloud_api/__init__.py +1 -1
- {hyxi_cloud_api-1.3.2 → hyxi_cloud_api-1.3.4}/src/hyxi_cloud_api/api.py +4 -13
- {hyxi_cloud_api-1.3.2 → hyxi_cloud_api-1.3.4/src/hyxi_cloud_api.egg-info}/PKG-INFO +2 -2
- {hyxi_cloud_api-1.3.2 → hyxi_cloud_api-1.3.4}/src/hyxi_cloud_api.egg-info/requires.txt +1 -1
- {hyxi_cloud_api-1.3.2 → hyxi_cloud_api-1.3.4}/tests/test_metrics_errors.py +2 -2
- {hyxi_cloud_api-1.3.2 → hyxi_cloud_api-1.3.4}/LICENSE +0 -0
- {hyxi_cloud_api-1.3.2 → hyxi_cloud_api-1.3.4}/README.md +0 -0
- {hyxi_cloud_api-1.3.2 → hyxi_cloud_api-1.3.4}/setup.cfg +0 -0
- {hyxi_cloud_api-1.3.2 → hyxi_cloud_api-1.3.4}/src/hyxi_cloud_api.egg-info/SOURCES.txt +0 -0
- {hyxi_cloud_api-1.3.2 → hyxi_cloud_api-1.3.4}/src/hyxi_cloud_api.egg-info/dependency_links.txt +0 -0
- {hyxi_cloud_api-1.3.2 → hyxi_cloud_api-1.3.4}/src/hyxi_cloud_api.egg-info/top_level.txt +0 -0
- {hyxi_cloud_api-1.3.2 → hyxi_cloud_api-1.3.4}/tests/test_additional_coverage.py +0 -0
- {hyxi_cloud_api-1.3.2 → hyxi_cloud_api-1.3.4}/tests/test_alarm_push.py +0 -0
- {hyxi_cloud_api-1.3.2 → hyxi_cloud_api-1.3.4}/tests/test_all_in_one.py +0 -0
- {hyxi_cloud_api-1.3.2 → hyxi_cloud_api-1.3.4}/tests/test_api.py +0 -0
- {hyxi_cloud_api-1.3.2 → hyxi_cloud_api-1.3.4}/tests/test_build_plant_tasks.py +0 -0
- {hyxi_cloud_api-1.3.2 → hyxi_cloud_api-1.3.4}/tests/test_caching.py +0 -0
- {hyxi_cloud_api-1.3.2 → hyxi_cloud_api-1.3.4}/tests/test_compute_battery_metrics.py +0 -0
- {hyxi_cloud_api-1.3.2 → hyxi_cloud_api-1.3.4}/tests/test_compute_derived_metrics.py +0 -0
- {hyxi_cloud_api-1.3.2 → hyxi_cloud_api-1.3.4}/tests/test_compute_grid_metrics.py +0 -0
- {hyxi_cloud_api-1.3.2 → hyxi_cloud_api-1.3.4}/tests/test_compute_load_metrics.py +0 -0
- {hyxi_cloud_api-1.3.2 → hyxi_cloud_api-1.3.4}/tests/test_device_control.py +0 -0
- {hyxi_cloud_api-1.3.2 → hyxi_cloud_api-1.3.4}/tests/test_device_entry.py +0 -0
- {hyxi_cloud_api-1.3.2 → hyxi_cloud_api-1.3.4}/tests/test_devices_errors.py +0 -0
- {hyxi_cloud_api-1.3.2 → hyxi_cloud_api-1.3.4}/tests/test_discovery.py +0 -0
- {hyxi_cloud_api-1.3.2 → hyxi_cloud_api-1.3.4}/tests/test_execute_device_tasks.py +0 -0
- {hyxi_cloud_api-1.3.2 → hyxi_cloud_api-1.3.4}/tests/test_execute_metric_tasks.py +0 -0
- {hyxi_cloud_api-1.3.2 → hyxi_cloud_api-1.3.4}/tests/test_execute_metrics_and_map_alarms.py +0 -0
- {hyxi_cloud_api-1.3.2 → hyxi_cloud_api-1.3.4}/tests/test_extract_battery_info.py +0 -0
- {hyxi_cloud_api-1.3.2 → hyxi_cloud_api-1.3.4}/tests/test_extract_device_info_metadata.py +0 -0
- {hyxi_cloud_api-1.3.2 → hyxi_cloud_api-1.3.4}/tests/test_fetch_and_process_alarms.py +0 -0
- {hyxi_cloud_api-1.3.2 → hyxi_cloud_api-1.3.4}/tests/test_fetch_device_list_for_plant.py +0 -0
- {hyxi_cloud_api-1.3.2 → hyxi_cloud_api-1.3.4}/tests/test_fetch_plants.py +0 -0
- {hyxi_cloud_api-1.3.2 → hyxi_cloud_api-1.3.4}/tests/test_fetch_state.py +0 -0
- {hyxi_cloud_api-1.3.2 → hyxi_cloud_api-1.3.4}/tests/test_fetch_sub_device_list.py +0 -0
- {hyxi_cloud_api-1.3.2 → hyxi_cloud_api-1.3.4}/tests/test_filter_metrics.py +0 -0
- {hyxi_cloud_api-1.3.2 → hyxi_cloud_api-1.3.4}/tests/test_fuzz_parser.py +0 -0
- {hyxi_cloud_api-1.3.2 → hyxi_cloud_api-1.3.4}/tests/test_get_f.py +0 -0
- {hyxi_cloud_api-1.3.2 → hyxi_cloud_api-1.3.4}/tests/test_handle_back_discovery_alarm.py +0 -0
- {hyxi_cloud_api-1.3.2 → hyxi_cloud_api-1.3.4}/tests/test_info_errors.py +0 -0
- {hyxi_cloud_api-1.3.2 → hyxi_cloud_api-1.3.4}/tests/test_mask_id.py +0 -0
- {hyxi_cloud_api-1.3.2 → hyxi_cloud_api-1.3.4}/tests/test_parse_data_list.py +0 -0
- {hyxi_cloud_api-1.3.2 → hyxi_cloud_api-1.3.4}/tests/test_parse_ems_kv.py +0 -0
- {hyxi_cloud_api-1.3.2 → hyxi_cloud_api-1.3.4}/tests/test_parser.py +0 -0
- {hyxi_cloud_api-1.3.2 → hyxi_cloud_api-1.3.4}/tests/test_process_alarms_and_back_discovery.py +0 -0
- {hyxi_cloud_api-1.3.2 → hyxi_cloud_api-1.3.4}/tests/test_process_devices_for_plant.py +0 -0
- {hyxi_cloud_api-1.3.2 → hyxi_cloud_api-1.3.4}/tests/test_push.py +0 -0
- {hyxi_cloud_api-1.3.2 → hyxi_cloud_api-1.3.4}/tests/test_sanitize_dict.py +0 -0
- {hyxi_cloud_api-1.3.2 → hyxi_cloud_api-1.3.4}/tests/test_sanitize_list.py +0 -0
- {hyxi_cloud_api-1.3.2 → hyxi_cloud_api-1.3.4}/tests/test_security_fix.py +0 -0
- {hyxi_cloud_api-1.3.2 → hyxi_cloud_api-1.3.4}/tests/test_subscriptions.py +0 -0
- {hyxi_cloud_api-1.3.2 → hyxi_cloud_api-1.3.4}/tests/test_token_errors.py +0 -0
- {hyxi_cloud_api-1.3.2 → hyxi_cloud_api-1.3.4}/tests/test_token_handling.py +0 -0
- {hyxi_cloud_api-1.3.2 → hyxi_cloud_api-1.3.4}/tests/test_validate_post_rate_ms.py +0 -0
- {hyxi_cloud_api-1.3.2 → hyxi_cloud_api-1.3.4}/tests/test_validate_subscription_device_sns.py +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: hyxi-cloud-api
|
|
3
|
-
Version: 1.3.
|
|
3
|
+
Version: 1.3.4
|
|
4
4
|
Summary: An async API client for HYXi Cloud.
|
|
5
5
|
Author-email: Veldkornet <Veldkornet@users.noreply.github.com>
|
|
6
6
|
Classifier: Programming Language :: Python :: 3
|
|
@@ -14,7 +14,7 @@ Classifier: Topic :: Home Automation
|
|
|
14
14
|
Requires-Python: >=3.14
|
|
15
15
|
Description-Content-Type: text/markdown
|
|
16
16
|
License-File: LICENSE
|
|
17
|
-
Requires-Dist: aiohttp>=3.
|
|
17
|
+
Requires-Dist: aiohttp>=3.14.0
|
|
18
18
|
Provides-Extra: test
|
|
19
19
|
Requires-Dist: pytest>=9.0.3; extra == "test"
|
|
20
20
|
Requires-Dist: pytest-asyncio; extra == "test"
|
|
@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
|
|
|
4
4
|
|
|
5
5
|
[project]
|
|
6
6
|
name = "hyxi-cloud-api"
|
|
7
|
-
version = "1.3.
|
|
7
|
+
version = "1.3.4"
|
|
8
8
|
authors = [
|
|
9
9
|
{ name="Veldkornet", email="Veldkornet@users.noreply.github.com" },
|
|
10
10
|
]
|
|
@@ -12,7 +12,7 @@ description = "An async API client for HYXi Cloud."
|
|
|
12
12
|
readme = "README.md"
|
|
13
13
|
requires-python = ">=3.14"
|
|
14
14
|
dependencies = [
|
|
15
|
-
"aiohttp>=3.
|
|
15
|
+
"aiohttp>=3.14.0",
|
|
16
16
|
]
|
|
17
17
|
classifiers = [
|
|
18
18
|
"Programming Language :: Python :: 3",
|
|
@@ -5,5 +5,5 @@ from .api import HyxiApiClient
|
|
|
5
5
|
# Module-level alias so callers can do: from hyxi_cloud_api import VPP_ACTIVE_MODES
|
|
6
6
|
VPP_ACTIVE_MODES: frozenset[str] = HyxiApiClient.VPP_ACTIVE_MODES
|
|
7
7
|
|
|
8
|
-
__version__ = "1.3.
|
|
8
|
+
__version__ = "1.3.4"
|
|
9
9
|
__all__ = ["VPP_ACTIVE_MODES", "HyxiApiClient"]
|
|
@@ -924,7 +924,7 @@ class HyxiApiClient: # pylint: disable=too-many-instance-attributes
|
|
|
924
924
|
# Confirmed values (live observation + HYXI community research):
|
|
925
925
|
# "13" = VPP Charge (remote grid charge active)
|
|
926
926
|
# "14" = VPP Discharge (remote grid discharge active)
|
|
927
|
-
# "16" = VPP
|
|
927
|
+
# "16" = VPP Enrolled / Standby (device registered, NOT under active dispatch)
|
|
928
928
|
#
|
|
929
929
|
# Standard non-VPP modes for reference (NOT included here):
|
|
930
930
|
# "0" = Self-use / general
|
|
@@ -935,7 +935,9 @@ class HyxiApiClient: # pylint: disable=too-many-instance-attributes
|
|
|
935
935
|
# workMode is returned as a string or integer from the API, cast to string for matching.
|
|
936
936
|
# Source: live workMode value observed during active VPP dispatch,
|
|
937
937
|
# corroborated by HYXI community register documentation.
|
|
938
|
-
VPP_ACTIVE_MODES: frozenset[str] = frozenset(
|
|
938
|
+
VPP_ACTIVE_MODES: frozenset[str] = frozenset(
|
|
939
|
+
{"13", "14"}
|
|
940
|
+
) # "16" = standby only, not active dispatch
|
|
939
941
|
|
|
940
942
|
class ControlError(Exception):
|
|
941
943
|
"""Raised when a device control command fails."""
|
|
@@ -1269,17 +1271,6 @@ class HyxiApiClient: # pylint: disable=too-many-instance-attributes
|
|
|
1269
1271
|
"HYXI EMS telemetry probe returned no data for %s", _mask_id(sn)
|
|
1270
1272
|
)
|
|
1271
1273
|
|
|
1272
|
-
if not is_comm_unit:
|
|
1273
|
-
# Always write VPP keys so HA sensor attributes are never missing.
|
|
1274
|
-
# Pivot: VPP active detection is now driven by workMode.
|
|
1275
|
-
# If workMode is "16" (VPP active), set vppMode to "16" to trigger HA lockout.
|
|
1276
|
-
work_mode = entry["metrics"].get("workMode", "")
|
|
1277
|
-
entry["metrics"]["vppMode"] = work_mode
|
|
1278
|
-
entry["metrics"]["vppCode"] = ""
|
|
1279
|
-
entry["metrics"]["vppName"] = ""
|
|
1280
|
-
entry["metrics"]["vppManufacturer"] = ""
|
|
1281
|
-
entry["metrics"]["vppSupplierName"] = ""
|
|
1282
|
-
|
|
1283
1274
|
return sn, entry
|
|
1284
1275
|
|
|
1285
1276
|
async def _fetch_device_list_for_plant(self, plant_id: str) -> list[dict] | None:
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: hyxi-cloud-api
|
|
3
|
-
Version: 1.3.
|
|
3
|
+
Version: 1.3.4
|
|
4
4
|
Summary: An async API client for HYXi Cloud.
|
|
5
5
|
Author-email: Veldkornet <Veldkornet@users.noreply.github.com>
|
|
6
6
|
Classifier: Programming Language :: Python :: 3
|
|
@@ -14,7 +14,7 @@ Classifier: Topic :: Home Automation
|
|
|
14
14
|
Requires-Python: >=3.14
|
|
15
15
|
Description-Content-Type: text/markdown
|
|
16
16
|
License-File: LICENSE
|
|
17
|
-
Requires-Dist: aiohttp>=3.
|
|
17
|
+
Requires-Dist: aiohttp>=3.14.0
|
|
18
18
|
Provides-Extra: test
|
|
19
19
|
Requires-Dist: pytest>=9.0.3; extra == "test"
|
|
20
20
|
Requires-Dist: pytest-asyncio; extra == "test"
|
|
@@ -139,7 +139,7 @@ async def test_fetch_ems_basic_data_no_data(caplog):
|
|
|
139
139
|
await api._fetch_all_for_device("10602251600016", entry, "INVERTER")
|
|
140
140
|
|
|
141
141
|
assert "HYXI EMS telemetry probe returned no data for fefbfd75" in caplog.text
|
|
142
|
-
#
|
|
142
|
+
# No EMS data should be merged into metrics.
|
|
143
143
|
assert "new_metric" not in entry["metrics"]
|
|
144
144
|
|
|
145
145
|
|
|
@@ -158,7 +158,7 @@ async def test_fetch_ems_basic_data_error(caplog):
|
|
|
158
158
|
entry = {"metrics": {}, "device_type_code": "EMS"}
|
|
159
159
|
await api._fetch_all_for_device("10602251600016", entry, "INVERTER")
|
|
160
160
|
|
|
161
|
-
# No EMS data should be
|
|
161
|
+
# No EMS data should be merged into metrics.
|
|
162
162
|
assert "batSoc" not in entry["metrics"]
|
|
163
163
|
assert "HYXI EMS telemetry probe returned no data for fefbfd75" in caplog.text
|
|
164
164
|
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{hyxi_cloud_api-1.3.2 → hyxi_cloud_api-1.3.4}/src/hyxi_cloud_api.egg-info/dependency_links.txt
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
|
|
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
|
|
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
|
|
File without changes
|
|
File without changes
|
{hyxi_cloud_api-1.3.2 → hyxi_cloud_api-1.3.4}/tests/test_process_alarms_and_back_discovery.py
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
|
{hyxi_cloud_api-1.3.2 → hyxi_cloud_api-1.3.4}/tests/test_validate_subscription_device_sns.py
RENAMED
|
File without changes
|