libtmux is picking up the wrong tmux version
Nadie ha tomado este issue todavía.
Evaluación
- Dificultad
- 3/5
- Tiempo estimado
- 1-2 días
- Aptitud para principiantes
- 45/100
Línea de trabajo
Read libtmux/common.py around line 241 and the linked tmuxp report first; inspect how which combines default_paths with append_env_path. Done means the selected tmux executable follows the user's intended environment path rather than /usr/bin/tmux, addressing the reported protocol mismatch.
Escrito por el modelo de indexación a partir del texto del issue.
Descripción
See: https://github.com/tmux-python/tmuxp/issues/794
Started new server, protocol mismatch. tmuxp seems to be using /usr/bin/tmux instead of what I have aliased.
$ tmux -V
tmux.orig 2.8
$ /usr/bin/tmux -V
tmux 1.8
The problem for me is https://github.com/tmux-python/libtmux/blob/master/libtmux/common.py#L241
Your search paths are then placing the system paths AFTER the custom patch which tmux pulls up:
241 def __init__(self, *args: t.Any, **kwargs: t.Any) -> None:
242 tmux_bin = which(
243 "tmux",
244 default_paths=kwargs.get(
245 "tmux_search_paths",
246 ["/bin", "/sbin", "/usr/bin", "/usr/sbin", "/usr/local/bin"],
247 ),
248 append_env_path=kwargs.get("append_env_path", True),
249 )
This really should be the other way around.
$ which tmux
tmux=/apollo/env/envImprovement/bin/tmux
I'd hate to have to fork this, so can we just perform a subprocess.run which tmux instead? Why do we need to search paths?
tmuxp:
-------------------------
environment:
dist: Linux-5.4.204-124.362.amzn2int.x86_64-x86_64-with-glibc2.2.5
arch: x86_64
uname: Linux; dev-dsk-deguzim-1a-fa82568b.us-east-1.amazon.com; 5.4.204-124.362.amzn2int.x86_64
version: #1 SMP Wed Jul 13 03:24:31 UTC 2022
-------------------------
tmux version: 1.8
libtmux version: 0.12.0
tmuxp version: 1.12.1
tmux path: /usr/bin/tmux
tmuxp path: /home/deguzim/.local/lib/python3.7/site-packages/tmuxp
shell: /bin/zsh
-------------------------
tmux sessions:
protocol version mismatch (client 7, server 8)
tmux windows:
protocol version mismatch (client 7, server 8)
tmux panes:
protocol version mismatch (client 7, server 8)
tmux global options:
protocol version mismatch (client 7, server 8)
tmux window options:
protocol version mismatch (client 7, server 8)
- Lenguaje dominante
- Python
- Estrellas
- 1.2k
- Forks
- 127
- Merge medio
- 2 h 13 min
- PR fusionados (30 d)
- 1
Guía de contribución
Primeros pasos
- Lee el issue completo y luego la guía de contribución del proyecto.
- Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
- Haz un fork del repositorio y trabaja en una rama.
- Abre un pull request que haga referencia al número del issue.
Más de tmux-python/libtmux
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 88/100
tmux-python/libtmux#759 ·
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 68/100
tmux-python/libtmux#745 · 2 comentarios ·
-
enhancement
Dificultad 2/5 1-3 horas Aptitud para principiantes 72/100
tmux-python/libtmux#744 ·
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 78/100
tmux-python/libtmux#731 ·
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 68/100
tmux-python/libtmux#654 ·
Todos los issues de tmux-python/libtmux
Issues similares
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 75/100
anthropics/skills#1811 · 1 comentario ·
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 75/100
speaches-ai/speaches#678 ·
-
bug
Dificultad 2/5 1-3 horas Aptitud para principiantes 75/100
datalayer/mcp-compose#42 ·
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 75/100
conda-forge/spacy-feedstock#177 ·
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 70/100
UKGovernmentBEIS/inspect_evals#2523 ·