Syntax error and currentLoop is undefined error

URL of experiment: DFFidelityReps [PsychoPy]

Description of the problem: Syntax Error followed by currentLoop is undefined error

My current experiment, when complied by PsychoPy to a .js, contains a hanging ‘}’.

Error message: Uncaught SyntaxError: Unexpected token ‘}’ Line: 3814

The only solution I have found is deleting it from the local .js file to get past initializing. However, when I do, I am met with a currentLoop is undefined error (my experiment contains loops and all routines requiring it have “is trials” checked).

I took the whole .js code and put it in VSCode to determine where the floating “}” could be coming from and am dumbfounded after about 3 hours of looking. Any help would be greatly appreciated!

The error is almost certainly visible in Builder.

Check any code components that aren’t set to Auto

Any code you’ve entered into component parameters or routine settings

Your expInfo variables.

1 Like