[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[netCDF #UGI-412728]: Unexpected chunking behavior test-case



> Hi Charlie,
> 

> 
> I think it's a bug that nc_def_var_chunking ignores an attempt to set
> contiguous storage for a variable that must use chunking, and the
> function should return an error in this case, rather then letting the
> bug result in subsequent HDF-level errors.  Assuming Ed agrees, we'll
> get this fixed in a subsequent snapshot release and let you know about
> it.
> 
> --Russ
> 
> > 2. Modifying the code by one line and uncommenting line 47,
> > which explicitly sets the variable to unchunked by calling
> > nc_def_var_chunking() with storage type = NC_CONTIGUOUS,
> > leads to numerous HDF complaints followed by failure of the
> > nc_put_var_int() call.
> >

Howdy Charlie!

Thanks for the test code. It always makes it easier to fix!

The bug here, as Russ pointed out, was that netcdf should not have let you set 
contiguous storage on a variable with an unlimited dimension. I've just checked 
in a fix to this and it will appear in tomorrow's snapshot.

I have added your test code (slightly modified) to the bottom of 
libsrc4/tst_vars2.c. Now it checks that if a variable uses a filter or an 
unlimited dimension, it will not allow you to set contiguous storage - you will 
get an error code if you try: NC_EINVAL.

Thanks for pointing out this bug!

Ed

Ticket Details
===================
Ticket ID: UGI-412728
Department: Support netCDF
Priority: Normal
Status: Closed