Permalink
Browse files

Fix unicode format string error. Version bump.

  • Loading branch information...
bboe committed Jun 3, 2012
1 parent 6628b30 commit 281f4e825a32c57a4b7d17a25795dc069245235c
Showing with 3 additions and 2 deletions.
  1. +1 −1 reddit/__init__.py
  2. +1 −1 reddit/objects.py
  3. +1 −0 reddit/reddit_test.py
View
@@ -30,7 +30,7 @@
import reddit.objects
from reddit.settings import CONFIG
-__version__ = '1.3.8'
+__version__ = '1.3.9'
UA_STRING = '%%s PRAW/%s Python/%s %s' % (__version__,
sys.version.split()[0],
platform.platform(True))
View
@@ -484,7 +484,7 @@ def __init__(self, reddit_session, json_dict):
def __unicode__(self):
title = self.title.replace('\r\n', ' ')
- return '{0} :: {1}'.format(self.score, title)
+ return six.text_type('{} :: {}').format(self.score, title)
def _insert_comment(self, comment):
if comment.name in self._comments_by_id: # Skip existing comments
View
@@ -173,6 +173,7 @@ def test_unicode_submission(self):
title = 'Wiki Entry on \xC3\x9C'
url = 'http://en.wikipedia.org/wiki/\xC3\x9C?id=%s' % unique
submission = self.r.submit(self.sr, title, url=url)
+ str(submission)
self.assertEqual(title, submission.title)
self.assertEqual(url, submission.url)

0 comments on commit 281f4e8

Please sign in to comment.