netcdf-c icon indicating copy to clipboard operation
netcdf-c copied to clipboard

Testings imple szip filter setup Unexpected Result

Open WardF opened this issue 2 years ago • 8 comments

Running on MacOS, with HDF5 built w/out szlib support, is seeing a failure in nc_test4/tst_vars3.c, line: 443. The message being reported is:

**** testing simple szip filter setup...Sorry! Unexpected result (...)

This occurs even if ENABLE_FILTER_TESTING=OFF is specified when running cmake. I'm uncertain what the solution is, but it seems that we should be able to selectively toggle which filter libraries to use, even when detected, perhaps?

WardF avatar Jun 22 '22 19:06 WardF

Note: This only occurs using cmake.

WardF avatar Jun 22 '22 19:06 WardF

Make sure that HAVE_H5Z_SZIP is undefined if szip is not present in HDF5.

edwardhartnett avatar Jun 22 '22 20:06 edwardhartnett

I'm wondering if this block of nc_test4/tsts_vars3.c should be split off into a new test file that can be fenceposted via ENABLE_FILTER_TESTING; it feels like szip should not be part of the equation in this case. Or, perhaps change the current #ifdef HAVE_SZ to #ifdef HAVE_H5Z_SZIP; that feels more apt, for this file, but as always I'll benefit from considering it a few moments before asserting an answer.

WardF avatar Jun 22 '22 20:06 WardF

Rather, as always, I'll wish I had considered it before asserting an answer, if I don't.

WardF avatar Jun 22 '22 20:06 WardF

Well this test is a holdover from the case of HDF5 having szip, but before filters were supported.

In other words this test can run when HDF5 supports szip, even if filter testing is turned off.

I think it would also be fine to just not test this if filter testing is off, if that is easier.

edwardhartnett avatar Jun 22 '22 20:06 edwardhartnett

Ward- can you send me the contents of libnetcdf.settings when you see the MacOS fail?

DennisHeimbigner avatar Jun 22 '22 21:06 DennisHeimbigner

@DennisHeimbigner sure thing:

WardF avatar Jun 22 '22 21:06 WardF

May be fixed by PR https://github.com/Unidata/netcdf-c/pull/2421

DennisHeimbigner avatar Jun 22 '22 22:06 DennisHeimbigner