Log device IP sending local msg (#67987)

This commit is contained in:
Paulus Schoutsen 2022-03-11 07:50:44 -08:00 committed by GitHub
parent 8948bada58
commit 49b642a6ba
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -331,7 +331,12 @@ class AbstractConfig(ABC):
payload = await request.json()
if _LOGGER.isEnabledFor(logging.DEBUG):
_LOGGER.debug("Received local message:\n%s\n", pprint.pformat(payload))
_LOGGER.debug(
"Received local message from %s (JS %s):\n%s\n",
request.remote,
request.headers.get("HA-Cloud-Version", "unknown"),
pprint.pformat(payload),
)
if not self.enabled:
return json_response(smart_home.turned_off_response(payload))