From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: David Shepherd Newsgroups: gmane.emacs.bugs Subject: bug#24778: 25.1; cl-assert always calls the default debugger on assertion failures Date: Sun, 23 Oct 2016 20:00:03 +0100 Message-ID: NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Trace: blaine.gmane.org 1477249289 32529 195.159.176.226 (23 Oct 2016 19:01:29 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Sun, 23 Oct 2016 19:01:29 +0000 (UTC) To: 24778@debbugs.gnu.org Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Sun Oct 23 21:01:24 2016 Return-path: Envelope-to: geb-bug-gnu-emacs@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 1byO1A-0006Tc-3h for geb-bug-gnu-emacs@m.gmane.org; Sun, 23 Oct 2016 21:01:12 +0200 Original-Received: from localhost ([::1]:42088 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1byO1C-0003Dh-Fv for geb-bug-gnu-emacs@m.gmane.org; Sun, 23 Oct 2016 15:01:14 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:34895) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1byO12-0003DV-HA for bug-gnu-emacs@gnu.org; Sun, 23 Oct 2016 15:01:06 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1byO10-0004FV-DY for bug-gnu-emacs@gnu.org; Sun, 23 Oct 2016 15:01:04 -0400 Original-Received: from debbugs.gnu.org ([208.118.235.43]:34430) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1byO10-0004F5-AJ for bug-gnu-emacs@gnu.org; Sun, 23 Oct 2016 15:01:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1byO10-0007Vt-3u for bug-gnu-emacs@gnu.org; Sun, 23 Oct 2016 15:01:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: David Shepherd Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 23 Oct 2016 19:01:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 24778 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: X-Debbugs-Original-To: bug-gnu-emacs@gnu.org Original-Received: via spool by submit@debbugs.gnu.org id=B.147724924028841 (code B ref -1); Sun, 23 Oct 2016 19:01:01 +0000 Original-Received: (at submit) by debbugs.gnu.org; 23 Oct 2016 19:00:40 +0000 Original-Received: from localhost ([127.0.0.1]:49828 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1byO0e-0007V7-1g for submit@debbugs.gnu.org; Sun, 23 Oct 2016 15:00:40 -0400 Original-Received: from eggs.gnu.org ([208.118.235.92]:43841) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1byO0c-0007Uu-9U for submit@debbugs.gnu.org; Sun, 23 Oct 2016 15:00:38 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1byO0V-00049n-Af for submit@debbugs.gnu.org; Sun, 23 Oct 2016 15:00:33 -0400 Original-Received: from lists.gnu.org ([2001:4830:134:3::11]:34937) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1byO0V-00049h-7a for submit@debbugs.gnu.org; Sun, 23 Oct 2016 15:00:31 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:34809) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1byO0S-0003BJ-Tk for bug-gnu-emacs@gnu.org; Sun, 23 Oct 2016 15:00:30 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1byO0Q-00048d-VP for bug-gnu-emacs@gnu.org; Sun, 23 Oct 2016 15:00:29 -0400 Original-Received: from mail-wm0-x231.google.com ([2a00:1450:400c:c09::231]:38562) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1byO0Q-000487-Jz for bug-gnu-emacs@gnu.org; Sun, 23 Oct 2016 15:00:26 -0400 Original-Received: by mail-wm0-x231.google.com with SMTP id c78so77499887wme.1 for ; Sun, 23 Oct 2016 12:00:26 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:from:date:message-id:subject:to :content-transfer-encoding; bh=e+W9Z1Zxhscefz0OGciDy9OnJoUXNPb6AnUrEp2R1xI=; b=QiZpYCPAKthWYCPezJxUlrDXkOrov+VXoLF6SyXmTDde96AF2+pTdmRiqqopaJfd90 EOVh4abkz7/fv+yekh1/SGkjFhzyabD+QRiIg2+sutbGSwNoh9oraoc+T0iZvTcpmJLf piwhytVy8MIyDpDoIzNydiJ8KzCmYBxYAEcKge6yxiUI3BHHEw8Wh1O4Kd5A5qhnv3QF hFd3lFQF3osQIonMaXf7HVPZ9GiP1NtQYgjWr9jZKgPxYVHwVWkA75XIm9NLP7Swe3Rv enRgLebD28EO0F44MQSb9DVgEA8x294DUtFEOZIPbBYqj/cu4XZHLDlL0MWLpdoj+8f+ KlsQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:from:date:message-id:subject:to :content-transfer-encoding; bh=e+W9Z1Zxhscefz0OGciDy9OnJoUXNPb6AnUrEp2R1xI=; b=bVVI9NyINpOxg2r0y8X4vkV5E024GyFLdYoRBcM5hpElZsQKswcsFME/HzwOxoWo+I 3P1m5yI/tqDmjZRTagHxhNeADFcGgdDZweC3uuQA3kXMFLSBbC0A5pI803G168e+Rl1I YIfjjkLP5XwdDtS2YuzLgYBabYSPSJAXiIH1XWGOCf+kYS+EKFB2wty06E5dYhHF8HpD 1Kx7eEVxgbLAtw0f5/BBcvWKbj5YuN0lDD+EkT992tLTemZhoM0OThgg2KQ1Kcf7rnYS YAb/7S6A6kX2kckZOzMNtBhCwL8spUU+x7b4Wst7z1UuBI1TrXTDSKgRHIdYhCMBiU8V lNrQ== X-Gm-Message-State: AA6/9RkVcaqCuWo164Qmw6hFC6FuRfzxrol29i4E0hJcWYXGfCddimalNO0m0WNftjNEADBUe8HGHlliBPddPA== X-Received: by 10.28.94.139 with SMTP id s133mr12492125wmb.1.1477249224578; Sun, 23 Oct 2016 12:00:24 -0700 (PDT) Original-Received: by 10.28.154.203 with HTTP; Sun, 23 Oct 2016 12:00:03 -0700 (PDT) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 208.118.235.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.org gmane.emacs.bugs:124927 Archived-At: This causes problems with ert if you use cl-assert. For example with the following saved in temp.el (require 'cl-macs) (ert-deftest cl-assert-failure () (cl-assert (equal 1 2) "uh oh")) and run with emacs -Q -batch -l ert -l temp.el -f ert-run-tests-batch-and-exit (as recommended by the ert manual) the output is Running 1 tests (2016-10-23 19:48:21+0100) Debugger entered: ((cl-assertion-failed (equal 1 2) nil)) cl--assertion-failed((equal 1 2)) (or (equal 1 2) (cl--assertion-failed (quote (equal 1 2)))) (progn (or (equal 1 2) (cl--assertion-failed (quote (equal 1 2)))) ni= l) followed by a large backtrace. Whereas (ert-deftest normal-error-call () (error "uh oh")) gives the output Running 1 tests (2016-10-23 19:52:07+0100) Test normal-error-call backtrace: (lambda nil (error "uh oh"))() ert--run-test-internal([cl-struct-ert--test-execution-info [cl-struc ert-run-test([cl-struct-ert-test normal-error-call nil (lambda nil ( ert-run-or-rerun-test([cl-struct-ert--stats t [[cl-struct-ert-test n ert-run-tests(t #[385 "\306\307\"\203G\211\211G\310U\203\211@\20 ert-run-tests-batch(nil) ert-run-tests-batch-and-exit() command-line-1(("-l" "ert" "-l" "temp.el" "-f" "ert-run-tests-batch- command-line() normal-top-level() Test normal-error-call condition: (error "uh oh") FAILED 1/1 normal-error-call Ran 1 tests, 0 results as expected, 1 unexpected (2016-10-23 19:52:07+0= 100) 1 unexpected results: FAILED normal-error-call Older versions of emacs gave something like the second output even when cl-assert was used. This doesn't seem to be an issue if ert tests are run interactively, I'm not sure why. Removing the lines (if debug-on-error (apply debugger `(cl-assertion-failed ,form ,string ,@sargs)) from cl--assertion-failed seems to solve the problem, but I don't know if that would break other things. In GNU Emacs 25.1.1 (x86_64-pc-linux-gnu, X toolkit, Xaw3d scroll bars) of 2016-10-23 built on david-entroware Repository revision: f0eb70d8935be90f7c03e187c12d9b60e7214cc6 Windowing system distributor 'The X.Org Foundation', version 11.0.11803000 System Description: Ubuntu 16.04.1 LTS Configured using: 'configure --with-x-toolkit=3Dlucid 'CFLAGS=3D-O3 -march=3Dnative'' Configured features: XAW3D XPM JPEG TIFF GIF PNG RSVG IMAGEMAGICK SOUND GPM DBUS GCONF GSETTINGS NOTIFY ACL LIBSELINUX GNUTLS LIBXML2 FREETYPE M17N_FLT LIBOTF XFT ZLIB TOOLKIT_SCROLL_BARS LUCID X11 Important settings: value of $LANG: en_GB.UTF-8 locale-coding-system: utf-8-unix Major mode: Emacs-Lisp Minor modes in effect: electric-pair-mode: t editorconfig-mode: t highlight-symbol-mode: t suppress-multiline-string-indent-mode: ds/line-in-string-block? nameless-mode: t rainbow-delimiters-mode: t which-key-mode: t global-discover-mode: t discover-mode: t aggressive-fill-paragraph-mode: t ws-butler-global-mode: t ws-butler-mode: t yas-global-mode: t yas-minor-mode: t hl-sexp-mode: t global-diff-hl-mode: t diff-hl-mode: t savehist-mode: t helm-mode: t async-bytecomp-package-mode: t projectile-global-mode: t projectile-mode: t flycheck-mode: t global-company-mode: t company-mode: t diff-auto-refine-mode: t global-git-commit-mode: t recentf-mode: t shell-dirtrack-mode: t frames-only-mode: t super-save-mode: t evil-mode: t global-undo-tree-mode: t undo-tree-mode: t evil-local-mode: t global-subword-mode: t subword-mode: t global-anzu-mode: t anzu-mode: t save-place-mode: t global-auto-revert-mode: t whitespace-mode: t global-linum-mode: t linum-mode: t global-page-break-lines-mode: t page-break-lines-mode: t show-paren-mode: t override-global-mode: t tooltip-mode: t global-eldoc-mode: t electric-layout-mode: t electric-indent-mode: t mouse-wheel-mode: t prettify-symbols-mode: t file-name-shadow-mode: t global-font-lock-mode: t font-lock-mode: t auto-composition-mode: t auto-encryption-mode: t auto-compression-mode: t column-number-mode: t line-number-mode: t global-visual-line-mode: t visual-line-mode: t transient-mark-mode: t Recent messages: Saving file /home/david/code/espuds/test/espuds-test.el... Wrote /home/david/code/espuds/test/espuds-test.el (Cannot open load file: No such file or directory, f) Mark set [2 times] Saving file /home/david/code/espuds/test/test-helper.el... Wrote /home/david/code/espuds/test/test-helper.el Reverting buffer =E2=80=98espuds-test.el=E2=80=99. Saving file /home/david/code/espuds/espuds.el... Wrote /home/david/code/espuds/espuds.el Load-path shadows: ~/.emacs.d/vc-packages/projectile/helm-projectile hides /home/david/.emacs.d/elpa/helm-projectile-20151220.221/helm-projectile /home/david/.emacs.d/elpa/helm-20160409.113/helm-multi-match hides /home/david/.emacs.d/elpa/helm-core-20160407.2135/helm-multi-match ~/.emacs.d/vc-packages/projectile/projectile hides /home/david/.emacs.d/elpa/projectile-20160210.905/projectile /home/david/.emacs.d/elpa/seq-20150928.1218/seq hides /usr/local/share/emacs/25.1/lisp/emacs-lisp/seq Features: (shadow sort mail-extr emacsbug sendmail two-column helm-ring ansi espuds jka-compr expand-region text-mode-expansions cc-mode-expansions the-org-mode-expansions python-el-fgallina-expansions js-mode-expansions html-mode-expansions feature-mode-expansions css-mode-expansions clojure-mode-expansions er-basic-expansions expand-region-core expand-region-custom misearch multi-isearch image-file helm-command eieio-opt speedbar sb-image ezimage dframe helm-elisp helm-eval editorconfig-core editorconfig-core-handle editorconfig-fnmatch winner elec-pair company-yasnippet hamburger-menu tmm ivy delsel editorconfig emerge fill-function-arguments highlight-symbol scratch ag vc-svn find-dired crux flycheck-cask smooth-scrolling nameless lisp-mnt rainbow-delimiters multiple-cursors mc-hide-unmatched-lines-mode mc-separate-operations rectangular-region-mode mc-mark-pop mc-mark-more mc-cycle-cursors mc-edit-lines multiple-cursors-core helm-dash lex-mode feature-mode cucumber-mode yaml-mode replace-pairs electric-operator ess ess-inf ess-mode ess-noweb-mode ess-utils ess-custom ess-compat which-key discover makey aggressive-fill-paragraph ws-butler imenu-anywhere avy deft yasnippet list-register goto-last-change markdown-mode hl-sexp names-dev diff-hl face-remap vc-hg vc-git vc-dir vc vc-dispatcher savehist ds/toggle-electricity names evil-matchit evil-surround smartparens key-chord helm-mode helm-config helm-easymenu async-bytecomp async helm-projectile flx helm-files image-dired dired-aux helm-buffers helm-elscreen helm-tags helm-bookmark helm-adaptive helm-info bookmark helm-locate helm-grep helm-regexp helm-plugin helm-external helm-net xml url url-proxy url-privacy url-expand url-methods url-history url-cookie url-domsuf url-util mailcap helm-utils helm-help helm-types helm helm-source eieio-compat helm-multi-match helm-lib cmake-mode projectile ibuf-macs ibuf-ext ibuffer typescript-mode cider cider-debug cider-browse-ns cider-inspector cider-mode cider-interaction arc-mode archive-mode cider-repl cider-resolve cider-test cider-overlays cider-stacktrace cider-doc org-table cider-grimoire cider-popup cider-eldoc cider-client cider-common cider-util clojure-mode nrepl-client queue nrepl-dict cider-compat sh-script executable css-mode smie sqlup-mode sql view ds-js json-mode json-reformat json-snatcher grep align js sgml-mode imenu javadoc-lookup evil-args company-anaconda anaconda-mode f json-rpc python matlab gud tempo ds/scheme scheme reftex reftex-vars reftex-global modern-cpp-font-lock flycheck json map compile cc-mode cc-fonts cc-guess cc-menus cc-cmds cc-styles cc-align cc-engine cc-vars cc-defs skeleton smart-mode-line-dark-theme smart-mode-line-light-theme smart-mode-line rich-minority company-oddmuse company-keywords company-etags company-gtags company-dabbrev-code company-dabbrev company-files company-capf company-cmake company-xcode company-clang company-semantic company-eclim company-template company-css company-nxml company-bbdb company magit-blame magit-stash magit-bisect magit-remote magit-commit epa magit-sequence magit dired-x magit-log magit-apply magit-wip magit-diff smerge-mode diff-mode magit-core magit-process magit-popup magit-mode magit-git crm magit-section magit-utils ido git-commit recentf tree-widget log-edit message rfc822 mml mml-sec epg mm-decode mm-bodies mm-encode mail-parse rfc2231 rfc2047 rfc2045 ietf-drums mailabbrev mail-utils gmm-utils mailheader pcvs-util add-log with-editor warnings term disp-table ehelp esh-var esh-io esh-cmd esh-opt esh-ext esh-proc esh-arg esh-groups eshell esh-module esh-mode esh-util dired tramp-sh tramp tramp-compat tramp-loaddefs trampver shell server frames-only-mode ediff-wind ediff-help ediff-init org-agenda org org-macro org-footnote org-pcomplete pcomplete org-list org-faces org-entities noutline outline org-version ob-emacs-lisp ob ob-tangle ob-ref ob-lob ob-table ob-exp org-src ob-keys ob-comint comint ansi-color ob-core ob-eval org-compat org-macs org-loaddefs format-spec cal-menu calendar cal-loaddefs super-save evil evil-integration undo-tree diff evil-maps evil-commands ffap url-parse auth-source gnus-util mm-util help-fns mail-prsvr password-cache url-vars evil-command-window evil-types evil-search evil-ex evil-macros evil-repeat evil-states evil-core evil-common windmove rect evil-digraphs evil-vars cap-words superword subword anzu thingatpt saveplace autorevert filenotify whitespace linum page-break-lines browse-url etags xref project eieio aggressive-indent shepherd-theme time-date paren s ucs-normalize dash validate cus-edit cus-start cus-load wid-edit paradox paradox-menu paradox-commit-list derived hydra ring lv paradox-execute let-alist paradox-github paradox-core spinner subr-x package-utils epl rx cl-seq use-package diminish cl bind-key easy-mmode ert pp find-func ewoc debug finder-inf tex-site go-mode-autoloads eieio-core cl-macs advice info package epg-config seq byte-opt gv bytecomp byte-compile cl-extra help-mode cconv hi-lock edebug easymenu edmacro kmacro cl-loaddefs pcase cl-lib mule-util tooltip eldoc electric uniquify ediff-hook vc-hooks lisp-float-type mwheel x-win term/common-win x-dnd tool-bar dnd fontset image regexp-opt fringe tabulated-list newcomment elisp-mode lisp-mode prog-mode register page menu-bar rfn-eshadow timer select scroll-bar mouse jit-lock font-lock syntax facemenu font-core frame cl-generic cham georgian utf-8-lang misc-lang vietnamese tibetan thai tai-viet lao korean japanese eucjp-ms cp51932 hebrew greek romanian slovak czech european ethiopic indian cyrillic chinese charscript case-table epa-hook jka-cmpr-hook help simple abbrev minibuffer cl-preloaded nadvice loaddefs button faces cus-face macroexp files text-properties overlay sha1 md5 base64 format env code-pages mule custom widget hashtable-print-readable backquote dbusbind inotify dynamic-setting system-font-setting font-render-setting x-toolkit x multi-tty make-network-process emacs) Memory information: ((conses 16 1651645 597548) (symbols 48 70565 14) (miscs 40 3875 4877) (strings 32 200962 89787) (string-bytes 1 6503680) (vectors 16 130612) (vector-slots 8 3417816 168105) (floats 8 11594 2168) (intervals 56 92902 10298) (buffers 976 497) (heap 1024 120587 60830))