| Reference | Downloads | Github

Conditional loop depending on slider answer worked yesterday, today not


The first routine of my online experiment is a consent form template (Text) with a slider component with two labels “agree” and “disagree” in a radio style.

I have added a conditional loop in order to continue the experiment if they click on “agree” and to quit if they click on “disagree”. It worked yesterday online without any problems. But today not, I haven’t done any changes to this. It still works fine if I run the experiment directly on the computer but not online: it shows me 4 radio button instead of the two and no matter on which I click it ends the experiment. I can not understand why this happens but maybe it happened to someone else?

Thanks for helping.

Can you link the repository and make it public please?

Go to “Code” in the experiment dashboard, copy that link and paste it here, and in the repository, go to “Settings” then “General” then “Permissions” and make sure it’s set to public.

If you want to do some digging yourself, on the Code page there should be a link that says “History”, that will tell you if the code was changed between yesterday and today. It pretty much had to be, in some way.

Yes I have changed some things to the code since yesterday but not on the routines/codes concerned, and was not able to find what it could be (especially because it works well when I run the experiment on the computer).
Thanks very much for helping, I hope you will find it out.

It looks like something may have been re-ordered so that the number of loops based on AgreeSelected is set before AgreeSelected is updated, and never updated after that? I couldn’t tell you why exactly that happened, but that’s my best guess.

Alternately I’m finding that there’s a number of issues that are browser cache related, so before getting too deep into that, try clearing your browser cache and see if it works then.

Ok I have cleared the browser cache and it still doesn’t work.

WebGL: INVALID_OPERATION: loseContext: context already lost

This is the error message I get in the JavaScript Console

I am using safari version 13.0.5

I have found another way to this: instead of having two labels “agree” and “disagree”, I ask the participants to click on ‘y’ or ‘n’ as a keyboard response and I changed my conditional loop according to the keyboard response. It doesn’t look so great as with the radio buttons but I think it is a good alternative.