5

enter image description here

I configured python 3.6 in JetBrains initially but uninstalled it today since it reached end-of-life. I installed version 3.10 but I keep getting the error that "Python 3.1 has reached end of date."

Clicking on 'Configure Python Interpreter'>Project Settings>Modules>Dependencies>Python 3.10 doesn't solve the problem.enter image description here

Using File->settings and searching for interpreter shows only this option enter image description here. Used "Use SDK of module" and "specified Python Interpreter" options but the error persists. I can't find any other resolution on the JetBrains support page for this. Thank you for your help!

  • I tried removing all existing configuration SDK from File | Project Structure | Platform Settings | SDKs and adding Python 3.10 again.
  • A screenshot of the interpreter configured in an existing virtual environment is attached here. enter image description here
  • When I click ok, I get this error.enter image description here
  • I figured this may be since my venv was initially configured in the 3.6 version but I'm not able to configure a new venv with Python 3.10. (The Ok option is greyed out) enter image description here While trying to add venv manually using /venv or /venv2, I get the error- 'Specified path cannot be found' enter image description here

4 Answers4

2

I installed version 3.10

Did you get it from python.org?

Please go to Platform settings | SDKs and delete all existing SDKs configurations. After that, please click the + sign and add a new Python SDK. Please attach a screenshot of the new interpreter configuration you set.

  • I tried this, but I'm unable to save the interpreter configuration in a new virtual environment while the existing one that was setup in Python 3.6 throws up an error. I only have Python 3.10 in my device now. I installed the setup from Python.org – Sruthi Gopalakrishnan Feb 02 '22 at 19:30
  • 1
    Could you please add the \venv or \venv2 to the location field to the path which is already set there? Will it help? (the last screenshot) – Antonina Belianskaya Feb 03 '22 at 11:57
  • I tried that. I get the error- "Specified path not found" for \venv and \venv2. I can't save the path. – Sruthi Gopalakrishnan Feb 04 '22 at 13:01
  • It seems like you change a path to the "Base interpreter" field, but it should point to python.exe - no need to change anything there. Please add the path to the "Location" field. – Antonina Belianskaya Feb 04 '22 at 14:08
2

I had the same problem with IDEA 2019.3, but my version was python 3.11.1. So, I am download more older version Python 3.9.13, set up it as new project SDK and it fixed the problem!

It looks like a bug in IDEA - it match vesion py as ^([0-9]+.[0-9]{1}).*$ So, version 3.11.1 it defined as version 3.1 :-)

1

I had the same problem. My solution: delete Pycharm and install it again (maybe export your settings): https://www.jetbrains.com/pycharm/download/#section=windows

Fixed the problem for me.

0

Refer to PyCharm doesn't recognize Python 3.10, how do I configure it?

You are likely using an old PyCharm version. Python 3.10 is rather new. Update PyCharm to at least 2020.2. See the relevant ticket in PyCharm's bug tracker https://youtrack.jetbrains.com/issue/PY-42855.

Thanks to Pavel Karateev

Rod D
  • 57
  • 1
  • 2