Post by karambit on Apr 22, 2021 8:15:37 GMT -8
My station stopped uploading data to Weather Underground. They've been having issues the past few days and looks like something happened last night that made the station stop uploading data. I think there needs to be some error handling in pclogging.py maybe to handle this issue and allow writeWeatherRecord to continue to run.
After that this log message appears every time it tries to run writeWeatherRecord
Apr 22 08:58:42 weatherstationpi rc.local[434]: Execution of job "writeWeatherRecord (trigger: interval[0:05:00], next run at: 2021-04-22 08:58:42 EDT)" skipped: maximum number of running instances reached (1)
I had to restart everything to get it going again.
Apr 22 04:21:01 weatherstationpi sm-msp-queue[14377]: unable to qualify my own domain name (weatherstationpi) -- using short name
Apr 22 04:33:42 weatherstationpi rc.local[434]: File "/usr/lib/python3/dist-packages/OpenSSL/SSL.py", line 1915, in do_handshake
Apr 22 04:33:42 weatherstationpi rc.local[434]: self._raise_ssl_error(self._ssl, result)
Apr 22 04:33:42 weatherstationpi rc.local[434]: File "/usr/lib/python3/dist-packages/OpenSSL/SSL.py", line 1639, in _raise_ssl_error
Apr 22 04:33:42 weatherstationpi rc.local[434]: raise SysCallError(errno, errorcode.get(errno))
Apr 22 04:33:42 weatherstationpi rc.local[434]: OpenSSL.SSL.SysCallError: (104, 'ECONNRESET')
Apr 22 04:33:42 weatherstationpi rc.local[434]: During handling of the above exception, another exception occurred:
Apr 22 04:33:42 weatherstationpi rc.local[434]: Traceback (most recent call last):
Apr 22 04:33:42 weatherstationpi rc.local[434]: File "/usr/lib/python3/dist-packages/urllib3/connectionpool.py", line 600, in urlopen
Apr 22 04:33:42 weatherstationpi rc.local[434]: chunked=chunked)
Apr 22 04:33:42 weatherstationpi rc.local[434]: File "/usr/lib/python3/dist-packages/urllib3/connectionpool.py", line 343, in _make_request
Apr 22 04:33:42 weatherstationpi rc.local[434]: self._validate_conn(conn)
Apr 22 04:33:42 weatherstationpi rc.local[434]: File "/usr/lib/python3/dist-packages/urllib3/connectionpool.py", line 841, in _validate_conn
Apr 22 04:33:42 weatherstationpi rc.local[434]: conn.connect()
Apr 22 04:33:42 weatherstationpi rc.local[434]: File "/usr/lib/python3/dist-packages/urllib3/connection.py", line 344, in connect
Apr 22 04:33:43 weatherstationpi rc.local[434]: ssl_context=context)
Apr 22 04:33:43 weatherstationpi rc.local[434]: File "/usr/lib/python3/dist-packages/urllib3/util/ssl_.py", line 344, in ssl_wrap_socket
Apr 22 04:33:43 weatherstationpi rc.local[434]: return context.wrap_socket(sock, server_hostname=server_hostname)
Apr 22 04:33:43 weatherstationpi rc.local[434]: File "/usr/lib/python3/dist-packages/urllib3/contrib/pyopenssl.py", line 459, in wrap_socket
Apr 22 04:33:43 weatherstationpi rc.local[434]: raise ssl.SSLError('bad handshake: %r' % e)
Apr 22 04:33:43 weatherstationpi rc.local[434]: ssl.SSLError: ("bad handshake: SysCallError(104, 'ECONNRESET')",)
Apr 22 04:33:43 weatherstationpi rc.local[434]: During handling of the above exception, another exception occurred:
Apr 22 04:33:43 weatherstationpi rc.local[434]: Traceback (most recent call last):
Apr 22 04:33:43 weatherstationpi rc.local[434]: File "/usr/lib/python3/dist-packages/requests/adapters.py", line 449, in send
Apr 22 04:33:43 weatherstationpi rc.local[434]: timeout=timeout
Apr 22 04:33:43 weatherstationpi rc.local[434]: File "/usr/lib/python3/dist-packages/urllib3/connectionpool.py", line 638, in urlopen
Apr 22 04:33:43 weatherstationpi rc.local[434]: _stacktrace=sys.exc_info()[2])
Apr 22 04:33:43 weatherstationpi rc.local[434]: File "/usr/lib/python3/dist-packages/urllib3/util/retry.py", line 398, in increment
Apr 22 04:33:43 weatherstationpi rc.local[434]: raise MaxRetryError(_pool, url, error or ResponseError(cause))
Apr 22 04:33:43 weatherstationpi rc.local[434]: urllib3.exceptions.MaxRetryError: HTTPSConnectionPool(host='rtupdate.wunderground.com', port=443): Max retries exceeded with url: /weatherstation/updateweatherstation.php?ID=XXXXXXX&PASSWORD=XXXXXXX&dateutc=now&winddir=352&windspeedmph=4.91&windgustmph=5.81&humidity=67&tempf=33.21&dewptf=21.33&rainin=0.00&dailyrainin=0.22&baromin=29.84&indoortempf=35.91&indoorhumidity59.00=&solarradiation=15.79&UV=0.50&software=SkyWeather2 (Caused by SSLError(SSLError("bad handshake: SysCallError(104, 'ECONNRESET')")))
Apr 22 04:33:43 weatherstationpi rc.local[434]: During handling of the above exception, another exception occurred:
Apr 22 04:33:43 weatherstationpi rc.local[434]: Traceback (most recent call last):
Apr 22 04:33:43 weatherstationpi rc.local[434]: File "/home/pi/SkyWeather/SDL_Pi_SkyWeather2/WeatherUnderground.py", line 57, in sendWeatherUndergroundData
Apr 22 04:33:43 weatherstationpi rc.local[434]: r = requests.get("https://rtupdate.wunderground.com/weatherstation/updateweatherstation.php", params=myURL)
Apr 22 04:33:43 weatherstationpi rc.local[434]: File "/usr/lib/python3/dist-packages/requests/api.py", line 75, in get
Apr 22 04:33:43 weatherstationpi rc.local[434]: return request('get', url, params=params, **kwargs)
Apr 22 04:33:43 weatherstationpi rc.local[434]: File "/usr/lib/python3/dist-packages/requests/api.py", line 60, in request
Apr 22 04:33:43 weatherstationpi rc.local[434]: return session.request(method=method, url=url, **kwargs)
Apr 22 04:33:43 weatherstationpi rc.local[434]: File "/usr/lib/python3/dist-packages/requests/sessions.py", line 533, in request
Apr 22 04:33:43 weatherstationpi rc.local[434]: resp = self.send(prep, **send_kwargs)
Apr 22 04:33:43 weatherstationpi rc.local[434]: File "/usr/lib/python3/dist-packages/requests/sessions.py", line 646, in send
Apr 22 04:33:43 weatherstationpi rc.local[434]: r = adapter.send(request, **kwargs)
Apr 22 04:33:43 weatherstationpi rc.local[434]: File "/usr/lib/python3/dist-packages/requests/adapters.py", line 514, in send
Apr 22 04:33:43 weatherstationpi rc.local[434]: raise SSLError(e, request=request)
Apr 22 04:33:43 weatherstationpi rc.local[434]: requests.exceptions.SSLError: HTTPSConnectionPool(host='rtupdate.wunderground.com', port=443): Max retries exceeded with url: /weatherstation/updateweatherstation.php?ID=XXXXXXXXX&PASSWORD=XXXXXX&dateutc=now&winddir=352&windspeedmph=4.91&windgustmph=5.81&humidity=67&tempf=33.21&dewptf=21.33&rainin=0.00&dailyrainin=0.22&baromin=29.84&indoortempf=35.91&indoorhumidity59.00=&solarradiation=15.79&UV=0.50&software=SkyWeather2 (Caused by SSLError(SSLError("bad handshake: SysCallError(104, 'ECONNRESET')")))
Apr 22 04:33:43 weatherstationpi rc.local[434]: Execution of job "writeWeatherRecord (trigger: interval[0:05:00], next run at: 2021-04-22 04:33:42 EDT)" skipped: maximum number of running instances reached (1)
Apr 22 04:38:42 weatherstationpi rc.local[434]: Execution of job "writeWeatherRecord (trigger: interval[0:05:00], next run at: 2021-04-22 04:38:42 EDT)" skipped: maximum number of running instances reached (1)
After that this log message appears every time it tries to run writeWeatherRecord
Apr 22 08:58:42 weatherstationpi rc.local[434]: Execution of job "writeWeatherRecord (trigger: interval[0:05:00], next run at: 2021-04-22 08:58:42 EDT)" skipped: maximum number of running instances reached (1)
I had to restart everything to get it going again.