mirror of
https://github.com/home-assistant/core.git
synced 2025-07-09 22:37:11 +00:00
Fix link (#5343)
This commit is contained in:
parent
e00e6f9db6
commit
2465aea63b
@ -2,7 +2,7 @@
|
||||
Support for the google speech service.
|
||||
|
||||
For more details about this component, please refer to the documentation at
|
||||
https://home-assistant.io/components/tts/google/
|
||||
https://home-assistant.io/components/tts.google/
|
||||
"""
|
||||
import asyncio
|
||||
import logging
|
||||
@ -41,12 +41,12 @@ PLATFORM_SCHEMA = PLATFORM_SCHEMA.extend({
|
||||
|
||||
@asyncio.coroutine
|
||||
def async_get_engine(hass, config):
|
||||
"""Setup Google speech component."""
|
||||
"""Set up Google speech component."""
|
||||
return GoogleProvider(hass, config[CONF_LANG])
|
||||
|
||||
|
||||
class GoogleProvider(Provider):
|
||||
"""Google speech api provider."""
|
||||
"""The Google speech API provider."""
|
||||
|
||||
def __init__(self, hass, lang):
|
||||
"""Init Google TTS service."""
|
||||
|
@ -25,7 +25,7 @@ PLATFORM_SCHEMA = PLATFORM_SCHEMA.extend({
|
||||
|
||||
|
||||
def get_engine(hass, config):
|
||||
"""Setup pico speech component."""
|
||||
"""Set up Pico speech component."""
|
||||
if shutil.which("pico2wave") is None:
|
||||
_LOGGER.error("'pico2wave' was not found")
|
||||
return False
|
||||
|
@ -2,7 +2,7 @@
|
||||
Support for the voicerss speech service.
|
||||
|
||||
For more details about this component, please refer to the documentation at
|
||||
https://home-assistant.io/components/tts/voicerss/
|
||||
https://home-assistant.io/components/tts.voicerss/
|
||||
"""
|
||||
import asyncio
|
||||
import logging
|
||||
@ -83,12 +83,12 @@ PLATFORM_SCHEMA = PLATFORM_SCHEMA.extend({
|
||||
|
||||
@asyncio.coroutine
|
||||
def async_get_engine(hass, config):
|
||||
"""Setup VoiceRSS speech component."""
|
||||
"""Set up VoiceRSS TTS component."""
|
||||
return VoiceRSSProvider(hass, config)
|
||||
|
||||
|
||||
class VoiceRSSProvider(Provider):
|
||||
"""VoiceRSS speech api provider."""
|
||||
"""The VoiceRSS speech API provider."""
|
||||
|
||||
def __init__(self, hass, conf):
|
||||
"""Init VoiceRSS TTS service."""
|
||||
@ -115,7 +115,7 @@ class VoiceRSSProvider(Provider):
|
||||
|
||||
@asyncio.coroutine
|
||||
def async_get_tts_audio(self, message, language):
|
||||
"""Load TTS from voicerss."""
|
||||
"""Load TTS from VoiceRSS."""
|
||||
websession = async_get_clientsession(self.hass)
|
||||
form_data = self._form_data.copy()
|
||||
|
||||
@ -137,11 +137,11 @@ class VoiceRSSProvider(Provider):
|
||||
|
||||
if data in ERROR_MSG:
|
||||
_LOGGER.error(
|
||||
"Error receive %s from voicerss.", str(data, 'utf-8'))
|
||||
"Error receive %s from VoiceRSS", str(data, 'utf-8'))
|
||||
return (None, None)
|
||||
|
||||
except (asyncio.TimeoutError, aiohttp.errors.ClientError):
|
||||
_LOGGER.error("Timeout for voicerss api.")
|
||||
_LOGGER.error("Timeout for VoiceRSS API")
|
||||
return (None, None)
|
||||
|
||||
finally:
|
||||
|
Loading…
x
Reference in New Issue
Block a user