Skip to main content

When you are in the status report of the admin area are you finding the following issue:

ENTITY/FIELD DEFINITIONS Mismatched entity and/or field definitions
The following changes were detected in the entity type and field definitions.

File
The File type field needs to be installed.

Paragraph
The Published field needs to be updated.
The Behavior settings field needs to be updated.

Check whether you have the module file_entity.  As File Entity has mostly been installed in to the core, this could be the fall out of different versions.  On the module project page there is a note 

This module has been renamed or deprecated by another module in Drupal 8

If you uninstall the module, then the error will vanish.

For some, resolving the error will be uninstalling the module.  However, if you were like us, the uninstall option failed to work.  So to test that this is the error (for us), we rebuilt a relative new site without the module.  And presto, the error was gone.

More on the error... when reviewing the server logs the error was:

Uncaught PHP Exception Drupal\\Core\\Field\\FieldException: "Attempt to create a field field_image_alt_text that does not exist on entity type file." at /var/www/vhosts/example.com/dir/core/modules/field/src/Entity/FieldConfig.php line 293, referer: https://example.com/admin/modules/uninstall/confirm

Related articles

Andrew Fletcher04 Apr 2025
Managing .gitignore changes
When working with Git, the .gitignore file plays a critical role in controlling which files and folders are tracked by version control. Yet, many developers are unsure when changes to .gitignore take effect and how to manage files that are already being tracked. This uncertainty can lead to...
Andrew Fletcher26 Mar 2025
How to fix the ‘Undefined function t’ error in Drupal 10 or 11 code
Upgrading to Drupal 10.4+ you might have noticed a warning in their code editor stating “Undefined function ‘t’”. While Drupal’s `t()` function remains valid in procedural code, some language analysis tools — such as Intelephense — do not automatically recognise Drupal’s global functions. This...
Andrew Fletcher17 Mar 2025
Upgrading to PHP 8.4 challenges with Drupal contrib modules
The upgrade from PHP 8.3.14 to PHP 8.4.4 presents challenges for Drupal 10.4 websites, particularly when dealing with contributed modules. While Drupal core operates seamlessly, various contrib modules have not yet been updated to accommodate changes introduced in PHP 8.4.x. This has resulted in...