This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

classification
Title: MultiCall bug crashing the config dialog
Type: Stage:
Components: IDLE Versions:
process
Status: closed Resolution: accepted
Dependencies: Superseder:
Assigned To: Nosy List: georg.brandl, taleinat
Priority: normal Keywords: patch

Created on 2007-03-02 15:29 by taleinat, last changed 2022-04-11 14:56 by admin. This issue is now closed.

Files
File name Uploaded Description Edit
IDLE_MultiCall.070302.patch taleinat, 2007-03-02 15:29 Initial patch
Messages (3)
msg52027 - (view) Author: Tal Einat (taleinat) * (Python committer) Date: 2007-03-02 15:29
Simple patch to MultiCall which stops IDLE's config dialog from crashing upon OK/Apply.

The bug is caused by ConfigDialog calling event_add() for key bindings only if there are sequences to be bound, while event_delete() is called even if there are no sequences. This causes MultiCall's internal dictionary of virtual events to raise a KeyError when event_delete() is called with a virtual event, for which event_add() was not called.

The Best Thing IMO is to have MultiCall check if such an event exists in its internal dict, and if not - just ignore the event_delete() call.

Patch attached.
msg52028 - (view) Author: Tal Einat (taleinat) * (Python committer) Date: 2007-03-03 18:17
Just to be clear - the bug is that writing certain things in the extension config file (either the user file or the defaults file) causes IDLE's configuration handling mechanism to crash. One symptom is that IDLE's config dialog doesn't save or apply changes, and is therefore useless.

The bug occurs when a config option without a value is added under a *_bindings or *_cfgBindings section in the extensions config file.

This bug is a result of an assumption in the design of MultiCall which is not true in this case.
msg52029 - (view) Author: Georg Brandl (georg.brandl) * (Python committer) Date: 2007-03-06 11:52
Committed in rev. 54156, 54157 (2.5).
History
Date User Action Args
2022-04-11 14:56:22adminsetgithub: 44646
2007-03-02 15:29:05taleinatcreate