Skip to content

Commit

Permalink
use minversion
Browse files Browse the repository at this point in the history
  • Loading branch information
zacharyburnett committed Jul 19, 2024
1 parent 745c413 commit 6ac17df
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions gwcs/tests/test_wcs.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
# Licensed under a 3-clause BSD style license - see LICENSE.rst
import importlib.metadata
import warnings
import os.path

Expand All @@ -15,6 +14,7 @@
from astropy import wcs as astwcs
from astropy.wcs import wcsapi
from astropy.time import Time
from astropy.utils.introspection import minversion
import asdf

from .. import wcs
Expand Down Expand Up @@ -53,7 +53,7 @@


def asdf_open_memory_mapping_kwarg(memmap: bool) -> dict:
if tuple(int(part) for part in importlib.metadata.version("asdf").split(".")) >= (3, 1, 0):
if minversion("asdf", "3.1.0"):
return {"memmap": memmap}
else :
return {"copy_arrays": not memmap}
Expand Down

0 comments on commit 6ac17df

Please sign in to comment.