converted to python3 via 2to3