Problem/Motivation
In Drupal 10.3.2 or 10.3.3, while authoring a Media field referencing the Remote Video media type with the Media Library widget as a non-administrator, I'm unable to add a URL. This is true for both content types and taxonomy terms.
As an administrator, I can add a URL in this way.
As any role with permission to create Remote Video media, I can add a URL and create a media entity via /media/add/remote_video, then add it via the media library list in the widget. So there is currently a workaround.
In attempting to debug the issue, I noticed that in core/modules/media_library/src/Form/OEmbedForm.php, when I remove the #required attribute for the url field, I am able to select "Add" but the saved entity has an empty URL.
Steps to reproduce
1. Add field to content type or taxonomy:
Entity reference
Reference type: Media
Media type: Remote video (allowed providers: YouTube, Vimeo)
2. While logged in as a non-administrator, author content or taxonomy term. Select "Add media".
3. In the Media Library widget, enter a valid YouTube or Vimeo URL and select "Add".
4. The URL field becomes blank. Error messages related to required field missing value appear (see attached screenshot).
Proposed resolution
Remaining tasks
User interface changes
Introduced terminology
API changes
Data model changes
Release notes snippet
| Comment | File | Size | Author |
|---|---|---|---|
| #3 | Videograbación 2025-01-23 17_35_49.mp4 | 3.29 MB | wilsotoa |
| Screenshot 2024-09-10 at 11.10.35 AM.png | 36.17 KB | ericblack |
Comments
Comment #2
cilefen commentedI've read this report and I've not been able to reproduce this bug as written. Here is what I did:
Since you have a site set up to reproduce the bug we need more information from you on how to trigger the issue.
Comment #3
wilsotoa commentedHello cilefen, in my case I get the same error but it is due to the honeypot module, because when rendering the modal I get repeated several times the field 'url' and when I assign the permission Bypass Honeypot protection, to my user who has the basic permissions of content editor then if the form works correctly, I share video.
Comment #4
quietone commentedChanges are made on on 11.x (our main development branch) first, and are then back ported as needed according to the Core change policies.
Comment #5
smustgrave commentedWanted to bump 1 more time before closing.
Comment #7
bbralaBeen a while. Guess no issue anymore.