[issue14205] Raise an error if a dict is modified during a lookup

STINNER Victor report at bugs.python.org
Mon Mar 5 22:19:55 CET 2012


New submission from STINNER Victor <victor.stinner at gmail.com>:

Lib/test/crashers/nasty_eq_vs_dict.py does crash Python because of an
infinite loop in the dictionary lookup. The script modifies the
dictionary at each lookup, whereas Python tries a new lookup each time
that the dictionary is modified.

I proposed to make the lookup fail with a RuntimeError if the
dictionary has been modified during a lookup. It should not occur if
you are not doing something evil.

----------
components: Interpreter Core
files: dict_lookup.patch
keywords: patch
messages: 154976
nosy: haypo
priority: normal
severity: normal
status: open
title: Raise an error if a dict is modified during a lookup
versions: Python 3.3
Added file: http://bugs.python.org/file24740/dict_lookup.patch

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue14205>
_______________________________________


More information about the Python-bugs-list mailing list