all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Michael Heerdegen <michael_heerdegen@web.de>
To: Drew Adams <drew.adams@oracle.com>
Cc: emacs-devel@gnu.org
Subject: Re: use of `user-error'
Date: Mon, 29 Apr 2013 19:56:34 +0200	[thread overview]
Message-ID: <8738u99q5p.fsf@web.de> (raw)
In-Reply-To: <5DBEBF3431DC44C8A258E389611FF827@us.oracle.com> (Drew Adams's message of "Thu, 7 Mar 2013 08:36:25 -0800")

Hi,

I really would like to discuss these questions raised by Drew (see
at the bottom, shortened!).

I would love to have `debug-on-error' bound to t all the time, to get an
immediate backtrace of errors that happen very rarely and are hard to
reproduce.  But getting a popped up debugger every time I hit a wrong
key or did something obviously wrong by accident is a pain in the ass.

So, can we try to substitute the appropriate occurrences of `error' by
`user-error', or are there any things that prevent us from doing that?


Thanks,

Michael.

> 1. I see many places in the trunk source code where `error' is used
> instead of `user-error' and where I would naively expect the latter to
> be used.
>
> Is this because most occurrences of `error' have simply not yet been
> updated to `user-error', or am I misunderstanding what `user-error' is
> for? [...]

> 2. When `user-error' is used, a user will not get a backtrace, even
> with non-nil `debug-on-error'.
>
> For a developer to request that a user obtain a backtrace in such a
> case, it seems that s?he must now ask the user to also customize
> debug-ignored-errors' to remove `user-error' from the value, in
> addition to turning on `debug-on-error'.
>
> That is a bit of bother to explain and do.  Is there a simpler
> approach? [...]

> 3. 3rd-party developers often look to the Emacs source code as a
> guideline for new things like this. [...]



  reply	other threads:[~2013-04-29 17:56 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-03-07 16:36 use of `user-error' Drew Adams
2013-04-29 17:56 ` Michael Heerdegen [this message]
2013-04-30 12:00   ` Xue Fuqiao
2013-05-05  4:45   ` Stefan Monnier
2013-05-05 13:29     ` Drew Adams
2013-05-05 13:40       ` Dmitry Gutov
2013-05-05 18:16         ` Josh
2013-05-06  1:44           ` Stefan Monnier
2013-05-08 13:24         ` Xue Fuqiao

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=8738u99q5p.fsf@web.de \
    --to=michael_heerdegen@web.de \
    --cc=drew.adams@oracle.com \
    --cc=emacs-devel@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.