Since upgrading to 2021.4.0 yesterday, the Surepetcare integration had stopped working. I’ve upgrade to 2021.4.1 today and I’m getting the same error.
I’m running on a Pi4 with the Home Assistant SD image.
Note, I updated both the core and OS yesterday via supervisor.
My configuration.yaml has the following config
surepetcare:
username: !secret surepetcare_user
password: !secret surepetcare_pass
flaps: [xxxxxx]
pets: [xxxxx,xxxxx,xxxxx,xxxxx]
In the logs, I have a warning
Logger: homeassistant.util.async_
Source: util/async_.py:131
First occurred: 17:04:42 (1 occurrences)
Last logged: 17:04:42
Detected I/O inside the event loop. This is causing stability issues. Please report issue for surepetcare doing I/O at homeassistant/components/surepetcare/__init__.py, line 116: device_data = await surepy.device(device[CONF_ID])
Then an error
Logger: homeassistant.setup
Source: util/async_.py:139
First occurred: 17:04:42 (1 occurrences)
Last logged: 17:04:42
Error during setup of component surepetcare
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/setup.py", line 240, in _async_setup_component
result = await task
File "/usr/src/homeassistant/homeassistant/components/surepetcare/__init__.py", line 116, in async_setup
device_data = await surepy.device(device[CONF_ID])
File "/usr/local/lib/python3.8/site-packages/surepy/__init__.py", line 184, in device
device: Dict[str, Any] = (await self.devices).get(device_id, {})
File "/usr/local/lib/python3.8/site-packages/surepy/__init__.py", line 181, in devices
return await self.get_entities("devices")
File "/usr/local/lib/python3.8/site-packages/surepy/__init__.py", line 244, in get_entities
await self._get_resource(resource=MESTART_RESOURCE)
File "/usr/local/lib/python3.8/site-packages/surepy/__init__.py", line 262, in _get_resource
self.get_token()
File "/usr/local/lib/python3.8/site-packages/surepy/__init__.py", line 410, in get_token
raw_response: requests.Response = requests.post(
File "/usr/local/lib/python3.8/site-packages/requests/api.py", line 119, in post
return request('post', url, data=data, json=json, **kwargs)
File "/usr/local/lib/python3.8/site-packages/requests/api.py", line 61, in request
return session.request(method=method, url=url, **kwargs)
File "/usr/local/lib/python3.8/site-packages/requests/sessions.py", line 542, in request
resp = self.send(prep, **send_kwargs)
File "/usr/local/lib/python3.8/site-packages/requests/sessions.py", line 655, in send
r = adapter.send(request, **kwargs)
File "/usr/local/lib/python3.8/site-packages/requests/adapters.py", line 439, in send
resp = conn.urlopen(
File "/usr/local/lib/python3.8/site-packages/urllib3/connectionpool.py", line 699, in urlopen
httplib_response = self._make_request(
File "/usr/local/lib/python3.8/site-packages/urllib3/connectionpool.py", line 394, in _make_request
conn.request(method, url, **httplib_request_kw)
File "/usr/local/lib/python3.8/site-packages/urllib3/connection.py", line 234, in request
super(HTTPConnection, self).request(method, url, body=body, headers=headers)
File "/usr/local/lib/python3.8/http/client.py", line 1255, in request
self._send_request(method, url, body, headers, encode_chunked)
File "/usr/local/lib/python3.8/http/client.py", line 1266, in _send_request
self.putrequest(method, url, **skips)
File "/usr/local/lib/python3.8/site-packages/urllib3/connection.py", line 214, in putrequest
return _HTTPConnection.putrequest(self, method, url, *args, **kwargs)
File "/usr/src/homeassistant/homeassistant/util/async_.py", line 150, in protected_loop_func
check_loop()
File "/usr/src/homeassistant/homeassistant/util/async_.py", line 139, in check_loop
raise RuntimeError(
RuntimeError: I/O must be done in the executor; Use `await hass.async_add_executor_job()` at homeassistant/components/surepetcare/__init__.py, line 116: device_data = await surepy.device(device[CONF_ID])
I couldn’t see anything else on the forum or GitHub, I just wondered if this is a bug that needs raising?