Commit afcd6fb1 by kimth

Safe logging of File-included answers

parent eeaa1e04
...@@ -16,6 +16,7 @@ from xmodule.exceptions import NotFoundError ...@@ -16,6 +16,7 @@ from xmodule.exceptions import NotFoundError
from progress import Progress from progress import Progress
from capa.capa_problem import LoncapaProblem from capa.capa_problem import LoncapaProblem
from capa.responsetypes import StudentInputError from capa.responsetypes import StudentInputError
from capa.util import convert_files_to_filenames
log = logging.getLogger("mitx.courseware") log = logging.getLogger("mitx.courseware")
...@@ -415,8 +416,7 @@ class CapaModule(XModule): ...@@ -415,8 +416,7 @@ class CapaModule(XModule):
event_info['problem_id'] = self.location.url() event_info['problem_id'] = self.location.url()
answers = self.make_dict_of_responses(get) answers = self.make_dict_of_responses(get)
event_info['answers'] = convert_files_to_filenames(answers)
event_info['answers'] = answers
# Too late. Cannot submit # Too late. Cannot submit
if self.closed(): if self.closed():
...@@ -424,8 +424,7 @@ class CapaModule(XModule): ...@@ -424,8 +424,7 @@ class CapaModule(XModule):
self.system.track_function('save_problem_check_fail', event_info) self.system.track_function('save_problem_check_fail', event_info)
raise NotFoundError('Problem is closed') raise NotFoundError('Problem is closed')
# Problem submitted. Student should reset before checking # Problem submitted. Student should reset before checking again
# again.
if self.lcp.done and self.rerandomize == "always": if self.lcp.done and self.rerandomize == "always":
event_info['failure'] = 'unreset' event_info['failure'] = 'unreset'
self.system.track_function('save_problem_check_fail', event_info) self.system.track_function('save_problem_check_fail', event_info)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment