A quick fix for the py3 compatibility