1 """Errors for Google Assistant."""
3 from .const
import ERR_CHALLENGE_NEEDED
7 """Google Assistant Smart Home errors.
9 https://developers.google.com/actions/smarthome/create-app#error_responses
18 """Convert to a response format."""
19 return {
"errorCode": self.
codecode}
23 """Google Assistant Smart Home errors.
25 https://developers.google.com/actions/smarthome/create-app#error_responses
29 """Initialize challenge needed error."""
30 super().
__init__(ERR_CHALLENGE_NEEDED, f
"Challenge needed: {challenge_type}")
34 """Convert to a response format."""
36 "errorCode": self.
codecode,
def __init__(self, challenge_type)
def __init__(self, code, msg)