Skip to content
This repository has been archived by the owner on Jul 14, 2023. It is now read-only.

iotc.connect failed after internet reboot #114

Open
5MarsR opened this issue Apr 4, 2020 · 0 comments
Open

iotc.connect failed after internet reboot #114

5MarsR opened this issue Apr 4, 2020 · 0 comments

Comments

@5MarsR
Copy link

5MarsR commented Apr 4, 2020

hi,
so we had a power outage and i had a rapsberry pi 3 with the iotc librairy, in case of a power failure code will just restart after power is back on. when i used the librairie version 3.3 we never had any problem, but when I upgraded to version 3.5, after the reboot it seems the internet router was taking some time to restart, the previous version would still work if the power went router closed but with this new version I got this error and i am not sure if the problem was just the lack of internet that raised this error cause our whole system kept on rebooting and failing again.

Apr 3 14:41:00 km0 python3[973]: iotc.connect()
Apr 3 14:41:00 km0 python3[973]: File "/home/pi/.local/lib/python3.5/site-packages/iotc/init.py", line 652, in connect
Apr 3 14:41:00 km0 python3[973]: content = _request(self, target.geturl(), "PUT", body, headers)
Apr 3 14:41:00 km0 python3[973]: File "/home/pi/.local/lib/python3.5/site-packages/iotc/init.py", line 278, in _request
Apr 3 14:41:00 km0 python3[973]: return _doRequest(device, target_url, method, body, headers)
Apr 3 14:41:00 km0 python3[973]: File "/home/pi/.local/lib/python3.5/site-packages/iotc/init.py", line 270, in _doRequest
Apr 3 14:41:00 km0 python3[973]: conn.request(method, target_url, body, req_headers)
Apr 3 14:41:00 km0 python3[973]: File "/usr/lib/python3.5/http/client.py", line 1107, in request
Apr 3 14:41:00 km0 python3[973]: self._send_request(method, url, body, headers)
Apr 3 14:41:00 km0 python3[973]: File "/usr/lib/python3.5/http/client.py", line 1152, in _send_request
Apr 3 14:41:00 km0 python3[973]: self.endheaders(body)
Apr 3 14:41:00 km0 python3[973]: File "/usr/lib/python3.5/http/client.py", line 1103, in endheaders
Apr 3 14:41:00 km0 python3[973]: self._send_output(message_body)
Apr 3 14:41:00 km0 python3[973]: File "/usr/lib/python3.5/http/client.py", line 934, in _send_output
Apr 3 14:41:00 km0 python3[973]: self.send(msg)
Apr 3 14:41:00 km0 python3[973]: File "/usr/lib/python3.5/http/client.py", line 877, in send
Apr 3 14:41:00 km0 python3[973]: self.connect()
Apr 3 14:41:00 km0 python3[973]: File "/usr/lib/python3.5/http/client.py", line 1253, in connect
Apr 3 14:41:00 km0 python3[973]: super().connect()
Apr 3 14:41:00 km0 python3[973]: File "/usr/lib/python3.5/http/client.py", line 849, in connect
Apr 3 14:41:00 km0 python3[973]: (self.host,self.port), self.timeout, self.source_address)
Apr 3 14:41:00 km0 python3[973]: File "/usr/lib/python3.5/socket.py", line 694, in create_connection
Apr 3 14:41:00 km0 python3[973]: for res in getaddrinfo(host, port, 0, SOCK_STREAM):
Apr 3 14:41:00 km0 python3[973]: File "/usr/lib/python3.5/socket.py", line 733, in getaddrinfo
Apr 3 14:41:00 km0 python3[973]: for res in _socket.getaddrinfo(host, port, family, type, proto, flags):
Apr 3 14:41:00 km0 python3[973]: socket.gaierror: [Errno -3] Temporary failure in name resolution

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant