Merge pull request #1028 from chrisbrickhouse/1014

Warn about possible deadlock if response_ends_trial is false and trial_duration is null
This commit is contained in:
Becky Gilbert 2020-10-19 16:52:48 -07:00 committed by GitHub
commit dadf120f17
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 4 additions and 2 deletions

View File

@ -216,8 +216,9 @@ jsPsych.plugins["image-button-response"] = (function() {
jsPsych.pluginAPI.setTimeout(function() {
end_trial();
}, trial.trial_duration);
} else if (trial.response_ends_trial === false) {
console.warn("The experiment may be stuck in a loop. Try setting a trial duration or set response_ends_trial to true.");
}
};
return plugin;

View File

@ -174,8 +174,9 @@ jsPsych.plugins["image-keyboard-response"] = (function() {
jsPsych.pluginAPI.setTimeout(function() {
end_trial();
}, trial.trial_duration);
} else if (trial.response_ends_trial === false) {
console.warn("The experiment may be stuck in a loop. Try setting a trial duration or set response_ends_trial to true.");
}
};
return plugin;