"A Python is installed" #27146

Closed
jillesme opened this Issue Mar 2, 2014 · 19 comments

Projects

None yet
@jillesme
jillesme commented Mar 2, 2014

Hey guys,

So I'm getting this error when brew doctor'in.. Google is no help either and I can't find anyone else with this issue.. What do I need to do the get brewin again?

Warning: A Python is installed in /Library/Frameworks

Homebrew only supports building against the System-provided Python or a
brewed Python. In particular, Pythons installed to /Library can interfere
with other software installs.

Thanks!

screen shot 2014-03-02 at 23 51 47

@chdiza
Contributor
chdiza commented Mar 2, 2014

You don't have to do anything. It's just a heads-up that the presence of that python might cause problems down the road, depending on what else you brew.

@jacknagel
Contributor

Yep, it's just a warning; python installs in /Library tend to cause compilation issues when other software's build systems pick them up; for example, if the python is built for incompatible architectures.

It's not always the case, but having this in the brew dr output is a useful starting point for debugging.

@jacknagel jacknagel closed this Mar 3, 2014
@adamv
Contributor
adamv commented Mar 3, 2014

Off topic, but what font are you using in your terminal?

@jillesme
jillesme commented Mar 3, 2014

@jacknagel Thanks! Is there any way I can remove that warning from brew doctor by 'fixing' it?
@adamv Source Code Pro!

@Dr-Radialist

I have same problems. I understand that it is just a warning. However, could you tell me how I could delete the warning message when 'brew doctor'?

@adamv
Contributor
adamv commented Mar 6, 2014

To clear the warning, remove the Python from /Library/Frameworks/Python.framework.

(But don't actually remove it if something is using it.)

@Dr-Radialist

Thanks, I can brew now!

@ricksevans

Would someone be so kind as to postulate (offer a likely story) about how this Python got into /Library/Frameworks/Python.framework? It is probably something I did... but I do not recall what I did.

@adamv
Contributor
adamv commented Mar 7, 2014

I think the official Python installer from the website may install here; Enthought may distribute a Python that goes here. Anything installed from a .pkg file may decide to put things in Frameworks though I don't know of any common thing that installs Python, but I have seen software put a version there in the past.

There are a few ways, and it's not always obvious the user that this happens.

@ricksevans

Thanks. I found a reasonable explanation here: http://docs.python.org/2/using/mac.html
Apparently I updated Python.

@zedware
zedware commented Mar 7, 2014

So, is it a good choice to keep or remove the Apple provided Python? Thanks.

@adamv
Contributor
adamv commented Mar 7, 2014

The Apple provided Python is in /System/Library, not /Library, and should always be kept intact.

@chdiza
Contributor
chdiza commented Mar 7, 2014

If you don't brew Python and don't brew things that interact with Python, you will probably be fine leaving a /Library/Frameworks one there. I've done this for about 15 months now and have never had a problem. The catch is that you have to always be prepared to move that Python out of the way for testing purposes when a recalcitrant issue arises.

Just because this can be done under certain conditions doesn't mean it is wise to do it, however. If you don't have a good reason for keeping it, the wise thing is to remove it.

@tonyfazio

How do you remove Python from /Library/Frameworks/Python.framework.

@chdiza
Contributor
chdiza commented Mar 13, 2014

How do you remove Python from /Library/Frameworks/Python.framework.

sudo rm -rf /Library/Frameworks/Python.framework

@tonyfazio

Thanks chdiza!

@ablyler ablyler referenced this issue in Homebrew/homebrew-php Aug 30, 2014
Closed

Cannot reinstall php55 on Maverick #1304

@AndySoltani

The comments here helped me remove python and fix my brew doctor errors! Thanks everyone!

@HtwoO
HtwoO commented Jul 10, 2015

I currently have /Library/Frameworks/Python.framework, 3.4. I have system Python untouched. I have anaconda installed at $HOME/anaconda. I think it must had been installed by brew-cask. Because I did explicitly brew-cask install python3. Maybe I should report to the brew-cask team?

@tdsmith
Member
tdsmith commented Jul 10, 2015

That is exactly what brew cask install python3 should do. Homebrew's warning is also correct.

@xu-cheng xu-cheng locked and limited conversation to collaborators Feb 17, 2016
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.