Home  >  Article  >  Backend Development  >  What should I do if python’s idle cannot be opened?

What should I do if python’s idle cannot be opened?

coldplay.xixi
coldplay.xixiOriginal
2020-10-29 09:54:0835237browse

Solution for python's idle cannot be opened: 1. Find [idle.bat] in the [D:\Users\Python37\Lib\idlelib] directory and double-click to open it; 2. In the user folder of the c drive Find the [.idlerc] folder and delete the files inside.

What should I do if python’s idle cannot be opened?

Solution to python's idle cannot be opened:

1. In D:\Users\Python37\Lib Find idle.bat in the \idlelib directory, double-click to open

2. For conflicts between python2 and python3, refer to the solutions given online and find the .idlerc file in the user folder of the c drive folder, delete the files inside or enter "%USERPROFILE%.idlerc" under win r to delete it

3. Reinstall and repair python, find the installation package, and select repair

4. The above three points None of them work. Like the problem I encountered, first use cmd to locate the py file, and then manually test python xx.py. If no error is reported when running, it means that the interpreter is normal. Next, locate the python installation folder. The idle.py file, for example, mine is "D:\Users\Python37\Lib\idlelib". After cmd is run,

What should I do if python’s idle cannot be opened?

pops up and you can see the autocomplete.py file. There is an error in importing the package

Open autocomplete.py, delete import urllib2, run cmd again, python idle.py, the same way

What should I do if python’s idle cannot be opened?

Just delete it in the same way , after deletion, you can open .py with the built-in idle. As for the reason, the auto-complete function was manually added before.

Related free learning recommendations: python video tutorial

The above is the detailed content of What should I do if python’s idle cannot be opened?. For more information, please follow other related articles on the PHP Chinese website!

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn