| Reference | Downloads | Github

Error 'python.exe has stopped working'


I’m new to using PsychoPy but I’m having issues creating programmes with sounds.

I managed to create a programme with sounds and run the programme but now I keep getting an error message with ‘python.exe has stopped working’. The sound programme worked this morning so I know it’s not how I have created the experiment in builder, and I have not changed computers so I’m still using the same one for making and running the experiments.

This only happens in the programmes where I have sound files as I have created image programmes with no problems.

Can anyone help?


Can we see the full and complete error message?

**Hello, I have copied the message I get. **

The programme just stops, then I get a box which appears stating ‘python.exe has stopped working’. The link below shows an example.

When I look at the coder view, I see the following:

Welcome to PsychoPy2!

Running: E:\PSYCHOPY STUDY INFO\Quant Experiments\Quant4 Verbal

pyo version 0.8.0 (uses single precision)
Fatal Python error: (pygame parachute) Segmentation Fault

This application has requested the Runtime to terminate it in an unusual way.
Please contact the application’s support team for more information.

I had successfully created and ran the programme earlier today but when I came to run the programme a few hours later, this message appeared.



Sorry, I forgot to add that I am using Windows 7.

I have recently started getting this problem too Windows 7 and 10. If I take out all sound stimuli it works but this is less than ideal.

This only happens if I run it from the builder. If I hit the “compile script” button and run it from the coder it works. Afterwards I get this output

Running: …\

pyo version 0.8.0 (uses single precision)
portaudio error in Pa_AbortStream: Unanticipated host error
Exception TypeError: “‘NoneType’ object is not callable” in <bound method Server.del of <pyolib.server.Server object at 0x09B33750>> ignored

Yeah, I don’t have the option of removing the sounds as it’s a verbal number recognition task.

I’m hoping someone can help :slight_smile:

Did you try the suggestion above from @bigaddo81 ?

Have no idea why that would work but will be interested to see if it helps.

This did not work for me!

I’ve given up and have changed the task slightly to omit sounds.

Maybe PsychoPy just doesn’t like my sound files :frowning:




I’m also getting this error sporadically and also with an experiment using sound files. It doesn’t happen when I run it on an older (~Win7) computer or on a Mac, just on a newer computer (Win10). It also doesn’t happen when running experiments without sound files. I’m updated to 1.85.2; has this issue been fixed in the last six months?

I am also getting this exact error on Win10. It happens regardless of whether I try to run the experiment from the builder or the coder. I have also tried using multiple different audio file extensions (wav and mp3). Thanks in advance to anyone who can help!

mp3 files definitely won’t work, but wav files do.

Folks, the key is to try and narrow down what might be causing the problem. If it seems to be about sound files, is there a specific sound file that causes the issue? Do the sound demos work? What happens if you change the audio library in the PsychoPy preferences?

There’s very little we can do with the information we have so far.

Did anything come of this? I’m also getting the same issue re. psychopy.exe has stopped working, for builder-view experiments that contain wav files. Unfortunately for me it is not a reproducible error - i.e. sometimes running the experiment causes it to crash, but then a few minutes later, with the exact same experiment, it will do (nothing has changed between these times). Compiling the script didn’t work (as mentioned above), using wav files, windows 7, psychopy 1.84.2.

I believe you need to go to the sound preferences and make one minor change: ['pyo,‘pygame’] needs to be [‘pygame’,‘pyo’]. I have had success with this in my own studies. Sometimes I also will remove .cfg files from my AppData when PsychoPy is being finicky, but be sure to repeat this setup solution or you will get this error (although this error is pretty vague and could be happening for a multitude of other reasons).