GNU bug report logs - #19073
Ispell fails to initialise when hunspell does not report any loaded dictionaries

Previous Next

Package: emacs;

Reported by: Peter Oliver <lists.gnu.org <at> mavit.org.uk>

Date: Sun, 16 Nov 2014 17:51:03 UTC

Severity: normal

Tags: moreinfo

Done: Peter Oliver <lists.gnu.org <at> mavit.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 19073 in the body.
You can then email your comments to 19073 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#19073; Package emacs. (Sun, 16 Nov 2014 17:51:04 GMT) Full text and rfc822 format available.

Acknowledgement sent to Peter Oliver <lists.gnu.org <at> mavit.org.uk>:
New bug report received and forwarded. Copy sent to bug-gnu-emacs <at> gnu.org. (Sun, 16 Nov 2014 17:51:04 GMT) Full text and rfc822 format available.

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

From: Peter Oliver <lists.gnu.org <at> mavit.org.uk>
To: bug-gnu-emacs <at> gnu.org
Subject: Ispell fails to initialise when hunspell does not report any loaded
 dictionaries
Date: Sun, 16 Nov 2014 13:34:57 +0000 (GMT)
[Message part 1 (text/plain, inline)]
The build of Hunspell 1.3.2 at http://sourceforge.net/projects/ezwinports/files/ from doesn't output the "LOADED DICTIONARY:" section when "hunspell -D" is run.  I don't know if this is a bug in hunspell, or in the build, or if this feature is missing on Windows, or if there is some other reason.

In any case, this missing section confuses function ispell-find-hunspell-dictionaries in Emacs 24.4 (I'm using the build at http://sourceforge.net/projects/emacs-bin/files/releases/emacs-24.4-bin-i686-pc-mingw32.7z/download).  Variable hunspell-default-dict never gets set, meaning function ispell-parse-hunspell-affix-file ends up being called with a nil argument and erroring.

The attached patch gets things working again for me, although I must admit I don't understand the implications of not detecting a default dictionary.

If this patch is used, I believe that I will need to sign legal papers before patches from me can be accepted.  I am happy to do so.

-- 
Peter Oliver
[0001-Don-t-error-when-no-default-Hunspell-dictionary-is-d.patch (text/plain, attachment)]

Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#19073; Package emacs. (Mon, 17 Nov 2014 16:46:02 GMT) Full text and rfc822 format available.

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

From: Eli Zaretskii <eliz <at> gnu.org>
To: Peter Oliver <lists.gnu.org <at> mavit.org.uk>
Cc: 19073 <at> debbugs.gnu.org
Subject: Re: bug#19073: Ispell fails to initialise when hunspell does not
 report	any loaded dictionaries
Date: Mon, 17 Nov 2014 18:45:16 +0200
> Date: Sun, 16 Nov 2014 13:34:57 +0000 (GMT)
> From: Peter Oliver <lists.gnu.org <at> mavit.org.uk>
> 
> The build of Hunspell 1.3.2 at http://sourceforge.net/projects/ezwinports/files/ from doesn't 
> output the "LOADED DICTIONARY:" section when "hunspell -D" is run.

It does for me:

  D:\usr\eli>hunspell -a -D
  SEARCH PATH:
  .;;C:\Hunspell\;D:\usr\eli\.openoffice.org\3\user\wordbook;D:\usr\bin\..\share\hunspell;C:\Program files\OpenOffice.org 2.4\share\dict\ooo\;C:\Program files\OpenOffice.org 2.3\share\dict\ooo\;C:\Program files\OpenOffice.org 2.2\share\dict\ooo\;C:\Program files\OpenOffice.org 2.1\share\dict\ooo\;C:\Program files\OpenOffice.org 2.0\share\dict\ooo\
  AVAILABLE DICTIONARIES (path is not mandatory for -d option):
  D:\usr\bin\..\share\hunspell\default
  D:\usr\bin\..\share\hunspell\ENU
  D:\usr\bin\..\share\hunspell\en_GB
  D:\usr\bin\..\share\hunspell\en_US
  D:\usr\bin\..\share\hunspell\HEB
  D:\usr\bin\..\share\hunspell\he_IL
  D:\usr\bin\..\share\hunspell\ru_RU
  LOADED DICTIONARY:                         <<<<<<<<<<<<<<<<<
  D:\usr\bin\..\share\hunspell\default.aff   <<<<<<<<<<<<<<<<<
  D:\usr\bin\..\share\hunspell\default.dic   <<<<<<<<<<<<<<<<<
  @(#) International Ispell Version 3.2.06 (but really Hunspell 1.3.2)

> I don't know if this is a bug in hunspell, or in the build, or if
> this feature is missing on Windows, or if there is some other
> reason.

I'm guessing that you have an old binary of the ported Hunspell.
Please install the latest one from ezwinports and try again.  (I'm
using that myself with Emacs 24.4, and have absolutely no problems.)
This problem indeed existed in the original port, but once I started
using Emacs 24.4, I fixed it and uploaded a fixed binary (in April
this year).




Reply sent to Peter Oliver <lists.gnu.org <at> mavit.org.uk>:
You have taken responsibility. (Sat, 22 Nov 2014 20:21:02 GMT) Full text and rfc822 format available.

Notification sent to Peter Oliver <lists.gnu.org <at> mavit.org.uk>:
bug acknowledged by developer. (Sat, 22 Nov 2014 20:21:02 GMT) Full text and rfc822 format available.

Message #13 received at 19073-done <at> debbugs.gnu.org (full text, mbox):

From: Peter Oliver <lists.gnu.org <at> mavit.org.uk>
To: Eli Zaretskii <eliz <at> gnu.org>
Cc: 19073-done <at> debbugs.gnu.org
Subject: Re: bug#19073: Ispell fails to initialise when hunspell does not
 report any loaded dictionaries
Date: Sat, 22 Nov 2014 20:20:10 +0000 (GMT)
On Mon, 17 Nov 2014, Eli Zaretskii wrote:

> I'm guessing that you have an old binary of the ported Hunspell.
> Please install the latest one from ezwinports and try again.

You're quite right.  I mistakenly believed that because I had version 1.3.2, and the latest ezwinports version was 1.3.2, that I had the latest release.

Thanks.

-- 
Peter Oliver




bug archived. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Sun, 21 Dec 2014 12:24:04 GMT) Full text and rfc822 format available.

bug unarchived. Request was from PK <djc <at> resiak.org> to control <at> debbugs.gnu.org. (Wed, 28 Jan 2015 19:15:03 GMT) Full text and rfc822 format available.

Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#19073; Package emacs. (Wed, 28 Jan 2015 21:10:02 GMT) Full text and rfc822 format available.

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

From: PK <djc <at> resiak.org>
To: 19073 <at> debbugs.gnu.org
Subject: Re: bug#19073: Ispell fails to initialise when hunspell does not
 report any loaded dictionaries
Date: Wed, 28 Jan 2015 22:09:23 +0100
With relation to the discussion of this bug in gnu.emacs.bug: I've 
installed the latest ezwinport of hunspell 1.3.2 (suggested by Eli
Zaretskii) and ispell still fails with the "ispell-phaf ... nil" error
under my setup of emacs 24.4.1 (Windows), which I described in

    https://lists.gnu.org/archive/html/help-gnu-emacs/2014-04/msg00030.html

for Emacs 24.3, where the setup works fine with the same installation
of hunspell.  Is there an accepted fix to ispell.el under 24.4 for this?
Or an accepted compatible way to invoke ispell?  (Compatible across emacs
versions, that is.)

Clearly something changed for ispell between 24.3 and 24.4 that made my
setup stop working.  But if it's a change I should accommodate, I'd like
to know what to do, because that's not clear to me.

Thanks.

PK




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#19073; Package emacs. (Thu, 29 Jan 2015 03:50:02 GMT) Full text and rfc822 format available.

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

From: Eli Zaretskii <eliz <at> gnu.org>
To: djc <at> resiak.org
Cc: 19073 <at> debbugs.gnu.org
Subject: Re: bug#19073: Ispell fails to initialise when hunspell does not
 report	any loaded dictionaries
Date: Thu, 29 Jan 2015 05:49:04 +0200
> Date: Wed, 28 Jan 2015 22:09:23 +0100
> From: PK <djc <at> resiak.org>
> 
> With relation to the discussion of this bug in gnu.emacs.bug: I've 
> installed the latest ezwinport of hunspell 1.3.2 (suggested by Eli
> Zaretskii) and ispell still fails with the "ispell-phaf ... nil" error
> under my setup of emacs 24.4.1 (Windows), which I described in
> 
>      https://lists.gnu.org/archive/html/help-gnu-emacs/2014-04/msg00030.html
> 
> for Emacs 24.3, where the setup works fine with the same installation
> of hunspell.  Is there an accepted fix to ispell.el under 24.4 for this?

I am using that very version of Hunspell with Emacs 24.4 all the time,
in several different languages, and it works for me without any fixes.

> Or an accepted compatible way to invoke ispell?  (Compatible across emacs
> versions, that is.)

Emacs 24.4 did change significantly how dictionaries are set up with
Hunspell, so it might be hard to find a setup that works the same with
prior versions.

I suspect your setup is the culprit.  In particular, try in "emacs -Q"
or without your ispell-local-dictionary-alist setting.  It's not
needed anymore.




bug archived. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Thu, 26 Feb 2015 12:24:04 GMT) Full text and rfc822 format available.

This bug report was last modified 10 years and 175 days ago.

Previous Next


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