Home python In the project folder on Python, the __pycache __

In the project folder on Python, the __pycache __

Author

Date

Category

Good evening!
I can not understand where the folder __ Pycache __ appeared in the project on Python. What is this folder and how was it created?

P.S.: All Happy New Year !!!


Answer 1, Authority 100%

During the first import of the module, the source code is compiled into byte code (How Do I Create a .pyc file? ). __ pycache __ The folder contains a cache byte code (in *. PYC files) so as not to recompile each time the same code. Initially __ pycache __ folders introduced to more convenient to support several versions of the python interpreter (PEP 3147 ).

Programmers, Start Your Engines!

Why spend time searching for the correct question and then entering your answer when you can find it in a second? That's what CompuTicket is all about! Here you'll find thousands of questions and answers from hundreds of computer languages.

Recent questions