Skip to content

Commit

Permalink
Py39 can't check isisntance of a Union type.
Browse files Browse the repository at this point in the history
  • Loading branch information
MicahGale committed Dec 15, 2024
1 parent e855ca2 commit 09cf9f9
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion montepy/mcnp_object.py
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,7 @@ def __init__(
self._parameters = ParametersNode()
self._input = None
if input:
if not isinstance(input, InitInput):
if not isinstance(input, (montepy.input_parser.mcnp_input.Input, str)):
raise TypeError(f"input must be an Input or str. {input} given.")
if isinstance(input, str):
input = montepy.input_parser.mcnp_input.Input(
Expand Down

0 comments on commit 09cf9f9

Please sign in to comment.