ecmwf / eccodes-python

Python interface to the ecCodes GRIB/BUFR decoder/encoder

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Update min_recommended_version for eccodes

zklaus opened this issue · comments

What happened?

Version 1.6.0 added codes_bufr_key_is_coordinate in 880855c.

This was added to Eccodes only in version 2.31.0, c.f. ECC-1611.

Consequently, the min_recommended_version should be updated in

min_recommended_version_str = "2.21.0"

With older versions installed, we get runtime linker errors such as

ImportError: /opt/conda/envs/esmvaltool/lib/python3.11/site-packages/gribapi/_bindings.cpython-311-x86_64-linux-gnu.so: undefined symbol: codes_bufr_key_is_coordinate

What are the steps to reproduce the bug?

  • Install eccodes-python-1.6.0 with any version of eccodes<2.31.0 (>=2.21.0 according to min_recommended_version)
  • import gribapi

Version

v1.6.0

Platform (OS and architecture)

Linux

Relevant log output

No response

Accompanying data

No response

Organisation

No response

We do have some GitHub actions which use the ecCodes library as old as 2.27.0 and all the tests pass.
No errors on import
For example see https://github.com/ecmwf/eccodes-python/actions/runs/6235294400/job/16924240979

Thanks for following up. Which test imports gribapi? I could not find any.

Note that it is the minimum recommended version for gribapi (after all, it is in gribapi/__init__.py) and that the error shows up when you do import gribapi (c.f. "[...] steps to reproduce [...]" above).

OK I will update the minimum recommended version to 2.31.0
Many thanks