Description of the problem: When trying to start the local debug mode for any experiment (even those running fine on pavlovia) i run into a ERR_EMPTY_RESPONSE error (see screenshot).
I’m using psychopy 2022.2.4 on mac and have chrome as my standard browser.
would anyone have an idea what causes this and how to fix it.
Alternatively, if there’s another way to debug the js file locally (i.e. not via builder but via VS code), i would also be grateful for ideas!
I’m receiving this issue suddenly on experiments that had previously been working with no errors. I’ve tried re-cloning the repositories and reinstalling PsychoPy.
Would greatly appreciate any help on this matter!
sorry no, it’s been quite some time back, I think I just kept syncing the project to Pavlovia and debugged it that way. Time-consuming, but I didn’t find an easier way to debug locally.
I resolved the error by killing whatever process was running in the localhost port. So since the local debug mode sent me to localhost:12002, I killed it by running the following command in my terminal (this is on a Mac): lsof -ti:12002 | xargs kill -9
After this, I could click the “Pilot in Browser” button from the Builder and it was back to normal.
If that doesn’t work, I was also able to run it manually by following instructions from here: How to run a local server and more! | by Mohammad H. Sattarian | Medium
Again in my terminal, I navigated to my project folder and then ran the following line: python2 -m SimpleHTTPServer 12003
Then I opened my browser and went to localhost:12003/ and the experiment was there.