eth2.0-specs/test_libs/config_helpers
Danny Ryan 5e902b448a Update test_libs/config_helpers/README.md
Co-Authored-By: protolambda <proto@protolambda.com>
2019-04-15 23:32:51 +10:00
..
preset_loader Work for new pyspec based test generators 2019-04-10 21:45:46 +10:00
README.md Update test_libs/config_helpers/README.md 2019-04-15 23:32:51 +10:00
requirements.txt intro configuration support pkg 2019-04-07 17:02:20 +10:00
setup.py intro configuration support pkg 2019-04-07 17:02:20 +10:00

README.md

ETH 2.0 config helpers

preset_loader: A util to load constants-presets with. See Constants-presets documentation.

Usage:

configs_path = 'configs/'

...

import preset_loader
from eth2spec.phase0 import spec
my_presets = preset_loader.load_presets(configs_path, 'mainnet')
spec.apply_constants_preset(my_presets)

WARNING: this overwrites globals, make sure to prevent accidental collisions with other usage of the same imported specs package.