Homevolt 0.4.2__tar.gz → 0.4.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.
- {homevolt-0.4.2 → homevolt-0.4.4}/Homevolt.egg-info/PKG-INFO +1 -1
- {homevolt-0.4.2 → homevolt-0.4.4}/PKG-INFO +1 -1
- {homevolt-0.4.2 → homevolt-0.4.4}/homevolt/homevolt.py +12 -4
- {homevolt-0.4.2 → homevolt-0.4.4}/pyproject.toml +1 -1
- {homevolt-0.4.2 → homevolt-0.4.4}/Homevolt.egg-info/SOURCES.txt +0 -0
- {homevolt-0.4.2 → homevolt-0.4.4}/Homevolt.egg-info/dependency_links.txt +0 -0
- {homevolt-0.4.2 → homevolt-0.4.4}/Homevolt.egg-info/requires.txt +0 -0
- {homevolt-0.4.2 → homevolt-0.4.4}/Homevolt.egg-info/top_level.txt +0 -0
- {homevolt-0.4.2 → homevolt-0.4.4}/LICENSE +0 -0
- {homevolt-0.4.2 → homevolt-0.4.4}/README.md +0 -0
- {homevolt-0.4.2 → homevolt-0.4.4}/homevolt/__init__.py +0 -0
- {homevolt-0.4.2 → homevolt-0.4.4}/homevolt/const.py +0 -0
- {homevolt-0.4.2 → homevolt-0.4.4}/homevolt/exceptions.py +0 -0
- {homevolt-0.4.2 → homevolt-0.4.4}/homevolt/models.py +0 -0
- {homevolt-0.4.2 → homevolt-0.4.4}/setup.cfg +0 -0
|
@@ -89,6 +89,10 @@ class Homevolt:
|
|
|
89
89
|
raise HomevoltAuthenticationError("Authentication failed")
|
|
90
90
|
response.raise_for_status()
|
|
91
91
|
ems_data = await response.json()
|
|
92
|
+
except HomevoltAuthenticationError:
|
|
93
|
+
raise
|
|
94
|
+
except HomevoltConnectionError:
|
|
95
|
+
raise
|
|
92
96
|
except aiohttp.ClientError as err:
|
|
93
97
|
raise HomevoltConnectionError(f"Failed to connect to device: {err}") from err
|
|
94
98
|
except Exception as err:
|
|
@@ -107,6 +111,10 @@ class Homevolt:
|
|
|
107
111
|
raise HomevoltAuthenticationError("Authentication failed")
|
|
108
112
|
response.raise_for_status()
|
|
109
113
|
schedule_data = await response.json()
|
|
114
|
+
except HomevoltAuthenticationError:
|
|
115
|
+
raise
|
|
116
|
+
except HomevoltConnectionError:
|
|
117
|
+
raise
|
|
110
118
|
except aiohttp.ClientError as err:
|
|
111
119
|
raise HomevoltConnectionError(f"Failed to connect to device: {err}") from err
|
|
112
120
|
except Exception as err:
|
|
@@ -183,14 +191,14 @@ class Homevolt:
|
|
|
183
191
|
type="system_temperature",
|
|
184
192
|
device_identifier=ems_device_id,
|
|
185
193
|
),
|
|
186
|
-
"
|
|
194
|
+
"Energy imported": Sensor(
|
|
187
195
|
value=ems["ems_aggregate"]["imported_kwh"],
|
|
188
|
-
type="
|
|
196
|
+
type="energy_imported",
|
|
189
197
|
device_identifier=ems_device_id,
|
|
190
198
|
),
|
|
191
|
-
"
|
|
199
|
+
"Energy exported": Sensor(
|
|
192
200
|
value=ems["ems_aggregate"]["exported_kwh"],
|
|
193
|
-
type="
|
|
201
|
+
type="energy_exported",
|
|
194
202
|
device_identifier=ems_device_id,
|
|
195
203
|
),
|
|
196
204
|
"Available Charging Power": Sensor(
|
|
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
|