Skip to content

Consider passing in an SSLContext when creating the httpx client if you need ssl #117

@bdraco

Description

@bdraco

self._session = self._session_instance or httpx.AsyncClient()

We recently discovered httpx does not perform well without passing in an ssl context (home-assistant/core#89932)

see encode/httpx#2609 encode/httpx#838 (comment)

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 client

from homeassistant.helpers.httpx_client import create_async_httpx_client to create a new one (if you need to recreate or need you own)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions