Pavlovia survey issue with group allocation using a random number

Hi everyone,

I’ve tried to implement a simple survey where a random number is generated, which is then used to assign participants to one of two groups. Participants then see different pages depending on the group they’ve been assigned. This is the survey: Pavlovia Survey

The issue is that, while it works fine when no answers are submitted, when I type in answers it starts going back and forth between the pages/reassigning participants to another group.
For example: participant is assigned to group A, sees the page for group A, types in an answer, clicks Next. The survey goes back to the random number/group allocation page, sometimes assigns group B instead, participant sees the page for group B.

I’m not sure if that’s entirely clear, so I’ve taken a screen capture of what is happening, which is in the folder attached. In the folder are also the survey’s JSON file and a data file, where you can see on line 3 that I’ve been able to answer question1 (on the group A page) and question2 (on the group B page), which is because of what I’ve explained.
survey-group-issue.zip (3.0 MB)

I’ve looked at all my settings and can’t see anything that would cause this, so not sure if this is my fault or if there’s a bug maybe?

Thanks in advance for your help!
Lorna

Sorry, but I’m afraid this is a bug. I’m hoping it will be fixed over the next month or so.

https://run.pavlovia.org/pavlovia/survey/?surveyId=0a1c0544-25d1-476d-b735-e1f074b3e387

Good to know, thanks Wake!

I’m helping about 115 students with final year projects and they have started to get to the point where this bug manifests - it does seem to have appeared since the Autumn as I demoed using the method back in October. Hate to be putting the pressure on but any sense of that ‘month’ estimate to fix it given 27 days ago means it may well get fixed in the next week (which basically would save us a huge amount of grief) or is it further out in which case I need to dfind a workaround

Hi Andrew,

Honestly I’m not sure whether it will be fixed by next week.

However, I’ve just written a workaround

https://run.pavlovia.org/vespr/survey-group

To launch a survey create a URL of the form

https://run.pavlovia.org/vespr/survey-group?surveyID=733492ba-8997-416b-9c8c-4fe08c3519bc&groups=3

This will launch survey 733492ba-8997-416b-9c8c-4fe08c3519bc and randomly allocate a value for group between 1 and 3.

Please test.

Hi Wake, I’m afraid when I click on https://run.pavlovia.org/Wake/survey-group I’m getting a 404 not found page

Sorry, wrong link. I moved it to https://run.pavlovia.org/vespr/survey-group/

Thanks that appears to be working with quick test at survey-group [PsychoPy]

Note for anyone else you then use Display page logic like {group} = ‘1’

I presume however this method will not pass Sona credit data to the survey - any chance of a variant that would do so?

What variable do you need to pass? It already passes participant.

Unless I’m misunderstanding the completion URL Sona is also expecting experiment_id and credit_token

The completion URL on the overview page should look something like this:
'https://ucd-ie.sona-systems.com/webstudy_credit.aspx?experiment_id=453&credit_token=249cfe8d848b4e1bb0099f8386be61bc&survey_code=' + {participant}

Since experiment_id and credit_token don’t change for a given experiment then these can be hard coded in the overview page (as per your link). Is that working?

Ah thanks, I wasn’t thinking that through fully but yes that should work for them