Skip to content

Commit f05967c

Browse files
jswhit2jswhit2
authored andcommitted
fix has_***_filter functions to use c interface
1 parent 906d9a8 commit f05967c

2 files changed

Lines changed: 21 additions & 18 deletions

File tree

.github/workflows/miniconda.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -45,8 +45,8 @@ jobs:
4545
4646
- name: Tests
4747
run: |
48-
export NO_PLUGINS=YES
49-
#export HDF5_PLUGIN_PATH="${CONDA_PREFIX}/hdf5/lib/plugin/"
48+
#export NO_PLUGINS=YES
49+
export HDF5_PLUGIN_PATH="${CONDA_PREFIX}/hdf5/lib/plugin/"
5050
pytest -s -rxs -v test
5151
5252
run-mpi:

src/netCDF4/_netCDF4.pyx

Lines changed: 19 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -3558,10 +3558,11 @@ to be installed and in `$PATH`.
35583558
"""**`has_blosc_filter(self)`**
35593559
returns True if blosc compression filter is available
35603560
"""
3561-
if __has_blosc_support__:
3562-
return True
3563-
else:
3564-
return False
3561+
3562+
#if __has_blosc_support__:
3563+
# return True
3564+
#else:
3565+
# return False
35653566

35663567
cdef int ierr
35673568
with nogil:
@@ -3573,10 +3574,10 @@ to be installed and in `$PATH`.
35733574
returns True if zstd compression filter is available
35743575
"""
35753576

3576-
if __has_zstandard_support__:
3577-
return True
3578-
else:
3579-
return False
3577+
#if __has_zstandard_support__:
3578+
# return True
3579+
#else:
3580+
# return False
35803581

35813582
cdef int ierr
35823583
with nogil:
@@ -3588,10 +3589,10 @@ to be installed and in `$PATH`.
35883589
returns True if bzip2 compression filter is available
35893590
"""
35903591

3591-
if __has_bzip2_support__:
3592-
return True
3593-
else:
3594-
return False
3592+
#if __has_bzip2_support__:
3593+
# return True
3594+
#else:
3595+
# return False
35953596

35963597
cdef int ierr
35973598
with nogil:
@@ -3603,11 +3604,13 @@ to be installed and in `$PATH`.
36033604
returns True if szip compression filter is available
36043605
"""
36053606

3606-
if not __has_ncfilter__:
3607-
return __has_szip_support__
3607+
#if not __has_ncfilter__:
3608+
# return __has_szip_support__
36083609

3609-
if not __has_szip_support__:
3610-
return False
3610+
#if __has_szip_support__:
3611+
# return True
3612+
#else:
3613+
# return False
36113614

36123615
cdef int ierr
36133616
with nogil:

0 commit comments

Comments
 (0)