The Unifi controller code was not properly handling the auth failure that occurs ~2 hrs after prior authentication. Since the code already had some level of retries built in, it just needed to be properly triggered. To address that:
Direct all responses to raise an exception on all status codes
Ensure the retry logic catches the HTTPError exception and triggers the retry/re-auth
I've also removed the python-pushover from the requirements.txt since it's not used AND fixed a comparison operation.
My eisy has been running with these changes in my dev environment for over a week now with no issues.
The Unifi controller code was not properly handling the auth failure that occurs ~2 hrs after prior authentication. Since the code already had some level of retries built in, it just needed to be properly triggered. To address that:
I've also removed the python-pushover from the requirements.txt since it's not used AND fixed a comparison operation.
My eisy has been running with these changes in my dev environment for over a week now with no issues.