I am trying to play audio in my python code where I am taking a response from a free dictionary API and trying to play the pronunciation of the word. I am doing a GET request from https://api.dictionaryapi.dev/api/v2/entries/en/hello and from the response I am extracting the audio URL from obj[0]['phonetics'][0]['audio'].
I am playing it using vlc
import vlc
url = obj[0]['phonetics'][0]['audio']
p = vlc.MediaPlayer("https:{}".format(url))
p.play()
It does play correctly, but after I quit my app it displays an error: [0000021593639c90] prefetch stream error: unimplemented query (264) in control
I was not able to find a way to remove this error. How do I stop it from printing this error message? Are there other alternatives to play the .mp3 from the URL? Any help is appreciated. Thanks.