Breaking changes to customize in 0.39.0

Hi,

it was interesting to know that the format has changed again. This on-line tool from @balloob was supposed to help, however, it does not work correctly with the following customization formats:

homeassistant:
  customize:
    - entity_id: sensor.wintablet, sensor.mypc
      icon: mdi:tablet
    - entity_id: sensor.next_bus, sensor.mot_*
      icon: mdi:bus

Any ideas how it will work in 0.39 if different entities need the same icon and you don’t want to repeat the same code for each entity?

You need to use a customize_glob entry, here is what the conversion tool output for your config:

homeassistant:
  customize:
    sensor.wintablet: &ref_0
      icon: 'mdi:tablet'
    ' sensor.mypc': *ref_0
    sensor.next_bus: &ref_1
      icon: 'mdi:bus'
  customize_domain: {}
  customize_glob:
    ' sensor.mot_*': *ref_1

thank you, @touliloup
Will this output work with ref? The format of the output doesn’t look correct in terms of formating.

It used to be so simple and foolproof!

The new format is actually easier compared to the one inbetween.

Ref is valid YAML, it will just allow you to re-use the same block without specifying it again.

Noticed a bug in the tool, it would not strip the strings properly. Hence the quotation marks around the entities with a space inside. Updated version is here: https://jsfiddle.net/balloob/d2e56q6f/74/

1 Like

Hi All,

Have been pretty busy of late and have just upgraded from 0.38 to 0.41.

The breaking changes with Customize in 0.39 are causing me a bit of trouble at the moment. I’ve tried using the tool by @balloob to convert but I’m not having much luck.

Can anyone help me convert my “customize”?

https://pastebin.com/dHxL1kn0

Many thanks :slight_smile:

I think it has been reverted back to the old style, so no need to use the tool, but I might be wrong.

OK, Its not recognising any of my customise config since upgrading. I can’t see where it’s reverted back? Is there any up to date documention for it?

I think this is the up-to-date documentation: