Problem/Motivation
\Drupal\Core\Entity\EntityDeleteForm
is marked as being a member of Drupal's internal-only API, which is subject to the possibility of a higher frequency of backward-incompatible changes between releases. Curiously, \Drupal\Core\Entity\EntityDeleteFormTrait
is not internal. Also, contrib seems to be making use of this internal-only API (likely by mistake).
Proposed resolution
Make EntityDeleteForm
part of Drupal's public API (similar to EntityDeleteFormTrait
).
User interface changes
n/a
API changes
This issue would only change the visibility of internal API to public API.
Data model changes
n/a
Issue fork drupal-3196168
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 #3
clayfreemanComment #4
longwave@internal was added on a blanket basis to all core forms in #2873696: Add @internal to core form classes, methods, and properties. However I agree there doesn't seem to be a good reason in this case, and many contrib modules are already extending it anyway: http://grep.xnddx.ru/search?text=extends+EntityDeleteForm&filename=
Comment #5
longwaveUnsure if #2491057: Streamline the entity deletion form class hierarchy is still relevant but I suppose it should be considered before committing this. Alternatively maybe that just needs to be closed as won't fix, especially if contrib already has expectations here.
Comment #6
alexpottRe #5 that issue suggests removing the trait and moving the methods to EntityDeleteForm - which definitely makes this less @internal. Also the current docs for EntityDeleteForm say
* Provides a generic base class for an entity deletion form.
- I don't think a generic base class should be @internal.Committed ed76f2c and pushed to 9.2.x. Thanks!
Comment #9
TR CreditAttribution: TR commentedShouldn't there be a change record for this?