Fix all python 3 errors