Skip to content

Commit 6a4b13b

Browse files
authored
Merge pull request #19 from StephanU/bugfix/20251110_streampath_access
Fixed stream access.
2 parents 527cc0b + 8d4a677 commit 6a4b13b

3 files changed

Lines changed: 5 additions & 3 deletions

File tree

PyMyGekko/resources/Cams.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -82,8 +82,8 @@ def update_resources(self, resources):
8282
if key not in self._data:
8383
self._data[key] = {}
8484
self._data[key]["name"] = cams[key]["name"]
85-
self._data[key]["imagepath"] = cams[key]["imagepath"]
86-
self._data[key]["streampath"] = cams[key]["streampath"]
85+
self._data[key]["imagepath"] = cams[key].get("imagepath", None)
86+
self._data[key]["streampath"] = cams[key].get("streampath", None)
8787

8888
@property
8989
def cams(self):

PyMyGekko/resources/DoorInterComs.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,7 @@ class DoorInterComConnectionState(IntEnum):
9696
ERROR_FAV_CHECK = -3
9797
ERROR_PROVISIONING = -2
9898
ERROR_CONNECTION = -1
99-
NOT_SET_UP = (0,)
99+
NOT_SET_UP = 0
100100
OK = 1
101101

102102

tests/door_inter_coms/test_pymygekko_door_inter_coms_879015.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
from aiohttp import web
66
from PyMyGekko import MyGekkoApiClientBase
77
from PyMyGekko.resources.DoorInterComs import DoorInterComConnectionState
8+
from PyMyGekko.resources.DoorInterComs import DoorInterComSoundMode
89

910
_LOGGER: logging.Logger = logging.getLogger(__name__)
1011

@@ -63,3 +64,4 @@ async def test_get_door_inter_coms(mock_server):
6364
assert door_inter_coms[0].connection_state == DoorInterComConnectionState.OK
6465
assert door_inter_coms[0].last_missed_call_date is None
6566
assert door_inter_coms[0].missed_calls == 0
67+
assert door_inter_coms[0].sound_mode == DoorInterComSoundMode.RINGING

0 commit comments

Comments
 (0)