[Idle-dev] Strange error
Kurt B. Kaiser
kbk@shore.net
24 Dec 2002 15:15:19 -0500
Tony Lownds <tony@lownds.com> writes:
> I'm seeing a strange bug.
>
> When I start up IDLE, and enter a line into the untitled window, I get
> this message:
>
> Exception in Tkinter callback
> Traceback (most recent call last):
> File
> "/BinaryCache/python/python-3.root~193/usr/lib/python2.2/lib-tk/Tkinter.py",
> line 1292, in __call__
> return apply(self.func, args)
> File "idlelib/EditorWindow.py", line 1014, in newline_and_indent_event
> if line == sys.ps1:
> AttributeError: 'module' object has no attribute 'ps1'
>
> The error stops happening if I have opened a Python Shell window.
>
> Anyone else seeing this?
Good one. It's caused by the change I made at
EditorWindow.py Rev 1.37
to fix the beep at the prompt and allow a tab to be backspaced.
I usually start with the shell window so I didn't see it. It's caused by
sys.ps1 not being set until the shell starts.
Workaround, select start with the shell.
I'll fix it.
--
KBK