Re: [Python-ideas] Unicode Name Aliases keyword argument abbreviation in unicodedata.name for missing names

2018-07-15 Thread Stephen J. Turnbull
Steven D'Aprano writes: > Sorry, I'm not sure if you mean my proposed alias() function isn't > useful, or Robert's try...except loop around it. I was questioning the utility of "If the abbreviation list is sorted by AdditionToUnicodeDate." But since you ask, neither function is useful TO ME, a

Re: [Python-ideas] Unicode Name Aliases keyword argument abbreviation in unicodedata.name for missing names

2018-07-15 Thread Stephen J. Turnbull
Robert Vanden Eynde writes: > Not for control characters. There's a standard convention for "naming" control characters (U+, U+0001, etc), which is recommended by the Unicode Standard (in slightly generalized form) for characters that otherwise don't have names, as "code point labels". This

Re: [Python-ideas] Unicode Name Aliases keyword argument abbreviation in unicodedata.name for missing names

2018-07-12 Thread Steven D'Aprano
On Thu, Jul 12, 2018 at 03:11:59PM +, Robert Vanden Eynde wrote: [Stephen] > I don't understand what you're asking for. The Unicode Standard > already provides canonical names. > > Not for control characters. That's because the Unicode Consortium considers that control characters have no

Re: [Python-ideas] Unicode Name Aliases keyword argument abbreviation in unicodedata.name for missing names

2018-07-12 Thread Steven D'Aprano
On Fri, Jul 13, 2018 at 12:02:20AM +0900, Stephen J. Turnbull wrote: > > I like your alias(...) function, with that one, an application > > could code my function like try name(x) expect > > alias(x).abbreviations[0]. If the abbreviation list is sorted by > > AdditionToUnicodeDate. > > I don'

Re: [Python-ideas] Unicode Name Aliases keyword argument abbreviation in unicodedata.name for missing names

2018-07-12 Thread MRAB
On 2018-07-12 16:02, Stephen J. Turnbull wrote: Robert Vanden Eynde writes: > As I'm at, I mentionned the ffef character but we don't care about > it because it already has a name, so that's mostly a control > character issue. The problem with control characters is that from the point of

Re: [Python-ideas] Unicode Name Aliases keyword argument abbreviation in unicodedata.name for missing names

2018-07-12 Thread Robert Vanden Eynde
> I like your alias(...) function, with that one, an application > could code my function like try name(x) expect > alias(x).abbreviations[0]. If the abbreviation list is sorted by > AdditionToUnicodeDate. I don't understand why that's particularly useful, especially in the Han case (see belo

Re: [Python-ideas] Unicode Name Aliases keyword argument abbreviation in unicodedata.name for missing names

2018-07-12 Thread Stephen J. Turnbull
Robert Vanden Eynde writes: > As I'm at, I mentionned the ffef character but we don't care about > it because it already has a name, so that's mostly a control > character issue. The problem with control characters is that from the point of view of the Unicode Standard, the C0 and C1 registers

Re: [Python-ideas] Unicode Name Aliases keyword argument abbreviation in unicodedata.name for missing names

2018-07-12 Thread Robert Vanden Eynde
I like your alias(...) function, with that one, an application could code my function like try name(x) expect alias(x).abbreviations[0]. If the abbreviation list is sorted by AdditionToUnicodeDate. Or try: return name(x) expect: if category(x) == 'Cc': return alias(x).abbrevia

Re: [Python-ideas] Unicode Name Aliases keyword argument abbreviation in unicodedata.name for missing names

2018-07-12 Thread Robert Vanden Eynde
Yes, my gmail client transformed unicodata . name to a url. I hope the mobile gmail client won't do it here. Yes current version is 11. I noticed it after sending the mail, I've compared to the version 6 and all my arguments are still valid (they just added some characters in the "correction" s

Re: [Python-ideas] Unicode Name Aliases keyword argument abbreviation in unicodedata.name for missing names

2018-07-12 Thread Oleg Broytman
On Thu, Jul 12, 2018 at 05:17:26PM +1000, Steven D'Aprano wrote: > > I propose adding a keyword argument, to > > unicodedata.name > > I don't think that's a real URL. I'm sure it was a stupid autoreplacement by web mail (hotmail in this case). As '.name' is a valid

Re: [Python-ideas] Unicode Name Aliases keyword argument abbreviation in unicodedata.name for missing names

2018-07-12 Thread Steven D'Aprano
Replying to a few points out of order... On Thu, Jul 12, 2018 at 02:03:07AM +, Robert Vanden Eynde wrote: > lookup(name(x)) == x for all x is natural isn't it ? The Unicode Consortium doesn't think so, or else they would mandate that all defined code points have a name. > In the NameAlias