- Notifications
You must be signed in to change notification settings - Fork233
fix(tests): explicitly state the shell to use#844
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to ourterms of service andprivacy statement. We’ll occasionally send you account related emails.
Already on GitHub?Sign in to your account
base:master
Are you sure you want to change the base?
fix(tests): explicitly state the shell to use#844
Uh oh!
There was an error while loading.Please reload this page.
Conversation
codecovbot commentedNov 2, 2022 • edited
Loading Uh oh!
There was an error while loading.Please reload this page.
edited
Uh oh!
There was an error while loading.Please reload this page.
Codecov Report
@@ Coverage Diff @@## master #844 +/- ##======================================= Coverage 76.46% 76.46% ======================================= Files 24 24 Lines 1606 1606 Branches 362 362 ======================================= Hits 1228 1228 Misses 269 269 Partials 109 109 📣 We’re building smart automated test selection to slash your CI/CD build times.Learn more |
tony commentedNov 3, 2022 • edited
Loading Uh oh!
There was an error while loading.Please reload this page.
edited
Uh oh!
There was an error while loading.Please reload this page.
Perhaps it may be beneficial or necessary to set a Out of curiousity, without this, what error do you get? What distro / system are you running into an issue on? As for |
zappolowski commentedNov 3, 2022 • edited
Loading Uh oh!
There was an error while loading.Please reload this page.
edited
Uh oh!
There was an error while loading.Please reload this page.
I'm on Arch, but I think the issue is my (login) shell: Running (on current master): There are two issues with fish for me:
I think, |
Thank you! I will look closer during the weekend. I'd like to get arch / perhaps freebsd setup locally Perhaps |
tony commentedNov 5, 2022 • edited
Loading Uh oh!
There was an error while loading.Please reload this page.
edited
Uh oh!
There was an error while loading.Please reload this page.
@zappolowski On a fresh Arch installation, I initially got a similar error. I don't have fish. But I think it's due to not having It started working after installing a few packages / configurations. Likely since thearch package for tmuxp installs tmux. $sudo pacman -Qearch-install-scripts 27-1base 3-1dhcpcd 9.4.1-1diffutils 3.8-1git 2.38.1-2groff 1.22.4-7inetutils 2.3-1keychain 2.8.5-2logrotate 3.20.1-1make 4.3-3man-db 2.11.0-1man-pages 6.01-1nano 6.4-1netctl 1.28-1nodejs 19.0.1-1openresolv 3.12.0-1openssh 9.1p1-3python 3.10.8-3sudo 1.9.12-5sysfsutils 2.1.1-1texinfo 6.8-2vcspull 1.18.0-1vi 1:070224-6vim 9.0.0814-1which 2.21-5yarn 1.22.19-1 I created a second user: |
e800c99 tob1b3775Comparezappolowski commentedNov 5, 2022 • edited
Loading Uh oh!
There was an error while loading.Please reload this page.
edited
Uh oh!
There was an error while loading.Please reload this page.
As I've said the culprit is not Arch, but my login-shell, which is I've created two (hopefully) portable containers to verify this (TBH it was a bit of a PITA to figure out, why the tests failed as man pages were missing): If you have $ podman run --rm --volume$(pwd):/src:ro localhost/arch-bash-tmuxp-dev:latest$ podman run --rm --volume$(pwd):/src:ro localhost/arch-fish-tmuxp-dev:latest The first one should succeed, the second one should fail. Edit: Using the bash image I can locally run the test-suite without issues, which would be okay for me. It's up to you to decide whether it"s worth the effort of supporting "special" configurations like mine. Edit2: A note on running the containers. As |
tony commentedNov 5, 2022 • edited
Loading Uh oh!
There was an error while loading.Please reload this page.
edited
Uh oh!
There was an error while loading.Please reload this page.
This is the error I got with podman run --rm --interactive --tty --volume $(pwd):/src:rw localhost/arch-fish-tmuxp-dev:latestInstalling the current project: libtmux (0.15.9)============================================================================================================ test session starts ============================================================================================================collected 180 itemssrc/libtmux/pane.py .RRF [ 1%]src/libtmux/pytest_plugin.py .. [ 2%]src/libtmux/server.py .. [ 3%]src/libtmux/session.py . [ 3%]src/libtmux/test.py ...... [ 7%]src/libtmux/window.py .. [ 8%]tests/test_common.py .................... [ 19%]tests/test_pane.py ..... [ 22%]tests/test_pytest_plugin.py . [ 22%]tests/test_server.py ............ [ 29%]tests/test_session.py ......................... [ 43%]tests/test_test.py ..... [ 46%]tests/test_tmuxobject.py ..... [ 48%]tests/test_window.py ....................... [ 61%]docs/index.md ............. [ 68%]docs/quickstart.md ..................... [ 80%]docs/reference/properties.md ............. [ 87%]docs/topics/traversal.md ......... [ 92%]README.md ............. [100%]================================================================================================================= FAILURES ==================================================================================================================___________________________________________________________________________________________________ [doctest] libtmux.pane.Pane.send_keys ___________________________________________________________________________________________________150 .. versionchanged:: 0.14151152 Default changed from True to False.153 literal : bool, optional154 Send keys literally, default True.155156 Examples157 --------158 >>> pane = window.split_window(shell='sh')159 >>> pane.capture_pane()Expected: ['$']Got: ['sh-5.1$']/src/src/libtmux/pane.py:159: DocTestFailure============================================================================================================= warnings summary ==============================================================================================================../home/arch/.cache/pypoetry/virtualenvs/libtmux-VsnhxLU2-py3.10/lib/python3.10/site-packages/_pytest/cacheprovider.py:433 /home/arch/.cache/pypoetry/virtualenvs/libtmux-VsnhxLU2-py3.10/lib/python3.10/site-packages/_pytest/cacheprovider.py:433: PytestCacheWarning: cache could not write path /src/.pytest_cache/v/cache/nodeids config.cache.set("cache/nodeids", sorted(self.cached_nodeids))../home/arch/.cache/pypoetry/virtualenvs/libtmux-VsnhxLU2-py3.10/lib/python3.10/site-packages/_pytest/cacheprovider.py:387 /home/arch/.cache/pypoetry/virtualenvs/libtmux-VsnhxLU2-py3.10/lib/python3.10/site-packages/_pytest/cacheprovider.py:387: PytestCacheWarning: cache could not write path /src/.pytest_cache/v/cache/lastfailed config.cache.set("cache/lastfailed", self.lastfailed)../home/arch/.cache/pypoetry/virtualenvs/libtmux-VsnhxLU2-py3.10/lib/python3.10/site-packages/_pytest/stepwise.py:52 /home/arch/.cache/pypoetry/virtualenvs/libtmux-VsnhxLU2-py3.10/lib/python3.10/site-packages/_pytest/stepwise.py:52: PytestCacheWarning: cache could not write path /src/.pytest_cache/v/cache/stepwise session.config.cache.set(STEPWISE_CACHE_DIR, [])-- Docs: https://docs.pytest.org/en/stable/how-to/capture-warnings.html========================================================================================================== short test summary info ==========================================================================================================FAILED src/libtmux/pane.py::libtmux.pane.Pane.send_keys============================================================================================ 1 failed, 179 passed, 3 warnings, 2 rerun in 42.16s ============================================================================================ |
You've run the tests on But yeah, that error I also get on |
b1b3775 toe2b8600Compare
I removed If you're in the PR's branches checked out: git pull --rebase --autostash |
Those |
Do you have a list of which tests you issues with when you use |
zappolowski commentedNov 5, 2022 • edited
Loading Uh oh!
There was an error while loading.Please reload this page.
edited
Uh oh!
There was an error while loading.Please reload this page.
Yes, these are the same tests failing for me. |
e2b8600 to7aa4ca2Compare`tmux` uses the default login shell and thus tests might fail if this isnot bash (or something compatible). Explicitly stating which shell touse circumvents issues arising from accidentally using another shell.
7aa4ca2 to727ab39Compare1989584 tob30a864Compare
tmuxuses the default login shell and thus tests might fail if this is not bash (or something compatible). Explicitly stating which shell to use circumvents issues arising from accidentally using another shell.