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.
Problem/Motivation
The bits in \Drupal\views\Plugin\Derivative\ViewsEntityRow
relies on being cached by language, but in fact we DefaultPluginManager expects to be TranslationWrappers, so it just caches plugin definitions once.
Proposed resolution
Use TranslationWrappers and let $entity_type->getlabel() return a translation wrapper.
Comments
Comment #9
LendudeCleaning up old bugs.
\Drupal\Core\Entity\EntityTypeInterface::getLabel now typehints to string|\Drupal\Core\StringTranslation\TranslatableMarkup, so hopefully we are good here.
Not sure if there is still anything else we need to do here, feel free to re-open is you feel there is still work to do here.