Fix python console for Python 2.6