jing332 / tts-server-android

这是一个Android系统TTS应用,内置微软演示接口,可自定义HTTP请求,可导入其他本地TTS引擎,以及根据中文双引号的简单旁白/对话识别朗读 ,还有自动重试,备用配置,文本替换等更多功能。
3.02k stars 242 forks source link

tts-server keeps crashing on Pixel 7 Pro running Android 14 #198

Open hjings opened 4 weeks ago

hjings commented 4 weeks ago

My phone is a Google Pixel 7 Pro running Android 14. I use built-in TTS engines as the system TTS, and try using it in Moon+ Reader Pro to read texts. But there isn't any voice, and the error message is:

2024-06-18T23:29:21.855
版本代码:9, 版本名称:0.9_202307261647
崩溃详情:
java.lang.NullPointerException: request.voiceName must not be null
    at com.github.jing332.tts_server_android.service.systts.SystemTtsService.onSynthesizeText(SystemTtsService.kt:327)
    at android.speech.tts.TextToSpeechService$SynthesisSpeechItem.playImpl(TextToSpeechService.java:1033)
    at android.speech.tts.TextToSpeechService$SpeechItem.play(TextToSpeechService.java:819)
    at android.speech.tts.TextToSpeechService$SynthHandler$1.run(TextToSpeechService.java:583)
    at android.os.Handler.handleCallback(Handler.java:959)
    at android.os.Handler.dispatchMessage(Handler.java:100)
    at android.os.Looper.loopOnce(Looper.java:232)
    at android.os.Looper.loop(Looper.java:317)
    at android.os.HandlerThread.run(HandlerThread.java:85)

Interestingly, I employ the same setting on my another phone running Android 13. The version of TTS-server installed on that phone is also 0.9_202307261647. And I also use TTS-server with Moon+ Reader Pro. It works.

Is this a problem caused by something changed in Android 14?