GNU bug report logs - #23625
viper-tests.el fails in master

Previous Next

Package: emacs;

Reported by: Paul Eggert <eggert <at> cs.ucla.edu>

Date: Thu, 26 May 2016 20:35:02 UTC

Severity: normal

Fixed in version 25.1

Done: Phillip Lord <phillip.lord <at> russet.org.uk>

Bug is archived. No further changes may be made.

To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 23625 in the body.
You can then email your comments to 23625 AT debbugs.gnu.org in the normal way.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to bug-gnu-emacs <at> gnu.org:
bug#23625; Package emacs. (Thu, 26 May 2016 20:35:02 GMT) Full text and rfc822 format available.

Acknowledgement sent to Paul Eggert <eggert <at> cs.ucla.edu>:
New bug report received and forwarded. Copy sent to bug-gnu-emacs <at> gnu.org. (Thu, 26 May 2016 20:35:02 GMT) Full text and rfc822 format available.

Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Paul Eggert <eggert <at> cs.ucla.edu>
To: Phillip Lord <phillip.lord <at> russet.org.uk>
Cc: Emacs bug reports <bug-gnu-emacs <at> gnu.org>
Subject: viper-tests.el fails in master
Date: Thu, 26 May 2016 13:33:53 -0700
[Message part 1 (text/plain, inline)]
Phillip, I just now merged emacs-25 into master and fixed all the merge 
conflicts that were easy, but one problem remains: viper-tests, which 
you recently introduced to emacs-25, fails in the new master. Could you 
please look into this? I don't offhand know what viper-tests is supposed 
to do and don't know how to interpret the test failures. Thanks.

The symptoms with Emacs master commit 
9a834970e822db10bc887db343fd8561a3639a66 compiled for Fedora 23 x86-64, 
are that 'make check' fails with the attached output seemingly being the 
relevant part of the output. This attachment contains some control 
characters; I hope they survive the email process.

(Is there any way to fix the test so that it outputs ordinary text when 
it fails?)

[viper-test-log.txt (text/plain, attachment)]

Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#23625; Package emacs. (Thu, 26 May 2016 21:39:01 GMT) Full text and rfc822 format available.

Message #8 received at submit <at> debbugs.gnu.org (full text, mbox):

From: phillip.lord <at> russet.org.uk (Phillip Lord)
To: Paul Eggert <eggert <at> cs.ucla.edu>
Cc: 23625 <at> debbugs.gnu.org, Emacs bug reports <bug-gnu-emacs <at> gnu.org>,
 Stefan Monnier <monnier <at> iro.umontreal.ca>
Subject: Re: viper-tests.el fails in master
Date: Thu, 26 May 2016 22:38:23 +0100
[Message part 1 (text/plain, inline)]
Paul Eggert <eggert <at> cs.ucla.edu> writes:

> Phillip, I just now merged emacs-25 into master and fixed all the merge
> conflicts that were easy, but one problem remains: viper-tests, which you
> recently introduced to emacs-25, fails in the new master. Could you please
> look into this? I don't offhand know what viper-tests is supposed to do and
> don't know how to interpret the test failures. Thanks.

They are "do this, do that" keyboard macros. Hard to explain what they
do other than "this is how viper is supposed to behave".

Anyway, I think that the tests are working -- that is, they are picking
up a real bug, caused independently by 088acab3 which was from Stefan.
I've attached a fix. Stefan, can you check I have this right?

> (Is there any way to fix the test so that it outputs ordinary text when it
> fails?)

>   #[nil "\301 \210\30!\207" [before-buffer toggle-viper-mode switch-

You mean this bit? To be honest I am not sure where that bit of trace is
coming from.

Phil

[0001-Fix-broken-viper-deactivation.patch (text/x-diff, inline)]
From 76409ca9daf72b697db9c1983aa322a365bfc066 Mon Sep 17 00:00:00 2001
From: Phillip Lord <phillip.lord <at> russet.org.uk>
Date: Thu, 26 May 2016 22:18:32 +0100
Subject: [PATCH] Fix broken viper deactivation

* lisp/emulation/viper.el (viper--deactivate-advice-list): Destructure
  args to advice-remove.
  (viper--advice-add): Use cons not list.
Addresses bug#23625
---
 lisp/emulation/viper.el | 8 ++++++--
 1 file changed, 6 insertions(+), 2 deletions(-)

diff --git a/lisp/emulation/viper.el b/lisp/emulation/viper.el
index a0bba9a..1ee1464 100644
--- a/lisp/emulation/viper.el
+++ b/lisp/emulation/viper.el
@@ -647,10 +647,14 @@ viper--advice-list
 
 (defun viper--advice-add (function where advice)
   (advice-add function where advice)
-  (push (list function advice) viper--advice-list))
+  (push (cons function advice) viper--advice-list))
 
 (defun viper--deactivate-advice-list ()
-  (mapc #'advice-remove viper--advice-list)
+  (mapc (lambda (n)
+          (advice-remove
+           (car n)
+           (cdr n)))
+        viper--advice-list)
   (setq viper--advice-list nil))
 
 (defun viper-go-away ()
-- 
2.8.3


Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#23625; Package emacs. (Thu, 26 May 2016 21:39:01 GMT) Full text and rfc822 format available.

Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#23625; Package emacs. (Fri, 27 May 2016 13:16:02 GMT) Full text and rfc822 format available.

Message #14 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Andy Moreton <andrewjmoreton <at> gmail.com>
To: bug-gnu-emacs <at> gnu.org
Subject: Re: bug#23625: viper-tests.el fails in master
Date: Fri, 27 May 2016 14:14:44 +0100
On Thu 26 May 2016, Paul Eggert wrote:

> Phillip, I just now merged emacs-25 into master and fixed all the merge
> conflicts that were easy, but one problem remains: viper-tests, which you
> recently introduced to emacs-25, fails in the new master. Could you please
> look into this? I don't offhand know what viper-tests is supposed to do and
> don't know how to interpret the test failures. Thanks.
>
> The symptoms with Emacs master commit 9a834970e822db10bc887db343fd8561a3639a66
> compiled for Fedora 23 x86-64, are that 'make check' fails with the attached
> output seemingly being the relevant part of the output. This attachment
> contains some control characters; I hope they survive the email process.
>
> (Is there any way to fix the test so that it outputs ordinary text when it
> fails?)

The control characters are from backtraces in the log - I assuem that
this is the bytecode representation from compiled elisp files.

    AndyM





Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#23625; Package emacs. (Fri, 27 May 2016 14:57:01 GMT) Full text and rfc822 format available.

Message #17 received at 23625 <at> debbugs.gnu.org (full text, mbox):

From: Stefan Monnier <monnier <at> IRO.UMontreal.CA>
To: phillip.lord <at> russet.org.uk (Phillip Lord)
Cc: 23625 <at> debbugs.gnu.org, Emacs bug reports <bug-gnu-emacs <at> gnu.org>,
 Paul Eggert <eggert <at> cs.ucla.edu>
Subject: Re: viper-tests.el fails in master
Date: Fri, 27 May 2016 10:56:39 -0400
> Anyway, I think that the tests are working -- that is, they are picking
> up a real bug, caused independently by 088acab3 which was from Stefan.
> I've attached a fix. Stefan, can you check I have this right?

Indeed, thanks, the patch looks fine.  The use of `list` instead of
`cons` was because I intended to do

    (mapc (apply-partially #'apply #'advice-remove) viper--advice-list)

but your code is at least as good.


        Stefan




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#23625; Package emacs. (Fri, 27 May 2016 14:58:02 GMT) Full text and rfc822 format available.

bug marked as fixed in version 25.1, send any further explanations to 23625 <at> debbugs.gnu.org and Paul Eggert <eggert <at> cs.ucla.edu> Request was from Phillip Lord <phillip.lord <at> russet.org.uk> to control <at> debbugs.gnu.org. (Fri, 27 May 2016 15:55:02 GMT) Full text and rfc822 format available.

bug archived. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Sat, 25 Jun 2016 11:24:04 GMT) Full text and rfc822 format available.

This bug report was last modified 8 years and 356 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.