* 'x-create-frame' succeeds, but 'x-open-connection' fails with same display argument
@ 2023-12-04 0:11 Herman
2023-12-04 0:31 ` Po Lu
0 siblings, 1 reply; 3+ messages in thread
From: Herman @ 2023-12-04 0:11 UTC (permalink / raw)
To: help-gnu-emacs
Hi !
$ emacs --fg-daemon
$ emacsclient --eval "(terminal-list)"
(#<terminal 0 on initial_terminal>)
$ emacsclient --eval "(get-device-terminal nil)"
#<terminal 0 on initial_terminal>
$ emacsclient --eval "(x-display-list)"
nil
$ emacsclient --eval "(x-create-frame \`((display . ,(getenv \"DISPLAY\"))))"
#<frame *scratch* - GNU Emacs 0x55db73fd9c30>
$ emacsclient --eval "(terminal-list)"
(#<terminal 0 on initial_terminal> #<terminal 1 on :0.0>)
$ emacsclient --eval "(get-device-terminal nil)"
#<terminal 1 on :0.0>
$ emacsclient --eval "(x-display-list)"
(":0.0")
$ emacsclient --eval "(kill-emacs)"
$ emacs --fg-daemon
$ emacsclient --eval "(x-open-connection (getenv \"DISPLAY\"))"
nil
...
Debugger entered--Lisp error: (error "Display :0.0 does not exist")
signal(error ("Display :0.0 does not exist"))
error("Display %s does not exist" ":0.0")
get-device-terminal(":0.0")
frames-on-display-list(":0.0")
font-setting-change-default-font(":0.0" nil)
dynamic-setting-handle-config-changed-event((config-changed-event font-render ":0.0"))
funcall-interactively(dynamic-setting-handle-config-changed-event (config-changed-event font-render ":0.0"))
call-interactively(dynamic-setting-handle-config-changed-event nil [(config-changed-event font-render ":0.0")])
command-execute(dynamic-setting-handle-config-changed-event nil [(config-changed-event font-render ":0.0")] t)
Emacs 29.1.
/---
30.2 Multiple Terminals topic in Elisp manual says, 'x-open-connection' can be tested for communication with a given X display. What I have missed ?
Thank you in advance for your help !
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: 'x-create-frame' succeeds, but 'x-open-connection' fails with same display argument
2023-12-04 0:11 'x-create-frame' succeeds, but 'x-open-connection' fails with same display argument Herman
@ 2023-12-04 0:31 ` Po Lu
2023-12-04 3:31 ` Eli Zaretskii
0 siblings, 1 reply; 3+ messages in thread
From: Po Lu @ 2023-12-04 0:31 UTC (permalink / raw)
To: Herman; +Cc: help-gnu-emacs
Herman <mahlamytsike@gmail.com> writes:
> Hi !
>
> $ emacs --fg-daemon
> $ emacsclient --eval "(terminal-list)"
> (#<terminal 0 on initial_terminal>)
> $ emacsclient --eval "(get-device-terminal nil)"
> #<terminal 0 on initial_terminal>
> $ emacsclient --eval "(x-display-list)"
> nil
> $ emacsclient --eval "(x-create-frame \`((display . ,(getenv \"DISPLAY\"))))"
> #<frame *scratch* - GNU Emacs 0x55db73fd9c30>
> $ emacsclient --eval "(terminal-list)"
> (#<terminal 0 on initial_terminal> #<terminal 1 on :0.0>)
> $ emacsclient --eval "(get-device-terminal nil)"
> #<terminal 1 on :0.0>
> $ emacsclient --eval "(x-display-list)"
> (":0.0")
> $ emacsclient --eval "(kill-emacs)"
> $ emacs --fg-daemon
> $ emacsclient --eval "(x-open-connection (getenv \"DISPLAY\"))"
> nil
> ...
> Debugger entered--Lisp error: (error "Display :0.0 does not exist")
> signal(error ("Display :0.0 does not exist"))
> error("Display %s does not exist" ":0.0")
> get-device-terminal(":0.0")
> frames-on-display-list(":0.0")
> font-setting-change-default-font(":0.0" nil)
> dynamic-setting-handle-config-changed-event((config-changed-event font-render ":0.0"))
> funcall-interactively(dynamic-setting-handle-config-changed-event (config-changed-event font-render ":0.0"))
> call-interactively(dynamic-setting-handle-config-changed-event nil [(config-changed-event font-render ":0.0")])
> command-execute(dynamic-setting-handle-config-changed-event nil [(config-changed-event font-render ":0.0")] t)
>
> Emacs 29.1.
>
> /--- 30.2 Multiple Terminals topic in Elisp manual says,
> 'x-open-connection' can be tested for communication with a given X
> display. What I have missed ?
>
> Thank you in advance for your help !
I think this is a bug in Emacs, since the display is opened but a font
configuration event arrives shortly after it does, and triggers some
form of bug where, as no frame on that display then exists,
get-device-terminal signals that the display in the configuration event
is nonexistent.
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: 'x-create-frame' succeeds, but 'x-open-connection' fails with same display argument
2023-12-04 0:31 ` Po Lu
@ 2023-12-04 3:31 ` Eli Zaretskii
0 siblings, 0 replies; 3+ messages in thread
From: Eli Zaretskii @ 2023-12-04 3:31 UTC (permalink / raw)
To: help-gnu-emacs
> From: Po Lu <luangruo@yahoo.com>
> Cc: help-gnu-emacs@gnu.org
> Date: Mon, 04 Dec 2023 08:31:29 +0800
>
> > Emacs 29.1.
> >
> > /--- 30.2 Multiple Terminals topic in Elisp manual says,
> > 'x-open-connection' can be tested for communication with a given X
> > display. What I have missed ?
> >
> > Thank you in advance for your help !
>
> I think this is a bug in Emacs, since the display is opened but a font
> configuration event arrives shortly after it does, and triggers some
> form of bug where, as no frame on that display then exists,
> get-device-terminal signals that the display in the configuration event
> is nonexistent.
Please submit a bug report with all the details using
report-emacs-bug.
Thanks.
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2023-12-04 3:31 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-12-04 0:11 'x-create-frame' succeeds, but 'x-open-connection' fails with same display argument Herman
2023-12-04 0:31 ` Po Lu
2023-12-04 3:31 ` Eli Zaretskii
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).