I have resolved this problem in my code. It has something to do with your current working directory when you append cwd/jars to sys.path and try to import from interactive console<br clear="all">-Alex Goretoy<br><a href="http://www.goretoy.com">http://www.goretoy.com</a><br>
<br>
<br><br><div class="gmail_quote">On Thu, Mar 12, 2009 at 4:58 AM, alex goretoy <span dir="ltr"><<a href="mailto:aleksandr.goretoy@gmail.com">aleksandr.goretoy@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
How would I import with __import__ from dict values?<br>I want sys.path value inside d['syspath'], below code doesn't work for me<br><br><br>d={}<br>d['sys']='sys'<br>d['path']='path'<br>

<br>d['syspath']=__import__(d['sys'],fromlist=[d['path']])<br><br>and how come does  above line doesn't give me diff value than below line?<br><br>d['syspath']=__import__(d['sys'])<br>

<br>Meaning, when I do this doesn't work. Which makes sense.<br>d['syspath']()<br>d['syspath'].d['path']<br><br>but this works both with fromlist and without.<br><br>d['syspath'].path<br>
<font color="#888888">
<br><br clear="all">-Alex Goretoy<br><a href="http://www.goretoy.com" target="_blank">http://www.goretoy.com</a><br><br>
</font></blockquote></div><br>