Description
PROBLEM DESCRIPTION
A clear and concise description of what the problem is.
The prometheus metrics energy_power_kilowatts_daily
and energy_power_kilowatts_total
report the number of kilowatt hours on the Sonoff S31 rather than kilowatts, as implied by the metric name.
REQUESTED INFORMATION
Make sure your have performed every step and checked the applicable boxes before submitting your issue. Thank you!
- Read the Contributing Guide and Policy and the Code of ConductSearched the problem in issuesSearched the problem in discussionsSearched the problem in the docsSearched the problem in the chatDevice used (e.g., Sonoff Basic): Sonoff S31Tasmota binary firmware version number used: 12.1.1
- Pre-compiled
- Self-compiled
Flashing tools used: TasmotizerProvide the output of command:Backlog Template; Module; GPIO 255
:
Configuration output here:
19:57:02.435 RSL: RESULT = {"NAME":"Generic","GPIO":[1,1,1,1,1,1,1,1,1,1,1,1,1,1],"FLAG":0,"BASE":18}
19:57:02.659 RSL: RESULT = {"Module":{"41":"Sonoff S31"}}
19:57:02.875 RSL: RESULT = {"GPIO0":{"32":"Button1"},"GPIO1":{"3072":"CSE7766 Tx"},"GPIO2":{"0":"None"},"GPIO3":{"3104":"CSE7766 Rx"},"GPIO4":{"0":"None"},"GPIO5":{"0":"None"},"GPIO9":{"0":"None"},"GPIO10":{"0":"None"},"GPIO12":{"224":"Relay1"},"GPIO13":{"320":"Led_i1"},"GPIO14":{"0":"None"},"GPIO15":{"0":"None"},"GPIO16":{"0":"None"},"GPIO17":{"0":"None"}}
- If using rules, provide the output of this command:
Backlog Rule1; Rule2; Rule3
:
Rules output here:
- Provide the output of this command:
Status 0
:
- Set
weblog
to 4 and then, when you experience your issue, provide the output of the Console log:
Console output here:
TO REPRODUCE
Steps to reproduce the behavior:
Enable prometheus metrics during compilation and visit the /metrics endpoint.
EXPECTED BEHAVIOUR
A clear and concise description of what you expected to happen.
The metric names should match the units of the reported values. These metrics, on the S31, should be named energy_power_kilowatt_hours_daily
and energy_power_kilowatt_hours_total
.
I haven't looked into any other power monitoring devices that report these metrics. Assuming that other devices are reporting kilowatts rather than kilowatt hours, the best approach is likely to add two new metrics with the proposed names.
SCREENSHOTS
If applicable, add screenshots to help explain your problem.
ADDITIONAL CONTEXT
Add any other context about the problem here.
(Please, remember to close the issue when the problem has been addressed)
Activity
subtlepseudonym commentedon Sep 17, 2023
This issue can be fixed on the prometheus side with metric relabeling, so this issue is a relatively high effort change for low reward, but I figured it was worth documenting.
Jason2866 commentedon Sep 24, 2023
@subtlepseudonym Would you add to the Documentation? It is Open Source too. Just klick the sheet with the pencil in the upper right corner.
subtlepseudonym commentedon Sep 24, 2023
Can do -- tasmota/docs#1283