-
-
Notifications
You must be signed in to change notification settings - Fork 1.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Run batch process when (un)installing modules via config:import #5714
Conversation
I've added test coverage to a functional but than decided to move the whole class to integration. All green ;) |
Hello, After updating to drush 12 I stumbled on what looks like a race condition with language config collections which lead me to this issue. I am getting an error on a multilingual site during
At the beginning of This may not be easy to reproduce from a clean setup... but I'll try to do it when I have some time. Thank you |
@vever001 I haven't noticed but, indeed, this looks like a possible edge case. We probably need a new PR with a test that replicates the scenario to start with |
Thanks @claudiu-cristea, I opened #5838, and will try to provide more info there. |
Problem
Say a module install process requires some batch operations, like adding some initial content or like
locale
module, which is downloading translations. When such a module is installed withdrush en some_module
the batch process is running because of these lines fromPmCommands::install()
:if (batch_get()) { drush_backend_batch_process(); }
However, not only
drush en some_module
installs a module. There is alsodrush config:import
, which installs/uninstalls module based on changes detected incore.extension
config. In such cases, the batch process doesn't run.Proposal
On
processExtensions
config import sync step, if there's a batch waiting to be triggered, calldrush_backend_batch_process()
.