[ncl-talk] how redirect fatal error message on a log file?

Rick Brownrigg brownrig at ucar.edu
Thu Jul 27 07:03:59 MDT 2017


Hi,

My colleague Dennis Shea pointed out the following
 capabilities, which I was unaware of:


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

It contains:

To redirect all error reporting to a file:

  setvalues err
    "*errFileName*
<http://www.ncl.ucar.edu/Document/Graphics/Resources/err.shtml#errFileName>"
: "/tmp/myErrors"
  end setvalues

This will send all errors reported by NCL during execution to the file
/tmp/myErrors


====

Also: not printing at all ...

http://www.ncl.ucar.edu/FAQ/#err_msgs_006




On Thu, Jul 27, 2017 at 6:34 AM, Francesco Trotta <
francesco.trotta4 at unibo.it> wrote:

> ​ok, thanks
>
> Fra
> ------------------------------
> *Da:* Rick Brownrigg <brownrig at ucar.edu>
> *Inviato:* mercoledì 26 luglio 2017 22:56
> *A:* Francesco Trotta
> *Cc:* ncl-talk at ucar.edu
> *Oggetto:* Re: [ncl-talk] how redirect fatal error message on a log file?
>
> Hi,
>
> You can of course use standard unix I/O redirection:
>
>    ncl myScript >myscript.log
>
> but this will capture all output from your script, including output from
> print statements. Unfortunately, ncl does not send error messages to
> stderr; if it did,  you could isolate only error output.
>
> Rick
>
> On Wed, Jul 26, 2017 at 10:57 AM, Francesco Trotta <
> francesco.trotta4 at unibo.it> wrote:
>
>> Dear NCL,
>>
>>    When I run my ncl scripts I get my fatal error message on a std output
>> (i.e. on the terminal screen)
>>
>>
>>    I would like for my application to send the error message not on the
>> std output but  in a log file.
>>
>>    Is there in ncl the way to do this?
>>
>>
>> Thanks
>>
>> Francesco
>>
>> _______________________________________________
>> ncl-talk mailing list
>> ncl-talk at ucar.edu
>> List instructions, subscriber options, unsubscribe:
>> http://mailman.ucar.edu/mailman/listinfo/ncl-talk
>>
>>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mailman.ucar.edu/pipermail/ncl-talk/attachments/20170727/8e6470d6/attachment.html 


More information about the ncl-talk mailing list