Change record status: 
Project: 
Introduced in branch: 
9.4.x
Introduced in version: 
9.4.0
Description: 

Module uninstall validators are now run during the validation step prior to actually uninstalling modules as part of a configuration import.

If a custom or contributed module has a service that implements \Drupal\Core\Extension\ModuleUninstallValidatorInterface and requires different logic prior to uninstalling due to a configuration import then the validator can implement \Drupal\Core\Extension\ConfigImportModuleUninstallValidatorInterface. For example, module that provide fields can be uninstalled via configuration even if there are fields with data because the field module implements hook_config_import_steps_alter() in order to purge any field data.

Impacts: 
Module developers