-
Notifications
You must be signed in to change notification settings - Fork 16
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Error starting integration since HA 2023.5 upgrade #42
Comments
IotaWatt is natively supported through a HomeAssistant integration. It was release in the 2021.9 version, and I don't believe we need a custom component to use it. I was using the custom integration until today, but switched to the native because I received the same error like you did. Everything's back to working now! cheers. |
Thanks for your reply here. I like to do the same thing in 2023.4 version (I restored that), and migrate to the "official" iotawatt integration before upgrading HA again. |
tbh, I did the migration to using the official integration AFTER migrating to 2023.5.1. It was pretty straight forward. Please make any backups as needed before doing the below steps in case you encounter data loss of any sorts.
Once I did steps 1-4, all my existing data showed up. I think this should work for you as well. |
Thanks for the help, that worked ! I didn't expect that all sensors and history would be kept. Very smooth switch! |
I fixed this in my fork and added PR to merge it here. The one embedded in HA itself has issues with removed UUIDs so that entities from outputs can't be edited in UI. Switching to native likely renames all sensors. I didn't want to switch. |
@karthikvenkat123, I was also having issues since 2023.5.0. Upgraded to .5.2 which did not resolve. I have followed your steps and it is now working but as @darek-margas points out, the official one does not add in outputs. Using @darek-margas's fork is working for me now. Hope for some collaboration on merging to the official release sometime in the future. I had no idea there were so many versions of this integration floating around! |
The official integration has issues with Inputs, but only in one way: You cannot edit the names/entities, but they actually do show up. I have the "official" integration working with all inputs working - as long as you can accept the names which are generated automatically. The migration was really smooth, just delete the custom integration, reboot, install the "official" integration - and it kept all data and all entities from the custom integration. |
It is mixed problem. First these silly names and inability to set them any other way than in yaml. Then, while inputs are showing up, outputs are hidden. They do appear but HA does not recognize them as sensors from Iotawatt. This is why I haven't found them at first go. It is a mess but one which HA demanded. For HA dev team Iotawatt does not provide sensor with id being unique enough so that to integrate within, this integration had to be screwed up to have no unique IDs. The one here has them. Personally I want them regardless of politics biased fight in HA team. It is politics only as what is documented allows what Iotawatt has just not for Iotawatt. |
Very interesting. As a user, I need my inputs and custom outputs. So the official one would be fine if I was only using my inputs but part of IotaWatt’s brilliance is it’s outputs feature. I export both inputs and outputs to a database too. And the only real way of getting accurate data in the energy dashboard is by using outputs too. Anyway, hope something can be resolved going forward. It clearly works as a HACS component. So I hope they get over any policy stuff and make it work because it’s a brilliant device. |
I updated my fork to backport all the changes from core up to 2024.8 while retaining outputs with unique IDs. I may actually push a PR yet this repo seems dormant, hence unlikely to merge here. I think easiest way is to add my fork into HACS. |
After upgrading to Homassistant 2023.5, this integration no longer works.
The HA log file shows following error:
Logger: homeassistant.config_entries
Source: custom_components/iotawatt/init.py:16
Integration: IoTaWatt
First occurred: 09:05:55 (1 occurrences)
Last logged: 09:05:55
Error setting up entry iotawatt for iotawatt
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/config_entries.py", line 387, in async_setup
result = await component.async_setup_entry(hass, self)
File "/config/custom_components/iotawatt/init.py", line 16, in async_setup_entry
hass.config_entries.async_setup_platforms(entry, PLATFORMS)
AttributeError: 'ConfigEntries' object has no attribute 'async_setup_platforms'
The text was updated successfully, but these errors were encountered: