all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: npostavs@users.sourceforge.net
To: Eli Zaretskii <eliz@gnu.org>
Cc: 24616@debbugs.gnu.org, clement.pit@gmail.com
Subject: bug#24616: 26.0.50; No backtrace when emacsclient --eval fails
Date: Sat, 22 Oct 2016 11:35:49 -0400	[thread overview]
Message-ID: <877f90tmzu.fsf@users.sourceforge.net> (raw)
In-Reply-To: <831szvmh6j.fsf@gnu.org> (Eli Zaretskii's message of "Wed, 05 Oct 2016 09:41:08 +0300")

Eli Zaretskii <eliz@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





  reply	other threads:[~2016-10-22 15:35 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-10-04 16:30 bug#24616: 26.0.50; No backtrace when emacsclient --eval fails Philipp Stephani
2016-10-04 17:15 ` Eli Zaretskii
2016-10-04 20:52 ` Noam Postavsky
2016-10-04 22:28   ` Clément Pit--Claudel
2016-10-04 23:50     ` Noam Postavsky
2016-10-05  0:02       ` Clément Pit--Claudel
2016-10-05  6:41       ` Eli Zaretskii
2016-10-22 15:35         ` npostavs [this message]
2016-10-22 15:52           ` Eli Zaretskii
2016-10-22 16:08             ` npostavs
2019-11-02  1:09               ` Stefan Kangas
2019-11-18 21:05                 ` Philipp Stephani
2019-11-19 14:31                   ` Stefan Kangas
2016-10-24  0:51 ` Live System User
2016-10-26  1:46   ` Noam Postavsky

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=877f90tmzu.fsf@users.sourceforge.net \
    --to=npostavs@users.sourceforge.net \
    --cc=24616@debbugs.gnu.org \
    --cc=clement.pit@gmail.com \
    --cc=eliz@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.