URL of experiment: https://run.pavlovia.org/psychunsw/forpsylab-anita-trinh-str-3-exp-2-v2/html/
JS Code: https://gitlab.pavlovia.org/psychunsw/forpsylab-anita-trinh-str-3-exp-2-v2/blob/master/html/Strand3Exp2_Draft2_OnlineOnly.js
Hi all! So the Builder version of my experiment runs just fine, but once I had uploaded the experiment onto Pavlovia, I wasn’t able to run my trials due to the error “this_loop_number not defined” (this_loop_number is a variable I defined myself in a Code Component). In my Code Component, the variable is defined at the beginning of the experiment, but the error for this_loop_number only appears once it reaches the conditions loop.
This experiment is being run at version 3.1, and I currently have PsychoPy 2020.1 installed on my computer.
I’ve tried doing the following things, none of which have worked:
- Changed all my Code Components (including the one defining this_loop_number) to “Auto > JS” from “Py”, then syncing the experiment to Pavlovia, and;
- Changing the code to say “var this_loop_number = 0;” rather than “this_loop_number = 0;”
Any help would be appreciated. Thank you!