skip to Main Content

I recently ported into the linux os , any time I try to create a new flask project or any other project it doesn’t install the package but it shows ‘failed to create interpreter’ .
Although I can manually set the interpreter up,but I would like a smoother workflow. My guess is that the problem should not be from pycharm but rather how ubuntu is configured.

The version of the pycharm pro is pycharm-2022.1.2
Python version is 3.10.2.
Ubuntu version is 22.04 LTS .

enter image description here

2

Answers


  1. Chosen as BEST ANSWER

    sudo apt install python3-distutils fixed it.


  2. This problem can be caused by a bad installation of Pycharm or an absence of the Java package. If you are using the version of Pycharm provided on the JetBrains website, this behavior is normal and I advise you to install Pycharm via snap. To do so, execute the following command in your terminal:

    sudo snap install pycharm-professional --classic
    

    If you have installed Pycharm this way, this error may come from your Java version. At this moment type this command in your terminal:

    sudo apt install default-jre 
    

    If none of this worked, uninstall Pycharm: sudo snap remove pycharm-professional. Then reinstall it.

    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search