Re: catching fatal errors in ncl

From: Mary Haley <haley_at_nyahnyahspammersnyahnyah>
Date: Tue, 21 Apr 2009 10:40:56 -0600 (MDT)

Jamie made me realize I forgot to mention something in my last
message. The "status_exit" function might be of use here:

    http://www.ncl.ucar.edu/Document/Functions/Built-in/status_exit.shtml

Note that the example shows how to use it for a non-existent file. :-)

--Mary

On Tue, 21 Apr 2009, Jamie Scott wrote:

> Keith,
>
> Here is a way to make the csh script abort if NCL reports a fatal error.
> I've used this method when running multiple ncl scripts that depend on each
> other's proper completion.
> Does this help?
>
> -Jamie
>
>
> On Apr 21, 2009, at 9:43 AM, ncl-talk-request_at_ucar.edu wrote:
>
>> Hi,
>>
>> I'm trying to use the techique described in the thread
>> "http://www.ncl.ucar.edu/Support/talk_archives/2006/0520.html" to catch
>> errors in an ncl script. That is, before calling ncl, I'm creating a
>> sentinel file and the last ncl command removes it. If the files exists
>> after ncl is done, I conclude that ncl aborted.
>>
>> However, ncl, version 5.1.0, is not aborting on fatal errors. So the ncl
>> script is always executing the command to remove the sentinel file. I've
>> attached a csh script that opens a non-existent file and reads from it a
>> non-existent variable. ncl reports multiple fatal errors, but proceeds,
>> and does remove the sentinel file.
>>
>> How do I make ncl abort on fatal errors?
>>
>> Thanks, Keith
>
>
_______________________________________________
ncl-talk mailing list
List instructions, subscriber options, unsubscribe:
http://mailman.ucar.edu/mailman/listinfo/ncl-talk
Received on Tue Apr 21 2009 - 10:40:56 MDT

This archive was generated by hypermail 2.2.0 : Tue Apr 21 2009 - 11:04:41 MDT