Open ccshc opened 3 years ago
Actually, there's backoff logic:
time.sleep(tries / 10) # Back off 10, 20, ... depending on tries
tries += 1
logging.warning('Retrying again, attempt #%d', tries)
But I could have messed up and the division isn't turning into fractions, just zero which would explain what you're seeing :) Good catch
I think that is just returning 0 delay! Maybe change it to time.sleep(tries * 10)
?
Yes, I think I confused it with minutes which is why it's a division. Should have been multiplied since it's seconds.
Changes for the backoff timer as well as the use of a faulty variable name have been fixed on latest. Please let me know how it works @ccshc
I've been meaning to look back at this again. I still have seen this error with the revised code. If I read it correctly, the slideshow will stop if the Internet connection is down for ~2.5 min. That has happened to me several times, and the photoframe does not recover after the Internet comes back. I'd rather have it back off a bit more and then continue to test for connectivity periodically. Maybe every 5 min?
I actually found the issue the other night, just need to test some more.
Hi,
I think my network connection is dropping occasionally, which seems to cause the PhotoFrame to just keep showing the same picture.
The summary is ConnectionError: HTTPSConnectionPool fails 5 times, which eventually triggers an error when it trys to display a photo which it hasn't got.
I can solve this by rebooting.
A possible solution would be that if the network fails to connect, have a longer delay (eg a minute) between retries rather than instantaneously trying again.
The full log is below: