I have a problem with "[mp3 @ 000001dc99bec540] Estimating duration from bitrate, this may be inaccurate", using discord.py. Everything works (bot is speaking the text, which we tell him), but, at the end, always shows it. How can I solve it?
if _command == "speak":
try:
await message.delete()
try:
error = _message[1]
except IndexError:
message = await _channel.send("Where is my text, which I have to speak?!")
await asyncio.sleep(3)
await message.delete()
return
channel = message.author.voice.channel
voice = discord.utils.get(client.voice_clients, guild=_guild)
if voice and voice.is_connected():
await voice.move_to(channel)
else:
voice = await channel.connect()
tts = gTTS(text=text, lang='en')
tts.save("pcvoice.mp3")
voice.play(discord.FFmpegPCMAudio(executable=r"C:\ffmpeg\bin\ffmpeg.exe", source="pcvoice.mp3"))
except discord.errors.ClientException:
await _channel.send("Come on! I am already playing something!")
This is a perfectly normal FFmpeg debug print A way to disable this, while probably not the best is doing
or any other loglevel FFmpeg deems acceptable. This is generally bad because if FFmpeg is failing, you might want to know.