mirror of
https://github.com/python-kasa/python-kasa.git
synced 2025-10-12 02:18:02 +00:00
Add bare bones homekit module for iot devices (#1566)
Based on the existing smart HomeKit module, this has been tested with a real device that supports this module. --------- Co-authored-by: Teemu Rytilahti <tpr@iki.fi>
This commit is contained in:
@@ -4,6 +4,7 @@ from __future__ import annotations
|
||||
|
||||
import asyncio
|
||||
import logging
|
||||
import re
|
||||
from collections.abc import Callable
|
||||
from pprint import pformat as pf
|
||||
from typing import TYPE_CHECKING, Any
|
||||
@@ -54,6 +55,8 @@ REDACTORS: dict[str, Callable[[Any], Any] | None] = {
|
||||
"oemId": lambda x: "REDACTED_" + x[9::],
|
||||
"username": lambda _: "user@example.com", # cnCloud
|
||||
"hwId": lambda x: "REDACTED_" + x[9::],
|
||||
"setup_code": lambda x: re.sub(r"\w", "0", x), # homekit
|
||||
"setup_payload": lambda x: re.sub(r"\w", "0", x), # homekit
|
||||
}
|
||||
|
||||
|
||||
|
Reference in New Issue
Block a user