Because setdefaultencoding does not exist in Python 3