From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Stefan Monnier Newsgroups: gmane.emacs.devel Subject: Re: Backtraces on server? Date: Wed, 03 Aug 2016 16:37:17 -0400 Message-ID: References: NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: blaine.gmane.org 1470491742 13206 195.159.176.226 (6 Aug 2016 13:55:42 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Sat, 6 Aug 2016 13:55:42 +0000 (UTC) User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/25.1.50 (gnu/linux) To: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Sat Aug 06 15:55:39 2016 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1bW23X-0008PS-Uf for ged-emacs-devel@m.gmane.org; Sat, 06 Aug 2016 15:54:28 +0200 Original-Received: from localhost ([::1]:49521 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bW23U-00083t-KQ for ged-emacs-devel@m.gmane.org; Sat, 06 Aug 2016 09:54:24 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:42835) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bW22P-0007zC-9I for emacs-devel@gnu.org; Sat, 06 Aug 2016 09:53:18 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1bW22L-00066Q-5r for emacs-devel@gnu.org; Sat, 06 Aug 2016 09:53:16 -0400 Original-Received: from [195.159.176.226] (port=51367 helo=blaine.gmane.org) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bW22K-000663-UW for emacs-devel@gnu.org; Sat, 06 Aug 2016 09:53:13 -0400 Original-Received: from list by blaine.gmane.org with local (Exim 4.84_2) (envelope-from ) id 1bV2sL-0002N5-72 for emacs-devel@gnu.org; Wed, 03 Aug 2016 22:34:49 +0200 X-Injected-Via-Gmane: http://gmane.org/ Original-Lines: 20 Original-X-Complaints-To: usenet@blaine.gmane.org Cancel-Lock: sha1:hjlREwuPaF0o3ER9K7EULLRFA9o= X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 195.159.176.226 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.org gmane.emacs.devel:206444 Archived-At: > Is is by design that the server doesn't print backtraces, or am > I doing something silly? > > $ emacs -Q --eval '(setq server-name "test")' --daemon > > $ emacsclient -s test --eval "(progn (setq debug-on-error t) (/ 1 0))" > *ERROR*: Arithmetic error > > $ emacsclient -s test --eval "(progn (setq noninteractive t) (setq debug-on-error t) (/ 1 0))" > *ERROR*: Arithmetic error IIRC server.el runs the expression within a condition-case so as to send the error back to the client, and debug-on-error only kicks in for errors that aren't caught by any condition-case. We could use the condition-case-unless-debug construct there, but you still wouldn't see the backtrace in the client. Stefan