### The problem
Home Assistant has been working fine for months, without changi…ng configuration, beyond official updates...
For the last two nights (starting approx 8/2/2023) when we've woken up, the system hasn't been working correctly.
This morning (8/4/2023), I have isolated it to be that the automations aren't working, a significant number of our switches rely on automation to turn on the devices (eg Switch -> Zwave light on another circuit).
While attempting to diagnose this, I trying going through the logs:
The core log is filled with:
2023-08-03 06:08:12.452 WARNING (SyncWorker_2) [homeassistant.components.sql.sensor] SELECT min(time_fired) earliest FROM events LIMIT 1; returned no results
2023-08-03 06:08:12.455 WARNING (SyncWorker_3) [homeassistant.components.sql.sensor] SELECT max(time_fired) latest FROM events LIMIT 1; returned no results
With the SyncWorking thread varying....
I do see this error, but I am not seeing any errors when examining the automation?
2023-08-03 08:20:05.843 ERROR (MainThread) [homeassistant.components.zwave_js] Unable to set value 21-38-0-targetValue: Z-Wave error 1405: The node failed to decode the message. (ZW1405)
2023-08-03 08:20:05.846 ERROR (MainThread) [homeassistant.components.automation.entrance_hallway_door_sensor_tripped] Entrance Hallway - Turn On Light: Error executing script. Error for device at pos 1:
2023-08-03 08:20:05.849 ERROR (MainThread) [homeassistant.components.automation.entrance_hallway_door_sensor_tripped] Error while executing automation automation.entrance_hallway_door_sensor_tripped:
And at least one or more of async errors:
2023-08-03 10:56:22.342 ERROR (MainThread) [homeassistant] Error doing job: Exception in callback Future.set_result(None)
Traceback (most recent call last):
File "/usr/local/lib/python3.11/asyncio/events.py", line 80, in _run
self._context.run(self._callback, *self._args)
asyncio.exceptions.InvalidStateError: invalid state
And home assistant is crashing with an airplay device?
2023-08-03 19:07:27.393 ERROR (MainThread) [pyatv.protocols.airplay] Failed to set up remote control channel
Traceback (most recent call last):
File "/usr/local/lib/python3.11/site-packages/pyatv/protocols/airplay/__init__.py", line 289, in _connect_rc
await session.connect()
File "/usr/local/lib/python3.11/site-packages/pyatv/protocols/airplay/ap2_session.py", line 63, in connect
self.connection = await http_connect(self._address, self._control_port)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/pyatv/support/http.py", line 631, in http_connect
_, connection = await loop.create_connection(HttpConnection, address, port)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/asyncio/base_events.py", line 1085, in create_connection
raise exceptions[0]
File "/usr/local/lib/python3.11/asyncio/base_events.py", line 1069, in create_connection
sock = await self._connect_sock(
^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/asyncio/base_events.py", line 973, in _connect_sock
await self.sock_connect(sock, address)
File "/usr/local/lib/python3.11/asyncio/selector_events.py", line 628, in sock_connect
return await fut
^^^^^^^^^
File "/usr/local/lib/python3.11/asyncio/selector_events.py", line 668, in _sock_connect_cb
raise OSError(err, f'Connect call failed {address}')
OSError: [Errno 113] Connect call failed ('192.168.1.103', 7000)
2023-08-03 19:07:30.465 ERROR (MainThread) [homeassistant.components.apple_tv] Failed to connect
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/components/apple_tv/__init__.py", line 226, in connect_once
await self._connect(conf, raise_missing_credentials)
File "/usr/src/homeassistant/homeassistant/components/apple_tv/__init__.py", line 328, in _connect
self.atv = await connect(conf, self.hass.loop, session=session)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/pyatv/__init__.py", line 135, in connect
await atv.connect()
File "/usr/local/lib/python3.11/site-packages/pyatv/core/facade.py", line 681, in connect
if await setup_data.connect():
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/pyatv/protocols/mrp/__init__.py", line 1090, in _connect
await protocol.start()
File "/usr/local/lib/python3.11/site-packages/pyatv/protocols/mrp/protocol.py", line 129, in start
await self.connection.connect()
File "/usr/local/lib/python3.11/site-packages/pyatv/protocols/mrp/connection.py", line 104, in connect
await self.loop.create_connection(lambda: self, self.host, self.port)
File "/usr/local/lib/python3.11/asyncio/base_events.py", line 1085, in create_connection
raise exceptions[0]
File "/usr/local/lib/python3.11/asyncio/base_events.py", line 1069, in create_connection
sock = await self._connect_sock(
^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/asyncio/base_events.py", line 973, in _connect_sock
await self.sock_connect(sock, address)
File "/usr/local/lib/python3.11/asyncio/selector_events.py", line 628, in sock_connect
return await fut
^^^^^^^^^
File "/usr/local/lib/python3.11/asyncio/selector_events.py", line 668, in _sock_connect_cb
raise OSError(err, f'Connect call failed {address}')
OSError: [Errno 113] Connect call failed ('192.168.1.103', 7000)
Supervisor logs show nothing useful
The zwavejs2mqtt logs don't show a lot of content but:
023-08-04T09:11:36.539Z DRIVER RangeError: The value of "offset" is out of range. It must be an integer. Rece
ived NaN
at new NodeError (node:internal/errors:405:5)
at boundsError (node:internal/buffer:82:11)
at Buffer.readInt8 (node:internal/buffer:426:5)
at parseRSSI (/opt/node_modules/zwave-js/src/lib/serialapi/transport/SendD
ataShared.ts:55:22)
at tryParseRSSI (/opt/node_modules/zwave-js/src/lib/serialapi/transport/Se
ndDataShared.ts:72:9)
at new BridgeApplicationCommandRequest (/opt/node_modules/zwave-js/src/lib
/serialapi/application/BridgeApplicationCommandRequest.ts:97:27)
at Function.from (/opt/node_modules/@zwave-js/serial/src/message/Message.t
s:255:15)
at Driver.serialport_onData (/opt/node_modules/zwave-js/src/lib/driver/Dri
ver.ts:2797:18)
at SerialAPIParser.emit (node:events:514:28)
at SerialAPIParser.emit (node:domain:489:12)
2023-08-04T09:11:38.061Z DRIVER Dropping message because it could not be deserialized: The command class unkno
wn (0x04) is not implemented (ZW0303)
2023-08-04T09:11:48.556Z DRIVER Dropping message because it could not be deserialized: The command class unkno
wn (0xc2) is not implemented (ZW0303)
2023-08-04T09:11:49.158Z DRIVER Dropping message because it could not be deserialized: The command class unkno
wn (0xc3) is not implemented (ZW0303)
2023-08-04T09:11:49.755Z DRIVER Dropping message because it could not be deserialized: The command class unkno
wn (0xc4) is not implemented (ZW0303)
2023-08-04T09:11:50.360Z DRIVER Dropping message because it could not be deserialized: The command class unkno
wn (0xc5) is not implemented (ZW0303)
### What version of Home Assistant Core has the issue?
2023.8.0
### What was the last working version of Home Assistant Core?
_No response_
### What type of installation are you running?
Home Assistant OS
### Integration causing the issue
Core
### Link to integration documentation on our website
_No response_
### Diagnostics information
[a0d7b954_zwavejs2mqtt_2023-08-04T09-16-04.394Z.log](https://github.com/home-assistant/core/files/12259692/a0d7b954_zwavejs2mqtt_2023-08-04T09-16-04.394Z.log)
[home-assistant_2023-08-04T09-12-55.204Z.log](https://github.com/home-assistant/core/files/12259693/home-assistant_2023-08-04T09-12-55.204Z.log)
[home-assistant_2023-08-04T09-15-33.200Z.log](https://github.com/home-assistant/core/files/12259694/home-assistant_2023-08-04T09-15-33.200Z.log)
[supervisor_2023-08-04T09-16-58.157Z.log](https://github.com/home-assistant/core/files/12259695/supervisor_2023-08-04T09-16-58.157Z.log)
### Example YAML snippet
_No response_
### Anything in the logs that might be useful for us?
_No response_
### Additional information
_No response_