| Reference | Downloads | Github

PsychoPy Internal Error When Trying to Export HTML

OS (e.g. Win10): MacOS Big Sur
PsychoPy version (e.g. 1.84.x): 2021.1.2
Standard Standalone? (y/n):y
What are you trying to achieve?: I am trying to export HTML for my experiment and upload to Pavlovia. I have encountered the following error:
Traceback (most recent call last):
File “/Applications/”, line 759, in fileExport
File “/Applications/”, line 73, in generateScript
File “/Applications/”, line 242, in compileScript
File “/Applications/”, line 214, in _makeTarget
File “/Applications/”, line 242, in writeScript
File “/Applications/”, line 140, in writeInitCodeJS
File “/Applications/”, line 256, in writeInitCodeJS
File “/Applications/”, line 256, in
TypeError: unhashable type: ‘list’

What did you try to make it work?: After failing to compile to JS script, I tried compiling to python script, and it ran successfully with no errors. I tried quitting and reopening the app several times, and the same error comes up. If I ignore the error and click “export HTML” or “compile with JS script”, sometimes it just ignores my request. In my folder, I can see that a file called “index.html” is successfully generated, but nothing else. Please help!

This might be relevant

1 Like

@wakecarter, thanks! I have checked out that post and decided to update to PsychoPy version 2021.2.2. After that, I changed the style from [‘rating’] to rating, and now I’m able to export HTML, although it takes a lot longer than compiling to python script.