Subject: Re: bug#78896: 29.4; display-time-mode breaks minibuffer in emacsclient

From: Juri Linkov <[email-masked]>
Date: Wed, 25 Jun 2025 21:57:30 +0300

> Given the following minimal init file:
> ```
> ;; min-init.el
> (require 'tab-bar)
> (tab-bar-mode)
> (add-to-list 'tab-bar-format 'tab-bar-format-global 'append)
> (display-time-mode -1)
> ```
>
> I do the following:
> ```
> emacs -Q --daemon --load min-init.el
> ```
>
> Then when I start emacsclient in the terminal with `emacsclient -t`, the
> minibuffer won't work at all. When I don't do this via the server,
> e.g. removing `--daemon` from the above invocation, the minibuffer works
> fine.
>
> Let me try to describe what I mean when I say that the minibuffer
> doesn't work. `M-x` puts the cursor at the beginning of the minibuffer
> (no "M-x" text). Typing any key says that the key is not defined. `C-g`
> doesn't work either.

Thanks for the bug report.  My guess is that it's related
to forcing switching frame focus to the active minibuffer.
'tab-bar-format-global' calls 'format-mode-line' that
on a tty frame forces focus to the initial daemon frame.