[OS X Emacs] debugger entered

Win Treese treese at acm.org
Tue Apr 2 17:08:43 EDT 2019


savehist.el saves a set of minibuffer history lists, and the list of variables to be saved is savehist-minibuffer-history-variables. In lisp/replace.el, the local variable query-replace-from-to-history is inadvertently added to the list.

In Emacs 26.1, the relevant code has changed quite a bit, so I suspect that it has gone away in the core code one way or another. 

As a workaround, I suspect, but I haven’t proved, that:

(add-hook 'savehist-save-hook
   (lambda () (delete 'query-replace-from-to-history savehist-minibuffer-history-variables)))

might avoid the error.

 - Win

> On Apr 1, 2019, at 8:39 PM, Tom Van Vleck <thvv at multicians.org> wrote:
> 
> Aquamacs 3.4  GNU Emacs 25.3.50.1 (x86_64-apple-darwin14.5.0, NS appkit-1348.17 Version 10.10.5 (Build 14F27))
> macOS Mojave 10.14.3
> 
> 
> This seems to happen when I am typing in a long regexp into the minibuffer for replace-regexp, 
> and get interrupted, and some kind of autosave timer goes off.
> I have seen it on High Sierra and maybe earlier.
> 
> Debugger entered--Lisp error: (wrong-type-argument listp query-replace-from-to-history)
>  savehist-save(t)
>  savehist-autosave()
>  apply(savehist-autosave nil)
>  timer-event-handler([t 23714 44340 679375 300 savehist-autosave nil nil 896500])
>  read-from-minibuffer(#("Replace regexp (default (.*)): " 28 29 (separator t display #(" → " 0 3 (face minibuffer-prompt)))) nil nil nil query-replace-from-to-history ("1" "\\_<1\\_>" "amazon") t)
>  read-regexp(#("Replace regexp (default (.*)): " 28 29 (separator t display #(" → " 0 3 (face minibuffer-prompt)))) nil query-replace-from-to-history)
>  query-replace-read-from("Replace regexp" t)
>  query-replace-read-args("Replace regexp" t)
>  (let ((common (query-replace-read-args (concat "Replace" (if current-prefix-arg (if (eq current-prefix-arg ...) " backward" " word") "") " regexp" (if (use-region-p) " in region" "")) t))) (list (nth 0 common) (nth 1 common) (nth 2 common) (if (use-region-p) (region-beginning)) (if (use-region-p) (region-end)) (nth 3 common)))
>  call-interactively(replace-regexp nil nil)
>  command-execute(replace-regexp)
> 
> 
> _____________________________________________________________
> MacOSX-Emacs mailing list
> MacOSX-Emacs at email.esm.psu.edu
> https://email.esm.psu.edu/mailman/listinfo/macosx-emacs
> List Archives: http://dir.gmane.org/gmane.emacs.macintosh.osx



More information about the MacOSX-Emacs mailing list