URL of experiment: https://run.pavlovia.org/bsingh/jbt-familiarity-online-study-1/html
Any thoughts on how to work around this?
In case it helps, here is the redirect URL:
and the js code component that creates my condition variable:
cond = [“control”,“comp_orig”, “comp_scale”, “familiar”][Math.floor(Math.random() * 4)];
In the meantime I was able to figure out a workaround and wanted to share it with anyone else who has the same issue.
In my study flow, I am linking SONA to Qualtrics to Pavlovia to Qualtrics and back to SONA. SONA creates a unique id for each participant which I am using as a participant number. The first qualtrics study is the consent form, and passes the participant number from SONA to pavlovia. In the first Qualtrics survey, I set up a new embedded condition which randomly selected the condition. I then passed this from Qualtrics to Pavlovia. This ensures that the condition variable comes before the redirect URL.
Here is a screenshot of the Qualtrics Survey Flow:
Here is an example of the redirect URL from Qualtrics to Pavlovia
Here is a picture of the experiment settings on pavlovia.
Next you have to tell psychopy that the expinfo variable is your condition variable
cond = expInfo['qcond'];
Now you can use it to pull specific excel files
Lastly the redirect URL to pass it along to the next survey. In my case Qualtrics
Sounds like you have found out lots of useful information about the issue already. Please can I check what version of PsychoPy you are using? the newest version has a “Before Experiment” tab in the code component, which might allow you to implement the JS code component you mention there before the redirect url.
EDIT: saw that you found a solution after posting to your initial question - pleased you found a work around and thanks for sharing your solution