Summary card and badges for people, devices and status (with python script and custom card)

No i did not but i made the changes and then got the new error:

2018-06-28 17:32:22 ERROR (Thread-22) [homeassistant.components.python_script.summary.py] Error executing script: list index out of range
Traceback (most recent call last):
  File "/srv/homeassistant/lib/python3.5/site-packages/homeassistant/components/python_script.py", line 166, in execute
    exec(compiled.code, restricted_globals, local)
  File "summary.py", line 106, in <module>
  File "/srv/homeassistant/lib/python3.5/site-packages/RestrictedPython/Eval.py", line 35, in default_guarded_getitem
    return ob[index]
IndexError: list index out of range

As per sensor.summary, that does not show up at all in the list.

means you have to have the same amount for all lists in the script:

groups = ['group.family', 'group.devices_default', 'group.devices_alwayson']
groups_format = ['{} at home: {}', '{} in use: {}', '!{} to check it out: {}'] # Message prefix
groups_filter = ['homex', 'on|playing', 'off|not_home'] # Filter to list
groups_badge = ['Home', 'In use', 'Status'] # Badge 'belt' (unit_of_measurement)
groups_badge_pic = ['', '', 'ok|bug|critical'] # Pictures: none, on picure or a list of picture (in this case the picture position will match the count)
groups_min_show = [0, 1, 1] # Mininum count to show
groups_theme = ['entity_green', 'entity_purple', 'entity_green|entity_orange|entity_red'] # Theme template
groups_desc = ['!Nobody in home since ', '', ''] # Can set the default description, for use in case count = 0
#groups_desc = ['!Nobody in home', '', '+System ok']
groups_count = [0, 0, 0]

this uses 3 groups, and all groups_ items need the have 3 filled out.

also, you need to set 3 images for ‘ok|bug|critical’ in the correct folder, and need the themes for the groups_theme…

its a bit of a complex script if you start with it at point blank…

I get this error now:

2018-06-28 17:32:22 ERROR (Thread-22) [homeassistant.components.python_script.summary.py] Error executing script: list index out of range
Traceback (most recent call last):
  File "/srv/homeassistant/lib/python3.5/site-packages/homeassistant/components/python_script.py", line 166, in execute
    exec(compiled.code, restricted_globals, local)
  File "summary.py", line 106, in <module>
  File "/srv/homeassistant/lib/python3.5/site-packages/RestrictedPython/Eval.py", line 35, in default_guarded_getitem
    return ob[index]
IndexError: list index out of range

and my groups look like this:

groups = ['group.tracker', 'group.all_devices', 'group.all_lights']

maybe post your full script so we can read along.

did you create the images too? ok, bug, critical? in the correct folder:
picture = '/local/badges/{}.png'.format(picture)

and the themes (groups_theme = ['entity_green', 'entity_purple', 'entity_green|entity_orange|entity_red'] # Theme template) : home-assistant-config/config/frontend_themes.yaml at master · maattdiy/home-assistant-config · GitHub

the line your error is complaining about is just that: theme = list[groups_count[idx]]

so be sure to have the themes installed.

last thing i can think of without your code, is this is a version of the script that might need all groups to have the same amount of entities. Check if you do, and see if this makes a difference if you adjust it.

Hello,
I found this page I think a lit a bit to late ^^
Can somebody post his code? please I think there have a lot of changes with the first code.
I can not have the sensor.summary ^^

THX

@Mariusthvdb