[Python-Dev] [Python-checkins] cpython: Close #14205: dict lookup raises a RuntimeError if the dict is modified during
Yury Selivanov
yselivanov.ml at gmail.com
Fri Mar 9 23:38:05 CET 2012
Actually, I too noticed that you've dropped few crasher tests. I think
we need to keep them, to make sure that future development will not
introduce the same vulnerabilities. That's a common practice with
unit-testing.
On 2012-03-09, at 5:27 PM, Victor Stinner wrote:
> On 09/03/2012 22:32, Jim Jewett wrote:
>> I do not believe the change set below is valid.
>>
>> As I read it, the new test verifies that one particular type of Nasty
>> key will provoke a RuntimeError -- but that particular type already
>> did so, by hitting the recursion limit. (It doesn't even really
>> mutate the dict.)
>
> Oh yes, thanks for the report. I fixed that test.
>
>> Meanwhile, the patch throws out tests for several different types of
>> mutations that have caused problems -- even segfaults -- in the past,
>> even after the dict implementation code was already "fixed".
>>
>> Changing these tests to "assertRaises" would be fine, but they should
>> all be kept; if nothing else, they test whether you've caught all
>> mutation avenues.
>
> I ran all these tests, none is still crashing. I don't think that it is interesting to keep them.
>
> Victor
> _______________________________________________
> Python-Dev mailing list
> Python-Dev at python.org
> http://mail.python.org/mailman/listinfo/python-dev
> Unsubscribe: http://mail.python.org/mailman/options/python-dev/yselivanov.ml%40gmail.com
More information about the Python-Dev
mailing list