From 9d97399504ae81fb443606666b1b63c5632e6c9a Mon Sep 17 00:00:00 2001 From: Samlon Date: Mon, 11 Aug 2025 17:55:20 +0200 Subject: more logs!?!?! --- cogs/tts.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'cogs/tts.py') diff --git a/cogs/tts.py b/cogs/tts.py index dceb26c..8076a2d 100644 --- a/cogs/tts.py +++ b/cogs/tts.py @@ -22,12 +22,13 @@ class TTS(commands.Cog): tts.save('tts.mp3') if output == "file": await ctx.respond(file=discord.File('tts.mp3')) + logger.info("TTS file sent") os.remove('tts.mp3') elif output == "vc": # Check if the user is in a voice channel if not (ctx.author.voice and ctx.author.voice.channel): await ctx.respond("Musisz być na kanale głosowym, aby odtworzyć TTS!", ephemeral=True) - logger.info("tts: User is not in a voice channel") + logger.info("User is not in a voice channel") os.remove('tts.mp3') return channel = ctx.author.voice.channel @@ -40,6 +41,7 @@ class TTS(commands.Cog): # Play the TTS audio if not voice_client.is_playing(): audio_source = discord.FFmpegPCMAudio('tts.mp3', options='-filter:a "volume=6"') + logger.info("TTS audio played") voice_client.play(audio_source) # Wait for playback to finish while voice_client.is_playing(): @@ -47,6 +49,7 @@ class TTS(commands.Cog): os.remove('tts.mp3') else: await ctx.respond("Nieznany sposób odtwarzania.", ephemeral=True) + logger.info("Unknown playback method") os.remove('tts.mp3') -- cgit v1.2.3