xanderfrangos / crushee

Desktop tool for batch image optimization and resizing. Available for Windows and Mac. Built with Electron and Node.js.
https://crushee.app
MIT License
73 stars 13 forks source link

French accent characters in file name prevent saving #77

Closed positlabs closed 2 years ago

positlabs commented 2 years ago

I get a "file not compatible" error message when trying to save this file: "large-Capture d’écran 2022-03-24 à 17.32.17.png"

Screen Shot 2022-04-05 at 9 27 09 AM

I'm pretty sure it's just an issue with the file name itself, and not the file, but here is the original in case it's helpful. Renaming the file allows me to process/save the image.

large-Capture d’écran 2022-03-24 à 17 32 17
xanderfrangos commented 2 years ago

Hi @positlabs,

I'm having trouble recreating this on my end. I set my MacOS language to French and then took a screen shot, but Crushee didn't have any issues. It looks like when the file was dropped into Crushee, MacOS hadn't fully saved it yet. Are you able to recreate this issue on your end? And if so, what are the exact steps to do so?

Thanks!

positlabs commented 2 years ago

I have my language set to english. Here are my laptop specs:

Screen Shot 2022-04-08 at 2 00 37 PM

I found it's an issue with "é", and "à" in the file name. This is all the same png file, just with different names.

Screen Shot 2022-04-08 at 2 03 45 PM
xanderfrangos commented 2 years ago

I'm not having any issues with those characters.

Screen Shot 2022-04-13 at 9 39 58 AM

The only difference I can see is that I'm on macOS Monterey. But I don't see why that should make a difference.

I'll see about making the name of the file less likely to affect anything, but I'm not actually able to replicate the issue on my end.

xanderfrangos commented 2 years ago

@positlabs I've released v2.4.1, which includes fixes that might affect your issue. Could you give it a try and let me know if you're still getting the errors? Thanks!

positlabs commented 2 years ago

It's still giving the error on 2.4.3

Screen Shot 2022-07-05 at 12 04 51 PM

éà

xanderfrangos commented 2 years ago

I'm not quite sure why this issue is affecting your Mac but not mine. Would you mind running Crushee from the Terminal and watching the output for anything that looks like an error (while processing the éà file)? Assuming the app is in your Applications folder, you should be able to start it by running: /Applications/Crushee.app/Contents/MacOS/Crushee

positlabs commented 2 years ago
josh@Joshs-MacBook-Pro ~ % /Applications/Crushee.app/Contents/MacOS/Crushee
Analytics: starting with UUID c53a9e7c-e5b7-4700-a3c1-5fa8d25dd7de
objc[92519]: Class WebSwapCGLLayer is implemented in both /System/Library/Frameworks/WebKit.framework/Versions/A/Frameworks/WebCore.framework/Versions/A/Frameworks/libANGLE-shared.dylib (0x7ffa5763a318) and /Applications/Crushee.app/Contents/Frameworks/Electron Framework.framework/Versions/A/Libraries/libGLESv2.dylib (0x110290ce0). One of the two will be used. Which one is undefined.
Cleaning old output files
Server Ready!

Done cleaning!
Thread 1 says "Thread ready!"
Thread 0 says "Thread ready!"
Thread 2 says "Thread ready!"
Adding thread 3
Adding thread 4
Adding thread 5

Thread 3 says "Thread ready!"
Thread 4 says "Thread ready!"
Thread 5 says "Thread ready!"
Analyzing /Users/josh/Desktop/éà.jpg
Thread 2 says "Recieved job 41b76d10-fe33-11ec-b43d-e76314a59ad8 | Current queue: 1"
Thread 2 says "Making previews..."
Thread 2 says "Finished job 41b76d10-fe33-11ec-b43d-e76314a59ad8 | Current queue: 0"
Thread 0 says "Recieved job 41b76d10-fe33-11ec-b43d-e76314a59ad8 | Current queue: 1"
Thread 0 says "Processing..."
Thread 0 says "Detected format:jpeg"
Thread 0 says "Requested output:jpeg"
Thread 0 says "MozJPEG compressing..."
Thread 0 says "Subsampling at 2x2"
Thread 0 says "MozJPEG compressing original..."
Thread 0 says "Subsampling at 2x2"
Thread 0 says "Compressing..."
===== RESULTS =====
original: 5.183kb
mozJPEG: 6.003kb
compressedOriginal: 5.183kb
mozOriginal: 6.032kb
compressed: 5.16kb
===================
Smallest size is compressed at 5.16 kb!
===================
Thread 0 says "Preparing final file..."
Thread 0 says "Writing timestamp..."
Thread 0 says "Clearing temp files..."
Thread 0 says "Done!"
Thread 0 says "Finished job 41b76d10-fe33-11ec-b43d-e76314a59ad8 | Current queue: 0"
ERROR: Could not save 41b76d10-fe33-11ec-b43d-e76314a59ad8
Analytics: Sending analytics
xanderfrangos commented 2 years ago

@positlabs Thanks! I've re-released v2.4.4 with a fix for this.

positlabs commented 2 years ago

You rock! I confirmed the fix. Thank you!

Screen Shot 2022-07-20 at 2 14 47 PM