From 51c6e6627e1aee855ee91ef9c4cc4598ef1f1bc7 Mon Sep 17 00:00:00 2001 From: Phixxy Date: Wed, 4 Sep 2024 22:24:40 -0700 Subject: [PATCH] fixed error with stderr/stdout --- cogs/ytdl.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/cogs/ytdl.py b/cogs/ytdl.py index cc7f1c2..e4c6d4f 100644 --- a/cogs/ytdl.py +++ b/cogs/ytdl.py @@ -20,8 +20,8 @@ class YoutubeDL(BotBaseCog): video_or_audio = ctx.message.content.split(" ")[2] process = subprocess.Popen(["python3", "data/ytdl/youtubedl.py", url, video_or_audio]) process.wait() - logging.error(process.stdout.read()) - logging.error(process.stderr.read()) + logging.error(process.stdout) + logging.error(process.stderr) logging.error(process.returncode) await ctx.send(f"Downloading {video_or_audio} from {url}...", suppress_embeds=True) except Exception as e: