Spaces:
Runtime error
Runtime error
Tristan Thrush
commited on
Commit
•
5c5d2d9
1
Parent(s):
829775d
bugfixes
Browse files- app.py +2 -2
- collect.py +0 -1
app.py
CHANGED
@@ -121,9 +121,9 @@ with demo:
|
|
121 |
|
122 |
post_hit_js = """
|
123 |
function(state) {
|
124 |
-
if (state["assignmentId"] !== ""){
|
125 |
// If there is an assignmentId, then the submitter is on mturk
|
126 |
-
// and we need to submit their HIT.
|
127 |
const form = document.createElement('form');
|
128 |
form.action = 'https://workersandbox.mturk.com/mturk/externalSubmit';
|
129 |
form.method = 'post';
|
|
|
121 |
|
122 |
post_hit_js = """
|
123 |
function(state) {
|
124 |
+
if (state["assignmentId"] !== "" || state["assignmentId"] == "ASSIGNMENT_ID_NOT_AVAILABLE"){
|
125 |
// If there is an assignmentId, then the submitter is on mturk
|
126 |
+
// and has accepted the HIT. So, we need to submit their HIT.
|
127 |
const form = document.createElement('form');
|
128 |
form.action = 'https://workersandbox.mturk.com/mturk/externalSubmit';
|
129 |
form.method = 'post';
|
collect.py
CHANGED
@@ -54,4 +54,3 @@ for i in range(args.num_hits):
|
|
54 |
+ new_hit["HIT"]["HITGroupId"]
|
55 |
)
|
56 |
|
57 |
-
new_hits.append(new_hit)
|
|
|
54 |
+ new_hit["HIT"]["HITGroupId"]
|
55 |
)
|
56 |
|
|