[Idle-dev] [ idlefork-Bugs-507298 ] shellpython2.2 -Qnew smart indent error
noreply@sourceforge.net
noreply@sourceforge.net
Tue, 22 Jan 2002 17:16:37 -0800
Bugs item #507298, was opened at 2002-01-22 17:16
You can respond by visiting:
http://sourceforge.net/tracker/?func=detail&atid=109579&aid=507298&group_id=9579
Category: None
Group: None
Status: Open
Resolution: None
Priority: 5
Submitted By: Stephen M. Gava (elguavas)
Assigned to: Nobody/Anonymous (nobody)
Summary: shellpython2.2 -Qnew smart indent error
Initial Comment:
submitted to idle-dev by
Gregor Lingl <glingl@aon.at>
when starting idle under python2.2, using python2.2's
-Qnew switch (new division implementation),
AutoIndent.py throws an exception in the shell window
as detailed below.
original idle-dev message:
--------------------------
Has anybody an explanation vor this:
I started IDLE with the -Qnew switch.
(I have a copy of the IDLE-Icon with this switch on my
desktop)
Then I did the following in IDLE's Python-Shell-Window:
>>>def ggt(a,b):
while b: ##### WHEN NOW I HIT ENTER,
##### THE RESULT WAS:
>>> Exception in Tkinter callback
Traceback (most recent call last):
File "C:\Python22\lib\lib-tk\Tkinter.py", line 1292,
in __call__
return apply(self.func, args)
File "C:\Python22\Tools\idle\PyShell.py", line 588,
in enter_callback
self.auto.auto_indent(event)
File "C:\Python22\Tools\idle\AutoIndent.py", line
301, in newline_and_indent_event
self.smart_indent_event(event)
File "C:\Python22\Tools\idle\AutoIndent.py", line
208, in smart_indent_event
self.reindent_to(effective + self.indentwidth)
File "C:\Python22\Tools\idle\AutoIndent.py", line
455, in reindent_to
text.insert("insert", self._make_blanks(column))
File "C:\Python22\Tools\idle\AutoIndent.py", line
442, in _make_blanks
return '\t' * ntabs + ' ' * nspaces
TypeError: unsupported operand type(s) for *: 'str' and
'float'
def ggt(a,b):
while b:
So the cryptic Error - backtrace appeard after the >>>
- Prompt
and BEFORE the two lines I just had typed in.
Moreover, I only could return to the >>> - prompt
by hitting ^C (Keybord-Interrupt)
This strange behaviour doesn't appear in ordinarily
started IDLE.
It also does not appear when starting Python (with or
without -Qnew)
from the MS-DOS prompt.
----------------------------------------------------------------------
You can respond by visiting:
http://sourceforge.net/tracker/?func=detail&atid=109579&aid=507298&group_id=9579