Skip to content
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

Ion shell compatibility problem #597

Closed
Delamare2112 opened this issue Jul 3, 2021 · 6 comments
Closed

Ion shell compatibility problem #597

Delamare2112 opened this issue Jul 3, 2021 · 6 comments

Comments

@Delamare2112
Copy link

Basic information

zellij --version: 0.13.0
tput lines: 42
tput cols: 134
uname -av: Linux manjaro 5.12.9-1-MANJARO #1 SMP PREEMPT Thu Jun 3 14:56:42 UTC 2021 x86_64 GNU/Linux

alacritty --version: alacritty 0.9.0-dev (fa2fa398)
Ion Shell version: git (https://gitlab.redox-os.org/redox-os/ion) (a7c02229)

Further information

Zellij becomes frozen when doing anything that spawns a new ion shell beyond the first initial shell. Like when creating a new pane or tab for example.

I tried using different terminals and window managers until I found that the problem is Zellij + Ion Shell. If I switch my default shell to Zsh and relog, the problem goes away.

Repro:

  1. use chsh to make ion your default shell
  2. logout of your system, then log back into your system
  3. zellij
  4. echo "inside" (works fine)
  5. Ctrl+p n
  6. Zellij is frozen now but type (without feedback) echo "outside"
  7. (in another terminal) killall -2 zellij (or some other method of closing your frozen Zellij)
  8. Notice that echo "outside" and outside were both printed after Zellij closes.
@Delamare2112
Copy link
Author

Oh yeah! The log files! Here they are:

zellij-7.log
zellij-8.log
zellij-9.log

@a-kenji
Copy link
Contributor

a-kenji commented Jul 3, 2021

Hey @Delamare2112.
Thank you for reaching out and filing this bug!
I can reproduce it quite easily.
I wonder what could cause this.
I'll try to look into it some more.

@a-kenji
Copy link
Contributor

a-kenji commented Jul 4, 2021

This problem is also apparent with nu shell.
To reproduce:

zellij options --default-shell ion
zellij options --default-shell nu

And try to start a new tab/pane.

@imsnif
Copy link
Member

imsnif commented Jul 5, 2021

Hey @Delamare2112, thanks for reporting and debugging this. And also thanks @a-kenji as well.

This was happening because the pty thread inside Zellij did not manage to properly close these shells (ion or nu). It was sending them the SIGKILL which I guess under certain circumstances was not enough for them to die (I'm not sure which circumstances exactly - I for example only managed to reproduce this with the development build of ion and not with any build of nu).

I issued a fix for this which should be merged to main just as soon as the CI gives me a go. If you'd like to test it there to make sure, that would be great - otherwise it'll be released with the next version in the not-too-distant future.

@a-kenji
Copy link
Contributor

a-kenji commented Jul 5, 2021

@imsnif
Awesome, thanks for the quick fix.
It behaves well on my side now.
Yes the problem with nu was not with
every single launch.

@Delamare2112
Copy link
Author

It works! Thanks very much for the bug fix :)

@a-kenji a-kenji closed this as completed Jul 5, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants