-
-
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 12 Upgrade issues #5694
Comments
Looks like your configuration is using Drush 8 as a launcher to run Drush 12. Try adjusting your $PATH so that Drush 12 is called directly. |
Interesting. I could look into why the container would be doing this, but it does beg the question why it isn't having the same issue with Drush 11. |
Looks like the deprecation warnings are in the box (.phar maker) libraries of Drush 8. In theory, these are compatible with PHP 8.2. I'm not sure what the issue is with your Acquia example. |
My actual local computer really doesn't handle the drush commands, so $PATH probably won't fix anything. Here's the relevant stuff in my computer's $PATH:
But when you execute drupal with docksal using I am very curious why it's throwing an error now and never had a problem with Drush 11. It's very strange. |
In that configuration, my suggestion is for the path inside the container, which I suppose you do not maintain. |
I do not. I finally found something that explains the Docksal issue at least: docksal/docksal#1783 drush-ops/drush-launcher ref: drush-ops/drush-launcher#105 And I also noticed on Acquia, they are using a launcher, but the version is just reporting a variable: |
Acquia provides a launcher but you dont have to use it. Use vendor/bin/drush instead. I think everthing is covered in other issues so closing. |
Thanks so much for that explanation. I didn't realize that the direction was to literally use vendor/bin/drush on the command line rather than drush. Running Is that really how we're supposed to be executing drush commands now? I can't even create an alias for that. What's more, we cannot re-write the blt commands to use vendor/bin/drush. We'll have to stay with Drush 11 until BLT's drush commands run through ci without error. |
The maintainer of the image should remove the launcher, and add |
@greg-1-anderson Docksal doesn't actually enforce drush versioning. It leaves that up to the user. But yeah, they are going to have to adjust the image so that it doesn't use the launcher, it seems. |
They could adjust the PATH such that |
Flightdeck maintainer here, we added /var/www/vendor/bin to our $PATH and drush is now being found in our 8.1 and 8.2 containers, but it always claims Drupal doesn't exist, even when sitting in the docroot. |
Please open a new issue showing the command you ran, the dir you are in, and the -vvv log output. Also please show output of |
Actually, this thread pointed me in the right direction and we no longer have this issue. The problem is the container still had the Drush launcher globally installed and in $PATH. When the launcher is removed, the composer-local drush works as expected. |
I believe this is now fixed if you switch to https://github.com/docksal/service-cli/releases/tag/v3.6.0 |
Describe the bug
We have sites running Drupal 10 and Drush 11 on PHP 8.1. Recently, there was an upgrade to BLT from 13.7.0 to 13.7.1 which includes Drush 12. We've had several issues with this. We have been able to downgrade drush/drush to ^11.0 for the time being, but I was hoping to get to the bottom of this. On our local sites, when we run drush commands, we get deprecation warnings, but the commadns run. When we push the code up to the remote, Acquia pipelines fails as it is unable to execute any Drush commands. Since we are having problems in both environments, I chose to create a bug report here instead of in the issue queues for those two projects.
To Reproduce
Expected behavior
Drush commands run without error or deprecation warnings.
Actual behavior
Local
Locally, we are using Docksal. During any drush command, we get the following deprecation warnings:
It makes me think Drush 12 would prefer it if we installed PHP 8.2. Not sure.
I really wonder why it's looking in usr/local/bin/drush8. Drush 12 is bootstrapping:
However, after these warnings, the commands do actually run. I noticed some issues that have a similar error point to the drush launcher being an issue.
fin drush --version
reports we are using Drush Launcher 0.10.1.Acquia
We can't get any branches with Drush 12 past pipelines. We get the following error:
drupal:sync:db
I was wondering if there's something amiss with our site file. Here's the code for the test environment's alias:
As far as I can tell, no documentation has said we need to change anything with these files when upgrading from 11.x-12.x
Workaround
Downgrade to 11.x
System Configuration
Thanks, in advance, for your help.
The text was updated successfully, but these errors were encountered: