#2216: rencode changes str/unicode types
--------------------------+-------------------------------------------------
 Reporter:  gazpachoking  |       Owner:       
     Type:  bug           |      Status:  new  
 Priority:  minor         |   Milestone:  1.3.x
Component:  other         |     Version:  1.3.5
 Keywords:                |  
--------------------------+-------------------------------------------------

Comment(by gazpachoking):

 Example:
 {{{
 #!python
 from deluge import rencode
 def ident(x):
     print repr(rencode.loads(rencode.dumps(x)))

 ident(u'a') # unicode in, str out
 ident('a') # str in str out
 ident(u'\xf8') # unicode in unicode out
 ident(u'\xf8'.encode('utf8')) # str in unicode out

 ### Result
 'a'
 'a'
 u'\xf8'
 u'\xf8'
 }}}

-- 
Ticket URL: <http://dev.deluge-torrent.org/ticket/2216#comment:1>
Deluge <http://deluge-torrent.org/>
Deluge project

-- 
You received this message because you are subscribed to the Google Groups 
"Deluge Dev" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/deluge-dev?hl=en.

Reply via email to