bertouttier / flukso-hacs Goto Github PK
View Code? Open in Web Editor NEWFlukso energy monitoring for HACS
License: MIT License
Flukso energy monitoring for HACS
License: MIT License
After upgrading to 1.0.9 (or 1.0.10), Home Assistant (2022.11.5) complains about duplicate id for all Flukso sensors:
hass_1 | 2022-12-03 19:18:18.753 ERROR (MainThread) [homeassistant.components.sensor] Platform flukso does not generate unique IDs. ID 688d2bdab6d733ee02ff88b4eadd95f5_538e5b386f0415a1fa704ba7d4de1edc_gauge is already used by sensor.electricity_electricity_gauge - ignoring sensor.electricity_electricity_gauge
hass_1 | 2022-12-03 19:18:18.761 ERROR (MainThread) [homeassistant.components.sensor] Platform flukso does not generate unique IDs. ID 688d2bdab6d733ee02ff88b4eadd95f5_538e5b386f0415a1fa704ba7d4de1edc_counter is already used by sensor.electricity_electricity_counter - ignoring sensor.electricity_electricity_counter
hass_1 | 2022-12-03 19:18:18.764 ERROR (MainThread) [homeassistant.components.sensor] Platform flukso does not generate unique IDs. ID 688d2bdab6d733ee02ff88b4eadd95f5_c60205b98f6f20ff427fc5cba2ecb916_gauge is already used by sensor.water_water_gauge - ignoring sensor.water_water_gauge
hass_1 | 2022-12-03 19:18:18.767 ERROR (MainThread) [homeassistant.components.sensor] Platform flukso does not generate unique IDs. ID 688d2bdab6d733ee02ff88b4eadd95f5_c60205b98f6f20ff427fc5cba2ecb916_counter is already used by sensor.water_water_counter - ignoring sensor.water_water_counter
hass_1 | 2022-12-03 19:18:18.771 ERROR (MainThread) [homeassistant.components.sensor] Platform flukso does not generate unique IDs. ID 688d2bdab6d733ee02ff88b4eadd95f5_3b9b4607e090eaa86eb654f1cc37c123_gauge is already used by sensor.gas_gas_gauge - ignoring sensor.gas_gas_gauge
hass_1 | 2022-12-03 19:18:18.774 ERROR (MainThread) [homeassistant.components.sensor] Platform flukso does not generate unique IDs. ID 688d2bdab6d733ee02ff88b4eadd95f5_3b9b4607e090eaa86eb654f1cc37c123_counter is already used by sensor.gas_gas_counter - ignoring sensor.gas_gas_counter
(messages repeated numerous times)
Messages disappear when downgrading to 1.0.8.
It seems we have the wrong units for the Gas sensor on the FLM02A.
The MQTT stream shows data in Liters / Liters/Day:
/sensor/3b9b4607e090eaa86eb654f1cc37c123/counter [1654440504,45287000,"L"]
/sensor/3b9b4607e090eaa86eb654f1cc37c123/gauge [1654440504,130252,"L/day"]
/sensor/3b9b4607e090eaa86eb654f1cc37c123/counter [1654447813,45287100,"L"]
/sensor/3b9b4607e090eaa86eb654f1cc37c123/gauge [1654447813,1184,"L/day"]
These are 2 consecutive messages, we have 100L difference, which matches my setup (my gas meter gives 1 pulse per 0,1 cubic meter)
But in Home Assistant I am getting cubic meters instead of liters!
I guess this is coming from
(As such I am fine with cubic meters for the sensor, but we should scale the data ;) )
Just installed your new integration for Home Assistant. Got it working and entered Device-Hashes (I think you mean the "Sensor Identification", don't you?). But nothing is shown in Home Assistant. Only the Integration-Page shows, that I configured it. Does it work with my Flukso-Model FLM02A?
Any Hints?
Thank you.
The latest Home Assistant version 2022.6 introduced a new format for mqtt sensors. This Flukso add-on now produces the following warning in logs:
Manually configured MQTT sensor(s) found under platform key 'sensor', please move to the mqtt integration key, see https://www.home-assistant.io/integrations/sensor.mqtt/#new_format
As described in the documentation https://www.home-assistant.io/integrations/sensor.mqtt/#new_format,
the previous method is now deprecated:
sensor:
- platform: mqtt
state_topic: "home/bedroom/temperature"
Can you update discovery.py to use the new method?
# Example configuration.yaml entry
mqtt:
sensor:
- state_topic: "home/bedroom/temperature"
Note - it will still work using the old method, however at some point the old method will cease to work in future HA releases.
Thanks
Hi,
Home Assistant 2022.4.3
Flukso 1.0.6
Device: FLM02B, firmware 250
Following the instructions, I added a MQTT bridge which is working. In the mosquitto broker I can listen to topic /device/6bbbee8xxxxxxxxxxxxxxxcdfc0c1/config/sensor and get feedback.
However when I register the device hash (not the sensor hash) in the Flukso integration, I get the error "Failed to set up"
_This error originated from a custom integration.
Logger: homeassistant.config_entries
Source: custom_components/flukso/discovery.py:490
Integration: Flukso (documentation, issues)
First occurred: 20:26:51 (1 occurrences)
flukso.log
Last logged: 20:26:51
Error setting up entry Flukso 6bbbee8xxxxxxxxxxxxxxxcdfc0c1 for flukso
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/config_entries.py", line 335, in async_setup
result = await component.async_setup_entry(hass, self)
File "/config/custom_components/flukso/init.py", line 26, in async_setup_entry
await async_discover_device(hass, entry)
File "/config/custom_components/flukso/discovery.py", line 490, in async_discover_device
if len(pending) == 1 and config_futures["kube"] == pending[0]:
TypeError: 'set' object is not subscriptable_
Line 490 in /config/custom_components/flukso/discovery.py is this one:
if len(pending) == 1 and config_futures["kube"] == pending[0]:
_LOGGER.debug("kube config pending, FLM02?")
I have no Kube setup.
In the attached log, the sensors are present, so the connection is made I think.
Any help is appreciated.
Regards,
Sam
Hi,
Somehow this integration is returning errors for me. I have a Flukso FLM02A. Below the details and at the end the error messages I'm getting.
I've implemented the integration via HACS, it's version 1.0.4:
I also posted a conversation on the Flukso forum here about this issue, you can see my post of "10/02/2022 - 18:53" and later.
My Mosquitto broker Add-On is also the latest version 6.0.1 and has the following config:
logins: []
customize:
active: true
folder: mosquitto
certfile: fullchain.pem
keyfile: privkey.pem
require_certificate: false
Checking the broker with MQTT Explorer shows the data from Flukso coming in:
I've then used the device hash, see green arrow in screenshot, to add the Flukso integration. It says that it's created but the logs return error messages. I've activated the Debug logger for the Flukso integration and this is the output (note that the device has has been anonymized with the x's at the end):
2022-02-12 09:21:09 INFO (MainThread) [custom_components.flukso.config_flow] Creating new entry for Flukso d4599ea546cb8aacff3bb18bxxxxxxxx
2022-02-12 09:21:13 DEBUG (MainThread) [custom_components.flukso.discovery] test tap pending, FLM02?
2022-02-12 09:21:13 DEBUG (MainThread) [custom_components.flukso.discovery] all configs and tap received
2022-02-12 09:21:13 ERROR (MainThread) [homeassistant.components.binary_sensor] Error while setting up flukso platform for binary_sensor
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 249, in _async_setup_platform
await asyncio.shield(task)
File "/config/custom_components/flukso/binary_sensor.py", line 10, in async_setup_entry
configs = get_entities_for_platform(
File "/config/custom_components/flukso/discovery.py", line 443, in get_entities_for_platform
entities.extend(_get_binary_sensor_entities(entry_data, device_info))
File "/config/custom_components/flukso/discovery.py", line 287, in _get_binary_sensor_entities
for sensor in entry_data["sensor"].values():
KeyError: 'sensor'
2022-02-12 09:21:13 ERROR (MainThread) [homeassistant.components.sensor] Error while setting up flukso platform for sensor
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 249, in _async_setup_platform
await asyncio.shield(task)
File "/config/custom_components/flukso/sensor.py", line 10, in async_setup_entry
configs = get_entities_for_platform("sensor", hass.data[DOMAIN][entry.entry_id])
File "/config/custom_components/flukso/discovery.py", line 445, in get_entities_for_platform
entities.extend(_get_sensor_entities(entry_data, device_info))
File "/config/custom_components/flukso/discovery.py", line 401, in _get_sensor_entities
for sensor in entry_data["sensor"].values():
KeyError: 'sensor'
Anything I'm doing wrong? Any additional information you might need for this issue to find the source of the error? Just let me know and I'll provide it or test it.
Many thanks in advance.
Hi, I updated to 2022.03 today and this stopped working with the following error in the logs:
This error originated from a custom integration.
Logger: homeassistant.config_entries
Source: custom_components/flukso/discovery.py:479
Integration: Flukso (documentation, issues)
First occurred: 12:00:31 PM (1 occurrences)
Last logged: 12:00:31 PM
Error setting up entry Flukso fe779fdxxxxxxxxxxxxx for flukso
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/config_entries.py", line 335, in async_setup
result = await component.async_setup_entry(hass, self)
File "/config/custom_components/flukso/init.py", line 26, in async_setup_entry
await async_discover_device(hass, entry)
File "/config/custom_components/flukso/discovery.py", line 479, in async_discover_device
sub_state = await subscription.async_subscribe_topics(
TypeError: async_subscribe_topics() takes 2 positional arguments but 3 were given
Hi,
After updating to 1.0.9 via HACS I have the same problem as I had earlier this week when I manually copied the changed files to the custom_components/flukso folder on my homeassistant.
The entities become unavailable.
This is what I see on my dashboard: " This entity is no longer being provided by the flukso integration. If the entity is no longer in use, delete it in settings. "
I deleted the integration and added it again. This worked fine, but no new entities were added.
I rolled back to 1.0.8 and everything worked again (including the warning about the MQTT syntax)
Regards,
Sam
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.