Online timing issues- routine 1 restarts before routine 2 is done

Background info:
I used the builder to create this experiment (Psychopy v2024.2.3). It runs fine locally, but I am having timing issues online. More specifically I have a loop that encompasses two routines, the first called “show_pairs”, and the second “rating_phase”.
It looks like this:


and this is my loop:

As you can see, show_pairs has a fixed timing of 4 seconds. This is the routine setup:


The code component there only saves the words shown to the output file, at the end of the routine.

The second routine asks participant to click on one of seven buttons (looks inelegant I know):


The code here again is just used to save data to the output.

Description of the problem:
When running online, show_pairs restarts automatically before rating_phase is complete. That means that, depending on how fast one clicks in the rating_phase, they go back to a different point in show_pairs (fixation is skipped, second word is already showing, or simply trial of show_pairs is already completed). Basically, show_pairs does not wait for rating_phase to be complete in order to restart. How can I fix this timing issue? The JS code is automatically translated from the builder as I don’t know how to code in JS, but I am happy to try any solution one might have.

Thanks in advance!

Hello

What ends the rating phase?

BTW, I would insert a short ITI between show_pairs and rating_phase by not starting the display of components in show_pairs and rating_phase at the start of the trial. But your experimental requirements may demand otherwise.

Best wishes Jens

Thank you for your reply.

The rating phase ends with a mouse click in the following manner:

I could add the ITI at the start of each routine, out of curiosity what is the reason for doing so?

I’ve been experiencing timing and loop issues in 2024.2. Try setting the version as 2024.1.4 in experiment settings and see if that helps.

That worked! Thank you so much!!!