TibberHome.update_info_and_price_info with parameter to change the resolution of Price_Info#381
Open
Godionplus wants to merge 5 commits intoDanielhiversen:masterfrom
Open
TibberHome.update_info_and_price_info with parameter to change the resolution of Price_Info#381Godionplus wants to merge 5 commits intoDanielhiversen:masterfrom
Godionplus wants to merge 5 commits intoDanielhiversen:masterfrom
Conversation
Add RESOLUTION_QUARTER_HOURLY: Final = "QUARTER_HOURLY"
UPDATE_INFO_PRICE make 'resolution' as parameter
Add parameter in function 'update_info_and_price_info' in order to change the resolution. For compatibly the default value is RESOLUTION_QUARTER_HOURLY. But if necessary, the parameter can also changed to RESOLUTION_HOURLY.
add parameter description of update_info_and_price_info
Owner
|
Why do you need this? You can always aggregate the quarterly prices if needed? |
Add import RESOLUTION_QUARTER_HOURLY
Author
|
Hi Daniel, You ask about the sense of my changes.
Let me know what do you think. beste regards, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The new Tibber API allows to request the Price_Info with the resolution QUARTER_HOURLY or HOURLY. For many reasons it is necessary to change the resolution. But the current implementation of pyTibber requests always only the QUARTER_HOURLY resolution.
This pull request includes the changes to add to the TibberHome.update_info_and_price_info function an 'resolution' parameter. In addition, the new const RESOLUTION_QUARTER_HOURLY has been added. Also the gql_query 'UPDATE_INFO_PRICE' has been changed to add the resolution as parameter.
I hope these changes comes to the master branch, in order to give everyone the possibility to change the resolution in the Price_Info request to the Tibber API.