<br><br><div class="gmail_quote">On Sat, Sep 24, 2011 at 4:14 PM, Ryan Schmidt <span dir="ltr"><<a href="mailto:ryandesign@macports.org">ryandesign@macports.org</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
Please keep the discussion on the mailing list by using the Reply All feature.<br>
<br>
<br>
On Sep 24, 2011, at 11:49, Jin-Rui Xu wrote:<br>
<div class="im"><br>
> On Sat, Sep 24, 2011 at 10:57 AM, Ryan Schmidt wrote:<br>
><br>
>> Are you sure that you're running MacPorts python 2.7, and not some other python?<br>
><br>
> Yes, I am running 2.7. Here is the info<br>
><br>
> Python 2.7.1 (r271:86832, Jun 16 2011, 16:59:05)<br>
> [GCC 4.2.1 (Based on Apple Inc. build 5658) (LLVM build 2335.15.00)] on darwin<br>
> Type "help", "copyright", "credits" or "license" for more information.<br>
<br>
</div>What command produced that output?<br>
<br>
It's hard for me to know whether that indicates you're using MacPorts Python 2.7, or possibly Apple Python 2.7, if that's the version of Python that's on Lion.<br>
<div class="im"><br>
<br>
> I totally ran three commands to install and use MMTK. sudo port install py-MMTK, python and from MMTK import *. I do not know whether there are something else I need to set up. Thanks!<br>
<br>
</div>Exactly how are you running your code? i.e. by typing "python" (in which case, what does "which python" say?), by typing python2.7, by typing /opt/local/bin/python2.7, etc.<br>
<br>
<br>
</blockquote></div>Hi Ryan,<div><br></div><div>I just typed "python" in my terminal to invoke interactive python. And I think it was apple's python 2.7.1. Now I typed python2.7 or /opt/local/bin/python2.7 and got the "MacPorts python2.7" which is python2.7.2. With 2.7.2, MMTK modules can be imported. Thanks very much!</div>
<div><br></div><div>I am sure that my following questions are quite naive. But please explain a little bit for me as well as people who are not familiar with CS like me~~</div><div> </div><div>Can you explain differences between apple's python and Macports' python, why typing "python" simply did not give the newest version of python and should I set up manually to fix this and how? </div>
<div><br></div><div>jinrui,</div>