Invalid Config on HA Green

I just got HA Green. I set it up based on the insturctions via my browser. I am getting the following notifications on start up each time:

Invalid config
The following integrations and platforms could not be set up:

cloud (Show logs)
zeroconf (Show logs)
conversation (Show logs)
assist_pipeline (Show logs)
mobile_app (Show logs)
default_config (Show logs)
Please check your config and logs.
    from .connection import SamsungTVWSConnection
  File "/usr/local/lib/python3.13/site-packages/samsungtvws/connection.py", line 126, in <module>
    class SamsungTVWSConnection(SamsungTVWSBaseConnection):
    ...<133 lines>...
            return self.connection is not None and self.connection.connected
  File "/usr/local/lib/python3.13/site-packages/samsungtvws/connection.py", line 127, in SamsungTVWSConnection
    connection: Optional[websocket.WebSocket]
                         ^^^^^^^^^^^^^^^^^^^
AttributeError: module 'websocket' has no attribute 'WebSocket'
2024-12-31 20:29:07.191 WARNING (MainThread) [homeassistant.util.loop] Detected blocking call to import_module with args ('homeassistant.components.samsungtv.config_flow',) in /usr/src/homeassistant/homeassistant/loader.py, line 1303: return importlib.import_module(f"{self.pkg_path}.{platform_name}") inside the event loop; This is causing stability issues. Please create a bug report at https://github.com/home-assistant/core/issues?q=is%3Aopen+is%3Aissue
For developers, please see https://developers.home-assistant.io/docs/asyncio_blocking_operations/#import_module
Traceback (most recent call last):
  File "<frozen runpy>", line 198, in _run_module_as_main
  File "<frozen runpy>", line 88, in _run_code
  File "/usr/src/homeassistant/homeassistant/__main__.py", line 227, in <module>
    sys.exit(main())
  File "/usr/src/homeassistant/homeassistant/__main__.py", line 213, in main
    exit_code = runner.run(runtime_conf)
  File "/usr/src/homeassistant/homeassistant/runner.py", line 154, in run
    return loop.run_until_complete(setup_and_run_hass(runtime_config))
  File "/usr/local/lib/python3.13/asyncio/base_events.py", line 708, in run_until_complete
    self.run_forever()
  File "/usr/local/lib/python3.13/asyncio/base_events.py", line 679, in run_forever
    self._run_once()
  File "/usr/local/lib/python3.13/asyncio/base_events.py", line 2027, in _run_once
    handle._run()
  File "/usr/local/lib/python3.13/asyncio/events.py", line 89, in _run
    self._context.run(self._callback, *self._args)
  File "/usr/src/homeassistant/homeassistant/util/async_.py", line 112, in sem_task
    return await task
  File "/usr/src/homeassistant/homeassistant/config_entries.py", line 1315, in async_init
    flow, result = await self._async_init(flow_id, handler, context, data)
  File "/usr/src/homeassistant/homeassistant/config_entries.py", line 1340, in _async_init
    flow = await self.async_create_flow(handler, context=context, data=data)
  File "/usr/src/homeassistant/homeassistant/config_entries.py", line 1536, in async_create_flow
    handler = await _async_get_flow_handler(
  File "/usr/src/homeassistant/homeassistant/config_entries.py", line 3333, in _async_get_flow_handler
    await _load_integration(hass, domain, hass_config)
  File "/usr/src/homeassistant/homeassistant/config_entries.py", line 3312, in _load_integration
    await integration.async_get_platform("config_flow")
  File "/usr/src/homeassistant/homeassistant/loader.py", line 1107, in async_get_platform
    platforms = await self.async_get_platforms((platform_name,))
  File "/usr/src/homeassistant/homeassistant/loader.py", line 1172, in async_get_platforms
    platforms.update(self._load_platforms(platform_names))
  File "/usr/src/homeassistant/homeassistant/loader.py", line 1097, in _load_platforms
    platform_name: self._load_platform(platform_name)
  File "/usr/src/homeassistant/homeassistant/loader.py", line 1271, in _load_platform
    cache[full_name] = self._import_platform(platform_name)
  File "/usr/src/homeassistant/homeassistant/loader.py", line 1303, in _import_platform
    return importlib.import_module(f"{self.pkg_path}.{platform_name}")
2024-12-31 20:29:07.252 ERROR (MainThread) [homeassistant.loader] Unexpected exception importing platform homeassistant.components.samsungtv.config_flow
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/loader.py", line 1271, in _load_platform
    cache[full_name] = self._import_platform(platform_name)
                       ~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/loader.py", line 1303, in _import_platform
    return importlib.import_module(f"{self.pkg_path}.{platform_name}")
           ~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/util/loop.py", line 200, in protected_loop_func
    return func(*args, **kwargs)
  File "/usr/local/lib/python3.13/importlib/__init__.py", line 88, in import_module
    return _bootstrap._gcd_import(name[level:], package, level)
           ~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "<frozen importlib._bootstrap>", line 1387, in _gcd_import
  File "<frozen importlib._bootstrap>", line 1360, in _find_and_load
  File "<frozen importlib._bootstrap>", line 1310, in _find_and_load_unlocked
  File "<frozen importlib._bootstrap>", line 488, in _call_with_frames_removed
  File "<frozen importlib._bootstrap>", line 1387, in _gcd_import
  File "<frozen importlib._bootstrap>", line 1360, in _find_and_load
  File "<frozen importlib._bootstrap>", line 1331, in _find_and_load_unlocked
  File "<frozen importlib._bootstrap>", line 935, in _load_unlocked
  File "<frozen importlib._bootstrap_external>", line 1022, in exec_module
  File "<frozen importlib._bootstrap>", line 488, in _call_with_frames_removed
  File "/usr/src/homeassistant/homeassistant/components/samsungtv/__init__.py", line 29, in <module>
    from .bridge import (
    ...<4 lines>...
    )
  File "/usr/src/homeassistant/homeassistant/components/samsungtv/bridge.py", line 15, in <module>
    from samsungtvws.async_remote import SamsungTVWSAsyncRemote
  File "/usr/local/lib/python3.13/site-packages/samsungtvws/__init__.py", line 9, in <module>
    from .remote import SamsungTVWS
  File "/usr/local/lib/python3.13/site-packages/samsungtvws/remote.py", line 16, in <module>
    from . import art, connection, helper, rest, shortcuts
  File "/usr/local/lib/python3.13/site-packages/samsungtvws/art.py", line 22, in <module>
    from .connection import SamsungTVWSConnection
  File "/usr/local/lib/python3.13/site-packages/samsungtvws/connection.py", line 126, in <module>
    class SamsungTVWSConnection(SamsungTVWSBaseConnection):
    ...<133 lines>...
            return self.connection is not None and self.connection.connected
  File "/usr/local/lib/python3.13/site-packages/samsungtvws/connection.py", line 127, in SamsungTVWSConnection
    connection: Optional[websocket.WebSocket]
                         ^^^^^^^^^^^^^^^^^^^
AttributeError: module 'websocket' has no attribute 'WebSocket'
2024-12-31 20:29:07.278 ERROR (MainThread) [homeassistant.config_entries] Error occurred loading flow for integration samsungtv: Exception importing homeassistant.components.samsungtv.config_flow
2024-12-31 20:29:07.281 ERROR (MainThread) [homeassistant] Error doing job: Task exception was never retrieved (None)
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/loader.py", line 1271, in _load_platform
    cache[full_name] = self._import_platform(platform_name)
                       ~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/loader.py", line 1303, in _import_platform
    return importlib.import_module(f"{self.pkg_path}.{platform_name}")
           ~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/util/loop.py", line 200, in protected_loop_func
    return func(*args, **kwargs)
  File "/usr/local/lib/python3.13/importlib/__init__.py", line 88, in import_module
    return _bootstrap._gcd_import(name[level:], package, level)
           ~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "<frozen importlib._bootstrap>", line 1387, in _gcd_import
  File "<frozen importlib._bootstrap>", line 1360, in _find_and_load
  File "<frozen importlib._bootstrap>", line 1310, in _find_and_load_unlocked
  File "<frozen importlib._bootstrap>", line 488, in _call_with_frames_removed
  File "<frozen importlib._bootstrap>", line 1387, in _gcd_import
  File "<frozen importlib._bootstrap>", line 1360, in _find_and_load
  File "<frozen importlib._bootstrap>", line 1331, in _find_and_load_unlocked
  File "<frozen importlib._bootstrap>", line 935, in _load_unlocked
  File "<frozen importlib._bootstrap_external>", line 1022, in exec_module
  File "<frozen importlib._bootstrap>", line 488, in _call_with_frames_removed
  File "/usr/src/homeassistant/homeassistant/components/samsungtv/__init__.py", line 29, in <module>
    from .bridge import (
    ...<4 lines>...
    )
  File "/usr/src/homeassistant/homeassistant/components/samsungtv/bridge.py", line 15, in <module>
    from samsungtvws.async_remote import SamsungTVWSAsyncRemote
  File "/usr/local/lib/python3.13/site-packages/samsungtvws/__init__.py", line 9, in <module>
    from .remote import SamsungTVWS
  File "/usr/local/lib/python3.13/site-packages/samsungtvws/remote.py", line 16, in <module>
    from . import art, connection, helper, rest, shortcuts
  File "/usr/local/lib/python3.13/site-packages/samsungtvws/art.py", line 22, in <module>
    from .connection import SamsungTVWSConnection
  File "/usr/local/lib/python3.13/site-packages/samsungtvws/connection.py", line 126, in <module>
    class SamsungTVWSConnection(SamsungTVWSBaseConnection):
    ...<133 lines>...
            return self.connection is not None and self.connection.connected
  File "/usr/local/lib/python3.13/site-packages/samsungtvws/connection.py", line 127, in SamsungTVWSConnection
    connection: Optional[websocket.WebSocket]
                         ^^^^^^^^^^^^^^^^^^^
AttributeError: module 'websocket' has no attribute 'WebSocket'
The above exception was the direct cause of the following exception:
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/config_entries.py", line 3312, in _load_integration
    await integration.async_get_platform("config_flow")
  File "/usr/src/homeassistant/homeassistant/loader.py", line 1107, in async_get_platform
    platforms = await self.async_get_platforms((platform_name,))
                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/loader.py", line 1184, in async_get_platforms
    import_future.result()
    ~~~~~~~~~~~~~~~~~~~~^^
  File "/usr/src/homeassistant/homeassistant/loader.py", line 1172, in async_get_platforms
    platforms.update(self._load_platforms(platform_names))
                     ~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/loader.py", line 1097, in _load_platforms
    platform_name: self._load_platform(platform_name)
                   ~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/loader.py", line 1291, in _load_platform
    raise ImportError(
        f"Exception importing {self.pkg_path}.{platform_name}"
    ) from err
ImportError: Exception importing homeassistant.components.samsungtv.config_flow
The above exception was the direct cause of the following exception:
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/discovery_flow.py", line 137, in _async_start
    await gather_with_limited_concurrency(FLOW_INIT_LIMIT, *init_coros)
  File "/usr/src/homeassistant/homeassistant/util/async_.py", line 114, in gather_with_limited_concurrency
    return await gather(
           ^^^^^^^^^^^^^
    ...<2 lines>...
    )
    ^
  File "/usr/src/homeassistant/homeassistant/util/async_.py", line 112, in sem_task
    return await task
           ^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/config_entries.py", line 1315, in async_init
    flow, result = await self._async_init(flow_id, handler, context, data)
                   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/config_entries.py", line 1340, in _async_init
    flow = await self.async_create_flow(handler, context=context, data=data)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/config_entries.py", line 1536, in async_create_flow
    handler = await _async_get_flow_handler(
              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
        self.hass, handler_key, self._hass_config
        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    )
    ^
  File "/usr/src/homeassistant/homeassistant/config_entries.py", line 3333, in _async_get_flow_handler
    await _load_integration(hass, domain, hass_config)
  File "/usr/src/homeassistant/homeassistant/config_entries.py", line 3319, in _load_integration
    raise data_entry_flow.UnknownHandler from err
homeassistant.data_entry_flow.UnknownHandler
2024-12-31 20:29:07.560 ERROR (MainThread) [homeassistant.config_entries] Error occurred loading flow for integration sonos: cannot import name 'parse' from 'xmltodict' (/usr/local/lib/python3.13/site-packages/xmltodict.py)
2024-12-31 20:29:07.563 ERROR (MainThread) [homeassistant.config_entries] Error occurred loading flow for integration sonos: cannot import name 'parse' from 'xmltodict' (/usr/local/lib/python3.13/site-packages/xmltodict.py)
2024-12-31 20:29:07.563 ERROR (MainThread) [homeassistant.config_entries] Error occurred loading flow for integration sonos: cannot import name 'parse' from 'xmltodict' (/usr/local/lib/python3.13/site-packages/xmltodict.py)
2024-12-31 20:29:07.564 ERROR (MainThread) [homeassistant.config_entries] Error occurred loading flow for integration sonos: cannot import name 'parse' from 'xmltodict' (/usr/local/lib/python3.13/site-packages/xmltodict.py)
2024-12-31 20:29:07.566 ERROR (MainThread) [homeassistant.config_entries] Error occurred loading flow for integration sonos: cannot import name 'parse' from 'xmltodict' (/usr/local/lib/python3.13/site-packages/xmltodict.py)
2024-12-31 20:29:07.566 ERROR (MainThread) [homeassistant.config_entries] Error occurred loading flow for integration sonos: cannot import name 'parse' from 'xmltodict' (/usr/local/lib/python3.13/site-packages/xmltodict.py)

I can share more logs or whatever else would be helpful.

1 Like

Thanks, this fixed it!

1 Like