Skip to content

File save dialog output goes to python terminal on OS X #3476

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
amadio opened this issue Sep 5, 2014 · 9 comments
Closed

File save dialog output goes to python terminal on OS X #3476

amadio opened this issue Sep 5, 2014 · 9 comments
Labels

Comments

@amadio
Copy link

amadio commented Sep 5, 2014

I install matplotlib on OS X using a Gentoo prefix install. Everything seems to work ok. The only problem I've encountered so far is that when I try to save something to a file, I can't change the filename on the dialog box, because the keyboard strokes go to the terminal where I am running python. I don't know if this is a matplotlib issue or a issue in tkinter from Python, but matplotlib is the only place where I have this problem.

@tacaswell
Copy link
Member

possibly related to #665 and #3367?

I could have sworn I saw this go by very recently, but couldn't turn up the exact issue.

@tacaswell tacaswell added the OSX label Sep 5, 2014
@tacaswell tacaswell added this to the v1.4.x milestone Sep 6, 2014
@amadio
Copy link
Author

amadio commented Sep 22, 2014

This seems to be a duplicate of #665, but the solution there (checking if Python is installed as a framework) doesn't seem to fix it.

@mdehoon
Copy link
Contributor

mdehoon commented Nov 28, 2014

Which backend are you using? Tkagg or the Mac OS X native backend?

@tacaswell tacaswell modified the milestones: 1.5.0, v1.4.x Feb 7, 2015
@tacaswell tacaswell added status: needs clarification Issues that need more information to resolve. and removed GUI: tk labels Feb 7, 2015
@tacaswell
Copy link
Member

@amadio ping

@tacaswell tacaswell modified the milestones: unassigned, 1.5.0 Feb 7, 2015
@amadio
Copy link
Author

amadio commented Feb 8, 2015

Hi @tacaswell I'm sorry, completely forgot about this issue. I don't have access to a Mac right now, and won't have for the next three months, so I can't check what backend I was using. Feel free to close this issue, I can open another when I get back home and can test this again.

@mdboom
Copy link
Member

mdboom commented Oct 9, 2015

I can reproduce this on a Mac with the macosx backend, Anaconda Python and current master of matplotlib. -- I should add it may be due to Anaconda Python not being a true Framework build.

@mdboom
Copy link
Member

mdboom commented Oct 9, 2015

Scratch that: If started with pythonw on Anaconda python, things work correctly. Using pythonw as a workaround seems reasonable.

@movelikeriver
Copy link

For anyone working with scikit-learn:

Same issue here:
I got the lib from scikit: http://scikit-learn.org/stable/install.html

conda install scikit-learn
$ python
Python 2.7.11 |Anaconda 2.4.1 (x86_64)| (default, Dec  6 2015, 18:57:58) 
[GCC 4.2.1 (Apple Inc. build 5577)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
Anaconda is brought to you by Continuum Analytics.
Please check out: http://continuum.io/thanks and https://anaconda.org
>>> import sys
>>> sys.executable
'//anaconda/bin/python'

pythonw is working. But the downside is: your other python script may be broken due the the python version.

A workaround solution for Anaconda python:
in ~/.bash_profile

# added by Anaconda2 2.4.1 installer
# export PATH="//anaconda/bin:$PATH"
alias python_a='//anaconda/bin/pythonw'

Use python_a instead of python for scikit-learn or plot related scripts.

@dstansby
Copy link
Member

dstansby commented Nov 1, 2017

I'm going to close this, since importing Matplotlib without using pythonw now errors. Feel free to re-open if this is still an issue in Maptlotlib 2.1 whilst running pythonw!

@dstansby dstansby closed this as completed Nov 1, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

7 participants