Why is not recommended to install poetry with homebrew?
Question:
Poetry official documentation strictly recommends sticking with the official installer. However, homebrew has poetry formulae.
brew install poetry
Usually, I like to keep everything I can in homebrew to manage installations easily.
What is the drawback and risks of installing poetry using homebrew instead of the recommended installation script?
Answers:
The drawback is that poetry
will be unable to upgrade itself (I’ve no idea what’d actually happen), and you’ll not be able to install specific poetry versions. Homebrew installed poetry will probably also depend on Homebrew-installed Python, etc, instead of having its own isolated venv
to execute from.
If you use homebrew to install poetry, don’t try to manage that installation any way outside of homebrew. Otherwise, it’s probably fine.
On top of what Kache said, homebrew poetry formula is actually built with the specific python version ([email protected]) in the virtualenv manner.
IMO, there are two reasons why there is poetry formula:
- it is required by other formula (like dooit) to do the build
- homebrew user would manage the tools in the consistent way (via brew bundle)
You can use Homebrew while sticking to officially recommended installation methods with one extra step.
-
The pipx project officially supports Homebrew installation:
brew install pipx
pipx ensurepath
-
pipx
is an officially supported way of installing poetry:
pipx install poetry
Poetry official documentation strictly recommends sticking with the official installer. However, homebrew has poetry formulae.
brew install poetry
Usually, I like to keep everything I can in homebrew to manage installations easily.
What is the drawback and risks of installing poetry using homebrew instead of the recommended installation script?
The drawback is that poetry
will be unable to upgrade itself (I’ve no idea what’d actually happen), and you’ll not be able to install specific poetry versions. Homebrew installed poetry will probably also depend on Homebrew-installed Python, etc, instead of having its own isolated venv
to execute from.
If you use homebrew to install poetry, don’t try to manage that installation any way outside of homebrew. Otherwise, it’s probably fine.
On top of what Kache said, homebrew poetry formula is actually built with the specific python version ([email protected]) in the virtualenv manner.
IMO, there are two reasons why there is poetry formula:
- it is required by other formula (like dooit) to do the build
- homebrew user would manage the tools in the consistent way (via brew bundle)
You can use Homebrew while sticking to officially recommended installation methods with one extra step.
-
The pipx project officially supports Homebrew installation:
brew install pipx pipx ensurepath
-
pipx
is an officially supported way of installing poetry:pipx install poetry