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

does not create a new line and consumes a lot of CPU resources #12360

Open
intern opened this issue Apr 17, 2024 · 15 comments
Open

does not create a new line and consumes a lot of CPU resources #12360

intern opened this issue Apr 17, 2024 · 15 comments
Assignees
Labels
Area: core Issue or PR related to core parts of the project Platform: Linux Issue or PR for a Linux system

Comments

@intern
Copy link

intern commented Apr 17, 2024

Describe the bug

Local mac os system, using iterm2 to ssh connect to remote centos 7 system, ohmyzsh latest version installed on centos 7, encountering issues where pressing ctrl c does not create a new line, and zsh consumes a lot of CPU resources after the connection is disconnected.

Steps to reproduce

Local mac os system, using iterm2 to ssh connect to remote centos 7 system, ohmyzsh latest version installed on centos 7, encountering issues where pressing ctrl c does not create a new line, and zsh consumes a lot of CPU resources after the connection is disconnected.

Expected behavior

Rolling back to a previous version(15ffbdd) resolves the issue, and I haven't tested the versions in between. I'm not sure which version's changes are causing the problem.

Screenshots and recordings

No response

OS / Linux distribution

Mac os 13.52

Zsh version

5.9

Terminal emulator

iTerm2

If using WSL on Windows, which version of WSL

None

Additional context

Please Fix it!

@carlosala
Copy link
Member

Could you git bisect and discover which commit creates the issue?

@carlosala carlosala self-assigned this Apr 17, 2024
@intern
Copy link
Author

intern commented Apr 22, 2024

ec1afe9

@intern
Copy link
Author

intern commented Apr 22, 2024

Could you git bisect and discover which commit creates the issue?

This issue was caused by changes in this version. I noticed that "-t" was changed to "-T". After reverting this modification to "-t" on the master branch, the issue did not occur.

@carlosala
Copy link
Member

carlosala commented Apr 22, 2024

@intern could you update to the latest omz master and see if it is fixed for you? Try it with no modifications and without disabling async prompt!

@liguoqinjim
Copy link

I encountered the same problem. Ctrl+C can still send an INT signal, but it cannot create a new line. Press Ctrl+C, then press a letter to create a new line.

@carlosala
Copy link
Member

carlosala commented May 13, 2024

Hi @liguoqinjim! Which version of ohmyzsh are you running? Are you as well on centos 7?

@liguoqinjim
Copy link

Hi @liguoqinjim! Which version of ohmyzsh are you running? Are you as well on centos 7?
Hello, I tried it out and might have found the issue.I hope this helps you solve the problem.🤪

centos verions:CentOS Linux release 7.6.1810 (Core)
zsh version:zsh 5.0.2 (x86_64-redhat-linux-gnu)

correct commit: f78c6b9
commit that may have issues: 0c80a06

@mcornella
Copy link
Member

If commit f78c6b9 fixes the issue then this is already solved in the latest version and this should be closed.

@mcornella mcornella added Platform: Linux Issue or PR for a Linux system Area: core Issue or PR related to core parts of the project Resolution: duplicate This issue or pull request already exists labels May 13, 2024
@mcornella
Copy link
Member

Duplicate of #12331.

@mcornella mcornella closed this as not planned Won't fix, can't repro, duplicate, stale May 13, 2024
@liguoqinjim
Copy link

If commit f78c6b9 fixes the issue then this is already solved in the latest version and this should be closed.

Nope,the latest commit b1c5315a5fbc33624525e434ddbaec3bb30030e2still has the issue.

@mcornella mcornella reopened this May 13, 2024
@mcornella mcornella removed the Resolution: duplicate This issue or pull request already exists label May 13, 2024
@mcornella
Copy link
Member

And you can turn the behavior off with the following line in your .zshrc file, before Oh My Zsh is sourced?

zstyle ':omz:alpha:lib:git' async-prompt no

@mcornella
Copy link
Member

Can you make a screen recording of the issue, and also put functions -t _omz_async_request _omz_async_callback in your zshrc file at the bottom to get a trace?

@mcornella mcornella self-assigned this May 13, 2024
@liguoqinjim
Copy link

And you can turn the behavior off with the following line in your .zshrc file, before Oh My Zsh is sourced?

zstyle ':omz:alpha:lib:git' async-prompt no

commit id: "b1c5315a5fbc33624525e434ddbaec3bb30030e2"

zstyle ':omz:alpha:lib:git' async-prompt no
source $ZSH/oh-my-zsh.sh

With the line, result is correct.

@nasacj
Copy link

nasacj commented May 21, 2024

And you can turn the behavior off with the following line in your .zshrc file, before Oh My Zsh is sourced?

zstyle ':omz:alpha:lib:git' async-prompt no

This works. Could you please help to fix it? So that with runningomz update can fix this issue @mcornella

@carlosala
Copy link
Member

Can you make a screen recording of the issue, and also put functions -t _omz_async_request _omz_async_callback in your zshrc file at the bottom to get a trace?

Could someone send the screen recording? 🙏🏻
Maybe @jsrdzhk?
Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Area: core Issue or PR related to core parts of the project Platform: Linux Issue or PR for a Linux system
Projects
Status: Backlog
Development

No branches or pull requests

5 participants