Python on Snow Leopard

I have just installed Snow Leopard and came upon some excellent sites which have inspired me to learn the programming language Python

The first site is Clark’s Tech Blog

The articles listed below are excellent examples of using Python to manage your itunes library, well worth the read.

and a nice little article about the new version of python and some useful modules to install – Upgrading to Snow Leopard Part 1: Python

Python 2.6.1 (r261:67515, Jul 7 2009, 23:51:51)
[GCC 4.2.1 (Apple Inc. build 5646)] on darwin

The second blog which has a plethora of scripts for automation is And now it’s all this

2 thoughts on “Python on Snow Leopard”

  1. Congratulations on getting on the Python bandwagon.

    If you use a lot of external libraries you may find that being open source projects they have not got around to making 64bit version of their installation binaries available.

    I lost the ability to do all my cross-platform GUI scripting in wxPython on the Snow Leopard built-in Python it ships with.

    This is because Snow Leopard Python is running in 64bit mode. Which is great but wxPython is stuck in 32bit land for ages and will throw errors when trying to load up.

    To fix, in the terminal on OS X type in the following command:
    # To Prefer 32-bit execution for Python 2.6.1 on Snow Leopard

    $ defaults write com.apple.versioner.python Prefer-32-Bit -bool yes

    Then Python will be running in 32bit mode and will be able to work with all the libraries already out their with OS X binary installers.

    Cheers,
    PN

    Reply

Leave a comment