Skip to content

Commit

Permalink
Renaming Reactor.moveList to Reactor.moves (#1881)
Browse files Browse the repository at this point in the history
  • Loading branch information
john-science committed Sep 18, 2024
1 parent 94d3ed7 commit f3d16df
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 18 deletions.
4 changes: 2 additions & 2 deletions armi/physics/fuelCycle/fuelHandlerInterface.py
Original file line number Diff line number Diff line change
Expand Up @@ -142,7 +142,7 @@ def makeShuffleReport(self):
This can be used to export shuffling to an external code or to
perform explicit repeat shuffling in a restart.
It creates a ``*SHUFFLES.txt`` file based on the Reactor.moveList structure
It creates a ``*SHUFFLES.txt`` file based on the Reactor.moves structure
See Also
--------
Expand All @@ -155,7 +155,7 @@ def makeShuffleReport(self):
# remember, we put cycle 0 in so we could do BOL branch searches.
# This also syncs cycles up with external physics kernel cycles.
out.write("Before cycle {0}:\n".format(cycle + 1))
movesThisCycle = self.r.core.moveList.get(cycle)
movesThisCycle = self.r.core.moves.get(cycle)
if movesThisCycle is not None:
for (
fromLoc,
Expand Down
13 changes: 6 additions & 7 deletions armi/reactor/reactors.py
Original file line number Diff line number Diff line change
Expand Up @@ -293,7 +293,7 @@ def __init__(self, name):
self.timeOfStart = time.time()
self.zones = zones.Zones() # initialize with empty Zones object
# initialize the list that holds all shuffles
self.moveList = {}
self.moves = {}
self.scalarVals = {}
self._nuclideCategories = {}
self.typeList = [] # list of block types to convert name - to -number.
Expand Down Expand Up @@ -1886,13 +1886,12 @@ def _getReflectiveDuplicateAssembly(self, neighborLoc):
def setMoveList(self, cycle, oldLoc, newLoc, enrichList, assemblyType, assemName):
"""Tracks the movements in terms of locations and enrichments."""
data = (oldLoc, newLoc, enrichList, assemblyType, assemName)
# NOTE: moveList is actually a moveDict (misnomer)
if self.moveList.get(cycle) is None:
self.moveList[cycle] = []
if data in self.moveList[cycle]:
if self.moves.get(cycle) is None:
self.moves[cycle] = []
if data in self.moves[cycle]:
# remove the old version and throw the new on at the end.
self.moveList[cycle].remove(data)
self.moveList[cycle].append(data)
self.moves[cycle].remove(data)
self.moves[cycle].append(data)

def createFreshFeed(self, cs=None):
"""
Expand Down
15 changes: 6 additions & 9 deletions doc/release/0.4.rst
Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,8 @@ New Features
#. ARMI now supports Python 3.12. (`PR#1813 <https://github.com/terrapower/armi/pull/1813>`_)
#. Removing the ``tabulate`` dependency by ingesting it to ``armi.utils.tabulate``. (`PR#1811 <https://github.com/terrapower/armi/pull/1811>`_)
#. Adding ``--skip-inspection`` flag to ``CompareCases`` CLI. (`PR#1842 <https://github.com/terrapower/armi/pull/1842>`_)
#. Provide utilities for determining location of a rotated object in a hexagonal lattice:
:func:`armi.utils.hexagon.getIndexOfRotatedCell`
(`PR#1846 <https://github.com/terrapower/armi/1846`)
#. Allow merging a component with zero area into another component (`PR#1858 <https://github.com/terrapower/armi/pull/1858>`_)
#. Provide utilities for determining location of a rotated object in a hexagonal lattice (``getIndexOfRotatedCell``). (`PR#1846 <https://github.com/terrapower/armi/1846`)
#. Allow merging a component with zero area into another component. (`PR#1858 <https://github.com/terrapower/armi/pull/1858>`_)
#. TBD

API Changes
Expand All @@ -23,9 +21,8 @@ API Changes
#. Removing deprecated method ``prepSearch``. (`PR#1845 <https://github.com/terrapower/armi/pull/1845>`_)
#. Removing unused function ``SkippingXsGen_BuChangedLessThanTolerance``. (`PR#1845 <https://github.com/terrapower/armi/pull/1845>`_)
#. Allow for unknown Flags when opening a DB. (`PR#1844 <https://github.com/terrapower/armi/pull/1835>`_)
#. ``Assembly.rotatePins`` and ``Block.rotatePins`` have been removed. Prefer to use
:meth:`armi.reactor.assemblies.Assembly.rotate` and meth:`armi.reactor.block.Block.rotate`
(`PR#1846 <https://github.com/terrapower/armi/1846`)
#. ``Assembly.rotatePins`` and ``Block.rotatePins`` have been removed. Prefer to use ``Assembly.rotate`` and ``Block.rotate``. (`PR#1846 <https://github.com/terrapower/armi/1846`)
#. Renaming ``Reactor.moveList`` to ``Reactor.moves``. (`PR#1881 <https://github.com/terrapower/armi/pull/1881>`_)
#. TBD

Bug Fixes
Expand All @@ -41,8 +38,8 @@ Bug Fixes

Quality Work
------------
#. Removing deprecated code (``axialUnitGrid``) (`PR#1809 <https://github.com/terrapower/armi/pull/1809>`_)
#. Refactoring (``axialExpansionChanger``) (`PR#1861 <https://github.com/terrapower/armi/pull/1861>`_)
#. Removing deprecated code ``axialUnitGrid``. (`PR#1809 <https://github.com/terrapower/armi/pull/1809>`_)
#. Refactoring ``axialExpansionChanger``. (`PR#1861 <https://github.com/terrapower/armi/pull/1861>`_)
#. TBD

Changes that Affect Requirements
Expand Down

0 comments on commit f3d16df

Please sign in to comment.