Internal Error when pushing to Pavlovia

OS (e.g. Win10): Windows 10
PsychoPy version (e.g. 1.84.x): 2020.2.10
Standard Standalone? (y/n) If not then what?:
What are you trying to achieve?:

I was pushing code from the Builder to Pavolvia when presented with the unhandled internal error message. Below is the message

Traceback (most recent call last):
File “C:\Program Files\PsychoPy3\lib\site-packages\psychopy\”, line 864, in onIdle
File “C:\Program Files\PsychoPy3\lib\site-packages\psychopy\app\”, line 120, in doIdleTasks
File “C:\Program Files\PsychoPy3\lib\site-packages\psychopy\”, line 314, in flush
File “C:\Program Files\PsychoPy3\lib\site-packages\psychopy\”, line 300, in flush
target.write(formatted[thisEntry] + ‘\n’)
File “C:\Program Files\PsychoPy3\lib\site-packages\psychopy\”, line 208, in write
File “C:\Program Files\PsychoPy3\lib\site-packages\psychopy\app\runner\”, line 888, in write
StdOutRich.write(self, inStr, evt)
File “C:\Program Files\PsychoPy3\lib\site-packages\psychopy\app\”, line 40, in write
self.MoveEnd() # always ‘append’ text rather than ‘writing’ it
RuntimeError: wrapped C/C++ object of type StdOutText has been deleted

Does anyone know what this means?
Thank you in advance!

Looks like it’s trying to do something to the Stdout panel in the Runner window after it’s been closed - what windows did you have open when trying to sync? Was this a new project or an existing one?

I also notice you’re using 2020.2.10, there’s a new version out now (2021.1.2) so it may be something we’ve already fixed, might be worth updating to see if the problem persists :slight_smile:

This is a new project. I would like to upload it successfully to Pavlovia and then edit a few things in Python to finalize it and then sync it online. I had the Runner, Builder, Coder, and Google Chrome open when trying to upload. I will go ahead and update to the new version and come back shortly.

What do you recommend to remedy the Stdout panel?

Thank you

So I updated PsychoPy to the latest version and the code successfully pushes online! I had the files in a designated folder but it was a bit buried in other folders so I brought it directly to my downloads. Unfortunately, I have some added custom code and some of it works and some of it doesn’t. The first hiccup I have run into is below. Participants are supposed to answer 1 of 5 practice trials to see if two words are the same color and get feedback as a response.

This is what i have written in Python:
if(prac_resp.keys == str(PCorrAns)) or (prac_resp.keys == PCorrAns):
prac_resp.corr = 1
prac_resp.corr = 0

And this is the automatic translation by PyschoPy into Javascript

if (((prac_resp.keys === PCorrAns.toString()) || (prac_resp.keys === PCorrAns))) {
prac_resp.corr = 1;
} else {
prac_resp.corr = 0;

Are there any outstanding errors you can see? Also, is there a way for PsychoPy to tell what’s wrong specifically with the JS code?

Thank you! :smiley: