fixing Python3 compatibility issue (thanks to that Travis dude)