[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#34765: 26.1; with-temp-buffer should not run buffer-list-update-hook

From: Alexander Miller
Subject: bug#34765: 26.1; with-temp-buffer should not run buffer-list-update-hook
Date: Thu, 7 Mar 2019 10:44:11 +0100
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.5.1

> So what was the problem there?  How did 'buffer-list-update-hook' get
> invoked in such a wild manner

As I understand it: advising select-window served the purpose of
remembering the
current window so the modeline can be highlighted in tune with the
selection. The
advising code would also call force-mode-line-update, that in turn lead
to a re-calculation
of the frame title, in spacemacs this could in turn call format-spec,
that would use a
temp-buffer, that triggers buffer-list-update-hook, that triggers
treemacs' follow-mode
callback, that calls with-selected-window, that leads back to the
modeline's select-window
advice. That's more or less what the feedback loop looked like.

Come to think of it, maybe just suppressing the hook during my own
will do the trick.

> This alone qualifies as a bug IMHO.

You'll have to take that up with Jonas. I linked this discussion in
github, so he'll probably
read this.

> I think that creating a new temporary buffer should always be the
> exception and never the rule.  Does the point moving happen in the
> treemacs buffer or in that of a plain (probably git-controlled)
> buffer?

You misunderstood. The issue only happened when the treemacs window was
but point was in magit's status buffer and a region was active (e.g.
when you want to
select single lines for staging or reverting). Non-magit buffers had no

> Can you pass me a corresponding URL?

Did that already, Here it is again:

reply via email to

[Prev in Thread] Current Thread [Next in Thread]