cleanup exception handling when scripts fail

issue same exceptions in ESSearch and GroupBy