Subject: bug#60896: dired-view-file vs. .7z

From: Eli Zaretskii <[email-masked]>
Date: Wed, 25 Jan 2023 14:21:59 +0200

> From: Dan Jacobson <[email-masked]>
> Cc: [email-masked],[email-masked]
> Date: Wed, 25 Jan 2023 10:51:43 +0800
> 
> Well, if the file is not in 7z format,
> then I hope dired-view-file would make an error message,
> like it does if a file is not in .gz format:
> ---
> Error while executing "gzip -c -q -d < /tmp/x.gz"
> 
> 
> gzip: stdin: not in gzip format

That gzip error message comes from the gzip program, not from Emacs.
What does 7z say in a similar case?  That's what dired-view-file
should show.