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
673cc2bb
Commit
673cc2bb
authored
Aug 23, 2012
by
kimth
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Keep queueuing time
parent
77f928d1
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
7 additions
and
1 deletions
+7
-1
common/lib/capa/capa/correctmap.py
+3
-0
common/lib/capa/capa/responsetypes.py
+4
-1
No files found.
common/lib/capa/capa/correctmap.py
View file @
673cc2bb
...
...
@@ -73,6 +73,9 @@ class CorrectMap(object):
def
is_right_queuekey
(
self
,
answer_id
,
test_key
):
return
self
.
is_queued
(
answer_id
)
and
self
.
cmap
[
answer_id
][
'queuestate'
][
0
]
==
test_key
def
get_queuetime_str
(
self
,
answer_id
):
return
self
.
cmap
[
answer_id
][
'queuestate'
][
1
]
if
self
.
is_queued
(
answer_id
)
else
None
def
get_npoints
(
self
,
answer_id
):
npoints
=
self
.
get_property
(
answer_id
,
'npoints'
)
if
npoints
is
not
None
:
...
...
common/lib/capa/capa/responsetypes.py
View file @
673cc2bb
...
...
@@ -1149,7 +1149,10 @@ class CodeResponse(LoncapaResponse):
(
error
,
msg
)
=
qinterface
.
send_to_queue
(
header
=
xheader
,
body
=
json
.
dumps
(
contents
))
queuestate
=
(
queuekey
,
''
)
# State associated with the queueing request
qtime
=
datetime
.
strftime
(
datetime
.
now
(),
'
%
Y
%
m
%
d
%
H
%
M
%
S'
)
queuestate
=
(
queuekey
,
qtime
)
cmap
=
CorrectMap
()
if
error
:
cmap
.
set
(
self
.
answer_id
,
queuestate
=
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