-
-
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
New TTY detection in 9.7.0 breaks sql-cli input via STDIN (fixed, needs test) #4092
Comments
This keeps breaking. 😢 |
Yeah. I'm certainly not oblivious to the fact that I'm the one who introduced this regression in #4033 😢 Getting this right is hard. I'm not sure where to go from here. For one thing, we should probably add a test to ensure |
Yeah I've been testing with |
This appears to be yet another instance where Drush stopped using its own code and started using a method from Symfony on the theory that the upstream was better tested and more maintainable, but ended up breaking some use-cases. Maybe we should bring back our TerminalUtils method, and fall back on Symfony when |
Seems that consolidation/site-process#43 fixes this. |
Tagged stable release consolidation/site-process 2.0.3. If you are using a site-local Drush, just run |
A PR with a new test for sql-cli would be most welcome. |
Thanks a lot for the quick response. It is indeed fixed by consolidation/site-process#43 I'll try to prioritize a test for this in the next few days. |
@greg-1-anderson I was just starting to write a test for this, and noticed an architectural discrepancy you should decide on I've always done If you look at It seems like we should either:
I don't have a strong opinion, let me know what you think. |
I tend to think that The |
Thanks for the guidance, fixed in #4100 |
Describe the bug
In versions of Drush prior to 9.7.0, you could provide arguments to sql-cli via STDIN. This is no longer possible in 9.7.0. Most notably, this breaks the ability to import db dumps via Drush (I'm not sure of any easier way than using sql-cli).
To Reproduce
Create a db dump, attempt to import it like so:
drush sql-cli < mysqlDump.sql
Expected behavior
SQL tables to be imported
Actual behavior
Silent failure, nothing imported.
Workaround
Retrieve the SQL connection information via Drush, then feed it to mysql directly in order to import data.
System Configuration
Additional information
Regression due to #4033
The text was updated successfully, but these errors were encountered: