GNU bug report logs - #20972
25.0.50; eieio-persistent broken

Previous Next

Package: emacs;

Reported by: Jan Tatarik <jan.tatarik <at> gmail.com>

Date: Fri, 3 Jul 2015 11:35:02 UTC

Severity: normal

Found in version 25.0.50

Done: Stefan Monnier <monnier <at> IRO.UMontreal.CA>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: help-debbugs <at> gnu.org (GNU bug Tracking System)
To: Jan Tatarik <jan.tatarik <at> gmail.com>
Subject: bug#20972: closed (Re: bug#20972: 25.0.50; eieio-persistent broken)
Date: Mon, 06 Jul 2015 15:57:02 +0000
[Message part 1 (text/plain, inline)]
Your bug report

#20972: 25.0.50; eieio-persistent broken

which was filed against the emacs package, has been closed.

The explanation is attached below, along with your original report.
If you require more details, please reply to 20972 <at> debbugs.gnu.org.

-- 
20972: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=20972
GNU Bug Tracking System
Contact help-debbugs <at> gnu.org with problems
[Message part 2 (message/rfc822, inline)]
From: Stefan Monnier <monnier <at> IRO.UMontreal.CA>
To: Jan Tatarik <jan.tatarik <at> gmail.com>
Cc: 20972-done <at> debbugs.gnu.org
Subject: Re: bug#20972: 25.0.50; eieio-persistent broken
Date: Mon, 06 Jul 2015 11:56:49 -0400
[ Please keep the "Cc:".  ]

>> I'm not 100% sure what the code *should* do, but can you try the patch
>> below for you use case and confirm that it does the right thing for you?
> Yes, this works fine, thanks.

Thanks for confirming.  Installed into "master".


        Stefan

[Message part 3 (message/rfc822, inline)]
From: Jan Tatarik <jan.tatarik <at> gmail.com>
To: bug-gnu-emacs <at> gnu.org
Subject: 25.0.50; eieio-persistent broken
Date: Fri, 03 Jul 2015 13:34:22 +0200
The commit a0010db41ca83a8211162b649e679162dd4153a6 has broken eieio
persistence.

Besides my own stuff, it affects gnus registry - just lost my registry
file, because gnus couldn't read the registry file, so it created a new,
empty one...

I found three issues, the recipe can be reproduced with emacs -Q:

(require 'eieio)
(require 'eieio-base)

(defclass test-persist (eieio-persistent)
  ((slot :initarg :slot :type string))
  "Test class.")

;; In theory, calling it like this should override the :file slot
;; defined in eieio-persistent
(eieio-persistent-save (test-persist :slot "foo") "/tmp/test.eieio")

;; But when no :file has been specified, it breaks
;; Debugger entered--Lisp error: (unbound-slot test-persist "#<test-persist test-persist>" file oref)

;; with explicit :file it works
(eieio-persistent-save (test-persist :file "/tmp/test.eieio" :slot "foo"))

;; But this stores the file in :file, no override takes place, contrary to the docs
(eieio-persistent-save (test-persist :file "/tmp/test.eieio" :slot "foo")
                        "/tmp/another_file.eieio")


;; And finally, the most important issue - we cannot read the files back in
(eieio-persistent-read "/tmp/test.eieio")
;; Debugger entered--Lisp error: (wrong-type-argument arrayp test-persist)


The first two issues (if they are issues), must have been already
present for some time.

The eieio-persistent-read was caused by the latest changes to eieio
(tested with 8bab1490f14207eeeee4b2f4ad30b5d695db8245 and it still
worked).



This bug report was last modified 9 years and 325 days ago.

Previous Next


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