[Andrew Kuchling] > Is it OK to refer to 8-bit strings under that name? > How about "expected an 8-bit string or Unicode string", when the > object passed to ord() isn't of the right type. > > Similarly, when the value is of the right type but has length>1, > the message is "ord() expected a character, length-%d string found". > Should that be "length-%d (string / unicode) found)" > > And should the type names be changed to '8-bit string'/'Unicode > string', maybe? Actually, upon reflection I think it was a mistake to add all these "or Unicode" clauses to the error msgs to begin with. Python used to have only one string type, we're saying that's also a hope for the future, and in the meantime I know I'd have no trouble understanding "string" as including both 8-bit strings and Unicode strings. So we should say "8-bit string" or "Unicode string" when *only* one of those is allowable. So "ord() expected string ..." instead of (even a repaired version of) "ord() expected string or Unicode character ..." but-i'm-not-even-motivated-enough-to-finish-this-sig-
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4