[Python-ideas] High time for a builtin function to manage packages (simply)?

Andrew Barnert abarnert at yahoo.com
Mon Sep 7 05:07:44 CEST 2015


On Sep 6, 2015, at 18:51, Stephen J. Turnbull <stephen at xemacs.org> wrote:
> 
> But IMO it doesn't address this issue because the almost but not
> really universally-available GUI is Tcl/Tk, which isn't even available
> in any of the four packaged Python instances I have installed (Mac OS
> X system Python 2.6 and 2.7, MacPorts Python 2.7 and 3.4, although
> IIRC MacPorts offers a tk variant you can enable, but it's off by
> default).

Tcl/Tk, and Tkinter for all pre-installed Pythons but 2.3, have been included with every OS X since they started pre-installing 2.5. Here's a brand new laptop that I've done nothing to but run the 10.10.4 update and other recommended updates from the App Store app:

    $ /usr/bin/python2.6
    Python 2.6.9 (unknown, Sep  9 2014, 15:05:12)
    [GCC 4.2.1 Compatible Apple LLVM 6.0 (clang-600.0.391)] on darwin
    Type "help", "copyright", "credits" or "license" for more information.
    >>> import Tkinter
    >>> root = Tkinter.Tk()
    >>>

That works, and pops up an empty root window.

And it works with all python.org installs for 10.6 or later, all Homebrew default installs, standard source builds... Just about anything besides MacPorts (which seems to want to build Tkinter against its own Tcl/Tk instead of Apple's)

Also, why do you think Qt would be less of a problem? Apple has at various times bundled Qt into OS X and/or Xcode, but not consistently, and even when it's there it's often set up in a way that you can't use it, and of course Apple has never include PyQt or PySide. So, if pip used Qt, a user would have to go to qt.io, register an account, figure out what they need to download and install, figure out how to make it install system-wide instead of per-user, and then repeat for PySide against each copy of Python they want to use. Either that, or pip would have to include its own complete copy of Qt and PySide.


More information about the Python-ideas mailing list