If you're using subprocess.Popen (which you probably should be), use stdout=subprocess.PIPE and stderr=subprocess.PIPE.

from subprocess import Popen, PIPE
p = Popen((command, arg1, arg2), stdout=PIPE, stderr=PIPE)
out, err = p.communicate()

And use p.returncode if you need it.

-- Chris

On Sat, Jun 25, 2011 at 12:43 PM, Martin Owens <doctormo@gmail.com> wrote:
I'm trying to solve a bug with my deviantArt stash extension.

It produces warnings because poxy webkit with bleedin java and god
aweful html decide that it's a great idea to shout out to the world a
whole bunch of version information, including any javascript errors that
happen in the loaded pages.

What cute is that I told the inx to load a bash shell which loaded the
python script and to dev/null everything. That didn't hack fix it. I
tried redirecting sys.stderr to a file, somehow it still manages to come

Please tell me there is a way to stop inkscape from reporting warnings
from python extensions? There is no reason to report warnings to users
unless they can be formatted in a nice way and these can't be.


All the data continuously generated in your IT infrastructure contains a
definitive record of customers, application performance, security
threats, fraudulent activity and more. Splunk takes this data and makes
sense of it. Business sense. IT sense. Common sense..
Inkscape-devel mailing list