Utilizo pip / pipx para instalar herramientas de Python. Si hago eso en el host, la herramienta no funciona en la caja de herramientas. Si la instalo en la caja de herramientas, la herramienta no funciona en el host:
$ pipx install jrnl
Installing to existing venv 'jrnl'
installed package jrnl 2.7.1, Python 3.9.5
These apps are now globally available
- jrnl
done! ✨ 🌟 ✨
$ jrnl --version
jrnl version v2.7.1
[..]
$ toolbox enter --container fedora-toolbox-32
$ jrnl
Traceback (most recent call last):
File "/var/home/hferreiro/.local/bin/jrnl", line 5, in <module>
from jrnl.cli import cli
ImportError: No module named jrnl.cli
Siguiendo el mismo ejemplo en el sitio web de pipx:
[oliver<strong i="6">@t480s</strong> src]$ pipx install cowsay
installed package cowsay 4.0, Python 3.9.5
These apps are now globally available
- cowsay
done! ✨ 🌟 ✨
[oliver<strong i="7">@t480s</strong> src]$ cowsay Yeah
____
| Yeah |
====
\
\
^__^
(oo)\_______
(__)\ )\/\
||----w |
|| ||
[oliver<strong i="8">@t480s</strong> src]$ ./toolbox enter f34
⬢[oliver<strong i="9">@toolbox</strong> src]$ cowsay moo
___
| moo |
===
\
\
^__^
(oo)\_______
(__)\ )\/\
||----w |
|| ||
⬢[oliver<strong i="10">@toolbox</strong> src]$
Funcionó con la última versión de la caja de herramientas.
¿Quizás es un problema con jrnl? (Lo probaré también)
Probado con jrnl y funcionó OOB
[oliver<strong i="6">@t480s</strong> src]$ pipx install jrnl
installed package jrnl 2.8.1, Python 3.9.5
These apps are now globally available
- jrnl
done! ✨ 🌟 ✨
[oliver<strong i="7">@t480s</strong> src]$ ./toolbox enter f34
⬢[oliver<strong i="8">@toolbox</strong> src]$
logout
[oliver<strong i="9">@t480s</strong> src]$ jrnl --version
jrnl version v2.8.1
Copyright (C) 2012-2021 jrnl contributors
This is free software, and you are welcome to redistribute it under certain
conditions; for details, see: https://www.gnu.org/licenses/gpl-3.0.html
[oliver<strong i="10">@t480s</strong> src]$ ./toolbox enter f34
⬢[oliver<strong i="11">@toolbox</strong> src]$ jrnl --version
jrnl version v2.8.1
Copyright (C) 2012-2021 jrnl contributors
This is free software, and you are welcome to redistribute it under certain
conditions; for details, see: https://www.gnu.org/licenses/gpl-3.0.html
⬢[oliver<strong i="12">@toolbox</strong> src]$
Esta línea también podría ser importante:
Installing to existing venv 'jrnl'
Encontré el problema. Mi caja de herramientas está en Fedora 32, que por defecto es python2. Usar una caja de herramientas de Fedora 34 no tiene problemas.
Comentario más útil
Encontré el problema. Mi caja de herramientas está en Fedora 32, que por defecto es python2. Usar una caja de herramientas de Fedora 34 no tiene problemas.