Variables not being initialized in the generated JavaScript script

I am currently working on translating my PsychoPy experiment from the Builder to run online. I’ve encountered an issue with variables (var currentLoop; var frameDur etc.) not being initialized in the generated JavaScript script. It seems as if the generated JavaScript script lacks any automatic initialization of these variables, which seems odd. Any advice on what might be causing this would be great.

What version of PsychoPy are you using?

I am using v2023.1.3.

Update: I managed to resolve the issue. I re-coded the experiment step-by-step and identified that the incorrect translation was caused by a trickle-down effect, i.e. an arrow-shaped polygon not being translated correctly. I made the necessary corrections (thanks to this post: I need advice about one stimuli - #8 by shabkr), and now everything is initialized as expected.

1 Like