I broke poetry and have no idea how to reinstall it

$ poetry <any command/-v/-h/etc>
/home/qwerty/.local/share/pypoetry/venv/bin/python: error while loading shared libraries: libpython3.10.so.1.0: cannot open shared object file: No such file or directory

I suppose it happens because i have python 3.11.6 version, while poetry wants libpython3.10. So i tried to reinstall poetry, but unfortunately… i have no idea how it was installed.

pip freeze gives no positive result, pacman -Qqe as well…

So, how to fix my poetry?

P.S. poetry self update not working

Hi @gamer_girl_2007_nah,

Please provide the output for:

pamac search --installed poetry


pamac search --installed python | grep --ignore-case 'poetry'

both empty

If both return empty, then you didn’t install it with pamac. Please post the output of:

pip list


pipenv lock -r


conda list


ls -l ~/.local/share/pypoetry
pamac reinstall python-poetry


It is a virtual environment, which hasn’t been updated.

python -m venv --upgrade /home/qwerty/.local/share/pypoetry/venv
1 Like

Won’t work as it’s not installed with pamac:

Package             Version
------------------- ------------
anytree             2.12.1
apparmor            3.1.6
application-utility 1.3.2
attrs               23.1.0
beautifulsoup4      4.12.2
btrfsutil           6.6.2
certifi             2023.11.17
cffi                1.16.0
chardet             5.2.0
charset-normalizer  3.3.2
cryptography        41.0.7
dbus-python         1.3.2
distro              1.8.0
docutils            0.20.1
idna                3.4
lensfun             0.3.4
LibAppArmor         3.1.6
lit                 16.0.6.dev0
lxml                4.9.2
Mako                1.2.4
mallard-ducktype    1.0.2
manjaro-sdk         0.1.1
Markdown            3.5.1
MarkupSafe          2.1.3
meson               1.3.0
moddb               0.10.0
netsnmp-python      1.0a1
nftables            0.1
npyscreen           4.10.5
packaging           23.2
pacman_mirrors      4.24.0
pexpect             4.8.0
Pillow              10.1.0
pip                 23.3.1
ply                 3.11
psutil              5.9.6
ptyprocess          0.7.0
pybind11            2.11.1
pycairo             1.25.1
pycparser           2.21
Pygments            2.17.2
PyGObject           3.46.0
pyinotify           0.9.6
pyparsing           3.1.1
PyQt5               5.15.10
PyQt5-sip           12.13.0
pyrate-limiter      3.1.0
PySide6             6.6.1
python-pam          2.0.2
pytz                2023.3.post1
PyYAML              6.0.1
requests            2.31.0
setproctitle        1.3.3
shiboken6           6.6.1
shiboken6-generator 6.6.1
six                 1.16.0
soupsieve           2.5
systemd-python      235
TBB                 0.2
tinycss2            1.2.1
toolz               0.12.0
tqdm                4.66.1
typing_extensions   4.9.0
urllib3             1.26.18
vboxapi             1.0
webencodings        0.5.1
wheel               0.40.0

dont use pipenv or conda

Unable to symlink '/usr/bin/python' to '/home/qwerty/.local/share/pypoetry/venv/bin/python'

now its

$ poetry

Traceback (most recent call last):
  File "/home/qwerty/.local/bin/poetry", line 5, in <module>
    from poetry.console.application import main
ModuleNotFoundError: No module named 'poetry'

No idea then, how you installed it. But a folder venv indicates that python-venv was used.

I’m now thinking:

pipx install poetry


Note: I have no idea if this will work or if it’ll beak something, so do at your own risk.

-bash: pipx: command not found

i really have no clue how my poetry was installed

perhaps i need a solution how to delete it now…
to reinstall properly

That’s actually what I was also thinking…

What is the output of

which poetry
1 Like


OK. I think delete it:

mv /home/qwerty/.local/bin/poetry /home/qwerty/.local/bin/poetry.backup

And then reinstall it, properly this time:

pamac install python-poetry

…and hope for good news.

1 Like

Yay! Now its working, thanks :slight_smile:


Then you can safely remove the backed up file:

rm /home/qwerty/.local/bin/poetry.backup

I’m glad it worked. Next time, be more careful of how you do something.

1 Like

This topic was automatically closed 3 hours after the last reply. New replies are no longer allowed.