Score:0

Poetry installation fails on Ubuntu

br flag

I am trying to install poetry the recommended way on Ubuntu 20.04.3 LTS:

curl -sSL https://raw.githubusercontent.com/python-poetry/poetry/master/get-poetry.py | python -

When I do so, it says:

content.com/python-poetry/poetry/master/get-poetry.py | python -

Command 'python' not found, did you mean:

  command 'python3' from deb python3
  command 'python' from deb python-is-python3

curl: (23) Failed writing body (485 != 1378)

Then I try python3

curl -sSL https://raw.githubusercontent.com/python-poetry/poetry/master/get-poetry.py | python3 -

The installation succeeds.

Afterwards when calling poetry --version to test the installation, I get:

poetry: command not found

Although I added poetry to PATH manually, in .bash_profile:

PATH=$PATH:~/poetry/bin

I also tried adding poetry to path in .bashrc similarly to this answer:

export PATH="~/poetry/bin:$PATH"
pLumo avatar
in flag
you add `PATH=$PATH:~/poetry/bin` to path, but the path is `~/.poetry/bin`!
br flag
Thanks @pLumo, that worked. What a useless question I asked.
us flag
@pLumo Consider writing it as an answer.
Score:0
in flag

You add ~/poetry/bin to PATH, but it should be ~/.poetry/bin.


Regarding python is not available, you can (re)install python-is-python3 package via apt:

sudo apt install python-is-python3
N0rbert avatar
zw flag
"add a symlink manually" will be out of the APT control. Suggesting to remove this recommendation from answer.
mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.