Repository navigation
Add an estimated ready time sensor to Poolside - #1
Open
jaltmayerpizzorno wants to merge 5 commits into
Open
jaltmayerpizzorno wants to merge 5 commits into
jaltmayerpizzorno wants to merge 5 commits into
Conversation
The controller pushes a TemperatureRiseInformation document under each body of water while it heats toward its set point. Its TargetEndDateTime is the prediction the Poolside app shows as "ready in ...". Expose it as a timestamp sensor per body of water. The value is unknown while the controller is still sampling the water temperature (TargetEndDateTime is a 0001-01-01 placeholder), once ActualEndDateTime is set, when the document is missing or malformed, and when no heat-up is in progress. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
- Show a ready time only when the vendor app does: TemperatureState SAMPLED and HeatingEventType NORMAL (no preliminary estimate while sampling, none while maintaining temperature or learning), and only while the target is ahead. A time that passes without a new prediction is cleared at that moment, rather than lingering as "x minutes ago". - Drop the ActualEndDateTime check: the controller clears the document when a heat-up ends, so it's never set on the value read. - Parse the document once per update, accepting a native value or an encoded string, and warn when it can't be parsed, like other JSON fields. - Create the sensor the first time a body of water reports TemperatureRiseInformation, like the chemistry sensors, so bodies without a heater don't get one. Tests first; coverage of the sensor's new code stays complete. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
jaltmayerpizzorno
added a commit
to jaltmayerpizzorno/poolside-official-integration
that referenced
this pull request
Oct 2, 2026
- Show a ready time only when the Poolside app does: TemperatureState SAMPLED and HeatingEventType NORMAL, and only while the target is ahead; a time that passes without a new prediction is cleared at that moment. - Drop the ActualEndDateTime check (the controller clears the document when a heat-up ends). - Parse the document once per update, accepting a native value or an encoded string, with a warning when it can't be parsed. - Create the sensor the first time a body of water reports TemperatureRiseInformation, like the chemistry sensors. - List the sensor in the README. Same change as PoolsideStan/home-assistant-core#1, where it is tested. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
PoolsideStan
approved these changes
Oct 5, 2026
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.
What
This adds an Estimated ready time timestamp sensor for each body of water, for example
sensor.spa_estimated_ready_time. It shows when the controller predicts the water will reach its set point, which is the same prediction the Poolside app shows as "ready in …".The value comes from the body of water's
TemperatureRiseInformationpush, specifically itsTargetEndDateTime. The sensor isunknown:TargetEndDateTimeis the0001-01-01…placeholder;ActualEndDateTimeis set;Why
People want to know when the spa will be ready, for a dashboard or for automations such as notifying guests. The controller already computes this, but the integration doesn't expose it.
Changes
sensor.py: a newPoolsideBodyReadyTimeSensorentity, created alongside the temperature and water-state sensors for each body of water, plus a small parser for the document.const.py: the field and key names. They aren't inaiopoolside.constin 0.1.0, so the comment says to import them from there once they are. That library change is in Add TemperatureRiseInformation field constants aiopoolside#3.strings.json/icons.json: the entity name and icon.Tests
The tests were written first, from payloads captured on a live controller. In
tests/components/poolside/test_sensor.py:test_ready_time_sensor_reflects_temperature_risecovers six cases: a prediction, still sampling, target reached, no target, malformed, and not a document.test_ready_time_sensor_follows_revisionschecks that a revised prediction updates the sensor and that clearing the field resets it.Results:
poolside.Tried on a real system
I ran the same change as a custom component on an Attendant controller. The sensor stayed
unknownwhile the app said "mixing water…". Then it reported the predicted time, matching the app's "ready in" to within a minute, and followed the controller's revisions as heating progressed.The same change is also prepared for PoolsideStan/poolside-official-integration, so it can ship there before the core integration lands.
🤖 Generated with Claude Code