mirror of
https://github.com/home-assistant/core.git
synced 2025-07-23 05:07:41 +00:00
Fix unreleased breaking change in Google Cloud (#121523)
This commit is contained in:
parent
98651cbd2e
commit
5f909d0c52
@ -58,11 +58,14 @@ def tts_options_schema(
|
|||||||
CONF_GENDER,
|
CONF_GENDER,
|
||||||
description={"suggested_value": config_options.get(CONF_GENDER)},
|
description={"suggested_value": config_options.get(CONF_GENDER)},
|
||||||
default=texttospeech.SsmlVoiceGender.NEUTRAL.name, # type: ignore[attr-defined]
|
default=texttospeech.SsmlVoiceGender.NEUTRAL.name, # type: ignore[attr-defined]
|
||||||
): SelectSelector(
|
): vol.All(
|
||||||
SelectSelectorConfig(
|
vol.Upper,
|
||||||
mode=SelectSelectorMode.DROPDOWN,
|
SelectSelector(
|
||||||
options=list(texttospeech.SsmlVoiceGender.__members__),
|
SelectSelectorConfig(
|
||||||
)
|
mode=SelectSelectorMode.DROPDOWN,
|
||||||
|
options=list(texttospeech.SsmlVoiceGender.__members__),
|
||||||
|
)
|
||||||
|
),
|
||||||
),
|
),
|
||||||
vol.Optional(
|
vol.Optional(
|
||||||
CONF_VOICE,
|
CONF_VOICE,
|
||||||
@ -78,11 +81,14 @@ def tts_options_schema(
|
|||||||
CONF_ENCODING,
|
CONF_ENCODING,
|
||||||
description={"suggested_value": config_options.get(CONF_ENCODING)},
|
description={"suggested_value": config_options.get(CONF_ENCODING)},
|
||||||
default=texttospeech.AudioEncoding.MP3.name, # type: ignore[attr-defined]
|
default=texttospeech.AudioEncoding.MP3.name, # type: ignore[attr-defined]
|
||||||
): SelectSelector(
|
): vol.All(
|
||||||
SelectSelectorConfig(
|
vol.Upper,
|
||||||
mode=SelectSelectorMode.DROPDOWN,
|
SelectSelector(
|
||||||
options=list(texttospeech.AudioEncoding.__members__),
|
SelectSelectorConfig(
|
||||||
)
|
mode=SelectSelectorMode.DROPDOWN,
|
||||||
|
options=list(texttospeech.AudioEncoding.__members__),
|
||||||
|
)
|
||||||
|
),
|
||||||
),
|
),
|
||||||
vol.Optional(
|
vol.Optional(
|
||||||
CONF_SPEED,
|
CONF_SPEED,
|
||||||
@ -125,11 +131,14 @@ def tts_options_schema(
|
|||||||
CONF_TEXT_TYPE,
|
CONF_TEXT_TYPE,
|
||||||
description={"suggested_value": config_options.get(CONF_TEXT_TYPE)},
|
description={"suggested_value": config_options.get(CONF_TEXT_TYPE)},
|
||||||
default="text",
|
default="text",
|
||||||
): SelectSelector(
|
): vol.All(
|
||||||
SelectSelectorConfig(
|
vol.Lower,
|
||||||
mode=SelectSelectorMode.DROPDOWN,
|
SelectSelector(
|
||||||
options=["text", "ssml"],
|
SelectSelectorConfig(
|
||||||
)
|
mode=SelectSelectorMode.DROPDOWN,
|
||||||
|
options=["text", "ssml"],
|
||||||
|
)
|
||||||
|
),
|
||||||
),
|
),
|
||||||
}
|
}
|
||||||
)
|
)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user