Skip to content

Commit 7ed1f0a

Browse files
committed
more caution in scipy netcdf backend
1 parent d6a47b7 commit 7ed1f0a

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

xarray/backends/scipy_.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -330,7 +330,7 @@ class ScipyBackendEntrypoint(BackendEntrypoint):
330330
"""
331331
Backend for netCDF files based on the scipy package.
332332
333-
It can open ".nc", ".nc4", ".cdf" and ".gz" files but will only be
333+
It can open ".nc", ".cdf", and "nc..gz" files but will only be
334334
selected as the default if the "netcdf4" and "h5netcdf" engines are
335335
not available. It has the advantage that is is a lightweight engine
336336
that has no system requirements (unlike netcdf4 and h5netcdf).
@@ -347,7 +347,7 @@ class ScipyBackendEntrypoint(BackendEntrypoint):
347347
backends.H5netcdfBackendEntrypoint
348348
"""
349349

350-
description = "Open netCDF files (.nc, .nc4, .cdf and .gz) using scipy in Xarray"
350+
description = "Open netCDF files (.nc, .cdf and .nc.gz) using scipy in Xarray"
351351
url = "https://docs.xarray.dev/en/stable/generated/xarray.backends.ScipyBackendEntrypoint.html"
352352

353353
def guess_can_open(
@@ -364,7 +364,7 @@ def guess_can_open(
364364

365365
if isinstance(filename_or_obj, str | os.PathLike):
366366
_, ext = os.path.splitext(filename_or_obj)
367-
return ext in {".nc", ".nc4", ".cdf", ".gz"}
367+
return ext in {".nc", ".cdf", ".nc.gz"}
368368

369369
return False
370370

0 commit comments

Comments
 (0)