Skip to content

Make sure output is treated consistently in R2SManager#3994

Merged
pshriwise merged 1 commit into
openmc-dev:developfrom
paulromano:r2s-output-fix
Jul 5, 2026
Merged

Make sure output is treated consistently in R2SManager#3994
pshriwise merged 1 commit into
openmc-dev:developfrom
paulromano:r2s-output-fix

Conversation

@paulromano

Copy link
Copy Markdown
Contributor

Description

Small PR here to fix unwanted output behavior when carrying out R2S runs with R2SManager:

  • Before, an initialization of an empty OpenMC model (from openmc.lib.TemporarySession) was shown. This is fixed by passing output=False to TemporarySession
  • The actual initialization of the neutron transport model was always shown regardless of the output option specified in run_kwargs. Now it is handled consistently: if the user calls manager.run(run_kwargs={'output': True}) they will see output and if they call manager.run(run_kwargs={'output': False}) they will not see output.

Checklist

  • I have performed a self-review of my own code
  • I have run clang-format (version 18) on any C++ source files (if applicable)
  • I have followed the style guidelines for Python source files (if applicable)
  • I have made corresponding changes to the documentation (if applicable)
  • I have added tests that prove my fix is effective or that my feature works (if applicable)

@GuySten GuySten left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me.

@pshriwise pshriwise left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me as well @paulromano. Thanks!

@pshriwise pshriwise merged commit 3fcb969 into openmc-dev:develop Jul 5, 2026
17 checks passed
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.

3 participants