GNU logs - #51843, boring messages


Message sent to bug-gnu-emacs@HIDDEN:


X-Loop: help-debbugs@HIDDEN
Subject: bug#51843: Ispell personal dictionary breaks other dictionaries
Resent-From: Tor Kringeland <tor.a.s.kringeland@HIDDEN>
Original-Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
Resent-CC: bug-gnu-emacs@HIDDEN
Resent-Date: Sun, 14 Nov 2021 13:51:01 +0000
Resent-Message-ID: <handler.51843.B.163689781423907 <at> debbugs.gnu.org>
Resent-Sender: help-debbugs@HIDDEN
X-GNU-PR-Message: report 51843
X-GNU-PR-Package: emacs
X-GNU-PR-Keywords: 
To: 51843 <at> debbugs.gnu.org
X-Debbugs-Original-To: bug-gnu-emacs@HIDDEN
Received: via spool by submit <at> debbugs.gnu.org id=B.163689781423907
          (code B ref -1); Sun, 14 Nov 2021 13:51:01 +0000
Received: (at submit) by debbugs.gnu.org; 14 Nov 2021 13:50:14 +0000
Received: from localhost ([127.0.0.1]:49485 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1mmFte-0006DX-Cx
	for submit <at> debbugs.gnu.org; Sun, 14 Nov 2021 08:50:14 -0500
Received: from lists.gnu.org ([209.51.188.17]:41126)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <tor.a.s.kringeland@HIDDEN>) id 1mmFtc-0006DO-Pm
 for submit <at> debbugs.gnu.org; Sun, 14 Nov 2021 08:50:13 -0500
Received: from eggs.gnu.org ([209.51.188.92]:44502)
 by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <tor.a.s.kringeland@HIDDEN>)
 id 1mmFtb-0008Ml-Ct
 for bug-gnu-emacs@HIDDEN; Sun, 14 Nov 2021 08:50:12 -0500
Received: from mailgw101.it.ntnu.no ([129.241.56.177]:50190)
 by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <tor.a.s.kringeland@HIDDEN>)
 id 1mmFtZ-0000WV-5n
 for bug-gnu-emacs@HIDDEN; Sun, 14 Nov 2021 08:50:11 -0500
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=ntnu.no;
 i=@ntnu.no; q=dns/txt; s=s1-1909-ntnu; t=1636897806; h=from : to :
 subject : date : message-id : mime-version : content-type : from;
 bh=0njys1kT9dM1ij2TNBB8F1D/TWS+1J9BdrmK7Wo/0kg=;
 b=MlOP7PzCZF5FTR5ZBKx+ivOxXa3kxhrIPKdW8t/K/qyVWK7SeiN7BOKFnN3pH8ys3ojvE
 iBIvTI1BzJMagQm2K0wBr/f7iU2eEQhdT+YL6PQLQw0YN1g3fH3S0enqJxaOg5JsinWJPzP
 na8gJu1rVT0t818qqSyKBSvoFg/AdFaHc+RX8c7ROhnV8ZGXBKwnBMcxACtMqMwKhMlu1ev
 AaNZbv+arMmGmavrsvtH6wolNqAxqrKxH7BrKvHGC0KOEGNIb4lYnOhOkTlcrxqL66g0pU2
 pgnwXRhQY40k11xY2i7lwKZaSlaQfLdRqIh60Zysgb+EhSDogKn3vCr9wTMw==
Received: from localhost (localhost [127.0.0.1])
 by mailgw101.it.ntnu.no (Postfix) with ESMTP id 14B2A1DE1F78
 for <bug-gnu-emacs@HIDDEN>; Sun, 14 Nov 2021 14:50:06 +0100 (CET)
X-Virus-Scanned: Debian amavisd-new at mailgw101.it.ntnu.no
X-Spam-Flag: NO
X-Spam-Score: -4.59
X-Spam-Level: 
Received: from mailgw101.it.ntnu.no ([127.0.0.1])
 by localhost (mailgw101.it.ntnu.no [127.0.0.1]) (amavisd-new, port 10024)
 with ESMTP id uBtqlhS1Mts4 for <bug-gnu-emacs@HIDDEN>;
 Sun, 14 Nov 2021 14:50:05 +0100 (CET)
Received: from localhost (unknown [37.120.203.82])
 (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)
 key-exchange ECDHE (P-256) server-signature RSA-PSS (4096 bits) server-digest
 SHA256) (No client certificate requested)
 (Authenticated sender: takringe@HIDDEN)
 by mailgw101.it.ntnu.no (Postfix) with ESMTPSA id 917E81DE11F2
 for <bug-gnu-emacs@HIDDEN>; Sun, 14 Nov 2021 14:50:05 +0100 (CET)
From: Tor Kringeland <tor.a.s.kringeland@HIDDEN>
Date: Sun, 14 Nov 2021 14:50:01 +0100
Message-ID: <m2r1bietiu.fsf@HIDDEN>
MIME-Version: 1.0
Content-Type: text/plain
Received-SPF: pass client-ip=129.241.56.177;
 envelope-from=tor.a.s.kringeland@HIDDEN; helo=mailgw101.it.ntnu.no
X-Spam_score_int: -20
X-Spam_score: -2.1
X-Spam_bar: --
X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1,
 DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1,
 RCVD_IN_MSPIKE_H4=-0.01, RCVD_IN_MSPIKE_WL=-0.01, SPF_HELO_NONE=0.001,
 SPF_PASS=-0.001 autolearn=ham autolearn_force=no
X-Spam_action: no action
X-Spam-Score: -1.6 (-)
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.6 (--)

Using e.g. `ispell' with an English dictionary and setting
`ispell-personal-dictionary' to, say, `/tmp/words.txt' will add new
words to this file when using this dictionary.  However, if I change the
dictionary to something else (like a Norwegian dictionary), I get the
following output

  Starting new Ispell process /usr/local/bin/aspell with english dictionary...done
  ispell-init-process: Error: Expected language "nn" but got "en".

when running `ispell-word' on a misspelled word.  By extension this
breaks `flyspell-mode'.  If I set `ispell-personal-dictionary' back to
nil, though, things works as usual.

For reference this happens on a build of Emacs 29 from 11 November using
`-Q' on macOS Catalina, though I remember having this problem for quite
some time.




Message sent:


Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable
MIME-Version: 1.0
X-Mailer: MIME-tools 5.505 (Entity 5.505)
Content-Type: text/plain; charset=utf-8
X-Loop: help-debbugs@HIDDEN
From: help-debbugs@HIDDEN (GNU bug Tracking System)
To: Tor Kringeland <tor.a.s.kringeland@HIDDEN>
Subject: bug#51843: Acknowledgement (Ispell personal dictionary breaks
 other dictionaries)
Message-ID: <handler.51843.B.163689781423907.ack <at> debbugs.gnu.org>
References: <m2r1bietiu.fsf@HIDDEN>
X-Gnu-PR-Message: ack 51843
X-Gnu-PR-Package: emacs
Reply-To: 51843 <at> debbugs.gnu.org
Date: Sun, 14 Nov 2021 13:51:01 +0000

Thank you for filing a new bug report with debbugs.gnu.org.

This is an automatically generated reply to let you know your message
has been received.

Your message is being forwarded to the package maintainers and other
interested parties for their attention; they will reply in due course.

Your message has been sent to the package maintainer(s):
 bug-gnu-emacs@HIDDEN

If you wish to submit further information on this problem, please
send it to 51843 <at> debbugs.gnu.org.

Please do not send mail to help-debbugs@HIDDEN unless you wish
to report a problem with the Bug-tracking system.

--=20
51843: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=3D51843
GNU Bug Tracking System
Contact help-debbugs@HIDDEN with problems


Message sent to bug-gnu-emacs@HIDDEN:


X-Loop: help-debbugs@HIDDEN
Subject: bug#51843: Ispell personal dictionary breaks other dictionaries
Resent-From: Eli Zaretskii <eliz@HIDDEN>
Original-Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
Resent-CC: bug-gnu-emacs@HIDDEN
Resent-Date: Sun, 14 Nov 2021 14:32:03 +0000
Resent-Message-ID: <handler.51843.B51843.163690029528292 <at> debbugs.gnu.org>
Resent-Sender: help-debbugs@HIDDEN
X-GNU-PR-Message: followup 51843
X-GNU-PR-Package: emacs
X-GNU-PR-Keywords: 
To: Tor Kringeland <tor.a.s.kringeland@HIDDEN>
Cc: 51843 <at> debbugs.gnu.org
Received: via spool by 51843-submit <at> debbugs.gnu.org id=B51843.163690029528292
          (code B ref 51843); Sun, 14 Nov 2021 14:32:03 +0000
Received: (at 51843) by debbugs.gnu.org; 14 Nov 2021 14:31:35 +0000
Received: from localhost ([127.0.0.1]:49578 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1mmGXf-0007ME-Fp
	for submit <at> debbugs.gnu.org; Sun, 14 Nov 2021 09:31:35 -0500
Received: from eggs.gnu.org ([209.51.188.92]:49618)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <eliz@HIDDEN>) id 1mmGXd-0007Lv-Vb
 for 51843 <at> debbugs.gnu.org; Sun, 14 Nov 2021 09:31:34 -0500
Received: from [2001:470:142:3::e] (port=55204 helo=fencepost.gnu.org)
 by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <eliz@HIDDEN>)
 id 1mmGXY-00064E-D3; Sun, 14 Nov 2021 09:31:28 -0500
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org;
 s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date:
 mime-version; bh=eg25EoAMGr0H66S4HX362wtxSpwVUQ+ubVIHXLnEm4Q=; b=i2TekU7nEU0a
 aI/MWGL5qw7g5zV521vayo1IL5NGTdGG9wmLu0TwWwqTQQI/yMiEGxA1evXNyRZjT6AQOpHJo9egi
 78bNYeI5AvJzCM9tTHMrdDzWbVBjBlNH52VBbFk4fRZ6zaxKVTCF0LXA5b8U226g4DoMGAcCHdRup
 4MezttXId+KV4YjTWdAX39vcIKarz/abd8UPtMjBmrLyeXVPecuwC30LNKCZ7byCmIFVxM8GEMIAp
 ztW4SMy4BjRJHsLZ4K9c19TUfoFP5lkt3t+2kLeSLESS+zLDgwcd/jFrlAuPj6pUn02DYEJtblX/1
 +1OJxc/Ait6VqyRjJG/NLg==;
Received: from [87.69.77.57] (port=3617 helo=home-c4e4a596f7)
 by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <eliz@HIDDEN>)
 id 1mmGXX-0008KY-Vz; Sun, 14 Nov 2021 09:31:28 -0500
Date: Sun, 14 Nov 2021 16:31:14 +0200
Message-Id: <834k8evmfh.fsf@HIDDEN>
From: Eli Zaretskii <eliz@HIDDEN>
In-Reply-To: <m2r1bietiu.fsf@HIDDEN> (message from Tor Kringeland on Sun, 14
 Nov 2021 14:50:01 +0100)
References: <m2r1bietiu.fsf@HIDDEN>
X-Spam-Score: -2.3 (--)
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: Tor Kringeland <tor.a.s.kringeland@HIDDEN>
> Date: Sun, 14 Nov 2021 14:50:01 +0100
> 
> Using e.g. `ispell' with an English dictionary and setting
> `ispell-personal-dictionary' to, say, `/tmp/words.txt' will add new
> words to this file when using this dictionary.  However, if I change the
> dictionary to something else (like a Norwegian dictionary), I get the
> following output
> 
>   Starting new Ispell process /usr/local/bin/aspell with english dictionary...done
>   ispell-init-process: Error: Expected language "nn" but got "en".
> 
> when running `ispell-word' on a misspelled word.  By extension this
> breaks `flyspell-mode'.  If I set `ispell-personal-dictionary' back to
> nil, though, things works as usual.
> 
> For reference this happens on a build of Emacs 29 from 11 November using
> `-Q' on macOS Catalina, though I remember having this problem for quite
> some time.

Isn't this the same problem with the LANG setting in the environment?




Message sent to bug-gnu-emacs@HIDDEN:


X-Loop: help-debbugs@HIDDEN
Subject: bug#51843: Ispell personal dictionary breaks other dictionaries
Resent-From: Tor Kringeland <tor.a.s.kringeland@HIDDEN>
Original-Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
Resent-CC: bug-gnu-emacs@HIDDEN
Resent-Date: Sun, 14 Nov 2021 15:30:02 +0000
Resent-Message-ID: <handler.51843.B51843.163690377511750 <at> debbugs.gnu.org>
Resent-Sender: help-debbugs@HIDDEN
X-GNU-PR-Message: followup 51843
X-GNU-PR-Package: emacs
X-GNU-PR-Keywords: 
To: Eli Zaretskii <eliz@HIDDEN>
Cc: 51843 <at> debbugs.gnu.org
Received: via spool by 51843-submit <at> debbugs.gnu.org id=B51843.163690377511750
          (code B ref 51843); Sun, 14 Nov 2021 15:30:02 +0000
Received: (at 51843) by debbugs.gnu.org; 14 Nov 2021 15:29:35 +0000
Received: from localhost ([127.0.0.1]:51364 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1mmHRm-00033S-QT
	for submit <at> debbugs.gnu.org; Sun, 14 Nov 2021 10:29:35 -0500
Received: from mailgw201.it.ntnu.no ([129.241.56.178]:52868)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <tor.a.s.kringeland@HIDDEN>) id 1mmHRk-00033J-DR
 for 51843 <at> debbugs.gnu.org; Sun, 14 Nov 2021 10:29:33 -0500
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=ntnu.no;
 i=@ntnu.no; q=dns/txt; s=s1-1909-ntnu; t=1636903770; h=from : to : cc
 : subject : in-reply-to : references : date : message-id :
 mime-version : content-type : from;
 bh=Q1PniOhTsLeVBr3vhpVVxLQZWzpdKQTvJSnCB/YnCRQ=;
 b=fdyA9SlqHk86QQsAQQQ0UZfOulTFsE+xsX+zfeTRn8tMd8WEgYp1Dkpk4Hb2AaXOevk9Z
 t9q1cCeIInkRmQbcJsHo7w8rSfGPhjx1jJgQ+xaXdg8eRBj9mclQQiPIBFIkaMPJ7OAF2Ln
 9VVvYr3i9GkPPkKUWyNmaLHZOjcOgCcPgMvdr/qMwlmtLJj0jkavKtiKFDJj6/xd9MtRDxR
 UEulbGp81CAUYPvelfgm4e03ms43tqq2WlmaEh1CNphsZm6cykEDODke0IZtqu6o7KCf5Ey
 jxQCbHkZwNlWt6W/MsSEikY02RBkpyyJj4awbiXET7YXrxlBcMFOiObxQmGQ==
Received: from localhost (localhost [127.0.0.1])
 by mailgw201.it.ntnu.no (Postfix) with ESMTP id D38F99028D0;
 Sun, 14 Nov 2021 16:29:30 +0100 (CET)
X-Virus-Scanned: Debian amavisd-new at mailgw201.it.ntnu.no
X-Spam-Flag: NO
X-Spam-Score: -4.59
X-Spam-Level: 
Received: from mailgw201.it.ntnu.no ([127.0.0.1])
 by localhost (mailgw201.it.ntnu.no [127.0.0.1]) (amavisd-new, port 10024)
 with ESMTP id r_fs2vYjRHFa; Sun, 14 Nov 2021 16:29:30 +0100 (CET)
Received: from localhost (unknown [37.120.203.82])
 (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)
 key-exchange ECDHE (P-256) server-signature RSA-PSS (4096 bits) server-digest
 SHA256) (No client certificate requested)
 (Authenticated sender: takringe@HIDDEN)
 by mailgw201.it.ntnu.no (Postfix) with ESMTPSA id 71B169028AE;
 Sun, 14 Nov 2021 16:29:30 +0100 (CET)
From: Tor Kringeland <tor.a.s.kringeland@HIDDEN>
In-Reply-To: <834k8evmfh.fsf@HIDDEN>
References: <m2r1bietiu.fsf@HIDDEN> <834k8evmfh.fsf@HIDDEN>
Date: Sun, 14 Nov 2021 16:29:29 +0100
Message-ID: <m27ddaeox2.fsf@HIDDEN>
MIME-Version: 1.0
Content-Type: text/plain
X-Spam-Score: 0.0 (/)
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:

> Isn't this the same problem with the LANG setting in the environment?

I don't think so.  The issues seems to be a disparity between the
language codes for the personal dictionary (you can only have a personal
dictionary for one language) and the main dictionary.  The header of
`/tmp/words.txt' is

  personal_ws-1.1 en 1

where the `en' refers to the language/dictionary and `1' refers to the
number of words in your personal dictionary.  If I initiate a personal
dictionary with, say, Norwegian, the header looks like

  personal_ws-1.1 nn 1

and I get the opposite problem (that it works for Norwegian but not
English).

I suspect the error comes from `ispell' feeding these two disparate
language codes to `aspell': it tries to combine two dictionaries for two
different languages and `aspell' complains.  But I'm not certain this is
the case, as I don't understand well the code in `ispell.el'.

A possible fix would be to have an `ispell-personal-dictionaries-alist'
in which one could specify different personal dictionaries for different
language codes/dictionaries, which would be a feature improvement.
Another fix would be for `ispell' to check for disparity in language
code of the current dictionary and the personal dictionary, and if there
is one, to not feed the personal dictionary into `ispell-program-name'.

Are you able to reproduce the issue?

(Sorry for re-sending, I forgot to CC the mailing list.)




Message sent to bug-gnu-emacs@HIDDEN:


X-Loop: help-debbugs@HIDDEN
Subject: bug#51843: Ispell personal dictionary breaks other dictionaries
Resent-From: Eli Zaretskii <eliz@HIDDEN>
Original-Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
Resent-CC: bug-gnu-emacs@HIDDEN
Resent-Date: Sun, 14 Nov 2021 16:11:02 +0000
Resent-Message-ID: <handler.51843.B51843.163690624515961 <at> debbugs.gnu.org>
Resent-Sender: help-debbugs@HIDDEN
X-GNU-PR-Message: followup 51843
X-GNU-PR-Package: emacs
X-GNU-PR-Keywords: 
To: Tor Kringeland <tor.a.s.kringeland@HIDDEN>
Cc: 51843 <at> debbugs.gnu.org
Received: via spool by 51843-submit <at> debbugs.gnu.org id=B51843.163690624515961
          (code B ref 51843); Sun, 14 Nov 2021 16:11:02 +0000
Received: (at 51843) by debbugs.gnu.org; 14 Nov 2021 16:10:45 +0000
Received: from localhost ([127.0.0.1]:51399 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1mmI5c-00049N-KL
	for submit <at> debbugs.gnu.org; Sun, 14 Nov 2021 11:10:44 -0500
Received: from eggs.gnu.org ([209.51.188.92]:33516)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <eliz@HIDDEN>) id 1mmI5a-00049A-MK
 for 51843 <at> debbugs.gnu.org; Sun, 14 Nov 2021 11:10:43 -0500
Received: from [2001:470:142:3::e] (port=57036 helo=fencepost.gnu.org)
 by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <eliz@HIDDEN>)
 id 1mmI5V-0008Li-28; Sun, 14 Nov 2021 11:10:37 -0500
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org;
 s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date:
 mime-version; bh=zI9u3sjAxPPsG387mlrvrQxBgZzf/eDPxbd8Ar7FZp4=; b=KHYS7EJXN45n
 0uwpOUMsGwZbm62kXMB/cRcdtbBpsNVEdr3qnq4aAVP6gdwUKSGlcmLRmi8VWorigE13aCpLsvuw+
 xD2TLuKSyKdBY+Ao6uczAP31C6NJivLvlZBOIIrUwLC6CT/Ec+LoP7lh4+BiHVgjMCHQ0x42InBBB
 Ks0D3XLHQIoR6pyZ2rYTeEF193NrLKVu0+vcb5sSlAN8SWuMmRcDA/m2s8YKZANMtIORwrTU0doJD
 nXrpBXt5Z/MniqNcGF8T9ey3LZ7nhkYp6SkSEb6ukLHzwCpV70UmIym9Ql5GlnwfqSum+UIoN88Ho
 uKdujhpWQM3+LoEisYm/NA==;
Received: from [87.69.77.57] (port=1821 helo=home-c4e4a596f7)
 by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <eliz@HIDDEN>)
 id 1mmI5U-0000sN-Mn; Sun, 14 Nov 2021 11:10:37 -0500
Date: Sun, 14 Nov 2021 18:10:22 +0200
Message-Id: <83y25qu39t.fsf@HIDDEN>
From: Eli Zaretskii <eliz@HIDDEN>
In-Reply-To: <m2czn2eozf.fsf@HIDDEN> (message from Tor Kringeland on Sun, 14
 Nov 2021 16:28:04 +0100)
References: <m2r1bietiu.fsf@HIDDEN> <834k8evmfh.fsf@HIDDEN>
 <m2czn2eozf.fsf@HIDDEN>
X-Spam-Score: -2.3 (--)
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 (---)

[Please use Reply All to reply, so that the bug tracker gets a copy.]

> From: Tor Kringeland <tor.a.s.kringeland@HIDDEN>
> Date: Sun, 14 Nov 2021 16:28:04 +0100
> 
> Eli Zaretskii <eliz@HIDDEN> writes:
> 
> > Isn't this the same problem with the LANG setting in the environment?
> 
> I don't think so.  The issues seems to be a disparity between the
> language codes for the personal dictionary (you can only have a personal
> dictionary for one language) and the main dictionary.  The header of
> `/tmp/words.txt' is
> 
>   personal_ws-1.1 en 1
> 
> where the `en' refers to the language/dictionary and `1' refers to the
> number of words in your personal dictionary.  If I initiate a personal
> dictionary with, say, Norwegian, the header looks like
> 
>   personal_ws-1.1 nn 1
> 
> and I get the opposite problem (that it works for Norwegian but not
> English).

How do you initiate the personal dictionary?

> I suspect the error comes from `ispell' feeding these two disparate
> language codes to `aspell': it tries to combine two dictionaries for two
> different languages and `aspell' complains.  But I'm not certain this is
> the case, as I don't understand well the code in `ispell.el'.

Does the same problem happen if you invoke Aspell from the shell,
passing it the Norwegian language and the personal dictionary for
English?

> A possible fix would be to have an `ispell-personal-dictionaries-alist'
> in which one could specify different personal dictionaries for different
> language codes/dictionaries, which would be a feature improvement.
> Another fix would be for `ispell' to check for disparity in language
> code of the current dictionary and the personal dictionary, and if there
> is one, to not feed the personal dictionary into `ispell-program-name'.
> 
> Are you able to reproduce the issue?

I don't use Aspell.  I use Hunspell, where this problem doesn't exist,
and where you can have a separate personal dictionary for each
language.




Message sent to bug-gnu-emacs@HIDDEN:


X-Loop: help-debbugs@HIDDEN
Subject: bug#51843: Ispell personal dictionary breaks other dictionaries
Resent-From: Tor Kringeland <tor.a.s.kringeland@HIDDEN>
Original-Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
Resent-CC: bug-gnu-emacs@HIDDEN
Resent-Date: Sun, 14 Nov 2021 16:48:01 +0000
Resent-Message-ID: <handler.51843.B51843.163690846919809 <at> debbugs.gnu.org>
Resent-Sender: help-debbugs@HIDDEN
X-GNU-PR-Message: followup 51843
X-GNU-PR-Package: emacs
X-GNU-PR-Keywords: 
To: Eli Zaretskii <eliz@HIDDEN>
Cc: 51843 <at> debbugs.gnu.org
Received: via spool by 51843-submit <at> debbugs.gnu.org id=B51843.163690846919809
          (code B ref 51843); Sun, 14 Nov 2021 16:48:01 +0000
Received: (at 51843) by debbugs.gnu.org; 14 Nov 2021 16:47:49 +0000
Received: from localhost ([127.0.0.1]:51455 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1mmIfV-00059R-C9
	for submit <at> debbugs.gnu.org; Sun, 14 Nov 2021 11:47:49 -0500
Received: from mailgw101.it.ntnu.no ([129.241.56.177]:50188)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <tor.a.s.kringeland@HIDDEN>) id 1mmIfS-00059G-Qm
 for 51843 <at> debbugs.gnu.org; Sun, 14 Nov 2021 11:47:48 -0500
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=ntnu.no;
 i=@ntnu.no; q=dns/txt; s=s1-1909-ntnu; t=1636908464; h=from : to : cc
 : subject : in-reply-to : references : date : message-id :
 mime-version : content-type : from;
 bh=yA2xvJ3yIkFa9AlkkUjZNpAloIQpoG1VD2xm8jgsxT8=;
 b=lumY7fO3v+0HnyFEk42DwFb8gl3WwmdGD8GCjTA3c8ze4ZMH0LDoky13+Wr7A7RDzl06V
 zJ3Bv+XLy4g3zNZuynxUkRbaH9duqX2BYAuJmLyLDFgG4eiy9DdbIbD9FZ6ybz1qrNDM5Sq
 NORcdiZvB6el3D0QdQ/O8WwhSHBagxCQiKDql86rIGFmw7P6aEFAtJc8P9eHE/PgMwPxAlZ
 4amnGEBVnmNVmckuF0iT0H0XjajdjEZTTBQl8W/qbRIzjF/wd3eXNhp1Lec0EsT7DqfSqcd
 zS7pndkm4F7IV4d4kFacSPBTdh2G+8wxUkxMS7GdtSV4NzofXnsd4GqyAudQ==
Received: from localhost (localhost [127.0.0.1])
 by mailgw101.it.ntnu.no (Postfix) with ESMTP id D3CD81DE27D0;
 Sun, 14 Nov 2021 17:47:44 +0100 (CET)
X-Virus-Scanned: Debian amavisd-new at mailgw101.it.ntnu.no
X-Spam-Flag: NO
X-Spam-Score: -4.59
X-Spam-Level: 
Received: from mailgw101.it.ntnu.no ([127.0.0.1])
 by localhost (mailgw101.it.ntnu.no [127.0.0.1]) (amavisd-new, port 10024)
 with ESMTP id 5z7h5I1vThwO; Sun, 14 Nov 2021 17:47:44 +0100 (CET)
Received: from localhost (unknown [37.120.203.82])
 (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)
 key-exchange ECDHE (P-256) server-signature RSA-PSS (4096 bits) server-digest
 SHA256) (No client certificate requested)
 (Authenticated sender: takringe@HIDDEN)
 by mailgw101.it.ntnu.no (Postfix) with ESMTPSA id 2CB241DE279D;
 Sun, 14 Nov 2021 17:47:44 +0100 (CET)
From: Tor Kringeland <tor.a.s.kringeland@HIDDEN>
In-Reply-To: <83y25qu39t.fsf@HIDDEN>
References: <m2r1bietiu.fsf@HIDDEN> <834k8evmfh.fsf@HIDDEN>
 <m2czn2eozf.fsf@HIDDEN> <83y25qu39t.fsf@HIDDEN>
Date: Sun, 14 Nov 2021 17:47:42 +0100
Message-ID: <m2czn2d6q9.fsf@HIDDEN>
MIME-Version: 1.0
Content-Type: text/plain
X-Spam-Score: -0.0 (/)
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:

> [Please use Reply All to reply, so that the bug tracker gets a copy.]
>
>> From: Tor Kringeland <tor.a.s.kringeland@HIDDEN>
>> Date: Sun, 14 Nov 2021 16:28:04 +0100
>> 
>> Eli Zaretskii <eliz@HIDDEN> writes:
>> 
>> > Isn't this the same problem with the LANG setting in the environment?
>> 
>> I don't think so.  The issues seems to be a disparity between the
>> language codes for the personal dictionary (you can only have a personal
>> dictionary for one language) and the main dictionary.  The header of
>> `/tmp/words.txt' is
>> 
>>   personal_ws-1.1 en 1
>> 
>> where the `en' refers to the language/dictionary and `1' refers to the
>> number of words in your personal dictionary.  If I initiate a personal
>> dictionary with, say, Norwegian, the header looks like
>> 
>>   personal_ws-1.1 nn 1
>> 
>> and I get the opposite problem (that it works for Norwegian but not
>> English).
>
> How do you initiate the personal dictionary?

By setting `ispell-personal-dictionary' to point at a non-existent file.
It then creates the file with the language code for the current
dictionary.

>> I suspect the error comes from `ispell' feeding these two disparate
>> language codes to `aspell': it tries to combine two dictionaries for two
>> different languages and `aspell' complains.  But I'm not certain this is
>> the case, as I don't understand well the code in `ispell.el'.
>
> Does the same problem happen if you invoke Aspell from the shell,
> passing it the Norwegian language and the personal dictionary for
> English?

Yes.  If `/tmp/words.txt' is

  personal_ws-1.1 en 1
  mysterious

running

  echo -n mystiks | aspell -a --lang=nn_NO -p /tmp/words.txt

outputs `Error: Expected language "nn" but got "en".' similar to the
error using `ispell' in Emacs.  Running the following similar command
with `hunspell'

  echo -n mystiks | hunspell -a -d nn_NO -p /tmp/words.txt

gives no complaints and suggests the word is a typo for `mystisk'.

One could argue that the behavior of `hunspell' is not the correct one
here, since we're using dictionaries of two different languages and it
could have yielded a warning at least.  But this has nothing to do with
Emacs.

But given that this is "undefined behavior" for spell checkers one can
use with `ispell', it would be good if Emacs could sanity check the
language code of the personal dictionary with that of the main one and
not include the former if there is a disparity --- or optionally being
able to set personal dictionaries for multiple language codes.





Last modified: Sun, 14 Nov 2021 17:00:02 UTC

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