How to handle Luup error in a scene


I am writing a Luup script to run in a scene. This script will use the Weather Underground Plugin to obtain nearby weather conditions and determine if the scene should run or not. Searching the forums and Wiki I have not been able to find what will happen if there is a communications error and how I should handle this error in the Luup code.

Any help will be appreciated.



I have a similar scenario. Also calling WGET… sometimes there is a problem reaching the URL… then I get the “Error in LUA” for scenes banner… This is bad, since it then prevents all other scenes from running properly… is there some try catch mechanism for the LUA scene?

Did some quick googling… seems this is quite simple to handle…


I implemented it, and seems to work…