Python

I don’t have any issues with Python’s packaging ecosystem anymore, having settled comfortably into a pyenv+virtualenv+pip-tools as my “stack” after going around the block a few times.

But even so, I must recognise how awful the experience is for new users. It’s taken me years to settle into this system, and it can take half a day to get someone up to speed with these tools if they haven’t used them. - HN

caption

PyEnv / VirtualEnv

The pyenv project was forked from rbenv and ruby-build, and modified for Python. - Is there a Python alternative to RVM or Rbenv?

pyenv - allows to work with different python version
virtualenv - for same python version, allows tu use different set of installed library. ex: virtualenv -p python3 py-opencv pyenv-virtualenv - is a plugin for pyenv by the same author as pyenv, to allow you to use pyenv and virtualenv at the same time conveniently.

virtualenv

create with virtualenv -p python3 mytest
activate with source mytest/bin/activate

see also

Conda - see HN comment

Don’t need sudo right to use it.

  • Installing on Linux - Anaconda vs. miniconda - Choose Anaconda if you are new to conda or Python - Choose Miniconda if you Just want fast access to Python and the conda commands, and wish to sort out the other programs later

Fish shell support

Run ‘conda init fish’ and restart your shell.

Written on July 18, 2020, Last update on January 2, 2024
python lang fish