Setup failed for push

Hello,

I have an error in my configuration but I don’t know how to fix it.
Can you help me?

Logger: homeassistant.setup
Source: setup.py:172
First occurred: 10:27:18 (1 occurrences)
Last logged: 10:27:18

Setup failed for push: No setup or config entry setup function defined.

Thank you in advance
Have a nice day

Nicolouts

Did you noticed the changes?

Hello,
Can you explain me what you mean?
I didn’t understand.

I think the history if the problem start by
first I had push notification to my iPhone and I try to split my config, and I think that this problem occur after.

Regards

Nicolouts

It means that the handling of notifications has changed. But it is difficult to evaluate the problem without your yaml code.

Hello,

Sorry I haven’t understand at the beginning.
Here is my yaml

Thank you for your help

Nicolouts

automation.yaml

  • id: notify_nicolas_ouvrir_garage_porte
    alias: “[:mega:] Envoyer une notification à Nicolas pour ouvrir la porte de garage”
    trigger:
    platform: state
    entity_id: person.nicolouts
    from: not_home
    to: home
    action:

    • service: notify.mobile_app_beskonic_iphone
      data:
      message: “Voulez-vous ouvrir la porte de garage”
      data:
      actions:
      - action: “OUVRIR”
      title: “:house_with_garden: :key: Bienvenu à la maison Nicolouts!”
      timeout: 60
  • id: notify_sarah_ouvrir_garage_porte
    alias: “[:mega:] Envoyer une notification à Sarah pour ouvrir la porte de garage”
    trigger:
    platform: state
    entity_id: person.sarah
    from: not_home
    to: home
    action:

    • service: notify.mobile_app_sarah_iphone
      data:
      message: “Voulez-vous ouvrir la porte de garage”
      data:
      actions:
      - action: “OUVRIR”
      title: “:house_with_garden: :key: Bienvenu à la maison Sarah!”
      timeout: 60
  • id: notify_ana_ouvrir_garage_porte
    alias: “[:mega:] Envoyer une notification à Ana pour ouvrir la porte de garage”
    trigger:
    platform: state
    entity_id: person.ana
    from: not_home
    to: home
    action:

    • service: notify.mobile_app_iphone_de_ana
      data:
      message: “Voulez-vous ouvrir la porte de garage”
      data:
      actions:
      - action: “OUVRIR”
      title: “:house_with_garden: :key: Bienvenu à la maison Ana!”
      timeout: 60
  • id: notify_ouvrir_garage_porte
    alias: “[:mega::calling:] Notification pour ouvrir la porte du garage”
    trigger:

    • platform: event
      event_type: mobile_app_notification_action
      event_data:
      action: “OUVRIR”
      action:
    • service: switch.turn_on
      data: {}
      entity_id: switch.porte_garage_distance

config.yaml

push:
categories:
- name: Ouvrir la porte de garage
identifier: ‘ouvrir_porte_garage’
actions:
- identifier: ‘OUVRIR_PORTE_GARAGE’
title: “Ouvrir la porte de garage”
activationMode: ‘background’
authenticationRequired: false # Require FaceID / TouchID
destructive: false
behavior: ‘default’

Can you do me a favour and post your code properly formatted? No. 11 of the FAQ will help you..
To do this, use the </> button in the text editor window:

and paste your code between the backticks.

You can split the configuration.yaml (I did so) but I think you need the ios: key. Look at the companion app docs:

Here’s a fully built example configuration:


ios:
  push:
    categories:
      - name: Alarm
        identifier: 'alarm'
        actions:
          - identifier: 'SOUND_ALARM'
            title: 'Sound Alarm'
            activationMode: 'background'
            authenticationRequired: true
            destructive: true
            behavior: 'default'
          - identifier: 'SILENCE_ALARM'
            title: 'Silence Alarm'
            activationMode: 'background'
            authenticationRequired: true
            destructive: false
            behavior: 'textInput'
            textInputButtonTitle: 'Silencio!'
            textInputPlaceholder: 'Placeholder'

Hello pedolsky,

Sorry I didn’t know how to do.
I try to split my file, but maybe you can also give me a good idea how to split better the yaml file

Thank you again

Nicolouts

automation.yaml

- id: notify_nicolas_ouvrir_garage_porte
  alias: "[📣] Envoyer une notification à Nicolas pour ouvrir la porte de garage"
  trigger:
    platform: state
    entity_id: person.nicolouts
    from: not_home
    to: home
  action:
    - service: notify.mobile_app_beskonic_iphone
      data:
        message: "Voulez-vous ouvrir la porte de garage"
        data:
          actions:
            - action: "OUVRIR"
              title: "🏡 🔑 Bienvenu à la maison Nicolouts!"
              timeout: 60

- id: notify_sarah_ouvrir_garage_porte
  alias: "[📣] Envoyer une notification à Sarah pour ouvrir la porte de garage"
  trigger:
    platform: state
    entity_id: person.sarah
    from: not_home
    to: home
  action:
    - service: notify.mobile_app_sarah_iphone
      data:
        message: "Voulez-vous ouvrir la porte de garage"
        data:
          actions:
            - action: "OUVRIR"
              title: "🏡 🔑 Bienvenu à la maison Sarah!"
              timeout: 60

- id: notify_ana_ouvrir_garage_porte
  alias: "[📣] Envoyer une notification à Ana pour ouvrir la porte de garage"
  trigger:
    platform: state
    entity_id: person.ana
    from: not_home
    to: home
  action:
    - service: notify.mobile_app_iphone_de_ana
      data:
        message: "Voulez-vous ouvrir la porte de garage"
        data:
          actions:
            - action: "OUVRIR"
              title: "🏡 🔑 Bienvenu à la maison Ana!"
              timeout: 60

- id: notify_ouvrir_garage_porte
  alias: "[📣📲] Notification pour ouvrir la porte du garage"
  trigger:
    - platform: event
      event_type: mobile_app_notification_action
      event_data:
        action: "OUVRIR"
  action:
    - service: switch.turn_on
      data: {}
      entity_id: switch.porte_garage_distance

ios.yaml

push:
  categories:
    - name: Ouvrir la porte de garage
      identifier: 'ouvrir_porte_garage'
      actions:
        - identifier: 'OUVRIR_PORTE_GARAGE'
          title: "Ouvrir la porte de garage"
          activationMode: 'background'
          authenticationRequired: false # Require FaceID / TouchID
          destructive: false
          behavior: 'default'

config.yaml

automation: !include_dir_merge_list include/automations/
script: !include_dir_merge_list include/scripts/
notify: !include_dir_merge_list include/notifies/
ios: !include_dir_merge_list include/ios/

Thank you!

Now it becomes clearer. I may be wrong but I wouldn‘t use push notifications as a list. This is what you instruct Home Assistant to handle with when your ios.yaml is included as dir_merge_list.

It‘s not an advice, just my (lazy) point of view: I only use


  !include_dir_named packages


It fits each case for me; almost everything is inside of it. My folder „packages“ has various sub-folders which include all files on a specific topic.

Or - as an similarly easy way - use ios.yaml in the config directory and include it in your configuration.yaml as

ios: !include ios.yaml