Message147642
So I contacted the Unicode Technical Committee about the issue and received a promptly received a response back. They pointed that the ZWSP was, once upon a time considered white space but that was changed in Unicode 4.0.1
http://www.unicode.org/review/resolved-pri.html#pri21
One particular comment worth noting: "... for historical reasons the general category is still Zs (Space Separator)".
Perhaps this ticket can be changed to a feature request? In addition to stripping out whitespace, it is useful to remove any non-printable characters from a string (or know if a string contains any non-printable characters).
Perhaps a boolean keyword parameter, "control_chars" could be added to isspace and strip? Thus:
>>> u' \t\r\n\u200B'.isspace(control_chars=True)
True |
|
Date |
User |
Action |
Args |
2011-11-14 23:32:18 | mankyd | set | recipients:
+ mankyd, loewis, ezio.melotti |
2011-11-14 23:32:18 | mankyd | set | messageid: <1321313538.46.0.801341205797.issue13391@psf.upfronthosting.co.za> |
2011-11-14 23:32:17 | mankyd | link | issue13391 messages |
2011-11-14 23:32:17 | mankyd | create | |
|