Closed rpls closed 2 months ago
This seems to be a problem with the cached environment in .spacemacs.env
. Apparently starting processes which needs a connection to X11 simply failed and restart-emacs or external file viewers started but crashed (sadly, they crashed silently) as the connection to X11 failed due to old environment variables (e.g. DISPLAY). Deleting .spacemacs.env
fixed the issue for now. This didn't affect language servers and alike, as they didn't really depend on the invalid environment variables.
Both restart-emacs
(SPC q r
or SPC q R
) and call-process
works for me.
(call-process "gedit")
in Ubuntu 18.04.02 (virtualbox guest with win 10 as host)(call-process "notepad")
in Windows 10 version 1803I don't know anything about X11, so I don't know if gedit connects to it. If it doesn't is there some other application I can test with?
(emacs-lisp git helm multiple-cursors org spell-checking treemacs version-control)
(autohotkey emacs-lisp git helm markdown
(multiple-cursors :variables multiple-cursors-backend 'evil-mc)
(org :variables org-enable-org-journal-support t)
spell-checking treemacs version-control)
New reproduction guide:
.spacemacs.env
and change the DISPLAY variable (in my case, this happened over time as I changed display managers, usually the DISPLAY variable stays pretty much the same on all systems).(call-process "XXX")
to start a process which requires X11.Mitigation for now would be to simply force the regeneration of .spacemacs.env
by deleting it. Full fix would be to continually update the environment stored in .spacemacs.env
.
After changing DISPLAY=:0
to: DISPLAY=:1
and restarting or pressing:
SPC f e E
to call dotspacemacs/call-user-env
Now (call-process "gedit")
doesn't start gedit
and the minibuffer shows:
1 (#o1, #x1, ?\C-a)
With DISPLAY=:0
, gedit
starts and when it's closed then Emacs shows: 0 (#o0, #x0, ?\C-@)
.
I informed the maintainers.
For me, removing the XDG_SESSION
related variables, DISPLAY
and xauthority
from the .spacemacs.env
fixed the issue.
For me, removing the
XDG_SESSION
related variables,DISPLAY
andxauthority
from the.spacemacs.env
fixed the issue.
I remove the .spacemacs.env and spacemacs created it again. now it works for me.
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Please let us know if this issue is still valid!
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Please let us know if this issue is still valid!
Description :octocat:
Emacs can't start processes in some cases. For example, when using
restart-emacs
, emacs will not restart but simply close. Other examples include opening attachments using notmuch (usingnotmuch-show-interactively-view-part
, which in turn will callmm-display-external
to start a process which will view the attachment, for example, a PDF viewer). No errors will show up in*Messages*
. From what I can tell, the execution will (in the case ofrestart-emacs
, and also other instances) arrive atcall-process
orstart-process
or similar, which in turn instead of starting a process, will have no effect whatsoever.The problem is not present in a blank emacs config (i.e.
emacs -q
).Layers which, for example, use language servers are completely fine by the way. So starting processes doesn't fail in general.
Reproduction guide :beetle:
restart-emacs
(call-process "SOMEPROGRAM")
Observed behaviour: :eyes: :broken_heart:
call-process
doesn't do anythingExpected behaviour: :heart: :smile:
call-process
should start a process.System Info :computer:
Backtrace :paw_prints:
Not relevant