zsh-autosuggestions
zsh-autosuggestions copied to clipboard
High cpu usage and autosuggestions freezes on make command
Describe the bug
I'm in a makefile project directory, I start typing make then zsh freezes and is at around 60% cpu usage.
To Reproduce
Steps to reproduce the behavior: Enable autosuggestions, enable zdharma/fast-syntax-highlighting, type make inside a makefile project directory.
% zsh -df
% source path/to/zsh-autosuggestions.zsh
% ... # what do you do to reproduce?
zdharma/fast-syntax-highlighting is causing the freeze in autosuggestions with make
Expected behavior
No freeze here
Screenshots
exact line it freezes on:
+ zsh-autosuggestions.zsh:816 @_zsh_autosuggest_async_response:1> emulate -L zsh
+ zsh-autosuggestions.zsh:818 @_zsh_autosuggest_async_response:3> local suggestion
+ zsh-autosuggestions.zsh:820 @_zsh_autosuggest_async_response:5> [[ -z '' ]]
+ zsh-autosuggestions.zsh:822 @_zsh_autosuggest_async_response:7> IFS='' + zsh-autosuggestions.zsh:822 @_zsh_autosuggest_async_response:7> read -rd '' -u 13 suggestion
+ zsh-autosuggestions.zsh:823 @_zsh_autosuggest_async_response:8> zle autosuggest-suggest -- ''
+ zsh-autosuggestions.zsh:830 @_zsh_autosuggest_async_response:15> zle -F 13
Desktop
- OS + distribution: macOS 12.5 Monterey
- Zsh version: 5.8.1
- Plugin version: a411ef3e0992d4839f0732ebeb9823024afaaaa8
Additional context
Facing same issue on zsh 5.9 (x86_64-apple-darwin22.0)