mifi / lossless-cut

The swiss army knife of lossless video/audio editing
GNU General Public License v2.0
24.24k stars 1.21k forks source link

"File not natively supported" error when folder contains backslash #1941

Closed pentool closed 3 months ago

pentool commented 3 months ago

The fewer issues I have to read, the more new features I will have time to implement, so I ask that you please try these things first

Operating System

MacOS 12

Steps to reproduce

I had this infuriating issue recently. I opened a video file from my action camera (Osmo Action 3) and I got the following message: "File not natively supported. Preview may have no audio or low quality. The final export will however be lossless with audio. You may convert it from the menu for a better preview with audio."

I did not understand why am I getting this message. (Side note, the file didn't open with DaVinci Resolve either.) The file did open with iMove, QuickTime player, VLC, and Elmedia Player.

After pulling some of my hair out, it turned out I had a backslash in the containing folder name. I have quite a few folders with forward slash in the folder name, eg "This / That / Other". Apparently I did not pay attention and accidentally used backslahes, eg "This \ That \ Other" to name the containing folder.

In this case LosslessCut gives a confusing message by stating that "File is not natively supported..." blah blah and telling me that I might have to convert the file.

This is clearly incorrect because the problem was the backslash in the folder name () and not the file itself. Maybe this could be rectified because the message is confusing.

STEPS:

  1. Add a backslash character to the folder name somewhere whichi contains a supported video file.
  2. Try to open the file in LosslessCut.
  3. You will get a confusing message why the file cannot be open.
  4. Change the backslash character to a forward slash and now the file opens.

macOS 12.7.4 LosslessCut 3.59.1

Expected behavior

The file should either open, since there's nothing wrong with the file itself or somehow give a different message to the user if a backslash (or unsupported character) is detected in the path name.

Actual behavior

I described the actual behavior above.

Share log from developer tools

No response

mifi commented 3 months ago

thanks for the detailed report! i was able to reproduce the problem and will provide a fix