drupal-console icon indicating copy to clipboard operation
drupal-console copied to clipboard

Workaround for missing mysql extension

Open drubb opened this issue 10 years ago • 10 comments

DrupalConsole does a settings check when running commands, which checks for php 'mysql' extension. When this extension is missing, it says The extension mysql is recommended to install..

This extension has been removed in PHP 7, and for previous versions it's not mandatory. There are mysqli and mysqlnd, too. IMHO DrupalConsole should not check the ancient mysql extension, if there's a newer extension available.

drubb avatar Apr 12 '16 13:04 drubb

@drubb You can change setting checked as true and avoid receiving any messages by executing

drupal settings:set checked "true"

jmolivas avatar Apr 13 '16 06:04 jmolivas

The above does not work (php70, and just installed everything (php, php extensions, composer, drupal console) new today):

[rkoberg@mbp ~/Sites/fwi/drupal (master *)]$ drupal settings:set checked "true"
 [OK] Setting checked was set to true                                             
[rkoberg@mbp ~/Sites/fwi/drupal (master *)]$ drupal check
 The extension mysql is recommended to install.                                                                      
 [OK] Checks passed.            
 // settings:set                                                                                                                     
 [OK] Setting checked was set to true  

rkoberg avatar May 24 '16 18:05 rkoberg

I need to test on php7 and create a diff set of extensions for this version.

Currently the checker only for works properly on php5 https://github.com/hechoendrupal/DrupalConsole/blob/master/config/dist/phpcheck.yml

jmolivas avatar May 24 '16 18:05 jmolivas

If it's broken the check for the mysql extension should be removed until it's fixed.

I just end up losing an hours trying to fix a problem than I didn't have.

gagarine avatar Jul 10 '16 15:07 gagarine

me too

cristinallamas avatar Jul 10 '16 15:07 cristinallamas

:-1:

poproar avatar Jul 13 '16 03:07 poproar

same issue here

thisisablock avatar Jul 13 '16 08:07 thisisablock

same here also sqlite3 (Ubuntu 16.04 - PHP7.0)

zuernBernhard avatar Jul 25 '16 13:07 zuernBernhard

I use everyday PHP7 and my extensions are this one: pdo_mysql opcache gd soap bcmath imagick xdebug

(The black ones are mandatory, the others are specific for my projects)

Saphyel avatar Jul 30 '16 10:07 Saphyel

@zuernBernhard I changed the pull request according to your comment. If you have some time review https://github.com/hechoendrupal/DrupalConsole/pull/2518 so it can be merged

gagarine avatar Jul 31 '16 15:07 gagarine