More python 3.x fixes