-
Notifications
You must be signed in to change notification settings - Fork 20
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
Support for new Home Assistant Energy Managment and Stats #16
Comments
I'm currently figuring out how to start with this |
In case you had not seen this, https://developers.home-assistant.io/blog/2021/08/16/state_class_total/ , looks like it would help for this.Adam |
Love your work and add-on so far. To add to @adam-olson URL above, here is some additional Home Assistant documentation on the sensor entity updates for long term statistics capture. https://www.home-assistant.io/more-info/statistics/ https://developers.home-assistant.io/docs/core/entity/sensor#long-term-statistics Let me know if you need someone to help test this out if you ever get around to it. |
the energy dashboard is looking for kWh and fpl comes in as KWH maybe the difference |
@dotKrad I've made substantial changes to the sensors. I'd like to make sure we are aligned in this. Maybe you would want to try or evaluate the code before I submit? It's going to be about 2 more days as I've just made changes and I must wait for the values to level out due to the new last_reset which were just implemented in sensors relating to energy consumption. I'd prefer to make required changes sooner rather than later before I push patches. https://github.com/adamoutler/hass-fpl/tree/master/custom_components/fpl |
thank you for working on it i would be happy to look at it but still fairly new at this how do i add this to my ha, |
@kzelnick for now you can remove the existing integration, then in a terminal, It would be preferred to wait for official support as this is all up in the air right now, but you can do this if you'd like to try bleeding edge. |
Can't seem to be able to copy the files to test? Getting a not found error. Something I'm doing wrong? |
I committed so it should be available when/if the author merges it. It's a significant change so be patient. |
Updated with new changes through HACS. Removed integration to get new sensors but authentication is failing. |
I am having this issue too. Here is the error in the logs. This error originated from a custom integration. Logger: aiohttp.server Error handling request |
Ok. Looks like only people with accounts configured to handle solar would have net delivered and net received. I'll add a try:except: there. |
This is intended to fix dotKrad#16 .
I'm working on it
|
Thanks @dotKrad . I am not able to handle this. Don't take my patch. |
Oh, good, I didn't pull request it. |
I'm having this problem too. @adamoutler mentioned that the issue is "for only people with accounts configured to handle solar". I don't have solar capability. Is there a way to reconfigure the FPL account to un-configure solar as a means to get around this error? When I first setup HA and this integration in June everything worked fine, so I'm assuming the problem was a change between then and now. |
Wish I had the skills to help make this happen, but very willing to test. Working with the energy dashboard would be amazing. |
That's my belief. I don't know @dotKrad says he's on it, dog gone it, don't rush perfection. The accounts which can return power to the grid apparently have additional values which are causing a null for those who don't. I was going to put something to handle it, but mr. kiloRad says he was going to handle it. Should I handle it @dotKrad ? |
From what I can see, it looks like fplApi.py needs the new |
@adamoutler Thanks. To get the integration working again, I have added two if statements before the block of code which produces the error. This will take care of the problem for the short term.
|
Since you confirmed operation, I recommend submitting a pull request. kRad can take it or leave it. You can edit within the browser. It just works for me so I can't really take your account type into account. |
If it helps, i added the code above to my install, works now. |
Mine seems to be working as well with the new code and the extra IF statements, however I get this error in my log every so often.
|
Yeah. That's a weird problem I see as well. It's like sometimes fplapi is missing data. |
This was working perfectly, but it broke during the last commit where the relevant |
had the same issue, removing the integration from HASS and HACS, restarting HASS, reinstalling and restarting fixed it. |
That doesn't change the fact that the code necessary for identifying the meter type was commented out. I know, because I'm the one who added it and brought energy system support to this addon. |
oh gotcha, I haven't had time to check/re-setup the energy monitoring stuff yet. I saw the sensors on my dashboard again and assumed it was working. Thanks for your work on adding energy system support! Hope it works again soon. |
Checking in to see if there was any work being done to update this to work with the energy dashboard. I saw a comment that there was a refactor going on. @dotKrad |
What's not working? Why is this still open? |
I’m getting last_reset errors in the log because it has been deprecated and is no longer valid to set it on this state type. It doesn’t happen until the end of the month, then the data is no longer valid and it starts throwing the error. The new type of ‘total_increasing’ sets its own last_reset. Or at least that’s my understanding from the error. |
`Logger: homeassistant.components.sensor Entity sensor.fpl_498081442_daily_usage_kwh (<class 'custom_components.fpl.sensor_DailyUsageSensor.FplDailyUsageKWHSensor'>) with state_class total_increasing has set last_reset. Setting last_reset for entities with state_class other than 'total' is not supported. Please update your configuration if state_class is manually configured, otherwise report it to the custom integration author. ` |
Created pull request #49 with changes that should make all the daily kWH and monthly stats usable in the energy dashboard. Please wait a few days before accepting in case it doesn't work like I expect. |
My fork has been updated with code is working for reading the daily received reading and daily delivered reading (new sensors) |
RE: Support for new Home Assistant Energy Managment and Stats #16
Thank you for all the work on this! Can’t wait to try it. |
Is your feature request related to a problem? Please describe.
Would like to add support for new Home Assistant Energy Management functions.
https://www.home-assistant.io/blog/2021/08/04/home-energy-management/
Describe the solution you'd like
Support for the new statistics functions, seems like we would just need to add a few properties to the sensors. Not sure on the pricing and pricing projections can be worked in as of yet. https://developers.home-assistant.io/docs/core/entity/sensor/
Describe alternatives you've considered
A clear and concise description of any alternative solutions or features you've considered.
Additional context
https://www.home-assistant.io/docs/energy/
The text was updated successfully, but these errors were encountered: