subprocess considered harmfull?

2005-09-25 Thread Uri Nix
Hi all, I've been trying to use (Python 2.4 on WinXP) the subprocess module to execute a shell command (nmake in this case), and pass its output to a higher level. Using the following snippet: p = subprocess.Popen(nmake,stderr=subprocess.PIPE,stdout=subprocess.PIPE, \ u

Re: subprocess considered harmfull?

2005-09-25 Thread Uri Nix
Roger Upole wrote: > "Fredrik Lundh" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > > Steven Bethard wrote: > > > >> > Using the following snippet: > >> > p = > >> > subprocess.Popen(nmake,stderr=subprocess.PIPE,stdout=subprocess.PIPE, \ > >> >universal_new

Re: subprocess problem

2005-09-27 Thread Uri Nix
Hi, I had a similar problem recently, and found that using pipes with os.popen* helped in my case. You can check the thread at: http://mail.python.org/pipermail/python-list/2005-September/300744.html. Cheers, Uri Do Re Mi chel La Si Do wrote: > Hi! > > This script (under Win-XP + P-2.4.1) : >

Re: subprocess.Popen on Windows

2006-06-25 Thread Uri Nix
Hi, Been there - try looking at: http://groups.google.com/group/comp.lang.python/browse_frm/thread/f2cb83e948326ff5/d69feabbfc940b01?q=uri.nix&rnum=2#d69feabbfc940b01 Cheers, Uri -- http://mail.python.org/mailman/listinfo/python-list

ctypes and DLL exceptions

2007-02-20 Thread Uri Nix
Hi all, Is there a method to deal with exceptions originating from a DLL creatively? After experimentation, I've observed that calling a ctypes wrapped DLL exception raises WindowsError, and an accompanying code. Does the code mean something? Can I throw an object from C++ and somehow catch i