system-bridge
system-bridge copied to clipboard
Home Assistant won't work with the dev version (4.2.0)
Description
Adding a new item to the system module breaks the connector
What Platform / OS are you running?
Windows/Linux
What version are you running?
4.2.0 (dev)
Anything in the logs or a references that might be useful?
HA Core:
2024-04-07 16:03:23.699 ERROR (MainThread) [homeassistant] Error doing job: Task exception was never retrieved
Traceback (most recent call last):
File "/usr/local/lib/python3.12/site-packages/systembridgeconnector/websocket_client.py", line 591, in listen
await self.listen_for_messages(callback=_callback_message)
File "/usr/local/lib/python3.12/site-packages/systembridgeconnector/websocket_client.py", line 607, in listen_for_messages
await callback(message)
File "/usr/local/lib/python3.12/site-packages/systembridgeconnector/websocket_client.py", line 579, in _callback_message
else model(**message[EVENT_DATA]),
^^^^^^^^^^^^^^^^^^^^^^^^^^^^
TypeError: System.__init__() got an unexpected keyword argument 'run_mode'
2024-04-07 16:03:38.654 WARNING (MainThread) [homeassistant.components.system_bridge.config_flow] Timed out connecting to 192.168.1.127:
Holding the release until https://github.com/home-assistant/core/pull/114896 and a second PR after updating the connector and models
Once the package update to the connector and models package is in, the release needs to be timed
Since the old connector relies on models with no enums, just updating the models won't work either:
2024-04-07 15:25:33.566 ERROR (MainThread) [homeassistant.config_entries] Error occurred loading flow for integration system_bridge: cannot import name 'MODEL_RESPONSE' from 'systembridgemodels.const' (/home/vscode/.local/lib/python3.12/site-packages/systembridgemodels/const.py)
If anything comes up, there are a couple of workarounds:
- Downgrade the models and connector on the backend
- Remove the new fields in models, update connector, update cli and backend
Applying a hybrid of the above