Skip to content

Commit

Permalink
fix: windows pipe error
Browse files Browse the repository at this point in the history
  • Loading branch information
kamui-fin committed Jun 9, 2024
1 parent 41c63f7 commit c421c9d
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions ytanki/ffmpeg.py
Original file line number Diff line number Diff line change
Expand Up @@ -39,14 +39,14 @@ def get_picture(self, dimensions):
+ '"'
)
if os.name == "nt":
extra_opts = {creationflags: subprocess.CREATE_NO_WINDOW}
extra_opts = {"creationflags": subprocess.CREATE_NO_WINDOW}
else:
extra_opts = {}

subprocess.run(
picture_command,
stdout=subprocess.DEVNULL,
stderr=subprocess.STDOUT,
stdout=subprocess.PIPE,
stderr=subprocess.PIPE,
shell=True,
**extra_opts,
)
Expand All @@ -69,14 +69,14 @@ def get_audio(self):
+ '"'
)
if os.name == "nt":
extra_opts = {creationflags: subprocess.CREATE_NO_WINDOW}
extra_opts = {"creationflags": subprocess.CREATE_NO_WINDOW}
else:
extra_opts = {}

subprocess.run(
audio_command,
stdout=subprocess.DEVNULL,
stderr=subprocess.STDOUT,
stdout=subprocess.PIPE,
stderr=subprocess.PIPE,
shell=True,
**extra_opts,
)
Expand Down

0 comments on commit c421c9d

Please sign in to comment.