snstuff
snstuff

Reputation: 319

Cannot debug the code in PyCharm 2020.1 - Python 3.5 EOL bug

I am getting the following error whenever I try to debug any code. Running the code works fine though. I have tried few suggestions from the forums, with no luck.

Traceback (most recent call last):
  File "C:\Program Files\JetBrains\PyCharm Community Edition 2020.1\plugins\python-ce\helpers\pydev\pydevd.py", line 39, in <module>
    from _pydevd_bundle.pydevd_comm import CMD_SET_BREAK, CMD_SET_NEXT_STATEMENT, CMD_STEP_INTO, CMD_STEP_OVER, \
  File "C:\Program Files\JetBrains\PyCharm Community Edition 2020.1\plugins\python-ce\helpers\pydev\_pydevd_bundle\pydevd_comm.py", line 96, in <module>
    from _pydevd_bundle import pydevd_bytecode_utils
  File "C:\Program Files\JetBrains\PyCharm Community Edition 2020.1\plugins\python-ce\helpers\pydev\_pydevd_bundle\pydevd_bytecode_utils.py", line 105, in <module>
    _unpack_opargs = dis._unpack_opargs
AttributeError: module 'dis' has no attribute '_unpack_opargs'

Upvotes: 0

Views: 327

Answers (1)

DeepSpace
DeepSpace

Reputation: 81624

Python 3.5 has reached EOL. As such, PyCharm 20.1 (and newer, most likely) apparently does not fully support it. See PyCharm issue PY-41642.

Edit: Actually, it appears that PyCharm 20.1.1 included the fix for it, so actually try a newer version first (ctrlf the page for PY-41642).

You have 3 options (ordered from best to worst):

  • Upgrade to a newer Python version
  • Install an older version of PyCharm
  • Use the workaround suggested at the above link by manually editing PyCharm files

Upvotes: 1

Related Questions