GNU bug report logs - #24050
24.5; ispell-change-dictionary suggests non-existent dicts (aspell)

Please note: This is a static page, with minimal formatting, updated once a day.
Click here to see this page with the latest information and nicer formatting.

Package: emacs; Severity: minor; Reported by: Ole Jørgen Brønner <olejorgenb@HIDDEN>; dated Thu, 21 Jul 2016 22:01:02 UTC; Maintainer for emacs is bug-gnu-emacs@HIDDEN.

Message received at 24050 <at> debbugs.gnu.org:


Received: (at 24050) by debbugs.gnu.org; 30 Jul 2019 14:43:07 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Tue Jul 30 10:43:06 2019
Received: from localhost ([127.0.0.1]:51008 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1hsTLG-0007qd-Lm
	for submit <at> debbugs.gnu.org; Tue, 30 Jul 2019 10:43:06 -0400
Received: from eggs.gnu.org ([209.51.188.92]:52089)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <eliz@HIDDEN>) id 1hsTLE-0007q9-Ca
 for 24050 <at> debbugs.gnu.org; Tue, 30 Jul 2019 10:43:05 -0400
Received: from fencepost.gnu.org ([2001:470:142:3::e]:60933)
 by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from <eliz@HIDDEN>)
 id 1hsTL9-0006JS-0u; Tue, 30 Jul 2019 10:42:59 -0400
Received: from [176.228.60.248] (port=1491 helo=home-c4e4a596f7)
 by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256)
 (Exim 4.82) (envelope-from <eliz@HIDDEN>)
 id 1hsTL8-0004xH-4U; Tue, 30 Jul 2019 10:42:58 -0400
Date: Tue, 30 Jul 2019 17:42:47 +0300
Message-Id: <834l33k2hk.fsf@HIDDEN>
From: Eli Zaretskii <eliz@HIDDEN>
To: Lars Ingebrigtsen <larsi@HIDDEN>
In-reply-to: <m336invkb9.fsf@HIDDEN> (message from Lars Ingebrigtsen on Tue, 
 30 Jul 2019 13:22:18 +0200)
Subject: Re: bug#24050: 24.5; ispell-change-dictionary suggests non-existent
 dicts (aspell)
References: <CA+MVPv5Dk=Y=atXVeL3KNWxjxdVa0a2rAQ2zNvWOLXTEc-Uwqw@HIDDEN>
 <87k1c2cv77.fsf@HIDDEN> <83h876kzv1.fsf@HIDDEN>
 <m3pnlu44nw.fsf@HIDDEN> <83d0hukya1.fsf@HIDDEN>
 <m3lfwi42ol.fsf@HIDDEN> <83a7cyku2k.fsf@HIDDEN>
 <m336ipxfg0.fsf@HIDDEN> <83o91ckhib.fsf@HIDDEN> <m336invkb9.fsf@HIDDEN>
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic]
X-Spam-Score: -2.3 (--)
X-Debbugs-Envelope-To: 24050
Cc: 24050 <at> debbugs.gnu.org, olejorgenb@HIDDEN
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -3.3 (---)

> From: Lars Ingebrigtsen <larsi@HIDDEN>
> Cc: olejorgenb@HIDDEN,  24050 <at> debbugs.gnu.org
> Date: Tue, 30 Jul 2019 13:22:18 +0200
> 
> > So all of this is ... complicated.  And since the original complaint
> > is about the completion candidates shown by ispell-change-directory, I
> > think we should solve that problem by tweaking only the completion,
> > not the data structures it uses.  If you agree, maybe you or someone
> > else could come up with an alternative patch which only modified how
> > the collection of completion candidates is calculated.
> 
> A different option might be to use the current way of doing the
> completion candidates, but mark (for instance in bold) the ones that
> aspell/hunspell has said are available on the system.

Yes.  Although that would be different from the way we display
completion candidates in other cases, and might require inline
explanation.




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#24050; Package emacs. Full text available.

Message received at 24050 <at> debbugs.gnu.org:


Received: (at 24050) by debbugs.gnu.org; 30 Jul 2019 11:22:23 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Tue Jul 30 07:22:23 2019
Received: from localhost ([127.0.0.1]:49639 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1hsQD1-0006xg-06
	for submit <at> debbugs.gnu.org; Tue, 30 Jul 2019 07:22:23 -0400
Received: from quimby.gnus.org ([80.91.231.51]:59666)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <larsi@HIDDEN>) id 1hsQCz-0006xZ-On
 for 24050 <at> debbugs.gnu.org; Tue, 30 Jul 2019 07:22:22 -0400
Received: from cm-84.212.202.86.getinternet.no ([84.212.202.86] helo=stories)
 by quimby.gnus.org with esmtpsa
 (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.89)
 (envelope-from <larsi@HIDDEN>)
 id 1hsQCw-00075p-8V; Tue, 30 Jul 2019 13:22:20 +0200
From: Lars Ingebrigtsen <larsi@HIDDEN>
To: Eli Zaretskii <eliz@HIDDEN>
Subject: Re: bug#24050: 24.5; ispell-change-dictionary suggests non-existent
 dicts (aspell)
References: <CA+MVPv5Dk=Y=atXVeL3KNWxjxdVa0a2rAQ2zNvWOLXTEc-Uwqw@HIDDEN>
 <87k1c2cv77.fsf@HIDDEN> <83h876kzv1.fsf@HIDDEN>
 <m3pnlu44nw.fsf@HIDDEN> <83d0hukya1.fsf@HIDDEN>
 <m3lfwi42ol.fsf@HIDDEN> <83a7cyku2k.fsf@HIDDEN>
 <m336ipxfg0.fsf@HIDDEN> <83o91ckhib.fsf@HIDDEN>
Face: iVBORw0KGgoAAAANSUhEUgAAADAAAAAwBAMAAAClLOS0AAAAElBMVEUrCQWDGAQOAwPJIwLV
 JgLXXz9b40YKAAACVElEQVQ4jV2US3IjIQyGJTqzl1DPXsgXAIsDuAuyT01N7n+VEZ3Y8Ri7qwwf
 evyS2pBwn/fVH7+aAYDKz8F9ZYNkBvpKRlEgs2L7/DzXezx/F0kGsyqnVzACcNKa+ngBEcOgj9br
 i6tqgGe06+djnWAk2L5A/1/HzLDfQXz8Gcw7GP1ZDX8D2t39GTj0SassDMKnJ7+DpdIsoZW0yZzH
 d9ARFkzItlGxLVK/GT5czSGxdYIeZ4fqV9DTsnJWQV/mB4J8gZXKESEk8k37oIufkhPsI2y8WZ8N
 EzfSxuuqwdsCM1OvKzsAk+XqyAGW4mx7Xc3EaizuqyThcb/1atK9qqGEXNOxX8+y35gMnJLa5sJK
 pSEtMGqOVno2tcLYkBlguRq2wuI4CDUSc9JeS10xrnE1kUeOnAp5Yzm2CtyjPiWXjH4zpkLDWVoh
 SG/RYM1m0toSyN3z3lABl4qSAQMgMW0yaB9QoMwptWTFzVnZXbxGmQSg9AaAtXBxTtsCDcJVgsuc
 yCrKpVHo8zCIYRM9wUgbEbToe/dhLZluvJRvBwq3xpGnt6aerEiDqL4E8Ijt65tQspXm0GK4jnRp
 0tb1HlBq49HDYkStpY5jwxpDyuC3JrMDMcaN5j7Yr6tDuoo1J5Sr+tVCwW2rV/FxMIeLGLgLMUcn
 MCrKY83ngT3CTVDVKPvvnxfns07Z6w6WlEzenwjFa2kIRl7F3/HJAldDozD7Ebtf9+OPeGxNmOnO
 a/vxBPIJ8Mhr++cb/InfJwA0DVoSrkEFu684L5zsIrnwiL+JB/gHNzzIbvr5IfcAAAAASUVORK5C
 YII=
Date: Tue, 30 Jul 2019 13:22:18 +0200
In-Reply-To: <83o91ckhib.fsf@HIDDEN> (Eli Zaretskii's message of "Mon, 29 Jul
 2019 18:06:04 +0300")
Message-ID: <m336invkb9.fsf@HIDDEN>
User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (gnu/linux)
MIME-Version: 1.0
Content-Type: text/plain
X-Spam-Report: Spam detection software, running on the system "quimby.gnus.org",
 has NOT identified this incoming email as spam.  The original
 message has been attached to this so you can view it or label
 similar future email.  If you have any questions, see
 @@CONTACT_ADDRESS@@ for details.
 Content preview:  Eli Zaretskii <eliz@HIDDEN> writes: > Not necessarily,
 because
 the dictionary can be specified as a full > absolute file name. Also,
 ispell-dictionary-alist
 provides for > specifying command-line options for the speller, and some
 of tho [...] 
 Content analysis details:   (-2.9 points, 5.0 required)
 pts rule name              description
 ---- ---------------------- --------------------------------------------------
 -1.0 ALL_TRUSTED            Passed through trusted hosts only via SMTP
 -1.9 BAYES_00               BODY: Bayes spam probability is 0 to 1%
 [score: 0.0000]
X-Spam-Score: 0.0 (/)
X-Debbugs-Envelope-To: 24050
Cc: 24050 <at> debbugs.gnu.org, olejorgenb@HIDDEN
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -1.0 (-)

Eli Zaretskii <eliz@HIDDEN> writes:

> Not necessarily, because the dictionary can be specified as a full
> absolute file name.  Also, ispell-dictionary-alist provides for
> specifying command-line options for the speller, and some of those
> could instruct the speller to look for the dictionary in a
> non-standard directory, where the speller doesn't look when we query
> it about installed dictionaries.

OK; I see now that this is more complicated than I assumed.  Thanks for
explaining.  I've now reverted the patch and reopened the bug.

>> With the patch, ispell-change-directory (on this system) seems to list
>> all the dictionaries it can use.  This is quite useful, because now that
>> command allows me to actually choose the dictionary variant I most want
>> to use, which was impossible before when they were hidden among all the
>> dictionaries Emacs was claiming I could use (but can't).
>
> I see your point and agree with the convenience part, but
> unfortunately things are not as simple as they seem.
>
> First, if this kind of filtering of the potentially available
> dictionaries should happen, its place is in
> ispell-valid-dictionary-list, not where the proposed change was made.

Right.

> So all of this is ... complicated.  And since the original complaint
> is about the completion candidates shown by ispell-change-directory, I
> think we should solve that problem by tweaking only the completion,
> not the data structures it uses.  If you agree, maybe you or someone
> else could come up with an alternative patch which only modified how
> the collection of completion candidates is calculated.

A different option might be to use the current way of doing the
completion candidates, but mark (for instance in bold) the ones that
aspell/hunspell has said are available on the system.

> (And btw, I think it is a mistake to call completing-read with
> MUST-MATCH argument non-nil here, because it prevents users from
> typing a full absolute file name of the dictionary, an entirely valid
> and useful response.)

Yup.

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#24050; Package emacs. Full text available.
Removed tag(s) fixed. Request was from Lars Ingebrigtsen <larsi@HIDDEN> to control <at> debbugs.gnu.org. Full text available.
bug No longer marked as fixed in versions 27.1 and reopened. Request was from Debbugs Internal Request <help-debbugs@HIDDEN> to internal_control <at> debbugs.gnu.org. Full text available.

Message received at 24050 <at> debbugs.gnu.org:


Received: (at 24050) by debbugs.gnu.org; 29 Jul 2019 15:06:30 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Mon Jul 29 11:06:29 2019
Received: from localhost ([127.0.0.1]:48955 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1hs7EL-0004o6-AU
	for submit <at> debbugs.gnu.org; Mon, 29 Jul 2019 11:06:29 -0400
Received: from eggs.gnu.org ([209.51.188.92]:56981)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <eliz@HIDDEN>) id 1hs7EH-0004np-Iv
 for 24050 <at> debbugs.gnu.org; Mon, 29 Jul 2019 11:06:28 -0400
Received: from fencepost.gnu.org ([2001:470:142:3::e]:45418)
 by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from <eliz@HIDDEN>)
 id 1hs7EC-0002Xx-Gb; Mon, 29 Jul 2019 11:06:20 -0400
Received: from [176.228.60.248] (port=2793 helo=home-c4e4a596f7)
 by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256)
 (Exim 4.82) (envelope-from <eliz@HIDDEN>)
 id 1hs7EB-000154-93; Mon, 29 Jul 2019 11:06:20 -0400
Date: Mon, 29 Jul 2019 18:06:04 +0300
Message-Id: <83o91ckhib.fsf@HIDDEN>
From: Eli Zaretskii <eliz@HIDDEN>
To: Lars Ingebrigtsen <larsi@HIDDEN>
In-reply-to: <m336ipxfg0.fsf@HIDDEN> (message from Lars Ingebrigtsen on Mon, 
 29 Jul 2019 13:12:15 +0200)
Subject: Re: bug#24050: 24.5; ispell-change-dictionary suggests non-existent
 dicts (aspell)
References: <CA+MVPv5Dk=Y=atXVeL3KNWxjxdVa0a2rAQ2zNvWOLXTEc-Uwqw@HIDDEN>
 <87k1c2cv77.fsf@HIDDEN> <83h876kzv1.fsf@HIDDEN>
 <m3pnlu44nw.fsf@HIDDEN> <83d0hukya1.fsf@HIDDEN>
 <m3lfwi42ol.fsf@HIDDEN> <83a7cyku2k.fsf@HIDDEN>
 <m336ipxfg0.fsf@HIDDEN>
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic]
X-Spam-Score: -2.3 (--)
X-Debbugs-Envelope-To: 24050
Cc: 24050 <at> debbugs.gnu.org, olejorgenb@HIDDEN
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -3.3 (---)

> From: Lars Ingebrigtsen <larsi@HIDDEN>
> Cc: olejorgenb@HIDDEN,  24050 <at> debbugs.gnu.org
> Date: Mon, 29 Jul 2019 13:12:15 +0200
> 
> Eli Zaretskii <eliz@HIDDEN> writes:
> 
> > If aspell/hunspell is misconfigured, or has some bug, it might not
> > output the correct list of installed dictionaries, or not at all.
> 
> But if it's misconfigured, then it'll bug out when you ask it to do
> other things as well, as hitting `M-$'.

Not necessarily, because the dictionary can be specified as a full
absolute file name.  Also, ispell-dictionary-alist provides for
specifying command-line options for the speller, and some of those
could instruct the speller to look for the dictionary in a
non-standard directory, where the speller doesn't look when we query
it about installed dictionaries.

> With the patch, ispell-change-directory (on this system) seems to list
> all the dictionaries it can use.  This is quite useful, because now that
> command allows me to actually choose the dictionary variant I most want
> to use, which was impossible before when they were hidden among all the
> dictionaries Emacs was claiming I could use (but can't).

I see your point and agree with the convenience part, but
unfortunately things are not as simple as they seem.

First, if this kind of filtering of the potentially available
dictionaries should happen, its place is in
ispell-valid-dictionary-list, not where the proposed change was made.

Second, ispell-find-aspell-dictionaries was (before the change you
made) modifying in-place the entries for the dictionaries it found
(and now it doesn't -- this could be a bug in itself in some other use
case), so after ispell-find-aspell-dictionaries returned,
ispell-dictionary-base-alist had some of its entries modified to adapt
them to the underlying installation.  Thus, you cannot disregard
ispell-dictionary-base-alist, because it includes other valuable
information, and at least part of it is not theoretical, it reflects
what the underlying system has installed.

Third, by ignoring ispell-dictionary-base-alist, you make it
impossible to install a dictionary while Emacs is running with
ispell.el loaded.

So all of this is ... complicated.  And since the original complaint
is about the completion candidates shown by ispell-change-directory, I
think we should solve that problem by tweaking only the completion,
not the data structures it uses.  If you agree, maybe you or someone
else could come up with an alternative patch which only modified how
the collection of completion candidates is calculated.  (And btw, I
think it is a mistake to call completing-read with MUST-MATCH argument
non-nil here, because it prevents users from typing a full absolute
file name of the dictionary, an entirely valid and useful response.)

OK?




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#24050; Package emacs. Full text available.

Message received at 24050 <at> debbugs.gnu.org:


Received: (at 24050) by debbugs.gnu.org; 29 Jul 2019 14:33:02 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Mon Jul 29 10:33:02 2019
Received: from localhost ([127.0.0.1]:48895 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1hs6hx-0001nM-VS
	for submit <at> debbugs.gnu.org; Mon, 29 Jul 2019 10:33:02 -0400
Received: from neon-v1.ccupm.upm.es ([138.100.198.71]:36140)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <agustin.martin@HIDDEN>) id 1hs6ht-0001ms-CU
 for 24050 <at> debbugs.gnu.org; Mon, 29 Jul 2019 10:33:00 -0400
Received: from agmartin.aq.upm.es (Agmartin.aq.upm.es [138.100.41.131])
 (user=agustin.martin@HIDDEN mech=LOGIN bits=0)
 by neon-v1.ccupm.upm.es (8.14.4/8.14.4/neon-v1-002) with ESMTP id
 x6TEWpTn006057
 (version=TLSv1/SSLv3 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); 
 Mon, 29 Jul 2019 16:32:51 +0200
Received: by agmartin.aq.upm.es (Postfix, from userid 1000)
 id 8909C43AD3; Mon, 29 Jul 2019 16:32:51 +0200 (CEST)
Date: Mon, 29 Jul 2019 16:32:51 +0200
From: Agustin Martin <agustin6martin@HIDDEN>
To: 24050 <at> debbugs.gnu.org
Subject: Re: bug#24050: 24.5; ispell-change-dictionary suggests non-existent
 dicts (aspell)
Message-ID: <20190729143251.GA19151@HIDDEN>
References: <CA+MVPv5Dk=Y=atXVeL3KNWxjxdVa0a2rAQ2zNvWOLXTEc-Uwqw@HIDDEN>
 <87k1c2cv77.fsf@HIDDEN> <83h876kzv1.fsf@HIDDEN>
 <m3pnlu44nw.fsf@HIDDEN> <83d0hukya1.fsf@HIDDEN>
MIME-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
In-Reply-To: <83d0hukya1.fsf@HIDDEN>
User-Agent: Mutt/1.10.1 (2018-07-13)
X-Spam-Score: -0.0 (/)
X-Debbugs-Envelope-To: 24050
Cc: Lars Ingebrigtsen <larsi@HIDDEN>, olejorgenb@HIDDEN
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -2.0 (--)

On Sun, Jul 28, 2019 at 05:51:34PM +0300, Eli Zaretskii wrote:
> > From: Lars Ingebrigtsen <larsi@HIDDEN>
> > Cc: olejorgenb@HIDDEN,  24050 <at> debbugs.gnu.org
> > Date: Sun, 28 Jul 2019 16:25:39 +0200
> > 
> > > The OP's suggestion would make sense if the list created by that
> > > function was only used for completion.  However, in fact we also force
> > > the user to specify a dictionary from the list, i.e. the selection
> > > must match one of the members of the list.  So this change is for the
> > > worse.
> > 
> > OK; I can revert, but I don't quite understand your objection.  If you
> > choose a dictionary that's not in the list aspell/hunspell returned, the
> > next time you hit `M-$' you'll just get an error message.
> 
> You assume that a dictionary not in the list doesn't exist; but that
> isn't a given.  I've heard enough reports from users who for some
> reason or other bumped into situations where ispell.el couldn't figure
> out correctly what dictionaries are installed.  The standard list
> (which is also customizable) leaves a "fire escape" for those cases.

IIRC the original discussion was in the thread starting with

https://lists.gnu.org/archive/html/emacs-devel/2005-10/msg00566.html

The problem was with aspell dicts not having .dat file, and the workaround
was to preserve default values. Not sure if code has been changed
afterwards.

-- 
Agustin




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#24050; Package emacs. Full text available.

Message received at 24050 <at> debbugs.gnu.org:


Received: (at 24050) by debbugs.gnu.org; 29 Jul 2019 11:12:21 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Mon Jul 29 07:12:21 2019
Received: from localhost ([127.0.0.1]:47729 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1hs3Zk-0000pj-Sv
	for submit <at> debbugs.gnu.org; Mon, 29 Jul 2019 07:12:21 -0400
Received: from quimby.gnus.org ([80.91.231.51]:41714)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <larsi@HIDDEN>) id 1hs3Zj-0000pb-Vf
 for 24050 <at> debbugs.gnu.org; Mon, 29 Jul 2019 07:12:20 -0400
Received: from cm-84.212.202.86.getinternet.no ([84.212.202.86] helo=stories)
 by quimby.gnus.org with esmtpsa
 (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.89)
 (envelope-from <larsi@HIDDEN>)
 id 1hs3Zg-0001LG-2r; Mon, 29 Jul 2019 13:12:18 +0200
From: Lars Ingebrigtsen <larsi@HIDDEN>
To: Eli Zaretskii <eliz@HIDDEN>
Subject: Re: bug#24050: 24.5; ispell-change-dictionary suggests non-existent
 dicts (aspell)
References: <CA+MVPv5Dk=Y=atXVeL3KNWxjxdVa0a2rAQ2zNvWOLXTEc-Uwqw@HIDDEN>
 <87k1c2cv77.fsf@HIDDEN> <83h876kzv1.fsf@HIDDEN>
 <m3pnlu44nw.fsf@HIDDEN> <83d0hukya1.fsf@HIDDEN>
 <m3lfwi42ol.fsf@HIDDEN> <83a7cyku2k.fsf@HIDDEN>
Face: iVBORw0KGgoAAAANSUhEUgAAADAAAAAwBAMAAAClLOS0AAAAGFBMVEUPAw4MAQvPflDhpE/C
 akRNKh+mUjQiDRXZl1F4AAACY0lEQVQ4jW2UTXPbIBCG0XRUrvK0rs9dEfUOcXrtUKJz0gni2moQ
 uUqdKPz9votsx5PpyrJhH/aDXbCodv+VRpwGa95E5pPiAiS0C975HdgtQlSHuaqqawCdFMsCz81O
 illeADw8hrCUQX7I+QyaWUiEKECewwA0Wc4zrw3ZQ9ssVbNWnK70J5l8Og8f2eLJkXLOERG+3CYL
 wCE6u82G5OIJ/AHYY6LKzJJyV+ALFKT6J2UJgw7cKvpRADGwDBQ+EdO2gNZoglaxIZ5EZMx3gM/G
 GFZRhCv8qLHdwCcARfDXRxeVtTpegagUYiAIeKvNGxi1dSMRYjlrWI4b0KaEJqVh2Z7BBx5oRW2J
 bUfN5Cg20JqO9K3lHDjKGyCs1iqlyMWxJ4u/cKSVNZRcSvAWrflZwEt728K5uY28FeUitWoDtkOF
 rLlDvl1yrm/pjm4YOFcsuMhustRZZHIP8Apj6sikLkFG6pCiLSDCPlkzsiMGZHrHoOaFKXK+LqKQ
 CNin6QK4CZq4SZA+PRew1B7HAP3qhxHHxN5kHwD2YbfzaRqs0T6RSz7+FjJIHJ9HXIIU/GiO9UBd
 eHUPALA4LAyq9Zf5eoiUxOBmIUIGwDEfaNm35tthxJaf2MIz8BUU9y8o6UfsdCD3LOqJweAHW5qg
 bUkW8YeJg3sUAp0tjeT+uj6VDTar97x11DWyDjJND6JcHBZ/EZ4JIRqB+yVEgcjzWiRWowi4aMH7
 2oc6nIEMqwwAYfarn0N9McQlzABzEB7VO1tkuA9rLhbZr7Cty2I8HNlznDXAJ1g4rS//OTPf/ODz
 Rf4BHtj7VtrH1nkAAAAASUVORK5CYII=
Date: Mon, 29 Jul 2019 13:12:15 +0200
In-Reply-To: <83a7cyku2k.fsf@HIDDEN> (Eli Zaretskii's message of "Sun, 28 Jul
 2019 19:22:27 +0300")
Message-ID: <m336ipxfg0.fsf@HIDDEN>
User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (gnu/linux)
MIME-Version: 1.0
Content-Type: text/plain
X-Spam-Report: Spam detection software, running on the system "quimby.gnus.org",
 has NOT identified this incoming email as spam.  The original
 message has been attached to this so you can view it or label
 similar future email.  If you have any questions, see
 @@CONTACT_ADDRESS@@ for details.
 Content preview:  Eli Zaretskii <eliz@HIDDEN> writes: > If aspell/hunspell
 is misconfigured, or has some bug, it might not > output the correct list
 of installed dictionaries, or not at all. But if it's misconfigured, then
 it'll bug out when you ask it to do other things as well, as hitting `M-$'.
 So I don't understand why we can't rely on aspell/hunspell to tell us what
 it knows about. 
 Content analysis details:   (-2.9 points, 5.0 required)
 pts rule name              description
 ---- ---------------------- --------------------------------------------------
 -1.0 ALL_TRUSTED            Passed through trusted hosts only via SMTP
 -1.9 BAYES_00               BODY: Bayes spam probability is 0 to 1%
 [score: 0.0000]
X-Spam-Score: 0.0 (/)
X-Debbugs-Envelope-To: 24050
Cc: 24050 <at> debbugs.gnu.org, olejorgenb@HIDDEN
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -1.0 (-)

Eli Zaretskii <eliz@HIDDEN> writes:

> If aspell/hunspell is misconfigured, or has some bug, it might not
> output the correct list of installed dictionaries, or not at all.

But if it's misconfigured, then it'll bug out when you ask it to do
other things as well, as hitting `M-$'.  So I don't understand why we
can't rely on aspell/hunspell to tell us what it knows about.

With the patch, ispell-change-directory (on this system) seems to list
all the dictionaries it can use.  This is quite useful, because now that
command allows me to actually choose the dictionary variant I most want
to use, which was impossible before when they were hidden among all the
dictionaries Emacs was claiming I could use (but can't).

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#24050; Package emacs. Full text available.

Message received at 24050 <at> debbugs.gnu.org:


Received: (at 24050) by debbugs.gnu.org; 28 Jul 2019 16:22:53 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Sun Jul 28 12:22:53 2019
Received: from localhost ([127.0.0.1]:47047 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1hrlwj-0004xy-35
	for submit <at> debbugs.gnu.org; Sun, 28 Jul 2019 12:22:53 -0400
Received: from eggs.gnu.org ([209.51.188.92]:52500)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <eliz@HIDDEN>) id 1hrlwh-0004xj-DU
 for 24050 <at> debbugs.gnu.org; Sun, 28 Jul 2019 12:22:51 -0400
Received: from fencepost.gnu.org ([2001:470:142:3::e]:59153)
 by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from <eliz@HIDDEN>)
 id 1hrlwc-0004iN-78; Sun, 28 Jul 2019 12:22:46 -0400
Received: from [176.228.60.248] (port=3181 helo=home-c4e4a596f7)
 by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256)
 (Exim 4.82) (envelope-from <eliz@HIDDEN>)
 id 1hrlwb-0005os-LB; Sun, 28 Jul 2019 12:22:46 -0400
Date: Sun, 28 Jul 2019 19:22:27 +0300
Message-Id: <83a7cyku2k.fsf@HIDDEN>
From: Eli Zaretskii <eliz@HIDDEN>
To: Lars Ingebrigtsen <larsi@HIDDEN>
In-reply-to: <m3lfwi42ol.fsf@HIDDEN> (message from Lars Ingebrigtsen on Sun, 
 28 Jul 2019 17:08:26 +0200)
Subject: Re: bug#24050: 24.5; ispell-change-dictionary suggests non-existent
 dicts (aspell)
References: <CA+MVPv5Dk=Y=atXVeL3KNWxjxdVa0a2rAQ2zNvWOLXTEc-Uwqw@HIDDEN>
 <87k1c2cv77.fsf@HIDDEN> <83h876kzv1.fsf@HIDDEN>
 <m3pnlu44nw.fsf@HIDDEN> <83d0hukya1.fsf@HIDDEN> <m3lfwi42ol.fsf@HIDDEN>
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic]
X-Spam-Score: -2.3 (--)
X-Debbugs-Envelope-To: 24050
Cc: 24050 <at> debbugs.gnu.org, olejorgenb@HIDDEN
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -3.3 (---)

> From: Lars Ingebrigtsen <larsi@HIDDEN>
> Cc: olejorgenb@HIDDEN,  24050 <at> debbugs.gnu.org
> Date: Sun, 28 Jul 2019 17:08:26 +0200
> 
> OK, so aspell/hunspell won't output the real list of dictionaries it has
> access to, but find more later when you give them a dictionary name?

If aspell/hunspell is misconfigured, or has some bug, it might not
output the correct list of installed dictionaries, or not at all.

> ispell.el itself doesn't look around for dictionaries -- it just calls
> aspell/hunspell and it outputs the dictionaries (see below).

Yes.

> If the backend is something other than aspell/hunspell, ispell will
> still output the entire list of built-in dictionary names.

Right.




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#24050; Package emacs. Full text available.

Message received at 24050 <at> debbugs.gnu.org:


Received: (at 24050) by debbugs.gnu.org; 28 Jul 2019 15:08:32 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Sun Jul 28 11:08:32 2019
Received: from localhost ([127.0.0.1]:46985 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1hrkml-00079S-QL
	for submit <at> debbugs.gnu.org; Sun, 28 Jul 2019 11:08:32 -0400
Received: from quimby.gnus.org ([80.91.231.51]:57322)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <larsi@HIDDEN>) id 1hrkmk-00079J-1C
 for 24050 <at> debbugs.gnu.org; Sun, 28 Jul 2019 11:08:30 -0400
Received: from cm-84.212.202.86.getinternet.no ([84.212.202.86] helo=stories)
 by quimby.gnus.org with esmtpsa
 (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.89)
 (envelope-from <larsi@HIDDEN>)
 id 1hrkmg-00052T-Kq; Sun, 28 Jul 2019 17:08:28 +0200
From: Lars Ingebrigtsen <larsi@HIDDEN>
To: Eli Zaretskii <eliz@HIDDEN>
Subject: Re: bug#24050: 24.5; ispell-change-dictionary suggests non-existent
 dicts (aspell)
References: <CA+MVPv5Dk=Y=atXVeL3KNWxjxdVa0a2rAQ2zNvWOLXTEc-Uwqw@HIDDEN>
 <87k1c2cv77.fsf@HIDDEN> <83h876kzv1.fsf@HIDDEN>
 <m3pnlu44nw.fsf@HIDDEN> <83d0hukya1.fsf@HIDDEN>
Face: iVBORw0KGgoAAAANSUhEUgAAADAAAAAwBAMAAAClLOS0AAAAJFBMVEUUFBrS1cq1sIwMChAK
 CA4DAgdmXTbo6t1FRz1/dDsqMTqUiEJ+LDMUAAACNElEQVQ4jXXTT4vaQBgG8LfEFsmpSWG3y17W
 FLZaL8JIWbya/QTtQksvoYep4sm9DG0vaUtDjJeshWD0MrAgOnuRHsQ/X67vZKKJrn1AjM+PN5k4
 CRj5lAzDiiIad+gI8r1lWRGlER2PF6GEbtqbVuBRGq/am81iDgbDpGQJj7bjOIVTKbsJbzxedbIJ
 NbKmrudh299slmtgKnKgdMYlrCSMcnDC2EuPdlb7gFJlrDyh/QTWebjslpaPAa9ufq+AgtVmHuaA
 sVsnhfEenLJy6El4OIDz7gVQhMUhnFhhg9LeYzCscsNr9eLFw+IAvmn6MTB/doFP/dk+GEaZF5l7
 T4oI/aUC3LjIFwBguBqpzeKhgkvfF4EQHOHLxf0OHPB9rIXACp48f0XILBr21wp8BaBdvfiVQG89
 DnMTmD8aIZNo1FvHCNMgAY2keYYQShDiAKizBbEHb1v/A5xwjsFVy/GctrODbU8aLbfn0h3wDPCp
 C45BjXJPUMdNoJwDokMG5qCqSukNmBQTmApxx5gCuTahCV1C9KOi00EpO5UA3pgi4Evntq0qaRJi
 K+BaDYCDUX0Dn/+u6jaxFehcflwwK+3OYBnWbZkEcAf0wIXz4euvxambAeAKdNxq4/aOzQEU2KTe
 lFDUOT4lZoWndZKavH28uFlxCzdJ3qdnw/UBrivQbrIg+JrdxBvVYNu9S8fEAXywnqoDIHazRmo7
 +Gj+VgfNggTQgFwnvz+V1fe1jf8BECj8A+pZr0hZcFA2AAAAAElFTkSuQmCC
Date: Sun, 28 Jul 2019 17:08:26 +0200
In-Reply-To: <83d0hukya1.fsf@HIDDEN> (Eli Zaretskii's message of "Sun, 28 Jul
 2019 17:51:34 +0300")
Message-ID: <m3lfwi42ol.fsf@HIDDEN>
User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (gnu/linux)
MIME-Version: 1.0
Content-Type: text/plain
X-Spam-Report: Spam detection software, running on the system "quimby.gnus.org",
 has NOT identified this incoming email as spam.  The original
 message has been attached to this so you can view it or label
 similar future email.  If you have any questions, see
 @@CONTACT_ADDRESS@@ for details.
 Content preview: Eli Zaretskii <eliz@HIDDEN> writes: > You assume that a
 dictionary
 not in the list doesn't exist; but that > isn't a given. I've heard enough
 reports from users who for some > reason or other bumped into situations
 where ispell.el could [...] 
 Content analysis details:   (-2.9 points, 5.0 required)
 pts rule name              description
 ---- ---------------------- --------------------------------------------------
 -1.0 ALL_TRUSTED            Passed through trusted hosts only via SMTP
 -1.9 BAYES_00               BODY: Bayes spam probability is 0 to 1%
 [score: 0.0000]
X-Spam-Score: 0.0 (/)
X-Debbugs-Envelope-To: 24050
Cc: 24050 <at> debbugs.gnu.org, olejorgenb@HIDDEN
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -1.0 (-)

Eli Zaretskii <eliz@HIDDEN> writes:

> You assume that a dictionary not in the list doesn't exist; but that
> isn't a given.  I've heard enough reports from users who for some
> reason or other bumped into situations where ispell.el couldn't figure
> out correctly what dictionaries are installed.  The standard list
> (which is also customizable) leaves a "fire escape" for those cases.

OK, so aspell/hunspell won't output the real list of dictionaries it has
access to, but find more later when you give them a dictionary name?

ispell.el itself doesn't look around for dictionaries -- it just calls
aspell/hunspell and it outputs the dictionaries (see below).

If the backend is something other than aspell/hunspell, ispell will
still output the entire list of built-in dictionary names.

$ aspell dicts
en
en-variant_0
en-variant_1
en-variant_2
en-w_accents
en-wo_accents
en_AU
en_AU-variant_0
en_AU-variant_1
en_AU-w_accents
en_AU-wo_accents
en_CA
[...]

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#24050; Package emacs. Full text available.

Message received at 24050 <at> debbugs.gnu.org:


Received: (at 24050) by debbugs.gnu.org; 28 Jul 2019 14:51:59 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Sun Jul 28 10:51:59 2019
Received: from localhost ([127.0.0.1]:46967 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1hrkWl-0004Yb-4l
	for submit <at> debbugs.gnu.org; Sun, 28 Jul 2019 10:51:59 -0400
Received: from eggs.gnu.org ([209.51.188.92]:36183)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <eliz@HIDDEN>) id 1hrkWj-0004YN-Cy
 for 24050 <at> debbugs.gnu.org; Sun, 28 Jul 2019 10:51:57 -0400
Received: from fencepost.gnu.org ([2001:470:142:3::e]:57322)
 by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from <eliz@HIDDEN>)
 id 1hrkWe-0006qm-66; Sun, 28 Jul 2019 10:51:52 -0400
Received: from [176.228.60.248] (port=1461 helo=home-c4e4a596f7)
 by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256)
 (Exim 4.82) (envelope-from <eliz@HIDDEN>)
 id 1hrkWd-0006GX-LO; Sun, 28 Jul 2019 10:51:52 -0400
Date: Sun, 28 Jul 2019 17:51:34 +0300
Message-Id: <83d0hukya1.fsf@HIDDEN>
From: Eli Zaretskii <eliz@HIDDEN>
To: Lars Ingebrigtsen <larsi@HIDDEN>
In-reply-to: <m3pnlu44nw.fsf@HIDDEN> (message from Lars Ingebrigtsen on Sun, 
 28 Jul 2019 16:25:39 +0200)
Subject: Re: bug#24050: 24.5; ispell-change-dictionary suggests non-existent
 dicts (aspell)
References: <CA+MVPv5Dk=Y=atXVeL3KNWxjxdVa0a2rAQ2zNvWOLXTEc-Uwqw@HIDDEN>
 <87k1c2cv77.fsf@HIDDEN> <83h876kzv1.fsf@HIDDEN>
 <m3pnlu44nw.fsf@HIDDEN>
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic]
X-Spam-Score: -2.3 (--)
X-Debbugs-Envelope-To: 24050
Cc: 24050 <at> debbugs.gnu.org, olejorgenb@HIDDEN
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -3.3 (---)

> From: Lars Ingebrigtsen <larsi@HIDDEN>
> Cc: olejorgenb@HIDDEN,  24050 <at> debbugs.gnu.org
> Date: Sun, 28 Jul 2019 16:25:39 +0200
> 
> > The OP's suggestion would make sense if the list created by that
> > function was only used for completion.  However, in fact we also force
> > the user to specify a dictionary from the list, i.e. the selection
> > must match one of the members of the list.  So this change is for the
> > worse.
> 
> OK; I can revert, but I don't quite understand your objection.  If you
> choose a dictionary that's not in the list aspell/hunspell returned, the
> next time you hit `M-$' you'll just get an error message.

You assume that a dictionary not in the list doesn't exist; but that
isn't a given.  I've heard enough reports from users who for some
reason or other bumped into situations where ispell.el couldn't figure
out correctly what dictionaries are installed.  The standard list
(which is also customizable) leaves a "fire escape" for those cases.




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#24050; Package emacs. Full text available.

Message received at 24050 <at> debbugs.gnu.org:


Received: (at 24050) by debbugs.gnu.org; 28 Jul 2019 14:25:47 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Sun Jul 28 10:25:47 2019
Received: from localhost ([127.0.0.1]:46939 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1hrk7N-0001it-Rj
	for submit <at> debbugs.gnu.org; Sun, 28 Jul 2019 10:25:47 -0400
Received: from quimby.gnus.org ([80.91.231.51]:56772)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <larsi@HIDDEN>) id 1hrk7L-0001ij-RU
 for 24050 <at> debbugs.gnu.org; Sun, 28 Jul 2019 10:25:44 -0400
Received: from cm-84.212.202.86.getinternet.no ([84.212.202.86] helo=stories)
 by quimby.gnus.org with esmtpsa
 (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.89)
 (envelope-from <larsi@HIDDEN>)
 id 1hrk7H-0004m7-JA; Sun, 28 Jul 2019 16:25:42 +0200
From: Lars Ingebrigtsen <larsi@HIDDEN>
To: Eli Zaretskii <eliz@HIDDEN>
Subject: Re: bug#24050: 24.5; ispell-change-dictionary suggests non-existent
 dicts (aspell)
References: <CA+MVPv5Dk=Y=atXVeL3KNWxjxdVa0a2rAQ2zNvWOLXTEc-Uwqw@HIDDEN>
 <87k1c2cv77.fsf@HIDDEN> <83h876kzv1.fsf@HIDDEN>
Face: iVBORw0KGgoAAAANSUhEUgAAADAAAAAwBAMAAAClLOS0AAAAJFBMVEUiCxOqMEsDAQYHBQ0F
 AwuvHTXXJkUEAgloT17arrYIBQ+CFieDl4FlAAACS0lEQVQ4jW3TsY/TMBQG8IeOKyYsrGyVdcjD
 LYdSiVMYaylVmVsJdYGhlqpbSggyOpboJrcTQuIUiyW6LFVGRDvQf47PTlLSOzJV/uV779lOiXM+
 DKuqoPsPIA2j/whAePFPcQRcywtjssaqoDiAEBtr8/KQIwJ6+PTIWhuEYUPMmKqGaw+plEOgW2+A
 +8RaxFIOYAUx8iD49VPAjdDISInQZZPQo5UHLqR09YbDsiKRCK1HLwCGJzyVWvpURBzr+ov1IJIz
 qb0MQwepXrpSmU7QBKUcDetE6prfxe7dNI61GwLNBV58hZ2nfqZUAzA1JT7yES38+kC6AhgMCfzS
 vRbwxMigeSLeTPY0RalxnUDz2PUQ6U6piVrYb1iKPMSpxlRiqZSaTwFhWIaDMqzrAb4CFCCvALIK
 B57GxF8q/+DYcRnuPhxEOJJeC7+L0l9TVA7w2RDf1bCwz9/+aQDduvDzYtbcuStIfNrCj5NJs+qh
 P2/hdrZ1EEalh2UDyt7Ot0FTC1PQuWrBqlNAGZWl+4Docwf2QT1UYTKi0w7MmjqGjKFeB9775iUj
 kxna3YeoyIxhGU1bwLxXbs7IMETYEXxw4APo0QXlpmIsy9Zs9RAyNDDmIWxcgqwvNW/AKkIlwiZW
 Nu8mAOMqcx1yJFQXggAtyNjc0BHMTx5fsrUrlB0l8tdnT0Zoblfr7GjnN7wfMJOvVjm2+O90Fznn
 z7YG/weso9TyAN95f6pQ3zXAkcRtZH/HzycLH2AGV1JF9cFf/eKAd+6/uNmwEfsLbq6+tBYldHkA
 AAAASUVORK5CYII=
Date: Sun, 28 Jul 2019 16:25:39 +0200
In-Reply-To: <83h876kzv1.fsf@HIDDEN> (Eli Zaretskii's message of "Sun, 28 Jul
 2019 17:17:22 +0300")
Message-ID: <m3pnlu44nw.fsf@HIDDEN>
User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (gnu/linux)
MIME-Version: 1.0
Content-Type: text/plain
X-Spam-Report: Spam detection software, running on the system "quimby.gnus.org",
 has NOT identified this incoming email as spam.  The original
 message has been attached to this so you can view it or label
 similar future email.  If you have any questions, see
 @@CONTACT_ADDRESS@@ for details.
 Content preview: Eli Zaretskii <eliz@HIDDEN> writes: > I think this is a
 mistake, 
 and should be reverted. It prevents users > from telling ispell.el to switch
 to a dictionary that aspell/hunspell > didn't return in the list. That's
 a regression. > > The [...] 
 Content analysis details:   (-2.9 points, 5.0 required)
 pts rule name              description
 ---- ---------------------- --------------------------------------------------
 -1.0 ALL_TRUSTED            Passed through trusted hosts only via SMTP
 -1.9 BAYES_00               BODY: Bayes spam probability is 0 to 1%
 [score: 0.0000]
X-Spam-Score: 0.0 (/)
X-Debbugs-Envelope-To: 24050
Cc: 24050 <at> debbugs.gnu.org, olejorgenb@HIDDEN
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -1.0 (-)

Eli Zaretskii <eliz@HIDDEN> writes:

> I think this is a mistake, and should be reverted.  It prevents users
> from telling ispell.el to switch to a dictionary that aspell/hunspell
> didn't return in the list.  That's a regression.
>
> The OP's suggestion would make sense if the list created by that
> function was only used for completion.  However, in fact we also force
> the user to specify a dictionary from the list, i.e. the selection
> must match one of the members of the list.  So this change is for the
> worse.

OK; I can revert, but I don't quite understand your objection.  If you
choose a dictionary that's not in the list aspell/hunspell returned, the
next time you hit `M-$' you'll just get an error message.  I don't
understand the utility of having ispell let you make make a choice
that'll lead to an inevitable error.

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#24050; Package emacs. Full text available.

Message received at 24050 <at> debbugs.gnu.org:


Received: (at 24050) by debbugs.gnu.org; 28 Jul 2019 14:17:47 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Sun Jul 28 10:17:47 2019
Received: from localhost ([127.0.0.1]:46935 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1hrjzf-0001W1-0P
	for submit <at> debbugs.gnu.org; Sun, 28 Jul 2019 10:17:47 -0400
Received: from eggs.gnu.org ([209.51.188.92]:58667)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <eliz@HIDDEN>) id 1hrjzc-0001Vo-CO
 for 24050 <at> debbugs.gnu.org; Sun, 28 Jul 2019 10:17:45 -0400
Received: from fencepost.gnu.org ([2001:470:142:3::e]:57094)
 by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from <eliz@HIDDEN>)
 id 1hrjzW-0006YY-Uz; Sun, 28 Jul 2019 10:17:38 -0400
Received: from [176.228.60.248] (port=3346 helo=home-c4e4a596f7)
 by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256)
 (Exim 4.82) (envelope-from <eliz@HIDDEN>)
 id 1hrjzW-0004a8-E8; Sun, 28 Jul 2019 10:17:38 -0400
Date: Sun, 28 Jul 2019 17:17:22 +0300
Message-Id: <83h876kzv1.fsf@HIDDEN>
From: Eli Zaretskii <eliz@HIDDEN>
To: Lars Ingebrigtsen <larsi@HIDDEN>
In-reply-to: <87k1c2cv77.fsf@HIDDEN> (message from Lars Ingebrigtsen
 on Sun, 28 Jul 2019 12:25:16 +0200)
Subject: Re: bug#24050: 24.5;
 ispell-change-dictionary suggests non-existent dicts (aspell)
References: <CA+MVPv5Dk=Y=atXVeL3KNWxjxdVa0a2rAQ2zNvWOLXTEc-Uwqw@HIDDEN>
 <87k1c2cv77.fsf@HIDDEN>
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic]
X-Spam-Score: -2.3 (--)
X-Debbugs-Envelope-To: 24050
Cc: 24050 <at> debbugs.gnu.org, olejorgenb@HIDDEN
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -3.3 (---)

> From: Lars Ingebrigtsen <larsi@HIDDEN>
> Date: Sun, 28 Jul 2019 12:25:16 +0200
> Cc: 24050 <at> debbugs.gnu.org
> 
> Thanks for the analysis; altering the code along these lines does fix
> the problem, and `M-x ispell-change-dictionary' now seems a lot more
> useful now that it just lists the dictionaries I actually have
> installed.
> 
> > I would suggest simply removing [1] and not add the *base-alist above when using
> > aspell/hunspell, but the following comment makes it seem like the "invalid"
> > entries are added intentionally:
> >
> >     ;; Substitute ispell-dictionary-alist with the list of
> >     ;; dictionaries corresponding to the given spellchecker.
> >     ;; If a recent aspell or hunspell, use the list of really
> >     ;; installed dictionaries and add to it elements of the original
> >     ;; list that are not present there*. Allow distro info.
> 
> It may be intentional, but the other comments seem to indicate that it's
> not...  and I don't see the utility of listing dictionaries we don't
> have, so I think it's a good change anyway.
> 
> So I've made it on the Emacs trunk now.

I think this is a mistake, and should be reverted.  It prevents users
from telling ispell.el to switch to a dictionary that aspell/hunspell
didn't return in the list.  That's a regression.

The OP's suggestion would make sense if the list created by that
function was only used for completion.  However, in fact we also force
the user to specify a dictionary from the list, i.e. the selection
must match one of the members of the list.  So this change is for the
worse.




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#24050; Package emacs. Full text available.
bug marked as fixed in version 27.1, send any further explanations to 24050 <at> debbugs.gnu.org and Ole Jørgen Brønner <olejorgenb@HIDDEN> Request was from Lars Ingebrigtsen <larsi@HIDDEN> to control <at> debbugs.gnu.org. Full text available.
Added tag(s) fixed. Request was from Lars Ingebrigtsen <larsi@HIDDEN> to control <at> debbugs.gnu.org. Full text available.

Message received at 24050 <at> debbugs.gnu.org:


Received: (at 24050) by debbugs.gnu.org; 28 Jul 2019 10:25:24 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Sun Jul 28 06:25:24 2019
Received: from localhost ([127.0.0.1]:45793 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1hrgMm-0005ts-4s
	for submit <at> debbugs.gnu.org; Sun, 28 Jul 2019 06:25:24 -0400
Received: from quimby.gnus.org ([80.91.231.51]:53472)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <larsi@HIDDEN>) id 1hrgMj-0005ti-Ej
 for 24050 <at> debbugs.gnu.org; Sun, 28 Jul 2019 06:25:21 -0400
Received: from cm-84.212.202.86.getinternet.no ([84.212.202.86] helo=marnie)
 by quimby.gnus.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.89) (envelope-from <larsi@HIDDEN>)
 id 1hrgMe-00031M-ES; Sun, 28 Jul 2019 12:25:18 +0200
From: Lars Ingebrigtsen <larsi@HIDDEN>
To: Ole =?utf-8?Q?J=C3=B8rgen_Br=C3=B8nner?= <olejorgenb@HIDDEN>
Subject: Re: bug#24050: 24.5; ispell-change-dictionary suggests non-existent
 dicts (aspell)
References: <CA+MVPv5Dk=Y=atXVeL3KNWxjxdVa0a2rAQ2zNvWOLXTEc-Uwqw@HIDDEN>
Date: Sun, 28 Jul 2019 12:25:16 +0200
In-Reply-To: <CA+MVPv5Dk=Y=atXVeL3KNWxjxdVa0a2rAQ2zNvWOLXTEc-Uwqw@HIDDEN>
 ("Ole \=\?utf-8\?Q\?J\=C3\=B8rgen_Br\=C3\=B8nner\=22's\?\= message of "Thu,
 21 Jul 2016 21:49:06 +0200")
Message-ID: <87k1c2cv77.fsf@HIDDEN>
User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (gnu/linux)
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Transfer-Encoding: quoted-printable
X-Spam-Report: Spam detection software, running on the system "quimby.gnus.org",
 has NOT identified this incoming email as spam.  The original
 message has been attached to this so you can view it or label
 similar future email.  If you have any questions, see
 @@CONTACT_ADDRESS@@ for details.
 
 Content preview:  Ole Jørgen Brønner <olejorgenb@HIDDEN> writes: > There's
    a dedicated function, `ispell-find-aspell-dictionaries`, to find valid >
   aspell dictionaries. It sanely ask bin/aspell for the list and then does some
    > post-processing to find the rest of t [...] 
 
 Content analysis details:   (-2.9 points, 5.0 required)
 
  pts rule name              description
 ---- ---------------------- --------------------------------------------------
 -1.0 ALL_TRUSTED            Passed through trusted hosts only via SMTP
 -1.9 BAYES_00               BODY: Bayes spam probability is 0 to 1%
                             [score: 0.0000]
X-Spam-Score: 0.0 (/)
X-Debbugs-Envelope-To: 24050
Cc: 24050 <at> debbugs.gnu.org
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -1.0 (-)

Ole J=C3=B8rgen Br=C3=B8nner <olejorgenb@HIDDEN> writes:

> There's a dedicated function, `ispell-find-aspell-dictionaries`, to find =
valid
> aspell dictionaries. It sanely ask bin/aspell for the list and then does =
some
> post-processing to find the rest of the spec.
>
> But after the *correct* list has been found this code[1] is run:
>
>     ;; Merge into FOUND any elements from the standard
> ispell-dictionary-base-alist
>     ;; which have no element in FOUND at all.
>     (dolist (dict ispell-dictionary-base-alist)
>       (unless (assoc (car dict) found)
>     (setq found (nconc found (list dict)))))
>
> Adding invalid entries to the list. There might be a rationale behind tha=
t, but
> to me is seems like `ispell-dictionary-base-alist` mostly exist due to la=
ck of
> *ispell* (old aspell?) introspection? (When using *ispell* as the
> provider, invalid entries
>  are filtered out in `ispell-valid-dictionary-list`)
>
> Removing that code isn't enough though:
>
> In `ispell-set-spellchecker-params` the invalid entries are added again:
> (where `found-dicts-alist` is the result of `ispell-find-aspell-dictionar=
ies`
> in when aspell is used)
>
>     (run-hooks 'ispell-initialize-spellchecker-hook)
>
>     ;; Add dicts to ``ispell-dictionary-alist'' unless already present.
>     (dolist (dict (append found-dicts-alist
>                           ispell-base-dicts-override-alist
>                           ispell-dictionary-base-alist))
>       (unless (assoc (car dict) all-dicts-alist)
>         (add-to-list 'all-dicts-alist dict)))
>     (setq ispell-dictionary-alist all-dicts-alist))
>
> This code seems to have two purposes:
> - When *ispell* is the provider, `found-dicts-alist` is nil at this
> point, so the
>   default entries must be added
> - Apply dictionary overrides (possibly set by the hook above)

(I'm going through old Emacs bug reports that haven't received any
response.)

Thanks for the analysis; altering the code along these lines does fix
the problem, and `M-x ispell-change-dictionary' now seems a lot more
useful now that it just lists the dictionaries I actually have
installed.

> I would suggest simply removing [1] and not add the *base-alist above whe=
n using
> aspell/hunspell, but the following comment makes it seem like the "invali=
d"
> entries are added intentionally:
>
>     ;; Substitute ispell-dictionary-alist with the list of
>     ;; dictionaries corresponding to the given spellchecker.
>     ;; If a recent aspell or hunspell, use the list of really
>     ;; installed dictionaries and add to it elements of the original
>     ;; list that are not present there*. Allow distro info.

It may be intentional, but the other comments seem to indicate that it's
not...  and I don't see the utility of listing dictionaries we don't
have, so I think it's a good change anyway.

So I've made it on the Emacs trunk now.

--=20
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#24050; Package emacs. Full text available.

Message received at submit <at> debbugs.gnu.org:


Received: (at submit) by debbugs.gnu.org; 21 Jul 2016 22:00:43 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Thu Jul 21 18:00:43 2016
Received: from localhost ([127.0.0.1]:60655 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1bQM1I-0002Qo-04
	for submit <at> debbugs.gnu.org; Thu, 21 Jul 2016 18:00:43 -0400
Received: from eggs.gnu.org ([208.118.235.92]:46608)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <olejorgenb@HIDDEN>) id 1bQJyB-0007mr-75
 for submit <at> debbugs.gnu.org; Thu, 21 Jul 2016 15:49:19 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
 (envelope-from <olejorgenb@HIDDEN>) id 1bQJy4-0003EB-QG
 for submit <at> debbugs.gnu.org; Thu, 21 Jul 2016 15:49:14 -0400
X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org
X-Spam-Level: 
X-Spam-Status: No, score=0.8 required=5.0 tests=BAYES_50,FREEMAIL_FROM,
 T_DKIM_INVALID autolearn=disabled version=3.3.2
Received: from lists.gnu.org ([2001:4830:134:3::11]:34354)
 by eggs.gnu.org with esmtp (Exim 4.71)
 (envelope-from <olejorgenb@HIDDEN>) id 1bQJy4-0003E7-Mm
 for submit <at> debbugs.gnu.org; Thu, 21 Jul 2016 15:49:12 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:37577)
 by lists.gnu.org with esmtp (Exim 4.71)
 (envelope-from <olejorgenb@HIDDEN>) id 1bQJy2-0001Zx-Q4
 for bug-gnu-emacs@HIDDEN; Thu, 21 Jul 2016 15:49:12 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
 (envelope-from <olejorgenb@HIDDEN>) id 1bQJy0-0003CA-KQ
 for bug-gnu-emacs@HIDDEN; Thu, 21 Jul 2016 15:49:09 -0400
Received: from mail-qk0-x230.google.com ([2607:f8b0:400d:c09::230]:34887)
 by eggs.gnu.org with esmtp (Exim 4.71)
 (envelope-from <olejorgenb@HIDDEN>) id 1bQJy0-0003C6-FE
 for bug-gnu-emacs@HIDDEN; Thu, 21 Jul 2016 15:49:08 -0400
Received: by mail-qk0-x230.google.com with SMTP id s63so83525540qkb.2
 for <bug-gnu-emacs@HIDDEN>; Thu, 21 Jul 2016 12:49:08 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113;
 h=mime-version:from:date:message-id:subject:to;
 bh=2gKX2z9T6v7/V/yW7flSqSv4aBqnt7GOFQJZrbndV38=;
 b=fMLqTHlkvWVn7rJ0Lv3GujlPMn0bLNfYChzX6AHKKXVIVmJHBy20NUqjyyTlgIuSV6
 Xjj0TVnWamtlNIpO/pobvpJ4rAwG1bnmDc2plR2EU1KExpwhICBxaXZpnTMTm1TXi6GK
 yqWXjr8Zsy1Bur1+jK6KCEx+xWRMBMNaRgBLqLHZD96HfdK2aGdCeJaqWjYqRCScrk9D
 EUphXqdSPMLom+Nlq5asIoj6gKbkQ67j1LZv+H0wgkCiPvHCBA39Jqq3kcHgzZoeUA8z
 lzu34Y2NChrV8Pe/CVzSIBgOq1kaQw7lpOtecg1eCdk5RcYQHAYq1fow8Kq/AkN1scqJ
 FkYg==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
 d=1e100.net; s=20130820;
 h=x-gm-message-state:mime-version:from:date:message-id:subject:to;
 bh=2gKX2z9T6v7/V/yW7flSqSv4aBqnt7GOFQJZrbndV38=;
 b=AQWicsyl3zZmXtroSDDdLl4XSfxAn2MmP9R9a9KrHajbIGR2GGLLfs9+iYRhZEHLZn
 /mKaeD/i6M4AzAuTSJrl2Cauon6Uf2mehtCpLruolvizIkTQaGq7XU54sFrpNuIyEapY
 jYip6ryilKPreJXlp7yHl4XsFfYHSqQJ6FBB4qbnrpoED4g2K78szzHnwJZzurtiQSQz
 vFxk3Gi2j+zN7i7ogPjS35vaiAAPy93HrGumSChfZ6w/KTZoDOSONdCf4r5ps0Kc+IwA
 x635TgOUiEeSU57vzQcuZs7BZ/+RGTpjXP9yhMZsrmjE0x3LL+wS84pC+Le71lpic+Gl
 mX3w==
X-Gm-Message-State: AEkoouukLAzbcZWUkKHIaheGO+75wgbfGkRSvdLccGk3KQy3Dw4L3P6dshn3lh4f8Dze46unSxiKiSruCiuEjA==
X-Received: by 10.55.190.199 with SMTP id o190mr33174qkf.192.1469130547424;
 Thu, 21 Jul 2016 12:49:07 -0700 (PDT)
MIME-Version: 1.0
Received: by 10.237.53.137 with HTTP; Thu, 21 Jul 2016 12:49:06 -0700 (PDT)
From: =?UTF-8?B?T2xlIErDuHJnZW4gQnLDuG5uZXI=?= <olejorgenb@HIDDEN>
Date: Thu, 21 Jul 2016 21:49:06 +0200
Message-ID: <CA+MVPv5Dk=Y=atXVeL3KNWxjxdVa0a2rAQ2zNvWOLXTEc-Uwqw@HIDDEN>
Subject: 24.5; ispell-change-dictionary suggests non-existent dicts (aspell)
To: bug-gnu-emacs@HIDDEN
Content-Type: text/plain; charset=UTF-8
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic]
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x
X-Received-From: 2001:4830:134:3::11
X-Spam-Score: -4.0 (----)
X-Debbugs-Envelope-To: submit
X-Mailman-Approved-At: Thu, 21 Jul 2016 18:00:39 -0400
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -4.0 (----)

I'm using aspell as the "ispell provider".

    M-x ispell-change-dictionary

helpfully gives a list of dictionaries to choose from. The list however contains
dictionaries I don't have installed on my system. Only after spellchecking is
attempted I get an error in *Messages*.

Diving into the code I find quite an effort to build a list of
dictionaries for the three different ispell providers.

There's a dedicated function, `ispell-find-aspell-dictionaries`, to find valid
aspell dictionaries. It sanely ask bin/aspell for the list and then does some
post-processing to find the rest of the spec.

But after the *correct* list has been found this code[1] is run:

    ;; Merge into FOUND any elements from the standard
ispell-dictionary-base-alist
    ;; which have no element in FOUND at all.
    (dolist (dict ispell-dictionary-base-alist)
      (unless (assoc (car dict) found)
    (setq found (nconc found (list dict)))))

Adding invalid entries to the list. There might be a rationale behind that, but
to me is seems like `ispell-dictionary-base-alist` mostly exist due to lack of
*ispell* (old aspell?) introspection? (When using *ispell* as the
provider, invalid entries
 are filtered out in `ispell-valid-dictionary-list`)

Removing that code isn't enough though:

In `ispell-set-spellchecker-params` the invalid entries are added again:
(where `found-dicts-alist` is the result of `ispell-find-aspell-dictionaries`
in when aspell is used)

    (run-hooks 'ispell-initialize-spellchecker-hook)

    ;; Add dicts to ``ispell-dictionary-alist'' unless already present.
    (dolist (dict (append found-dicts-alist
                          ispell-base-dicts-override-alist
                          ispell-dictionary-base-alist))
      (unless (assoc (car dict) all-dicts-alist)
        (add-to-list 'all-dicts-alist dict)))
    (setq ispell-dictionary-alist all-dicts-alist))

This code seems to have two purposes:
- When *ispell* is the provider, `found-dicts-alist` is nil at this
point, so the
  default entries must be added
- Apply dictionary overrides (possibly set by the hook above)

I would suggest simply removing [1] and not add the *base-alist above when using
aspell/hunspell, but the following comment makes it seem like the "invalid"
entries are added intentionally:

    ;; Substitute ispell-dictionary-alist with the list of
    ;; dictionaries corresponding to the given spellchecker.
    ;; If a recent aspell or hunspell, use the list of really
    ;; installed dictionaries and add to it elements of the original
    ;; list that are not present there*. Allow distro info.


In GNU Emacs 24.5.1 (x86_64-unknown-linux-gnu, GTK+ Version 3.20.6)
 of 2016-06-04 on juergen
Windowing system distributor `The X.Org Foundation', version 11.0.11803000
Configured using:
 `configure --prefix=/usr --sysconfdir=/etc --libexecdir=/usr/lib
 --localstatedir=/var --with-x-toolkit=gtk3 --with-xft
 'CFLAGS=-march=x86-64 -mtune=generic -O2 -pipe
 -fstack-protector-strong' CPPFLAGS=-D_FORTIFY_SOURCE=2
 LDFLAGS=-Wl,-O1,--sort-common,--as-needed,-z,relro'

Important settings:
  value of $LC_COLLATE: en_US.UTF-8
  value of $LC_CTYPE: en_US.UTF-8
  value of $LC_MESSAGES: en_US.UTF-8
  value of $LC_MONETARY: en_US.UTF-8
  value of $LC_NUMERIC: en_US.UTF-8
  value of $LC_TIME: nb_NO.utf8
  value of $LANG: en_US.utf8
  locale-coding-system: utf-8-unix

Major mode: Lisp Interaction

Minor modes in effect:
  tooltip-mode: t
  electric-indent-mode: t
  mouse-wheel-mode: t
  tool-bar-mode: t
  menu-bar-mode: t
  file-name-shadow-mode: t
  global-font-lock-mode: t
  font-lock-mode: t
  blink-cursor-mode: t
  auto-composition-mode: t
  auto-encryption-mode: t
  auto-compression-mode: t
  line-number-mode: t
  transient-mark-mode: t

Recent messages:
Making completion list... [2 times]
Local Ispell dictionary set to german
Entering debugger...
Back to top level.
<C-tab> is undefined
Making completion list... [2 times]
Starting new Ispell process /usr/bin/aspell with german dictionary...
ispell-init-process: Error: The file "/usr/lib/aspell-0.60/german" can
not be opened for reading.
ESC M-x is undefined [3 times]
Making completion list... [2 times]

Load-path shadows:
None found.

Features:
(shadow sort gnus-util mail-extr emacsbug message format-spec rfc822 mml
mml-sec mm-decode mm-bodies mm-encode mail-parse rfc2231 mailabbrev
gmm-utils mailheader sendmail rfc2047 rfc2045 ietf-drums mm-util
help-fns mail-prsvr mail-utils debug ispell help-mode easymenu time-date
tooltip electric uniquify ediff-hook vc-hooks lisp-float-type mwheel
x-win x-dnd tool-bar dnd fontset image regexp-opt fringe tabulated-list
newcomment lisp-mode prog-mode register page menu-bar rfn-eshadow timer
select scroll-bar mouse jit-lock font-lock syntax facemenu font-core
frame cham georgian utf-8-lang misc-lang vietnamese tibetan thai
tai-viet lao korean japanese hebrew greek romanian slovak czech european
ethiopic indian cyrillic chinese case-table epa-hook jka-cmpr-hook help
simple abbrev minibuffer nadvice loaddefs button faces cus-face macroexp
files text-properties overlay sha1 md5 base64 format env code-pages mule
custom widget hashtable-print-readable backquote make-network-process
dbusbind gfilenotify dynamic-setting system-font-setting
font-render-setting move-toolbar gtk x-toolkit x multi-tty emacs)

Memory information:
((conses 16 76572 7275)
 (symbols 48 18057 0)
 (miscs 40 46 163)
 (strings 32 10715 4971)
 (string-bytes 1 296127)
 (vectors 16 9261)
 (vector-slots 8 387535 14421)
 (floats 8 65 422)
 (intervals 56 220 26)
 (buffers 960 13)
 (heap 1024 26108 1053))




Acknowledgement sent to Ole Jørgen Brønner <olejorgenb@HIDDEN>:
New bug report received and forwarded. Copy sent to bug-gnu-emacs@HIDDEN. Full text available.
Report forwarded to bug-gnu-emacs@HIDDEN:
bug#24050; Package emacs. Full text available.
Please note: This is a static page, with minimal formatting, updated once a day.
Click here to see this page with the latest information and nicer formatting.
Last modified: Mon, 25 Nov 2019 12:00:02 UTC

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