Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
It looks like at current level of revisions support in ContentEntityForm RevisionableContentEntityForm became obsolete and should be deleted.
There is number of issues reporting bugs in it like #2839956: RevisionableContentEntityForm::getBundleEntity() is broken for entities that use non-entity bundles, #2913439: Some revision fields are duplicated which from my understanding all fixable by not using RevisionableContentEntityForm and using ContentEntityForm and entity annotation correctly.
Happy to provide a patch if agreed.
Comments
Comment #2
RoSk0Cross-linking
Comment #3
bojanz CreditAttribution: bojanz at Centarro commentedAgreed. ContentEntityForm now has everything that's needed.
Comment #4
bojanz CreditAttribution: bojanz at Centarro commentedLet's remove EntityViewBuilder at the same time, since it's the only other removal left.
Comment #6
bojanz CreditAttribution: bojanz at Centarro commentedDone.
Comment #7
freelockHi,
This removal has led to #2952374: Update Media Entity to use 8.5.x APIs in Media Entity... I created a patch that changes the base form to \Drupal\Core\Entity\ContentEntityForm, but the tests are still failing because of a missing field:
1) Drupal\Tests\media_entity\Functional\MediaUiFunctionalTest::testMediaWithOnlyOneBundle
Behat\Mink\Exception\ElementNotFoundException: Form field with id|name|label|value "edit-revision" not found.
... any suggestions for what needs to change over there?