-
-
Notifications
You must be signed in to change notification settings - Fork 651
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 our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
zellij 0.12 does not respond to input #538
Comments
Hey @cswinter, sorry for the experience. v0.12 moved to a multi-process model to support session detaching and my guess is that this is somehow related. Since I can't reproduce this issue, would you be willing to do some back-and-forth to help debug this? This would involve me attaching a version of zellij with some debug instructions, asking you to run it, press some keys and then attach a log file it will create. |
The problem seems to be with |
Dammit! Good find @kunalmohan !! I take it you're reproducing this issue too? |
I couldn't reproduce this on my ubuntu system. But I have windows as well (I barely use it), so I tried running zellij on WSL, and was able to reproduce it there. |
Right... do you think there's a way we can identify windows terminal and not run termbg somehow? |
I think we can try reading the environment variable Edit: I'll try and test it on my system, and update here. |
Much appreciated, @kunalmohan ! |
This is not limited to Windows. I observe the same on FreeBSD. (Edit: Let me know how I can help debugging this) |
Thanks @riggs- ! |
Also maybe open an issue in termbg. I would guess this loop never ends even after the timeout is reached: https://github.com/dalance/termbg/blob/c451055cdba21219d0cd7d5023fd9603b554124e/src/lib.rs#L211 |
@imsnif sounds good to me. I just created an issue there: dalance/termbg#5. |
Right, I pushed a hotfix to main. @kunalmohan, @riggs- (and @cswinter if you're around) - could you check to make sure it fixes the issue for you? |
@imsnif works for me. |
@imsnif I tried to fix termbg. Could you try dalance/termbg@fed9852 ? |
@imsnif I released termbg v0.3.0 to fix this issue. |
@dalance - thanks for the quick fix as always :) Tbh I'm getting a little concerned about encapsulating stdin behind a dependency like this. Do you think it would be possible to get an API that would allow us to do the stdin part ourselves? thread::spawn({
// wait for stdin and get response ourselves
termbg::interpret_colors(response_from_stdin);
});
termbg::send_osc(); For the time being to fix this issue, I'm going to release the current patch. |
I can provide such API. But I think there are some problems.
I'll consider the API design. |
Fair points. We already handle similar issues with OSC terminators elsewhere, so at least for us this is just a matter of re-using that code. |
Can also confirm this is now working, thanks for the quick fix. So long, tmux! |
`async-std` and `tokio` stdin use `spawn_blocking` to handle stdin, That is, `stdin` task does not end after the timeout, so no input can be processed after opening the TUI. This fix came from upstream: https://github.com/dalance/termbg/tree/non_blocking_stdin, but it was not adopted by upstream because it doesn't compile under Windows, but fortunately oma has no plans to support Windows for the time being. ref: - tokio-rs/tokio#5535 - async-rs/async-std#1055 - zellij-org/zellij#538 - https://github.com/zellij-org/zellij/blob/3569daf7c9cacc1dbbec6a3813079130b4c0683c/zellij-client/src/os_input_output.rs#L270
`async-std` and `tokio` stdin use `spawn_blocking` to handle stdin, That is, `stdin` task does not end after the timeout, so no input can be processed after opening the TUI. This fix came from upstream: https://github.com/dalance/termbg/tree/non_blocking_stdin, but it was not adopted by upstream because it doesn't compile under Windows, but fortunately oma has no plans to support Windows for the time being. ref: - tokio-rs/tokio#5535 - async-rs/async-std#1055 - zellij-org/zellij#538 - https://github.com/zellij-org/zellij/blob/3569daf7c9cacc1dbbec6a3813079130b4c0683c/zellij-client/src/os_input_output.rs#L270
I just upgraded to zellij 0.12 and zellij sessions are completely unresponsive to input. None of the commands work, nor do other keys have observable effects. I've tried all of Powershell, Windows Terminal, and WSL Terminal and run zellij both under WSL and in an ssh session on an Ubuntu machine. Downgrading to 0.11 fixes the issue.
OS version:
zellij version:
The text was updated successfully, but these errors were encountered: