37

After upgrade from Pycharm 2017.2.3 to Pycharm 2017.1.4 Pycharm's Debugger suggested to build cpython (or sth associated with it):

path/to/my/python /opt/pycharm-community-2017.1.4/helpers/pydev/setup_cython.py build_ext --inplace

After I did this, Debugger now instantly returns this error:

Process finished with exit code 139 (interrupted by signal 11: SIGSEGV)

I found out that there was similar issue with cpython (https://youtrack.jetbrains.com/issue/PY-23273) but I cannot use the workaround mentioned there because I am missing the files it suggest to remove... I am not using cython, I wish I ignored this message about building it..

I am on linux (SMP Debian 3.16.36-1+deb8u1 (2016-09-03) x86_64 GNU/Linux)

Python 2.7

dankal444
  • 3,172
  • 1
  • 23
  • 35
  • Have you tried creating a new debug run configuration? – nanotek Jul 10 '17 at 16:15
  • Yes, I did, no change. – dankal444 Jul 13 '17 at 09:21
  • This seems to happen regardless of python version. I get it when trying to debug code on a remote machine, in Pycharm Pro version; the interpreter I used was python3.5, from anaconda environment. Disabling PyQt (see re-gor's answer) solved the problem. – Mircea Jul 13 '18 at 08:52

11 Answers11

63

I've fixed it by disabling PyQt compatible option in PyCharms's debugger settings (Build, Execution, Deployment > Python Debugger). I don't use PyQt, so I have not met any troubles

re-gor
  • 1,311
  • 11
  • 17
31

Goto pycharm -> Preferences -> Build,Execution and deployment -> Python debugger

Check box Collect run-time types information for code insight.

This solved issues for me.

Sanchit
  • 347
  • 4
  • 10
10

I had the same issue with 2018.3 after updating and installing Cython for fast debugging.

The issue was with gevent library.

Solved enabling Gevent compatible option and disabling PyQt compatible.

enter image description here

Marcos Martínez
  • 545
  • 2
  • 9
  • 24
6

I did change Pycharm from 2017.1.4 to Pycharm EAP 2017.2, but with no effect.

I solved the problem by making new python virtual environment and changing default Pycharm interpreter to it. Not the fastest solution I guess, but at least it worked.

Pycharm now again gives suggestions of building something for Cython, but now I just ignore it.

dankal444
  • 3,172
  • 1
  • 23
  • 35
2

I agree with James.

I meet the same question as you after I install PYQT. After I uninstall pyqt by Pycharm's "Preference->Project:your current project->Project Interpreter" find pyqt and push '-' button, the debug works.

What is interesting is that when I run a script which includes 'from PyQt4 import QtGui'. The pyqt package installed auto. And the debug does not work again. So I uninstall pyqt again and debug works one more time!

So I think there may be some package make debug not work , what you should do is just find and uninstall it. The crime package is often the pyqt, matplotlib or something similary.

Cauchyzhou
  • 31
  • 3
2

i meet this problem, and i search for it a long time, all caused by the compatible of pyqt,So I think a good idea to solve it....

  • uninstall pyqt and matplotlib
  • Fist install pyqt
  • Second install matplotlib

then the problem was solved happily.

Teddy Z.P.J.
  • 101
  • 3
  • I also faced the same issue after PyCharm got updated to 2018.3.1 (professional). The code I am testing could be debug previously but not after update. Uninstalling and reinstalling pyqt, matplotlib worked. – YohanK Dec 06 '18 at 09:36
  • The @re-gor solution worked once. I re-created my env and now I have no issues (at least few debugs) – visoft Sep 04 '19 at 10:02
1

Mine worked after I removed pyqt5 bindings.

sudo apt-get remove python3-pyqt5

This wasn't happening to me because of building cpython. It was because I had installed an unrelated program. Hope it helps.

James D
  • 1,580
  • 1
  • 13
  • 9
1

Try clearing all your breakpoints. Worked for me. Also check you have no problem when doing Run instead of Debug.

Edwin Evans
  • 2,726
  • 5
  • 34
  • 47
1

I resolved this problem in 2022.3 by clearing the many breakpoints I had

hasii
  • 350
  • 2
  • 9
0

I mostly randomly enabled and disabled Attach to subprocess automatically while debugging and PyQt compatible until I found a version that was stable for me. Eventually it was stable at Attach to subprocess automatically while debugging enabled and PyQt compatible enabled at auto.

I also followed

 - uninstall pyqt and matplotlib
 - Fist install pyqt
 - Second install matplotlib
Mark Wang
  • 342
  • 3
  • 11
-1

I had the same with 2017.1.4 Problem was resolved after update to 2017.1.5