Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
E
edx-platform
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-platform
Commits
96bb5e16
Commit
96bb5e16
authored
Sep 11, 2013
by
Alexander Kryklia
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'db/update-requests-lib' of github.com:edx/edx-platform into db/update-requests-lib
parents
68409f0c
6a854680
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
4 deletions
+5
-4
common/lib/xmodule/xmodule/open_ended_grading_classes/grading_service_module.py
+5
-4
No files found.
common/lib/xmodule/xmodule/open_ended_grading_classes/grading_service_module.py
View file @
96bb5e16
...
@@ -42,7 +42,7 @@ class GradingService(object):
...
@@ -42,7 +42,7 @@ class GradingService(object):
response
.
raise_for_status
()
response
.
raise_for_status
()
return
response
.
json
return
response
.
json
()
def
post
(
self
,
url
,
data
,
allow_redirects
=
False
):
def
post
(
self
,
url
,
data
,
allow_redirects
=
False
):
"""
"""
...
@@ -88,9 +88,10 @@ class GradingService(object):
...
@@ -88,9 +88,10 @@ class GradingService(object):
Returns the result of operation(). Does not catch exceptions.
Returns the result of operation(). Does not catch exceptions.
"""
"""
response
=
operation
()
response
=
operation
()
if
(
response
.
json
resp_json
=
response
.
json
()
and
response
.
json
.
get
(
'success'
)
is
False
if
(
resp_json
and
response
.
json
.
get
(
'error'
)
==
'login_required'
):
and
resp_json
.
get
(
'success'
)
is
False
and
resp_json
.
get
(
'error'
)
==
'login_required'
):
# apparrently we aren't logged in. Try to fix that.
# apparrently we aren't logged in. Try to fix that.
r
=
self
.
_login
()
r
=
self
.
_login
()
if
r
and
not
r
.
get
(
'success'
):
if
r
and
not
r
.
get
(
'success'
):
...
...
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