Opened 15 months ago

Closed 15 months ago

Last modified 15 months ago

#331 closed Support (fixed)

problem with importing eccodes library in flex_extract_v7.1.3

Reported by: gance Owned by:
Priority: major Milestone:
Component: flex_extract Version: flex_extract_v7.1
Keywords: Cc:

Description (last modified by pesei)

I can't solve a problem with running the new run_bologna script to extract ecmwf fields using the remote access on my new ATOS home directory.

I got the following error message in the job output message

  MARS retrieve done ... 
Prepare 20220831/to/20220831
Traceback (most recent call last):
  File "/home/tpn/flex_extract_v7.1.3/Source/Python/", line 272, in <module>
  File "/home/tpn/flex_extract_v7.1.3/Source/Python/", line 110, in main
    prepare_flexpart(ppid, c)
  File "/home/tpn/flex_extract_v7.1.3/Source/Python/Mods/", line 161, in prepare_flexpart
    flexpart.deacc_fluxes(inputfiles, c)
  File "/home/tpn/flex_extract_v7.1.3/Source/Python/Classes/", line 974, in deacc_fluxes
    from eccodes import (codes_index_select, codes_get,
  File "/usr/local/apps/python3/3.8.8-01/lib/python3.8/site-packages/eccodes/", line 13, in <module>
    from .eccodes import *  # noqa
  File "/usr/local/apps/python3/3.8.8-01/lib/python3.8/site-packages/eccodes/", line 12, in <module>
    from gribapi import (
  File "/usr/local/apps/python3/3.8.8-01/lib/python3.8/site-packages/gribapi/", line 13, in <module>
    from .gribapi import *  # noqa
  File "/usr/local/apps/python3/3.8.8-01/lib/python3.8/site-packages/gribapi/", line 34, in <module>
    from gribapi.errors import GribInternalError
  File "/usr/local/apps/python3/3.8.8-01/lib/python3.8/site-packages/gribapi/", line 16, in <module>
    from .bindings import ENC, ffi, lib
  File "/usr/local/apps/python3/3.8.8-01/lib/python3.8/site-packages/gribapi/", line 35, in <module>
    raise RuntimeError("Cannot find the ecCodes library")
RuntimeError: Cannot find the ecCodes library

I have checked that eccodes is indeed mounted using python3 -m eccodes selfcheck

The  submitscript.template looks correct with 
 module load python3
  module load ecmwf-toolbox
  module load ecaccess

Error occurs when processing the flux accumulated fields.

Could you help to solve this problem ?

Best regards


Change History (3)

comment:1 Changed 15 months ago by saeck

Dear Gerard,

This might be a problem already reported - I copy the conversation/solution here:

"I experienced the very same error, i.e., RuntimeError: Cannot find the ecCodes library with version 7.1.3. Based on a hint from a flex_extract developer it was solved by substituting both instances of module load prgenv/gnu gcc/8.4.1 in submitscript.template with module load prgenv/gnu gcc/system. It looks like different gcc-compilers are (were?) available on different nodes of the server explaining the unsteady behaviour."


Last edited 15 months ago by pesei (previous) (diff)

comment:2 Changed 15 months ago by gance

Hello Sabine
Yes this has solved the problem.
Thanks a lot

comment:3 Changed 15 months ago by pesei

  • Description modified (diff)
  • Resolution set to fixed
  • Status changed from new to closed
  • Type changed from Defect to Support
Note: See TracTickets for help on using tickets.
hosted by ZAMG