Giter Club home page Giter Club logo

Comments (5)

flatcap avatar flatcap commented on September 22, 2024

Hmm...
From the other issue, you index_format looks like:

set index_format = '%3C %4Z %?X?📎& ? %D %-20.20F %.70s (%-4.4c) %>'

The %X could be the cause.
To count the number of attachments, NeoMutt has to parse the entire email.

the issue rectifies itself after the first scroll-through.

Once the cache has been populated, NeoMutt can use the cached value.
Everything should be zippy again.


The caches are very sensitive to code changes and new releases can sometimes cause the cache to be invalidated.
We try to keep these changes to a minimum, but sometimes they're unavoidable.

If you see a persistent slowdown, please let me know.

Thanks

from neomutt.

bmclean2 avatar bmclean2 commented on September 22, 2024

@flatcap That actually fixed it! Good call, thank you so much!

from neomutt.

bmclean2 avatar bmclean2 commented on September 22, 2024

@flatcap Just seeking clarification on this. Removing %X does indeed fix the lag. Assuming I want to keep %X, however, what's not clear is why the cache that makes everything zippy on subsequent scrolls doesn't persist on Neomutt restart. When you say "cache," do you mean the disk-stored header/body caches, or is there some separate memory-based caching that happens? I haven't been able to get body caching to work because I think it requires the use of IMAP/POP (I use isync/mbsync), so maybe this is my issue. 🤷🏻‍♂️

from neomutt.

flatcap avatar flatcap commented on September 22, 2024

Just seeking clarification on this

No problem...
I've just checked the behaviour, to be certain.

The header cache stores the value for %X, but only for the emails you've seen in the Index.

Calculating %X is slow, so NeoMutt will do it on demand (for the page you're looking at)
That info will be saved to the header cache.

When you change pages, more reading needs to be done.
If you restart NeoMutt and open the same folder, the pages you've looked at before will be fast.
Anything else will be slow, once.

Unfortunately, there isn't a way to tell NeoMutt to re-cache an entire folder.
You either need to hold down <Page-Up>, or create huge macro to do it a lot of times.


Here are my header cache settings:

# Trailing / means create separate dirs for each folder
set header_cache = "~/.cache/mutt/"
# Fast modern database
set header_cache_backend = "lmdb"
# Enable compression; even low levels are quite effective in saving space
set header_cache_compress_level = 18
set header_cache_compress_method = "zstd"

from neomutt.

bmclean2 avatar bmclean2 commented on September 22, 2024

When you change pages, more reading needs to be done. If you restart NeoMutt and open the same folder, the pages you've looked at before will be fast. Anything else will be slow, once.

My header cache settings (lmdb,zstd,10) are close to yours and when I do change-folder and come back to the original, or restart Neomutt, the lag returns. I checked again, and for some reason the lag is nearly non-existent on Linux with %X. Deleting the existing cache files did not help.

from neomutt.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.