python2 compatability