Problem/Motivation
Hello project maintainers,
This is an automated issue to help make this module compatible with Drupal 10.
To read more about this effort by the Drupal Association, please read: The project update bot is being refreshed to support Drupal 10 readiness of contributed projects
Patches will periodically be added to this issue that remove Drupal 10 deprecated API uses. To stop further patches from being posted, change the status to anything other than Active, Needs review, Needs work or Reviewed and tested by the community. Alternatively, you can remove the "ProjectUpdateBotD10" tag from the issue to stop the bot from posting updates.
The patches will be posted by the Project Update Bot official user account. This account will not receive any issue credit contributions for itself or any company.
Proposed resolution
You have a few options for how to use this issue:
- Accept automated patches until this issue is closed
If this issue is left open (status of Active, Needs review, Needs work or Reviewed and tested by the community) and the "ProjectUpdateBotD10" tag is left on this issue, new patches will be posted periodically if new deprecation fixes are needed.
As the Drupal Rector project improves and is able to fix more deprecated API uses, the patches posted here will cover more of the deprecated API uses in the module.
Patches and/or merge requests posted by others are ignored by the bot, and general human interactions in the issue do not stop the bot from posting updates, so feel free to use this issue to refine bot patches. The bot will still post new patches then if there is a change in the new generated patch compared to the patch that the bot posted last. Those changes are then up to humans to integrate.
- Leave open but stop new automated patches.
If you want to use this issue as a starting point to remove deprecated API uses but then don't want new automated patches, remove the "ProjectUpdateBotD10" tag from the issue and use it like any other issue (the status does not matter then). If you want to receive automated patches again, add back the "ProjectUpdateBotD10" tag.
- Close it and don't use it
If the maintainers of this project don't find this issue useful, they can close this issue (any status besides Active, Needs review, Needs work and Reviewed and tested by the community) and no more automated patches will be posted here.
If the issue is reopened, then new automated patches will be posted.
If you are using another issue(s) to work on Drupal 10 compatibility it would be very useful to other contributors to add those issues as "Related issues" when closing this issue.
Remaining tasks
Using the patches
- Apply the latest patch in the comments by Project Update Bot or human contributors that made it better.
- Thoroughly test the patch. These patches are automatically generated so they haven't been tested manually or automatically.
- Provide feedback about how the testing went. If you can improve the patch, post an updated patch here.
Providing feedback
If there are problems with one of the patches posted by the Project Update Bot, such as it does not correctly replace a deprecation, you can file an issue in the Drupal Rector issue queue. For other issues with the bot, for instance if the issue summary created by the bot is unclear, use the Project analysis issue queue.
| Comment | File | Size | Author |
|---|---|---|---|
| #2 | entity_embed.1.x-dev.rector.patch | 14.59 KB | project update bot |
Issue fork entity_embed-3287235
Show commands
Start within a Git clone of the project using the version control instructions.
Or, if you do not have SSH keys set up on git.drupalcode.org:
Comments
Comment #2
project update bot commentedThis is an automated patch generated by Drupal Rector. Please see the issue summary for more details.
It is important that any automated tests available are run with this patch and that you manually test this patch.
Drupal 10 Compatibility
According to the Upgrade Status module, even with this patch, this module is not yet compatible with Drupal 10.
Currently Drupal Rector, version 0.12.0, cannot fix all Drupal 10 compatibility problems.
This patch does not update the
info.ymlfile for Drupal 10 compatibility.Leaving this issue open, even after committing the current patch, will allow the Project Update Bot to post additional Drupal 10 compatibility fixes as they become available in Drupal Rector.
Debug info
This patch was created using these packages:
Comment #3
mglamanQueued for 9.3 and 9.4
Comment #4
mglamanNeeds manual review (remove and make sure assertions transformed correctly.)
Is this needed? maybe not.
Comment #5
project update bot commentedThis is an automated patch generated by Drupal Rector. Please see the issue summary for more details.
It is important that any automated tests available are run with this patch and that you manually test this patch.
Drupal 10 Compatibility
According to the Upgrade Status module, even with this patch, this module is not yet compatible with Drupal 10.
Currently Drupal Rector, version 0.13.0, cannot fix all Drupal 10 compatibility problems.
This patch does not update the
info.ymlfile for Drupal 10 compatibility.Leaving this issue open, even after committing the current patch, will allow the Project Update Bot to post additional Drupal 10 compatibility fixes as they become available in Drupal Rector.
Debug info
This patch was created using these packages:
Comment #6
dave reidThis needs to also bump the drupal/core requirement from 9.2 to 9.4.
Comment #7
project update bot commentedThis is an automated patch generated by Drupal Rector. Please see the issue summary for more details.
It is important that any automated tests available are run with this patch and that you manually test this patch.
Drupal 10 Compatibility
According to the Upgrade Status module, even with this patch, this module is not yet compatible with Drupal 10.
Currently Drupal Rector, version 0.13.1, cannot fix all Drupal 10 compatibility problems.
This patch does not update the
info.ymlfile for Drupal 10 compatibility.Leaving this issue open, even after committing the current patch, will allow the Project Update Bot to post additional Drupal 10 compatibility fixes as they become available in Drupal Rector.
Debug info
This patch was created using these packages:
Comment #10
nkoporecStill needs a bit of work since drupal/embed doesn't have a D10 release
Comment #11
dave reidEmbed now has a D10 release
Comment #12
uditrawatComment #13
uditrawatI tested, @nkoporec (#9) MR on Drupal 10 and am happy to pass the review!
Test Steps.
Comment #14
uditrawatSome drupal tests failed.
https://www.drupal.org/pift-ci-job/2462015
Comment #15
nkoporecI have removed the update hooks and its tests and fixtures since those update hooks are more that 3 years old, instead I implemented the hook_update_last_removed().
I also added the
protected $failOnJavascriptConsoleErrors = FALSE;to ConfigurationUiTest, since D10 tests will fail if the console have any JS errors, I think that the JS error reported is not related to the module, but a core issue, see a similar issue https://www.drupal.org/project/drupal/issues/3091878The ContentTranslationTest failure is most likely a legit failure and we need to fix that still.
Comment #16
nkoporecFixed the tests, partly overlaps with https://www.drupal.org/project/entity_embed/issues/3269454, leaving up to the maintainers to decide whether to include this in this patch or commit the separate issue first.
Comment #17
mglamanhook_field_widget_single_element_form_alter was added in 9.2.x, when hook_field_widget_form_alter was deprecated. See https://www.drupal.org/node/3180429
Let's make the fixes backward compatible for at least 9.2.x with the file_url_generator service changes.
Comment #19
mglamanMoving to Needs Review.
I think we should address CKEditor5 in its own issue. Despite the fact this module may not do anything without it 😬. But this is a good first step.
Comment #20
wim leers+1 to adding CKE5 support in a separate issue — that already exists: #3272732: Drupal 10 & CKEditor 5 readiness 😊
Posted a review — I think we can reduce the amount of change and simplify the code 😊
Retitling because there's little automatic about this left 😅
Comment #21
dave reidI have officially bumped the module to require ^9.3 in the current 8.x-1.x branch.
Comment #22
project update bot commentedComment #24
jcnventuraRebased the MR, as the changes to composer.json and the info.yml file were creating merge conflicts
Comment #25
wim leersClosed #3264333: Drupal 9 - Deprecated class name Twig_Extension as a duplicate.
Comment #26
wim leersDone.
Comment #27
wim leersAnd now running all tests again against D10 — let's see what fails.
Comment #28
wim leersLet's find out how this does on Drupal 10.
Comment #29
mglamanDrupalCI + D10 fail unless
composer.jsonis modified.Comment #30
wim leers#29: I doubt it, because there's nothing about Drupal core in there:
Just like in #3294389: Fix fails in HEAD, there's no way to convince DrupalCI to run this on Drupal 10 — the only solution is to commit it. Because the only "Drupal 9.3" mention is in the
*.info.ymlfile and that has been broadened to support Drupal 10.Comment #31
wim leersRan the entire test suite in D10:
Comment #32
phenaproximaHiding patches in favor of the merge request.
Comment #34
phenaproximaTransferring credit from #3317353: Replace "stable" them with "stable9" for testing purposes.
Comment #35
wim leersThe 2 commits you added make total sense, and now it's green! 👍🚀
Comment #37
phenaproximaThanks, everyone. Merged into 8.x-1.x!
Note that we probably should NOT tag a release with this change until we have #3309747: Add CKEditor 5 compatibility and keep supporting CKEditor 4 done, because without CKEditor 5 support, this module is essentially worthless with Drupal 10 core alone.
Comment #39
rajab natshahThank you, for having time to maintain the Entity Embed important module.
Hoping for a soft tag release (
pre-release), to ease testing with Drupal 10Testing now with the
1.x-devdevelopment.Comment #40
loopy1492 commentedWorked great for me with the patch from MR9. Looking forward to a release.
Comment #41
rajab natshahAgrees with Adam
Comment #42
anybody@Maintainers: If #3309747: Add CKEditor 5 compatibility and keep supporting CKEditor 4 won't land soon and nobody can do anything about it, would it perhaps make sense to document on the module page, why there's no Drupal 10 compatible release yet for this module?
Or can anyone push things forward at #3309747: Add CKEditor 5 compatibility and keep supporting CKEditor 4 or become Co-Maintainer of Embed? Or does someone know someone who knows the maintainers to ping them? ;)
Thanks!
Comment #43
Sana.Neyazi commented@Maintaners: Do you have any idea if your team plans to be releasing a D10 compatible version of this module in the near future? Any help you can provide would be appreciated!
Thanks
Comment #44
heddnYou can still use ckeditor 4 w/ drupal 10. So a dev release that only supports ckeditor 4 isn't entirely worthless.
Comment #45
taran2l@phenaproxima, CKE4 is still relevant for D10 as updating CKE4 to CKE5 is not that straightforward. So, having a D10 compliant release with CKE4 support only is completely fine
Comment #46
wxman commentedI'm using Drupal 9.5.x and this is the only important module still showing not compatible on Upgrade Status. I tried following this thread but lost it. Is there a available patch that would cover the upgrade to 10?
Comment #47
samlerner commented@wxman I think you're looking for #3272732: Drupal 10 & CKEditor 5 readiness which has a patch that needs review.
Comment #48
wxman commented@SamLerner I think it looks like the working patch is https://www.drupal.org/files/issues/2023-05-05/entity_embed-3272732-80.p... .
What I'm wondering, before I try it, if this is one I can apply to the module while still using D9.5.x. As far as I understand, the upgrade won't work unless all the installed modules show ready for D10.
Comment #49
samlerner commented@wxman you'd need a patched and working version of Embed to also get a patched version of Entity Embed working. Hopefully that gets resolved soon, lots of attention on it since it's DrupalCon. Once Embed is CKE5-compatible, this should quickly follow.