r/pythonhelp • • Apr 17 '21

Using Python How Do I send FFMPEG stderr and stdout to Multiple Files?

/r/CodingHelp/comments/msjnvr/using_python_how_do_i_send_ffmpeg_stderr_and/
3 Upvotes

4 comments sorted by

2

u/MT1961 Apr 17 '21

Hm. Opening a file in write mode should obliterate it, which is the first clue. You have two loops through the csv reader, which is what I believe is causing your issue ... it only reads the file once.

1

u/mc587 Apr 18 '21

found the issue all i had to do whats remove the second for row in csv_reader;

1

u/MT1961 Apr 17 '21

hm. It actually looks ok. Have you verified that the row[0] is what you think it should be? Also, you are wiping out the log every time you write it. Is that the intent?

1

u/mc587 Apr 17 '21

the log isn’t being wiped. It actually writes every log in 1 file. it’s weird row[0] for the ffmpeg process starts with stream1 which is what i want. but row[0] for log variable stars with Name and all of the output goes under the file Name