fixed python3 compatability