make it compatible with python3