41

I'm trying to install packages in Pycharm for python3.5 interpreter. It says,

Python packaging tools not found. Install packaging tools.

But when I try to install, It gives this error.

AttributeError: module 'setuptools.dist' has no attribute 'check_specifier'

I'm using Ubuntu 16.04.2, Pycharm Community edition 2017.1.1

Goutham Ganesan
  • 907
  • 2
  • 8
  • 18

3 Answers3

67

Run this command and you should be able to install the packaging tools in Pycharm:

sudo apt install python3-pip

It's python3-pip, not python-pip if you are using the Python3 interpreter.

niklas
  • 786
  • 7
  • 4
  • Just installing python3-pip and executing pycharm by sudo did the trick. Thanks – Goutham Ganesan Apr 24 '17 at 15:00
  • I get the same error - and python3-pip is installed - what else might be missing ? – Tony Suffolk 66 May 23 '17 at 09:42
  • 14
    Any suggestions for windows? – varunsinghal Jun 25 '17 at 07:54
  • 1
    Thank you! +1. After that, I have encountered to another problem: AttributeError: module 'setuptools.dist' has no attribute 'check_specifier' and next solution found here: https://stackoverflow.com/questions/41141657/importerror-module-setuptools-dist-has-no-check-specifier-attribute I had to upgrade also my setuptools. Maybe for someone it will be helpful. – zviad Sep 02 '17 at 11:55
  • Removing all 'corrupted'(marked red) interpreters from the list in Pycharm helped me – MartinM Dec 14 '20 at 09:29
  • After running this and clicking 'Install packaging tools' again, PyCharm 2022.1.3 was smart enough to prompt for sudo password and then proceed with installing the rest. No need to launch PyCharm with sudo as @GouthamGanesan described. I'm guessing this was a PyCharm improvement. – Criminally Inane Jul 12 '22 at 05:58
1

I encountered this error when upgrading my Ubuntu to a newer version and it auto-installed an updated version of python and set it as the primary python version (3.8 --> 3.10).

I deleted the venv folder for the project and created a new one using the current python version (3.10) which seemed to resolve the problem.

Kevin King
  • 23
  • 7
0

When i open pycharm with python 3.8 interpreter '+' option is not clickable (additional packages)after typing sudo apt install python3-pip it works and '+' option is clickable .....so try it if you re facing same problem.