From bbh wiki
Revision as of 11:24, 26 October 2009 by imported>Scott (→‎Tools for Python Development)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigationJump to search

General Python Info

Python documentation, including Guido's tutorial

Python Quick Reference (2.4)

Python Programming wikibook

How to Think Like a Computer Scientist, Learning with Python, 2nd Ed. by Jeffrey Elkner, Allen B. Downey and Chris Meyers

Python for Software Design: How to Think Like a Computer Scientist by Allen B. Downey HTML version of Think Python

Dive Into Python book

From Guido van Rossum's Python Tutorial: "By the way, the language is named after the BBC show Monty Python's Flying Circus and has nothing to do with nasty reptiles. Making references to Monty Python skits in documentation is not only allowed, it is encouraged!"


Python IDEs


IPython an improved interactive python shell.

Python Bibliotheca

Installing Idle on a Mac with Leopard (which already has Python 2.5.1)

One Laptop Per Child Python environment: The OLPC's user interface (Sugar) and many of its applications are written in Python.

Location of site-packages on a Debian-based system (like Ubuntu):


Python documentation is written in reStructuredText

Presentations from PyCon

Virtualenv and virtualenvwrapper


Tools for Python Development

  • virtualenv for running python programs in isolated environment with a particular version of python and particular available packages.
  • sphinx a documentation generator. The official Python and Django documentation pages are done with Sphinx. The text is written in a stylized form of plain text known as ReStructuredText. See:A ReStructuredText Primer and Quick reStructuredText.
  • trac issue tracking and wiki. For configuration with WSGI: TracModWSGI
  • fabric "simple pythonic deployment"; deploying web applications to servers and automating other remote tasks. See the fabric tutorial.
  • pip python package installer

search path for loading modules

To see the current search path for loading modules:

import sys

to set the path in the shell so that it is available for a regular python command window

BUT this does not work for IDLE.

To add to that path, set the environment variable PYTHONPATH, such as (with a bash shell):

export PYTHONPATH=/path/to/someplace/mydirectory/

or multiple directories separated by colons, and $HOME refers to the user's home directory:

export PYTHONPATH=/path/to/someplace/mydirectory/:$HOME/path/to/subdirectory/belowhome/

in the case where PYTHONPATH is already set and you just want to add to it:

export PYTHONPATH=${PYTHONPATH}:/path/to/someplace/mydirectory/

The new path can be seen by:


or to see just PYTHONPATH:

export | grep PYTHONPATH

inside IDLE or inside any python command window

sys.path is a list of strings

to add to the front:

import sys

to add to the end:



Web Application Development