Subject: Re: bug#73231: 30.0.91; image-dired cannot be operated until all thumbnails are created (MS-Windows)

From: AKIYAMA Kouhei <[email-masked]>
Date: Sat, 14 Sep 2024 09:25:11 +0900

Thank you for your response.
# I forgot to CC it so I'll resend it. Sorry.

The error message you are referring to is "Unable to load image (image
:type jpeg ...)," correct? I had assumed that this message was
acceptable since it also appears when using ImageMagick. Are you
suggesting that this behavior was actually a bug? Do you believe it
would be better to change to synchronous processing and suppress the
error message even when using ImageMagick?

I understand that this error message is being triggered because the
image file, which does not yet exist, is specified in the "display"
text property (and because it tries to display when it enters the
window). Is this correct? If we fix that, it might be possible to
suppress the error message even in asynchronous processing.

Regarding the convert.exe issue on MS-Windows, the best solution I
recommend is using the magick command. In fact, the current Windows
version of the ImageMagick installer does not install the convert
command by default (you need to select "Install legacy utilities"). It
might be a good idea to provide an option that supports ImageMagick
v7, just as support was added for GraphicsMagick.

There are a few ways to reduce tests for the convert command, but the
most balanced one is to check only when the queue length is 0. You
probably wouldn't want to insert check code into each image-dired
command, right? (Though, it seems there are only a limited number of
commands that trigger thumbnail creation.)

Honestly, I believe a single check at startup should be
sufficient. Even if ImageMagick (with legacy utilities) is installed
while Emacs is running, it won’t be accessible unless the PATH
environment variable is updated. In the end, restarting Emacs is the
quickest solution. Of course, this is a different story if there is
already a directory (e.g., MSYS2 or Cygwin’s bin) prioritized over
System32 in your PATH, where you can place convert.exe (for safety, I
have MSYS2's bin placed after System32).
--
# This report was created using machine translation.
AKIYAMA Kouhei
[email-masked]