ReferenceError: os/frameDur is not defined when I upload my experiment

I tried to upload my experiment to a server by exporting it as HTML, but it’s not working. I get two error messages after I enter the ID number.
Also I’m using the latest version of Psychopy and Windows 11.

Unfortunately we encountered the following error:

  • ReferenceError: os is not defined

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

Unfortunately we encountered the following error:

  • ReferenceError: frameDur is not defined

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

Do you have any advice or solutions, please?

I suspect you are trying to access local files, which won’t work online. Here are a couple of relevant links.

Translation Problem: OS is not defined (however, you can now use custom file names)

Thank you for advice, but your link doesn’t work, could you send it to me again please

Click on the name of the thread, not the URL of the experiment

Thank you for your help,

but I have another problem: I tried uploading it differently using Pavlovia, created an account, and checked my code because the auto-JavaScript hadn’t translated it correctly, so I had to edit it. And now, I have the same problem: when I try to upload it online using the driver, a white screen appears with a message saying “please wait a moment,” but the page never loads.

Do you have any ideas on how to help me, please?

What code was it that didn’t translate correctly and what did you change it to?

i have this error : Uncaught SyntaxError: Unexpected token ‘*’

Sounds like you’re trying to import a Python library.