Setup in virtualenv: `pip install -e.` vs` python setup.py install`

I follow the Flask tutorial in which I use virtualenv, and with it I created an application directory tree that looks like this:

app/
|__app/
|__app.egg-inf/
|__setup.py
|__venv/

Inside my venvtutorial will tell me to run pip install -e ., which seems to be using mine setup.pyto install dependencies and my application.

Why does the textbook have me working pip install -e .? Why not python setup.py install? What are the differences?

(FWIW, export FLASK_APP=app; flask runworks fine after pip install -e ., but doesn't work after python setup.py install)

+4
source share
1 answer

-, , python setup.py install . pip <-> python setup.py :

Editable   pip                    setup.py
yes        pip install -e .       python setup.py develop    
no         pip install .          python setup.py install    

, pip :

, , , pip, python setup.py install.

+4

Source: https://habr.com/ru/post/1682701/


All Articles