I think this may not work in python 2.6. It's worth confirming.