4
hinst
3y

Installation instruction for a program written in Python:

> pip install MyProgram

Ok but I do not have pip, so I install it... Oops, needs Python 3 but linux has Python 2 installed by default. I try to start the program; it crashes.,...

People using Python, are you serious??????????? 👏👏😳 So it is possible to install a program written in Python only if I f*ck around with Python versions? I have both 2 and 3 installed but how the hell do I know what version is used when I run pip? I set global alias python=python3 but it did not help. RIP.

Comments
  • 4
    one of the reasons I havent touched python code since forever, I got frustrated and removed all versions of python3 to get a fresh start, turns out my desktop environment runs on a specific version of python3,

    it was at that point I knew I fucked up
  • 3
    Meet my little friend, pyenv

    https://github.com/pyenv/pyenv
  • 4
    python3 -m pip install {whatever}
    python2 -m pip install {whatever}
  • 2
    Which linux install are you using that has python2 installed?
    Maybe... you should upgrade it?
  • 5
    Note that on some setups you need "pip3" for Python3 and not just "pip".

    That said if a current distro still has Python2 as default in 2021 you should go find an alternative. Python 3 exists since 2008, not even LTS versions go nearly that far back.
  • 0
    @deadlyRants If a "python" binary exists, it's usually Python 2 (for compatibility; except on Arch Linux).

    Ubuntu 16.x and 18.x, and Redhat 7 have Python 2 as the respective default.
  • 0
    🍿 while I watch you destroy your os' python making parts of your os no longer work.
  • 0
    sudo apt install python3-pip

    pip3 install MyProgram

    ggez
Add Comment