Search code examples
pythoncompiler-errorswxpythonspyder

What is a Framework build of Python?


So I'm testing out the SPy library in Anaconda's Spyder, and have run into a strange error:

SystemExit: This program needs access to the screen. Please run with a Framework build of python, and only when you are logged in on the main display of your Mac.

This happens when I try to call the view_cube command from Spectral Python (SPy), which requires wxPython.

I have a feeling that this is related to Spyder's displaying of all the images generated by my program in its onboard console, instead of in independent windows.

How can I fix this error, and is there a way to tell Spyder to display images in their own windows? Can I run a "Framework Build" within Spyder?

EDIT: I was able to display the resulting images in separate windows by going to Preferences > IPython console > Graphics, and setting Backend to Mac OSX. However, the error when trying to run the view_cube command still persists...


Solution

  • I expect you're using the system version of python that comes installed on mac by default, which isn't a framework build.

    You'll want to install a version of python from python.org which are all framework builds. I expect you'll want the latest version of python 2. You will also have to install your dependancies again against this new python install.