Python 3.3 and python 3.2 fixes