fix python3 support