Fix for python 3