-
-
Notifications
You must be signed in to change notification settings - Fork 147
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
macOS GUI fails with space in absolute filepath [FIX AVAILABLE FOR TESTING] #30
Comments
Confirming that this is with v2.0.0 or v2.0.1? |
I can't reproduce this issue. Here is a test with Crunch v2.0.1 from a subdirectory in my Desktop directory on macOS 10.12.6: If you are able to do so, try installing the command line executable and run the following inside the image directory:
and if that works, change to the desktop directory and execute this command:
We will see error reporting with the CLI tool. The GUI application uses the same Python script that defines the command line executable. This will provide a bit of guidance on where to start with this issue. Sorry for the troubles. |
hmm... are you able to link those images in the repository thread here? not sure what is causing that. |
It is a problem with pngquant execution. can you confirm that you see the same issue from any directory? Also can you modify the file names and remove the @ number from the path? wonder if that is causing it. |
|
All files are valid PNG:
|
And all process without issues with the command line executable:
|
I can't reproduce this. I can verify that all four files compress for me through the DnD GUI: I executed the pngquant and zopflipng command directly on each of the images from the pngquant and zopflipng that are embedded with the application package and I receive no errors. It executes without issues and all four files are compressed. Mind executing the following command from your terminal inside the directory that contains those images?
Let me know if you get an error message. |
Is there a space between POOL and F in the directory path? |
Yup, there is a space. I'll test without the space. One sec... |
Yup, that seems to have been the problem. No good on subfolders that have spaces in them. |
OK. Thanks for checking. That is a simple fix. I am not escaping spaces in the absolute paths to the files. Will push a fix for this tonight. |
Happy days! Well done on finding that one. 👍🏼 |
Thanks for reporting it! Will leave this open until I definitely have a fix for it. Will post here when available. |
Opened #38 with a fix for this. A dmg installer for v2.0.2-beta1 is available in this directory: https://github.com/chrissimpkins/Crunch/tree/path-space-escape-fix/installer Mind letting me know if this fixes the problem for you? It wasn't as trivial as I initially thought but I think that we have a fix here. I have confirmed that the macOS GUI now works with spaces in the directory paths +/- spaces in the filename. This means that all of these should now properly complete execution as of the v2.0.2-beta1 build whereas they would not before:
|
Ran the same test as last night and this morning. I can confirm it's working a treat now even if I have a space in the subfolder name (eg. POOL E/image.png). Thanks for taking care of that one Chris - big help as far as my workflow goes. 👍🏼 |
Excellent. Thanks for confirming that it is fixed and for taking the time to report this! I will get the patch out today. |
Fix released as v2.0.2. Homebrew cask update PR submitted Homebrew/homebrew-cask#47349. The Homebrew cask release should be available in the next several hours. Thanks for this report and your help with testing the fix @masey9! |
I noticed this evening that Crunch will only execute successfully when I drag in PNG files from my Mac desktop into the GUI. If I drag them in from a folder on the desktop (eg. desktop/folder/image.png) then crunching fails to execute.
@chrissimpkins edits below:
Fix available for testing in #38 for anyone who is affected by this issue. Please weigh in on whether this fixes it for you in this thread. Thanks.
The text was updated successfully, but these errors were encountered: