process = subprocess.Popen(F"aws s3 sync {s3_base_dir} ./s3_files/{experiment_name}/{experiment_id}", stdout=subprocess.PIPE, shell=True)
for line in iter(process.stdout.readline, b''):
sys.stdout.buffer.write(line)
After running the above command, nothing gets outputted... I think perhaps because the stdout is a live progress bar and not lines? For context the stdout when running the above command in terminal looks like this:
bash$ aws s3 sync s3://s3_path ./s3_files/2
Completed 14.5 MiB/513.9 MiB (10.1 MiB/s) with 1 file(s) remaining