From 5fded72481753c377c01468dbea8d54beab216ae Mon Sep 17 00:00:00 2001 From: Marcelo Moreira de Mello Date: Fri, 28 Dec 2018 14:07:02 -0500 Subject: [PATCH 1/2] Currently we don't support Arlo DoorBells and this code is a temporary workaround to get the media library loaded when a doorbell is present. --- pyarlo/media.py | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/pyarlo/media.py b/pyarlo/media.py index 8c8fad0..724cc57 100644 --- a/pyarlo/media.py +++ b/pyarlo/media.py @@ -62,11 +62,14 @@ def load(self, days=PRELOAD_DAYS, only_cameras=None, for video in data: # pylint: disable=cell-var-from-loop - srccam = \ - list(filter( - lambda cam: cam.device_id == video.get('deviceId'), - all_cameras) - )[0] + try: + srccam = \ + list(filter( + lambda cam: cam.device_id == video.get('deviceId'), + all_cameras) + )[0] + except IndexError: + continue # make sure only_cameras is a list if only_cameras and \ From 460a0e32e9935ef8edd80252a9fb1cb25210e63f Mon Sep 17 00:00:00 2001 From: Marcelo Moreira de Mello Date: Fri, 28 Dec 2018 14:13:46 -0500 Subject: [PATCH 2/2] Added Python 3.7 to Travis --- .travis.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.travis.yml b/.travis.yml index eef022a..3723ce0 100644 --- a/.travis.yml +++ b/.travis.yml @@ -11,6 +11,8 @@ matrix: env: TOXENV=py35 - python: "3.6" env: TOXENV=py36 + - python: "3.7" + env: TOXENV=py37 - python: "3.4.2" env: TOXENV=lint install: pip install -U tox coveralls