Skip to content
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

Make sure the filtered hourprices get updated every hour. #188

Merged
merged 1 commit into from
Oct 5, 2024

Conversation

Roeland54
Copy link
Collaborator

should fix #186

@Roeland54 Roeland54 merged commit 264d52e into main Oct 5, 2024
4 checks passed
@Pluimvee
Copy link
Contributor

Pluimvee commented Oct 7, 2024

There shouldnt be made an update requestfrom the sensor to the coordinator as:

  1. this update request is now triggered for each sensor, with corresponding update and refilter logic
  2. the DataUpdateCoordinator has its own refresh event from HA

image

See the DataCoordinator construct
image

@Roeland54
Copy link
Collaborator Author

It is needed because the dict of filtered values that are used for calculations need to be updated on the hour mark. But I agree it only should be done once and not for each sensor. The coordinator update to fetch the data is ran with an interval of 60 min but not exacty on the hour. Mostly depends on the startup time of HA or when the integration is reloaded. Feel free to open a PR If you feel you can improve something.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Since v0.5 the sliding-mode stopped updating high/low prices each hour
2 participants