[Python-Dev] hash randomization in 3.3

Nick Coghlan ncoghlan at gmail.com
Tue Feb 21 23:25:30 CET 2012


On Wed, Feb 22, 2012 at 8:07 AM, Antoine Pitrou <solipsis at pitrou.net> wrote:
> On Tue, 21 Feb 2012 22:51:48 +0100
> "Martin v. Löwis" <martin at v.loewis.de> wrote:
>> On the contrary. PYTHONHASHSEED should go in 3.3, as should any
>> facility to disable or otherwise fix the seed.
>
> Being able to reproduce exact output is useful to chase sporadic test
> failures (as with the --randseed option to regrtest).

I'm with Antoine here - being able to force a particular seed still
matters for testing purposes. However, the documentation of the option
may need to be updated for 3.3 to emphasise that it should only be
used to reproduce sporadic failures. Using it to work around
applications that can't cope with randomised hashes would be rather
ill-advised.

Cheers,
Nick.

-- 
Nick Coghlan   |   ncoghlan at gmail.com   |   Brisbane, Australia


More information about the Python-Dev mailing list