python: fix for Python 3.