I have also issues with my NanoLeaf. I can control the light within HA but also see some errors pop up:
HA Version: 0.102.3
Nanoleaf FW: 3.3.3
2019-12-09 21:16:21 ERROR (SyncWorker_8) [pynanoleaf.pynanoleaf] 192.168.100.2 is not available
2019-12-09 21:16:21 ERROR (MainThread) [homeassistant.core] Error doing job: Task exception was never retrieved
Traceback (most recent call last):
File "/usr/local/lib/python3.7/site-packages/urllib3/connectionpool.py", line 421, in _make_request
six.raise_from(e, None)
File "<string>", line 3, in raise_from
File "/usr/local/lib/python3.7/site-packages/urllib3/connectionpool.py", line 416, in _make_request
httplib_response = conn.getresponse()
File "/usr/local/lib/python3.7/http/client.py", line 1336, in getresponse
response.begin()
File "/usr/local/lib/python3.7/http/client.py", line 306, in begin
version, status, reason = self._read_status()
File "/usr/local/lib/python3.7/http/client.py", line 267, in _read_status
line = str(self.fp.readline(_MAXLINE + 1), "iso-8859-1")
File "/usr/local/lib/python3.7/socket.py", line 589, in readinto
return self._sock.recv_into(b)
socket.timeout: timed out
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/usr/local/lib/python3.7/site-packages/requests/adapters.py", line 449, in send
timeout=timeout
File "/usr/local/lib/python3.7/site-packages/urllib3/connectionpool.py", line 720, in urlopen
method, url, error=e, _pool=self, _stacktrace=sys.exc_info()[2]
File "/usr/local/lib/python3.7/site-packages/urllib3/util/retry.py", line 400, in increment
raise six.reraise(type(error), error, _stacktrace)
File "/usr/local/lib/python3.7/site-packages/urllib3/packages/six.py", line 735, in reraise
raise value
File "/usr/local/lib/python3.7/site-packages/urllib3/connectionpool.py", line 672, in urlopen
chunked=chunked,
File "/usr/local/lib/python3.7/site-packages/urllib3/connectionpool.py", line 423, in _make_request
self._raise_timeout(err=e, url=url, timeout_value=read_timeout)
File "/usr/local/lib/python3.7/site-packages/urllib3/connectionpool.py", line 331, in _raise_timeout
self, url, "Read timed out. (read timeout=%s)" % timeout_value
urllib3.exceptions.ReadTimeoutError: HTTPConnectionPool(host='192.168.100.2', port=16021): Read timed out. (read timeout=2)
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/usr/local/lib/python3.7/site-packages/pynanoleaf/pynanoleaf.py", line 188, in _request
response = self._session.send(req.prepare(), timeout=self.timeout)
File "/usr/local/lib/python3.7/site-packages/requests/sessions.py", line 646, in send
r = adapter.send(request, **kwargs)
File "/usr/local/lib/python3.7/site-packages/requests/adapters.py", line 529, in send
raise ReadTimeout(e, request=request)
requests.exceptions.ReadTimeout: HTTPConnectionPool(host='192.168.100.2', port=16021): Read timed out. (read timeout=2)
The above exception was the direct cause of the following exception:
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 564, in async_request_call
await coro
File "/usr/local/lib/python3.7/concurrent/futures/thread.py", line 57, in run
result = self.fn(*self.args, **self.kwargs)
File "/usr/src/homeassistant/homeassistant/components/nanoleaf/light.py", line 213, in turn_on
self._light.effect = effect
File "/usr/local/lib/python3.7/site-packages/pynanoleaf/pynanoleaf.py", line 175, in effect
self._put("effects", {"select": value})
File "/usr/local/lib/python3.7/site-packages/pynanoleaf/pynanoleaf.py", line 219, in _put
self._request(path, 'PUT', data)
File "/usr/local/lib/python3.7/site-packages/pynanoleaf/pynanoleaf.py", line 194, in _request
raise Unavailable("{} is not available".format(self.host)) from e
pynanoleaf.pynanoleaf.Unavailable: 192.168.100.2 is not available
2019-12-09 21:19:49 ERROR (SyncWorker_12) [pynanoleaf.pynanoleaf] 192.168.100.2 is not available
2019-12-09 21:19:51 ERROR (SyncWorker_12) [pynanoleaf.pynanoleaf] 192.168.100.2 is not available
2019-12-09 21:19:51 ERROR (SyncWorker_12) [homeassistant.components.nanoleaf.light] Could not update status for Nanoleaf (192.168.100.2 is not available)
2019-12-09 21:20:20 ERROR (SyncWorker_1) [pynanoleaf.pynanoleaf] 192.168.100.2 is not available
2019-12-09 21:20:21 ERROR (SyncWorker_1) [pynanoleaf.pynanoleaf] 192.168.100.2 is not available
2019-12-09 21:20:21 ERROR (SyncWorker_1) [homeassistant.components.nanoleaf.light] Could not update status for Nanoleaf (192.168.100.2 is not available)
2019-12-09 21:20:51 ERROR (SyncWorker_18) [pynanoleaf.pynanoleaf] 192.168.100.2 is not available
2019-12-09 21:20:52 ERROR (SyncWorker_18) [pynanoleaf.pynanoleaf] 192.168.100.2 is not available
2019-12-09 21:20:52 ERROR (SyncWorker_18) [homeassistant.components.nanoleaf.light] Could not update status for Nanoleaf (192.168.100.2 is not available)
2019-12-09 21:21:22 ERROR (SyncWorker_0) [pynanoleaf.pynanoleaf] 192.168.100.2 is not available
2019-12-09 21:21:23 ERROR (SyncWorker_0) [pynanoleaf.pynanoleaf] 192.168.100.2 is not available
2019-12-09 21:21:23 ERROR (SyncWorker_0) [homeassistant.components.nanoleaf.light] Could not update status for Nanoleaf (192.168.100.2 is not available)
After this error dump I can still use NanoLeaf lights in HA. But cant find where this is come from…