zachcheatham / ha-omada

Home Assistant TP-Link Omada Integration
189 stars 26 forks source link

KeyError: 'omada' #25

Open djtoast opened 2 years ago

djtoast commented 2 years ago

Omada intergration works first time around to load it but if I restart Hassio im getting the following error. Note Im not using the default site im using HOME

2022-03-14 09:51:40 WARNING (SyncWorker_0) [homeassistant.loader] We found a custom integration omada which has not been tested by Home Assistant. This component might cause stability problems, be sure to disable it if you experience issues with Home Assistant 2022-03-14 09:52:07 ERROR (MainThread) [homeassistant.config_entries] Error setting up entry Home_Controler: HOME for omada File "/config/custom_components/omada/controller.py", line 164, in get_api_controller File "/config/custom_components/omada/api/controller.py", line 57, in login File "/config/custom_components/omada/api/controller.py", line 75, in _update_api_info File "/config/custom_components/omada/api/controller.py", line 190, in _request File "/config/custom_components/omada/init.py", line 30, in async_setup_entry File "/config/custom_components/omada/controller.py", line 89, in async_setup File "/config/custom_components/omada/controller.py", line 164, in get_api_controller File "/config/custom_components/omada/config_flow.py", line 102, in async_step_init self.controller: OmadaController = self.hass.data[OMADA_DOMAIN][self.config_entry.entry_id][DATA_OMADA] KeyError: 'omada'

thejacko12354 commented 2 years ago

Got the same Issue after I updated HA to 2022.3.3

axute commented 2 years ago

Same here:

Logger: aiohttp.server
Source: custom_components/omada/config_flow.py:96
Integration: TP-Link Omada (documentation)
First occurred: 10:54:40 (2 occurrences)
Last logged: 10:54:43

Error handling request
Traceback (most recent call last):
  File "/usr/local/lib/python3.9/site-packages/aiohttp/web_protocol.py", line 435, in _handle_request
    resp = await request_handler(request)
  File "/usr/local/lib/python3.9/site-packages/aiohttp/web_app.py", line 504, in _handle
    resp = await handler(request)
  File "/usr/local/lib/python3.9/site-packages/aiohttp/web_middlewares.py", line 117, in impl
    return await handler(request)
  File "/usr/src/homeassistant/homeassistant/components/http/security_filter.py", line 60, in security_filter_middleware
    return await handler(request)
  File "/usr/src/homeassistant/homeassistant/components/http/forwarded.py", line 222, in forwarded_middleware
    return await handler(request)
  File "/usr/src/homeassistant/homeassistant/components/http/request_context.py", line 28, in request_context_middleware
    return await handler(request)
  File "/usr/src/homeassistant/homeassistant/components/http/ban.py", line 79, in ban_middleware
    return await handler(request)
  File "/usr/src/homeassistant/homeassistant/components/http/auth.py", line 219, in auth_middleware
    return await handler(request)
  File "/usr/src/homeassistant/homeassistant/components/http/view.py", line 137, in handle
    result = await result
  File "/usr/src/homeassistant/homeassistant/components/config/config_entries.py", line 201, in post
    return await super().post(request)
  File "/usr/src/homeassistant/homeassistant/components/http/data_validator.py", line 62, in wrapper
    result = await method(view, request, *args, **kwargs)
  File "/usr/src/homeassistant/homeassistant/helpers/data_entry_flow.py", line 72, in post
    result = await self._flow_mgr.async_init(
  File "/usr/src/homeassistant/homeassistant/data_entry_flow.py", line 203, in async_init
    flow, result = await task
  File "/usr/src/homeassistant/homeassistant/data_entry_flow.py", line 230, in _async_init
    result = await self._async_handle_step(flow, flow.init_step, data, init_done)
  File "/usr/src/homeassistant/homeassistant/data_entry_flow.py", line 325, in _async_handle_step
    result: FlowResult = await getattr(flow, method)(user_input)
  File "/config/custom_components/omada/config_flow.py", line 96, in async_step_init
    self.controller: OmadaController = self.hass.data[OMADA_DOMAIN][self.config_entry.entry_id][DATA_OMADA]
KeyError: 'omada'

Setup: Success, get devices success, but next day this error. Details: SSL-Verify disabled

pwickie commented 2 years ago

did you guys manage to find a workaround for the issue above? thanks!

ZdenekM commented 1 year ago

Same here...