'Kivy app audio file can't load on Android

I have an android kivy app in which a function I built to play a wav file.

   def pronounce_func(self):
    item = self.root.get_screen("xxxxxscreen").ids.pos.text
    voice = gtts.gTTS(item)
    voice.save("./temp.wav")
    sound = SoundLoader.load("./temp.wav")
    sound.play()
    time.sleep(2)
    sound.stop()
    os.remove("./temp.wav")

It was running fine in windows, but crashed when run in Android with this error.

[WARNING] [AudioSDL2   ] Unable to load /data/data/xxxxxxx/files/app/temp.wav:b'java.io.FileNotFoundException: /etc/timidity/freepats.cfg

This is my buildozer spec.

# (list) Source files to include (let empty to include all the files)
source.include_exts = py,png,jpg,kv,atlas,json,ttf,txt,wav
# (list) List of inclusions using pattern matching
source.include_patterns = assets/*,images/*.png, sound/*.wav
# (list) Permissions
android.permissions = INTERNET,WRITE_EXTERNAL_STORAGE,READ_EXTERNAL_STORAGE

Anyone can help with the situation please? Thanks



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source