-
-
Notifications
You must be signed in to change notification settings - Fork 642
Uncaught Error: Call to undefined function cache_get() due to PHP version mismatch #1964
Comments
I'm not sure why the 7.3 version would still be installed... The php-versions role sets it here: https://github.com/geerlingguy/ansible-role-php-versions/blob/master/vars/Debian.yml#L14 And that overrides what's set in the php-mysql role here: https://github.com/geerlingguy/ansible-role-php-mysql/blob/master/vars/Debian.yml#L2 Is it possible this was a VM that was initially created with 7.3, then you changed the PHP version? There could be a bug in the process of changing PHP versions (but even that should work correctly). |
This is definitely related to #1963, which I'm about to fix through an upstream role update. |
I believe the above commit fixes this issue. Please try the latest master release and see if it's still an issue (I will be tagging a new release soon, as well). |
…eerlingguy#1964: Purge php-common package when installing different PHP version.
Issue Type
Your Environment
Your OS
Full console output
Summary
When I try to run any Drush command (or just
drush
) inside my VM, I get the above error. This is a Drupal 7 codebase.I think the problem is that even though I've configured the VM to use PHP 7.1, the CLI still uses PHP 7.3. And the MySQL extension is missing for PHP 7.3 (it's only present for 7.1).
As a workaround, I can run this in the VM:
sudo apt-get install php7.3-mysql
However, it seems like there's a bug in DrupalVM here, with one of two possible fixes:
My config.yml:
Seems similar to #1498
The text was updated successfully, but these errors were encountered: