diff options
Diffstat (limited to 'yaksh')
-rw-r--r-- | yaksh/error_messages.py | 3 | ||||
-rw-r--r-- | yaksh/grader.py | 3 |
2 files changed, 2 insertions, 4 deletions
diff --git a/yaksh/error_messages.py b/yaksh/error_messages.py index 77bb1c9..7ea8618 100644 --- a/yaksh/error_messages.py +++ b/yaksh/error_messages.py @@ -9,8 +9,9 @@ def prettify_exceptions(exception, message, traceback=None, testcase=None): "traceback": traceback, "message": message } - if traceback and traceback.count('\n') > 6: + if exception == 'RuntimeError' or exception == 'RecursionError': err["traceback"] = None + if exception == 'AssertionError': value = ("Expected answer from the" + " test case did not match the output") diff --git a/yaksh/grader.py b/yaksh/grader.py index 4b4c892..38cce8d 100644 --- a/yaksh/grader.py +++ b/yaksh/grader.py @@ -159,9 +159,6 @@ class Grader(object): self.timeout_msg ) ) - except OSError: - msg = traceback.format_exc(limit=0) - error.append("Error: {0}".format(msg)) except Exception: exc_type, exc_value, exc_tb = sys.exc_info() tb_list = traceback.format_exception(exc_type, exc_value, exc_tb) |