Hey crew, I’m hoping for some advice - my Z-Wave integration works great most of the time, but about once/day it goes offline, and I’m struggling to find & fix the root cause.
Here’s everything I know!
When does the error occur: usually once/day, and it also tends to go offline if I’m actively making changes in Home Assistant (like if I’m creating Automations).
Problem I experience: when the Z-Wave JS integration stops working, ALL of my Z-Wave devices go ‘unavailable’ so I can’t control them and my automations don’t work. But the weird part is, if I go into the Z-Wave JS UI addon, the devices are still online there and I can even turn lights on/off from within that UI.
How I typically fix it: the short-term fix is to Disable the Z-Wave JS integration, restart Home Assistant, and re-enable the Z-Wave JS Integration. As soon as I click Enable, the Z-Wave devices come back online and can be successfully controlled.
Drawing some conclusions: I wonder if I installed Z-Wave JS UI incorrectly, and maybe I have multiple programs vying for Port 3000?
CURRENT SETUP:
Home Assistant 2023.4.6
Supervisor 2023.07.1
Operating System 10.2
Z-Wave Controller: Z‐Stick Gen5 USB Controller, ZW090, by AEON Labs, Firmware: 1.1
Z-Wave JS Integration:
Driver Version: 11.9.2
Server Version: 1.30.0
Server URL: ws://a0d7b954-zwavejs2mqtt:3000
zwave-js-ui version: 8.22.3
- MQTT Gateway is disabled
- the WS gateway is activated, port is 3000
some relevant LOGS
2023-08-08 11:51:07.431 WARNING (MainThread) [homeassistant.config_entries] Config entry 'Z-Wave JS' for zwave_js integration not ready yet: Failed to connect: Cannot connect to host a0d7b954-zwavejs2mqtt:3000 ssl:default [Connect call failed ('172.30.33.0', 3000)]; Retrying in background
2023-08-08 11:52:22.761 ERROR (MainThread) [homeassistant.components.zwave_js] Unexpected exception: 1 validation error for ReadyEventModel
nodeState -> values -> 7 -> metadata -> states -> __key__
value is not a valid integer (type=type_error.integer)
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/components/zwave_js/__init__.py", line 765, in client_listen
await client.listen(driver_ready)
File "/usr/local/lib/python3.10/site-packages/zwave_js_server/client.py", line 261, in listen
await self.receive_until_closed()
File "/usr/local/lib/python3.10/site-packages/zwave_js_server/client.py", line 329, in receive_until_closed
self._handle_incoming_message(data)
File "/usr/local/lib/python3.10/site-packages/zwave_js_server/client.py", line 412, in _handle_incoming_message
self.driver.receive_event(event) # type: ignore
File "/usr/local/lib/python3.10/site-packages/zwave_js_server/model/driver.py", line 83, in receive_event
self.controller.receive_event(event)
File "/usr/local/lib/python3.10/site-packages/zwave_js_server/model/controller/__init__.py", line 813, in receive_event
node.receive_event(event)
File "/usr/local/lib/python3.10/site-packages/zwave_js_server/model/node/__init__.py", line 416, in receive_event
NODE_EVENT_MODEL_MAP[event.type](**event.data)
File "/usr/local/lib/python3.10/site-packages/pydantic/main.py", line 341, in __init__
raise validation_error
pydantic.error_wrappers.ValidationError: 1 validation error for ReadyEventModel
nodeState -> values -> 7 -> metadata -> states -> __key__
value is not a valid integer (type=type_error.integer)
2023-08-08 11:52:23.494 ERROR (MainThread) [homeassistant.config_entries] Error unloading entry Z-Wave JS for zwave_js
Traceback (most recent call last):
File "/usr/local/lib/python3.10/site-packages/zwave_js_server/client.py", line 116, in async_send_command
return await future
asyncio.exceptions.CancelledError
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/config_entries.py", line 539, in async_unload
result = await component.async_unload_entry(hass, self)
File "/usr/src/homeassistant/homeassistant/components/zwave_js/__init__.py", line 816, in async_unload_entry
await disconnect_client(hass, entry)
File "/usr/src/homeassistant/homeassistant/components/zwave_js/__init__.py", line 795, in disconnect_client
await asyncio.gather(listen_task, start_client_task, *platform_setup_tasks)
File "/usr/src/homeassistant/homeassistant/components/zwave_js/__init__.py", line 212, in start_client
await driver_events.setup(client.driver)
File "/usr/src/homeassistant/homeassistant/components/zwave_js/__init__.py", line 238, in setup
await async_enable_statistics(driver)
File "/usr/src/homeassistant/homeassistant/components/zwave_js/helpers.py", line 130, in async_enable_statistics
await driver.async_enable_statistics("Home Assistant", HA_VERSION)