Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
E
edx-ora2
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
edx
edx-ora2
Commits
63228da5
Commit
63228da5
authored
Dec 15, 2016
by
Eric Fischer
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Allow cancellation to succeed if get_score errors
parent
a64fd58c
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
1 deletions
+6
-1
openassessment/workflow/models.py
+6
-1
No files found.
openassessment/workflow/models.py
View file @
63228da5
...
@@ -19,6 +19,7 @@ from django.utils.timezone import now
...
@@ -19,6 +19,7 @@ from django.utils.timezone import now
from
model_utils
import
Choices
from
model_utils
import
Choices
from
model_utils.models
import
StatusModel
,
TimeStampedModel
from
model_utils.models
import
StatusModel
,
TimeStampedModel
from
submissions
import
api
as
sub_api
from
submissions
import
api
as
sub_api
from
openassessment.assessment.base
import
AssessmentError
from
openassessment.assessment.signals
import
assessment_complete_signal
from
openassessment.assessment.signals
import
assessment_complete_signal
from
.errors
import
AssessmentApiLoadError
,
AssessmentWorkflowError
,
AssessmentWorkflowInternalError
from
.errors
import
AssessmentApiLoadError
,
AssessmentWorkflowError
,
AssessmentWorkflowInternalError
...
@@ -507,7 +508,11 @@ class AssessmentWorkflow(TimeStampedModel, StatusModel):
...
@@ -507,7 +508,11 @@ class AssessmentWorkflow(TimeStampedModel, StatusModel):
if
on_cancel_func
is
not
None
:
if
on_cancel_func
is
not
None
:
on_cancel_func
(
self
.
submission_uuid
)
on_cancel_func
(
self
.
submission_uuid
)
score
=
self
.
get_score
(
assessment_requirements
,
step_for_name
)
try
:
score
=
self
.
get_score
(
assessment_requirements
,
step_for_name
)
except
AssessmentError
as
exc
:
logger
.
info
(
"TNL-5799, exception in get_score during cancellation. {}"
.
format
(
exc
))
score
=
None
# Set the points_earned to 0.
# Set the points_earned to 0.
if
score
is
not
None
:
if
score
is
not
None
:
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment