-
-
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
drush sql-query should exit with failure status if query fails #34
Comments
… query fails for any reason. Fixes #34.
Above are the commits to master and 8.x-6.x. Did not backport to 7.x-5.x as an overly-cautious nod to backwards compatibility. I think this could go in 5.x if anyone felt strongly that it shoudl. |
I would very much like it to go into 5.x, if that would be possible. |
But wow, what amazing responsiveness! Thanks! |
… query fails for any reason. Fixes #34.
Backported to 7.x-5.x. Seems like a pretty slim chance that anyone would have a script broken because they expected the script to keep running after a failed sql-query command. If anyone has any problems with this, please re-open, or just back out the change. |
Actually, that _drush_sql_query is an API function used elsewhere (I think). We should probably throw an error in the command callback, drush_sql_query(). |
You're right, I put that in the wrong place. I fixed it in master, 6.x and 5.x, but forgot to mention this issue in the commit comment. The commit on master was b8522b3 |
… query fails for any reason. Fixes drush-ops#34.
… query fails for any reason. Fixes drush-ops#34.
I'm still experiencing this on 8.x, apparently |
Currently, drush sql-query exits with a 0 even if there was an error in the query:
I think it would be useful to all of us if it returned an error status in a case like this.
Thanks!
The text was updated successfully, but these errors were encountered: