ep1cman / unifi-protect-backup

Python tool to backup unifi event clips in realtime
MIT License
576 stars 25 forks source link

start_time = events_chunk[-1].end IndexError: list index out of range #109

Closed ep1cman closed 8 months ago

ep1cman commented 8 months ago

I have the log open and it seems to be working, moving downloading the mp4.

Occassionaly I get the following error:

2023-10-31 06:01:45 [ DEBUG ] unifi_protect_backup.missing_event_checker : Running check for missing events... 2023-10-31 06:01:45 [ ERROR ] unifi_protect_backup.missing_event_checker : Unexpected exception occurred during missing event check: Traceback (most recent call last): File "/usr/lib/python3.10/site-packages/unifi_protect_backup/missing_event_checker.py", line 150, in start async for event in self._get_missing_events(): File "/usr/lib/python3.10/site-packages/unifi_protect_backup/missing_event_checker.py", line 72, in _get_missing_events start_time = events_chunk[-1].end IndexError: list index out of range

Originally posted by @maxnata in https://github.com/ep1cman/unifi-protect-backup/discussions/108

ep1cman commented 8 months ago

Fixed