Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add print warning if no natural isotopes when using add_element and wrote unit test #2975

Closed
wants to merge 3 commits into from

Conversation

cxtherineyu
Copy link
Contributor

Description

When adding nuclides to a material with add_element, OpenMC will silently do nothing if there are no natural nuclides of that element (e.g., plutonium). It would be nice if the user encountered a warning about this, because if the user was trying to do this in the first place they did not realize/recognize that there weren't actually any natural isotopes for that element. I added a warning when this happens.

Fixes # 2926

Checklist

  • I have performed a self-review of my own code
  • I have followed the style guidelines for Python source files (if applicable)
  • I have added tests that prove my fix is effective or that my feature works (if applicable)

@gridley
Copy link
Contributor

gridley commented Apr 24, 2024

It appears this is a duplicate of the already existing #2938, so I'm going to close this. If I'm doing this by mistake, feel free to re-open!

@gridley gridley closed this Apr 24, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants