This code is working:
> try:
> ffmpeg_proc = subprocess.Popen(queue[position].ffmpeg_cmd,
> stdout=subprocess.PIPE, stderr=open(os.devnull, 'w'))
> except WindowsError as exc:
> log_windows_error(exc, queue[position].ffmpeg_cmd, 'critical')
> break
> if queue[pos
On Fri, Jul 1, 2011 at 1:02 AM, Andrew Berg wrote:
> On 2011.07.01 02:26 AM, Peter Otten wrote:
>> I can't reproduce your setup, but I'd try using communicate() instead of
>> wait() and close().
> I don't really know what communicate() does.
"Read data from stdout and stderr, until end-of-file is
On 2011.07.01 02:26 AM, Peter Otten wrote:
> I can't reproduce your setup, but I'd try using communicate() instead of
> wait() and close().
I don't really know what communicate() does. The docs don't give much
info or any examples (that explain communicate() anyway), and don't say
when communicate
Andrew Berg wrote:
> Okay, so I've refactored those except WindowsError blocks into calls to
> a function and fixed the os.devnull bug, but I still can't get the
> triple chain working. I added calls to ffmpeg_proc.stdout.close() and
> sox_proc.stdout.close(), but I really am not sure where to put
Okay, so I've refactored those except WindowsError blocks into calls to
a function and fixed the os.devnull bug, but I still can't get the
triple chain working. I added calls to ffmpeg_proc.stdout.close() and
sox_proc.stdout.close(), but I really am not sure where to put them. The
following code wo
On 2011.06.28 02:44 AM, Thomas Rachel wrote:
> The way you work with the exception is not the very best - instead of
> parsing the stringified exception, you better would trigger on
> exc.winerror (it is an integer with the error number).
>
> Or, even better, just pas the error information contai
Am 28.06.2011 07:57 schrieb Andrew Berg:
I'm working on an audio/video converter script (moving from bash to
Python for some extra functionality), and part of it is chaining the
audio decoder (FFmpeg) either into SoX to change the volume and then to
the Nero AAC encoder or directly into the Nero
On Mon, Jun 27, 2011 at 11:47 PM, Andrew Berg wrote:
> On 2011.06.28 01:32 AM, Peter Otten wrote:
>> >>> subprocess.call(["ls"], stdout=open(os.devnull, "w"))
>> 0
> D'oh! Not sure why I was thinking os.devnull was a file object. :-[
On the bright side, I think in part due to this /exact/
misunde
On 2011.06.28 01:32 AM, Peter Otten wrote:
> >>> subprocess.call(["ls"], stdout=open(os.devnull, "w"))
> 0
D'oh! Not sure why I was thinking os.devnull was a file object. :-[
> Start with factoring out common code into a good old function.
For some reason I was thinking I would have problems doing
Andrew Berg wrote:
> I'm working on an audio/video converter script (moving from bash to
> Python for some extra functionality), and part of it is chaining the
> audio decoder (FFmpeg) either into SoX to change the volume and then to
> the Nero AAC encoder or directly into the Nero encoder. This i
I'm working on an audio/video converter script (moving from bash to
Python for some extra functionality), and part of it is chaining the
audio decoder (FFmpeg) either into SoX to change the volume and then to
the Nero AAC encoder or directly into the Nero encoder. This is the
chunk of code from my
11 matches
Mail list logo