Summary of issue
SerpentToolsException in depmtx reader due to extra string lines
Code for reproducing the issue
Using set depmtx 1 creates a depmtx file for each burnable material. The file contains lines such as flx = x or N0 = zeros(n, 1), which are not present in the serpentTools/data depmtx_ref.m file.
Actual outcome including console output and error traceback if applicable
File ~\Documents\serpent-tools\src\serpentTools\parsers\__init__.py:154, in read(filePath, reader)
152 loader = reader
153 returnedFromLoader = loader(filePath)
--> [154](https://file+.vscode-resource.vscode-cdn.net/c%3A/Users/Sara/Documents/serpentRuns/RVACS-transt0/~/Documents/serpent-tools/src/serpentTools/parsers/__init__.py:154) returnedFromLoader.read()
155 return returnedFromLoader
File ~\Documents\serpent-tools\src\serpentTools\parsers\base.py:49, in BaseReader.read(self)
47 info("Reading {}".format(self.filePath))
48 self._precheck()
---> [49](https://file+.vscode-resource.vscode-cdn.net/c%3A/Users/Sara/Documents/serpentRuns/RVACS-transt0/~/Documents/serpent-tools/src/serpentTools/parsers/base.py:49) self._read()
50 info(" - done")
51 self._postcheck()
File ~\Documents\serpent-tools\src\serpentTools\parsers\depmatrix.py:98, in DepmtxReader._read(self)
96 # process initial isotopics
97 line = stream.readline()
---> [98](https://file+.vscode-resource.vscode-cdn.net/c%3A/Users/Sara/Documents/serpentRuns/RVACS-transt0/~/Documents/serpent-tools/src/serpentTools/parsers/depmatrix.py:98) match = self._getMatch(line, NDENS_REGEX, 'n0 vector')
99 line = _parseIsoBlock(stream, tempN0, match, line, NDENS_REGEX)
100 numIso = len(tempN0)
...
88 .format(desc, self.filePath, line))
SerpentToolsException: Depmtx reader failed to match n0 vector from run_depmtx_air2_0_0.m:
flx = 2;
Expected outcome
reader reads the lines without erroring out
Versions
Please provide the following:
- Version from
serpentTools.__version__: 0.11.1.dev1+g1f6e60ede
- Python version -
python --version: Python 3.11.13
- IPython or Jupyter version if applicable
- If using the development version, the output from
git describe: 0.9.4rc0-47-g1f6e60e
Summary of issue
SerpentToolsException in depmtx reader due to extra string lines
Code for reproducing the issue
Using
set depmtx 1creates adepmtxfile for each burnable material. The file contains lines such asflx = xorN0 = zeros(n, 1), which are not present in the serpentTools/datadepmtx_ref.mfile.Actual outcome including console output and error traceback if applicable
Expected outcome
reader reads the lines without erroring out
Versions
Please provide the following:
serpentTools.__version__: 0.11.1.dev1+g1f6e60edepython --version: Python 3.11.13git describe: 0.9.4rc0-47-g1f6e60e