Fixed string formatting backwards compatibility with python 2.6