Hi ,
I am trying to clean up my code and also getting ready for the breaking change on mqtt syntax in the future 2022.12.0.
I merged all my MQTT stuff in mqtt.yaml like the example below
My mqtt.yaml
# SENSORI MQTT
sensor:
# Sensori T & H Shelly
- name: "Temperatura Studio"
state_topic: "shellies/SensoreHstudio/sensor/temperature"
value_template: "{{ value }}"
unit_of_measurement: "°C"
icon: mdi:thermometer
# SWITCH MQTT
switch:
#Roomba Switch
- name: "Roomba"
command_topic: "roomba/commands"
payload_on: "start"
payload_off: "stop"
in my config.yaml I added mqtt: !include mqtt.yaml and always seems to work correctly
The problem is that I have also this in my config .
sensor: !include sensor.yaml
mqtt: !include mqtt.yaml
switch: !include switch.yam
Can switch coexist in MQTT and a separate switch.yaml?
Even if I changed MQTT configuration removing - platform:mqtt as requested by 2022.12.0. new breaking changes I keep receiving an error that a " manually configurated sensor mqtt under platform sensor " still exist , but I can’t find it .
this is my sensor.yaml
language: it
forecast:
- 0
hourly_forecast:
- 0
- 1
monitored_conditions:
- summary
- icon
- temperature
- sunrise_time
- sunset_time
- alerts
- platform: time_date
display_options:
- 'time'
- 'date'
#System monitor sensor
- platform: systemmonitor
resources:
- type: disk_use_percent
arg: /
- type: memory_free
- type: processor_use
- type: last_boot
#Life 360 sensor
- platform: template
sensors:
andrea_phone:
friendly_name: "Batteria Andrea"
unit_of_measurement: '%'
value_template: "{{ state_attr('device_tracker.life360', 'battery') }}"
device_class: battery
- platform: template
sensors:
elisa_phone:
friendly_name: "Batteria Elisa"
unit_of_measurement: '%'
value_template: "{{ state_attr('device_tracker.life360', 'battery') }}"
device_class: battery
- platform: template
sensors:
neri_phone:
friendly_name: "Batteria Neri"
unit_of_measurement: '%'
value_template: "{{ state_attr('device_tracker.life360', 'battery') }}"
device_class: battery
- platform: template
sensors:
shelly_em_corrente_ch1:
friendly_name: "Corrente casa"
value_template: '{{ (states("sensor.Assorbimento_casa")|float / states("sensor.tensione_condominio")|float)|float|round(1) }}'
unit_of_measurement: "Ampere"
icon_template: mdi:current-ac
shelly_em_corrente_ch2:
friendly_name: "Corrente condominio"
value_template: '{{ (states("sensor.Assorbimento_condominio")|float / states("sensor.tensione_condominio")|float)|float|round(1) }}'
unit_of_measurement: "Ampere"
icon_template: mdi:current-ac
- platform: wundergroundpws
api_key:
pws_id:
numeric_precision: decimal
monitored_conditions:
- temp
- obsTimeLocal
- humidity
- dewpt
- heatIndex
- stationID
- winddir
- windChill
- precipTotal
- precipRate
- pressure
- windGust
- windSpeed
- precip_1d
- precip_2d
- precip_3d
- precip_4d
- precip_chance_1d
- temp_high_1d
- temp_low_1d
- weather_1d
- weather_2d
- weather_3d
- weather_4d
- platform: template
sensors:
my_wupws_humidity:
unit_of_measurement: "%"
value_template: "{{states('sensor.wupws_humidity') | int }}"
- platform: filesize
file_paths:
- /config/home-assistant_v2.db
- platform: sun2
monitored_conditions:
- sunrise
- sunset
- sun_phase
The configuration check is passed but I still receiving the repair alert regarding the MQTT breaking what I am missing?
Thank you
Andrea