Re: [Bro-Dev] Consistent error handling for scripting mistakes

2018-11-12 Thread Robin Sommer
On Mon, Nov 12, 2018 at 12:27 -0600, Jonathan Siwek wrote: > I recently noticed there's a range of behaviors in how various > scripting mistakes are treated. There's a 4th: InterpreterException. > 1st question: should these be made more consistent? I'd say yes. Yes, definitely. > that it's

Re: [Bro-Dev] Consistent error handling for scripting mistakes

2018-11-12 Thread Jon Siwek
On Mon, Nov 12, 2018 at 1:44 PM Jim Mellander wrote: > I was tinkering with the sumstats code, and inadvertantly deleted the final > "}" closing out the last function. When running the code, the misleading > error message is received: Yes, that's a bit of a different topic, but still tracked

Re: [Bro-Dev] Consistent error handling for scripting mistakes

2018-11-12 Thread Jim Mellander
Along the same vein of sensible Bro script error handling, I'm resending an issue I found in January: I was tinkering with the sumstats code, and inadvertantly deleted the final "}" closing out the last function. When running the code, the misleading error message is received: error in bro/share

[Bro-Dev] Consistent error handling for scripting mistakes

2018-11-12 Thread Jon Siwek
Trying to broaden the scope of: https://github.com/bro/bro/issues/208 I recently noticed there's a range of behaviors in how various scripting mistakes are treated. They may (1) abort, as in case of bad subnet mask or incompatible vector element assignment (2) skip over evaluating (sub)expressio