Fixed problems with py3k