Salut Gerald,
J’ai suivi votre tuto et appliqué à la lettre, sauf que je recontre un bug aléatoire il se produit une quinzaine de fois par jour. La tram ne remonte pas ! et j’ai le message suivant dans logs script : (auriez-vous une idée ??)
------------------------------------
Erreur exécution de la commande [Aucun][Empuria.sc][EmpuriaScr] : Erreur sur /var/www/html/plugins/script/data/PyEmVue/PyEmVue.PY 2>&1 valeur retournée : 1. Détails : Traceback (most recent call last): File "/usr/local/lib/python3.7/dist-packages/urllib3/connection.py", line 175, in _new_conn (self._dns_host, self.port), self.timeout, **extra_kw File "/usr/local/lib/python3.7/dist-packages/urllib3/util/connection.py", line 72, in create_connection for res in socket.getaddrinfo(host, port, family, socket.SOCK_STREAM): File "/usr/lib/python3.7/socket.py", line 748, in getaddrinfo for res in _socket.getaddrinfo(host, port, family, type, proto, flags): socket.gaierror: [Errno -3] Temporary failure in name resolution During handling of the above exception, another exception occurred: Traceback (most recent call last): File "/usr/local/lib/python3.7/dist-packages/urllib3/connectionpool.py", line 710, in urlopen chunked=chunked, File "/usr/local/lib/python3.7/dist-packages/urllib3/connectionpool.py", line 386, in _make_request self._validate_conn(conn) File "/usr/local/lib/python3.7/dist-packages/urllib3/connectionpool.py", line 1042, in _validate_conn conn.connect() File "/usr/local/lib/python3.7/dist-packages/urllib3/connection.py", line 358, in connect self.sock = conn = self._new_conn() File "/usr/local/lib/python3.7/dist-packages/urllib3/connection.py", line 187, in _new_conn self, "Failed to establish a new connection: %s" % e urllib3.exceptions.NewConnectionError: : Failed to establish a new connection: [Errno -3] Temporary failure in name resolution During handling of the above exception, another exception occurred: Traceback (most recent call last): File "/usr/local/lib/python3.7/dist-packages/requests/adapters.py", line 499, in send timeout=timeout, File "/usr/local/lib/python3.7/dist-packages/urllib3/connectionpool.py", line 788, in urlopen method, url, error=e, _pool=self, _stacktrace=sys.exc_info()[2] File "/usr/local/lib/python3.7/dist-packages/urllib3/util/retry.py", line 592, in increment raise MaxRetryError(_pool, url, error or ResponseError(cause)) urllib3.exceptions.MaxRetryError: HTTPSConnectionPool(host='api.emporiaenergy.com', port=443): Max retries exceeded with url: /customers/devices (Caused by NewConnectionError(': Failed to establish a new connection: [Errno -3] Temporary failure in name resolution')) During handling of the above exception, another exception occurred: Traceback (most recent call last): File "/var/www/html/plugins/script/data/PyEmVue/PyEmVue.PY", line 36, in devices = vue.get_devices() File "/usr/local/lib/python3.7/dist-packages/pyemvue/pyemvue.py", line 48, in get_devices response = self.auth.request('get', API_CUSTOMER_DEVICES) File "/usr/local/lib/python3.7/dist-packages/pyemvue/auth.py", line 84, in request method, f"{self.host}/{path}", **kwargs, headers=headers, File "/usr/local/lib/python3.7/dist-packages/requests/api.py", line 59, in request return session.request(method=method, url=url, **kwargs) File "/usr/local/lib/python3.7/dist-packages/requests/sessions.py", line 587, in request resp = self.send(prep, **send_kwargs) File "/usr/local/lib/python3.7/dist-packages/requests/sessions.py", line 701, in send r = adapter.send(request, **kwargs) File "/usr/local/lib/python3.7/dist-packages/requests/adapters.py", line 565, in send raise ConnectionError(e, request=request) requests.exceptions.ConnectionError: HTTPSConnectionPool(host='api.emporiaenergy.com', port=443): Max retries exceeded with url: /customers/devices (Caused by NewConnectionError(': Failed to establish a new connection: [Errno -3] Temporary failure in name resolution'))