- 🇺🇸United States dave reid Nebraska USA
This is going to pop up again with the new sdc module that was added to Drupal 10.1, while it exists in contrib for D9/D10.0:
https://www.drupal.org/project/drupal/issues/3340712#comment-15015670 ✨ Add Single Directory Components as a new experimental module Fixed
https://www.drupal.org/project/sdc →Anyone who declares a dependency on drupal:sdc in their .info.yml files going forward will unexpectedly get the contrib module. We really need this solved.
- 🇧🇪Belgium wim leers Ghent 🇧🇪🇪🇺
@Dave Reid: hah, you beat me to it, I was about to post the same! 😊
- 🇺🇸United States drumm NY, US
We've mentioned that projects need their name changed as they go into core to avoid conflicts. Since it does happen, we do have some handling of this around
project_composer_get_core_modules()
https://git.drupalcode.org/project/project_composer/-/blob/62ac7f27f70fd... - 🇬🇧United Kingdom MrDaleSmith
I still think it's a confusing Drupalism to be parsing composer dependencies from the info.yml files. Composer handles dependencies and where they should be downloaded from really well and all our documentation says "Use composer to manage your dependencies". It just causes issues to say "Drupal uses composer to manage dependencies, kind of - sometimes we think it's best to ignore it and use something else".
- 🇧🇪Belgium wim leers Ghent 🇧🇪🇪🇺
#36: ahh, right! Sorry about that.
And that is also why this is impossible to solve for CKEditor 4: it lived in core, and to ensure a smooth transition to those sticking to CKEditor 4 for now in Drupal 10, it must have the same name.
#37: I think everybody agrees with you on that. But Drupal predates Composer by literally more than a decade. So I think it's understandable that we have to slowly evolve, to bring the entire ecosystem along 😊 You're absolutely right it's confusing though!
- 🇬🇧United Kingdom MrDaleSmith
We've had a fair amount of time to get used to it, though, where we didn't with other changes like namespacing and plugins. I'd be interested to find out how many projects on d.org have dependencies in their info.yml files that aren't in their composer.json files - can it really be that big a number given that we never told anyone we'd use info.yml for composer dependencies?
- 🇺🇸United States joshuami Portland, OR
I'm trying to help a couple clients through their CKEditor 5/Drupal 10 upgrades and have come to the conclusion there are two paths:
Option 1: While on Drupal 9, upgrade to CKeditor 5, then upgrade to Drupal 10.
Option 2: Upgrade to Drupal 10 using the contrib ckeditor module, then upgrade to CKEditor 5 at a later date.
Either option is going to require some custom work to replace functionality from CKEditor 4 contrib modules (ckeditor_acr 1.0.1, ckedtior_config 8.x-3.1), some custom CKEditor 4 widgets (for inserting a phone number, email address, columns, accordions), and some code that relied on the MediaEmbedDialogue form and the ability to edit a media item inline and change attributes.
Of the two approaches, I would prefer option 2. Upgrading core to Drupal 10 is a larger risk. The smaller risk of not having our CKEditor 4 functionality replicated is not ideal—replicating the functionality is a fair bit of work—but at least it would *just* be CKEditor.
I was just about to post that there does not seem to be a valid way to add the contrib ckeditor to the latest Drupal 9 release, but then I happened on a successful order of operations.
Running
composer remove drupal/ckeditor_acr
orcomposer remove drupal/ckeditor_config
gives me an error likeckeditor_acr is not required in your composer.json and has not been removed
.If I manually remove ckeditor_acr and ckeditor_config from my composer.json, and run
composer update --lock
, the files for those two modules are removed. When I then try tocomposer require drupal/ckeditor:'^1.0'
, it adds the dependency to the composer.json file, but not to the composer.lock file. A newcomposer install
gives the error:- Required package "drupal/ckeditor" is not present in the lock file. This usually happens when composer files are incorrectly merged or the composer.json file is manually edited. Read more about correctly resolving merge conflicts https://getcomposer.org/doc/articles/resolving-merge-conflicts.md and prefer using the "require" command over editing the composer.json file directly https://getcomposer.org/doc/03-cli.md#require-r
It turns out that I also needed, to remove the following:
"provide": { "drupal/ckeditor": "*" },
This snippet was recommended in 3309026 → to stop ckeditor_config's requirement of drupal/ckeditor from downloading the contrib module unexpectedly. I was able to require, enable, and reconfigure ckeditor_acr and ckeditor_config after successfully switching to the CKEditor 4 contrib module.
If anyone has a simpler upgrade path, please share. If anyone thinks this comment belongs in another queue, let me know.
- 🇧🇪Belgium wim leers Ghent 🇧🇪🇪🇺
#40: RE options 1 & 2: that's also documented in the change record → , and the deprecated & obsolete modules handbook page → . I 💯% agree that that is not enough though. I've been unsuccessful at convincing core committers that #3304736-43: Provide a good UX to ensure the CKEditor 4 to 5 update is always done before upgrading to Drupal 10 unless the contrib module is installed → would have made all this much clearer. 😞 Could you please post a similar comment there? 🙏😊
- 🇺🇸United States joshuami Portland, OR
Thanks, Wim. I posted a comment (and a comment on my comment). I appreciate the link to the specific CKEditor 5 change record → .
Sheepishly, I have to admit that I'm not good at following change records—there are just so many of them.
I read release notes—though not all as I don't tend to read the release notes for a branch I'm not currently using. I like xjm's suggestion to include some reference to these known issues in release notes and to the Drupal 10 upgrade handbook → .
Incidentally, I could only find that handbook by searching, it might make sense to include references to that upgrade process in the next few release notes as well. Upgrade instructions are more important information than linking to the release cycle. (Or at the very least the release cycle should link to those upgrade instructions.)
In the update contributed projects → section of that handbook, it makes it sound like upgraded modules will just be compatible, but I've found several modules that have a version compatible with Drupal 9 or Drupal 10 but not both. I feel like we might need a bit of documentation to help module maintainers understand that it is best practice to have a release that is compatible with both major versions at each end of life transition to aid in the upgrade process.
Maybe we could add a bit to the Drupal 9 compatibility section of the → add a composer.json file → page in the creating modules handbook → .
- 🇺🇸United States dave reid Nebraska USA
FYI as of today we are now getting the https://www.drupal.org/project/ckeditor_lts → project installed instead of https://www.drupal.org/project/ckeditor → because of the module name is ckeditor_lts is actually "ckeditor". This problem has continued.
- 🇺🇸United States drumm NY, US
The ckeditor_lts issue was resolved with https://git.drupalcode.org/project/project_composer/-/commit/ae29b4b2060...
- 🇺🇸United States markfien
Our upgrade from 9.5 to 10.1 has been disastrous as it relates to CKEditor 5.
Will the commit resolve this issue:
The "ckeditor" plugin does not exist. Valid plugin IDs for Drupal\editor\Plugin\EditorManager are: ckeditor5
or this which we get everytime we try to access anything to edit
.. throw new PluginNotFoundException($plugin_id, sprintf('The "%s" plugin does not exist. Valid plugin IDs for %s are: %s', $plugin_id, static::class, $valid_ids));TIA, Mark
@markfien Did you install the contributed drupal/ckeditor on that site? You must if you did not convert to CKEditor 5.