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

Adding to GlobalFluxOptions docstring #1273

Merged
merged 2 commits into from
May 23, 2023
Merged

Conversation

john-science
Copy link
Member

Description

This PR attempts to document the over-the-top number of class attributes in GlobalFluxOptions.

In the process, I was able to remove two entirely unused class attributes. But it turns out there was one more secret one that wasn't defined in the constructor to begin with.

I also found a few of these aren't used in ARMI at all, but only in downstream plugins. So, I couldn't do as much cleanup as I was hoping.


Checklist

  • This PR has only one purpose or idea.
  • Tests have been added/updated to verify that the new/changed code works.
  • The release notes (location doc/release/0.X.rst) are up-to-date with any bug fixes or new features.
  • The documentation is still up-to-date in the doc folder.
  • The dependencies are still up-to-date in setup.py.

@john-science john-science added the documentation Improvements or additions to documentation label May 22, 2023
@john-science john-science linked an issue May 22, 2023 that may be closed by this pull request
@john-science
Copy link
Member Author

I probably didn't need to add so many reviewers. It's Tony's ticket.

But there are a lot of descriptions there, so who knows. I tried to be clear, and use existing setting descriptions where available.

Also... this class has SO MANY attributes with no defaults. That just feels... really strange to me. Like, half of those are booleans. We seriously can't default those? hmmmmmm

@albeanth
Copy link
Member

Also... this class has SO MANY attributes with no defaults. That just feels... really strange to me. Like, half of those are booleans. We seriously can't default those? hmmmmmm

I'd love to move all of the attributes that are only used in downstream plugins to those plugins, but I've been told that's not as easy as it seems....

@john-science
Copy link
Member Author

I'd love to move all of the attributes that are only used in downstream plugins to those plugins,

True. But this is supposed to just be a docstring PR, not a change to the API.

Still, we could look into that next.

@john-science john-science requested a review from mgjarrett May 23, 2023 14:23
@albeanth
Copy link
Member

I'd love to move all of the attributes that are only used in downstream plugins to those plugins,

True. But this is supposed to just be a docstring PR, not a change to the API.

Still, we could look into that next.

Agreed. 100%.

@john-science john-science merged commit 960d11f into main May 23, 2023
@john-science john-science deleted the global_flux_docstring branch May 23, 2023 17:01
@@ -351,7 +351,7 @@ class GlobalFluxOptions(executers.ExecutionOptions):
Attributes
----------
adjoint : bool
True if the ``CONF_NEUTRONICS_TYPE`` setting is set to ``adjoint``.
True if the ``CONF_NEUTRONICS_TYPE`` setting is set to ``adjoint`` or ``real``.
Copy link
Contributor

Choose a reason for hiding this comment

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

Should be

True if the ``CONF_NEUTRONICS_TYPE`` setting is set to ``adjoint`` or ``both``

drewj-usnctech added a commit to drewj-usnctech/armi that referenced this pull request Jun 1, 2023
* main: (23 commits)
  block converters preserve flags (terrapower#1271)
  Fixed float decimals v3 (terrapower#1283)
  Fixed string format error for snapshots (terrapower#1277)
  Pinning the versions of yamlize and ruamel (terrapower#1281)
  Releasing v0.2.7 (terrapower#1276)
  Creating verisons setting section (terrapower#1274)
  Adding to GlobalFluxOptions docstring (terrapower#1273)
  Harmonize material names and class names (terrapower#1270)
  Removing Component.getMassDensity (terrapower#1266)
  Cleaning up language for our versioning rules (terrapower#1175)
  Fixing the Settings Report in the Docs (terrapower#1264)
  Fixing getTemperatureAtDensity to use non-pseduo density (terrapower#1262)
  Fixing settings report docs from terrapower#1207 (terrapower#1263)
  Update test_components.py (terrapower#1261)
  Update gamma Uniform Mesh Converter (terrapower#1213)
  Updating way that settings report defaults are printed (terrapower#1207)
  Fixing UserPlugins.defineFlag (terrapower#1241)
  quick bug fix for PR 1239 (terrapower#1260)
  New Option to Control Lattice Physics Update Frequency (terrapower#1239)
  Fix a bug in database compare. (terrapower#1258)
  ...
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Docstring for GlobalFluxOptions attributes
3 participants