Lymphatus / caesium-image-compressor

Caesium is an image compression software that helps you store, send and share digital pictures, supporting JPG, PNG, WebP and TIFF formats. You can quickly reduce the file size (and resolution, if you want) by preserving the overall quality of the image.
https://saerasoft.com/caesium
GNU General Public License v3.0
3.31k stars 202 forks source link

Error: Cannot copy output file, check your permissions #264

Closed fengziX closed 2 months ago

fengziX commented 4 months ago

Describe the bug Error: Cannot copy output file, check your permissions

Software version 2.6.0

Operating System information windows10 run as admin

Screenshots QQ截图20240305135342

Application Log [2024-03-05 13:55:09.620][C] Failed to copy from "C:/Users/Administrator/Desktop/002.jpg" to "C:/Users/Administrator/Desktop/002.jpg" (:0, ) [2024-03-05 13:55:09.628][I] Compression ended successfully. Total images: 1 Uncompressed size: "1.51 MB" Compressed size: "1.51 MB" Elapsed time: 5920 ms [2024-03-05 13:55:12.139][I] Usage report sent successfully

fengziX commented 4 months ago

2.6.0 shows "Error: Cannot copy output file, check your permissions ", but use 2.5.1 compress the same files, it shows "Skipped: compressed file is bigger than original"

Lymphatus commented 4 months ago

I'm assuming is a problem related to #234 and its fix. I'll check it out.

JeckPeppinger commented 3 months ago

I had the same message for some images on ubuntu 23.10 and CIC v2.7.0

Lymphatus commented 3 months ago

@JeckPeppinger Can you please share detailed steps that lead to the problem? I'm trying to reproduce the issue myself. Would be helpful if you could also share all the compression options you are using (you can attach screenshots or you can find them by going to Preferences > Show Usage Data > Compression Options)

JeckPeppinger commented 3 months ago

hi, i checked and did not find a log or history that shows something useful. Will take care in the future and provide evidence if it happens again.

fengziX commented 3 months ago

@JeckPeppinger

It just looks like outputs the wrong "error".

It should be"Skipped: compressed file is bigger than original" , not "Error: Cannot copy output file, check your permissions ".

JeckPeppinger commented 2 months ago

Screenshot from 2024-04-23 22-38-16

captured the bug ... guess your hint that it should be the "skipped" message is correct.

Lymphatus commented 2 months ago

I was able to reproduce the bug and pushed a tentative fix. As you said, the message was wrong because the app was not really dealing with the extension change in filename. Should work as expected now and I'm gonna publish the fix on 2.7.0.