From 5b0d109674ae4eb1e89d980c772a632f0a51b581 Mon Sep 17 00:00:00 2001 From: "David F. Severski" Date: Mon, 16 Nov 2026 10:08:05 -0500 Subject: [PATCH 1/2] fix: type async_get_feed_fields as returning a dict --- pyemoncms/emoncms_client.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pyemoncms/emoncms_client.py b/pyemoncms/emoncms_client.py index 9d91e70..b86c4ad 100644 --- a/pyemoncms/emoncms_client.py +++ b/pyemoncms/emoncms_client.py @@ -181,12 +181,12 @@ async def async_list_feeds(self) -> list[dict[str, Any]] | None: return cast(list[dict[str, Any]], feed_data[MESSAGE_KEY]) return None - async def async_get_feed_fields(self, feed_id: int) -> list[Any] | None: + async def async_get_feed_fields(self, feed_id: int) -> dict[str, Any] | None: """Get all fields for a single feed.""" params = {"apikey": self.api_key, "id": feed_id} feed_data = await self.async_request("/feed/aget.json", params=params) if feed_data[SUCCESS_KEY]: - return cast(list[Any], feed_data[MESSAGE_KEY]) + return cast(dict[str, Any], feed_data[MESSAGE_KEY]) return None async def close(self) -> None: From 9560195381b34bdb4678c7cce5938072a231fd65 Mon Sep 17 00:00:00 2001 From: "David F. Severski" Date: Mon, 16 Nov 2026 10:08:33 -0500 Subject: [PATCH 2/2] fix: explicitly re-export public names for strict type checkers --- pyemoncms/__init__.py | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/pyemoncms/__init__.py b/pyemoncms/__init__.py index 5b49e69..1229887 100644 --- a/pyemoncms/__init__.py +++ b/pyemoncms/__init__.py @@ -5,3 +5,10 @@ EmoncmsConnectionError, EmoncmsError, ) + +__all__ = [ + "EmoncmsAuthError", + "EmoncmsClient", + "EmoncmsConnectionError", + "EmoncmsError", +]