arendst / Tasmota

Alternative firmware for ESP8266 and ESP32 based devices with easy configuration using webUI, OTA updates, automation using timers or rules, expandability and entirely local control over MQTT, HTTP, Serial or KNX. Full documentation at
https://tasmota.github.io/docs
GNU General Public License v3.0
21.93k stars 4.76k forks source link

Rule not executed when no connection to configured MQTT. #20371

Closed toszczyp closed 8 months ago

toszczyp commented 8 months ago

Self compiled Tasmota version 13.1.0.2 by Arends (because INA3221) is not in default configuration. When no connection to MQTT configured in Configuration/Configure MQTT then only this line is shown on main scrreen "INA3221 Voltage Current Power" - this is header only - no any additional lines with results. When connection returns all results are displaied as expected. To reproduce it is enougth to replace MQTT IP address in configuration to any IP with no MQTT in configuration. Expected behaviour: display INA3221 results if no connection to MQTT too.

PROBLEM DESCRIPTION

A clear and concise description of what the problem is.

When no connection to MQTT configured in Configuration/Configure MQTT then only this line is shown on main scrreen "INA3221 Voltage Current Power" - this is header only - no any additional lines with results. When connection returns all results are displaied as expected.

REQUESTED INFORMATION

Make sure your have performed every step and checked the applicable boxes before submitting your issue. Thank you!

- [x] If using rules, provide the output of this command: `Backlog Rule1; Rule2; Rule3`:
```lua
  Rules output here:
- [ ] Set `weblog` to 4 and then, when you experience your issue, provide the output of the Console log:
```lua
  Console output here:

TO REPRODUCE

Steps to reproduce the behavior:

To reproduce it is enougth to replace MQTT IP address in configuration to any IP with no MQTT

EXPECTED BEHAVIOUR

A clear and concise description of what you expected to happen.

Expected behaviour: display INA3221 results if no connection to MQTT too.

SCREENSHOTS

If applicable, add screenshots to help explain your problem. Tasmota_error Tasmota_ok

ADDITIONAL CONTEXT

Add any other context about the problem here.

(Please, remember to close the issue when the problem has been addressed)

barbudor commented 8 months ago

Please edit and fill missing required information

barbudor commented 8 months ago

I confirm that there is no dependencies to the MQTT connection in the code Docs have been updated regarding command Sensor100 Please check that you are using the command correctly More details in the PR: https://github.com/arendst/Tasmota/pull/16786

toszczyp commented 8 months ago

I found that issue is not connected to INA3221 but to not executed rule. So now i updated title - Rule not executed when no connection to configured MQTT. See in logs attached - here you see that in tasmota_ok.txt command Sensor100 is executed so all works but when no connection as in tasmota_error.txt then rule is not executed - so expected behavior is to execute rules if no connection to mqtt too.

tasmota_error.txt tasmota_ok.txt

toszczyp commented 8 months ago

I found that in case https://github.com/arendst/Tasmota/issues/7552 ascillato commented on Jan 24, 2020 As designed. SYSTEM#BOOT only triggers if mqtt is on. If you want a trigger for an earlier event prior all the initialization, you can use ON POWER1#BOOT DO ....

so it looks that I have the same case
RUL: SYSTEM#BOOT performs "backlog; Sensor100 1, 0.1, 0.1, 0.1; VoltRes 3;WattRes 2" finally: works as designed :-(