mirror of
https://github.com/openmc-dev/openmc.git
synced 2026-07-28 22:26:08 -04:00
Merge pull request #2298 from fusion-energy/improved_config_error_message
added acceptable keys to error message
This commit is contained in:
commit
1962139236
1 changed files with 3 additions and 1 deletions
|
|
@ -42,7 +42,9 @@ class _Config(MutableMapping):
|
|||
# Reset photon source data since it relies on chain file
|
||||
_DECAY_PHOTON_ENERGY.clear()
|
||||
else:
|
||||
raise KeyError(f'Unrecognized config key: {key}')
|
||||
raise KeyError(f'Unrecognized config key: {key}. Acceptable keys '
|
||||
'are "cross_sections", "mg_cross_sections" and '
|
||||
'"chain_file"')
|
||||
|
||||
def __iter__(self):
|
||||
return iter(self._mapping)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue