ualex73 / monitor_docker

Monitor Docker containers from Home Assistant
Apache License 2.0
267 stars 34 forks source link

After Update to the latest version KeyError: 'allinone' #147

Closed frauhottelmann closed 1 month ago

frauhottelmann commented 1 month ago

Hi there,

after I updated to the latest version I am getting the following error:

2024-05-13 15:40:22.136 ERROR (MainThread) [homeassistant.components.sensor] Error while setting up monitor_docker platform for sensor

Traceback (most recent call last):

  File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 356, in _async_setup_platform

    await asyncio.shield(awaitable)

  File "/config/custom_components/monitor_docker/sensor.py", line 147, in async_setup_platform

    CONTAINER_MONITOR_LIST[CONTAINER_INFO_ALLINONE],

    ~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^

KeyError: 'allinone'

I haven't changed anything in my config:

monitor_docker:
  - name: Docker
    switchenabled: false
    monitored_conditions:
      - state
      - status
      - image
      - allinone

Any ideas?

linsvensson commented 1 month ago

I've been having the same problem. My setup looks like this, haven't changed anything. monitored_conditions: [allinone]

Balok-Fesarius commented 1 month ago

Same. The issue started after upgrading to HA 2024.5.3. I tried rolling back to monitor_docker v1.14, but the problem still persisted. I'm thinking its something new in HA 2024.5.3 that broke monitordocker. `¯_(ツ)/¯ `

matteo-martinelli commented 1 month ago

Same for me: after the update, I have the following error:

Error while setting up monitor_docker platform for sensor

... with the following specification:

KeyError: 'allinone'

MikeDeltaHH commented 1 month ago

Same here…

ualex73 commented 1 month ago

I can reproduce the error, but I do not have a direct working solution (I can remove the error, but allinone then still does not work). I need to debug more to figure out where it goes wrong.

MikeDeltaHH commented 1 month ago

I removed "allinone" and it worked again... thanks!

ualex73 commented 1 month ago

Fixed in 1.16, which I just published.