pure icon indicating copy to clipboard operation
pure copied to clipboard

Cannot exit pure

Open sbmueller opened this issue 5 years ago • 12 comments

General information

  • Pure version: 1.8.0
  • ZSH version: 5.5.1
  • Terminal program & version: mintty 2.9.0
  • Operating system: Windows 10
  • ZSH framework: oh-my-zsh

I have:

  • [x] Followed the Integration instructions for my framework

Problem description

I cannot exit pure once I start zsh. exit or logout command seem not to finish. After pressing enter, I'm just in a new line where I can continue to write (with a high latency).

Reproduction steps

  1. Install pure
  2. Start zsh
  3. Type exit and press enter
  4. Zsh does not exit and seems to hang

My .zshrc:

ZSH_THEME = ""
plugins = ( gitfast )
source $ZSH/oh-my-zsh.sh
autoload -U promptinit; promptinit
prompt pure

sbmueller avatar Oct 16 '18 14:10 sbmueller

The zsh processes seem to never get killed, even when killing the tmux window: image

sbmueller avatar Oct 17 '18 13:10 sbmueller

Hi, unfortunately this is a Zsh on Windows bug which is related to using zpty's. There's some more information on this available here: https://github.com/mafredri/zsh-async/issues/26, #141 and #146.

Something like https://github.com/mafredri/zsh-async/issues/24 could help, but no work has been done on it yet nor has this assumption been validated.

mafredri avatar Oct 17 '18 14:10 mafredri

Hey @sbmueller, would you be able to try out the no-zpty branch of zsh-async? I'm curious if that method might work for you.

But please keep in mind that it was a super quick hack to test how zsh-async would behave without zpty 😄.

mafredri avatar Jan 20 '19 12:01 mafredri

@mafredri I think this solves the mentioned problems 😲

sbmueller avatar Jan 21 '19 07:01 sbmueller

That's great news, thanks for testing 😄! Going to be off on vacation for a week but after that I'll try to wrap it up into something useable.

mafredri avatar Jan 21 '19 08:01 mafredri

Hey @sbmueller, would you be able to try out the no-zpty branch of zsh-async? I'm curious if that method might work for you.

But please keep in mind that it was a super quick hack to test how zsh-async would behave without zpty smile.

this needs to be added to the readme or wiki

oryband avatar Feb 13 '19 14:02 oryband

@oryband I'd prefer not, until I've had more time to work on the no-zpty branch.

mafredri avatar Feb 13 '19 16:02 mafredri

I was also having the issue on Cygwin/mintty, as I couldn't exit out of the zsh shell. Fortunately, no-zpty branch seems to fix the problem. thank you.

otterpro avatar Jul 26 '19 02:07 otterpro

What happened to the no-zpty branch? I'm having this issue on cygwin

lminer avatar Sep 19 '19 03:09 lminer

@lminer It's still there, I just haven't worked on it since. It does work, but not fully featured, which can cause race conditions. I was actually using it on macOS for a month or two without realizing 😂... Hoping to get around to finishing it soon, but no promises.

mafredri avatar Sep 19 '19 08:09 mafredri

There's a small chance that the async refactor and improvements in #543 might have fixed these issues. It'd be super if someone could test it out!

mafredri avatar Apr 13 '20 14:04 mafredri

I haven't had time to work on this, so I've added the help wanted label. If someone is interested in working on this, continuing on the no-zpty work in zsh-async may be the best approach. Open to alternative solutions too!

mafredri avatar Jun 05 '22 12:06 mafredri