The problem turned out to be only that very line in "journal2ebook.py" which kicked out the error. It appears that python 2.6 doesn't support dictionary comprehensions. I've change the dictionary comprehension into a list comprehension which generates a list of (key,value)-tuples, and applied dict() to that list to generate the required dictionary. I don't think dict() or list comprehensions are due to disappear any time soon (both are still supprted as of python 3.4), so I don't think there is any downside in making the change.
The problem turned out to be only that very line in "journal2ebook.py" which kicked out the error. It appears that python 2.6 doesn't support dictionary comprehensions. I've change the dictionary comprehension into a list comprehension which generates a list of (key,value)-tuples, and applied dict() to that list to generate the required dictionary. I don't think dict() or list comprehensions are due to disappear any time soon (both are still supprted as of python 3.4), so I don't think there is any downside in making the change.