Installation and dependencies
===================================

Kedro's installation
--------------------------

- `kedro --version` : FIXME
- kedro compatible python version : you can opt for a different version of Python, any version >= 3.7 and <3.11

pyenv
---------

pyenv dependencies::

    apt-get install -y make build-essential libssl-dev zlib1g-dev libbz2-dev libreadline-dev libsqlite3-dev wget curl llvm libncurses5-dev libncursesw5-dev xz-utils tk-dev libffi-dev liblzma-dev python3-openssl

install pyenv using the builtin installer :

    curl https://pyenv.run | bash

then add to your `.bashrc`::

    # pyenv
    export PYENV_ROOT="$HOME/.pyenv"
    command -v pyenv >/dev/null || export PATH="$PYENV_ROOT/bin:$PATH"
    eval "$(pyenv init -)"
    eval "$(pyenv virtualenv-init -)"

List the available python `3.10` versions with::

      pyenv install --list | grep " 3\.[10]"
      3.10.0
      3.10-dev
      3.10.1
      3.10.2
      3.10.3
      3.10.4
      3.10.5
      3.10.6
      3.10.7
      3.10.8
      3.10.9
      3.10.10
      3.10.11
      3.10.12

Then install the latest `3.10` version like this::

    pyenv install -v 3.10.12
    /tmp/python-build.20230820080849.75484 ~
    Downloading Python-3.10.12.tar.xz...
    -> https://www.python.org/ftp/python/3.10.12/Python-3.10.12.tar.xz
    ...
    Successfully installed pip-23.0.1 setuptools-65.5.0
    Installed Python-3.10.12 to /home/gwen/.pyenv/versions/3.10.12

Verify the installation::

    pyenv versions
    * system
      3.10.12

virtual environments list::

    pyenv virtualenvs

pyenv local (in a folder) activation::

    datascience (develop %=) $ pyenv local 3.10.12
    datascience (develop %=) $ python
    Python 3.10.12 (main, Aug 20 2023, 08:14:29) [GCC 12.2.0] on linux
    Type "help", "copyright", "credits" or "license" for more information.
    >>>

virtualenv creation::

    datascience (develop %=) $ python -m venv .venv


pipenv and pdm
----------------

::

    apt search pipenv
    En train de trier... Fait
    Recherche en texte intégral... Fait
    pipenv/stable 2022.12.19+ds-1 all
    Python package manager based on virtualenv and Pipfiles

    python3-pdm/stable 2.2.1+ds1-1 all
    next generation Python package management tool

