I tried getting this working as well, after reinstalling multiple times I finally managed to install the beta and add the integration only to hit a similar (or same) error as you. I thought it was an install error given the initial issues so I restored a backup but I’m back at square one of not having it even appear in the integrations.
Are there any other companies that offer a similar API product as Glowmarkt which is currently supported by HA? Does anyone know of documentation on writing HA integrations? I work as a dev so if there’s nothing in this space that works I might give it a shot when I have time, it has been quite a while since I wrote any python though!
@Eldudemeister Not so far. Although beyond retrying it a couple of times in case it was some random glitch or temporary connectivity issue I haven’t tried anything else yet.
@declan-morris No other companies that I know of (but then my knowledge in this space is limited). There is documentation on integrations at Starting with Development | Home Assistant Developer Docs (home-assistant.io). From the error message I can’t help but wonder whether it’s as basic as something having changed in the Bright API that the current integration hasn’t caught up with. But I don’t know where to look on either end of that to investigate further.
Has a quick play with some of the glow.py code last night, authenticating and retrieving a list of resources worked, didn’t have time to test grabbing actual readings.
Looks like a PR has been submitted to get the integration at least found by HA. I implemented it manually and this allowed it to be found on the integrations page and it found my gas and electricity meters. After that though the sensors doesn’t update and I got the below errors.
2021-08-11 19:27:44 ERROR (MainThread) [homeassistant] Error doing job: Task exception was never retrieved
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 708, in _update_entity_states
await asyncio.gather(*tasks)
File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 451, in async_update_ha_state
self._async_write_ha_state()
File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 498, in _async_write_ha_state
state = self._stringify_state()
File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 470, in _stringify_state
state = self.state
File "/config/custom_components/hildebrandglow/sensor.py", line 112, in state
return self._state["data"][0][1]
IndexError: list index out of range
Hey @Gronda@Eldudemeister@declan-morris
The integration doesn’t work unless you have Glowmarkt hardware because it’s using the API to request realtime usage data, which doesn’t exist if you are going via the DCC because that data is updated every 30 minutes max. I’ve forked that integration and modified it slightly to have it pull the usage so far that day (but of course it will be up to 1 hour off) - you can find that repo and install it via HACS here (EDIT: new repo) Additionally, it has support for the home assistant energy statistics.
The only other company providing a similar API product are n3rgy, however from what I can tell they only update their data every day so it’s not as powerful as Hildebrand’s
This is amazing! Not against buying the CAD but don’t really need it if I can use your integration. All set up so will keep an eye on it and see my energy stats thanks for doing this!
Ah this is fantastic, I’ve quickly added your integration @HandyHat and it appears to be working! Thanks very much for getting this working. I’ve created a quick PR just to update the instructions in case people don’t notice the different URL!
@WhimsySpoon make sure you’ve added the URL https://github.com/HandyHat/ha-hildebrandglow not the unlobito repo
@declan-morris Thank you. Followed your instructions and bingo, all setup. Really looking forward to seeing this as the data starts to flow. @HandyHat - Thanks for your support for the HA Energy Stats.
@HandyHat i have everything set up but for some reason my electricity sensor has gone unavailable around midnight for the past couple of days and I have to re add the integration to get it back. Any ideas on why this is?
I’m also getting the sensor not providing data from midnight. I’ll try rebooting and see what happens.
One other question. In the Bright app I can see that both the electric and gas meters are present (under the Settings → Verified Meters section. However only the electric meter is providing data in the App. when Originally setup in HA only the Electric meter readings appear. Is there any other setting that is required to get gas data to flow or am i restricted to Electric data only?
Once again this is already a big step forward from where I was so happy to help in any testing and/or problem solving.