-
Notifications
You must be signed in to change notification settings - Fork 14
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
Remove total sensors #19
Comments
This repository hasn't seen any activity in a while. I would love to see improvements made to this library and the HA integration (or at least live somewhere where issues and PRs aren't ignored). Even if the official process is slow, forking the custom integration would at least allow people to have reliable IoTaWatt data in HA. I'm happy to help as I can. |
@F13 The HA integration was moved into core, so I believe that other repo is obsolete. |
@llamafilm That's what I'm saying - even if changes to core will be slow (since they're using this library, and getting core to switch to a new fork might take time), users can still benefit from updates if there is a custom integration they can use. |
Best case scenario in my mind is to fork this repo, deal with some of the issues, and get HA core to use the forked repo. But if that's not doable on a realistic time frame, a custom integration that uses the new library would let users (myself included) have a nearly-first-class installation experience through HACS. |
Oh I see what you mean, yeah this repo seems abandoned. I would prefer to focus on improving core, not a custom component. |
Already asked and ignored in #18 :) My point is, don't wait too long for a response. The best way forward is probably a fork and trying to get core to move to said fork. |
Agreed, I came to the same conclusion, see home-assistant/core#65143 (comment).
I think the opposite is true: The accumulated do not use what is known here as _total. They poll the API and sum the value for each period, which is inaccurate since a period might get missed for various reasons (e.g. at restart). Looking at the total is like looking at a good old power meter: It moves continously, and if you miss a read period the change will just be visible in the next period... |
I don't have rights in this repository, but having IotAWatt integration relying on an unmaintained lib is not in my interested either 😅 I probably can create a fork of this in the home-assistant-libs org.
Since the fork will largely be the same, and in that case in a trusted org, I think it should be fairly quick thing to move Core to use the fork. |
Oops, I thought you had rights because I saw some commits by you. I didn't know HA had an org for this but that sounds like the right place for this to live. I'll give Greg some time to respond to my email and then we can transfer ownership to your new repo according to PEP 541. |
So we would be able to publish new releases under the same PyPI project? My intention was to rename by pre- or postfixing the project name with |
the _total sensors should be removed, and the library that output accumulated sensor should be modified too. I added those when the integration sensors didn't exist yet. _total is no longer needed, should be using the integration sensors instead. I've wanted to make that change for a while, but lack of free time always got in the way I'm sorry. |
Yes exactly. That's what happens when a project is abandoned by the owner. @jyavenard no need to apologize, I know everyone is busy! Do you agree with moving this repo under the HA organization so that more people can contribute? |
It's not my repo, so sure. having to get my changes pushed upstream and they officially released was a pain anyway |
@jyavenard we definitely agree on removing the accumulated sensor. This should be done in Core first. Do you have time to create a PR which does that? |
I'll work on it this week-end. |
I've created the fork at https://github.com/home-assistant-libs/iotawattpy at created a 0.1.0 release (tagged the last commit, which seems to be what is on PyPI currently). I'd like the first release to be as thin as possible, so we can easily switch to it from Core side. E.g. just addressing the @llamafilm when do you think we can publish the first release on PyPI from that fork? |
Before requesting ownership transfer on PyPi, we need to make some improvements on the new fork. I guess that |
not quite. accumulated (energy) sensor are perfectly fine to use when you want to get the energy used by a particular device. |
@jyavenard what do you mean? I removed the accumulated sensors in my own fork and the regular |
The new repository is up and running, I've also created a discussion section (which this thread probably should be continue at): home-assistant-libs#2.
I agree, the question is how we fix that exactly. Let's move discussion to the new home (specifically home-assistant-libs#1 in this case). |
As we all agree that the Accumulated sensors should not be used I went ahead and removed them in Home Assistant Core, see home-assistant/core#86611. |
How are you doing the energy dashboard now? Removing accumulated values has broken my energy dashboard, the release notes say to use integrators, but I can't get integrators from the IoTaWatt to work with Home Assistant? They do not appear under the integration after adding them and reloading the integration |
@jay-oswald In HA, outputs and integrators do not appear in the UI to be associated with the IotaWatt device because they lack Unique IDs. I have a PR to fix that: home-assistant/core#86834 You should still be able to see these |
That they do not appear has nothing to do with the lack of unique_id. |
When I first set up iotawatt last year, each sensor had the |
No. The sensors ending with For an energy sensor to show in the energy setup it needs 3 attributes: |
More technically, @jyavenard, sensors do not need a |
I found my way here after having trouble setting up IotaWatt in Home Assistant. After a lot of reading, I've come to the conclusion that the
Accumulated
sensors in Home Assistant should never be used. They cause wildly inaccurate data in the HA energy dashboard. According to Bob, IotaWatt's integration feature makes this obsolete because:The
Accumulated
sensors in HA are known here as_total
. So I suggest removing all these_total
sensors, essentially reverting 4262ab2. If there is no dissent, I'll work on a PR for this and also for the HA integration.The text was updated successfully, but these errors were encountered: