1.3.0 MacOs: Backup for lossless crop is not created

Reported bugs that have been closed and/or resolved

Moderators: XnTriq, helmut, xnview, Dreamer

esv
Posts: 43
Joined: Fri Sep 16, 2022 1:04 pm

1.3.0 MacOs: Backup for lossless crop is not created

Post by esv »

XnView: MP 1.3.0 64 bit
OS: macOS 10.15.7 64bit

(installed via HomeBrew cask from this xnviewmp.rb recipe)

Lossless crop operations do NOT create backup files (*.bak), which makes the operations irreversible :(
The relevant config is enabled: GeneralFile operationsMake backup for lossless crop menu item is enabled (check mark is present)

Effect: crop operations become irreversible, so a user risks losing valuable data

To reproduce:
1. Open a JPEG file myjpegfile.jpg
2. Select any area with a mouse
3. Select ToolsJPEG lossless transformationsCrop

Actual behaviour (bug): the crop succeeds, but no backup file is created
Expected behaviour: the crop succeeds and a backup file myjpegfile.bak is created

P.S.
This happens even in folders in which XnView MP has an explicit write access according to the Security & Privacy → Files and Folders system settings

I've tested the same 1.3.0 version on Windows and this option works fine: the backup files are created
Disabling/Enabling this option has no effect
Enabling the other option for lossless flip/rotation also fails (doesn't create any backup files)
User avatar
xnview
Author of XnView
Posts: 43444
Joined: Mon Oct 13, 2003 7:31 am
Location: France
Contact:

Re: 1.3.0 MacOs: Backup for lossless crop is not created

Post by xnview »

it works here, the file is on a NAS or shared folder?
Pierre.
esv
Posts: 43
Joined: Fri Sep 16, 2022 1:04 pm

Re: 1.3.0 MacOs: Backup for lossless crop is not created

Post by esv »

Thanks for a prompt response.
No, the file is a regular local file in the ~/Documents/Pictures folder or ~/Downloads
And I've tried with a fresh manual install (without homebrew) with the settings folder removed, unfortunately, nothing changed :(
User avatar
xnview
Author of XnView
Posts: 43444
Joined: Mon Oct 13, 2003 7:31 am
Location: France
Contact:

Re: 1.3.0 MacOs: Backup for lossless crop is not created

Post by xnview »

is it working if you make a lossless rotation?
Pierre.
esv
Posts: 43
Joined: Fri Sep 16, 2022 1:04 pm

Re: 1.3.0 MacOs: Backup for lossless crop is not created

Post by esv »

esv wrote: Fri Sep 16, 2022 4:50 pm Enabling the other option for lossless flip/rotation also fails (doesn't create any backup files)
User avatar
xnview
Author of XnView
Posts: 43444
Joined: Mon Oct 13, 2003 7:31 am
Location: France
Contact:

Re: 1.3.0 MacOs: Backup for lossless crop is not created

Post by xnview »

xnview wrote: Tue Sep 20, 2022 6:56 am is it working if you make a lossless rotation?
Not the setting, but if you make a lossless rotation and not a lossless crop?
Pierre.
esv
Posts: 43
Joined: Fri Sep 16, 2022 1:04 pm

Re: 1.3.0 MacOs: Backup for lossless crop is not created

Post by esv »

No backup is created for the other operations when the setting is enabled (I just mentioned the setting because it's off by default)
User avatar
xnview
Author of XnView
Posts: 43444
Joined: Mon Oct 13, 2003 7:31 am
Location: France
Contact:

Re: 1.3.0 MacOs: Backup for lossless crop is not created

Post by xnview »

i've tried to make lossless a rotation from browser, and a .xnbak is created
Pierre.
esv
Posts: 43
Joined: Fri Sep 16, 2022 1:04 pm

Re: 1.3.0 MacOs: Backup for lossless crop is not created

Post by esv »

xnview wrote: Wed Sep 21, 2022 8:03 am i've tried to make lossless a rotation from browser, and a .xnbak is created
Unfortunately, not on my machine, neither operations in the browser, nor operations in the viewer create any .xnbak files, but I do see them on Windows for the same operations
Is there a log or something I could check to see whether there are any errors? Any debug mode or something?
User avatar
xnview
Author of XnView
Posts: 43444
Joined: Mon Oct 13, 2003 7:31 am
Location: France
Contact:

Re: 1.3.0 MacOs: Backup for lossless crop is not created

Post by xnview »

esv wrote: Wed Sep 21, 2022 9:52 am Is there a log or something I could check to see whether there are any errors? Any debug mode or something?
I send you a PM
Pierre.
esv
Posts: 43
Joined: Fri Sep 16, 2022 1:04 pm

Re: 1.3.0 MacOs: Backup for lossless crop is not created

Post by esv »

Yep, this new version launched from the terminal works!
- I've deleted the old version and the old configs
- launched your app from the terminal
- changed config to save backup on lossless rotation
- rotated losslessly
and got my .xnbak.jpg file! and the Do lossless line showing creating of this backup file in the terminal
Will try the terminal trick with the app from the website
esv
Posts: 43
Joined: Fri Sep 16, 2022 1:04 pm

Re: 1.3.0 MacOs: Backup for lossless crop is not created

Post by esv »

And now the app from the website also works! Didn't change anything, pasted back all my old configs and didn't need to launch anything from the terminal, it works fine now as is.
Weird
Thanks for your help
User avatar
xnview
Author of XnView
Posts: 43444
Joined: Mon Oct 13, 2003 7:31 am
Location: France
Contact:

Re: 1.3.0 MacOs: Backup for lossless crop is not created

Post by xnview »

:shock:
Pierre.
esv
Posts: 43
Joined: Fri Sep 16, 2022 1:04 pm

Re: 1.3.0 MacOs: Backup for lossless crop is not created

Post by esv »

Weirder still, the bug is back again!
I've tried to fix it by repeating the steps above
- I've deleted the old version and the old configs
- downloaded your app (not the web version, though the new web version also failed) and extracted it to "Applications"
- launched your app from the terminal
- changed settings to save backup on lossless rotation as well
- rotated losslessly in the browser
- cropped losslessly in the viewer
and NO backup this time!

There is also no "Do lossless" line, below are the log lines for the two lossless rotations (for some reason the lossless crop operations don't leave any log items as I've confirmed in a separate test)

Code: Select all

===> losslessTransformation
ThumbLoaderThread :: stop()
BitmapLoadThread :: stop()
 other /Users/u/Downloads/1/test.jpeg


 LosslessTransform : /Users/u/Downloads/1/test.jpeg /Users/u/Downloads/1/test.jpe_
##### RENAME /Users/u/Downloads/1/test.jpe_ /Users/u/Downloads/1/test.jpeg n===> losslessTransformation end
ThumbLoaderThread :: stop()
### ThumbLoaderThread :: setFileList(1)
ThumbLoaderThread :: stop()
 ** start condition wake one 2
### ThumbLoaderThread :: setFileList ok
######ThumbLoaderThread :: forever 2 : b3e4ecd0
CHECK <1>
### START 1
######ThumbLoaderThread :: start : 1     -1 -1
LOAD BITMAP </Users/u/Downloads/1/test.jpeg>
===> losslessTransformation ok
GFF :: LoadThumbnail : 204 288  (0)
LOADED & CREATED
######ThumbLoaderThread :: forever : b3e4ecd0
 ** start condition wait



===> losslessTransformation
ThumbLoaderThread :: stop()
BitmapLoadThread :: stop()
 other /Users/u/Downloads/1/test.jpeg


 LosslessTransform : /Users/u/Downloads/1/test.jpeg /Users/u/Downloads/1/test.jpe_
##### RENAME /Users/u/Downloads/1/test.jpe_ /Users/u/Downloads/1/test.jpeg n===> losslessTransformation end
ThumbLoaderThread :: stop()
### ThumbLoaderThread :: setFileList(1)
ThumbLoaderThread :: stop()
 ** start condition wake one 2
### ThumbLoaderThread :: setFileList ok
######ThumbLoaderThread :: forever 2 : b3e4ecd0
CHECK <1>
### START 1
######ThumbLoaderThread :: start : 1     -1 -1
LOAD BITMAP </Users/u/Downloads/1/test.jpeg>
===> losslessTransformation ok
GFF :: LoadThumbnail : 384 272  (0)
LOADED & CREATED
User avatar
xnview
Author of XnView
Posts: 43444
Joined: Mon Oct 13, 2003 7:31 am
Location: France
Contact:

Re: 1.3.0 MacOs: Backup for lossless crop is not created

Post by xnview »

i think that i understand, the file is .jpeg not .jpg, could you try on .jpg?
Pierre.
Post Reply