Python 3.4 AssertionError in pycharm debugger

I have Pycharm 3.1 (latest version) installed, which supposedly supports python 3.4, however this morning it started throwing exceptions whenever I run the debugger. Is there anything I can do to fix this AssertionError?

C:\Python34\python.exe "C:\Program Files (x86)\JetBrains\PyCharm 3.1\helpers\pydev\pydevd.py" --multiproc --client 127.0.0.1 --port xx --file C:/Users/xx/PycharmProjects/drop/my_file.py Connected to pydev debugger (build 133.881) pydev debugger: process 8492 is connecting None Exception in thread pydevd.CheckAliveThread: Traceback (most recent call last): File "C:\Python34\lib\threading.py", line 921, in _bootstrap_inner self.run() File "C:\Program Files (x86)\JetBrains\PyCharm 3.1\helpers\pydev\pydevd_comm.py", line 252, in run self.OnRun() File "C:\Program Files (x86)\JetBrains\PyCharm 3.1\helpers\pydev\pydevd.py", line 187, in OnRun self.stop() File "C:\Program Files (x86)\JetBrains\PyCharm 3.1\helpers\pydev\pydevd_comm.py", line 262, in stop _Thread_stop(self) File "C:\Python34\lib\threading.py", line 990, in _stop assert not lock.locked() AssertionError Traceback (most recent call last): File "C:\Program Files (x86)\JetBrains\PyCharm 3.1\helpers\pydev\pydevd.py", line 996, in trace_dispatch if not t.isAlive(): File "C:\Python34\lib\threading.py", line 1120, in is_alive self._wait_for_tstate_lock(False) File "C:\Python34\lib\threading.py", line 1076, in _wait_for_tstate_lock assert self._is_stopped AssertionError Traceback (most recent call last): File "C:\Program Files (x86)\JetBrains\PyCharm 3.1\helpers\pydev\pydevd.py", line 996, in trace_dispatch if not t.isAlive(): File "C:\Python34\lib\threading.py", line 1120, in is_alive self._wait_for_tstate_lock(False) File "C:\Python34\lib\threading.py", line 1076, in _wait_for_tstate_lock assert self._is_stopped AssertionError Traceback (most recent call last): File "C:\Program Files (x86)\JetBrains\PyCharm 3.1\helpers\pydev\pydevd.py", line 996, in trace_dispatch if not t.isAlive(): File "C:\Python34\lib\threading.py", line 1120, in is_alive self._wait_for_tstate_lock(False) File "C:\Python34\lib\threading.py", line 1076, in _wait_for_tstate_lock assert self._is_stopped AssertionError Traceback (most recent call last): File "C:\Program Files (x86)\JetBrains\PyCharm 3.1\helpers\pydev\pydevd.py", line 996, in trace_dispatch if not t.isAlive(): File "C:\Python34\lib\threading.py", line 1120, in is_alive self._wait_for_tstate_lock(False) File "C:\Python34\lib\threading.py", line 1076, in _wait_for_tstate_lock assert self._is_stopped AssertionError Traceback (most recent call last): File "C:\Program Files (x86)\JetBrains\PyCharm 3.1\helpers\pydev\pydevd.py", line 996, in trace_dispatch if not t.isAlive(): File "C:\Python34\lib\threading.py", line 1120, in is_alive self._wait_for_tstate_lock(False) File "C:\Python34\lib\threading.py", line 1076, in _wait_for_tstate_lock assert self._is_stopped AssertionError Traceback (most recent call last): File "C:\Program Files (x86)\JetBrains\PyCharm 3.1\helpers\pydev\pydevd.py", line 996, in trace_dispatch if not t.isAlive(): File "C:\Python34\lib\threading.py", line 1120, in is_alive self._wait_for_tstate_lock(False) File "C:\Python34\lib\threading.py", line 1076, in _wait_for_tstate_lock assert self._is_stopped AssertionError Traceback (most recent call last): File "C:\Program Files (x86)\JetBrains\PyCharm 3.1\helpers\pydev\pydevd.py", line 996, in trace_dispatch if not t.isAlive(): File "C:\Python34\lib\threading.py", line 1120, in is_alive self._wait_for_tstate_lock(False) File "C:\Python34\lib\threading.py", line 1076, in _wait_for_tstate_lock assert self._is_stopped AssertionError Traceback (most recent call last): File "C:\Program Files (x86)\JetBrains\PyCharm 3.1\helpers\pydev\pydevd.py", line 996, in trace_dispatch if not t.isAlive(): File "C:\Python34\lib\threading.py", line 1120, in is_alive self._wait_for_tstate_lock(False) File "C:\Python34\lib\threading.py", line 1076, in _wait_for_tstate_lock assert self._is_stopped AssertionError Traceback (most recent call last): File "C:\Program Files (x86)\JetBrains\PyCharm 3.1\helpers\pydev\pydevd.py", line 996, in trace_dispatch if not t.isAlive(): File "C:\Python34\lib\threading.py", line 1120, in is_alive self._wait_for_tstate_lock(False) File "C:\Python34\lib\threading.py", line 1076, in _wait_for_tstate_lock assert self._is_stopped AssertionError Traceback (most recent call last): File "C:\Program Files (x86)\JetBrains\PyCharm 3.1\helpers\pydev\pydevd.py", line 996, in trace_dispatch if not t.isAlive(): File "C:\Python34\lib\threading.py", line 1120, in is_alive self._wait_for_tstate_lock(False) File "C:\Python34\lib\threading.py", line 1076, in _wait_for_tstate_lock assert self._is_stopped AssertionError Traceback (most recent call last): File "C:\Program Files (x86)\JetBrains\PyCharm 3.1\helpers\pydev\pydevd.py", line 996, in trace_dispatch if not t.isAlive(): File "C:\Python34\lib\threading.py", line 1120, in is_alive self._wait_for_tstate_lock(False) File "C:\Python34\lib\threading.py", line 1076, in _wait_for_tstate_lock assert self._is_stopped AssertionError Traceback (most recent call last): File "C:\Program Files (x86)\JetBrains\PyCharm 3.1\helpers\pydev\pydevd.py", line 996, in trace_dispatch if not t.isAlive(): File "C:\Python34\lib\threading.py", line 1120, in is_alive self._wait_for_tstate_lock(False) File "C:\Python34\lib\threading.py", line 1076, in _wait_for_tstate_lock assert self._is_stopped AssertionError Process finished with exit code -1 

- Change -

In the end, I deleted the .py file and recreated the code in a new file, after which the debugger worked correctly. I'm not sure what corrupts these files, but I noticed that this happened several times. AssertionError was one of those times. Another time, the .py file is corrupted, and the interpreter throws an exception that I did not define for the encoding style to support unicode char, although I had

 # -*- coding: utf-8 -*- 

What surprised me, even after deleting all the code (including # - encoding: utf-8 -) and basically calling the simple print () function, it would still continue to throw an error! Then I again completely deleted the file and started from scratch. I was shocked, I have no idea how this happened.

+6
source share
2 answers

I am encountering this problem using PyCharm 3.1.1 and Python 3.4.0 on Windows .

This is a bug ( http://youtrack.jetbrains.com/issue/PY-12317 ), which is marked as "Fixed in 3.1.2".

Thus, I load PyCharm 3.1.2RC2 (build 133.1143) into the JetBrains PyCharm Preview (EAP) page . And this version solved this problem.

+5
source

I had the same problem with my Mac version, and http://download.jetbrains.com/python/pycharm-community-133.1262.dmg resolved it

0
source

All Articles