migration from Python 2.7 to Python 3.4