Version: 2020.2.5
What I am trying to do: I had a project I was running locally and on Pavlovia successfully, but then I downloaded it back from Pavlovia (to modify it for child participants) and saw that all the Py code was gone (the left panel of code component was empty) but the JS was there. So I kind of re-wrote the Py code back on the left side of the panel and made my modifications.
Now I have a hard time getting this program to upload to Pavlovia and also running locally. I have both the JS and thePy code in it, however I canāt seem to be able to run it locally due to JS syntax errors that occur in the Begin JS Routine and End JS Routine tabs. When I try to create new project to upload it to Pavlovia, I get an error message with āUnhandled internal errorā with the following:
Traceback (most recent call last):
File ā/Applications/PsychoPy.app/Contents/Resources/lib/python3.6/psychopy/app/pavlovia_ui/project.pyā, line 161, in submitChanges
AttributeError: āNoneTypeā object has no attribute āprojectā
After this, I sometimes get āupdatesā window show up for me to write the summary of changes, although Iām creating a new project. If I write something and press ok, my screen freezes and I have to force quit, and when I log into Pavlovia I see that an empty repository was created, but nothing else uploaded. Url: Sign in Ā· GitLab
I have attached the file here as well, and would appreciate any help I can get.SpatialMem101220.psyexp (106.8 KB)
Ok so a firstly, on your original project, you should be able to access the full version/commit history of the project. So if for one reason or another you suspect a file has been lost or deleted you should be able to recover it by using:
Dashboard> Experiment > (click on experiment you want) > View code > From the left hand panel look for Repository> Commits
Then scroll through your commit history to a point where you think that file would have been in your folder and select 'Browse files
ā
This will show you the full content of your directory at that point in time (so no need to rewrite code!).
Before moving forward with why there may be an issue with the new files, please can you see what happens if you try to retrieve the existing files from the version history (which by the sounds of it was running smoothly! )
This is very helpful, thank you very much for your reply! I did go back and check the earlier files I uploaded, including the first, although I still think that some of code components are missing. I actually ended up writing back the code when I first posted this, and I was able to run parts of it in the shell and it ran fine. Iām not saying that my code is definitely without errors but based on the recent error messages, it looks like itās about the JS Routine tabs which I cannot edit in the individual code components, and it seems to be why Iām getting the upload issue as well.
This is the error message I get when trying to run locally:
āAlert 4210:JavaScript Syntax Error in āBegin JS Routineā tab. See āLine 53: Unexpected end of inputā in the āBegin JS Routineā tab.
For further info see https://psychopy.org/alerts/4210.html
Alert 4210:JavaScript Syntax Error in āEnd JS Routineā tab. See āLine 2: Unexpected identifierā in the āEnd JS Routineā tab.ā
I tried opening the coder view, which doesnāt show any code when I just click on the window, so I went and opened the Py file from coder view and looked at and around those lines (2 and 53) and couldnāt see anything, it looked like the code PsychoPy adds itself and not anything that I typed.
Do you have any tips regarding these issues? Thank you again!
Hi @Becca I was able to find the version that ran online. I initially ran this as two blocks (Pavlovia and Pavlovia). Now I modified number of reps and combined the two blocks. I have not changed the JS code components I had written by looking at the crib sheet, however I keep failing to sync this. PsychoPy just stops responding and only creates and empty repository (Sign in Ā· GitLab). It either just stops responding, or says that it synced (along with the 4210 alert) but wonāt actually update anything in the repository. I uploaded the experiment here and would greatly appreciate any help with this!!!