From a4dcb6ba13f0d99fb7dd118888e3a75f63bbaf6d Mon Sep 17 00:00:00 2001 From: Ricardo Date: Tue, 2 Jan 2024 19:05:03 +0000 Subject: [PATCH] pass env variables so it is possible to set https proxy env = dict(os.environ) env['http_proxy'] = proxy env['https_proxy'] = proxy --- ffmpeg/_run.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/ffmpeg/_run.py b/ffmpeg/_run.py index f42d1d73..e3d8aef4 100644 --- a/ffmpeg/_run.py +++ b/ffmpeg/_run.py @@ -202,6 +202,7 @@ def run_async( quiet=False, overwrite_output=False, cwd=None, + env=None ): """Asynchronously invoke ffmpeg for the supplied node graph. @@ -293,6 +294,7 @@ def run_async( stdout=stdout_stream, stderr=stderr_stream, cwd=cwd, + env=env ) @@ -306,6 +308,7 @@ def run( quiet=False, overwrite_output=False, cwd=None, + env=None ): """Invoke ffmpeg for the supplied node graph. @@ -330,6 +333,7 @@ def run( quiet=quiet, overwrite_output=overwrite_output, cwd=cwd, + env=env ) out, err = process.communicate(input) retcode = process.poll()