Skip to content

Commit

Permalink
pre-commit changes
Browse files Browse the repository at this point in the history
  • Loading branch information
mtryan83 committed Jul 17, 2023
1 parent fdc78e8 commit d967d83
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions yt/frontends/gizmo/data_structures.py
Original file line number Diff line number Diff line change
Expand Up @@ -44,11 +44,13 @@ def _is_valid(cls, filename, *args, **kwargs):
)
# From Apr 2021, 7f1f06f, public gizmo includes a header variable
# GIZMO_version, which is set to the year of the most recent commit
# We should prefer this to checking the metallicity, which might
# We should prefer this to checking the metallicity, which might
# not exist
if "GIZMO_version" not in fh["/Header"].attrs:
dmetal = "/PartType0/Metallicity"
if dmetal not in fh or (fh[dmetal].ndim > 1 and fh[dmetal].shape[1] < 11):
if dmetal not in fh or (
fh[dmetal].ndim > 1 and fh[dmetal].shape[1] < 11
):
valid = False
fh.close()
except Exception:
Expand Down

0 comments on commit d967d83

Please sign in to comment.