Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > Python > Posix call (execve) breaks mercurial?

Thread Tools

Posix call (execve) breaks mercurial?

Wayne Werner
Posts: n/a
So... this is certainly the deepest I've got to dig into any source code.

I'm experimenting with Review Board for code reviews, and trying to get it
set up/working here at work. When using post-review, however, I started
getting issues with untrusted users - even though they were set to trusted
in my ~/.hgrc and things worked fine otherwise.

So here's where things got weird. I could call
`subprocess.check_output(['hg', 'root'])`, and things worked just fine.
But when I added the env parameter, I got the untrusted issues. So if I

import os, subprocess

# Works just fine
subprocess.check_output(['hg', 'root'])

# Gives untrusted issues
subprocess.check_output(['hg', 'root'], env=os.environ)

Long story short, I dug around the source code and ended up at the POSIX
execve function. I've been reading the manpages, but nothing seems to pop
out at me as "hey, this should/shouldn't work!".

Does anyone know what's going on here, or where I should go for more help?

Reply With Quote

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Re: Posix call (execve) breaks mercurial? Antoine Pitrou Python 0 10-12-2012 01:31 PM
Re: Posix call (execve) breaks mercurial? Wayne Werner Python 0 10-11-2012 11:33 PM
Capturing STDOUT from a system call (POSIX) into an array Venks Ruby 10 12-07-2007 01:01 AM
POSIX system() call return value C Programming 4 10-23-2006 08:32 PM
posix vs perl regular expressions RN Perl 0 09-10-2003 06:25 PM