Chocobozzz/PeerTube

Confusing error when using video/mov mimetype for uploading .mov files

Closed this issue · 2 comments

Describe the current behavior

Apparently on some Windows installs (like my friend's live media production machine) the system-wide mimetype registry has a nonstandard record for .mov files under HKEY_CLASSES_ROOT.

image

As web browsers defer to this registry to figure out the uploaded video's mimetype, the upload request sends video/mov instead of the standard video/quicktime that PeerTube is currently set up to accept, therefore the user is faced with an error telling them their format isn't supported even though .mov will be listed as a supported extension.

Steps to reproduce

  1. Install an application that changes the .mov mimetype to video/mov (not sure which one it is yet, but my hunch is Premiere)
  2. Try to upload a file with .mov extension to PeerTube
  3. Get rejected for invalid file type even though the error clearly lists .mov as a valid format

Describe the expected behavior

PeerTube either returns a different, more descriptive error, or caves and accepts video/mov mimetype for .mov files as well as video/quicktime even though it isn't standard, as this seems to be a somewhat common issue.
Another project that ran into this: immich-app/immich#1913

It might also be nice to log the rejected mimetype with the returned error to simplify troubleshooting similar issues.

Additional information

  • PeerTube instance:

  • Browser name, version and platforms on which you could reproduce the bug: Windows 10, both Chrome 129.0.6668.90 and Firefox 131.0.2, probably every browser that relies on OS mimetypes

I am on windows also and have had the same issue with .mov's . I have forgotten to report this issue.

Thanks! Should be fixed by 150d9f1