warpdotdev / Warp

Warp is a modern, Rust-based terminal with AI built in so you and your team can build great software, faster.
https://warp.dev
Other
21.32k stars 372 forks source link

suggestions tooltip options #5386

Open earmellin opened 2 weeks ago

earmellin commented 2 weeks ago

Dupe Check

Describe the bug

with the latest updates the tooltip with suggestions has filled up with entries related to shell functions that are not useful and make the tooltip less usable:

image

these tips disappear after hitting a space and the tooltip makes much more sense

image

To reproduce

start to digit something

Expected behavior

what you see in the second screenshot

Screenshots

No response

Operating system

MacOS

Operating system and version

Sonoma

Shell Version

zsh 5.9 (x86_64-apple-darwin23.0)

Current Warp version

v0.2024.10.08.08.02.stable_02

Regression

Yes, this bug started recently or with an X Warp version

Recent working Warp date

No response

Additional context

No response

Does this block you from using Warp daily?

No

Is this an issue only in Warp?

Yes, I confirmed that this only happens in Warp, not other terminals.

Warp Internal (ignore): linear-label:b9d78064-c89e-4973-b153-5178a31ee54e

None

dannyneira commented 2 weeks ago

Hi @earmellin don't think much has changed for this feature in recent updates. You can try enabling the "Open completions menu as you type" in Settings > Features > Editor, this should help with pulling up the completions menu when you type in yarn+SPACE. I noticed you had no space on the screenshot with the shell functions. I hope this helps with your completion issue.

earmellin commented 2 weeks ago

hi @dannyneira this feature is already enabled, the problem is that until I complete the word "yarn" and add a space the suggestions are completely useless and misleading

dannyneira commented 2 weeks ago

@earmellin, I noticed that yarn isn't syntax highlighted on your second screenshot, indicating it may not be part of the PATH. If you run which yarn you should see the path for your yarn install. In my example, I got /opt/homebrew/bin/yarn so I added the homebrew bin directory to my PATH, and the yarn completion is loaded into new sessions (windows/tab/panes)

So in my example, I added the following to my ~/.zshrc file:

# Homebrew
export PATH="/opt/homebrew/bin:$PATH"

CleanShot 2024-10-17 at 10 33 15

Note how yarn is highlighted at the top of the completions menu. I hope this helps!

earmellin commented 2 weeks ago

I probably didn't explain myself well but this strange behavior of the tooltip is not specific to yarn but to any command, for example look this one related to ollama, only the first suggestion is significant the rest are completely useless:

image

or these related to brew:

image
dannyneira commented 2 weeks ago

Heard, this is due to the nature of the fuzzy search algorithm which is used across Warp. notice that those results contain the same letters, and in the case of brew, the same word. But the more relevant one should always be at the top. That being said, there is a related bug report claiming that the fuzzy search is showing too many results in CTRL-R here, so I take it this is an issue for other users as well.

earmellin commented 2 weeks ago

exactly! I noticed that it was related to the search algorithm, my request is really very similar to that of the other linked issue. In my case it would be enough to exclude all the entries categorized as "Shell function"