psychopy.org | Reference | Downloads | Github

Current builder experiment works when run from Firefox but not from Google Chrome or Microsoft Edge

Win10
PsychoPy 2020.2.10
Standard Standalone? (y)

What specifically went wrong when you tried that?:

I received a series of errors and I’m not sure what the root cause of them are. Here are some of the error message I have received.

Error message 1:
Unfortunately we encountered the following error:
-when uploading participant’s results for experiment: user_name/23_way_action_recognition
-when saving data from a previously opened session on the server
-unable to push data with key: PARTICIPANT_task_2021-05-11_11h35.31.440.csv to GitLab repository: Cmd(‘git’) failed due to: exit code(128) cmdline: git add /var/www/pavlovia.org/run/user_name/23_way_action_recognition/data//PARTICIPANT_task_2021-05-11_11h35.31.440.csv stderr: 'fatal: Unable to create ‘/data/run/user_name/23_way_action_recognition/.git/index.lock’: File exists. Another git process seems to be running in this repository, e.g. an editor opened by ‘git commit’. Please make sure all processes are terminated then try again. If it still fails, a git process

Error message 2 (When piloting on Chrome):
Unfortunately we encountered the following error:

  • TypeError: Cannot read property ‘loseContext’ of null

Try to run the experiment again. If the error persists, contact the experiment designer.

The accompanying console for error message 2 has the following errors:
-Failed to load resource: the server responded with a status of 404 ()
-TypeError: Cannot read property ‘loseContext’ of null
at Window.close (core-2020.2.js:748)
at quitPsychoJS (task.js:4445)
at Scheduler._currentTask (task.js:1720)
at Scheduler._runNextTasks (util-2020.2.js:1570)
at Scheduler._runNextTasks (util-2020.2.js:1574)
at update (util-2020.2.js:1527)
-FATAL unknown | {}

BrowserConsoleAppender.append @ log4javascript.min.js:1
Appender.doAppend @ log4javascript.min.js:1
Logger.callAppenders @ log4javascript.min.js:1
Logger.log @ log4javascript.min.js:1
fatal @ log4javascript.min.js:1
dialog @ core-2020.2.js:1157
window.onerror @ core-2020.2.js:1847

When I run in Microsoft Edge or Chrome, both give me sad faces in the top left corner of the screen.

I’ve journeyed my way through similar threads on this forum but none of them have been able to help me yet. I’m more than happy to share the code if there is some preferred way of doing that and someone would like to take a look at my JS.

Thank you for any help!

Hello,

try to solve this error first. This prevents syncing. You need to delete the file index.lock in your .git directory. Read this to get some understanding of what you are doing.

Best wishes Jens

Does your experiment have a lot of resources or things that are being updated or logged every frame?

Hi Jens,

Thanks for the explanation, link and proposed solution. The issue is that a participant reported this error message to me whilst running the online experiment on their own computer. So they were unable to push information to their data file I guess, but I do not understand how any other interacting git process would be running on their computer.

Thanks, Michael

Hi wakecarter,

Yes there are 23 polygon stimuli and 23 textstim in 2 different subsequent routines. The polygons need to change colour when the user clicks them and remain that way for 0.5 seconds as feedback.

Thanks, Michael

What I do is check that the stimuli need to be changed before actually changing them.

e.g. instead of

text.text = newText

in each frame you could have

if newText != text.text:
     text.text = newText

Hello Michael,

sorry. I did not read carefully enough. That is really strange that a participant can’t upload the data. We had this here in a research class when participants finished at the same time. Could it be the case that two participants submitted their data simultaneously? The git exit code 128 can mean quite different things. The line “…index.lock” File exists" tells one can’t write at the moment.

Best wishes Jens

So I’ve just removed everything from the experiment except a single routine with a single textstim. It runs fine in the builder and on Pavlovia using Firefox. But if I run this single routine in Pavlovia on Chrome, I get:

Unfortunately we encountered the following error:

  • Unspecified JavaScript error

Try to run the experiment again. If the error persists, contact the experiment designer.

And in the console it reads:
core-2020.2.js:1846 null

window.onerror @ core-2020.2.js:1846
error (async)
_captureErrors @ core-2020.2.js:1844
PsychoJS @ core-2020.2.js:1535
(anonymous) @ task.js:17

FATAL unknown | null

BrowserConsoleAppender.append @ log4javascript.min.js:1
error (async)
_captureErrors @ core-2020.2.js:1844
PsychoJS @ core-2020.2.js:1535
(anonymous) @ task.js:17

These exact errors occur for all of my experiments, whether they are inactive, in pilot mode, or in running mode. Other experiments that I see under ‘explore’ seem to be running fine in Chrome.

Thanks,
Michael

I think it’s unlikely but it’s possible, I’ll be careful to ensure the participant doesn’t run the experiment at the same time as someone else and see if that error reoccurs.

Thanks Jens,
Michael

Please could you share an active run link so I can try it (in Chrome)?

Absolutely, thanks for taking a look at this:

https://pavlovia.org/run/mxj719/23_way_action_recognition/html/

Those resources took a long time to download.

You hadn’t mentioned video files. * TypeError: Cannot read property ‘loseContext’ of null may simply be a resource overload or an issue with a specific video. I saw two or three videos (small squares in centre) before I stopped.

Check this page for suitable formats.
https://www.psychopy.org/online/mediaFormats.html

1 Like

Apologies, I should have described the study. It is a 23-way video classification task. As the experiment runs fine in Firefox and not in Chrome I didn’t consider that these errors were arising due to particulars of the study design.

Yes there are a lot of preprepared videos. Each participant watches 460 three second videos and classifies them. Each participant watches the videos under 1 of 10 different conditions, so I’ve had to upload those 460 x 10 videos. Altogether it is around 6.6Gb. Thanks for the format link, I already have these videos formatted this way.

It’s interesting that the experiment ran for you but for me, in Chrome, it doesn’t run at all.