2022.9: Home Assistant Birthday Release!

Because the browser didn’t change, the version is the same as before the HA update. This only started after the update. I regressed to August the it doesn’t happen. Reinstalled September update and problem came back. So obviously it’s HA not the browser.

Bluetooth intragration crashes after some time (<1h) · Issue #78036 · home-assistant/core · GitHub is broken for me too.

Please be more careful when programming.

Please tell me someone who knows it for certain.

Currently people move their integrations from yaml to UI.
Is is obligatory? No.
Is it possible to maintain settings in UI & yaml in parallel? Probably yes; harder but still possible; and probably there is a way to “yaml settings - change in yaml only, UI settings - change in UI only”.

Similar questions are asked here many times.
And a situation becomes worse.

Check here: Actions - Home Assistant

Used "data" instead of "service_data":

Outdated docs?
Earlier I used “data” in “tap_action” - and it worked.

Btw, here all 3 different "tap_action" seem to give same result (i.e. toggling an "input_boolean"):

type: entities
entities:
  - input_boolean.test_boolean

  - entity: sun.sun
    name: using data
    tap_action:
      action: call-service
      service: input_boolean.toggle
      data:
        entity_id: input_boolean.test_boolean

  - entity: sun.sun
    name: using service_data
    tap_action:
      action: call-service
      service: input_boolean.toggle
      service_data:
        entity_id: input_boolean.test_boolean

  - entity: sun.sun
    name: using target
    tap_action:
      action: call-service
      service: input_boolean.toggle
      target:
        entity_id: input_boolean.test_boolean

For instance, these both codes work for a template switch:

        turn_on:
          - service: input_boolean.turn_on
            entity_id: input_boolean.test_boolean
...
        turn_off:
          - service: input_boolean.turn_off
            target:
              entity_id: input_boolean.test_boolean

But for picture-elements card you are obliged to use "service_data" instead of “target”:

          - type: service-button
            title: Button
            style:
              top: 6%
              left: 20%
            service: homeassistant.update_entity
            service_data:
              entity_id: sun.sun

So, 100500 different variants of calling a service.
There should be ONE way to define data when calling services - and it must be used in docs for examples (all of us may propose corrections in docs, btw).

Btw, got plenty of “repair required” after update 2022.9.4 → 2022.9.5.
These calls were considered as “wrong service”:

                        - service: input_boolean.turn_off
                          target:
                            entity_id: input_boolean.xxxxxx
                          data: {}

Will see, may be will register an issue for this.

Here background, esp. not everything is possible in each case. I agree, that it would be great to have always only one multi-optional way, but here I see the problems of breaking changes for 99,9% of the users as well in removing the “old” ways.

What? No. You completely miss-interpreted what I said.

Target isn’t valid in the frontend, i.e. under tap_action.

It’s valid in automation actions, template actions, blueprint actions, and script sequences.

So this is perfectly valid. Just not in the frontend.

1 Like

service_data was just changed to data recently in tap_actions. Before it required the verbiage service_data. Now, service_data and data both work in tap_actions. The docs no longer cover service_data because there’s no reason to at this point. But your old tap_actions will still work if they have service_data and your new tap actions that just use data will also still work.

Yes, see previous post.

1 Like

Yep, and that background doesn’t cover tap_actions at all. They have a different history, but similar. Maybe someday the yaml in tap_actions will match the yaml for calling a service in the backend. :man_shrugging:

This post was not really addressed to you. It was basically about “why this code is considered as wring service”.

This difference makes a syntax confusing.

This would be good!

Check this code - “target” seems to work:

type: entities
entities:
  - input_boolean.test_boolean
  - type: button
    name: tap to toggle boolean
    tap_action:
      action: call-service
      service: input_boolean.toggle
      target:
        entity_id: input_boolean.test_boolean
  - entity: sun.sun
    name: tap to toggle boolean
    tap_action:
      action: call-service
      service: input_boolean.toggle
      target:
        entity_id: input_boolean.test_boolean

image

Interesting, that makes it mean that there is a bug. But based on the documents, it’s unclear what the expected behavior is. So we don’t know where to file the issue. I’d just put it under core and let the devs figure it out. Either tap_action → target should work everywhere and the documents should include target, or target should not work anywhere and the docs don’t need to be updated.

And in custom cards still the “target” is not used:

  - type: custom:multiple-entity-row
    entity: sun.sun
    name: tap to toggle boolean
    entities:
      - icon: mdi:restore
        tap_action:
          action: call-service
          service: input_boolean.toggle
          target:
            entity_id: input_boolean.test_boolean
    show_state: false

image
Shows an error:
image

Could you post an issue’s link here then?
Or I may try to create the issue myself, if you like.

Well, that’s custom:multiple-entity-row not implementing tap action correctly. I’m pretty sure custom cards ‘replicate’ tap_action and don’t use core’s tap_action. That’s what custom:button-card does and many others.

Right, bad example.
This card has own rules: GitHub - benct/lovelace-multiple-entity-row: Show multiple entity states and attributes on entity rows in Home Assistant's Lovelace UI

What card are you using for that tap_action?

no repairs at all, but I had this copied from the docs before, and just about the only non custom:button-card service_data in my Dashboards…:

  - type: service-button
    title: ""
    service: remote.send_command
    service_data:
      entity_id: remote.xboxone_remote
      command: Up

on the XBOX remote.

this would need to be:

  - type: service-button
    title: ""
    service: remote.send_command
    data:
      entity_id: remote.xboxone_remote
      command: Up

now? Sorry for asking, but I can not find the service-button in the docs to check the official options

__
edit
nevermind, its here: Picture Elements Card - Home Assistant
and still using service_data

Created in issue:

1 Like

mushroom chip, mushroom entity and i tried with the regular entity card

thanks for that, I added a line on the picture elements