-
-
Notifications
You must be signed in to change notification settings - Fork 29.7k
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
Add IoTaWatt integration #55364
Add IoTaWatt integration #55364
Conversation
raise UpdateFailed("Connection failed") from err | ||
|
||
if not is_authenticated: | ||
raise UpdateFailed("Authentication error") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A future improvement would be to raise ConfigEntryAuthFailed
and start a reauth config flow.
https://developers.home-assistant.io/docs/config_entries_config_flow_handler#reauthentication
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good! If we add a test for removing an output sensor, I think this is ready. 👍
Co-authored-by: Paulus Schoutsen <balloob@gmail.com>
It is very unfortunate that no unique id are created for output sensors. Makes for much easier integration and allow to easily modify outputs on the iotawatt without having to modify everything in HA and lose history in the process. |
Unique IDs for output sensors require a IoTaWatt firmware upgrade. It's being worked on by IoTaWatt. |
I've always dealt with outputs the same as inputs. Or is this new version of the integration relying on another data from the iotawatt? |
Output sensors have no unique stable identifiers. Input has channels which can't change. Before you go mention name… that's not stable. |
Yes, as soon as you replied I guessed that's what you wanted to do. Make sense. I have made a lot of changes to the iotawatt HACS integration, to support calculating import/export data with the energy screen. Right now, the iotawatt code can't do that at all. I hope I can submit this very soon. |
Sorry for hijacking this ; but have only a STATE_CLASS_TOTAL_INCREASING is very limiting. A solar read will read negative and keeps reducing ; HA can't detect rollover. Having either a generic STATE_CLASS_TOTAL_MONOTONIC would be preferable. |
Please create an issue instead and describe the problem. We don't want discussion in PRs after they are merged. Thanks! |
Breaking change
Proposed change
Add a new integration to support the IoTaWatt Energy device
Type of change
Additional information
Checklist
black --fast homeassistant tests
)If user exposed functionality or configuration variables are added/changed:
If the code communicates with devices, web services, or third-party tools:
Updated and included derived files by running:
python3 -m script.hassfest
.requirements_all.txt
.Updated by running
python3 -m script.gen_requirements_all
..coveragerc
.The integration reached or maintains the following Integration Quality Scale:
To help with the load of incoming pull requests: