This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author lemburg
Recipients benjamin.peterson, jbradberry, lemburg, r.david.murray
Date 2009-09-18.19:59:20
SpamBayes Score 5.0939536e-10
Marked as misclassified No
Message-id <4AB3E6B8.1090602@egenix.com>
In-reply-to <1253303202.18.0.0643573803405.issue6300@psf.upfronthosting.co.za>
Content
Jeff Bradberry wrote:
> 
> Jeff Bradberry <jeff.bradberry@gmail.com> added the comment:
> 
> Ok, fixed.  I am kind of vague, though, on the usefulness of str.encode
> and unicode.decode.

codecs can work on any combination of types. Here's an example of
a codec that accepts str and unicode and returns str:

'313233'
>>> u'123'.encode('hex')
'313233'
>>> '313233'.decode('hex')
'123'
>>> u'313233'.decode('hex')
'123'

In 3.1 the method don't support this anymore, since they are more
strict w/r to type checking.
History
Date User Action Args
2009-09-18 19:59:22lemburgsetrecipients: + lemburg, benjamin.peterson, r.david.murray, jbradberry
2009-09-18 19:59:21lemburglinkissue6300 messages
2009-09-18 19:59:20lemburgcreate