Skip to content

Commit

Permalink
Don't allow transitions from ready_to_submit -> error.
Browse files Browse the repository at this point in the history
  • Loading branch information
iloveagent57 authored and matthugs committed Feb 21, 2020
1 parent 04f9d79 commit 7eac5cf
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 3 deletions.
2 changes: 1 addition & 1 deletion edx_proctoring/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,6 @@
from __future__ import absolute_import

# Be sure to update the version number in edx_proctoring/package.json
__version__ = '2.2.7'
__version__ = '2.2.8'

default_app_config = 'edx_proctoring.apps.EdxProctoringConfig' # pylint: disable=invalid-name
Original file line number Diff line number Diff line change
Expand Up @@ -159,9 +159,16 @@ edx = edx || {};
var pingInterval = self.model.get('ping_interval');
self.timerTick += 1;
self.secondsLeft -= 1;

// AED 2020-02-21:
// If the learner is in a state where they've finished the exam
// and the attempt can be submitted (i.e. they are "ready_to_submit"),
// don't ping the proctoring app (which action could move
// the attempt into an error state).
if (
self.timerTick % pingInterval === pingInterval / 2 &&
edx.courseware.proctored_exam.configuredWorkerURL
edx.courseware.proctored_exam.configuredWorkerURL &&
this.model.get('attempt_status') !== 'ready_to_submit'
) {
edx.courseware.proctored_exam.pingApplication(pingInterval)
.catch(self.endExamForFailureState.bind(self));
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"name": "@edx/edx-proctoring",
"//": "Be sure to update the version number in edx_proctoring/__init__.py",
"//": "Note that the version format is slightly different than that of the Python version when using prereleases.",
"version": "2.2.7",
"version": "2.2.8",
"main": "edx_proctoring/static/index.js",
"repository": {
"type": "git",
Expand Down

0 comments on commit 7eac5cf

Please sign in to comment.