Initial port to Python33