Opened 5 years ago
Last modified 7 months ago
#59930 assigned defect
Byobu attempts to load system Python3
Reported by: | jenstroeger (Jens Troeger) | Owned by: | l2dy (Zero King) |
---|---|---|---|
Priority: | Normal | Milestone: | |
Component: | ports | Version: | 2.6.2 |
Keywords: | Cc: | ||
Port: | byobu |
Description
I’ve installed byobu to play around with it, but receive the following error:
> byobu /opt/local/bin/byobu-select-session: /opt/local/lib/byobu/include/select-session.py: /usr/bin/python3: bad interpreter: No such file or directory /opt/local/bin/byobu-select-session: line 24: /opt/local/lib/byobu/include/select-session.py: Undefined error: 0
Looks like it tries to run the system’s Python3 interpreter (which ships only with 2.7) instead of MacPorts’ interpreter.
Change History (6)
comment:1 Changed 5 years ago by jenstroeger (Jens Troeger)
comment:2 Changed 5 years ago by reneeotten (Renee Otten)
Milestone: | MacPorts 2.7.0 |
---|---|
Owner: | set to l2dy |
Status: | new → assigned |
comment:3 follow-ups: 5 6 Changed 5 years ago by l2dy (Zero King)
The libnewt port with python support compiled is required for the python part of byobu to function. But this port is built --without-python
. So even if byobu properly loads Python from MacPorts, it would not have the required module.
byobu-5.130/usr/lib/byobu/include/constants # Find a suitable python interpreter, if undefined if [ -z "$BYOBU_PYTHON" ]; then if python3 -c "import snack" >/dev/null 2>&1; then export BYOBU_PYTHON="python3" elif python2 -c "import snack" >/dev/null 2>&1; then export BYOBU_PYTHON="python2" elif python -c "import snack" >/dev/null 2>&1; then export BYOBU_PYTHON="python" fi fi
We need to package py-newt
first.
comment:5 Changed 7 months ago by ryandesign (Ryan Carsten Schmidt)
Replying to l2dy:
We need to package
py-newt
first.
But calling libnewt's python modules py-newt would be wrong. That name should be reserved for the unrelated package at https://pypi.org/project/newt/
comment:6 Changed 7 months ago by ryandesign (Ryan Carsten Schmidt)
Replying to l2dy:
We need to package
py-newt
first.
This is now done; it's called py312-libnewt, etc.
Addendum:
and changing the first line to
worked.