Moet Mills
Moet Mills

Reputation: 39

What is the difference between "python" and "pythonw" in the mac Terminal?

im fairly new to programming in Python and i've been using the terminal to run my code with no problem. Usually by typing python {filename} to run it.

However, recently i got this error:

ImportError: Python is not installed as a framework. The Mac OS X backend will not be able to function correctly if Python is not installed as a framework. See the Python documentation for more information on installing Python as a framework on Mac OS X. Please either reinstall Python as a framework, or try one of the other backends. If you are using (Ana)Conda please install python.app and replace the use of 'python' with 'pythonw'. See 'Working with Matplotlib on OSX' in the Matplotlib FAQ for more information.

then i changed the python {filename} to pythonw {filename} and the code worked. Could someone give me some insight into this error and why it worked by just adding w?

Upvotes: 0

Views: 2961

Answers (1)

Natsfan
Natsfan

Reputation: 4802

pythonw - run python script allowing GUI. According to the man page for pythonw.

Upvotes: 1

Related Questions