Open bdraco opened 1 year ago
Hi @bdraco , just that I get the urgency right: if we use the client created by get_async_client (what we do), the issue will be handled for us. Other usages outside of Home Assistant are not running at best possible performance, but still work. Did I summarize it correctly?
Hi @bdraco , just that I get the urgency right: if we use the client created by get_async_client (what we do), the issue will be handled for us.
Yes. If you do this already there is nothing to do.
Other usages outside of Home Assistant are not running at best possible performance, but still work. Did I summarize it correctly?
Yes
https://github.com/2Fake/devolo_plc_api/blob/81723576742175f14aa50814209812b480d2d8c3/devolo_plc_api/device.py#L123
We recently discovered httpx does not perform well without passing in an ssl context (https://github.com/home-assistant/core/pull/89932)
see https://github.com/encode/httpx/pull/2609 https://github.com/encode/httpx/issues/838#issuecomment-1289927214
The shared helper will be updated for this issue as well so it can be used and passed the library
from homeassistant.helpers.httpx_client import get_async_client
to get the shared clientfrom homeassistant.helpers.httpx_client import create_async_httpx_client
to create a new one (if you need to recreate or need you own)