Problem/Motivation
==================
Filebrowser provides config/install/field.field.node.dir_listing.body.yml which depends on field.storage.node.body.
Starting from Drupal 11.3, the node module from core no longer provide the body field storage directly. It was moved into the deprecated node_storage_body_field compatibility module. Drupal’s guidance states that sites, profiles, recipes, and extensions using the body field should provide their own copy of field.storage.node.body.yml.
On a clean Drupal 11 installation, enabling Filebrowser fails with:
Drupal\Core\Config\UnmetDependenciesException:
Configuration objects provided by Filebrowser have unmet dependencies:
field.field.node.dir_listing.body (field.storage.node.body)
Steps to reproduce
==================
1. Install Drupal 11.3 or later using the minimal profile.
2. Download Filebrowser 3.1.x.
3. Run drush pm:enable filebrowser -y
4. Filebrowser installation fails because field.storage.node.body does not exist.
Proposed resolution
===================
- Provide field.storage.node.body.yml as optional Filebrowser configuration.
- Move field.field.node.dir_listing.body.ymlfrom config/install to config/optional.
- Allow Drupal’s optional configuration installer to create both configurations in dependency order.
Using optional configuration is important for compatibility:
- On Drupal 11, the missing body storage and Filebrowser body field are created.
- On Drupal 10 or another site where node.body already exists, the existing storage is preserved and only the Filebrowser bundle field is installed.
The configuration matches Drupal core’s node_storage_body_field storage definition.
Regression coverage
===================
The attached patch contain functional tests covering:
1. Installing Filebrowser when node.body does not exist.
2. Installing Filebrowser when node.body already exists.
Without the fix, installation fails with UnmetDependenciesException.
Also attaching guidance from Core for reference: https://www.drupal.org/node/3223395#s-node-storage-body-field
| Comment | File | Size | Author |
|---|---|---|---|
| drupal-11-body-field-storage-fix.patch | 3.92 KB | sker101 |
Comments
Comment #3
clivesj commentedThanks
Comment #5
clivesj commented