From 595c3ba9cf82a9bfcd3ce22716968c7f87022540 Mon Sep 17 00:00:00 2001 From: Your Name Date: Sat, 20 Dec 2025 11:21:06 -0600 Subject: [PATCH] Fix AsyncClient init in executor --- custom_components/groqd/__init__.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/custom_components/groqd/__init__.py b/custom_components/groqd/__init__.py index 1d3fd2b..881f5d1 100644 --- a/custom_components/groqd/__init__.py +++ b/custom_components/groqd/__init__.py @@ -28,7 +28,9 @@ type GroqdConfigEntry = ConfigEntry[GroqdRuntimeData] async def async_setup_entry(hass: HomeAssistant, entry: GroqdConfigEntry) -> bool: """Set up groqd from a config entry.""" api_key = entry.data[CONF_API_KEY] - client = await hass.async_add_executor_job(groq.AsyncClient, api_key=api_key) + client = await hass.async_add_executor_job( + lambda: groq.AsyncClient(api_key=api_key) + ) entry.runtime_data = GroqdRuntimeData(client=client) await hass.config_entries.async_forward_entry_setups(entry, PLATFORMS)