Subject: bug#67361: 29.1; MH-E: creating a new folder can sometimes fail with a Lisp error

From: Chris Siebenmann <[email-masked]>
Date: Fri, 24 Nov 2023 22:18:16 -0500

> Using mh-speed-folder-map as the test for whether the speedbar is active
> seems broken to me.  Unfortunately, I don't use the speedbar, and I
> don't understand the MH-E speedbar code all that well.  So I'm not sure
> what the right test is.  There's a function mh-speed-flists-active-p,
> but its docstring says
>
>   "Check if speedbar is running with message counts enabled."
>
> Bill, is there a mode where the speedbar is running *without* message
> counts enabled?  Or can we just replace 
>
>     (when (boundp 'mh-speed-folder-map)
>
> with
>
>     (if (mh-speed-flists-active-p)
>
> ?

I believe there is such a mode. If you set mh-speed-update-interval to 0
and invoke the speedbar, you get a display of your MH folders but
without any message counts, because MH-E isn't periodically running
flists to find them out. You might sensibly use the speedbar this way if
all of your email is put into +inbox (so nothing else will ever have
unread messages and the counts of read messages are broadly
uninteresting to you) and you use the speedbar as a handy way of
navigating and visualizing a complex folder hierarchy.

I believe that if the speedbar is active (which I believe is when
speedbar-buffer is non-nil) and you're in MH-E, the speedbar will be
showing your MH folder hierarchy instead of anything else. But I'm not
100% sure of this. The code in mh-speed certainly seems to expect to
find MH's content in the speedbar buffer without further checks that I
can see.

	- cks