tmux cant find sessions when testing in docker
Nobody has claimed this yet.
Assessment
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Newbie friendliness
- 45/100
- Issue type
- Bug
- Clarity
- Mostly clear
- Activity status
- Stale
- Tech stack
- docker, python, ubuntu
- Domain
- cli, devops, testing-qa
Research direction
Start by running the supplied test_tmux.py and Dockerfile with ubuntu:18.04, then compare the result with python:3.7-slim. Trace the session creation and lookup failure around the reported session_id error, and verify the fix by making docker build complete successfully with the reproduction test.
Written by the indexing model from the issue text.
Description
Steps to reproduce:
test_tmux.py
import libtmux
import pytest
@pytest.fixture
def server():
server = libtmux.Server()
return server
def test_can_start_tmux_session(server):
server.new_session("test")
assert server.has_session("test")
server.kill_session("test")
Dockerfile:
FROM ubuntu:18.04
RUN apt-get update && apt install -y tmux python-pip
RUN pip install libtmux pytest
COPY test_tmux.py .
RUN pytest test_tmux.py
then docker build . fails with
if 'session_id' not in kwargs:
> raise ValueError('Session requires a `session_id`')
E ValueError: Session requires a `session_id`
Interestingly, replacing 'ubuntu:18.04' with 'python:3.7-slim' works. I thought this might mean it was an issue with the apt version of pip (which I know is dodgy), but adding a 'pip install --upgrade pip' didn't help.
- Dominant language
- Python
- Stars
- 1.2k
- Forks
- 127
- Avg merge
- 2h 13m
- Merged PRs (30d)
- 1
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from tmux-python/libtmux
-
Difficulty 2/5 1-3 hours Newbie friendliness 88/100
tmux-python/libtmux#759 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
tmux-python/libtmux#745 · 2 comments ·
-
enhancement
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
tmux-python/libtmux#744 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
tmux-python/libtmux#731 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
tmux-python/libtmux#654 ·
All issues in tmux-python/libtmux
Similar issues
-
🐛 Bug 🔔 Pending processing
Difficulty 2/5 1-3 hours Newbie friendliness 84/100
jumpserver/jumpserver#17584 ·
-
link-check link-check:sphinx-theme
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 65/100
qgis/QGIS-Documentation#11275 ·
-
bug priority:normal ready-for-dev
Difficulty 2/5 1-3 hours Newbie friendliness 88/100
OpenHands/extensions#626 · 1 comment ·
-
Difficulty 1/5 Under an hour Newbie friendliness 90/100
CSCfi/sd-search-api#39 ·