atuin icon indicating copy to clipboard operation
atuin copied to clipboard

Slight performance drop in 12.0

Open dabeeeenster opened this issue 2 years ago • 5 comments

Hi,

I've noticed with 12.0 that if I havent used atuin for a few hours, then hit the keyboard shortcut, there's a slight delay (~150ms but noticable) before the search page comes up. I'm 99% sure this didn't happen prior to 12.0.

Appreciate this might be hard to analyse! Is there any way I can help with traces/metrics?

I'm on MacOS Ventura, fish shell, iTerm2.

dabeeeenster avatar Nov 09 '22 09:11 dabeeeenster

Yes, the same problem occurs in my case, I use arch linux and the atuin delay is sometimes even up to 5 seconds, this problem has been occurring for days, I just never got around to reporting it. And I also noticed that the accuracy of the search has dropped a lot, maybe the latest 12.0 version offers something like a fuzzy search, but it doesn't perform well and it's harder to type in keywords to find the historical commands I want.

Translated with www.DeepL.com/Translator (free version)

jlvihv avatar Nov 09 '22 11:11 jlvihv

Ah maybe related to https://github.com/ellie/atuin/pull/591 ?

dabeeeenster avatar Nov 09 '22 11:11 dabeeeenster

Ahh yeah there's two things here

  1. People kept complaining that fuzzy search was not the default, so we made it the default. If you change it back to prefix in your config, you should be good
  2. Lots of people had issues relating to being a large number of versions behind, so we added version checking. This is probably what is causing the pause 🙃

For 1)

search_mode = "prefix"

in your config should take you back to before @jlvihv

Otherwise for 2), for now,

update_check = false

if you're finding it too much of an issue. Otherwise I'll try and get a fix out in the next week for the delay

ellie avatar Nov 09 '22 12:11 ellie

Thank you @ellie

jlvihv avatar Nov 09 '22 12:11 jlvihv

FWIW, I'm using fuzzy search (coming from fzf), and just setting update_check = false did the trick to restore startup performance.

pdecat avatar Dec 01 '22 11:12 pdecat

Resolved in #693

ellie avatar Oct 18 '23 03:10 ellie