Issues with editing/syncing experiments in version 3.2.2

URLs for reference
original experiment, working in 3.2.2 online: AvatarAutomaticProl [PsychoPy]
cognitive load task, working in 3.2.2 online: cogload [PsychoPy]

I want to edit an old experiment (created in version 3.2.2; first URL above) created by a colleague to add a cognitive load manipulation. To do this, I first checked that the cognitive load task would run in version 3.2.2 separately (second URL above). I was able to sync both experiments and get them to work separately online. When I try to combine them, I am having issues with syncing, where files synced to pavlovia do not reflect the changes I have made locally. When I try to sync the project, I get the following error message:

Traceback (most recent call last):
  File "C:\Program Files\PsychoPy\lib\site-packages\psychopy\app\pavlovia_ui\project.py", line 166, in submitChanges
    self.parent.project = self.project
AttributeError: 'NoneType' object has no attribute 'project'

I have tried exporting the html (manually, on save, and on sync), and each way appears to update the js file locally, but syncing does not upload the altered js file. I’m not sure if other things are also going wrong, this is just something I have noticed. Confusingly, even when I create a new project, it uploads the original js file. Further, when I now go back and try to reupload minor changes to the original experiments, i get the same sync error and any changes I make are not reflected in the online experiment.

Does anyone have an idea of what I can try to fix this? I gather issues with syncing have been addressed in the latest version, but I don’t want to update because this introduces a lot of bugs into the experiment I’m trying to edit, and I since i didn’t create it I don’t know how to fix them. I’m happy to share the repositories (not sure how to do this) or provide further info if needed.

Thanks!

If the issue is that changes aren’t reflected online, check that you are viewing the latest version by refreshing the browser using Ctrl-Shift-R or an incognito tab.

Thanks, I tried recombing the experiments component by component, syncing changes each time to make sure it works/refreshing the browser to make sure it was the latest version. This worked until I added one component of the cogload task (select_digit and the associated loop), at this point the export html stopped creating a new version of the legacy-browers js file, and I get an error when exporting the html (shown below). Shown below are the js files in the project html folder after exporting html having added the select_digit component/loop (details below).

image

When i try to sync at this stage, the updated js file (top) does not sync to the online repository (which I confirmed by checking time of last change in the repository). The experiment file itself does sync. When I pilot the project at this stage the changes I made do not show up; it appears that the previous, unedited version is still running.

Do you have an idea of what is happening here?

Details for reference:

Error shown when exporting the html:

TypeError: Can't represent a Param of type color

Details of the select_digit component/loop:

image

code component within select_digit:

text component within select_digit:

Thanks, adding text components does appear to be the problem. When I remove the text components of the routines I added to the original experiment, it now exports the html and creates both js files normally. I then tried re-adding the text components and changing the type of the text colour values to str in a text editor, and then tried exporting the html again, but the js files as before failed to be created.

Do you think a possible fix might be able to downgrade my version of psychopy and add the text components in an older version?

More generally, I’m confused as to why these text components caused no issue as part of the initally separate experiment i created (second URL of my original post), also running in 3.2.2, but now cause a problem as part of this experiment.

Update, I fixed the text component problem by copy-pasting a text component from the original experiment - the js files sync properly now.

1 Like