Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Runtime segmentation fault using conda-forge netcdf4 #61

Closed
ngoldbaum opened this issue Sep 20, 2018 · 8 comments
Closed

Runtime segmentation fault using conda-forge netcdf4 #61

ngoldbaum opened this issue Sep 20, 2018 · 8 comments

Comments

@ngoldbaum
Copy link

This is very similar to #44.

The following code triggers a seg fault using netcdf4 1.4.1 from conda-forge (build py37h08833f9_0):

In [1]: from netCDF4 import Dataset

In [2]: Dataset('disk_mhdhdf5_chk_0020')
Assertion failed: (var->varid == grp->vars.nelems), function nc4_vararray_add, file /opt/concourse/worker/volumes/live/fc562f18-66b3-463b-5e64-a8624403e593/volume/libnetcdf_1536427225238/work/libsrc4/nc4var.c, line 431.

The file that triggers this is available here: http://use.yt/upload/4e49c548

Note that this is not a valid netcdf4 file. We hit this because yt will try to load random hdf5 files as netcdf4 files as a means to test if a given hdf5 file is a valid netcdf4 file.

Note that if I install netcdf4 from homebrew and the python bindings from pip, I get a RuntimeError and not a hard crash of the interpreter:

In [1]: from netCDF4 import Dataset

In [2]: Dataset('disk_mhdhdf5_chk_0020')
---------------------------------------------------------------------------
RuntimeError                              Traceback (most recent call last)
<ipython-input-2-a67635ee387f> in <module>()
----> 1 Dataset('disk_mhdhdf5_chk_0020')

netCDF4/_netCDF4.pyx in netCDF4._netCDF4.Dataset.__init__()

netCDF4/_netCDF4.pyx in netCDF4._netCDF4._get_vars()

netCDF4/_netCDF4.pyx in netCDF4._netCDF4._ensure_nc_success()

RuntimeError: NetCDF: Variable not found
@ngoldbaum
Copy link
Author

maybe @isuruf knows of another compile-time flag conda-forge should be using to turn off these checks?

@isuruf
Copy link
Member

isuruf commented Sep 20, 2018

What's the libnetcdf version?

@ngoldbaum
Copy link
Author

Ah sorry, didn't realize they were separate packages:

libnetcdf                 4.6.1                h4e6abe9_1

@ngoldbaum
Copy link
Author

OK, I don't know enough about cmake to feel confident to propose that pull request and work out any issues that happen as a result.

@ngoldbaum
Copy link
Author

@conda-forge-admin please rerender

@conda-forge-linter conda-forge-linter mentioned this issue Sep 22, 2018
1 task
@conda-forge-linter
Copy link

Hi! This is the friendly automated conda-forge-webservice.

I just wanted to let you know that I rerendered the recipe in #62.

@ngoldbaum
Copy link
Author

This is fixed with the latest build.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants