Skip to content
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

I can't upload webp file into Media Library #119

Closed
wojtekn opened this issue May 13, 2024 · 6 comments
Closed

I can't upload webp file into Media Library #119

wojtekn opened this issue May 13, 2024 · 6 comments

Comments

@wojtekn
Copy link
Contributor

wojtekn commented May 13, 2024

Quick summary

Users can't upload webp files in Studio. It looks like it doesn't work in https://playground.wordpress.net/, too.

Steps to reproduce

  1. Download webp file from https://developers.google.com/speed/webp/gallery1
  2. Create a site in Studio and open WP Admin
  3. Navigate to Media -> Add New Media File
  4. Drag the downloaded file to upload it

What you expected to happen

The file is uploaded.

What actually happened

Error is displauyed

Screenshot 2024-05-13 at 11 24 28 displayed

Impact

Most (> 50%)

Available workarounds?

Yes, easy to implement

Platform

Mac Silicon

Logs or notes

No response

@sejas
Copy link
Member

sejas commented May 13, 2024

Currently, there is a workaround to upload webp files:
If a user renames the file from .webp to .jpg, then the file uploads correctly and with the correct extension (webp).

This workaround works in Playground and Studio.

Screencast

Here you can see the error and the workaround:

webp-error-and-workaround.mp4

@liviopv
Copy link

liviopv commented May 14, 2024

📌 REPRODUCTION RESULTS

  • Tested on Studio - Partially

📌 FINDINGS/SCREENSHOTS/VIDEO

  • Uploading directly to the media library - fails ❌
  • Dragging into the editor - works ✅
  • Uploading through the editor via Image Block - works ✅
CleanShot.2024-05-14.at.12.26.04.mp4

📌 ACTIONS

  • Triaged

@liviopv liviopv added Triaged and removed Needs triage Ticket needs to be triaged labels May 14, 2024
@liviopv liviopv moved this from Needs Triage to Triaged in Automattic Prioritization: The One Board ™ May 14, 2024
@derekblank derekblank self-assigned this May 17, 2024
@derekblank
Copy link
Contributor

derekblank commented May 20, 2024

Just following up on this one - it seems like WebP support in Studio would be resolved when the changes from WordPress/wordpress-playground#1393 are published (and the @php-wasm/node dependency can be updated in Studio).

@sejas Does that sound correct? Anything else that can be done to help?

@sejas
Copy link
Member

sejas commented May 20, 2024

Exactly! That's correct! 👌
If you want, you can ask the Playground team to release a new version. If not, I can do it tomorrow morning.
Thanks!

@sejas
Copy link
Member

sejas commented May 21, 2024

@derekblank , php-wasm/node has been released with v0.7.20 https://www.npmjs.com/package/@php-wasm/node 👍

@sejas
Copy link
Member

sejas commented Sep 2, 2024

This has been fixed after updating the playground dependencies: #491
Kudos to @kozer and @jeroenpf ! 🎉

It will be available in the next Studio release.

I tested trunk, and I've been able to upload a webp image:

Screenshot 2024-09-02 at 14 21 05

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Development

No branches or pull requests

4 participants