MQTT Repair warning after upgrade to 2022.9.4

I need some help as I don’t understand how this works now.

Some time ago I built a Pool Water Temperature monitor by following the instructions in this document

The Main reason I liked it in the first place was it was compatible with HA and there was the code already written to enter into my configuration.yaml.
This was the code from the document.

mqtt:
  broker: YOUR_POOL_PI_IP
  port: 1883
  client_id: pool-temperature
  username: mqtt
  password: YOUR_POOL_PI_PASSWORD
  
sensor:
  - platform: mqtt
    state_topic: "pool/temperature"
    name: "Pool Temperature"
    unit_of_measurement: "C"

The only code I can fine in my configuration.yaml now is

# mqtt    
  - platform: mqtt
    state_topic: "pool/temperature"
    name: "Pool Temperature"
    unit_of_measurement: "C"

It has worked fine and still is but now I get this repair warning
image
but I do have this integration in my Devices & Services
image
Which I vaguely remember appearing at some stage but don’t know how or why. My memory is not what it use to be.

When I click on configure I get

Could someone enlighten me on what I need to do to fix this please.
Thank you

first you need to configure mqtt for that watch this video mqtt set up

then on your configuration should be like this

mqtt:
  sensor: 
    - name: "Pool Temperature"
      state_topic: "pool/temperature"
      unit_of_measurement: "C"

read the mqtt info click here

2 Likes

The “mqtt:” config section was there because at one time the mqtt broker configuration was configured in yaml. That has since been moved to UI config only so that section is no longer needed so you likely removed it then.

the last section (with mqtt at the beginning) is the actual sensor configuration. Somewhere on a line above there somewhere you will have “sensor:” setting up that code as an mqtt sensor.

now all mqtt stuff goes under the “mqtt:” header (just like all sensors go under the “sensor:” header, etc). Yes, it makes it a bit confusing if you’ve been here for while. Or at all since this question has been asked a hundred times in the last couple of weeks.

so you will now have:

mqtt:
  binary_sensor:
    - name: binary_sensor_1
      .
    - name: binary_sensor_2
      .
  sensor:
    - name: sensor_1
      .
    - name: sensor_2
      .
  switch:
    - name: switch_1
      .
    - name: switch_2
  cover:
    etc.
    etc.
1 Like