[Idle-dev] Some implemented ideas that may help IDLE, request for feedback

Tal Einat taleinat at gmail.com
Thu Aug 20 22:26:17 CEST 2009


Bruce Sherwood wrote:
> Tal Einat wrote:
>>>>
>>>> * When printing a traceback, highlight the stack traces that pertain
>>>> to the running file and also remove the "in <module>" from them. This
>>>> is an attempt to make easier for novices to spot probable errors in
>>>> their own code.Highlight here simply means that it is written to
>>>> stderr, like it is done now, and the other parts are printed to
>>>> stdout. The effect normally is that, by default, errors in the primary
>>>> file are displayed in red, and other call stack information is blue.
>>>
>>> +0 (I haven't noticed this problem but will take your word for it)
>>
>> I'm a big fan of the Squeezer IDLE extension, and this would break
>> Squeezer's recognition of blocks of output / tracebacks. Such (ab)use
>> of sys.stdout and sys.stderr is too much of a hack IMHO.
>>
>> -1
>
> Could you say a bit more about what Squeezer is or does? How would this
> colorization affect Squeezer?

The Squeezer[1] extension for IDLE avoids having IDLE slow down or
hang when large amounts of text are printed in the shell.

Technically, Squeezer can replace any block of output (either stdout
or stderr) with a button. This button can be expanded back to the
original text, or it can be used to view the squeezed text in a
separate window or copy it to the clipboard. When a large amount of
output is written at once to the output, squeezer automatically
inserts a "squeezed" button instead without ever printing the output,
thus saving the interactive session from doom. One can also manually
squeeze blocks of output and blocks of stderr output such as
tracebacks.

A picture is worth a thousand words, so I'm attaching a screenshot I
just worked up in my IDLE.

- Tal

[1] http://pypi.python.org/pypi/Squeezer/1.0
-------------- next part --------------
A non-text attachment was scrubbed...
Name: Squeezer.JPG
Type: image/jpeg
Size: 117885 bytes
Desc: not available
URL: <http://mail.python.org/pipermail/idle-dev/attachments/20090820/b8886363/attachment-0001.jpeg>


More information about the IDLE-dev mailing list