Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
E
edx-submissions
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-submissions
Commits
db885c34
Commit
db885c34
authored
Jul 21, 2017
by
John Eskew
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix exception printing and log upon error.
parent
6d4b7cc9
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
0 deletions
+6
-0
submissions/api.py
+6
-0
No files found.
submissions/api.py
View file @
db885c34
...
...
@@ -89,6 +89,7 @@ class SubmissionRequestError(SubmissionError):
if
field_errors
is
not
None
else
{}
)
self
.
args
+=
(
self
.
field_errors
,)
def
__repr__
(
self
):
"""
...
...
@@ -991,6 +992,11 @@ def _get_or_create_student_item(student_item_dict):
student_item_serializer
=
StudentItemSerializer
(
data
=
student_item_dict
)
if
not
student_item_serializer
.
is_valid
():
logger
.
error
(
"Invalid StudentItemSerializer: {}"
.
format
(
unicode
(
student_item_serializer
.
errors
)
)
)
raise
SubmissionRequestError
(
field_errors
=
student_item_serializer
.
errors
)
return
student_item_serializer
.
save
()
except
DatabaseError
:
...
...
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