[issue16258] test_local.TestEnUSCollection failures on Solaris 10

2017-06-20 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: This will change the documented behavior. Even if allow this change in a new feature release, it can't be made in maintained releases. A tuple of integers is memory excessive and slow. A bytes object is more compact (but may be less compact than a string) an

[issue16258] test_local.TestEnUSCollection failures on Solaris 10

2017-06-20 Thread STINNER Victor
STINNER Victor added the comment: > Agree, it's more a Python limitation. Why do you think of changing locale.strxfrm() from str to bytes or tuple? I prefer a tuple. But again, I'm not super motivated by this change. IMHO there are more severe issues that should be fixed in Solaris.

[issue16258] test_local.TestEnUSCollection failures on Solaris 10

2017-06-20 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Agree, it's more a Python limitation. -- ___ Python tracker ___ ___ Python-bugs-list mailing list

[issue16258] test_local.TestEnUSCollection failures on Solaris 10

2017-06-20 Thread STINNER Victor
STINNER Victor added the comment: > It is possible to use the special "encoding" for transformed strings on > platforms with broken wcsxfrm(). I wouldn't say that the function is wrong. wchar_t is 32-bit long, the function is free to use numbers > 0x10. It's more a Python limitation, no? -

[issue16258] test_local.TestEnUSCollection failures on Solaris 10

2017-06-20 Thread Serhiy Storchaka
Changes by Serhiy Storchaka : -- components: +Extension Modules -Interpreter Core ___ Python tracker ___ ___ Python-bugs-list mailing

[issue16258] test_local.TestEnUSCollection failures on Solaris 10

2017-06-20 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: It is possible to use the special "encoding" for transformed strings on platforms with broken wcsxfrm(). All codes < 0x1 are not changed. Codes >= 0x1 are encoded as a pair: 0x1 + (code >> 16), code & 0x. -- components: +Interpreter

[issue16258] test_local.TestEnUSCollection failures on Solaris 10

2017-06-20 Thread Antoine Pitrou
Changes by Antoine Pitrou : -- nosy: -pitrou ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.pyth

[issue16258] test_local.TestEnUSCollection failures on Solaris 10

2017-06-20 Thread STINNER Victor
STINNER Victor added the comment: Currently, the function is documented to return a string: https://docs.python.org/dev/library/locale.html#locale.strxfrm "Transforms a string to one that can be used in locale-aware comparisons." The problem is that we don't have enough developers who care of S

[issue16258] test_local.TestEnUSCollection failures on Solaris 10

2017-06-20 Thread STINNER Victor
STINNER Victor added the comment: A solution for that would be to return the raw byte string or to return a list of integers, rather than an unicode string. I don't think that locale.strxfrm() result is supposed to be displayed in a terminal, it should only be used to sort two strings, or to b

[issue16258] test_local.TestEnUSCollection failures on Solaris 10

2017-06-20 Thread Peter
Peter added the comment: I'm getting the same 2 errors in Python 3.4.6 on Solaris 11. Comes up when you run 'gmake test' or ./python -W default -bb -E -W error::BytesWarning -m test -r -w -j 0 -v test_locale.py -- nosy: +petriborg ___ Python tracke

[issue16258] test_local.TestEnUSCollection failures on Solaris 10

2017-03-10 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: May be issue15954 is related to this issue. Is this issue still reproduced? -- nosy: +serhiy.storchaka ___ Python tracker ___

[issue16258] test_local.TestEnUSCollection failures on Solaris 10

2012-10-17 Thread STINNER Victor
STINNER Victor added the comment: Python 3.2 rejects characters outside the range U+-U+10 in some operations, but not everywhere. I fixed Python 3.3 to be more strict and always reject characters outside this range. I noticed the Solaris issue with mbstowcs() on locale encodings different

[issue16258] test_local.TestEnUSCollection failures on Solaris 10

2012-10-17 Thread Jesús Cea Avión
Changes by Jesús Cea Avión : -- nosy: +haypo ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python

[issue16258] test_local.TestEnUSCollection failures on Solaris 10

2012-10-17 Thread Antoine Pitrou
Antoine Pitrou added the comment: (by the way, I also tried a memset() before calling wcsxfrm(): no change) -- ___ Python tracker ___

[issue16258] test_local.TestEnUSCollection failures on Solaris 10

2012-10-17 Thread Antoine Pitrou
Antoine Pitrou added the comment: It only works on Python 3.2 because PyUnicode_FromWideChar is more permissive, it seems. The first character in the wchar_t string returned by Solaris is still 0x101010e. -- ___ Python tracker

[issue16258] test_local.TestEnUSCollection failures on Solaris 10

2012-10-17 Thread Jesús Cea Avión
Jesús Cea Avión added the comment: BTW, this works in python 3.2: x86, 32 bit python, Solaris 10 update 10: """ Python 3.2.3 (default, Apr 12 2012, 13:29:13) [GCC 4.7.0] on sunos5 Type "help", "copyright", "credits" or "license" for more information. >>> import locale >>> locale.setlocale(loca

[issue16258] test_local.TestEnUSCollection failures on Solaris 10

2012-10-17 Thread Antoine Pitrou
Antoine Pitrou added the comment: With the system Python on s10: Python 2.6.8 (unknown, Apr 13 2012, 17:08:12) [C] on sunos5 Type "help", "copyright", "credits" or "license" for more information. >>> import locale >>> locale.strxfrm('a') 'a' >>> locale.setlocale(locale.LC_ALL, 'en_US.UTF-8') 'en

[issue16258] test_local.TestEnUSCollection failures on Solaris 10

2012-10-17 Thread Jesús Cea Avión
Jesús Cea Avión added the comment: I can reproduce this on my x86 Solaris 10 update 10. -- ___ Python tracker ___ ___ Python-bugs-list

[issue16258] test_local.TestEnUSCollection failures on Solaris 10

2012-10-17 Thread Trent Nelson
Trent Nelson added the comment: With the caveat that I know absolutely nothing about locales, here's what I've been able to reduce the problem down to: zinc (alias s11, Solaris 11 x64): >>> locale.setlocale(locale.LC_ALL, 'C') 'C' >>> locale.strxfrm('a') 'a' >>> locale.setlo

[issue16258] test_local.TestEnUSCollection failures on Solaris 10

2012-10-16 Thread Jesús Cea Avión
Changes by Jesús Cea Avión : -- nosy: +jcea ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.

[issue16258] test_local.TestEnUSCollection failures on Solaris 10

2012-10-16 Thread Trent Nelson
New submission from Trent Nelson: == ERROR: test_strxfrm (test.test_locale.TestEnUSCollation) -- Traceback (most recent call last): File "/home/cpython/builds