evcc-io / evcc

Sonne tanken ☀️🚘
https://evcc.io
MIT License
3.48k stars 641 forks source link

evcc CLI calls interfere with mqtt-API status #16808

Closed MaStr closed 1 hour ago

MaStr commented 3 hours ago

Describe the bug

With enabled mqtt option, calling evcc from the command line like „evcc chargers“ generate a representation in the mqtt topics. While evcc itself is running, the cli called evcc changes the evcc/status topics to offline after ending. The status is now wrong, because the running daemon does not refresh the topic during runtime.

Expected behavior is, that evcc cli does not use mqtt api during execution.

Steps to reproduce

  1. enable mqtt in evcc.yaml
  2. create some kind of listener on evcc/status for viewing the values
  3. start evcc daemon
  4. Run evcc with a CLI option, like evcc charger
  5. Review content of evcc/status

Configuration details

[…]

mqtt:
  broker: mqtt-server:1883
  topic:evcc # root topic for publishing, set empty to disable
  user: evcc
  password: password

[…]

Log details

Not needed

What type of operating system are you running?

Linux

Nightly build

Version

0.130.13

andig commented 2 hours ago

I see your point. It's not an obvious fix though- not sure we can/want to change this given how low the impact is.

MaStr commented 2 hours ago

Understood. I came across this issue while running a demo instance for testing the interaction between https://github.com/muexxl/batcontrol .

During normal operation, that issue is not a big thing.