This commit is contained in:
Saifeddine ALOUI 2024-05-24 23:14:34 +02:00
parent 27b4964cb9
commit b65fb56a6c
2 changed files with 7 additions and 4 deletions

View File

@ -192,8 +192,8 @@ class LollmsASR:
self.app.success("asr Service is now available.") self.app.success("asr Service is now available.")
self.ready = True self.ready = True
return True return True
except: except Exception as ex:
pass trace_exception(ex)
retries += 1 retries += 1
ASCIIColors.yellow("Waiting for asr...") ASCIIColors.yellow("Waiting for asr...")

View File

@ -218,14 +218,17 @@ class LollmsXTTS(LollmsTTS):
if response.status_code == 200: if response.status_code == 200:
self.update_settings() self.update_settings()
print(f"voices_folder is {self.voices_folder}.") print(f"voices_folder is {self.voices_folder}.")
self.ready = True
if self.voices_folder is not None: if self.voices_folder is not None:
print("Generating sample audio.") print("Generating sample audio.")
voice_file = [v for v in self.voices_folder.iterdir() if v.suffix==".wav"] voice_file = [v for v in self.voices_folder.iterdir() if v.suffix==".wav"]
try:
self.tts_audio("x t t s is ready",voice_file[0].stem) self.tts_audio("x t t s is ready",voice_file[0].stem)
except Exception as ex:
return True
print("Service is available.") print("Service is available.")
if self.app is not None: if self.app is not None:
self.app.success("XTTS Service is now available.") self.app.success("XTTS Service is now available.")
self.ready = True
return True return True
except: except:
pass pass