restored Python3 support