I have not much idea but Online Judges like SPOJ/codechef have regular programming-contests and python is one of allowed languages. So yes, it's possible. If I guess right, are you making an Online Judge for python.<br>

<br><div class="gmail_quote">On Thu, Jun 3, 2010 at 8:39 PM, Amit Sethi <span dir="ltr"><<a href="mailto:amit.pureenergy@gmail.com">amit.pureenergy@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">

Hi ,<br>
<br>
I wish to execute some user submitted python code and have absolutely<br>
no other way out . I saw that there used to be a module called rexec<br>
which could define which modules can be imported and which cannot<br>
however exec doesn't have that kind of feature . Please if you could<br>
tell me what would the best possible ways of sandboxing python code .<br>
--<br>
A-M-I-T S|S<br>
<font color="#888888">--<br>
<a href="http://mail.python.org/mailman/listinfo/python-list" target="_blank">http://mail.python.org/mailman/listinfo/python-list</a><br>
</font></blockquote></div><br>