mirror of
https://github.com/openmc-dev/openmc.git
synced 2026-07-24 12:05:32 -04:00
When adding temperature data, give warning instead of error if MT not present.
This commit is contained in:
parent
14e90db9c6
commit
3a021a2438
1 changed files with 5 additions and 5 deletions
|
|
@ -320,11 +320,11 @@ class IncidentNeutron(EqualityMixin):
|
|||
|
||||
# Add normal and summed reactions
|
||||
for mt in chain(data.reactions, data.summed_reactions):
|
||||
if mt not in self:
|
||||
raise ValueError("Tried to add cross sections for MT={} at T={}"
|
||||
" but this reaction doesn't exist.".format(
|
||||
mt, strT))
|
||||
self[mt].xs[strT] = data[mt].xs[strT]
|
||||
if mt in self:
|
||||
self[mt].xs[strT] = data[mt].xs[strT]
|
||||
else:
|
||||
warn("Tried to add cross sections for MT={} at T={} but this "
|
||||
"reaction doesn't exist.".format(mt, strT))
|
||||
|
||||
# Add probability tables
|
||||
if strT in data.urr:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue