Importing condition error

URL of experiment: Pavlovia
Dino / Religious Music and Cognition · GitLab

Description of the problem:

A participant has gotten the following error:

when getting the value of resource:
unknown resource

I have no counterbalance file named that, they are counterbalance 1-9. I have had similar threads where my files are being named different things and hence aren’t being “found” during the experiment as resources.

Why are these things being changed? I need help asap as I am losing many participants from these errors

NaN means Not a Number,

Please show the code where you set the counterbalance file name.

I have the conditions set to this in the outer loop controlling the music order:


I have counterbalance files 0-9

Instead of putting this in the loop definition, add the following to a Begin Experiment code tab:

counterbalance = 'counterbalance'+str(int(expInfo['participant'])%10)+'.xlsx'

Then put $counterbalance in the loop

Hi @wakecarter
I hope you are doing well. I am facing this very problem where I keep receiving the error regarding importing condition and getting the value of resource when I want to pilot my experiment online on Pavlovia.
I have tested other solutions presented here, but none of them worked.
What do you suggest I do?
Thank you in advance!

1 Like

Your issues is that your local hard drive “C:” is referenced in your file locations. You need to use relative file locations, and have all the files within the experiment you are running. I also note that your experiment (P2?) may be on your Desktop. Documents is better.

1 Like

Thanks @wakecarter for your reply. I changed the file path and still it does not work. Is it possible that sth is wrong with my excel file??

Are you getting exactly the same error message? If so, then perhaps you aren’t running the latest version of your code.

Yes, I still keep receiving the same error message. I also cleared my browser
cache and opened it incognito, but it did not work again.
BTW, can you make sense of this picture?