Fix python2 regression