Fix for Py3.x