Open tusharsadhwani opened 1 week ago
virtualenv
is infact just caching the pip
wheel's contents in a directory.
$ cd /Users/tusharsadhwani/Library/Application\ Support/virtualenv
$ ls
py_info wheel
$ ls wheel/3.12/image/1/CopyPipInstall/pip-24.0-py3-none-any/pip/
__init__.py __pip-runner__.py _vendor
__main__.py _internal py.typed
I don't like it when venv creation takes 2 seconds. Especially since I know it can be faster.
virtualenv
would be the prime example, which is super fast by default.I added
microvenv
which was super simple, but the problem withmicrovenv
is that we have to runpython -m ensurepip
after which is really slow.I looked at
micropip
from pyodide, andinstaller
from pypa, and both don't fit our usecase.So realistically, I'll have to figure out how virutalenv does it this fast. I have my ideas, such as it may just be copying or symlinking some stuff to get pip.