exception handling for local eval