From a02f122c91f4b89892204a637b80f7a7e80a2837 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Erik=20Hedenstr=C3=B6m?= <erik@hedenstroem.com>
Date: Tue, 18 Jun 2024 15:52:25 +0000
Subject: [PATCH] More logging

---
 openai_stt/stt.py | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/openai_stt/stt.py b/openai_stt/stt.py
index 2c7c992..48a0203 100644
--- a/openai_stt/stt.py
+++ b/openai_stt/stt.py
@@ -130,8 +130,10 @@ class OpenAISTTProvider(Provider):
                         return SpeechResult(json_response["text"], SpeechResultState.SUCCESS)
                     else:
                         text = await response.text()
+                        _LOGGER.warning("{}:{}".format(response.status, text))
                         return SpeechResult("", SpeechResultState.ERROR)
         except Exception as e:
+            _LOGGER.warning(e)
             return SpeechResult("", SpeechResultState.ERROR)
         finally:
             if 'file_to_send' in locals():
-- 
GitLab