explicit instance check

This commit is contained in:
Patrick Shriwise 2023-02-21 00:47:47 -06:00
parent b8c7c76444
commit 1b68e61a3e

View file

@ -1,9 +1,9 @@
from collections.abc import Iterable
from numbers import Integral
import os
import subprocess
import openmc
from openmc.checkvalue import PathLike
from .plots import _get_plot_image
@ -74,7 +74,7 @@ def _process_CLI_arguments(volume=False, geometry_debug=False, particles=None,
if event_based:
args.append('-e')
if isinstance(restart_file, PathLike.__args__):
if isinstance(restart_file, (str, os.PathLike)):
args += ['-r', str(restart_file)]
if tracks: