Strange behavior in PythonWin IDE

John Roth newsgroups at jhrothjr.com
Fri Nov 28 11:02:42 EST 2003


"Anders Eriksson" <anders.eriksson at morateknikutveckling.se> wrote in message
news:1fa1hqqgi2xas.dlg at morateknikutveckling.se...
> Hello!
>
> I'm using ActivePython 2.3.2 build 232 on Windows 2000 and I have noticed
a
> strange behavior in PythonWin IDE (win32all build 163)
>
> I'm from Sweden and we have a couple of letters in our alphabet that isn't
> part of ASCII and the strangeness is about one of them
>
> When I use the letter å (å) then the next character is eaten! Then
> when I enter the next character (the second after å) the last one appears.
>
> E.g.
> I want to write the word: "låna"
> I enter: "lå
> I enter: n ,but it won't show
> I enter: a , and the n appears
> I enter: " , and a s appears
> So in the editor I now have: "låns
>
> If I then enter a " PythonWin thinks that I'm beginning a new string and
> changes the color.
>
> If I then save the file and open it in another editor. Then I have the
> correct word: "låna"
>
> But if I run the program from the command prompt I get this error/warning
>
> "C:\Documents and Settings\ame\My Documents\My Scripts>python test.py
> sys:1: DeprecationWarning: Non-ASCII character '\xe5' in file test.py on
> line 1, but no encoding declared; see
> http://www.python.org/peps/pep-0263.html for details
>
> What is the error and what can I do to fix it?

There are two separate issues here:

1. To eliminate the depreciation warning, you do need to put in the
correct pep-0263 character set declaration line. I believe this will
become a fatal error in 2.4

However, the other problem isn't a Python problem as far as I know:
I believe the editor portion is written in C++. I could be wrong on
that, but please try reproducing the problem under IDLE.

John Roth
>
> // Anders
>
> -- 
> Womba Womba






More information about the Python-list mailing list