Page MenuHomePhabricator

Installer does not warn when webserver has PHP 5.1.x only
Closed, ResolvedPublic

Description

Installer does not warn when webserver has PHP 5.1.x only.

I run into this trap after a successfully installation of 1.17 (trunk) on a webserver with PHP 5.1.x only.

Fatal error: Call to undefined function array_fill_keys() in /var/www/html/kunden/ztd/w/includes/resourceloader/ResourceLoader.php on line 516

array_fill_keys() was introduced in PHP 5.2.0


Version: 1.17.x
Severity: normal

Details

Reference
bz27781

Event Timeline

bzimport raised the priority of this task from to Medium.Nov 21 2014, 11:28 PM
bzimport set Reference to bz27781.
bzimport added a subscriber: Unknown Object (MLST).

http://www.mediawiki.org/wiki/Installation says we support 5.1 or later (5.2 preferred). Looks like it needs to be 5.2 or later, or fix that method call

It seems easily to add an wrapper for this function, see the note in http://php.net/manual/en/function.array-fill-keys.php if we want to support PHP 5.1.x.

I think we should support 5.1.x for the last time in 1.17, providing a back-compat version (or fixing the array_fill_keys functions to do something else).

For 1.18/trunk, I think we should bump the requirement to 5.2.x (5.3.x preferred, of course).