Error Exception on Fail to connect to Internet
the tzupdate binary when used with Internet works really well, and hat off to all the developers. But, there is still one nasty problems. Whenever there is no Internet connection for the socket to open to such as error resolving DNS, or no connected iinterface, it thrown out a nasty python script error, and it continued on to try to reconnect at lightening speed. Maybe developers team can put a lid to the loop like 3 loops, if still error, just print out an one line error telling us users that no Internet or more specific issues.
It continued on to try to reconnect at lightening speed.
Huh? We don't try to reconnect at all, see here: https://github.com/cdown/tzupdate/blob/develop/tzupdate.py#L84
Why do you think we try to reconnect?
I would like to make a apologies that I got impatient and not wait for the script to finish 30 seconds later, which I assumed that It would run indefinitely; hence the statement above. When run without Internet, It immediately give out a long list of python errors from 2 files, process.py and request.py . It then got quiet for a 30 seconds before it printed the final long errors saying tzupdate.TimezoneAcquisitionError: No usable response from any API in 30.0 seconds. Consider increasing --timeout if your connection is slow., and it terminated. In the log file below, I have put a row of hash in the place where it waited quietly. I was hoping that you would eliminate the long python error, and make it short and precise, or print the long one to somewhere else like a log file in /var/log/tzupdate or something you could find. Thanks.
The full traceback can be useful to find the cause of issues, so I'm not going to remove it. It's also not going to go to /var/log: if the user wants that they can redirect stdout.
I'd be happy to review a patch which uses sentinel values to proactively determine when all available APIs have been exhausted, though. Feel free to send a pull request.
No PR for 1.5 years, closing.