-
-
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
SQL-Sanitize Fails in Drush 9.0.0-beta4 #3013
Comments
Correct, that flag was removed. You should sql-sync and then sql-sanitize.
You now need a functional Drupal site in order to sanitize. I think thats
why the command is not being listed. This was impossible to avoid.
|
interesting, the command does appear when there is a functional site (and does not when there isn't). thanks for the prompt response! |
The new architecture for Drush 9 instantiates Drupal-specific Drush commands via the Drupal services.yml mechanism, from information contained in a drush.services.yml file. This allows Drush commands to participate in Drupal dependency injection. Because Drupal-specific commands now expect Drupal objects to be injected into them, Drush does not instantiate any of these types of commands unless there is a valid site available. It is an aspirational goal to instead instantiate a proxy command for all of the Drupal-specific commands, so that they are not completely invisible when inspecting Drush from a non-bootstrapped environment. Running such a proxy command would only print a message advising the user how to select a site, or make their selected site bootstrap-able. |
After upgrading to 9.0.0-beta4, we are attempting to sanitize databases during syncs.
it would appear that the --sanitize flag was removed in this commit (19543e5#diff-fb2c277772bf5979ffd2cd9676de3c88). Note that it is still listed out here as a flag -- https://drushcommands.com/drush-9x/core/sql-sync/.
The commit message on ^^^ indicates that sql-sanitize is now intended to be run as a separate command and not attached as a flag to sql-sync.
As far as we can tell (see https://github.com/drush-ops/drush/blob/master/src/Drupal/Commands/sql/SanitizeCommands.php) sql-sanitize is still supposed to be a command that functions, however when doing a drush list it doesn't appear in the sql commands, and it doesn't work when running it.
The text was updated successfully, but these errors were encountered: