1

I am getting an error when importing the configuration from our development branch. When running. drush cim staging.
The error is.

The import failed due to the following reasons: Unable to install the responsive_tables_filter module since it does not exist. We installed this module a long time ago but then unistalled it, disabled it, then deleted it.

There were settings for responsive_tables_filter in these 2 config files.
/config/core.extension.yml
/config/lightning_core.versions.yml

I removed both settings. Then ran drush export then pulled from development again and ran drush import and the error was gone.
Is it safe to manually edit these files?

1 Answer 1

1

If the module was never installed in the target environment, it is safe to do so.

If the module was installed before however, and it features uninstall hooks for cleaning up possibly installed database tables, key/value pairs (State API), and the like, then your approach may leave data behind.

The more appropriate way would have been to uninstall the module after you restored its module files, then export the configuration again in development, push it to production and do the import there.

Afterwards you can safely delete the module files from your environments.

The error you've seen indicates, that your code base was not in sync with your configuration. You possibly tested modules and removed its files before uninstalling them.

2
  • Thank you. We ended up manually editing the files and removing the settings. We had a simular issue with another module in the past and we did what you said. We we reinstalled it, then unistalled and removed it. But I am not sure if this module has a working hook_unistall. Commented Feb 27, 2019 at 12:47
  • How does one simply "install" the module. Every time I try 'drush install XYZ' I get: Unable to install modules XYZ due to missing modules XYZ.
    – Ben Alan
    Commented May 21 at 16:28

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.