double-take icon indicating copy to clipboard operation
double-take copied to clipboard

[BUG] dots or space in ha user name break mqtt sensor discovery topic

Open hugalafutro opened this issue 2 years ago • 2 comments

Describe the bug HA log complains about illegal mqtt discovery:

Received message on illegal discovery topic 'homeassistant/sensor/double-take/c.g.b.-spender/config'. The topic contains not allowed characters. For more information see https://www.home-assistant.io/docs/mqtt/discovery/#discovery-topic

I assume double-take pulls this name from ha (ha user is C.G.B. Spender), as I can't find the name anywhere in double-take, where the only trained face is called David.

Version of Double Take v1.12.1-35874f3

Expected behavior I'm not really sure, both the "unknown" and "david" sensors work ok, I just always worry about warnings in logs and people then say just ignore it it's just warning, but if it's no issue then why warn about it, but I digress.

Screenshots n/a

Hardware

  • OS: Ubuntu 22.04.1, docker 20.10.17, docker compose v2.10.2
  • Browser Chrome

Additional context I've got nothing.

hugalafutro avatar Sep 09 '22 11:09 hugalafutro

Thanks for reporting this. I can look into it more. When you go to the Train page on Double Take, what names do you have in the dropdown? This error is making me think the image on the Double Take side is being recognized with the name c.g.b.-spender and then is trying to update the MQTT topic using that name.

2022-09-12 at 13 18 21@2x

jakowenko avatar Sep 12 '22 17:09 jakowenko

Hi, at the moment the only name in the dropdown is david as I was following the readme instructions and it just so happens to be my name as well. At some point during setup I might have trained and then deleted a person named C.G.B. Spender so perhaps some leftover? As at first I followed some older tutorial where I manually added the mqtt sensors, then found out they're autodiscovered now so I removed the manual and rebooted ha.

screenshots: image

image

entities detected by HA: image

config:

# Double Take
# Learn more at https://github.com/jakowenko/double-take/#configuration
auth: true

mqtt:
  host: !secret mq_host
  username: !secret mq_user
  password: !secret mq_pass

frigate:
  url: !secret frig_host

detectors:
  compreface:
    url: !secret compre_host
    key: !secret compre_api

detect:
  match:
    confidence: 70
    purge: 168
    min_area: 2500

telemetry: false

time:
  timezone: !secret time_zone

hugalafutro avatar Sep 13 '22 13:09 hugalafutro

am still facing the same problem. Am currently at version 1.13.1

Received message on illegal discovery topic 'homeassistant/sensor/double-take//config'. The topic contains not allowed characters. For more information see https://www.home-assistant.io/docs/mqtt/discovery/#discovery-topic

msolomos avatar Jan 03 '23 19:01 msolomos