GNU bug report logs -
#24616
26.0.50; No backtrace when emacsclient --eval fails
Previous Next
Full log
Message #26 received at 24616 <at> debbugs.gnu.org (full text, mbox):
Eli Zaretskii <eliz <at> gnu.org> writes:
>> >> Just a note: you can get a backtrace by setting debug-on-signal
>> >> instead of debug-on-error.
>> >
>> > Really?
>> >
>> > $ emacsclient --eval '(progn (defun f () (error "foo")) (setq debug-on-signal t debug-on-error t) (f))'
>> > *ERROR*: foo
>> >
>> > Am I missing something obvious?
>>
>> The backtrace shows up in Emacs, where the server is running.
>
> How about adding this to debugging.texi?
Something like this?
diff --git i/doc/lispref/debugging.texi w/doc/lispref/debugging.texi
index c88a2fa..bb3ced4 100644
--- i/doc/lispref/debugging.texi
+++ w/doc/lispref/debugging.texi
@@ -152,6 +152,11 @@ Error Debugging
must still fulfill the criteria specified by @code{debug-on-error} and
@code{debug-ignored-errors}.)
+For example, setting this variable is useful to get a backtrace from
+code evaluated by emacsclient. If elisp code evaluated by emacsclient
+signals an error while this variable is non-@code{nil}, the backtrace
+will popup in the running Emacs.
+
@strong{Warning:} Setting this variable to non-@code{nil} may have
annoying effects. Various parts of Emacs catch errors in the normal
course of affairs, and you may not even realize that errors happen
This bug report was last modified 5 years and 152 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.