Stop using string exceptions. They were removed in python 2.6.