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 terry.reedy
Recipients alexandre.vassalotti, benjamin.peterson, pitrou, serhiy.storchaka, skrah, terry.reedy, vstinner
Date 2014-03-03.18:02:58
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <>
The behavior of str.strip is not what I would expect from reading 
    Return a copy of the string with the leading and trailing characters removed.'''
but I guess it is consistent with a general rule that when mixing bytes and unicode (which was not always), the bytes are latin-1 decoded to unicode. However, the 'not always' part (str.strip yes, str.ljust no) made Python a bit inconsistent with itself.

Adding the unicode_literals import made Python more inconsistent with itself. "You can change byte literals to unicode literals, but if you do and you use one of the stdlib text apis that are bytes only, your program breaks."  This patch moves the inconsistency around a bit but does not remove it.  People who stick with 2.7 will have to live with inconsistency one way or another.

The turtle color issue is quite different in that it involve text names ('red') or encodings('#aabbcc') for color tuples that are quoted as text in order to be passed on to tkinter and tk (which wants unicode anyway).
Date User Action Args
2014-03-03 18:02:59terry.reedysetrecipients: + terry.reedy, pitrou, vstinner, alexandre.vassalotti, benjamin.peterson, skrah, serhiy.storchaka
2014-03-03 18:02:59terry.reedysetmessageid: <>
2014-03-03 18:02:59terry.reedylinkissue20015 messages
2014-03-03 18:02:58terry.reedycreate