support python 2.6

 - fix str.format placeholders
 - replace calls to datetime.timdelta#total_seconds