@jon, or anyone else who can help:
I got a similar error when trying to upload my current experiment, I went and added the line of code that you had suggested above to debug. It seems like part of the issue is my custom code is messing things up, but not sure how or why:
Welcome to PsychoPy3!
v2020.1.3
20.2626 INFO Loaded monitor calibration from ['2020_05_21 11:33']
Generating PsychoJS script...
C:\Users\zhbre\Desktop\online_recoblast\code
C:\Users\zhbre\Desktop\online_recoblast\Auto->JS
C:\Users\zhbre\Desktop\online_recoblast
C:\Users\zhbre\Desktop\online_recoblast
C:\Users\zhbre\Desktop\online_recoblast
C:\Users\zhbre\Desktop\online_recoblast
C:\Users\zhbre\Desktop\online_recoblast
C:\Users\zhbre\Desktop\online_recoblast\thisExp=psychoJS.experiment;
win=psychoJS.window;
event=psychoJS.eventManager;
Array.prototype.append = [].push;
Object.prototype.upper = "".toUpperCase;
shuffle = util.shuffle;
randint = function(min, maxplusone) {
return Math.floor(Math.random() * (maxplusone - min) ) + min;
}
C:\Users\zhbre\Desktop\online_recoblast
C:\Users\zhbre\Desktop\online_recoblast
C:\Users\zhbre\Desktop\online_recoblast
C:\Users\zhbre\Desktop\online_recoblast
C:\Users\zhbre\Desktop\online_recoblast\code_init
C:\Users\zhbre\Desktop\online_recoblast\Auto->JS
Traceback (most recent call last):
File "C:\Program Files\PsychoPy3\lib\site-packages\psychopy\scripts\psyexpCompile.py", line 74, in generateScript
compileScript(infile=exp, version=None, outfile=filename)
File "C:\Program Files\PsychoPy3\lib\site-packages\psychopy\scripts\psyexpCompile.py", line 245, in compileScript
_makeTarget(thisExp, outfile, targetOutput)
File "C:\Program Files\PsychoPy3\lib\site-packages\psychopy\scripts\psyexpCompile.py", line 217, in _makeTarget
script = thisExp.writeScript(outfile, target=targetOutput, modular=True)
File "C:\Program Files\PsychoPy3\lib\site-packages\psychopy\experiment\_experiment.py", line 209, in writeScript
localDateTime, modular)
File "C:\Program Files\PsychoPy3\lib\site-packages\psychopy\experiment\components\settings\__init__.py", line 516, in writeInitCodeJS
self.prepareResourcesJS()
File "C:\Program Files\PsychoPy3\lib\site-packages\psychopy\experiment\components\settings\__init__.py", line 504, in prepareResourcesJS
resourceFiles = self.exp.getResourceFiles()
File "C:\Program Files\PsychoPy3\lib\site-packages\psychopy\experiment\_experiment.py", line 830, in getResourceFiles
thisFile = getPaths(thisParam.val)
File "C:\Program Files\PsychoPy3\lib\site-packages\psychopy\experiment\_experiment.py", line 755, in getPaths
if os.path.isfile(thisFile['abs']):
File "C:\Program Files\PsychoPy3\lib\genericpath.py", line 30, in isfile
st = os.stat(path)
ValueError: stat: path too long for Windows