Skip to content

Commit

Permalink
Update nimage.py
Browse files Browse the repository at this point in the history
generic subclasses not allowed in isinstance checks
  • Loading branch information
TimMonko committed Oct 13, 2024
1 parent bca7425 commit ce7b939
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/napari_ndev/nimage.py
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ def __init__(
super().__init__(image, reader)
self.napari_data = None
self.napari_metadata = {}
self.path = image if isinstance(image, PathLike) else None
self.path = image if isinstance(image, (str, Path)) else None

def _determine_in_memory(self, path=None, max_in_mem_bytes: int = 4e9, max_in_mem_percent: int = 0.3) -> bool:
"""
Expand Down

0 comments on commit ce7b939

Please sign in to comment.