Chime TTS - Play audio before/after TTS audio lag free

Nothing has changed for me on 0.5.3.

2023-07-23 16:53:40.062 DEBUG (MainThread) [custom_components.chime_tts] ----- Chime TTS Say Called -----
2023-07-23 16:53:40.062 DEBUG (MainThread) [custom_components.chime_tts]  * hass = <homeassistant.core.HomeAssistant object at 0x7fe896b8fb10>
2023-07-23 16:53:40.062 DEBUG (MainThread) [custom_components.chime_tts]  * chime_path = 
2023-07-23 16:53:40.062 DEBUG (MainThread) [custom_components.chime_tts]  * end_chime_path = 
2023-07-23 16:53:40.062 DEBUG (MainThread) [custom_components.chime_tts]  * delay = 450.0
2023-07-23 16:53:40.062 DEBUG (MainThread) [custom_components.chime_tts]  * message = test playback
2023-07-23 16:53:40.062 DEBUG (MainThread) [custom_components.chime_tts]  * tts_platform = google_translate
2023-07-23 16:53:40.062 DEBUG (MainThread) [custom_components.chime_tts]  * tts_playback_speed = 100.0
2023-07-23 16:53:40.062 DEBUG (MainThread) [custom_components.chime_tts]  * entity_id = media_player.bose_soundbar
2023-07-23 16:53:40.062 DEBUG (MainThread) [custom_components.chime_tts]  * volume_level = -1.0
2023-07-23 16:53:40.062 DEBUG (MainThread) [custom_components.chime_tts]  * cache = False
2023-07-23 16:53:40.062 DEBUG (MainThread) [custom_components.chime_tts]  * language = None
2023-07-23 16:53:40.062 DEBUG (MainThread) [custom_components.chime_tts]  * tld = None
2023-07-23 16:53:40.062 DEBUG (MainThread) [custom_components.chime_tts]  * gender = None
2023-07-23 16:53:40.062 WARNING (MainThread) [custom_components.chime_tts] Media player "media_player.bose_soundbar" does not support volume level
2023-07-23 16:53:40.063 DEBUG (MainThread) [custom_components.chime_tts] async_get_playback_audio_path(params={'hass': <homeassistant.core.HomeAssistant object at 0x7fe896b8fb10>, 'chime_path': '', 'end_chime_path': '', 'delay': 450.0, 'message': 'test playback', 'tts_platform': 'google_translate', 'tts_playback_speed': 100.0, 'entity_id': 'media_player.bose_soundbar', 'volume_level': -1.0, 'cache': False, 'language': None, 'tld': None, 'gender': None})
2023-07-23 16:53:40.063 DEBUG (MainThread) [custom_components.chime_tts] get_audio_from_path("", 0, audio)
2023-07-23 16:53:40.063 DEBUG (MainThread) [custom_components.chime_tts] async_request_tts_audio_filepath(hass, tts_platform="google_translate", message="test playback", language="None", tld="None", gender="None"))
2023-07-23 16:53:40.063 DEBUG (MainThread) [custom_components.chime_tts] Requesting TTS audio:
2023-07-23 16:53:40.063 DEBUG (MainThread) [custom_components.chime_tts]  * url     = https://domain.com/api/tts_get_url
2023-07-23 16:53:40.063 DEBUG (MainThread) [custom_components.chime_tts]  * headers = {'Authorization': 'Bearer eyJhb##########SAZ5E', 'Content-Type': 'application/json'}
2023-07-23 16:53:40.063 DEBUG (MainThread) [custom_components.chime_tts]  * data    = {"message": "test playback", "platform": "google_translate", "cache": true}
2023-07-23 16:53:40.063 DEBUG (MainThread) [custom_components.chime_tts]  * timeout = 10
2023-07-23 16:53:40.072 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 410ms
2023-07-23 16:53:40.082 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 420ms
2023-07-23 16:53:40.092 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 430ms
2023-07-23 16:53:40.103 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 440ms
2023-07-23 16:53:40.113 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 450ms
2023-07-23 16:53:40.124 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 460ms
2023-07-23 16:53:40.134 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 470ms
2023-07-23 16:53:40.144 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 480ms
2023-07-23 16:53:40.155 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 490ms
2023-07-23 16:53:40.165 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 500ms
2023-07-23 16:53:40.176 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 510ms
2023-07-23 16:53:40.186 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 520ms
2023-07-23 16:53:40.196 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 530ms
2023-07-23 16:53:40.207 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 540ms
2023-07-23 16:53:40.217 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 550ms
2023-07-23 16:53:40.227 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 560ms
2023-07-23 16:53:40.238 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 570ms
2023-07-23 16:53:40.248 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 580ms
2023-07-23 16:53:40.259 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 590ms
2023-07-23 16:53:40.269 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 600ms
2023-07-23 16:53:40.280 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 610ms
2023-07-23 16:53:40.290 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 620ms
2023-07-23 16:53:40.300 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 630ms
2023-07-23 16:53:40.311 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 640ms
2023-07-23 16:53:40.321 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 650ms
2023-07-23 16:53:40.332 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 660ms
2023-07-23 16:53:40.344 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 670ms
2023-07-23 16:53:40.354 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 680ms
2023-07-23 16:53:40.365 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 690ms
2023-07-23 16:53:40.375 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 700ms
2023-07-23 16:53:40.386 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 710ms
2023-07-23 16:53:40.396 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 720ms
2023-07-23 16:53:40.406 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 730ms
2023-07-23 16:53:40.418 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 740ms
2023-07-23 16:53:40.428 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 750ms
2023-07-23 16:53:40.439 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 760ms
2023-07-23 16:53:40.449 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 770ms
2023-07-23 16:53:40.459 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 780ms
2023-07-23 16:53:40.470 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 790ms
2023-07-23 16:53:40.480 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 800ms
2023-07-23 16:53:40.491 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 810ms
2023-07-23 16:53:40.501 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 820ms
2023-07-23 16:53:40.511 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 830ms
2023-07-23 16:53:40.522 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 840ms
2023-07-23 16:53:40.532 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 850ms
2023-07-23 16:53:40.543 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 860ms
2023-07-23 16:53:40.553 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 870ms
2023-07-23 16:53:40.564 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 880ms
2023-07-23 16:53:40.574 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 890ms
2023-07-23 16:53:40.585 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 900ms
2023-07-23 16:53:40.596 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 910ms
2023-07-23 16:53:40.607 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 920ms
2023-07-23 16:53:40.617 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 930ms
2023-07-23 16:53:40.628 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 940ms
2023-07-23 16:53:40.638 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 950ms
2023-07-23 16:53:40.648 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 960ms
2023-07-23 16:53:40.659 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 970ms
2023-07-23 16:53:40.669 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 980ms
2023-07-23 16:53:40.679 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 990ms
2023-07-23 16:53:40.690 DEBUG (MainThread) [custom_components.chime_tts] TTS file not found on filesystem after waiting 1000ms
2023-07-23 16:53:40.690 DEBUG (MainThread) [custom_components.chime_tts] get_audio_from_path("None", 450.0, audio)
2023-07-23 16:53:40.690 DEBUG (MainThread) [custom_components.chime_tts] get_audio_from_path("", 450.0, audio)
2023-07-23 16:53:40.690 ERROR (MainThread) [custom_components.chime_tts] Unable to generate audio for playback
2023-07-23 16:53:44.087 DEBUG (MainThread) [custom_components.chime_tts]  - Repsonse status_code: "200"
2023-07-23 16:53:44.087 DEBUG (MainThread) [custom_components.chime_tts]  - Repsonse received: "{"url":"https://domain.com/api/tts_proxy/72fd416a9198cf7a9f40d18e660f8c3e97edbf69_en_-_google_translate.mp3","path":"/api/tts_proxy/72fd416a9198cf7a9f40d18e660f8c3e97edbf69_en_-_google_translate.mp3"}"
2023-07-23 16:53:44.087 DEBUG (MainThread) [custom_components.chime_tts]  - TTS filepaths = {'path': '/config/tts/72fd416a9198cf7a9f40d18e660f8c3e97edbf69_en_-_google_translate.mp3', 'url': 'https://domain.com/api/tts_proxy/72fd416a9198cf7a9f40d18e660f8c3e97edbf69_en_-_google_translate.mp3'}
2023-07-23 16:53:44.097 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 10ms
2023-07-23 16:53:44.108 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 20ms
2023-07-23 16:53:44.118 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 30ms
2023-07-23 16:53:44.128 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 40ms
2023-07-23 16:53:44.139 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 50ms
2023-07-23 16:53:44.149 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 60ms
2023-07-23 16:53:44.160 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 70ms
2023-07-23 16:53:44.170 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 80ms
2023-07-23 16:53:44.180 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 90ms
2023-07-23 16:53:44.191 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 100ms
2023-07-23 16:53:44.201 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 110ms
2023-07-23 16:53:44.212 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 120ms
2023-07-23 16:53:44.222 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 130ms
2023-07-23 16:53:44.232 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 140ms
2023-07-23 16:53:44.243 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 150ms
2023-07-23 16:53:44.253 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 160ms
2023-07-23 16:53:44.263 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 170ms
2023-07-23 16:53:44.274 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 180ms
2023-07-23 16:53:44.284 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 190ms
2023-07-23 16:53:44.295 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 200ms
2023-07-23 16:53:44.305 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 210ms
2023-07-23 16:53:44.315 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 220ms
2023-07-23 16:53:44.326 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 230ms
2023-07-23 16:53:44.336 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 240ms
2023-07-23 16:53:44.346 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 250ms
2023-07-23 16:53:44.357 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 260ms
2023-07-23 16:53:44.367 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 270ms
2023-07-23 16:53:44.378 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 280ms
2023-07-23 16:53:44.388 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 290ms
2023-07-23 16:53:44.399 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 300ms
2023-07-23 16:53:44.409 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 310ms
2023-07-23 16:53:44.419 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 320ms
2023-07-23 16:53:44.430 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 330ms
2023-07-23 16:53:44.440 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 340ms
2023-07-23 16:53:44.451 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 350ms
2023-07-23 16:53:44.461 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 360ms
2023-07-23 16:53:44.472 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 370ms
2023-07-23 16:53:44.482 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 380ms
2023-07-23 16:53:44.492 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 390ms
2023-07-23 16:53:44.503 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 400ms
2023-07-23 16:53:44.513 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 410ms
2023-07-23 16:53:44.524 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 420ms
2023-07-23 16:53:44.534 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 430ms
2023-07-23 16:53:44.544 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 440ms
2023-07-23 16:53:44.555 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 450ms
2023-07-23 16:53:44.565 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 460ms
2023-07-23 16:53:44.576 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 470ms
2023-07-23 16:53:44.586 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 480ms
2023-07-23 16:53:44.596 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 490ms
2023-07-23 16:53:44.607 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 500ms
2023-07-23 16:53:44.617 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 510ms
2023-07-23 16:53:44.628 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 520ms
2023-07-23 16:53:44.638 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 530ms
2023-07-23 16:53:44.648 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 540ms
2023-07-23 16:53:44.659 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 550ms
2023-07-23 16:53:44.669 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 560ms
2023-07-23 16:53:44.680 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 570ms
2023-07-23 16:53:44.690 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 580ms
2023-07-23 16:53:44.701 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 590ms
2023-07-23 16:53:44.711 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 600ms
2023-07-23 16:53:44.721 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 610ms
2023-07-23 16:53:44.732 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 620ms
2023-07-23 16:53:44.742 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 630ms
2023-07-23 16:53:44.753 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 640ms
2023-07-23 16:53:44.763 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 650ms
2023-07-23 16:53:44.773 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 660ms
2023-07-23 16:53:44.784 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 670ms
2023-07-23 16:53:44.794 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 680ms
2023-07-23 16:53:44.805 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 690ms
2023-07-23 16:53:44.815 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 700ms
2023-07-23 16:53:44.825 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 710ms
2023-07-23 16:53:44.835 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 720ms
2023-07-23 16:53:44.846 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 730ms
2023-07-23 16:53:44.856 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 740ms
2023-07-23 16:53:44.867 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 750ms
2023-07-23 16:53:44.877 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 760ms
2023-07-23 16:53:44.887 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 770ms
2023-07-23 16:53:44.898 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 780ms
2023-07-23 16:53:44.908 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 790ms
2023-07-23 16:53:44.919 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 800ms
2023-07-23 16:53:44.929 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 810ms
2023-07-23 16:53:44.940 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 820ms
2023-07-23 16:53:44.950 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 830ms
2023-07-23 16:53:44.960 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 840ms
2023-07-23 16:53:44.971 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 850ms
2023-07-23 16:53:44.984 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 860ms
2023-07-23 16:53:44.994 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 870ms
2023-07-23 16:53:45.004 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 880ms
2023-07-23 16:53:45.015 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 890ms
2023-07-23 16:53:45.025 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 900ms
2023-07-23 16:53:45.036 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 910ms
2023-07-23 16:53:45.046 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 920ms
2023-07-23 16:53:45.057 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 930ms
2023-07-23 16:53:45.067 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 940ms
2023-07-23 16:53:45.077 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 950ms
2023-07-23 16:53:45.087 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 960ms
2023-07-23 16:53:45.098 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 970ms
2023-07-23 16:53:45.108 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 980ms
2023-07-23 16:53:45.119 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 990ms
2023-07-23 16:53:45.129 DEBUG (MainThread) [custom_components.chime_tts] TTS file not found on filesystem after waiting 1000ms
2023-07-23 16:53:45.129 DEBUG (MainThread) [custom_components.chime_tts] get_audio_from_path("None", 450.0, audio)
2023-07-23 16:53:45.129 DEBUG (MainThread) [custom_components.chime_tts] get_audio_from_path("", 450.0, audio)
2023-07-23 16:53:45.129 ERROR (MainThread) [custom_components.chime_tts] Unable to generate audio for playback

For the record im unsetting volume level and it still warns me its not supported

@jreed509, i’m glad to hear that playback is fixed for you and thanks for spotting the volume level issue when cache is off. It should now be fixed in version v0.5.4.

The announce feature in Chime TTS should behave the same as in the native media_player.play_media service, as Chime TTS uses that same service to play audio (and simply passes the announce value in the data).
Could you please check if announce works for you when calling media_player.play_media ?

@Maxcodesthings, sorry to hear it’s still not working for you. Based on your debug log messages it looks like the tts_get_url API call isn’t working. Perhaps you could try removing and adding the integration with a new new long lived token? Also: is your HA host behind an SSL certificate?

@Bramus can you please upgrade to the latest version, v0.5.4, and report back whether you’re still having the same issue?

1 Like

@Nimrod_Dolev

Thanks for getting back, just tried and enabled debug. Now i have the following:

Logger: custom_components.chime_tts
Source: custom_components/chime_tts/__init__.py:159
Integration: Chime TTS (documentation, issues)
First occurred: 19:35:05 (1 occurrences)
Last logged: 19:35:05

async_get_playback_audio_path --> Unable to generate audio for playback

And also this:

Logger: custom_components.chime_tts
Source: custom_components/chime_tts/__init__.py:144
Integration: Chime TTS (documentation, issues)
First occurred: 19:35:03 (1 occurrences)
Last logged: 19:35:03

Audio filepath does not exist: "custom_components/chime_tts/mp3s/bells.mp3"

@Bramus Can you please provide the full debug log messages?

You can enable debug logging by going to Settings —> Devices & Services —> Chime TTS —> Enable debug logging

Then please run the service again, and in the log messages section, search for “Chime” and select the LOAD FULL LOGS button which will present the full debug logs.

Here is the output:

2023-07-24 11:52:07.878 WARNING (SyncWorker_1) [homeassistant.loader] We found a custom integration chime_tts which has not been tested by Home Assistant. This component might cause stability problems, be sure to disable it if you experience issues with Home Assistant
2023-07-24 19:35:03.724 DEBUG (MainThread) [custom_components.chime_tts] ----- Chime TTS Say Called -----
2023-07-24 19:35:03.725 DEBUG (MainThread) [custom_components.chime_tts] * hass = <homeassistant.core.HomeAssistant object at 0x744d1530>
2023-07-24 19:35:03.725 DEBUG (MainThread) [custom_components.chime_tts] * chime_path = custom_components/chime_tts/mp3s/bells.mp3
2023-07-24 19:35:03.725 DEBUG (MainThread) [custom_components.chime_tts] * end_chime_path =
2023-07-24 19:35:03.725 DEBUG (MainThread) [custom_components.chime_tts] * delay = 450.0
2023-07-24 19:35:03.726 DEBUG (MainThread) [custom_components.chime_tts] * message = Test message
2023-07-24 19:35:03.726 DEBUG (MainThread) [custom_components.chime_tts] * tts_platform = google_translate
2023-07-24 19:35:03.726 DEBUG (MainThread) [custom_components.chime_tts] * tts_playback_speed = 100.0
2023-07-24 19:35:03.726 DEBUG (MainThread) [custom_components.chime_tts] * entity_id = media_player.woonkamer
2023-07-24 19:35:03.726 DEBUG (MainThread) [custom_components.chime_tts] * volume_level = -1.0
2023-07-24 19:35:03.726 DEBUG (MainThread) [custom_components.chime_tts] * cache = False
2023-07-24 19:35:03.727 DEBUG (MainThread) [custom_components.chime_tts] * announce = False
2023-07-24 19:35:03.727 DEBUG (MainThread) [custom_components.chime_tts] * language = nl
2023-07-24 19:35:03.727 DEBUG (MainThread) [custom_components.chime_tts] * tld = None
2023-07-24 19:35:03.727 DEBUG (MainThread) [custom_components.chime_tts] * gender = None
2023-07-24 19:35:03.727 DEBUG (MainThread) [custom_components.chime_tts] ------
2023-07-24 19:35:03.728 DEBUG (MainThread) [custom_components.chime_tts] async_get_playback_audio_path
2023-07-24 19:35:03.728 DEBUG (MainThread) [custom_components.chime_tts] get_audio_from_path("custom_components/chime_tts/mp3s/bells.mp3", 0, audio)
2023-07-24 19:35:03.731 WARNING (MainThread) [custom_components.chime_tts] Audio filepath does not exist: "custom_components/chime_tts/mp3s/bells.mp3"
2023-07-24 19:35:03.811 DEBUG (MainThread) [custom_components.chime_tts] async_request_tts_audio_filepath(hass, tts_platform="google_translate", message="Test message", language="nl", tld="None", gender="None"))
2023-07-24 19:35:03.812 DEBUG (MainThread) [custom_components.chime_tts] Requesting TTS audio:
2023-07-24 19:35:03.813 DEBUG (MainThread) [custom_components.chime_tts] * url = http://192.168.2.25:8123/api/tts_get_url
2023-07-24 19:35:03.813 DEBUG (MainThread) [custom_components.chime_tts] * headers = {'Authorization': 'Bearer eyJhb##########mbW5k', 'Content-Type': 'application/json'}
2023-07-24 19:35:03.813 DEBUG (MainThread) [custom_components.chime_tts] * data = {"message": "Test message", "platform": "google_translate", "cache": true, "language": "nl"}
2023-07-24 19:35:03.813 DEBUG (MainThread) [custom_components.chime_tts] * timeout = 10
2023-07-24 19:35:03.982 DEBUG (MainThread) [custom_components.chime_tts] - Repsonse status_code: "200"
2023-07-24 19:35:03.982 DEBUG (MainThread) [custom_components.chime_tts] - Repsonse received: "{"url":"http://192.168.2.25:8123/api/tts_proxy/8de39b4722207f2da2a831e8734f02e740c15738_nl_-_google_translate.mp3","path":"/api/tts_proxy/8de39b4722207f2da2a831e8734f02e740c15738_nl_-_google_translate.mp3"}"
2023-07-24 19:35:03.982 DEBUG (MainThread) [custom_components.chime_tts] - TTS filepaths = {'path': '/config/tts/8de39b4722207f2da2a831e8734f02e740c15738_nl_-_google_translate.mp3', 'url': 'http://192.168.2.25:8123/api/tts_proxy/8de39b4722207f2da2a831e8734f02e740c15738_nl_-_google_translate.mp3'}
2023-07-24 19:35:03.994 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 10ms
2023-07-24 19:35:04.010 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 20ms
2023-07-24 19:35:04.022 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 30ms
2023-07-24 19:35:04.033 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 40ms
2023-07-24 19:35:04.045 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 50ms
2023-07-24 19:35:04.057 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 60ms
2023-07-24 19:35:04.071 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 70ms
2023-07-24 19:35:04.082 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 80ms
2023-07-24 19:35:04.097 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 90ms
2023-07-24 19:35:04.109 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 100ms
2023-07-24 19:35:04.120 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 110ms
2023-07-24 19:35:04.136 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 120ms
2023-07-24 19:35:04.147 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 130ms
2023-07-24 19:35:04.159 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 140ms
2023-07-24 19:35:04.170 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 150ms
2023-07-24 19:35:04.181 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 160ms
2023-07-24 19:35:04.193 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 170ms
2023-07-24 19:35:04.204 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 180ms
2023-07-24 19:35:04.215 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 190ms
2023-07-24 19:35:04.226 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 200ms
2023-07-24 19:35:04.238 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 210ms
2023-07-24 19:35:04.249 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 220ms
2023-07-24 19:35:04.260 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 230ms
2023-07-24 19:35:04.272 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 240ms
2023-07-24 19:35:04.283 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 250ms
2023-07-24 19:35:04.294 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 260ms
2023-07-24 19:35:04.306 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 270ms
2023-07-24 19:35:04.317 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 280ms
2023-07-24 19:35:04.329 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 290ms
2023-07-24 19:35:04.340 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 300ms
2023-07-24 19:35:04.351 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 310ms
2023-07-24 19:35:04.363 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 320ms
2023-07-24 19:35:04.374 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 330ms
2023-07-24 19:35:04.385 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 340ms
2023-07-24 19:35:04.397 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 350ms
2023-07-24 19:35:04.408 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 360ms
2023-07-24 19:35:04.419 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 370ms
2023-07-24 19:35:04.431 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 380ms
2023-07-24 19:35:04.442 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 390ms
2023-07-24 19:35:04.453 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 400ms
2023-07-24 19:35:04.465 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 410ms
2023-07-24 19:35:04.476 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 420ms
2023-07-24 19:35:04.488 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 430ms
2023-07-24 19:35:04.501 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 440ms
2023-07-24 19:35:04.512 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 450ms
2023-07-24 19:35:04.525 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 460ms
2023-07-24 19:35:04.537 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 470ms
2023-07-24 19:35:04.549 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 480ms
2023-07-24 19:35:04.560 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 490ms
2023-07-24 19:35:04.573 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 500ms
2023-07-24 19:35:04.585 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 510ms
2023-07-24 19:35:04.597 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 520ms
2023-07-24 19:35:04.609 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 530ms
2023-07-24 19:35:04.621 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 540ms
2023-07-24 19:35:04.636 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 550ms
2023-07-24 19:35:04.648 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 560ms
2023-07-24 19:35:04.660 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 570ms
2023-07-24 19:35:04.672 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 580ms
2023-07-24 19:35:04.684 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 590ms
2023-07-24 19:35:04.696 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 600ms
2023-07-24 19:35:04.708 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 610ms
2023-07-24 19:35:04.720 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 620ms
2023-07-24 19:35:04.731 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 630ms
2023-07-24 19:35:04.745 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 640ms
2023-07-24 19:35:04.757 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 650ms
2023-07-24 19:35:04.769 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 660ms
2023-07-24 19:35:04.781 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 670ms
2023-07-24 19:35:04.793 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 680ms
2023-07-24 19:35:04.805 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 690ms
2023-07-24 19:35:04.817 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 700ms
2023-07-24 19:35:04.829 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 710ms
2023-07-24 19:35:04.841 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 720ms
2023-07-24 19:35:04.879 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 730ms
2023-07-24 19:35:04.891 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 740ms
2023-07-24 19:35:04.902 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 750ms
2023-07-24 19:35:04.916 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 760ms
2023-07-24 19:35:04.930 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 770ms
2023-07-24 19:35:04.942 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 780ms
2023-07-24 19:35:04.954 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 790ms
2023-07-24 19:35:04.968 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 800ms
2023-07-24 19:35:04.982 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 810ms
2023-07-24 19:35:04.994 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 820ms
2023-07-24 19:35:05.006 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 830ms
2023-07-24 19:35:05.017 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 840ms
2023-07-24 19:35:05.029 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 850ms
2023-07-24 19:35:05.041 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 860ms
2023-07-24 19:35:05.052 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 870ms
2023-07-24 19:35:05.064 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 880ms
2023-07-24 19:35:05.076 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 890ms
2023-07-24 19:35:05.088 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 900ms
2023-07-24 19:35:05.100 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 910ms
2023-07-24 19:35:05.112 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 920ms
2023-07-24 19:35:05.127 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 930ms
2023-07-24 19:35:05.139 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 940ms
2023-07-24 19:35:05.151 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 950ms
2023-07-24 19:35:05.163 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 960ms
2023-07-24 19:35:05.175 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 970ms
2023-07-24 19:35:05.187 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 980ms
2023-07-24 19:35:05.199 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 990ms
2023-07-24 19:35:05.211 DEBUG (MainThread) [custom_components.chime_tts] TTS file not found on filesystem after waiting 1000ms
2023-07-24 19:35:05.212 DEBUG (MainThread) [custom_components.chime_tts] get_audio_from_path("", 450.0, audio)
2023-07-24 19:35:05.212 DEBUG (MainThread) [custom_components.chime_tts] - audio_dict = None
2023-07-24 19:35:05.212 ERROR (MainThread) [custom_components.chime_tts] async_get_playback_audio_path --> Unable to generate audio for playback
2023-07-24 20:55:17.412 DEBUG (MainThread) [custom_components.chime_tts] ----- Chime TTS Say Called -----
2023-07-24 20:55:17.412 DEBUG (MainThread) [custom_components.chime_tts] * hass = <homeassistant.core.HomeAssistant object at 0x744d1530>
2023-07-24 20:55:17.413 DEBUG (MainThread) [custom_components.chime_tts] * chime_path = custom_components/chime_tts/mp3s/tada.mp3
2023-07-24 20:55:17.413 DEBUG (MainThread) [custom_components.chime_tts] * end_chime_path = custom_components/chime_tts/mp3s/bright.mp3
2023-07-24 20:55:17.413 DEBUG (MainThread) [custom_components.chime_tts] * delay = 450.0
2023-07-24 20:55:17.414 DEBUG (MainThread) [custom_components.chime_tts] * message = Hi Bram this is an test
2023-07-24 20:55:17.414 DEBUG (MainThread) [custom_components.chime_tts] * tts_platform = google_translate
2023-07-24 20:55:17.414 DEBUG (MainThread) [custom_components.chime_tts] * tts_playback_speed = 100.0
2023-07-24 20:55:17.414 DEBUG (MainThread) [custom_components.chime_tts] * entity_id = media_player.woonkamer
2023-07-24 20:55:17.415 DEBUG (MainThread) [custom_components.chime_tts] * volume_level = -1.0
2023-07-24 20:55:17.415 DEBUG (MainThread) [custom_components.chime_tts] * cache = False
2023-07-24 20:55:17.415 DEBUG (MainThread) [custom_components.chime_tts] * announce = False
2023-07-24 20:55:17.415 DEBUG (MainThread) [custom_components.chime_tts] * language = nl
2023-07-24 20:55:17.416 DEBUG (MainThread) [custom_components.chime_tts] * tld = None
2023-07-24 20:55:17.416 DEBUG (MainThread) [custom_components.chime_tts] * gender = None
2023-07-24 20:55:17.416 DEBUG (MainThread) [custom_components.chime_tts] ------
2023-07-24 20:55:17.417 DEBUG (MainThread) [custom_components.chime_tts] async_get_playback_audio_path
2023-07-24 20:55:17.424 DEBUG (MainThread) [custom_components.chime_tts] get_audio_from_path("custom_components/chime_tts/mp3s/tada.mp3", 0, audio)
2023-07-24 20:55:17.430 WARNING (MainThread) [custom_components.chime_tts] Audio filepath does not exist: "custom_components/chime_tts/mp3s/tada.mp3"
2023-07-24 20:55:17.447 DEBUG (MainThread) [custom_components.chime_tts] async_request_tts_audio_filepath(hass, tts_platform="google_translate", message="Hi Bram this is an test", language="nl", tld="None", gender="None"))
2023-07-24 20:55:17.449 DEBUG (MainThread) [custom_components.chime_tts] Requesting TTS audio:
2023-07-24 20:55:17.450 DEBUG (MainThread) [custom_components.chime_tts] * url = http://192.168.2.25:8123/api/tts_get_url
2023-07-24 20:55:17.450 DEBUG (MainThread) [custom_components.chime_tts] * headers = {'Authorization': 'Bearer eyJhb##########mbW5k', 'Content-Type': 'application/json'}
2023-07-24 20:55:17.450 DEBUG (MainThread) [custom_components.chime_tts] * data = {"message": "Hi Bram this is an test", "platform": "google_translate", "cache": true, "language": "nl"}
2023-07-24 20:55:17.451 DEBUG (MainThread) [custom_components.chime_tts] * timeout = 10
2023-07-24 20:55:17.487 DEBUG (MainThread) [custom_components.chime_tts] - Repsonse status_code: "200"
2023-07-24 20:55:17.488 DEBUG (MainThread) [custom_components.chime_tts] - Repsonse received: "{"url":"http://192.168.2.25:8123/api/tts_proxy/7944c5f87770f2710f409032dd78d78b3aeea91d_nl_-_google_translate.mp3","path":"/api/tts_proxy/7944c5f87770f2710f409032dd78d78b3aeea91d_nl_-_google_translate.mp3"}"
2023-07-24 20:55:17.488 DEBUG (MainThread) [custom_components.chime_tts] - TTS filepaths = {'path': '/config/tts/7944c5f87770f2710f409032dd78d78b3aeea91d_nl_-_google_translate.mp3', 'url': 'http://192.168.2.25:8123/api/tts_proxy/7944c5f87770f2710f409032dd78d78b3aeea91d_nl_-_google_translate.mp3'}
2023-07-24 20:55:17.502 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 10ms
2023-07-24 20:55:17.515 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 20ms
2023-07-24 20:55:17.526 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 30ms
2023-07-24 20:55:17.538 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 40ms
2023-07-24 20:55:17.549 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 50ms
2023-07-24 20:55:17.561 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 60ms
2023-07-24 20:55:17.572 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 70ms
2023-07-24 20:55:17.584 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 80ms
2023-07-24 20:55:17.596 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 90ms
2023-07-24 20:55:17.608 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 100ms
2023-07-24 20:55:17.620 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 110ms
2023-07-24 20:55:17.631 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 120ms
2023-07-24 20:55:17.643 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 130ms
2023-07-24 20:55:17.656 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 140ms
2023-07-24 20:55:17.668 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 150ms
2023-07-24 20:55:17.680 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 160ms
2023-07-24 20:55:17.692 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 170ms
2023-07-24 20:55:17.704 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 180ms
2023-07-24 20:55:17.716 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 190ms
2023-07-24 20:55:17.728 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 200ms
2023-07-24 20:55:17.740 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 210ms
2023-07-24 20:55:17.752 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 220ms
2023-07-24 20:55:17.764 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 230ms
2023-07-24 20:55:17.776 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 240ms
2023-07-24 20:55:17.788 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 250ms
2023-07-24 20:55:17.799 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 260ms
2023-07-24 20:55:17.811 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 270ms
2023-07-24 20:55:17.842 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 280ms
2023-07-24 20:55:17.854 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 290ms
2023-07-24 20:55:17.866 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 300ms
2023-07-24 20:55:17.878 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 310ms
2023-07-24 20:55:17.890 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 320ms
2023-07-24 20:55:17.902 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 330ms
2023-07-24 20:55:17.914 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 340ms
2023-07-24 20:55:17.925 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 350ms
2023-07-24 20:55:17.937 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 360ms
2023-07-24 20:55:17.950 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 370ms
2023-07-24 20:55:17.961 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 380ms
2023-07-24 20:55:17.974 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 390ms
2023-07-24 20:55:17.985 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 400ms
2023-07-24 20:55:17.997 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 410ms
2023-07-24 20:55:18.009 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 420ms
2023-07-24 20:55:18.021 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 430ms
2023-07-24 20:55:18.033 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 440ms
2023-07-24 20:55:18.045 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 450ms
2023-07-24 20:55:18.056 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 460ms
2023-07-24 20:55:18.068 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 470ms
2023-07-24 20:55:18.080 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 480ms
2023-07-24 20:55:18.092 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 490ms
2023-07-24 20:55:18.104 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 500ms
2023-07-24 20:55:18.116 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 510ms
2023-07-24 20:55:18.128 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 520ms
2023-07-24 20:55:18.140 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 530ms
2023-07-24 20:55:18.152 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 540ms
2023-07-24 20:55:18.164 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 550ms
2023-07-24 20:55:18.176 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 560ms
2023-07-24 20:55:18.188 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 570ms
2023-07-24 20:55:18.200 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 580ms
2023-07-24 20:55:18.212 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 590ms
2023-07-24 20:55:18.224 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 600ms
2023-07-24 20:55:18.236 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 610ms
2023-07-24 20:55:18.248 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 620ms
2023-07-24 20:55:18.260 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 630ms
2023-07-24 20:55:18.273 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 640ms
2023-07-24 20:55:18.285 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 650ms
2023-07-24 20:55:18.297 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 660ms
2023-07-24 20:55:18.309 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 670ms
2023-07-24 20:55:18.321 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 680ms
2023-07-24 20:55:18.333 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 690ms
2023-07-24 20:55:18.345 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 700ms
2023-07-24 20:55:18.357 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 710ms
2023-07-24 20:55:18.369 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 720ms
2023-07-24 20:55:18.382 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 730ms
2023-07-24 20:55:18.394 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 740ms
2023-07-24 20:55:18.406 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 750ms
2023-07-24 20:55:18.418 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 760ms
2023-07-24 20:55:18.431 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 770ms
2023-07-24 20:55:18.443 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 780ms
2023-07-24 20:55:18.455 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 790ms
2023-07-24 20:55:18.472 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 800ms
2023-07-24 20:55:18.484 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 810ms
2023-07-24 20:55:18.496 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 820ms
2023-07-24 20:55:18.508 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 830ms
2023-07-24 20:55:18.520 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 840ms
2023-07-24 20:55:18.532 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 850ms
2023-07-24 20:55:18.544 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 860ms
2023-07-24 20:55:18.556 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 870ms
2023-07-24 20:55:18.568 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 880ms
2023-07-24 20:55:18.580 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 890ms
2023-07-24 20:55:18.592 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 900ms
2023-07-24 20:55:18.604 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 910ms
2023-07-24 20:55:18.616 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 920ms
2023-07-24 20:55:18.628 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 930ms
2023-07-24 20:55:18.640 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 940ms
2023-07-24 20:55:18.652 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 950ms
2023-07-24 20:55:18.664 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 960ms
2023-07-24 20:55:18.676 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 970ms
2023-07-24 20:55:18.689 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 980ms
2023-07-24 20:55:18.701 DEBUG (MainThread) [custom_components.chime_tts] ...waiting for TTS file for 990ms
2023-07-24 20:55:18.713 DEBUG (MainThread) [custom_components.chime_tts] TTS file not found on filesystem after waiting 1000ms
2023-07-24 20:55:18.713 DEBUG (MainThread) [custom_components.chime_tts] get_audio_from_path("custom_components/chime_tts/mp3s/bright.mp3", 450.0, audio)
2023-07-24 20:55:18.714 WARNING (MainThread) [custom_components.chime_tts] Audio filepath does not exist: "custom_components/chime_tts/mp3s/bright.mp3"
2023-07-24 20:55:18.717 DEBUG (MainThread) [custom_components.chime_tts] - audio_dict = None
2023-07-24 20:55:18.718 ERROR (MainThread) [custom_components.chime_tts] async_get_playback_audio_path --> Unable to generate audio for playback

@Nimrod_Dolev Thanks v0.5.4 fixes the volume issue as well.

For announce, I was able to confirm that announce works as expected using media_player.play_media, but not with chime_tts. I think this is just because you’re checking for the media_player.MediaPlayerEntityFeature.MEDIA_ANNOUNCE feature flag (line 175 in __init__.py). This flag is in the dev branch of home assistant, but it doesn’t look like it’s made its way into any of the release tags yet.

1 Like

@Bramus I think I managed to solve the issue. Please update to v0.5.5 and let me know.

1 Like

@jreed509 I removed the feature flag check logic in v0.5.5

Thanks for fixing some stuff. I just tested, now i’m getting a bit further in the process. The file seems to be generated except for the TTS content. Think there still is a bug in the path.

My media_player.kantoor is a HomePod Mini, that resumes the playback of for example Spotify with SpoCon, but nothing is being played.

Below the output of the log

2023-07-26 15:16:51.430 DEBUG (MainThread) [custom_components.chime_tts] ----- Chime TTS Say Called -----
2023-07-26 15:16:51.430 DEBUG (MainThread) [custom_components.chime_tts] * hass = <homeassistant.core.HomeAssistant object at 0x744502f0>
2023-07-26 15:16:51.431 DEBUG (MainThread) [custom_components.chime_tts] * chime_path = custom_components/chime_tts/mp3s/tada.mp3
2023-07-26 15:16:51.431 DEBUG (MainThread) [custom_components.chime_tts] * end_chime_path = custom_components/chime_tts/mp3s/bright.mp3
2023-07-26 15:16:51.431 DEBUG (MainThread) [custom_components.chime_tts] * delay = 450.0
2023-07-26 15:16:51.431 DEBUG (MainThread) [custom_components.chime_tts] * message = Hi Bram this is an test
2023-07-26 15:16:51.432 DEBUG (MainThread) [custom_components.chime_tts] * tts_platform = google_translate
2023-07-26 15:16:51.432 DEBUG (MainThread) [custom_components.chime_tts] * tts_playback_speed = 100.0
2023-07-26 15:16:51.432 DEBUG (MainThread) [custom_components.chime_tts] * entity_id = media_player.kantoor
2023-07-26 15:16:51.432 DEBUG (MainThread) [custom_components.chime_tts] * volume_level = 1.0
2023-07-26 15:16:51.433 DEBUG (MainThread) [custom_components.chime_tts] * cache = False
2023-07-26 15:16:51.433 DEBUG (MainThread) [custom_components.chime_tts] * announce = False
2023-07-26 15:16:51.433 DEBUG (MainThread) [custom_components.chime_tts] * language = nl
2023-07-26 15:16:51.433 DEBUG (MainThread) [custom_components.chime_tts] * tld = None
2023-07-26 15:16:51.434 DEBUG (MainThread) [custom_components.chime_tts] * gender = None
2023-07-26 15:16:51.434 DEBUG (MainThread) [custom_components.chime_tts] ------
2023-07-26 15:16:51.434 DEBUG (MainThread) [custom_components.chime_tts] async_get_playback_audio_path
2023-07-26 15:16:51.435 DEBUG (MainThread) [custom_components.chime_tts] get_audio_from_path("custom_components/chime_tts/mp3s/tada.mp3", 0, audio)
2023-07-26 15:16:51.438 DEBUG (MainThread) [custom_components.chime_tts] Retrieving audio from path: "/home/homeassistant/.homeassistant/custom_components/chime_tts/mp3s/tada.mp3"...
2023-07-26 15:16:51.774 DEBUG (MainThread) [custom_components.chime_tts] - ...audio with duration 2.323s retrieved successfully
2023-07-26 15:16:51.774 DEBUG (MainThread) [custom_components.chime_tts] async_request_tts_audio_filepath(hass, tts_platform="google_translate", message="Hi Bram this is an test", language="nl", tld="None", gender="None"))
2023-07-26 15:16:51.775 DEBUG (MainThread) [custom_components.chime_tts] Requesting TTS audio:
2023-07-26 15:16:51.775 DEBUG (MainThread) [custom_components.chime_tts] * url = http://192.168.2.25:8123/api/tts_get_url
2023-07-26 15:16:51.775 DEBUG (MainThread) [custom_components.chime_tts] * headers = {'Authorization': 'Bearer eyJhb##########mbW5k', 'Content-Type': 'application/json'}
2023-07-26 15:16:51.775 DEBUG (MainThread) [custom_components.chime_tts] * data = {"message": "Hi Bram this is an test", "platform": "google_translate", "cache": true, "language": "nl"}
2023-07-26 15:16:51.775 DEBUG (MainThread) [custom_components.chime_tts] * timeout = 10
2023-07-26 15:16:51.796 DEBUG (MainThread) [custom_components.chime_tts] - Repsonse status_code: "200"
2023-07-26 15:16:51.796 DEBUG (MainThread) [custom_components.chime_tts] - Repsonse received: "{"url":"http://192.168.2.25:8123/api/tts_proxy/7944c5f87770f2710f409032dd78d78b3aeea91d_nl_-_google_translate.mp3","path":"/api/tts_proxy/7944c5f87770f2710f409032dd78d78b3aeea91d_nl_-_google_translate.mp3"}"
2023-07-26 15:16:51.797 DEBUG (MainThread) [custom_components.chime_tts] - TTS filepaths = {'path': '/config/tts/7944c5f87770f2710f409032dd78d78b3aeea91d_nl_-_google_translate.mp3', 'url': 'http://192.168.2.25:8123/api/tts_proxy/7944c5f87770f2710f409032dd78d78b3aeea91d_nl_-_google_translate.mp3'}
2023-07-26 15:16:51.797 DEBUG (MainThread) [custom_components.chime_tts] File not found at path: "/config/tts/7944c5f87770f2710f409032dd78d78b3aeea91d_nl_-_google_translate.mp3"
2023-07-26 15:16:51.797 DEBUG (MainThread) [custom_components.chime_tts] - TTS file path not found on filesystem.
2023-07-26 15:16:51.797 DEBUG (MainThread) [custom_components.chime_tts] get_audio_from_path("custom_components/chime_tts/mp3s/bright.mp3", 450.0, audio)
2023-07-26 15:16:51.798 DEBUG (MainThread) [custom_components.chime_tts] Retrieving audio from path: "/home/homeassistant/.homeassistant/custom_components/chime_tts/mp3s/bright.mp3"...
2023-07-26 15:16:52.062 DEBUG (MainThread) [custom_components.chime_tts] - ...audio with duration 0.637s retrieved successfully
2023-07-26 15:16:52.074 DEBUG (MainThread) [custom_components.chime_tts] - Final audio created:
2023-07-26 15:16:52.075 DEBUG (MainThread) [custom_components.chime_tts] - Duration = 3.41s
2023-07-26 15:16:52.075 DEBUG (MainThread) [custom_components.chime_tts] Create temporary mp3 file
2023-07-26 15:16:52.075 DEBUG (MainThread) [custom_components.chime_tts] Temp folder exists?
2023-07-26 15:16:52.075 DEBUG (MainThread) [custom_components.chime_tts] Creating temporary mp3 file...
2023-07-26 15:16:52.076 DEBUG (MainThread) [custom_components.chime_tts] temp_filename_obj = <tempfile._TemporaryFileWrapper object at 0x679717b0>
2023-07-26 15:16:52.077 DEBUG (MainThread) [custom_components.chime_tts] - Filepath = '/home/homeassistant/.homeassistant/media/sounds/temp/chime_tts/hj2m1ukm.mp3'
2023-07-26 15:16:52.658 DEBUG (MainThread) [custom_components.chime_tts] - File saved successfully
2023-07-26 15:16:52.659 DEBUG (MainThread) [custom_components.chime_tts] - audio_dict = {'audio_path': '/home/homeassistant/.homeassistant/media/sounds/temp/chime_tts/hj2m1ukm.mp3', 'audio_duration': 3.41}
2023-07-26 15:16:52.660 DEBUG (MainThread) [custom_components.chime_tts] - async_set_volume_level("media_player.kantoor", 1.0)
2023-07-26 15:16:52.660 DEBUG (MainThread) [custom_components.chime_tts] - Seting volume_level of media player "media_player.kantoor" to: 1.0
2023-07-26 15:16:52.795 DEBUG (MainThread) [custom_components.chime_tts] - Completed
2023-07-26 15:16:52.796 DEBUG (MainThread) [custom_components.chime_tts] Calling media_player.play_media service with data:
2023-07-26 15:16:52.796 DEBUG (MainThread) [custom_components.chime_tts] - media_content_id: /home/homeassistant/.homeassistantmedia-source://media_source/local/sounds/temp/chime_tts/hj2m1ukm.mp3
2023-07-26 15:16:52.796 DEBUG (MainThread) [custom_components.chime_tts] - media_content_type: music
2023-07-26 15:16:52.796 DEBUG (MainThread) [custom_components.chime_tts] - entity_id: media_player.kantoor

Think most important is the log below:

2023-07-26 15:16:51.775 DEBUG (MainThread) [custom_components.chime_tts] * data = {"message": "Hi Bram this is an test", "platform": "google_translate", "cache": true, "language": "nl"}
2023-07-26 15:16:51.775 DEBUG (MainThread) [custom_components.chime_tts] * timeout = 10
2023-07-26 15:16:51.796 DEBUG (MainThread) [custom_components.chime_tts] - Repsonse status_code: "200"
2023-07-26 15:16:51.796 DEBUG (MainThread) [custom_components.chime_tts] - Repsonse received: "{"url":"http://192.168.2.25:8123/api/tts_proxy/7944c5f87770f2710f409032dd78d78b3aeea91d_nl_-_google_translate.mp3","path":"/api/tts_proxy/7944c5f87770f2710f409032dd78d78b3aeea91d_nl_-_google_translate.mp3"}"
2023-07-26 15:16:51.797 DEBUG (MainThread) [custom_components.chime_tts] - TTS filepaths = {'path': '/config/tts/7944c5f87770f2710f409032dd78d78b3aeea91d_nl_-_google_translate.mp3', 'url': 'http://192.168.2.25:8123/api/tts_proxy/7944c5f87770f2710f409032dd78d78b3aeea91d_nl_-_google_translate.mp3'}
2023-07-26 15:16:51.797 DEBUG (MainThread) [custom_components.chime_tts] File not found at path: "/config/tts/7944c5f87770f2710f409032dd78d78b3aeea91d_nl_-_google_translate.mp3"
2023-07-26 15:16:51.797 DEBUG (MainThread) [custom_components.chime_tts] - TTS file path not found on filesystem.
2023-07-26 15:16:51.797 DEBUG (MainThread) [custom_components.chime_tts] get_audio_from_path("custom_components/chime_tts/mp3s/bright.mp3", 450.0, audio)

@Bramus l agree that the path to the TTS audio file is still incorrect. Are you able to please send me the full path to the TTS file on your HA file system? It might point me in the right direction.

the full path should be:

/home/homeassistant/.homeassistant/tts/

With v0.5.5 I’m getting this error whenever I call chime_tts:

2023-07-26 09:51:49.540 DEBUG (MainThread) [custom_components.chime_tts] ----- Chime TTS Say Called -----
2023-07-26 09:51:49.540 DEBUG (MainThread) [custom_components.chime_tts]  * hass = <homeassistant.core.HomeAssistant object at 0x7f644c34ca90>
2023-07-26 09:51:49.540 DEBUG (MainThread) [custom_components.chime_tts]  * chime_path = custom_components/chime_tts/mp3s/bells.mp3
2023-07-26 09:51:49.541 DEBUG (MainThread) [custom_components.chime_tts]  * end_chime_path = 
2023-07-26 09:51:49.541 DEBUG (MainThread) [custom_components.chime_tts]  * delay = 450.0
2023-07-26 09:51:49.541 DEBUG (MainThread) [custom_components.chime_tts]  * message = Hello world! 4839
2023-07-26 09:51:49.541 DEBUG (MainThread) [custom_components.chime_tts]  * tts_platform = tts.piper
2023-07-26 09:51:49.541 DEBUG (MainThread) [custom_components.chime_tts]  * tts_playback_speed = 100.0
2023-07-26 09:51:49.541 DEBUG (MainThread) [custom_components.chime_tts]  * entity_id = media_player.workshop_sonos
2023-07-26 09:51:49.541 DEBUG (MainThread) [custom_components.chime_tts]  * volume_level = 0.4
2023-07-26 09:51:49.541 DEBUG (MainThread) [custom_components.chime_tts]  * cache = True
2023-07-26 09:51:49.541 DEBUG (MainThread) [custom_components.chime_tts]  * announce = True
2023-07-26 09:51:49.541 DEBUG (MainThread) [custom_components.chime_tts]  * language = None
2023-07-26 09:51:49.541 DEBUG (MainThread) [custom_components.chime_tts]  * tld = None
2023-07-26 09:51:49.541 DEBUG (MainThread) [custom_components.chime_tts]  * gender = None
2023-07-26 09:51:49.541 DEBUG (MainThread) [custom_components.chime_tts] ------
2023-07-26 09:51:49.541 DEBUG (MainThread) [custom_components.chime_tts] async_get_playback_audio_path
2023-07-26 09:51:49.541 DEBUG (MainThread) [custom_components.chime_tts] Attempting to retrieve generated mp3 file from cache
2023-07-26 09:51:49.541 DEBUG (MainThread) [custom_components.chime_tts]  - async_get_cached_audio_data('be235703a0738e63ff6eb7e612ed9e422089eb4a4692e1709ff7c34490c8e2ce')
2023-07-26 09:51:49.541 DEBUG (MainThread) [custom_components.chime_tts]  - Audio data not found in cache.
2023-07-26 09:51:49.541 DEBUG (MainThread) [custom_components.chime_tts] No previously generated mp3 file found
2023-07-26 09:51:49.541 DEBUG (MainThread) [custom_components.chime_tts] get_audio_from_path("custom_components/chime_tts/mp3s/bells.mp3", 0, audio)
2023-07-26 09:51:49.541 DEBUG (MainThread) [custom_components.chime_tts] Retrieving audio from path: "custom_components/chime_tts/mp3s/bells.mp3"...
2023-07-26 09:51:49.998 DEBUG (MainThread) [custom_components.chime_tts]  - ...audio with duration 0.944s retrieved successfully
2023-07-26 09:51:49.998 DEBUG (MainThread) [custom_components.chime_tts] Cached TTS mp3 file exists?
2023-07-26 09:51:49.998 DEBUG (MainThread) [custom_components.chime_tts]  - async_get_cached_audio_data('2577a2e350ae18b717851563ef827b285649c553f9c5624000b9bccf08c6773f')
2023-07-26 09:51:49.998 DEBUG (MainThread) [custom_components.chime_tts]  - Audio data not found in cache.
2023-07-26 09:51:49.998 DEBUG (MainThread) [custom_components.chime_tts]  - Cached TTS mp3 file not found
2023-07-26 09:51:49.998 DEBUG (MainThread) [custom_components.chime_tts] async_request_tts_audio_filepath(hass, tts_platform="tts.piper", message="Hello world! 4839", language="None", tld="None", gender="None"))
2023-07-26 09:51:49.998 DEBUG (MainThread) [custom_components.chime_tts] Requesting TTS audio:
2023-07-26 09:51:49.998 DEBUG (MainThread) [custom_components.chime_tts]  * url     = http://192.168.55.150:8123/api/tts_get_url
2023-07-26 09:51:49.998 DEBUG (MainThread) [custom_components.chime_tts]  * headers = {'Authorization': 'Bearer eyJhb##########TsXEU', 'Content-Type': 'application/json'}
2023-07-26 09:51:49.998 DEBUG (MainThread) [custom_components.chime_tts]  * data    = {"message": "Hello world! 4839", "platform": "tts.piper", "cache": true}
2023-07-26 09:51:49.998 DEBUG (MainThread) [custom_components.chime_tts]  * timeout = 10
2023-07-26 09:51:50.022 DEBUG (MainThread) [custom_components.chime_tts]  - Repsonse status_code: "200"
2023-07-26 09:51:50.023 DEBUG (MainThread) [custom_components.chime_tts]  - Repsonse received: "{"url":"http://192.168.55.150:8123/api/tts_proxy/cbc457f55f797491214d46d58bf1c002ba06a5a3_en-us_a877e2b3bf_tts.piper.wav","path":"/api/tts_proxy/cbc457f55f797491214d46d58bf1c002ba06a5a3_en-us_a877e2b3bf_tts.piper.wav"}"
2023-07-26 09:51:50.023 DEBUG (MainThread) [custom_components.chime_tts]  - TTS filepaths = {'path': '/config/tts/cbc457f55f797491214d46d58bf1c002ba06a5a3_en-us_a877e2b3bf_tts.piper.wav', 'url': 'http://192.168.55.150:8123/api/tts_proxy/cbc457f55f797491214d46d58bf1c002ba06a5a3_en-us_a877e2b3bf_tts.piper.wav'}
2023-07-26 09:51:50.023 DEBUG (MainThread) [custom_components.chime_tts]  - TTS file path found: /config/tts/cbc457f55f797491214d46d58bf1c002ba06a5a3_en-us_a877e2b3bf_tts.piper.wav
2023-07-26 09:51:50.023 DEBUG (MainThread) [custom_components.chime_tts] Saving to chime_tts storage:
2023-07-26 09:51:50.023 DEBUG (MainThread) [custom_components.chime_tts] key:   "2577a2e350ae18b717851563ef827b285649c553f9c5624000b9bccf08c6773f"
2023-07-26 09:51:50.023 DEBUG (MainThread) [custom_components.chime_tts] value: "{'audio_path': '/config/tts/cbc457f55f797491214d46d58bf1c002ba06a5a3_en-us_a877e2b3bf_tts.piper.wav', 'audio_duration': None}"
2023-07-26 09:51:50.027 DEBUG (MainThread) [custom_components.chime_tts] get_audio_from_path("/config/tts/cbc457f55f797491214d46d58bf1c002ba06a5a3_en-us_a877e2b3bf_tts.piper.wav", 450.0, audio)
2023-07-26 09:51:50.027 DEBUG (MainThread) [custom_components.chime_tts] Retrieving audio from path: "/config/tts/cbc457f55f797491214d46d58bf1c002ba06a5a3_en-us_a877e2b3bf_tts.piper.wav"...
2023-07-26 09:51:50.027 DEBUG (MainThread) [custom_components.chime_tts]  - ...audio with duration 3.92s retrieved successfully
2023-07-26 09:51:50.030 DEBUG (MainThread) [custom_components.chime_tts] get_audio_from_path("", 450.0, audio)
2023-07-26 09:51:50.030 DEBUG (MainThread) [custom_components.chime_tts] Retrieving audio from path: "/"...
2023-07-26 09:51:50.031 ERROR (MainThread) [homeassistant.helpers.script.websocket_api_script] websocket_api script: Error executing script. Unexpected error for call_service at pos 1: [Errno 21] Is a directory: '/'
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 468, in _async_step
    await getattr(self, handler)()
  File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 703, in _async_call_service_step
    response_data = await self._async_run_long_action(
                    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 665, in _async_run_long_action
    return long_task.result()
           ^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/core.py", line 1965, in async_call
    response_data = await coro
                    ^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/core.py", line 2005, in _execute_service
    return await cast(
           ^^^^^^^^^^^
  File "/config/custom_components/chime_tts/__init__.py", line 144, in async_say
    audio_dict = await async_get_playback_audio_path(params)
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/chime_tts/__init__.py", line 462, in async_get_playback_audio_path
    output_audio = get_audio_from_path(hass, end_chime_path, delay, output_audio)
                   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/chime_tts/__init__.py", line 516, in get_audio_from_path
    audio_from_path = AudioSegment.from_file(filepath)
                      ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/pydub/audio_segment.py", line 651, in from_file
    file, close_file = _fd_or_path_or_tempfile(file, 'rb', tempfile=False)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/pydub/utils.py", line 60, in _fd_or_path_or_tempfile
    fd = open(fd, mode=mode)
         ^^^^^^^^^^^^^^^^^^^
IsADirectoryError: [Errno 21] Is a directory: '/'
2023-07-26 09:51:50.036 ERROR (MainThread) [homeassistant.components.websocket_api.http.connection] [140067690660752] Error handling message: Unknown error (unknown_error) Jonathan from 192.168.55.46 (Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/114.0.0.0 Safari/537.36)
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/websocket_api/decorators.py", line 26, in _handle_async_response
    await func(hass, connection, msg)
  File "/usr/src/homeassistant/homeassistant/components/websocket_api/commands.py", line 680, in handle_execute_script
    response = await script_obj.async_run(msg.get("variables"), context=context)
               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 1569, in async_run
    return await asyncio.shield(run.async_run())
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 420, in async_run
    await self._async_step(log_exceptions=False)
  File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 470, in _async_step
    self._handle_exception(
  File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 493, in _handle_exception
    raise exception
  File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 468, in _async_step
    await getattr(self, handler)()
  File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 703, in _async_call_service_step
    response_data = await self._async_run_long_action(
                    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 665, in _async_run_long_action
    return long_task.result()
           ^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/core.py", line 1965, in async_call
    response_data = await coro
                    ^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/core.py", line 2005, in _execute_service
    return await cast(
           ^^^^^^^^^^^
  File "/config/custom_components/chime_tts/__init__.py", line 144, in async_say
    audio_dict = await async_get_playback_audio_path(params)
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/chime_tts/__init__.py", line 462, in async_get_playback_audio_path
    output_audio = get_audio_from_path(hass, end_chime_path, delay, output_audio)
                   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/chime_tts/__init__.py", line 516, in get_audio_from_path
    audio_from_path = AudioSegment.from_file(filepath)
                      ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/pydub/audio_segment.py", line 651, in from_file
    file, close_file = _fd_or_path_or_tempfile(file, 'rb', tempfile=False)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/pydub/utils.py", line 60, in _fd_or_path_or_tempfile
    fd = open(fd, mode=mode)
         ^^^^^^^^^^^^^^^^^^^
IsADirectoryError: [Errno 21] Is a directory: '/'

Thanks @jreed509. I will release a fix ASAP.

I want to test to see if the TTS path can be called correctly when entered explicitly. Can you please go to the services tab in the developer tools and send the following service call?

service: chime_tts.say
data:
  delay: 450
  tts_playback_speed: 100
  chime_path: >-
    /home/homeassistant/.homeassistant/tts/7944c5f87770f2710f409032dd78d78b3aeea91d_nl_-_google_translate.mp3
  end_chime_path: custom_components/chime_tts/mp3s/bells.mp3
  message: Hi Bram this is a test
  tts_platform: google_translate
  entity_id: media_player.kantoor
  language: nl
  volume_level: 0.71
  cache: true

@jreed509 I just released a hotfix v0.5.6 - can you please let me know if it’s working again for you?

Seems like the path is not working as it still gives the error about the /config/tts/ file. See output below:

2023-07-26 17:40:38.907 DEBUG (MainThread) [custom_components.chime_tts] ----- Chime TTS Say Called -----
2023-07-26 17:40:38.908 DEBUG (MainThread) [custom_components.chime_tts] * hass = <homeassistant.core.HomeAssistant object at 0x744502f0>
2023-07-26 17:40:38.908 DEBUG (MainThread) [custom_components.chime_tts] * chime_path = /home/homeassistant/.homeassistant/tts/7944c5f87770f2710f409032dd78d78b3aeea91d_nl_-_google_translate.mp3
2023-07-26 17:40:38.908 DEBUG (MainThread) [custom_components.chime_tts] * end_chime_path = custom_components/chime_tts/mp3s/bells.mp3
2023-07-26 17:40:38.909 DEBUG (MainThread) [custom_components.chime_tts] * delay = 450.0
2023-07-26 17:40:38.909 DEBUG (MainThread) [custom_components.chime_tts] * message = Hi Bram this is a test
2023-07-26 17:40:38.909 DEBUG (MainThread) [custom_components.chime_tts] * tts_platform = google_translate
2023-07-26 17:40:38.909 DEBUG (MainThread) [custom_components.chime_tts] * tts_playback_speed = 100.0
2023-07-26 17:40:38.910 DEBUG (MainThread) [custom_components.chime_tts] * entity_id = media_player.woonkamer
2023-07-26 17:40:38.910 DEBUG (MainThread) [custom_components.chime_tts] * volume_level = 0.71
2023-07-26 17:40:38.910 DEBUG (MainThread) [custom_components.chime_tts] * cache = True
2023-07-26 17:40:38.911 DEBUG (MainThread) [custom_components.chime_tts] * announce = False
2023-07-26 17:40:38.911 DEBUG (MainThread) [custom_components.chime_tts] * language = nl
2023-07-26 17:40:38.911 DEBUG (MainThread) [custom_components.chime_tts] * tld = None
2023-07-26 17:40:38.912 DEBUG (MainThread) [custom_components.chime_tts] * gender = None
2023-07-26 17:40:38.912 DEBUG (MainThread) [custom_components.chime_tts] ------
2023-07-26 17:40:38.916 DEBUG (MainThread) [custom_components.chime_tts] async_get_playback_audio_path
2023-07-26 17:40:38.917 DEBUG (MainThread) [custom_components.chime_tts] Attempting to retrieve generated mp3 file from cache
2023-07-26 17:40:38.917 DEBUG (MainThread) [custom_components.chime_tts] - async_get_cached_audio_data('487cbce769bfab5e71b86abd869b7c8efc3e4b506912ef0d738e50ba45d01629')
2023-07-26 17:40:38.918 DEBUG (MainThread) [custom_components.chime_tts] - Audio data not found in cache.
2023-07-26 17:40:38.918 DEBUG (MainThread) [custom_components.chime_tts] No previously generated mp3 file found
2023-07-26 17:40:38.918 DEBUG (MainThread) [custom_components.chime_tts] get_audio_from_path("/home/homeassistant/.homeassistant/tts/7944c5f87770f2710f409032dd78d78b3aeea91d_nl_-_google_translate.mp3", 0, audio)
2023-07-26 17:40:38.919 DEBUG (MainThread) [custom_components.chime_tts] Retrieving audio from path: "/home/homeassistant/.homeassistant/tts/7944c5f87770f2710f409032dd78d78b3aeea91d_nl_-_google_translate.mp3"...
2023-07-26 17:40:41.219 DEBUG (MainThread) [custom_components.chime_tts] - ...audio with duration 2.4s retrieved successfully
2023-07-26 17:40:41.219 DEBUG (MainThread) [custom_components.chime_tts] Cached TTS mp3 file exists?
2023-07-26 17:40:41.219 DEBUG (MainThread) [custom_components.chime_tts] - async_get_cached_audio_data('d0f068467344cc731c5ef93696e90cb681e084f8a3a8538721a681a28f4c84f8')
2023-07-26 17:40:41.220 DEBUG (MainThread) [custom_components.chime_tts] - Audio data not found in cache.
2023-07-26 17:40:41.220 DEBUG (MainThread) [custom_components.chime_tts] - Cached TTS mp3 file not found
2023-07-26 17:40:41.220 DEBUG (MainThread) [custom_components.chime_tts] async_request_tts_audio_filepath(hass, tts_platform="google_translate", message="Hi Bram this is a test", language="nl", tld="None", gender="None"))
2023-07-26 17:40:41.221 DEBUG (MainThread) [custom_components.chime_tts] Requesting TTS audio:
2023-07-26 17:40:41.221 DEBUG (MainThread) [custom_components.chime_tts] * url = http://192.168.2.25:8123/api/tts_get_url
2023-07-26 17:40:41.222 DEBUG (MainThread) [custom_components.chime_tts] * headers = {'Authorization': 'Bearer eyJhb##########mbW5k', 'Content-Type': 'application/json'}
2023-07-26 17:40:41.222 DEBUG (MainThread) [custom_components.chime_tts] * data = {"message": "Hi Bram this is a test", "platform": "google_translate", "cache": true, "language": "nl"}
2023-07-26 17:40:41.222 DEBUG (MainThread) [custom_components.chime_tts] * timeout = 10
2023-07-26 17:40:41.562 DEBUG (MainThread) [custom_components.chime_tts] - Repsonse status_code: "200"
2023-07-26 17:40:41.562 DEBUG (MainThread) [custom_components.chime_tts] - Repsonse received: "{"url":"http://192.168.2.25:8123/api/tts_proxy/81e1ddbfa91c6c9a0926c017af4b0570220892b0_nl_-_google_translate.mp3","path":"/api/tts_proxy/81e1ddbfa91c6c9a0926c017af4b0570220892b0_nl_-_google_translate.mp3"}"
2023-07-26 17:40:41.562 DEBUG (MainThread) [custom_components.chime_tts] - TTS filepaths = {'path': '/config/tts/81e1ddbfa91c6c9a0926c017af4b0570220892b0_nl_-_google_translate.mp3', 'url': 'http://192.168.2.25:8123/api/tts_proxy/81e1ddbfa91c6c9a0926c017af4b0570220892b0_nl_-_google_translate.mp3'}
2023-07-26 17:40:41.564 DEBUG (MainThread) [custom_components.chime_tts] File not found at path: "/config/tts/81e1ddbfa91c6c9a0926c017af4b0570220892b0_nl_-_google_translate.mp3"
2023-07-26 17:40:41.564 DEBUG (MainThread) [custom_components.chime_tts] - TTS file path not found on filesystem.
2023-07-26 17:40:41.565 DEBUG (MainThread) [custom_components.chime_tts] get_audio_from_path("custom_components/chime_tts/mp3s/bells.mp3", 450.0, audio)
2023-07-26 17:40:41.598 DEBUG (MainThread) [custom_components.chime_tts] Retrieving audio from path: "/home/homeassistant/.homeassistant/custom_components/chime_tts/mp3s/bells.mp3"...
2023-07-26 17:40:41.890 DEBUG (MainThread) [custom_components.chime_tts] - ...audio with duration 0.944s retrieved successfully
2023-07-26 17:40:41.903 DEBUG (MainThread) [custom_components.chime_tts] - Final audio created:
2023-07-26 17:40:41.903 DEBUG (MainThread) [custom_components.chime_tts] - Duration = 3.794s
2023-07-26 17:40:41.903 DEBUG (MainThread) [custom_components.chime_tts] Create temporary mp3 file
2023-07-26 17:40:41.904 DEBUG (MainThread) [custom_components.chime_tts] Temp folder exists?
2023-07-26 17:40:41.905 DEBUG (MainThread) [custom_components.chime_tts] Creating temporary mp3 file...
2023-07-26 17:40:41.907 DEBUG (MainThread) [custom_components.chime_tts] temp_filename_obj = <tempfile._TemporaryFileWrapper object at 0x50c1edf0>
2023-07-26 17:40:41.908 DEBUG (MainThread) [custom_components.chime_tts] - Filepath = '/home/homeassistant/.homeassistant/media/sounds/temp/chime_tts/cotpiv7i.mp3'
2023-07-26 17:40:42.286 DEBUG (MainThread) [custom_components.chime_tts] - File saved successfully
2023-07-26 17:40:42.287 DEBUG (MainThread) [custom_components.chime_tts] - audio_dict = {'audio_path': '/home/homeassistant/.homeassistant/media/sounds/temp/chime_tts/cotpiv7i.mp3', 'audio_duration': 3.794}
2023-07-26 17:40:42.287 DEBUG (MainThread) [custom_components.chime_tts] - async_set_volume_level("media_player.woonkamer", 0.71)
2023-07-26 17:40:42.287 DEBUG (MainThread) [custom_components.chime_tts] - Seting volume_level of media player "media_player.woonkamer" to: 0.71
2023-07-26 17:40:42.726 DEBUG (MainThread) [custom_components.chime_tts] - Completed
2023-07-26 17:40:42.726 DEBUG (MainThread) [custom_components.chime_tts] Calling media_player.play_media service with data:
2023-07-26 17:40:42.726 DEBUG (MainThread) [custom_components.chime_tts] - media_content_id: /home/homeassistant/.homeassistantmedia-source://media_source/local/sounds/temp/chime_tts/cotpiv7i.mp3
2023-07-26 17:40:42.726 DEBUG (MainThread) [custom_components.chime_tts] - media_content_type: music
2023-07-26 17:40:42.726 DEBUG (MainThread) [custom_components.chime_tts] - entity_id: media_player.woonkamer

Yep v0.5.6 isn’t working for me either. I can only hear TTS messages from previously cached messages, but any new text just plays the start chime sound:

2023-07-26 11:55:20.670 DEBUG (MainThread) [custom_components.chime_tts] ----- Chime TTS Say Called -----
2023-07-26 11:55:20.670 DEBUG (MainThread) [custom_components.chime_tts] * hass = <homeassistant.core.HomeAssistant object at 0x7fc44c6b28d0>
2023-07-26 11:55:20.670 DEBUG (MainThread) [custom_components.chime_tts] * chime_path = custom_components/chime_tts/mp3s/bells.mp3
2023-07-26 11:55:20.670 DEBUG (MainThread) [custom_components.chime_tts] * end_chime_path =
2023-07-26 11:55:20.671 DEBUG (MainThread) [custom_components.chime_tts] * delay = 450.0
2023-07-26 11:55:20.671 DEBUG (MainThread) [custom_components.chime_tts] * message = Hello world! 19874
2023-07-26 11:55:20.671 DEBUG (MainThread) [custom_components.chime_tts] * tts_platform = tts.piper
2023-07-26 11:55:20.671 DEBUG (MainThread) [custom_components.chime_tts] * tts_playback_speed = 100.0
2023-07-26 11:55:20.671 DEBUG (MainThread) [custom_components.chime_tts] * entity_id = media_player.workshop_sonos
2023-07-26 11:55:20.671 DEBUG (MainThread) [custom_components.chime_tts] * volume_level = 0.52
2023-07-26 11:55:20.671 DEBUG (MainThread) [custom_components.chime_tts] * cache = True
2023-07-26 11:55:20.671 DEBUG (MainThread) [custom_components.chime_tts] * announce = True
2023-07-26 11:55:20.671 DEBUG (MainThread) [custom_components.chime_tts] * language = None
2023-07-26 11:55:20.671 DEBUG (MainThread) [custom_components.chime_tts] * tld = None
2023-07-26 11:55:20.671 DEBUG (MainThread) [custom_components.chime_tts] * gender = None
2023-07-26 11:55:20.671 DEBUG (MainThread) [custom_components.chime_tts] ------
2023-07-26 11:55:20.671 DEBUG (MainThread) [custom_components.chime_tts] async_get_playback_audio_path
2023-07-26 11:55:20.671 DEBUG (MainThread) [custom_components.chime_tts] Attempting to retrieve generated mp3 file from cache
2023-07-26 11:55:20.671 DEBUG (MainThread) [custom_components.chime_tts] - async_get_cached_audio_data('eb5de0339e3d16deac8d84c2955d8d0fefc5e6f7aa10426b7798014ca081aa44')
2023-07-26 11:55:20.671 DEBUG (MainThread) [custom_components.chime_tts] - Audio data not found in cache.
2023-07-26 11:55:20.671 DEBUG (MainThread) [custom_components.chime_tts] No previously generated mp3 file found
2023-07-26 11:55:20.671 DEBUG (MainThread) [custom_components.chime_tts] get_audio_from_path("custom_components/chime_tts/mp3s/bells.mp3", 0, audio)
2023-07-26 11:55:20.671 DEBUG (MainThread) [custom_components.chime_tts] Retrieving audio from path: "custom_components/chime_tts/mp3s/bells.mp3"...
2023-07-26 11:55:20.762 DEBUG (MainThread) [custom_components.chime_tts] - ...audio with duration 0.944s retrieved successfully
2023-07-26 11:55:20.762 DEBUG (MainThread) [custom_components.chime_tts] Cached TTS mp3 file exists?
2023-07-26 11:55:20.762 DEBUG (MainThread) [custom_components.chime_tts] - async_get_cached_audio_data('807b2952721427c5057d83f46aaf724b0d679ad974f5b7e5a88c6a1f4ef686c7')
2023-07-26 11:55:20.762 DEBUG (MainThread) [custom_components.chime_tts] - Audio data not found in cache.
2023-07-26 11:55:20.762 DEBUG (MainThread) [custom_components.chime_tts] - Cached TTS mp3 file not found
2023-07-26 11:55:20.762 DEBUG (MainThread) [custom_components.chime_tts] async_request_tts_audio_filepath(hass, tts_platform="tts.piper", message="Hello world! 19874", language="None", tld="None", gender="None"))
2023-07-26 11:55:20.762 DEBUG (MainThread) [custom_components.chime_tts] Requesting TTS audio:
2023-07-26 11:55:20.762 DEBUG (MainThread) [custom_components.chime_tts] * url = http://192.168.55.150:8123/api/tts_get_url
2023-07-26 11:55:20.762 DEBUG (MainThread) [custom_components.chime_tts] * headers = {'Authorization': 'Bearer eyJhb##########TsXEU', 'Content-Type': 'application/json'}
2023-07-26 11:55:20.762 DEBUG (MainThread) [custom_components.chime_tts] * data = {"message": "Hello world! 19874", "platform": "tts.piper", "cache": true}
2023-07-26 11:55:20.762 DEBUG (MainThread) [custom_components.chime_tts] * timeout = 10
2023-07-26 11:55:20.773 DEBUG (MainThread) [custom_components.chime_tts] - Repsonse status_code: "200"
2023-07-26 11:55:20.773 DEBUG (MainThread) [custom_components.chime_tts] - Repsonse received: "{"url":"http://192.168.55.150:8123/api/tts_proxy/c388341a1598509358847be4382bdd6b9ca2f6ba_en-us_a877e2b3bf_tts.piper.wav","path":"/api/tts_proxy/c388341a1598509358847be4382bdd6b9ca2f6ba_en-us_a877e2b3bf_tts.piper.wav"}"
2023-07-26 11:55:20.773 DEBUG (MainThread) [custom_components.chime_tts] - TTS filepaths = {'path': '/config/tts/c388341a1598509358847be4382bdd6b9ca2f6ba_en-us_a877e2b3bf_tts.piper.wav', 'url': 'http://192.168.55.150:8123/api/tts_proxy/c388341a1598509358847be4382bdd6b9ca2f6ba_en-us_a877e2b3bf_tts.piper.wav'}
2023-07-26 11:55:20.773 DEBUG (MainThread) [custom_components.chime_tts] File not found at path: "/config/tts/c388341a1598509358847be4382bdd6b9ca2f6ba_en-us_a877e2b3bf_tts.piper.wav"
2023-07-26 11:55:20.773 DEBUG (MainThread) [custom_components.chime_tts] - TTS file path not found on filesystem.
2023-07-26 11:55:20.773 DEBUG (MainThread) [custom_components.chime_tts] get_audio_from_path("", 450.0, audio)
2023-07-26 11:55:20.773 DEBUG (MainThread) [custom_components.chime_tts] - Final audio created:
2023-07-26 11:55:20.774 DEBUG (MainThread) [custom_components.chime_tts] - Duration = 0.944s
2023-07-26 11:55:20.774 DEBUG (MainThread) [custom_components.chime_tts] Create temporary mp3 file
2023-07-26 11:55:20.774 DEBUG (MainThread) [custom_components.chime_tts] Temp folder exists?
2023-07-26 11:55:20.774 DEBUG (MainThread) [custom_components.chime_tts] Creating temporary mp3 file...
2023-07-26 11:55:20.774 DEBUG (MainThread) [custom_components.chime_tts] temp_filename_obj = <tempfile._TemporaryFileWrapper object at 0x7fc41a559790>
2023-07-26 11:55:20.775 DEBUG (MainThread) [custom_components.chime_tts] - Filepath = '/media/sounds/temp/chime_tts/lqrqauzj.mp3'
2023-07-26 11:55:20.829 DEBUG (MainThread) [custom_components.chime_tts] - File saved successfully
2023-07-26 11:55:20.829 DEBUG (MainThread) [custom_components.chime_tts] - audio_dict = {'audio_path': '/media/sounds/temp/chime_tts/lqrqauzj.mp3', 'audio_duration': 0.944}
2023-07-26 11:55:20.829 DEBUG (MainThread) [custom_components.chime_tts] - async_set_volume_level("media_player.workshop_sonos", 0.52)
2023-07-26 11:55:20.829 DEBUG (MainThread) [custom_components.chime_tts] - Seting volume_level of media player "media_player.workshop_sonos" to: 0.52
2023-07-26 11:55:20.839 DEBUG (MainThread) [custom_components.chime_tts] - Completed
2023-07-26 11:55:20.839 DEBUG (MainThread) [custom_components.chime_tts] Calling media_player.play_media service with data:
2023-07-26 11:55:20.839 DEBUG (MainThread) [custom_components.chime_tts] - media_content_id: media-source://media_source/local/sounds/temp/chime_tts/lqrqauzj.mp3
2023-07-26 11:55:20.839 DEBUG (MainThread) [custom_components.chime_tts] - media_content_type: music
2023-07-26 11:55:20.839 DEBUG (MainThread) [custom_components.chime_tts] - entity_id: media_player.workshop_sonos
2023-07-26 11:55:20.839 DEBUG (MainThread) [custom_components.chime_tts] - announce: True
2023-07-26 11:55:20.855 DEBUG (MainThread) [custom_components.chime_tts] ...media_player.play_media completed.
2023-07-26 11:55:20.855 DEBUG (MainThread) [custom_components.chime_tts] Returning volume level to 0.32 in 0.944s...
2023-07-26 11:55:21.799 DEBUG (MainThread) [custom_components.chime_tts] - async_set_volume_level("media_player.workshop_sonos", 0.32)
2023-07-26 11:55:21.799 DEBUG (MainThread) [custom_components.chime_tts] - Seting volume_level of media player "media_player.workshop_sonos" to: 0.32
2023-07-26 11:55:21.808 DEBUG (MainThread) [custom_components.chime_tts] - Completed
2023-07-26 11:55:21.808 DEBUG (MainThread) [custom_components.chime_tts] ...volume level restored
2023-07-26 11:55:21.808 DEBUG (MainThread) [custom_components.chime_tts] Saving generated mp3 file to cache
2023-07-26 11:55:21.808 DEBUG (MainThread) [custom_components.chime_tts] Saving to chime_tts storage:
2023-07-26 11:55:21.808 DEBUG (MainThread) [custom_components.chime_tts] key: "eb5de0339e3d16deac8d84c2955d8d0fefc5e6f7aa10426b7798014ca081aa44"
2023-07-26 11:55:21.808 DEBUG (MainThread) [custom_components.chime_tts] value: "{'audio_path': '/media/sounds/temp/chime_tts/lqrqauzj.mp3', 'audio_duration': 0.944}"
2023-07-26 11:55:21.810 DEBUG (MainThread) [custom_components.chime_tts] ----- Chime TTS Say Completed in 1139.819 ms -----

@Bramus it looks like there is an issue with both the path to the TTS audio file and the media source path of the generated media file: media_content_id: /home/homeassistant/.homeassistantmedia-source://media_source/local/sounds/temp/chime_tts/cotpiv7i.mp3

I have released another bugfix version, v0.5.7. Please let me know if the issue is fixed or if it persists.