Anyone else having trouble installing wxPython on Mac OSX lion for problem #10? I get crazy errors on import wx
Here's the error msg: Traceback (most recent call last): File "<pyshell#0>", line 1, in <module> import wx File "/usr/local/lib/wxPython-ansi-2.8.12.1/lib/python2.7/site-packages/wx-2.8-mac-ansi/wx/__init__.py", line 45, in <module> from wx._core import * File "/usr/local/lib/wxPython-ansi-2.8.12.1/lib/python2.7/site-packages/wx-2.8-mac-ansi/wx/_core.py", line 4, in <module> import _core_ ImportError: dlopen(/usr/local/lib/wxPython-ansi-2.8.12.1/lib/python2.7/site-packages/wx-2.8-mac-ansi/wx/_core_.so, 2): no suitable image found. Did find: /usr/local/lib/wxPython-ansi-2.8.12.1/lib/python2.7/site-packages/wx-2.8-mac-ansi/wx/_core_.so: no matching architecture in universal wrapper
I am running 3.2.2 on lion and a-thang seems fine. I installed lion after idle so maybe that is why. Regardless, make sure you are running a version of idle that is comparable with lion. Frankly, I do not know if 2.2 or 2.1 is compatible with lion.
What's a-thang? I can't seem to google it up. wxPython is an extension to python that you need to install in ps#10. Also it unfortunately only supports python 2.6 and 2.7
Had a lot of trouble with it. Finally had to use the version with "cocoa" in the name. Once I uninstalled all my old installations and then installed that, things worked fine. Look for it on the wx download page. It only supports 2.7 so you'll have to get that Python/IDLE version if you don't have it. The basic issue is the 32 vs 64 bit problem.
Also I should note that for that problem set, you don't really need it. Literally all you do is use it to run the provided code to display the GUI. There is no work involved other than importing it and running the provided GUI code. I don't know if you work with it more in futures assignments as I just got through that one a couple nights ago.
Yeah, I figured it out basically if you running Mac OSX Lion, you would have installed the 64bit python ide. But wxpython requires 32bit. So you'll need to install the python for Tiger and Snowleopard and it'll work. You don't need to uninstall, just install over initial one. # gcarter80 Thanks for the help!
it's good to experiment with wxpython though. apparently on stackoverflow, they say it's one of the best gui frameworks. Combined with wxglade (like a gui way of building guis), it's pretty easy and powerful. So they say.
Yeah if you scroll down to the development releases towards the bottom of the page you'll see the cocoa version - http://downloads.sourceforge.net/wxpython/wxPython2.9-osx-2.9.2.4-cocoa-py2.7.dmg That will work with 64bit IDLE. You basically choose between running 32 bit python and the stable WX or 64 bit python and the dev release of WX :) It's a sweet package either way so glad you got it to work.
Thank you!
Join our real-time social learning platform and learn together with your friends!