[Idle-dev] Unicode Literal in IDLE. (python2)
Andrew Svetlov
andrew.svetlov at gmail.com
Mon Apr 22 14:38:17 CEST 2013
As http://www.python.org/dev/peps/pep-0434/ has been accepted we *can*
do enhancements in IDLE for Python 2.
Not sure we *should* do it for this case.
Lets discuss in http://bugs.python.org/issue17348 and
http://bugs.python.org/issue15809.
On Mon, Apr 22, 2013 at 3:03 PM, Tomoki Imai <tomo832 at gmail.com> wrote:
> Of cource, I know, using Python3 is the best way.
> But, there are libraries only supporting Python2 (i.e python-xlib).
> Using Python2's dual-text system is not so difficult for me.
> Because I'm Japanese, I had to handle Japanese with many charsets in every
> programs I made.
> And I have one simple rule.
>
> "Use unicode type all time.
> Input must be converted to unicode soon.
> Output must be converted to str late."
>
> And, fixing this bug can open a can of worms ?
> I think, we should open it.
> IDLE needs cleanup such as removing too old codes.
>
>
>
> 2013/4/22 Terry Jan Reedy <tjreedy at udel.edu>
>
>> On 4/21/2013 4:20 PM, Andrew Svetlov wrote:
>>
>>> I think fixing this bug for python 2 can open a can of worms. Python 3
>>> works correctly IIRC.
>>>
>>> On Sun, Apr 21, 2013 at 7:47 PM, Tomoki Imai <tomo832 at gmail.com> wrote:
>>>
>>>> Hi.
>>>>
>>>> I found bug (I think) in IDLE.
>>>> That is, unicode literal in IDLE.
>>>> You can reconfirm it by executing following code in IDLE.
>>>>
>>>> u"こんにちは"
>>>>>>
>>>>> u'\xe3\x81\x93\xe3\x82\x93\**xe3\x81\xab\xe3\x81\xa1\xe3\**x81\xaf'
>>>> ("こんにちは" means hello in Japanese.It's unicode literal.)
>>>>
>>>> In normal Interpreter ( running in console)
>>>>
>>>> u"こんにちは"
>>>>>>
>>>>> u'\u3053\u3093\u306b\u3061\**u306f'
>>>>
>>>> I found a solution.
>>>> I posted here.But I found it was closed after I posted.
>>>>
>>>
>> To be clearer, it was closed a March 8.
>>
>>
>> http://bugs.python.org/**issue17348 <http://bugs.python.org/issue17348>
>>>>
>>>> Can I reopen it?Or, this is not bug?
>>>>
>>>
>> David reopened, but like Andrew, I am wary. One reason we made unicode
>> the text type in Python 3 was that patching the Python 2 dual-text system
>> became a bit like playing Whack-A-Mole
>> http://en.wikipedia.org/wiki/**Whac-A-Mole<http://en.wikipedia.org/wiki/Whac-A-Mole>
>>
>>
>>
>> ______________________________**_________________
>> IDLE-dev mailing list
>> IDLE-dev at python.org
>> http://mail.python.org/**mailman/listinfo/idle-dev<http://mail.python.org/mailman/listinfo/idle-dev>
>>
>
>
> _______________________________________________
> IDLE-dev mailing list
> IDLE-dev at python.org
> http://mail.python.org/mailman/listinfo/idle-dev
>
>
--
Thanks,
Andrew Svetlov
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/idle-dev/attachments/20130422/d5bfff51/attachment.html>
More information about the IDLE-dev
mailing list