Skip to content

Commit d65320c

Browse files
committed
adding polling properties to unified fireplace
1 parent f435fa2 commit d65320c

File tree

2 files changed

+11
-2
lines changed

2 files changed

+11
-2
lines changed

pyproject.toml

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[tool.poetry]
22
name = "intellifire4py"
3-
version = "4.1.4"
3+
version = "4.1.5"
44
description = "Intellifire4Py"
55
authors = ["Jeff Stein <[email protected]>"]
66
license = "MIT"

src/intellifire4py/unified_fireplace.py

+10-1
Original file line numberDiff line numberDiff line change
@@ -110,7 +110,16 @@ async def perform_local_poll(self, timeout_seconds: float = 10.0) -> None:
110110
await self._local_api.poll(timeout_seconds=timeout_seconds)
111111

112112
@property
113-
def dump_user_data_json(self) -> str:
113+
def is_cloud_polling(self) -> bool:
114+
"""Returns True if the cloud API is currently polling in the background."""
115+
return self._cloud_api.is_polling_in_background
116+
117+
@property
118+
def is_local_polling(self) -> bool:
119+
"""Returns True if the local API is currently polling in the background."""
120+
return self._local_api.is_polling_in_background
121+
122+
def get_user_data_as_json(self) -> str:
114123
"""Dump the internal _fireplace_data object to a JSON String."""
115124
try:
116125
return str(self._fireplace_data.model_dump_json(indent=2)) # type: ignore[attr-defined]

0 commit comments

Comments
 (0)