python 3.2/3.3 compatibility