Backend: Пакетный менеджер Python - PDM

Установка

Linux/Mac

curl -sSL https://raw.githubusercontent.com/pdm-project/pdm/main/install-pdm.py | python3 -

или:

brew install pdm

или:

pipx install pdm

Windows

(Invoke-WebRequest -Uri https://raw.githubusercontent.com/pdm-project/pdm/main/install-pdm.py -UseBasicParsing).Content | python -

Использование

Настройка, чтобы не использовать виртуальную среду:

pdm config python.use_venv false

Установка зависемостей из pyproject.toml:

pdm sync

Добавление зависимостей:

pdm add numpy

Добавление тестовых зависимостей:

pdm add -dG test pytest

Интеграция с IDE

PyCharm

Mark __pypackages__/3.10/lib as Sources Root. Then, select as Python interpreter a Python installation with the same 3.10 version.

Additionally, if you want to use tools from the environment (e.g. pytest), you have to add the __pypackages__/3.10/bin directory to the PATH variable in the corresponding run/debug configuration.