Skip to content

software/erp5: add control for PYTHONHASHSEED

Jérome Perrin requested to merge feat/erp5-pythonhashseed into master

See https://docs.python.org/3/using/cmdline.html#envvar-PYTHONHASHSEED

Setting a value will set the environment variable for all zope processes and for the test runner.

Default behavior is:

  • for zope: do not set the variable, so default python behavior will be used ( equivalent to setting 0 on python2 and random on python3)
  • for test runner: generate a random value for each execution and print it, to make it easy to re-run a failing test with the same seed.

This means that ERP5 tests will likely reveal problems where code depends on python2 behavior of deterministic hashing. To keep previous behavior (and hide these problems), it's possible to set python-hash-seed to 0 in test suite parameters.

Edited by Jérome Perrin

Merge request reports