Categories
Python

How to fix PyCharm AttributeError: ‘NoneType’ object has no attribute ‘get’

When you run or debug a Python script in PyCharm, it shows the following error about encoding… How can I fix it?

Pycharm How to fix PyCharm AttributeError NoneType object has no attribute get
/usr/bin/python /snap/pycharm-professional/218/plugins/python/helpers/pydev/pydevconsole.py --mode=client --port=37281
Traceback (most recent call last):
File "/usr/lib/python2.7/encodings/init.py", line 74, in search_function
entry = _cache.get(encoding, _unknown)
AttributeError: 'NoneType' object has no attribute 'get'

Process finished with exit code 1

3 steps to fix scripts not running error in PyCharm

Estimate Cost : 0

Time Needed : 2 minutes

  1. Go to the “File” menu to open “Settings” window

    pycharm file settings

  2. Go to “Tools” and then “Python Scientific”

    uncheck show plots in tool window

  3. Uncheck “Show plots in tool window”

    uncheck show plots in tool window

Tools
  • PyCharm
Materials
  • Python scripts

What is PyCharm?

PyCharm is an integrated development environment ( IDE) used, primarily for the Python language, in computer programming. It is being developed by the Czech JetBrains company. It offers code analysis, a graphical debugger, an integrated unit tester, version control systems (VCSes) integration, and supports Django web creation, as well as Anaconda data science.

PyCharm is cross-platform, with versions for Windows , MacOS and Linux. The Community version is licenced under the Apache License and, under a proprietary license, there is also a Professional Edition with extra features.

+1

By VarHowto Editor

Welcome to VarHowto!