Coordinator uses device.status from list response instead of fetching fresh data #6
Labels
No labels
blocked:commit-ready-failed
blocked:gate-fetch
blocked:gate-lint
blocked:gate-plan
blocked:gate-research
blocked:needs-decision
blocked:needs-human
blocked:no-changes
blocked:verify-failed
bug
deferred
feature-request
in-progress
needs-decompose
needs-triage
quickfix
security/medium
triage-approved
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
Mark/yeedi_awmbuild#6
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Severity: Low (stale data risk)
File:
custom_components/yeedi/coordinator.py, lines 36-37Issue: During
_async_update_data, when a device in the list response already has astatusfield, the coordinator uses that cached status directly and skips fetching fresh status from the API:The device list endpoint may return status that is stale — it could be minutes old or simply less detailed than
async_get_device_status. This means the vacuum entity may show outdated battery, state, or fan speed until the device list happens to return a fresh status.Fix: Always call
async_get_device_statusfor each device. If that fails, fall back to thedevice.statusfrom the list response as a cache.Alternatively, document this behavior clearly so users understand that status freshness depends on the device list response.
Fixed in commit. Closing.