How to use PyEnv and Poetry together for your environment and package management for data science projects
I am not a massive fan of Anaconda. It’s an excellent tool for introducing you to the data science and Python ecosystem, but I find its installation too clunky and intrusive.
This is why I prefer to use PyEnv for Python management and Poetry for managing dependencies. This combo really works for me as they are both lightweight, reasonably small, and straightforward to understand technologies.
In this article, I want to give you a short tutorial on how to get started using PyEnv and Poetry for your projects!
Note: This walkthrough will be for MacOS and Unix users, but PyEnv and Poetry have guides for other operating systems.
What Is It?
So, what is PyEnv? It’s short for Python Environment and a tool that manages your Python versions. As the creators quote on their GitHub page:
pyenv lets you easily switch between multiple versions of Python. It’s simple, unobtrusive, and follows the UNIX tradition of single-purpose tools that do one thing well.