Active
Project:
DBTNG
Version:
6.x-1.x-dev
Component:
Code
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
3 Jul 2009 at 17:49 UTC
Updated:
27 Jan 2011 at 20:42 UTC
Need to implement hook_requirements to check that PDO is installed, otherwise, bail and disable the module or functions somehow?
Comments
Comment #1
mikey_p commentedThis is probably not worth it since most PHP version of 5.2 or greater come with PDO.
Comment #2
sdrycroft commentedProbably not a bad idea to add this in, and prevent users like myself experiencing PHP Fatal errors.
Comment #3
mikey_p commentedCould you expand on how you ran into this error? This module now requires PHP 5.2 which comes with PDO, did you try enabling an older version of this module or do you have a nonstandard PDO compiled with PHP 5.2?
Comment #4
marvil07 commentedPDO installed do not mean to have the right PDO driver installed, so that seems to be a good reason :-)
BTW #978922: Implement hook_requirements() for PDO was marked as duplicate of this
Comment #5
kscheirerI got this fatal error as well
Implementing hook_requirements() would at least try to prevent this module from being enabled when the needed PDO drivers are not present.
I started on a patch for this over in #761098: Oracle driver compatibility and general 7.x driver issues - right now it is just a runtime check, I think we just need to add the same check when $phase is "install". I was doing it for people with Oracle PDO problems (which is almost never on by default in PHP), but maybe we should close that issue and bring the patch here.