I guess the problem is not with the filename but with the file location. Or more specifically: that you’ve installed the new version of Image Viewer likely as a snap or flatpak, both of which use a security sandbox that probably limits in which locations Image Viewer may open files.
You show images from your ~/Desktop/123 and ~/Downloads directories open without trouble. Then you show that images from disk “D” with a directory name written in Farsi (I guess) don’t open. I don’t think the problem is with the filename or the directory name, but that this file is in a location that the new Image Viewer isn’t allowed to open files. Try copying the blender_logo (Blue Background) - for Desktop.png file to your ~/Downloads directory and I think the new Image Viewer can open it from there.
If you installed the new Image Viewer as a flatpak, you can additionally install the Flatseal flatpak and that allows you to configure where the new Image Viewer flatpak is allowed to open files. I don’t know Ubuntu or snap but likely there is something similar for snaps.