once again: fix encoding issues
This commit is contained in:
parent
58177038c3
commit
103d7d4a28
@ -220,7 +220,7 @@ def list_all_feeds(session):
|
||||
totalfeeds = 0
|
||||
totalentries = 0
|
||||
for feed in allfeeds:
|
||||
print unicode(feed)
|
||||
print feed
|
||||
totalfeeds += 1
|
||||
totalentries += len(feed.entry)
|
||||
print 'TOTAL: %d entries in %d feeds.' % (totalentries, totalfeeds)
|
||||
@ -243,8 +243,9 @@ def reset_feed(session, feed_id):
|
||||
# TODO implement reset
|
||||
|
||||
if __name__ == '__main__':
|
||||
streamWriter = codecs.lookup('utf-8')[-1]
|
||||
sys.stdout = streamWriter(sys.stdout)
|
||||
if (sys.stdout.encoding is None):
|
||||
streamWriter = codecs.lookup('utf-8')[-1]
|
||||
sys.stdout = streamWriter(sys.stdout)
|
||||
|
||||
config = ConfigParser.ConfigParser()
|
||||
config.read('atomstrom.conf')
|
||||
|
Loading…
Reference in New Issue
Block a user