aioamazondevices 6.5.1__tar.gz → 6.5.2__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.
- {aioamazondevices-6.5.1 → aioamazondevices-6.5.2}/PKG-INFO +1 -1
- {aioamazondevices-6.5.1 → aioamazondevices-6.5.2}/pyproject.toml +1 -1
- {aioamazondevices-6.5.1 → aioamazondevices-6.5.2}/src/aioamazondevices/__init__.py +1 -1
- {aioamazondevices-6.5.1 → aioamazondevices-6.5.2}/src/aioamazondevices/api.py +25 -11
- {aioamazondevices-6.5.1 → aioamazondevices-6.5.2}/LICENSE +0 -0
- {aioamazondevices-6.5.1 → aioamazondevices-6.5.2}/README.md +0 -0
- {aioamazondevices-6.5.1 → aioamazondevices-6.5.2}/src/aioamazondevices/const.py +0 -0
- {aioamazondevices-6.5.1 → aioamazondevices-6.5.2}/src/aioamazondevices/exceptions.py +0 -0
- {aioamazondevices-6.5.1 → aioamazondevices-6.5.2}/src/aioamazondevices/py.typed +0 -0
- {aioamazondevices-6.5.1 → aioamazondevices-6.5.2}/src/aioamazondevices/query.py +0 -0
- {aioamazondevices-6.5.1 → aioamazondevices-6.5.2}/src/aioamazondevices/sounds.py +0 -0
- {aioamazondevices-6.5.1 → aioamazondevices-6.5.2}/src/aioamazondevices/utils.py +0 -0
|
@@ -62,6 +62,7 @@ from .const import (
|
|
|
62
62
|
REQUEST_AGENT,
|
|
63
63
|
SAVE_PATH,
|
|
64
64
|
SENSORS,
|
|
65
|
+
SPEAKER_GROUP_FAMILY,
|
|
65
66
|
URI_DEVICES,
|
|
66
67
|
URI_DND,
|
|
67
68
|
URI_NEXUS_GRAPHQL,
|
|
@@ -712,14 +713,16 @@ class AmazonEchoApi:
|
|
|
712
713
|
_LOGGER.debug(
|
|
713
714
|
"error in sensor %s - %s - %s", name, error_type, error_msg
|
|
714
715
|
)
|
|
715
|
-
|
|
716
|
-
|
|
717
|
-
|
|
718
|
-
|
|
719
|
-
|
|
720
|
-
|
|
721
|
-
|
|
722
|
-
|
|
716
|
+
|
|
717
|
+
if error_type != "NOT_FOUND":
|
|
718
|
+
device_sensors[name] = AmazonDeviceSensor(
|
|
719
|
+
name,
|
|
720
|
+
value,
|
|
721
|
+
error,
|
|
722
|
+
error_type,
|
|
723
|
+
error_msg,
|
|
724
|
+
scale,
|
|
725
|
+
)
|
|
723
726
|
|
|
724
727
|
return device_sensors
|
|
725
728
|
|
|
@@ -1139,7 +1142,9 @@ class AmazonEchoApi:
|
|
|
1139
1142
|
else:
|
|
1140
1143
|
for device_sensor in device.sensors.values():
|
|
1141
1144
|
device_sensor.error = True
|
|
1142
|
-
if
|
|
1145
|
+
if (
|
|
1146
|
+
device_dnd := dnd_sensors.get(device.serial_number)
|
|
1147
|
+
) and device.device_family != SPEAKER_GROUP_FAMILY:
|
|
1143
1148
|
device.sensors["dnd"] = device_dnd
|
|
1144
1149
|
|
|
1145
1150
|
# Update notifications
|
|
@@ -1208,11 +1213,20 @@ class AmazonEchoApi:
|
|
|
1208
1213
|
if not device or (device.get("deviceType") in DEVICE_TO_IGNORE):
|
|
1209
1214
|
continue
|
|
1210
1215
|
|
|
1216
|
+
account_name: str = device["accountName"]
|
|
1217
|
+
capabilities: list[str] = device["capabilities"]
|
|
1218
|
+
# Skip devices that cannot be used with voice features
|
|
1219
|
+
if "MICROPHONE" not in capabilities:
|
|
1220
|
+
_LOGGER.debug(
|
|
1221
|
+
"Skipping device without microphone capabilities: %s", account_name
|
|
1222
|
+
)
|
|
1223
|
+
continue
|
|
1224
|
+
|
|
1211
1225
|
serial_number: str = device["serialNumber"]
|
|
1212
1226
|
|
|
1213
1227
|
final_devices_list[serial_number] = AmazonDevice(
|
|
1214
|
-
account_name=
|
|
1215
|
-
capabilities=
|
|
1228
|
+
account_name=account_name,
|
|
1229
|
+
capabilities=capabilities,
|
|
1216
1230
|
device_family=device["deviceFamily"],
|
|
1217
1231
|
device_type=device["deviceType"],
|
|
1218
1232
|
device_owner_customer_id=device["deviceOwnerCustomerId"],
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|