Reputation: 538
I'm on Mac OS X 10.8 and I've installed latest stable Python 3 (3.2.3) using Homebrew. Then I created a virtual environment using virtualenvwrapper - mkvirtualenv --no-site-packages --python=/usr/local/bin/python3 py3
I've configured Pycharm to use this virtualenv and I can run scripts, but I can't debug them, when I press debug Pycharm's debugger just quits:
/Users/qweqwe/.virtualenvs/py3/bin/python /Applications/PyCharm.app/helpers/pydev/pydevd.py --multiproc --client 127.0.0.1 --port 61596 --file /Users/qweqwe/Dropbox/Works/test/python/asyncore_test.py
pydev debugger: process 84441 is connecting
Connected to pydev debugger (build 117.663)
Process finished with exit code 132
Am I missing something or Pycharm just can't debug python3?
Update: It doesn't work at all, no matter what the script is. Even when debugging single line hello world debugger exits with error
Upvotes: 5
Views: 3975
Reputation: 11
I had the same problem yesterday,and you can try in this way: add
if __name__ == '__main__':
in your code , then set breakpoints and run Debugger.
Upvotes: 0
Reputation: 373
Yes. enter this in pycharm settings/Library/Frameworks/Python.framework/Versions/3.2/bin/python3(copied from Python3/MacOSX integration into pycharm)
Upvotes: 2