unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: Reuben Thomas via "Bug reports for GNU Emacs, the Swiss army knife of text editors" <bug-gnu-emacs@gnu.org>
To: Eli Zaretskii <eliz@gnu.org>
Cc: 44318@debbugs.gnu.org, dinkonin <dinkonin@gmail.com>
Subject: bug#44318: 28.0.50; Problem with ispell/flyspell and ""enchant"" backend
Date: Sun, 1 Nov 2020 22:23:44 +0000	[thread overview]
Message-ID: <CAOnWdoj666B5ZwN8kXPuXbdrnDygX0_kejvMQJOo_zgMMjfMyA@mail.gmail.com> (raw)
In-Reply-To: <83k0v6hhzg.fsf@gnu.org>

[-- Attachment #1: Type: text/plain, Size: 1978 bytes --]

On Sat, 31 Oct 2020 at 09:17, Eli Zaretskii <eliz@gnu.org> wrote:

> > From: dinkonin <dinkonin@gmail.com>
> > Date: Sat, 31 Oct 2020 10:37:49 +0200
> > Cc: Reuben Thomas <rrt@sc3d.org>, 44318@debbugs.gnu.org
> >
> > I totally agree with you that this is an upstream problem and I have
> reported it there. But maybe I have not
> > worded my bug correctly (my English is lacking, sorry). Enchant is
> working everywhere else on the same
> > system i.e. in AbiWord, Vim, GtkSpell and gedit. It does not work only
> in Emacs, that's why I reported it here,
> > for the benefit of other Arch users using the package and Emacs.
>
> I don't know how it succeeds working in those other environments, but
> I don't think Emacs should work around clear problems in installing
> the spell-checker.
>

I've had a bit more time to think about this now, and I think I understand
better what is going on.

First, it's pretty obvious why this isn't a problem for programs other than
Emacs: they ignore the error messages.

I think Enchant is correct to generate the errors, as it shows that it has
been mis-installed. I looked at the Arch package, and it depends on
libvoikko, so I'm surprised you're getting these errors in the first place.

However, I think Emacs should be able (like other Enchant-using programs)
to cope with this problem, particularly as all it should have to do is
ignore stderr.

I think this can be achieved by changing the definition of
ispell--call-enchant-lsmod to:

(defun ispell--call-enchant-lsmod (&rest args)
  "Call enchant-lsmod with ARGS and return the output as string."
  (with-output-to-string
    (apply #'ispell-call-process
           (replace-regexp-in-string "enchant\\(-[0-9]\\)?\\'"
                                     "enchant-lsmod\\1"
                                     ispell-program-name)
           nil '(t nil) nil args)))

(I can't see any reason to use `with-current-buffer` either; am I missing
something?)

-- 
https://rrt.sc3d.org

[-- Attachment #2: Type: text/html, Size: 4104 bytes --]

  reply	other threads:[~2020-11-01 22:23 UTC|newest]

Thread overview: 26+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-10-29 20:25 bug#44318: 28.0.50; Problem with ispell/flyspell and ""enchant"" backend dinkonin
2020-10-30  7:38 ` Eli Zaretskii
2020-10-30 22:56   ` Reuben Thomas via Bug reports for GNU Emacs, the Swiss army knife of text editors
2020-10-31  7:29     ` Eli Zaretskii
2020-10-31  7:32     ` dinkonin
2020-10-31  7:50       ` Eli Zaretskii
2020-10-31  8:37         ` dinkonin
2020-10-31  9:17           ` Eli Zaretskii
2020-11-01 22:23             ` Reuben Thomas via Bug reports for GNU Emacs, the Swiss army knife of text editors [this message]
2020-11-02  3:34               ` Eli Zaretskii
2020-11-02  8:14                 ` dinkonin
2020-11-02 15:41                   ` Eli Zaretskii
2020-11-02  8:35                 ` Reuben Thomas via Bug reports for GNU Emacs, the Swiss army knife of text editors
2020-11-02 15:41                   ` dinkonin
2020-11-02 15:43                   ` Eli Zaretskii
2020-11-02 15:49                     ` Reuben Thomas via Bug reports for GNU Emacs, the Swiss army knife of text editors
2020-11-02 16:10                       ` Eli Zaretskii
2020-11-02 21:49                         ` Reuben Thomas via Bug reports for GNU Emacs, the Swiss army knife of text editors
2020-11-03 16:45                           ` Eli Zaretskii
2020-11-03 17:06                             ` Reuben Thomas via Bug reports for GNU Emacs, the Swiss army knife of text editors
     [not found]                             ` <CAOnWdohVdcVffjvptfJUjhRr1jdNn7H3PBzon0LvrR_cguPPow@mail.gmail.com>
     [not found]                               ` <835z6mcqyg.fsf@gnu.org>
2020-11-03 17:19                                 ` Reuben Thomas via Bug reports for GNU Emacs, the Swiss army knife of text editors
2020-11-03 17:31                                   ` Eli Zaretskii
2020-11-03 18:27                                     ` Reuben Thomas via Bug reports for GNU Emacs, the Swiss army knife of text editors
2020-11-03 18:50                                       ` Eli Zaretskii
2020-11-03 18:53                                         ` Reuben Thomas via Bug reports for GNU Emacs, the Swiss army knife of text editors
2020-11-03 19:39                                           ` Eli Zaretskii

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=CAOnWdoj666B5ZwN8kXPuXbdrnDygX0_kejvMQJOo_zgMMjfMyA@mail.gmail.com \
    --to=bug-gnu-emacs@gnu.org \
    --cc=44318@debbugs.gnu.org \
    --cc=dinkonin@gmail.com \
    --cc=eliz@gnu.org \
    --cc=rrt@sc3d.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).