LAE

Welcome to the LAE community!  Please feel free to start a discussion in the discussion tab or join in a conversation.

Discussions

Members

Resources

Events

 View Only
  • 1.  allow a Node to return a success code even if failed...

    Employee
    Posted 02-08-2016 05:17

    Note: This was originally posted by an inactive account. Content was preserved by moving under an admin account.

    Originally posted by: dhrobertson

    Hi ,

    I am using a Filter node to clean up files at the end of a graph run... my filter node uses the deletefile function to remove the files.
    There should not be a reason for the files it is trying to delete, to not be there, but... I would like the node to "succeed" whether files exist or not.
    Is there a way I can emit a success code statement so that the node does not "fail" if it does not find any/all files?

    It wold be good for the node to always have a green tick otherwise the runs may say failed even though they are fine.

    thanks

    Doug


  • 2.  RE: allow a Node to return a success code even if failed...

    Employee
    Posted 02-08-2016 07:21

    Note: This was originally posted by an inactive account. Content was preserved by moving under an admin account.

    Originally posted by: stonysmith

    You should be able to use the TRY() function to accomplish that.

    try(deleteFile("a.txt"),1,0)