From 3fe6427c63b65beae2934d0ad3c865bc3ee5bce6 Mon Sep 17 00:00:00 2001 From: firstmate crewmate Date: Fri, 17 Jul 2026 07:35:12 +1000 Subject: [PATCH] docs(teslemetry): correct find_authorized_clients reliability claim The docstring and docs/teslemetry.md characterized the cloud authorized-clients check as "best-effort" with an implied staleness concern. The repo's own history shows the one confirmed anomaly (an intermittent null response body) was already root-caused and attributed to the Teslemetry API response, not the underlying Tesla command, and is already handled by raising InvalidResponse - there is no evidence backing a broader staleness/reliability claim about the command itself. Rewrite both to state what the accessor returns without the unevidenced reliability editorializing. --- docs/teslemetry.md | 8 ++++---- tesla_fleet_api/teslemetry/energysite.py | 7 ++----- 2 files changed, 6 insertions(+), 9 deletions(-) diff --git a/docs/teslemetry.md b/docs/teslemetry.md index 191ebd3..2b373ca 100644 --- a/docs/teslemetry.md +++ b/docs/teslemetry.md @@ -558,10 +558,10 @@ never mistaken for "no authorized clients". `state` is typed as `AuthorizedClientState`. The raw response is still available on `raw` for anything not modeled. -Use these cloud helpers only as secondary, best-effort checks during local key -pairing. They are not authoritative verification that a key can make signed -LAN requests; the reliable proof is a successful signed local read through the -paired client, as shown in [Energy: Local Control](energy_local_control.md). +These cloud helpers report the gateway's registered-client state as returned +by the Teslemetry API. Confirming that a key can actually make signed LAN +requests requires a successful signed local read through the paired client, +as shown in [Energy: Local Control](energy_local_control.md). ```python async def main(): diff --git a/tesla_fleet_api/teslemetry/energysite.py b/tesla_fleet_api/teslemetry/energysite.py index 5b31301..4d2adfc 100644 --- a/tesla_fleet_api/teslemetry/energysite.py +++ b/tesla_fleet_api/teslemetry/energysite.py @@ -324,11 +324,8 @@ async def find_authorized_clients(self) -> AuthorizedClients: caller. Raises :class:`~tesla_fleet_api.exceptions.InvalidResponse` on a null response body or an unrecognized response shape rather than - treating either as "no clients". Treat it as a secondary, - best-effort cloud check during local key pairing; a successful - signed local read through the paired LAN client is the - authoritative verification. See :class:`AuthorizedClients` for the - exact parsing semantics. + treating either as "no clients". See :class:`AuthorizedClients` for + the exact parsing semantics. """ return _parse_authorized_clients(await self.list_authorized_clients())