retab for python3 compatibility