Mercurial > hg > bitsyblog
changeset 109:1fc637c3acc0
py3
author | Jeff Hammel <k0scist@gmail.com> |
---|---|
date | Tue, 03 Nov 2020 13:36:04 -0800 |
parents | e2f7dccbac26 |
children | 13f6a41882be |
files | bitsyblog/bitsyblog.py |
diffstat | 1 files changed, 3 insertions(+), 3 deletions(-) [+] |
line wrap: on
line diff
--- a/bitsyblog/bitsyblog.py Tue Nov 03 13:33:39 2020 -0800 +++ b/bitsyblog/bitsyblog.py Tue Nov 03 13:36:04 2020 -0800 @@ -114,7 +114,7 @@ handler = entry_point.load()(self, **handler_args.get(entry_point.name, {})) self.handlers.append(handler) except: - print 'Cant load entry point %s' % entry_point.name + print('Cant load entry point %s' % entry_point.name) raise @@ -654,8 +654,8 @@ buffer = StringIO() for entry in blog: - print >> buffer, '[ %s ]\n' % entry.date.strftime(self.date_format) - print >> buffer, entry.body.strip() + '\n' + buffer.write('[ {} ]\n\n'.format(entry.date.strftime(self.date_format))) + buffer.write('{}\n\n'.format(entry.body.strip()) return buffer.getvalue() def restructuredText(self, string):