removed directory assumptions, trying to use chdir
This commit is contained in:
parent
2141abae5e
commit
ee267275d6
2 changed files with 9 additions and 9 deletions
|
|
@ -18,7 +18,9 @@ class YoutubeDL(BotBaseCog):
|
|||
url = ctx.message.content.split(" ")[1]
|
||||
url = '"' + url + '"'
|
||||
video_or_audio = ctx.message.content.split(" ")[2]
|
||||
process = subprocess.Popen(["python3", "data/ytdl/youtubedl.py", url, video_or_audio])
|
||||
os.chdir("data/ytdl")
|
||||
process = subprocess.Popen(["python3", "youtubedl.py", url, video_or_audio])
|
||||
os.chdir("../../")
|
||||
process.wait()
|
||||
self.logger.exception(process.stdout)
|
||||
self.logger.exception(process.stderr)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue