The run_shell_process flow currently assumes it is running from within the current working directory and with the default environment variables. When the run_shell_process flow is either run outside the target working directory, or as a child flow, those values cannot be passed as arguments.
Describe the proposed behavior
The run_shell_process flow should accept additional optional arguments for cwd and env that are passed to the subprocess.Popen call.
Describe the current behavior
The
run_shell_process
flow currently assumes it is running from within the current working directory and with the default environment variables. When therun_shell_process
flow is either run outside the target working directory, or as a child flow, those values cannot be passed as arguments.Describe the proposed behavior
The
run_shell_process
flow should accept additional optional arguments forcwd
andenv
that are passed to the subprocess.Popen call.Example Use
Additional context
run_shell_process
is being run as a child flow within a Prefect (v3) flow.