Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

fix: accept application/x-scratch3-sprite for sprite uploads #205

Open
wants to merge 1 commit into
base: develop
Choose a base branch
from

Conversation

cwillisf
Copy link
Contributor

Resolves

It seems likely that this issue was already filed, maybe years ago, but I couldn't find it. I found several issues suggesting that we do something about our MIME types, just... not this particular issue 😅

Proposed Changes

Add application/x-scratch3-sprite to the list of accepted "file types" for sprite upload.

Reason for Changes

Installing https://aur.archlinux.org/packages/scratch3 (or the -bin version) registers the application/x-scratch3-sprite type with the system (see /usr/share/mime/scratch3.xml), which is kinda cool, but it also causes certain browsers to report sprite3 files with that MIME type during file upload. So, if you have one of those two applications installed, sprite upload fails. That includes the copy of Chromium that I use for integration tests. Fun!

Test Coverage

Tested locally after investigating why integration tests were failing for me but passing on CI...

Installing <https://aur.archlinux.org/packages/scratch3> (or the `-bin`
version) registers the `application/x-scratch3-sprite` type with the
system (see `/usr/share/mime/scratch3.xml`), which is kinda cool, but it
also causes certain browsers to report `sprite3` files with that MIME
type during file upload. So, if you have one of those two applications
installed, sprite upload fails. That includes integration tests. Fun!
@cwillisf cwillisf requested a review from a team as a code owner February 24, 2025 23:35
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant