Hacker News new | ask | show | jobs
by ausjke 2417 days ago

    python -m venv venv
    source venv/bin/activate
    pip install -U pip
    pip install whatever
    # <do you stuff here>
    deactivate
no need any third-party tools, venv is built-in the above steps always worked for me out of the box.
2 comments

But how about replacing all of these commands with two words? poetry install
which is another layer of abstraction and dependency that I do not really need, e.g poetry no longer maintained, poetry(or whatever) has an urgent bugfix,etc
Do you not consider pip third-party? It does not come with the standard Python distribution. Although `ensurepip` does.
No, pip has been available in standard Python distributions since 3.4.[1] Distributions that don't come with pip (e.g. some Linux distro packages) are non-standard.

[1] https://docs.python.org/3/whatsnew/3.4.html#whatsnew-pep-453