Trouble getting IDL to "see" coda

Good morning Sander,

The question relates to a linux machine with the latest harp 1.17 installed, both for use at the command line as well as via IDL/python.

I wish to use coda_open() from an IDL script, which is running fine so far with harp_import() for e.g… However, I cannot convince IDL that coda is also installed. In my .bashrc file, I had the following so far.

export IDL_PATH=‘<IDL_DEFAULT>:’/usr/local/exelis/idl84/
export CODA_DEFINITION=/usr/local/share/coda/definitions/
export IDL_DLM_PATH=‘<IDL_DEFAULT>:’/usr/local/lib/harp/idl
export IDL_STARTUP=~/idl/idlstartup.pro
export UDUNITS2_XML_PATH=/usr/local/share/harp/udunits2.xml

If I also add coda to the IDL_DLM_PATH, as suggested in the coda installation, for e.g.

export IDL_DLM_PATH=‘<IDL_DEFAULT>:’/usr/local/lib/coda/idl:/usr/local/lib/harp/idl

I still get a % Variable is undefined: CODA_OPEN error.

Our sys admin cannot think of anything else to try.

Any ideas?

Many thanks,
MariLiza

This looks ok.

Some things to check:

  • did you actually configure+build+install coda with --enable-idl? Do you actually have files present in /usr/local/lib/coda/idl
  • what is the content of your ~/idl/idlstartup.pro? Does it perhaps modify dlm paths as well?
1 Like

Hi Sander,

Thanks for getting back to me.

Yes, I confirmed with the sys admin, he did use --enable-idl when configure+build+install coda

Yes, there are files in /usr/local/lib/coda/idl, however there appear to be duplicates from a previous installation:

(base) ls -ltr /usr/local/lib/coda/idl
total 4296
-rw-r–r–. 1 root root 1241 Mar 26 2018 coda-idl.dlm
-rwxr-xr-x. 1 root root 4251136 Mar 26 2018 coda-idl.so
-rwxr-xr-x. 1 root root 965 Mar 26 2018 coda-idl.la
-rw-r–r–. 1 root root 1241 May 8 19:12 coda_idl.dlm
-rwxr-xr-x. 1 root root 129872 May 8 19:12 coda_idl.so
-rwxr-xr-x. 1 root root 988 May 8 19:12 coda_idl.la

I am guessing that the older, 2018, files should not be there, right? there is a change from hyphen to underscore in the file names I see.

Finally, ~/idl/idlstartup.pro just contains a few directories with IDL subroutines so I don’t call them all the time, i.e.

(base) more idlstartup.pro
!PATH = Expand_Path(‘+/usr/local/exelis/idl84/lib/coyote’) + ‘:’ + !PATH
!PATH = Expand_Path(‘+/home/mariliza/TROPOMI/Programs/astrolib’) + ‘:’ + !PATH

Shouldn’t cause any trouble, right? it’s the David Fanning Coyote Library and the NASA IDL Astronomy Users Library.

Thanks!
MariLiza

The older coda installation is likely the problem. Please remove all the old files from 2018 and then things will likely work.

1 Like

Will ask sys admin to delete and let you know!
Many thanks
MariLiza

Just confirming that the old files were indeed causing the issue,
Thanks!
MariLiza