unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: Eli Zaretskii <eliz@gnu.org>
To: Eshel Yaron <me@eshelyaron.com>
Cc: 74437@debbugs.gnu.org, mail@alternateved.com
Subject: bug#74437: 30.0.92; completion-preview-idle-delay is delayed by flyspell
Date: Wed, 20 Nov 2024 15:04:29 +0200	[thread overview]
Message-ID: <86sermrr8i.fsf@gnu.org> (raw)
In-Reply-To: <m14j43dlmv.fsf@macbookpro.home> (message from Eshel Yaron on Tue, 19 Nov 2024 21:16:56 +0100)

> From: Eshel Yaron <me@eshelyaron.com>
> Cc: 74437@debbugs.gnu.org,  mail@alternateved.com
> Date: Tue, 19 Nov 2024 21:16:56 +0100
> 
> >> -                           (accept-process-output ispell-process)
> >> +                           (accept-process-output ispell-process 1)
> >
> > Does this really work reliably from a timer?
> 
> I don't immediately see why it shouldn't, and the tests I tried so far
> seem to work, but your skepticism makes me wonder if there's anything
> I'm missing.  Do you have any particular potential issue in mind?

Not concretely, no.  But I see potential issues, since
accept-process-output enters a recursive wait_reading_process_output,
which could read output from other subprocesses, and timers affect how
frequently wait_reading_process_output loops.  So this should be
thoroughly tested in various scenarios.

> > You _are_ aware that this call to accept-process-output will run
> > timers while we wait?
> 
> Yes.  If that's a cause for concern, we can inhibit running timers here
> when we're calling flyspell-word from a timer, like in the patch below.

That's one measure, yes.  But it, too, should be thoroughly tested.

> > Also, what happens if there are other async
> > subprocesses running in parallel, like maybe Grep or compilation or
> > url-retrieve?
> 
> They make progress, which seems to work as expected, at least with Grep.
> That is if we use the previous patch, with the one below we pass non-nil
> JUST-THIS-ONE argument to accept-process-output when called from a timer
> so other processes shouldn't see new output during this call.  Either
> way works, AFAICT.

The question is: what do users expect to happen in those cases?





  reply	other threads:[~2024-11-20 13:04 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-11-19 11:55 bug#74437: 30.0.92; completion-preview-idle-delay is delayed by flyspell Tomasz Hołubowicz via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-11-19 16:13 ` Eshel Yaron via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-11-19 16:56   ` Tomasz Hołubowicz via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-11-19 17:19   ` Eli Zaretskii
2024-11-19 18:40     ` Eshel Yaron via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-11-19 19:10       ` Eli Zaretskii
2024-11-19 20:16         ` Eshel Yaron via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-11-20 13:04           ` Eli Zaretskii [this message]
2024-11-20 15:52             ` Eshel Yaron via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-11-20 16:29               ` 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=86sermrr8i.fsf@gnu.org \
    --to=eliz@gnu.org \
    --cc=74437@debbugs.gnu.org \
    --cc=mail@alternateved.com \
    --cc=me@eshelyaron.com \
    /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).