GNU bug report logs - #34019
26.1; Changing ispell-program-name causes unwanted behavior

Previous Next

Package: emacs;

Reported by: philip <at> warpmail.net (Philip K.)

Date: Wed, 9 Jan 2019 00:15:02 UTC

Severity: minor

Tags: patch

Found in version 26.1

Done: Eli Zaretskii <eliz <at> gnu.org>

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: Eli Zaretskii <eliz <at> gnu.org>
Cc: tracker <at> debbugs.gnu.org
Subject: bug#34019: closed (26.1; Changing ispell-program-name causes
 unwanted behavior)
Date: Sat, 12 Jan 2019 11:30:02 +0000
[Message part 1 (text/plain, inline)]
Your message dated Sat, 12 Jan 2019 13:28:33 +0200
with message-id <83lg3qf732.fsf <at> gnu.org>
and subject line Re: bug#34019: 26.1; Changing ispell-program-name causes unwanted behavior
has caused the debbugs.gnu.org bug report #34019,
regarding 26.1; Changing ispell-program-name causes unwanted behavior
to be marked as done.

(If you believe you have received this mail in error, please contact
help-debbugs <at> gnu.org.)


-- 
34019: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=34019
GNU Bug Tracking System
Contact help-debbugs <at> gnu.org with problems
[Message part 2 (message/rfc822, inline)]
From: philip <at> warpmail.net (Philip K.)
To: bug-gnu-emacs <at> gnu.org
Subject: 26.1; Changing ispell-program-name causes unwanted behavior
Date: Wed, 09 Jan 2019 01:01:18 +0100
[Message part 3 (text/plain, inline)]
Hello,

I've recently updated my Debian installation from stretch (9, stable) to
buster (10, testing) and I got to install Emacs 26.1 + enchant. But
sadly the version in the Debian repository is still too old (1.6 vs
2.1). But when changing back to aspell, I was informed that aspell was
too old (0.6 vs 2.1).

It's easy to reproduce the bug, assuming one's enchant is also too
old. Simply eval

	(setq-default ispell-program-name (executable-find "enchant"))

try spell-checking any word (which should lead to an error), followed by

	(setq-default ispell-program-name (executable-find "aspell"))

or whatever one was using before. Any spell-checking should still not
work, and an error will be reported no matter what version of
aspell/hunspell/ispell one uses.

Looking through the code I noticed that the issue was simply caused by
forgetting to reset the variable `ispell-really-enchant`, thus resetting
it fixes the issue.

I hope I haven't messed something up in the process, since this is the
first time I'm sending a patch. If that's not the case, please tell me
and I'll be eager to fix any issue (related to this bug).

	Sincerely,
	Philip K.
    https://zge.us.to

[0001-re-initialize-ispell-really-enchant-properly.patch (text/x-diff, inline)]
From 25e0c36e60ee9737e92994684887fe9a4062b0cc Mon Sep 17 00:00:00 2001
From: Philip K <philip <at> warpmail.net>
Date: Wed, 9 Jan 2019 00:37:48 +0100
Subject: [PATCH] (re-)initialize ispell-really-enchant properly
To: bug-gnu-emacs <at> gnu.org

* lisp/textmodes/ispell.el: adding missing variable that should have
  been reset
---
 lisp/textmodes/ispell.el | 1 +
 1 file changed, 1 insertion(+)

diff --git a/lisp/textmodes/ispell.el b/lisp/textmodes/ispell.el
index 22047598b2..0b07254af4 100644
--- a/lisp/textmodes/ispell.el
+++ b/lisp/textmodes/ispell.el
@@ -726,7 +726,7 @@ ispell-check-version
 	;; Make sure these variables are (re-)initialized to the default value
 	(setq ispell-really-aspell nil
               ispell-really-hunspell nil
+              ispell-really-enchant nil
 	      ispell-encoding8-command nil)
 
 	(goto-char (point-min))
---
2.20.1

[signature.asc (application/pgp-signature, inline)]
[Message part 6 (message/rfc822, inline)]
From: Eli Zaretskii <eliz <at> gnu.org>
To: philip <at> warpmail.net (Philip K.)
Cc: 34019-done <at> debbugs.gnu.org
Subject: Re: bug#34019: 26.1;
 Changing ispell-program-name causes unwanted behavior
Date: Sat, 12 Jan 2019 13:28:33 +0200
> From: philip <at> warpmail.net (Philip K.)
> Date: Wed, 09 Jan 2019 01:01:18 +0100
> 
> I've recently updated my Debian installation from stretch (9, stable) to
> buster (10, testing) and I got to install Emacs 26.1 + enchant. But
> sadly the version in the Debian repository is still too old (1.6 vs
> 2.1). But when changing back to aspell, I was informed that aspell was
> too old (0.6 vs 2.1).
> 
> It's easy to reproduce the bug, assuming one's enchant is also too
> old. Simply eval
> 
> 	(setq-default ispell-program-name (executable-find "enchant"))
> 
> try spell-checking any word (which should lead to an error), followed by
> 
> 	(setq-default ispell-program-name (executable-find "aspell"))
> 
> or whatever one was using before. Any spell-checking should still not
> work, and an error will be reported no matter what version of
> aspell/hunspell/ispell one uses.
> 
> Looking through the code I noticed that the issue was simply caused by
> forgetting to reset the variable `ispell-really-enchant`, thus resetting
> it fixes the issue.

Thanks, pushed to the emacs-26 branch, and will appear in Emacs 26.2.

> I hope I haven't messed something up in the process, since this is the
> first time I'm sending a patch. If that's not the case, please tell me
> and I'll be eager to fix any issue (related to this bug).

The commit log message should state the function in which the change
was made.  See the commit I actually made.  Otherwise, the patch was
OK, but for some reason it "git am" didn't apply it; perhaps because
you seem to have customized the number of context lines?


This bug report was last modified 6 years and 134 days ago.

Previous Next


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