-
Notifications
You must be signed in to change notification settings - Fork 18
Labels
bugsA deviation from expected behavior that does not reach the level of being reportable as an "Error".A deviation from expected behavior that does not reach the level of being reportable as an "Error".good first issueGood for newcomersGood for newcomers
Description
Describe the bug
Importance is missing a default _tree and when str is called this leads to an AttributeError.
To Reproduce
A short code snippet of what you have ran. Please change or remove any specific values or anything that can't be public. For example:
problem = montepy.read_input("tests/inputs/test_importance.imcnp")
print(problem.cells._importance)Error Message (if any)
If an error message was printed please include the entire stacktrace. If it includes any specific values please change or remove them. For example:
print(self)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
self = Importance: in_cell_block: False, set_in_cell_block False,
{}
def __str__(self):
if not self.in_cell_block and self._problem is None:
> return " ".join(self.input_lines)
E AttributeError: 'Importance' object has no attribute 'input_lines'
montepy/data_inputs/importance.py:165: AttributeErrorMCNP input file snippet
see tests/inputs/test_importance.imcnp
Version
- Version 0.4.1
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
bugsA deviation from expected behavior that does not reach the level of being reportable as an "Error".A deviation from expected behavior that does not reach the level of being reportable as an "Error".good first issueGood for newcomersGood for newcomers