Skip to content

Commit

Permalink
docker: re-install netcdf4 from source as fix for netcdf4 build problem
Browse files Browse the repository at this point in the history
See Unidata/netcdf4-python#1192 (comment)

Hopefully able to fix the following weird multiple warnings in homepage notebook 3:
```
HDF5-DIAG: Error detected in HDF5 (1.12.2) thread 1:
  #000: H5A.c line 528 in H5Aopen_by_name(): can't open attribute
    major: Attribute
    minor: Can't open object
  #1: H5VLcallback.c line 1091 in H5VL_attr_open(): attribute open failed
    major: Virtual Object Layer
    minor: Can't open object
  #2: H5VLcallback.c line 1058 in H5VL__attr_open(): attribute open failed
    major: Virtual Object Layer
    minor: Can't open object
  #3: H5VLnative_attr.c line 130 in H5VL__native_attr_open(): can't open attribute
    major: Attribute
    minor: Can't open object
  #4: H5Aint.c line 545 in H5A__open_by_name(): unable to load attribute info from object header
    major: Attribute
    minor: Unable to initialize object
  #5: H5Oattribute.c line 494 in H5O__attr_open_by_name(): can't locate attribute: '_QuantizeBitGroomNumberOfSignificantDigits'
    major: Attribute
    minor: Object not found
```
  • Loading branch information
tlvu committed May 24, 2023
1 parent 8aa243f commit 7da831c
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 0 deletions.
3 changes: 3 additions & 0 deletions docker/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,9 @@ ENV PATH="/opt/conda/envs/birdy/bin:$PATH"
# this python is from the birdy env above
RUN python -m ipykernel install --name birdy

# https://github.com/Unidata/netcdf4-python/issues/1192#issuecomment-1251532332
RUN python -m pip install --upgrade --force-reinstall --no-deps --no-cache-dir netcdf4 --no-binary netcdf4

# install using same channel preferences as birdy original env to not downgrade
# anything accidentally
# this is for debug only, all dependencies should be specified in
Expand Down
2 changes: 2 additions & 0 deletions docker/Dockerfile.testing
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,8 @@ RUN umask 0000 \
# && pip uninstall -y ravenpy \
# && mamba install -c conda-forge -c cdat -c bokeh -c plotly -c defaults -n birdy ravenpy aiohttp

RUN umask 0000 \
&& python -m pip install --upgrade --force-reinstall --no-deps --no-cache-dir netcdf4 --no-binary netcdf4
# RUN apt-get update && \
# DEBIAN_FRONTEND=noninteractive apt-get install -y unzip && \
# apt-get clean && \
Expand Down

0 comments on commit 7da831c

Please sign in to comment.